@gamecrafters/base-ui 0.0.24 → 0.0.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/build/components/combobox/Combobox.d.ts +36 -0
  2. package/build/components/combobox/Combobox.types.d.ts +146 -0
  3. package/build/components/combobox/ComboboxClearTrigger.d.ts +6 -0
  4. package/build/components/combobox/ComboboxContent.d.ts +5 -0
  5. package/build/components/combobox/ComboboxContext.d.ts +4 -0
  6. package/build/components/combobox/ComboboxControl.d.ts +5 -0
  7. package/build/components/combobox/ComboboxEmpty.d.ts +5 -0
  8. package/build/components/combobox/ComboboxInput.d.ts +5 -0
  9. package/build/components/combobox/ComboboxItem.d.ts +9 -0
  10. package/build/components/combobox/ComboboxItemGroup.d.ts +6 -0
  11. package/build/components/combobox/ComboboxItemGroupLabel.d.ts +5 -0
  12. package/build/components/combobox/ComboboxItemIndicator.d.ts +5 -0
  13. package/build/components/combobox/ComboboxItemText.d.ts +5 -0
  14. package/build/components/combobox/ComboboxLabel.d.ts +5 -0
  15. package/build/components/combobox/ComboboxList.d.ts +5 -0
  16. package/build/components/combobox/ComboboxPositioner.d.ts +8 -0
  17. package/build/components/combobox/ComboboxTrigger.d.ts +6 -0
  18. package/build/components/combobox/index.d.ts +104 -0
  19. package/build/components/index.d.ts +3 -0
  20. package/build/components/swap/Swap.d.ts +10 -0
  21. package/build/components/swap/Swap.types.d.ts +19 -0
  22. package/build/components/swap/SwapContext.d.ts +2 -0
  23. package/build/components/swap/SwapIndicator.d.ts +8 -0
  24. package/build/components/swap/index.d.ts +18 -0
  25. package/build/components/tour/Tour.d.ts +9 -0
  26. package/build/components/tour/Tour.types.d.ts +143 -0
  27. package/build/components/tour/TourActionTrigger.d.ts +8 -0
  28. package/build/components/tour/TourActions.d.ts +7 -0
  29. package/build/components/tour/TourArrow.d.ts +4 -0
  30. package/build/components/tour/TourBackdrop.d.ts +6 -0
  31. package/build/components/tour/TourCloseTrigger.d.ts +6 -0
  32. package/build/components/tour/TourContent.d.ts +5 -0
  33. package/build/components/tour/TourContext.d.ts +3 -0
  34. package/build/components/tour/TourControl.d.ts +5 -0
  35. package/build/components/tour/TourDescription.d.ts +5 -0
  36. package/build/components/tour/TourPositioner.d.ts +9 -0
  37. package/build/components/tour/TourProgressText.d.ts +5 -0
  38. package/build/components/tour/TourSpotlight.d.ts +6 -0
  39. package/build/components/tour/TourTitle.d.ts +5 -0
  40. package/build/components/tour/index.d.ts +64 -0
  41. package/build/components/tour/useTour.d.ts +2 -0
  42. package/build/components/tour/waitFor.d.ts +10 -0
  43. package/build/main.cjs.js +70 -70
  44. package/build/main.esm.js +68 -68
  45. package/build/styles/main.css +1 -1
  46. package/package.json +1 -1
@@ -0,0 +1,36 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "defaultValue" | "onSelect"> & {
3
+ value?: string[];
4
+ defaultValue?: string[];
5
+ onValueChange?: (value: string[]) => void;
6
+ onSelect?: (value: string) => void;
7
+ inputValue?: string;
8
+ defaultInputValue?: string;
9
+ onInputValueChange?: (inputValue: string) => void;
10
+ open?: boolean;
11
+ defaultOpen?: boolean;
12
+ onOpenChange?: (open: boolean) => void;
13
+ highlightedValue?: string | null;
14
+ defaultHighlightedValue?: string | null;
15
+ onHighlightChange?: (highlightedValue: string | null) => void;
16
+ multiple?: boolean;
17
+ closeOnSelect?: boolean;
18
+ selectionBehavior?: import("./Combobox.types").ComboboxSelectionBehavior;
19
+ inputBehavior?: import("./Combobox.types").ComboboxInputBehavior;
20
+ allowCustomValue?: boolean;
21
+ loopFocus?: boolean;
22
+ openOnClick?: boolean;
23
+ openOnChange?: boolean;
24
+ openOnKeyPress?: boolean;
25
+ filter?: import("./Combobox.types").ComboboxFilter;
26
+ shouldFilter?: boolean;
27
+ disabled?: boolean;
28
+ readOnly?: boolean;
29
+ invalid?: boolean;
30
+ required?: boolean;
31
+ placeholder?: string;
32
+ name?: string;
33
+ form?: string;
34
+ className?: string;
35
+ } & React.RefAttributes<any>) => React.ReactNode;
36
+ export default _default;
@@ -0,0 +1,146 @@
1
+ import type * as React from "react";
2
+ import type { ButtonVisual } from "../button";
3
+ import type { TextInputProps } from "../text-input";
4
+ import type { AnchorAlignment, AnchorSide } from "../tooltip/anchoredPosition";
5
+ export type ComboboxInputBehavior = "none" | "autohighlight" | "autocomplete";
6
+ export type ComboboxSelectionBehavior = "replace" | "clear" | "preserve";
7
+ export type ComboboxFilter = (label: string, inputValue: string) => boolean;
8
+ export type ComboboxItemEntry = {
9
+ value: string;
10
+ label: string;
11
+ id: string;
12
+ groupId?: string;
13
+ disabled: boolean;
14
+ };
15
+ export type ComboboxContextValue = {
16
+ inputId: string;
17
+ labelId: string;
18
+ listId: string;
19
+ getItemId: (value: string) => string | undefined;
20
+ inputValue: string;
21
+ completion: string;
22
+ onType: (inputValue: string) => void;
23
+ setInputValue: (inputValue: string) => void;
24
+ value: string[];
25
+ isSelected: (value: string) => boolean;
26
+ select: (value: string) => void;
27
+ clear: () => void;
28
+ open: boolean;
29
+ setOpen: (open: boolean) => void;
30
+ openAt: (end: "first" | "last") => void;
31
+ highlightedValue: string | null;
32
+ setHighlightedValue: (value: string | null) => void;
33
+ moveHighlight: (step: number) => void;
34
+ entries: ComboboxItemEntry[];
35
+ register: (entry: ComboboxItemEntry) => void;
36
+ unregister: (value: string) => void;
37
+ matches: string[];
38
+ isMatch: (value: string) => boolean;
39
+ multiple: boolean;
40
+ disabled: boolean;
41
+ readOnly: boolean;
42
+ invalid: boolean;
43
+ required: boolean;
44
+ placeholder?: string;
45
+ inputBehavior: ComboboxInputBehavior;
46
+ openOnClick: boolean;
47
+ openOnKeyPress: boolean;
48
+ inputRef: React.RefObject<HTMLInputElement | null>;
49
+ controlRef: React.RefObject<HTMLDivElement | null>;
50
+ contentRef: React.RefObject<HTMLDivElement | null>;
51
+ };
52
+ export type ComboboxItemGroupContextValue = {
53
+ groupId: string;
54
+ labelId: string;
55
+ };
56
+ export type ComboboxItemContextValue = {
57
+ value: string;
58
+ selected: boolean;
59
+ highlighted: boolean;
60
+ disabled: boolean;
61
+ };
62
+ export type ComboboxProps = Omit<React.ComponentPropsWithoutRef<"div">, "onSelect" | "defaultValue"> & {
63
+ value?: string[];
64
+ defaultValue?: string[];
65
+ onValueChange?: (value: string[]) => void;
66
+ onSelect?: (value: string) => void;
67
+ inputValue?: string;
68
+ defaultInputValue?: string;
69
+ onInputValueChange?: (inputValue: string) => void;
70
+ open?: boolean;
71
+ defaultOpen?: boolean;
72
+ onOpenChange?: (open: boolean) => void;
73
+ highlightedValue?: string | null;
74
+ defaultHighlightedValue?: string | null;
75
+ onHighlightChange?: (highlightedValue: string | null) => void;
76
+ multiple?: boolean;
77
+ closeOnSelect?: boolean;
78
+ selectionBehavior?: ComboboxSelectionBehavior;
79
+ inputBehavior?: ComboboxInputBehavior;
80
+ allowCustomValue?: boolean;
81
+ loopFocus?: boolean;
82
+ openOnClick?: boolean;
83
+ openOnChange?: boolean;
84
+ openOnKeyPress?: boolean;
85
+ filter?: ComboboxFilter;
86
+ shouldFilter?: boolean;
87
+ disabled?: boolean;
88
+ readOnly?: boolean;
89
+ invalid?: boolean;
90
+ required?: boolean;
91
+ placeholder?: string;
92
+ name?: string;
93
+ form?: string;
94
+ className?: string;
95
+ };
96
+ export type ComboboxLabelProps = React.ComponentPropsWithoutRef<"label"> & {
97
+ className?: string;
98
+ };
99
+ export type ComboboxControlProps = React.ComponentPropsWithoutRef<"div"> & {
100
+ className?: string;
101
+ };
102
+ export type ComboboxInputProps = Omit<TextInputProps, "value" | "defaultValue" | "type" | "placeholder" | "disabled" | "readOnly" | "required"> & {
103
+ className?: string;
104
+ };
105
+ type ComboboxTriggerOwnProps = {
106
+ icon?: NonNullable<ButtonVisual>;
107
+ className?: string;
108
+ };
109
+ export type ComboboxTriggerProps = Omit<React.ComponentPropsWithoutRef<"button">, "aria-labelledby"> & ComboboxTriggerOwnProps;
110
+ export type ComboboxClearTriggerProps = ComboboxTriggerProps;
111
+ export type ComboboxPositionerProps = React.ComponentPropsWithoutRef<"div"> & {
112
+ side?: AnchorSide;
113
+ align?: AnchorAlignment;
114
+ portalContainerName?: string;
115
+ className?: string;
116
+ };
117
+ export type ComboboxContentProps = React.ComponentPropsWithoutRef<"div"> & {
118
+ className?: string;
119
+ };
120
+ export type ComboboxListProps = React.ComponentPropsWithoutRef<"div"> & {
121
+ className?: string;
122
+ };
123
+ export type ComboboxItemGroupProps = React.ComponentPropsWithoutRef<"div"> & {
124
+ forceMount?: boolean;
125
+ className?: string;
126
+ };
127
+ export type ComboboxItemGroupLabelProps = React.ComponentPropsWithoutRef<"div"> & {
128
+ className?: string;
129
+ };
130
+ export type ComboboxItemProps = Omit<React.ComponentPropsWithoutRef<"div">, "onSelect"> & {
131
+ value: string;
132
+ label?: string;
133
+ disabled?: boolean;
134
+ onSelect?: (value: string) => void;
135
+ className?: string;
136
+ };
137
+ export type ComboboxItemTextProps = React.ComponentPropsWithoutRef<"span"> & {
138
+ className?: string;
139
+ };
140
+ export type ComboboxItemIndicatorProps = React.ComponentPropsWithoutRef<"span"> & {
141
+ className?: string;
142
+ };
143
+ export type ComboboxEmptyProps = React.ComponentPropsWithoutRef<"div"> & {
144
+ className?: string;
145
+ };
146
+ export {};
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref">, "aria-labelledby"> & {
3
+ icon?: NonNullable<import("..").ButtonVisual>;
4
+ className?: string;
5
+ } & React.RefAttributes<any>) => React.ReactNode;
6
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,4 @@
1
+ import type { ComboboxContextValue, ComboboxItemContextValue, ComboboxItemGroupContextValue } from "./Combobox.types";
2
+ export declare const ComboboxContext: import("react").Context<ComboboxContextValue | null>;
3
+ export declare const ComboboxItemGroupContext: import("react").Context<ComboboxItemGroupContextValue | null>;
4
+ export declare const ComboboxItemContext: import("react").Context<ComboboxItemContextValue | null>;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<import("..").TextInputProps, "value" | "defaultValue" | "disabled" | "type" | "placeholder" | "readOnly" | "required"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,9 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "onSelect"> & {
3
+ value: string;
4
+ label?: string;
5
+ disabled?: boolean;
6
+ onSelect?: (value: string) => void;
7
+ className?: string;
8
+ } & React.RefAttributes<any>) => React.ReactNode;
9
+ export default _default;
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ forceMount?: boolean;
4
+ className?: string;
5
+ } & React.RefAttributes<any>) => React.ReactNode;
6
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.LabelHTMLAttributes<HTMLLabelElement>, HTMLLabelElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ className?: string;
4
+ } & React.RefAttributes<any>) => React.ReactNode;
5
+ export default _default;
@@ -0,0 +1,8 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
3
+ side?: import("..").AnchorSide;
4
+ align?: import("..").AnchorAlignment;
5
+ portalContainerName?: string;
6
+ className?: string;
7
+ } & React.RefAttributes<any>) => React.ReactNode;
8
+ export default _default;
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref">, "aria-labelledby"> & {
3
+ icon?: NonNullable<import("..").ButtonVisual>;
4
+ className?: string;
5
+ } & React.RefAttributes<any>) => React.ReactNode;
6
+ export default _default;
@@ -0,0 +1,104 @@
1
+ import ComboboxClearTrigger from "./ComboboxClearTrigger";
2
+ import ComboboxContent from "./ComboboxContent";
3
+ import ComboboxControl from "./ComboboxControl";
4
+ import ComboboxEmpty from "./ComboboxEmpty";
5
+ import ComboboxInput from "./ComboboxInput";
6
+ import ComboboxItem from "./ComboboxItem";
7
+ import ComboboxItemGroup from "./ComboboxItemGroup";
8
+ import ComboboxItemGroupLabel from "./ComboboxItemGroupLabel";
9
+ import ComboboxItemIndicator from "./ComboboxItemIndicator";
10
+ import ComboboxItemText from "./ComboboxItemText";
11
+ import ComboboxLabel from "./ComboboxLabel";
12
+ import ComboboxList from "./ComboboxList";
13
+ import ComboboxPositioner from "./ComboboxPositioner";
14
+ import ComboboxTrigger from "./ComboboxTrigger";
15
+ export declare const Combobox: ((props: Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "defaultValue" | "onSelect"> & {
16
+ value?: string[];
17
+ defaultValue?: string[];
18
+ onValueChange?: (value: string[]) => void;
19
+ onSelect?: (value: string) => void;
20
+ inputValue?: string;
21
+ defaultInputValue?: string;
22
+ onInputValueChange?: (inputValue: string) => void;
23
+ open?: boolean;
24
+ defaultOpen?: boolean;
25
+ onOpenChange?: (open: boolean) => void;
26
+ highlightedValue?: string | null;
27
+ defaultHighlightedValue?: string | null;
28
+ onHighlightChange?: (highlightedValue: string | null) => void;
29
+ multiple?: boolean;
30
+ closeOnSelect?: boolean;
31
+ selectionBehavior?: import("./Combobox.types").ComboboxSelectionBehavior;
32
+ inputBehavior?: import("./Combobox.types").ComboboxInputBehavior;
33
+ allowCustomValue?: boolean;
34
+ loopFocus?: boolean;
35
+ openOnClick?: boolean;
36
+ openOnChange?: boolean;
37
+ openOnKeyPress?: boolean;
38
+ filter?: import("./Combobox.types").ComboboxFilter;
39
+ shouldFilter?: boolean;
40
+ disabled?: boolean;
41
+ readOnly?: boolean;
42
+ invalid?: boolean;
43
+ required?: boolean;
44
+ placeholder?: string;
45
+ name?: string;
46
+ form?: string;
47
+ className?: string;
48
+ } & import("react").RefAttributes<any>) => React.ReactNode) & {
49
+ Label: (props: Omit<import("react").DetailedHTMLProps<import("react").LabelHTMLAttributes<HTMLLabelElement>, HTMLLabelElement>, "ref"> & {
50
+ className?: string;
51
+ } & import("react").RefAttributes<any>) => React.ReactNode;
52
+ Control: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
53
+ className?: string;
54
+ } & import("react").RefAttributes<any>) => React.ReactNode;
55
+ Input: (props: Omit<import("..").TextInputProps, "value" | "defaultValue" | "disabled" | "type" | "placeholder" | "readOnly" | "required"> & {
56
+ className?: string;
57
+ } & import("react").RefAttributes<any>) => React.ReactNode;
58
+ Trigger: (props: Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref">, "aria-labelledby"> & {
59
+ icon?: NonNullable<import("..").ButtonVisual>;
60
+ className?: string;
61
+ } & import("react").RefAttributes<any>) => React.ReactNode;
62
+ ClearTrigger: (props: Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref">, "aria-labelledby"> & {
63
+ icon?: NonNullable<import("..").ButtonVisual>;
64
+ className?: string;
65
+ } & import("react").RefAttributes<any>) => React.ReactNode;
66
+ Positioner: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
67
+ side?: import("..").AnchorSide;
68
+ align?: import("..").AnchorAlignment;
69
+ portalContainerName?: string;
70
+ className?: string;
71
+ } & import("react").RefAttributes<any>) => React.ReactNode;
72
+ Content: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
73
+ className?: string;
74
+ } & import("react").RefAttributes<any>) => React.ReactNode;
75
+ List: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
76
+ className?: string;
77
+ } & import("react").RefAttributes<any>) => React.ReactNode;
78
+ ItemGroup: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
79
+ forceMount?: boolean;
80
+ className?: string;
81
+ } & import("react").RefAttributes<any>) => React.ReactNode;
82
+ ItemGroupLabel: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
83
+ className?: string;
84
+ } & import("react").RefAttributes<any>) => React.ReactNode;
85
+ Item: (props: Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "onSelect"> & {
86
+ value: string;
87
+ label?: string;
88
+ disabled?: boolean;
89
+ onSelect?: (value: string) => void;
90
+ className?: string;
91
+ } & import("react").RefAttributes<any>) => React.ReactNode;
92
+ ItemText: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
93
+ className?: string;
94
+ } & import("react").RefAttributes<any>) => React.ReactNode;
95
+ ItemIndicator: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
96
+ className?: string;
97
+ } & import("react").RefAttributes<any>) => React.ReactNode;
98
+ Empty: (props: Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
99
+ className?: string;
100
+ } & import("react").RefAttributes<any>) => React.ReactNode;
101
+ };
102
+ export { ComboboxLabel, ComboboxControl, ComboboxInput, ComboboxTrigger, ComboboxClearTrigger, ComboboxPositioner, ComboboxContent, ComboboxList, ComboboxItemGroup, ComboboxItemGroupLabel, ComboboxItem, ComboboxItemText, ComboboxItemIndicator, ComboboxEmpty, };
103
+ export { ComboboxContext, ComboboxItemContext, ComboboxItemGroupContext } from "./ComboboxContext";
104
+ export * from "./Combobox.types";
@@ -29,6 +29,7 @@ export * from "./clipboard";
29
29
  export * from "./code";
30
30
  export * from "./code-block";
31
31
  export * from "./collapsible";
32
+ export * from "./combobox";
32
33
  export * from "./command-palette";
33
34
  export * from "./confirmation-dialog";
34
35
  export * from "./counter-label";
@@ -104,6 +105,7 @@ export * from "./state-label";
104
105
  export * from "./statistic-card";
105
106
  export * from "./status";
106
107
  export * from "./steps";
108
+ export * from "./swap";
107
109
  export * from "./table-of-contents";
108
110
  export * from "./tabs";
109
111
  export * from "./text";
@@ -115,5 +117,6 @@ export * from "./toggle-switch";
115
117
  export * from "./token";
116
118
  export * from "./tooltip";
117
119
  export * from "./topic-tag";
120
+ export * from "./tour";
118
121
  export * from "./tree-view";
119
122
  export * from "./truncate";
@@ -0,0 +1,10 @@
1
+ import * as React from "react";
2
+ import type { SwapTransition } from "./Swap.types";
3
+ declare const _default: <As extends React.ElementType = "span">(props: import("../../utilities/polymorphic").DistributiveOmit<React.ComponentPropsWithRef<React.ElementType extends As ? "span" : As> & {
4
+ swap?: boolean;
5
+ transition?: SwapTransition;
6
+ className?: string;
7
+ }, "as"> & {
8
+ as?: As | undefined;
9
+ } & React.RefAttributes<any>) => React.ReactNode;
10
+ export default _default;
@@ -0,0 +1,19 @@
1
+ import type * as React from "react";
2
+ import type { PolymorphicProps } from "../../utilities/polymorphic";
3
+ export type SwapIndicatorType = "on" | "off";
4
+ export type SwapTransition = "fade" | "flip" | "rotate" | "scale" | "none";
5
+ export type SwapProps<As extends React.ElementType = "span"> = PolymorphicProps<As, "span", {
6
+ swap?: boolean;
7
+ transition?: SwapTransition;
8
+ className?: string;
9
+ }>;
10
+ type SwapIndicatorOwnProps = {
11
+ type: SwapIndicatorType;
12
+ className?: string;
13
+ };
14
+ export type SwapIndicatorProps<As extends React.ElementType = "span"> = PolymorphicProps<As, "span", SwapIndicatorOwnProps>;
15
+ export type SwapIndicatorElementProps = PolymorphicProps<"span", "span", SwapIndicatorOwnProps>;
16
+ export type SwapContextValue = {
17
+ swap?: boolean;
18
+ };
19
+ export {};
@@ -0,0 +1,2 @@
1
+ import type { SwapContextValue } from "./Swap.types";
2
+ export declare const SwapContext: import("react").Context<SwapContextValue>;
@@ -0,0 +1,8 @@
1
+ import * as React from "react";
2
+ declare const _default: <As extends React.ElementType = "span">(props: import("../../utilities/polymorphic").DistributiveOmit<React.ComponentPropsWithRef<React.ElementType extends As ? "span" : As> & {
3
+ type: import("./Swap.types").SwapIndicatorType;
4
+ className?: string;
5
+ }, "as"> & {
6
+ as?: As | undefined;
7
+ } & React.RefAttributes<any>) => React.ReactNode;
8
+ export default _default;
@@ -0,0 +1,18 @@
1
+ import SwapIndicator from "./SwapIndicator";
2
+ export declare const Swap: (<As extends React.ElementType = "span">(props: import("../../utilities/polymorphic").DistributiveOmit<import("react").ComponentPropsWithRef<import("react").ElementType extends As ? "span" : As> & {
3
+ swap?: boolean;
4
+ transition?: import("./Swap.types").SwapTransition;
5
+ className?: string;
6
+ }, "as"> & {
7
+ as?: As | undefined;
8
+ } & import("react").RefAttributes<any>) => React.ReactNode) & {
9
+ Indicator: <As extends React.ElementType = "span">(props: import("../../utilities/polymorphic").DistributiveOmit<import("react").ComponentPropsWithRef<import("react").ElementType extends As ? "span" : As> & {
10
+ type: import("./Swap.types").SwapIndicatorType;
11
+ className?: string;
12
+ }, "as"> & {
13
+ as?: As | undefined;
14
+ } & import("react").RefAttributes<any>) => React.ReactNode;
15
+ };
16
+ export { SwapIndicator };
17
+ export { SwapContext } from "./SwapContext";
18
+ export * from "./Swap.types";
@@ -0,0 +1,9 @@
1
+ import * as React from "react";
2
+ import type { TourProps } from "./Tour.types";
3
+ export declare const DEFAULT_SPOTLIGHT_OFFSET = 4;
4
+ export declare const DEFAULT_SPOTLIGHT_RADIUS = 8;
5
+ declare function Tour(props: TourProps): React.JSX.Element;
6
+ declare namespace Tour {
7
+ var displayName: string;
8
+ }
9
+ export default Tour;
@@ -0,0 +1,143 @@
1
+ import type * as React from "react";
2
+ import type { ButtonVariant, ButtonVisual } from "../button";
3
+ import type { CaretProps } from "../caret";
4
+ import type { AnchorAlignment, AnchorSide } from "../tooltip/anchoredPosition";
5
+ export type TourStepType = "dialog" | "tooltip" | "floating";
6
+ export type TourFloatingPlacement = "top-start" | "top-end" | "bottom-start" | "bottom-end";
7
+ export type TourActionKind = "next" | "prev" | "dismiss";
8
+ export type TourAction = {
9
+ label: string;
10
+ action: TourActionKind | ((tour: TourApi) => void);
11
+ };
12
+ export type TourStepUpdate = {
13
+ title?: React.ReactNode;
14
+ description?: React.ReactNode;
15
+ actions?: TourAction[];
16
+ };
17
+ export type TourStepEffectArgs = {
18
+ next: () => void;
19
+ prev: () => void;
20
+ goto: (stepId: string) => void;
21
+ dismiss: () => void;
22
+ show: () => void;
23
+ update: (details: TourStepUpdate) => void;
24
+ target: () => HTMLElement | null;
25
+ };
26
+ export type TourStepEffectCleanup = (() => void) | void;
27
+ export type TourStep = {
28
+ id: string;
29
+ type?: TourStepType;
30
+ title?: React.ReactNode;
31
+ description?: React.ReactNode;
32
+ target?: () => HTMLElement | null;
33
+ side?: AnchorSide;
34
+ align?: AnchorAlignment;
35
+ placement?: TourFloatingPlacement;
36
+ actions?: TourAction[];
37
+ backdrop?: boolean;
38
+ arrow?: boolean;
39
+ effect?: (args: TourStepEffectArgs) => TourStepEffectCleanup;
40
+ };
41
+ export type TourStatus = "started" | "completed" | "dismissed";
42
+ export type TourStatusChangeDetails = {
43
+ status: TourStatus;
44
+ };
45
+ export type TourStepChangeDetails = {
46
+ stepId: string | null;
47
+ stepIndex: number;
48
+ count: number;
49
+ };
50
+ export type TourRect = {
51
+ top: number;
52
+ left: number;
53
+ width: number;
54
+ height: number;
55
+ };
56
+ export type TourApi = {
57
+ open: boolean;
58
+ step: TourStep | null;
59
+ stepIndex: number;
60
+ steps: TourStep[];
61
+ start: (stepId?: string) => void;
62
+ next: () => void;
63
+ prev: () => void;
64
+ goto: (stepId: string) => void;
65
+ dismiss: () => void;
66
+ progressText: string;
67
+ progressPercent: number;
68
+ hasNext: boolean;
69
+ hasPrev: boolean;
70
+ };
71
+ export type TourContextValue = TourApi & {
72
+ titleId: string;
73
+ descriptionId: string;
74
+ stepType: TourStepType;
75
+ ready: boolean;
76
+ targetRect: TourRect | null;
77
+ getTarget: () => HTMLElement | null;
78
+ spotlightOffset: number;
79
+ spotlightRadius: number;
80
+ contentRef: React.RefObject<HTMLDivElement | null>;
81
+ };
82
+ export type TourPositionerContextValue = {
83
+ side: AnchorSide;
84
+ align: AnchorAlignment;
85
+ };
86
+ export type TourProps = {
87
+ steps: TourStep[];
88
+ step?: string | null;
89
+ defaultStep?: string | null;
90
+ onStepChange?: (details: TourStepChangeDetails) => void;
91
+ open?: boolean;
92
+ defaultOpen?: boolean;
93
+ onOpenChange?: (open: boolean) => void;
94
+ onStatusChange?: (details: TourStatusChangeDetails) => void;
95
+ keyboardNavigation?: boolean;
96
+ closeOnEscape?: boolean;
97
+ closeOnInteractOutside?: boolean;
98
+ spotlightOffset?: number;
99
+ spotlightRadius?: number;
100
+ id?: string;
101
+ children?: React.ReactNode;
102
+ };
103
+ export type TourBackdropProps = React.ComponentPropsWithoutRef<"div"> & {
104
+ portalContainerName?: string;
105
+ className?: string;
106
+ };
107
+ export type TourSpotlightProps = TourBackdropProps;
108
+ export type TourPositionerProps = React.ComponentPropsWithoutRef<"div"> & {
109
+ side?: AnchorSide;
110
+ align?: AnchorAlignment;
111
+ placement?: TourFloatingPlacement;
112
+ portalContainerName?: string;
113
+ className?: string;
114
+ };
115
+ export type TourContentProps = React.ComponentPropsWithoutRef<"div"> & {
116
+ className?: string;
117
+ };
118
+ export type TourArrowProps = Omit<CaretProps, "location">;
119
+ export type TourCloseTriggerProps = Omit<React.ComponentPropsWithoutRef<"button">, "aria-labelledby"> & {
120
+ icon?: NonNullable<ButtonVisual>;
121
+ className?: string;
122
+ };
123
+ export type TourTitleProps = React.ComponentPropsWithoutRef<"h2"> & {
124
+ className?: string;
125
+ };
126
+ export type TourDescriptionProps = React.ComponentPropsWithoutRef<"div"> & {
127
+ className?: string;
128
+ };
129
+ export type TourProgressTextProps = React.ComponentPropsWithoutRef<"div"> & {
130
+ className?: string;
131
+ };
132
+ export type TourControlProps = React.ComponentPropsWithoutRef<"div"> & {
133
+ className?: string;
134
+ };
135
+ export type TourActionsProps = {
136
+ children: (actions: TourAction[]) => React.ReactNode;
137
+ };
138
+ export type TourActionTriggerProps = Omit<React.ComponentPropsWithoutRef<"button">, "action" | "children"> & {
139
+ action: TourAction;
140
+ variant?: ButtonVariant;
141
+ children?: React.ReactNode;
142
+ className?: string;
143
+ };
@@ -0,0 +1,8 @@
1
+ import * as React from "react";
2
+ declare const _default: (props: Omit<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref">, "children" | "action"> & {
3
+ action: import("./Tour.types").TourAction;
4
+ variant?: import("..").ButtonVariant;
5
+ children?: React.ReactNode;
6
+ className?: string;
7
+ } & React.RefAttributes<any>) => React.ReactNode;
8
+ export default _default;