@nimbus-ds/components 5.31.0 → 5.32.1
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.
- package/CHANGELOG.md +12 -0
- package/dist/Box/index.d.ts +5 -1
- package/dist/CHANGELOG.md +12 -0
- package/dist/Icon/index.d.ts +1 -1
- package/dist/IconButton/index.d.ts +1 -1
- package/dist/ScrollPane/index.d.ts +5 -1
- package/dist/SegmentedControl/index.d.ts +5 -1
- package/dist/SplitButton/index.d.ts +1013 -0
- package/dist/SplitButton/index.js +2 -0
- package/dist/Stepper/index.d.ts +5 -1
- package/dist/Text/index.d.ts +4 -4
- package/dist/Tooltip/index.js +1 -1
- package/dist/components-props.json +1 -1
- package/dist/index.d.ts +98 -6
- package/dist/index.js +1 -1
- package/package.json +5 -1
|
@@ -0,0 +1,1013 @@
|
|
|
1
|
+
// Generated by dts-bundle-generator v7.2.0
|
|
2
|
+
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { ButtonHTMLAttributes, ComponentPropsWithRef, HTMLAttributes, ReactNode } from 'react';
|
|
5
|
+
|
|
6
|
+
export type Merge<P1 = {}, P2 = {}> = Omit<P1, keyof P2> & P2;
|
|
7
|
+
export type ForwardRefExoticComponent<E, OwnProps> = React.ForwardRefExoticComponent<Merge<E extends React.ElementType ? React.ComponentPropsWithRef<E> : never, OwnProps & {
|
|
8
|
+
as?: E;
|
|
9
|
+
}>>;
|
|
10
|
+
export interface PolymorphicForwardRefComponent<IntrinsicElementString, OwnProps = {}
|
|
11
|
+
/**
|
|
12
|
+
* Extends original type to ensure built in React types play nice
|
|
13
|
+
* with polymorphic components still e.g. `React.ElementRef` etc.
|
|
14
|
+
*/
|
|
15
|
+
> extends ForwardRefExoticComponent<IntrinsicElementString, OwnProps> {
|
|
16
|
+
/**
|
|
17
|
+
* When `as` prop is passed, use this overload.
|
|
18
|
+
* Merges original own props (without DOM props) and the inferred props
|
|
19
|
+
* from `as` element with the own props taking precendence.
|
|
20
|
+
*
|
|
21
|
+
* We explicitly avoid `React.ElementType` and manually narrow the prop types
|
|
22
|
+
* so that events are typed when using JSX.IntrinsicElements.
|
|
23
|
+
*/
|
|
24
|
+
<As = IntrinsicElementString>(props: As extends "" ? {
|
|
25
|
+
as: keyof JSX.IntrinsicElements;
|
|
26
|
+
} : As extends React.ComponentType<infer P> ? Merge<P, OwnProps & {
|
|
27
|
+
as: As;
|
|
28
|
+
}> : As extends keyof JSX.IntrinsicElements ? Merge<JSX.IntrinsicElements[As], OwnProps & {
|
|
29
|
+
as: As;
|
|
30
|
+
}> : never): React.ReactElement | null;
|
|
31
|
+
}
|
|
32
|
+
export interface Conditions<T> {
|
|
33
|
+
xs?: T;
|
|
34
|
+
md?: T;
|
|
35
|
+
lg?: T;
|
|
36
|
+
xl?: T;
|
|
37
|
+
}
|
|
38
|
+
export type BorderStyle = "solid" | "none" | "hidden" | "dashed" | "dotted";
|
|
39
|
+
export type BoxSizing = "border-box" | "content-box";
|
|
40
|
+
export type Cursor = "auto" | "pointer" | "not-allowed" | "grab" | "inherit";
|
|
41
|
+
export type Display = "block" | "flex" | "inline-flex" | "grid" | "inline-grid" | "none";
|
|
42
|
+
export type FlexWrap = "nowrap" | "wrap" | "wrap-reverse";
|
|
43
|
+
export type FlexDirection = "row" | "row-reverse" | "column" | "column-reverse";
|
|
44
|
+
export type JustifyContent = "flex-start" | "flex-end" | "center" | "space-between" | "space-around" | "space-evenly";
|
|
45
|
+
export type AlignItems = "stretch" | "flex-start" | "flex-end" | "center" | "baseline";
|
|
46
|
+
export type AlignSelf = "auto" | "flex-start" | "flex-end" | "center" | "baseline" | "stretch";
|
|
47
|
+
export type TextAlign = "left" | "right" | "center" | "justify";
|
|
48
|
+
export type TextDecoration = "none" | "underline" | "line-through";
|
|
49
|
+
export type Position = "absolute" | "fixed" | "relative" | "static" | "sticky";
|
|
50
|
+
export type Overflow = "visible" | "hidden" | "scroll" | "auto";
|
|
51
|
+
export type PointerEvents = "auto" | "none" | "visiblePainted" | "visibleFill" | "visibleStroke" | "visible" | "painted" | "fill" | "stroke" | "all" | "inherit";
|
|
52
|
+
export type TransitionTiming = "ease" | "ease-in" | "ease-out" | "ease-in-out" | "linear" | "step-start" | "step-end";
|
|
53
|
+
declare const propertiesBox: {
|
|
54
|
+
gap: {
|
|
55
|
+
none: string;
|
|
56
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
57
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
58
|
+
"1-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
59
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
60
|
+
"2-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
61
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
62
|
+
"3-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
63
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
64
|
+
"4-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
65
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
66
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
67
|
+
"7": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
68
|
+
"8": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
69
|
+
"9": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
70
|
+
"10": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
71
|
+
"11": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
72
|
+
"12": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
73
|
+
"14": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
74
|
+
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
75
|
+
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
76
|
+
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
77
|
+
};
|
|
78
|
+
gridGap: {
|
|
79
|
+
none: string;
|
|
80
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
81
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
82
|
+
"1-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
83
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
84
|
+
"2-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
85
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
86
|
+
"3-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
87
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
88
|
+
"4-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
89
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
90
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
91
|
+
"7": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
92
|
+
"8": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
93
|
+
"9": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
94
|
+
"10": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
95
|
+
"11": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
96
|
+
"12": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
97
|
+
"14": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
98
|
+
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
99
|
+
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
100
|
+
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
101
|
+
};
|
|
102
|
+
display: Display[];
|
|
103
|
+
flexDirection: FlexDirection[];
|
|
104
|
+
flexWrap: FlexWrap[];
|
|
105
|
+
justifyContent: JustifyContent[];
|
|
106
|
+
alignItems: AlignItems[];
|
|
107
|
+
alignSelf: AlignSelf[];
|
|
108
|
+
pointerEvents: PointerEvents[];
|
|
109
|
+
backgroundColor: {
|
|
110
|
+
"primary-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
111
|
+
"primary-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
112
|
+
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
113
|
+
"primary-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
114
|
+
"success-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
115
|
+
"success-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
116
|
+
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
117
|
+
"success-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
118
|
+
"warning-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
119
|
+
"warning-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
120
|
+
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
121
|
+
"warning-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
122
|
+
"danger-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`; /**
|
|
123
|
+
* The min height property specifies the height of a box's content area.
|
|
124
|
+
*/
|
|
125
|
+
"danger-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
126
|
+
"danger-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
127
|
+
"danger-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
128
|
+
"neutral-background": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
129
|
+
"neutral-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
130
|
+
"neutral-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
131
|
+
"neutral-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
132
|
+
"neutral-surfaceDisabled": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
133
|
+
"neutral-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
134
|
+
"neutral-textHigh": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
135
|
+
"ai-generative-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
136
|
+
"ai-generative-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
137
|
+
transparent: string;
|
|
138
|
+
};
|
|
139
|
+
background: {
|
|
140
|
+
"ai-generative-interactive-border": string;
|
|
141
|
+
"ai-generative-interactive": string;
|
|
142
|
+
transparent: string;
|
|
143
|
+
};
|
|
144
|
+
color: {
|
|
145
|
+
currentColor: string;
|
|
146
|
+
"primary-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
147
|
+
"primary-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
148
|
+
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
149
|
+
"primary-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
150
|
+
"success-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
151
|
+
"success-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
152
|
+
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
153
|
+
"success-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
154
|
+
"warning-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
155
|
+
"warning-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
156
|
+
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
157
|
+
"warning-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
158
|
+
"danger-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`; /**
|
|
159
|
+
* The min height property specifies the height of a box's content area.
|
|
160
|
+
*/
|
|
161
|
+
"danger-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
162
|
+
"danger-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
163
|
+
"danger-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
164
|
+
"neutral-background": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
165
|
+
"neutral-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
166
|
+
"neutral-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
167
|
+
"neutral-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
168
|
+
"neutral-surfaceDisabled": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
169
|
+
"neutral-textLow": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
170
|
+
"neutral-textHigh": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
171
|
+
"ai-generative-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
172
|
+
"ai-generative-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
173
|
+
transparent: string;
|
|
174
|
+
};
|
|
175
|
+
borderColor: {
|
|
176
|
+
"primary-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
177
|
+
"primary-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
178
|
+
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
179
|
+
"success-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
180
|
+
"success-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
181
|
+
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
182
|
+
"warning-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
183
|
+
"warning-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
184
|
+
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
185
|
+
"danger-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
186
|
+
"danger-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
187
|
+
"danger-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
188
|
+
"neutral-interactive": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
189
|
+
"neutral-surface": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
190
|
+
"neutral-surfaceDisabled": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
191
|
+
"neutral-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
192
|
+
transparent: string;
|
|
193
|
+
};
|
|
194
|
+
borderRadius: {
|
|
195
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
196
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
197
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
198
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
199
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
200
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
201
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
202
|
+
full: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
203
|
+
base: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
204
|
+
half: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
205
|
+
none: string;
|
|
206
|
+
};
|
|
207
|
+
borderWidth: {
|
|
208
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
209
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
210
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
211
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
212
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
213
|
+
none: string;
|
|
214
|
+
};
|
|
215
|
+
borderStyle: BorderStyle[];
|
|
216
|
+
boxSizing: BoxSizing[];
|
|
217
|
+
cursor: Cursor[];
|
|
218
|
+
spacing: {
|
|
219
|
+
none: string;
|
|
220
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
221
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
222
|
+
"1-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
223
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
224
|
+
"2-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
225
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
226
|
+
"3-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
227
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
228
|
+
"4-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
229
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
230
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
231
|
+
"7": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
232
|
+
"8": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
233
|
+
"9": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
234
|
+
"10": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
235
|
+
"11": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
236
|
+
"12": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
237
|
+
"14": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
238
|
+
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
239
|
+
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
240
|
+
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
241
|
+
};
|
|
242
|
+
margin: {
|
|
243
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
244
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
245
|
+
"1-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
246
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
247
|
+
"2-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
248
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
249
|
+
"3-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
250
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
251
|
+
"4-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
252
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
253
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
254
|
+
"7": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
255
|
+
"8": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
256
|
+
"9": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
257
|
+
"10": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
258
|
+
"11": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
259
|
+
"12": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
260
|
+
"14": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
261
|
+
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
262
|
+
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
263
|
+
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
264
|
+
auto: string;
|
|
265
|
+
none: string;
|
|
266
|
+
};
|
|
267
|
+
position: Position[];
|
|
268
|
+
overflow: Overflow[];
|
|
269
|
+
overflowX: Overflow[];
|
|
270
|
+
overflowY: Overflow[];
|
|
271
|
+
boxShadow: {
|
|
272
|
+
"0": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
273
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
274
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
275
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
276
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
277
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
278
|
+
focusRing: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
279
|
+
aiFocus: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
280
|
+
};
|
|
281
|
+
transitionDuration: {
|
|
282
|
+
base: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
283
|
+
fast: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
284
|
+
slow: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
285
|
+
slower: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
286
|
+
};
|
|
287
|
+
transitionTimingFunction: TransitionTiming[];
|
|
288
|
+
textDecoration: TextDecoration[];
|
|
289
|
+
zIndex: {
|
|
290
|
+
"100": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
291
|
+
"200": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
292
|
+
"300": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
293
|
+
"400": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
294
|
+
"500": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
295
|
+
"600": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
296
|
+
"700": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
297
|
+
"800": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
298
|
+
"900": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
299
|
+
};
|
|
300
|
+
textAlign: TextAlign[];
|
|
301
|
+
fontWeight: {
|
|
302
|
+
regular: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
303
|
+
medium: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
304
|
+
bold: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
305
|
+
};
|
|
306
|
+
fontSize: {
|
|
307
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
308
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
309
|
+
"1-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
310
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
311
|
+
"2-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
312
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
313
|
+
"3-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
314
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
315
|
+
"4-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
316
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
317
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
318
|
+
"7": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
319
|
+
"8": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
320
|
+
"9": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
321
|
+
"10": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
322
|
+
"11": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
323
|
+
"12": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
324
|
+
"14": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
325
|
+
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
326
|
+
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
327
|
+
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
328
|
+
h1: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
329
|
+
h2: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`; /**
|
|
330
|
+
* This defines the ability for a flex item to shrink if necessary.
|
|
331
|
+
*/
|
|
332
|
+
h3: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
333
|
+
h4: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
334
|
+
h5: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
335
|
+
h6: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
336
|
+
};
|
|
337
|
+
lineHeight: {
|
|
338
|
+
"0-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
339
|
+
"1": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
340
|
+
"1-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
341
|
+
"2": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
342
|
+
"2-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
343
|
+
"3": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
344
|
+
"3-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
345
|
+
"4": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
346
|
+
"4-5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
347
|
+
"5": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
348
|
+
"6": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
349
|
+
"7": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
350
|
+
"8": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
351
|
+
"9": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
352
|
+
"10": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
353
|
+
"11": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
354
|
+
"12": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
355
|
+
"14": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
356
|
+
"16": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
357
|
+
"18": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
358
|
+
"20": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
359
|
+
h1: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
360
|
+
h2: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
361
|
+
h3: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
362
|
+
h4: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
363
|
+
h5: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
364
|
+
h6: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
365
|
+
}; /**
|
|
366
|
+
* The paddingBottom property sets the height of the padding area on the bottom of an box.
|
|
367
|
+
*/
|
|
368
|
+
};
|
|
369
|
+
export type BoxBorderColorProperties = keyof typeof propertiesBox.borderColor;
|
|
370
|
+
export type BoxBorderRadiusProperties = keyof typeof propertiesBox.borderRadius;
|
|
371
|
+
export type BoxBorderWidthProperties = keyof typeof propertiesBox.borderWidth;
|
|
372
|
+
export type BoxBackgroundColorProperties = keyof typeof propertiesBox.backgroundColor;
|
|
373
|
+
export type BoxColorProperties = keyof typeof propertiesBox.color;
|
|
374
|
+
export type BoxShadowProperties = keyof typeof propertiesBox.boxShadow;
|
|
375
|
+
export type BoxSpacingProperties = keyof typeof propertiesBox.spacing;
|
|
376
|
+
export type BoxMarginProperties = keyof typeof propertiesBox.margin;
|
|
377
|
+
export type BoxGapProperties = keyof typeof propertiesBox.gap;
|
|
378
|
+
export type BoxGridGapProperties = keyof typeof propertiesBox.gridGap;
|
|
379
|
+
export type BoxZIndexProperties = keyof typeof propertiesBox.zIndex;
|
|
380
|
+
export type BoxTransitionDurationProperties = keyof typeof propertiesBox.transitionDuration;
|
|
381
|
+
export type BoxFontSizeProperties = keyof typeof propertiesBox.fontSize;
|
|
382
|
+
export type BoxFontWeightProperties = keyof typeof propertiesBox.fontWeight;
|
|
383
|
+
export type BoxLineHeightProperties = keyof typeof propertiesBox.lineHeight;
|
|
384
|
+
export type BoxBackgroundProperties = keyof typeof propertiesBox.background;
|
|
385
|
+
export interface BoxConditions<T> extends Conditions<T> {
|
|
386
|
+
focus?: T;
|
|
387
|
+
focusWithin?: T;
|
|
388
|
+
active?: T;
|
|
389
|
+
hover?: T;
|
|
390
|
+
disabled?: T;
|
|
391
|
+
}
|
|
392
|
+
export interface BoxSprinkle {
|
|
393
|
+
/**
|
|
394
|
+
* The width property specifies the width of a box's content area.
|
|
395
|
+
*/
|
|
396
|
+
width?: string | BoxConditions<string>;
|
|
397
|
+
/**
|
|
398
|
+
* The height property specifies the height of a box's content area.
|
|
399
|
+
*/
|
|
400
|
+
height?: string | BoxConditions<string>;
|
|
401
|
+
/**
|
|
402
|
+
* The max width property specifies the width of a box's content area.
|
|
403
|
+
*/
|
|
404
|
+
maxWidth?: string | BoxConditions<string>;
|
|
405
|
+
/**
|
|
406
|
+
* The max height property specifies the height of a box's content area.
|
|
407
|
+
*/
|
|
408
|
+
maxHeight?: string | BoxConditions<string>;
|
|
409
|
+
/**
|
|
410
|
+
* The min width property specifies the width of a box's content area.
|
|
411
|
+
*/
|
|
412
|
+
minWidth?: string | BoxConditions<string>;
|
|
413
|
+
/**
|
|
414
|
+
* The min height property specifies the height of a box's content area.
|
|
415
|
+
*/
|
|
416
|
+
minHeight?: string | BoxConditions<string>;
|
|
417
|
+
/**
|
|
418
|
+
* The bottom property participates in setting the vertical position of a positioned box.
|
|
419
|
+
*/
|
|
420
|
+
bottom?: string | BoxConditions<string>;
|
|
421
|
+
/**
|
|
422
|
+
* The left property participates in specifying the horizontal position of a positioned box.
|
|
423
|
+
*/
|
|
424
|
+
left?: string | BoxConditions<string>;
|
|
425
|
+
/**
|
|
426
|
+
* The right property participates in specifying the horizontal position of a positioned box.
|
|
427
|
+
*/
|
|
428
|
+
right?: string | BoxConditions<string>;
|
|
429
|
+
/**
|
|
430
|
+
* The top property participates in setting the vertical position of a positioned box.
|
|
431
|
+
*/
|
|
432
|
+
top?: string | BoxConditions<string>;
|
|
433
|
+
/**
|
|
434
|
+
* This is the shorthand for flexGrow, flexShrink and flexBasis combined.
|
|
435
|
+
*/
|
|
436
|
+
flex?: string | BoxConditions<string>;
|
|
437
|
+
/**
|
|
438
|
+
* This defines the ability for a flex item to shrink if necessary.
|
|
439
|
+
*/
|
|
440
|
+
flexShrink?: string | BoxConditions<string>;
|
|
441
|
+
/**
|
|
442
|
+
* This defines the ability for a flex item to grow if necessary.
|
|
443
|
+
*/
|
|
444
|
+
flexGrow?: string | BoxConditions<string>;
|
|
445
|
+
/**
|
|
446
|
+
* The flexWrap property sets whether flex items are forced onto one line or can wrap onto multiple lines.
|
|
447
|
+
*/
|
|
448
|
+
flexWrap?: FlexWrap | BoxConditions<FlexWrap>;
|
|
449
|
+
/**
|
|
450
|
+
* The order property controls the order in which they appear in a flex container.
|
|
451
|
+
*/
|
|
452
|
+
order?: string | BoxConditions<string>;
|
|
453
|
+
/**
|
|
454
|
+
* The gridTemplateColumns property defines the line names and track sizing functions of the grid columns.
|
|
455
|
+
*/
|
|
456
|
+
gridTemplateColumns?: string | BoxConditions<string>;
|
|
457
|
+
/**
|
|
458
|
+
* The gridTemplateAreas property specifies named grid areas, establishing the cells in the grid and assigning them names.
|
|
459
|
+
*/
|
|
460
|
+
gridTemplateAreas?: string | BoxConditions<string>;
|
|
461
|
+
/**
|
|
462
|
+
* The gridTemplateRows property defines the line names and track sizing functions of the grid rows.
|
|
463
|
+
*/
|
|
464
|
+
gridTemplateRows?: string | BoxConditions<string>;
|
|
465
|
+
/**
|
|
466
|
+
* The gridArea shorthand property specifies a grid item's size and location within a grid by contributing a line,
|
|
467
|
+
* a span, or nothing (automatic) to its grid placement, thereby specifying the edges of its grid area.
|
|
468
|
+
*/
|
|
469
|
+
gridArea?: string | BoxConditions<string>;
|
|
470
|
+
/**
|
|
471
|
+
* The display property sets whether an box is treated as a block or inline element and the layout used for its children,
|
|
472
|
+
* such as grid or flex.
|
|
473
|
+
*/
|
|
474
|
+
display?: Display | BoxConditions<Display>;
|
|
475
|
+
/**
|
|
476
|
+
* The justifyContent property defines how the browser distributes space between and around content items along
|
|
477
|
+
* the main-axis of a flex container, and the inline axis of a grid container.
|
|
478
|
+
*/
|
|
479
|
+
justifyContent?: JustifyContent | BoxConditions<JustifyContent>;
|
|
480
|
+
/**
|
|
481
|
+
* The flexDirection property sets how flex items are placed in the flex container defining the main axis and the direction.
|
|
482
|
+
*/
|
|
483
|
+
flexDirection?: FlexDirection | BoxConditions<FlexDirection>;
|
|
484
|
+
/**
|
|
485
|
+
* The alignItems property sets the align-self value on all direct children as a group. In Flexbox, it controls the alignment of items on the Cross Axis.
|
|
486
|
+
* In Grid Layout, it controls the alignment of items on the Block Axis within their grid area.
|
|
487
|
+
*/
|
|
488
|
+
alignItems?: AlignItems | BoxConditions<AlignItems>;
|
|
489
|
+
/**
|
|
490
|
+
* The alignSelf property overrides a grid or flex item's align-items value. In Grid, it aligns the item inside the grid area.
|
|
491
|
+
* In Flexbox, it aligns the item on the cross axis.
|
|
492
|
+
*/
|
|
493
|
+
alignSelf?: AlignSelf | BoxConditions<AlignSelf>;
|
|
494
|
+
/**
|
|
495
|
+
* The gap property sets the gaps between rows and columns. It is a shorthand for rowGap and columnGap.
|
|
496
|
+
*/
|
|
497
|
+
gap?: BoxGapProperties | BoxConditions<BoxGapProperties>;
|
|
498
|
+
/**
|
|
499
|
+
* The gridGap property sets the gaps between rows and columns. It is a shorthand for rowGap and columnGap.
|
|
500
|
+
*/
|
|
501
|
+
gridGap?: BoxGridGapProperties | BoxConditions<BoxGridGapProperties>;
|
|
502
|
+
/**
|
|
503
|
+
* The pointerEvents property sets under what circumstances (if any) a particular graphic element can become the target of pointer events.
|
|
504
|
+
*/
|
|
505
|
+
pointerEvents?: PointerEvents | BoxConditions<PointerEvents>;
|
|
506
|
+
/**
|
|
507
|
+
* The position property sets how an box is positioned in a document.
|
|
508
|
+
*/
|
|
509
|
+
position?: Position | BoxConditions<Position>;
|
|
510
|
+
/**
|
|
511
|
+
* The overflow shorthand property sets the desired behavior for an box's overflow.
|
|
512
|
+
*/
|
|
513
|
+
overflow?: Overflow | BoxConditions<Overflow>;
|
|
514
|
+
/**
|
|
515
|
+
* The overflow-x property sets what shows when content overflows a block-level box's left and right edges.
|
|
516
|
+
*/
|
|
517
|
+
overflowX?: Overflow | BoxConditions<Overflow>;
|
|
518
|
+
/**
|
|
519
|
+
* The overflow-y property sets what shows when content overflows a block-level box's top and bottom edges.
|
|
520
|
+
*/
|
|
521
|
+
overflowY?: Overflow | BoxConditions<Overflow>;
|
|
522
|
+
/**
|
|
523
|
+
* The cursor property sets the mouse cursor, if any, to show when the mouse pointer is over an box.
|
|
524
|
+
*/
|
|
525
|
+
cursor?: Cursor | BoxConditions<Cursor>;
|
|
526
|
+
/**
|
|
527
|
+
* The backgroundColor property sets the background color of the box.
|
|
528
|
+
* @default neutral-background
|
|
529
|
+
* @examples ["neutral-interactive", { xs: "neutral-surface", md: "neutral-interactive" }]
|
|
530
|
+
*/
|
|
531
|
+
backgroundColor?: BoxBackgroundColorProperties | BoxConditions<BoxBackgroundColorProperties>;
|
|
532
|
+
/**
|
|
533
|
+
* The color property is used to set the color of the box.
|
|
534
|
+
*/
|
|
535
|
+
color?: BoxColorProperties | BoxConditions<BoxColorProperties>;
|
|
536
|
+
/**
|
|
537
|
+
* The borderRadius property rounds the corners of an box's outer border edge.
|
|
538
|
+
*/
|
|
539
|
+
borderRadius?: BoxBorderRadiusProperties | BoxConditions<BoxBorderRadiusProperties>;
|
|
540
|
+
/**
|
|
541
|
+
* The borderWidth property sets the width of an box's border.
|
|
542
|
+
*/
|
|
543
|
+
borderWidth?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
544
|
+
/**
|
|
545
|
+
* The borderTopWidth property defines the width of the border at the top of a box.
|
|
546
|
+
*/
|
|
547
|
+
borderTopWidth?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
548
|
+
/**
|
|
549
|
+
* The borderBottomWidth property defines the width of the border at the bottom of a box.
|
|
550
|
+
*/
|
|
551
|
+
borderBottomWidth?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
552
|
+
/**
|
|
553
|
+
* The borderLeftWidth property defines the width of the border at the left of a box.
|
|
554
|
+
*/
|
|
555
|
+
borderLeftWidth?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
556
|
+
/**
|
|
557
|
+
* The borderRightWidth property defines the width of the border at the right of a box.
|
|
558
|
+
*/
|
|
559
|
+
borderRightWidth?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
560
|
+
/**
|
|
561
|
+
* The borderWidthX shorthand property defines the width of the element's border on the left and right.
|
|
562
|
+
*/
|
|
563
|
+
borderWidthX?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
564
|
+
/**
|
|
565
|
+
* The borderWidthY shorthand property defines the width of the element's border on the top and bottom.
|
|
566
|
+
*/
|
|
567
|
+
borderWidthY?: BoxBorderWidthProperties | BoxConditions<BoxBorderWidthProperties>;
|
|
568
|
+
/**
|
|
569
|
+
* The borderColor property sets the color of the box's four borders.
|
|
570
|
+
*/
|
|
571
|
+
borderColor?: BoxBorderColorProperties | BoxConditions<BoxBorderColorProperties>;
|
|
572
|
+
/**
|
|
573
|
+
* borderStyle property sets the line style for all four sides of an box's border.
|
|
574
|
+
*/
|
|
575
|
+
borderStyle?: BorderStyle | BoxConditions<BorderStyle>;
|
|
576
|
+
/**
|
|
577
|
+
* The boxSizing property sets how the total width and height of an box is calculated.
|
|
578
|
+
* @default border-box
|
|
579
|
+
*/
|
|
580
|
+
boxSizing?: BoxSizing | BoxConditions<BoxSizing>;
|
|
581
|
+
/**
|
|
582
|
+
* The boxShadow property adds shadow effects around an box's frame.
|
|
583
|
+
*/
|
|
584
|
+
boxShadow?: BoxShadowProperties | BoxConditions<BoxShadowProperties>;
|
|
585
|
+
/**
|
|
586
|
+
* The padding properties are used to generate space around an box's content area.
|
|
587
|
+
*/
|
|
588
|
+
padding?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
589
|
+
/**
|
|
590
|
+
* The paddingTop property sets the height of the padding area on the top of an box.
|
|
591
|
+
*/
|
|
592
|
+
paddingTop?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
593
|
+
/**
|
|
594
|
+
* The paddingBottom property sets the height of the padding area on the bottom of an box.
|
|
595
|
+
*/
|
|
596
|
+
paddingBottom?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
597
|
+
/**
|
|
598
|
+
* The paddingLeft property sets the width of the padding area to the left of an box.
|
|
599
|
+
*/
|
|
600
|
+
paddingLeft?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
601
|
+
/**
|
|
602
|
+
* The paddingLeft property sets the width of the padding area to the right of an box.
|
|
603
|
+
*/
|
|
604
|
+
paddingRight?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
605
|
+
/**
|
|
606
|
+
* The margin shorthand property sets the margin area on all four sides of an box.
|
|
607
|
+
*/
|
|
608
|
+
margin?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
609
|
+
/**
|
|
610
|
+
* The marginTop property sets the margin area on the top of an box.
|
|
611
|
+
*/
|
|
612
|
+
marginTop?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
613
|
+
/**
|
|
614
|
+
* The marginBottom property sets the margin area on the bottom of an box.
|
|
615
|
+
*/
|
|
616
|
+
marginBottom?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
617
|
+
/**
|
|
618
|
+
* The marginLeft property sets the margin area on the left side of an box.
|
|
619
|
+
*/
|
|
620
|
+
marginLeft?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
621
|
+
/**
|
|
622
|
+
* The marginRight property sets the margin area on the right side of an box.
|
|
623
|
+
*/
|
|
624
|
+
marginRight?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
625
|
+
/**
|
|
626
|
+
* The transitionTimingFunction property sets how intermediate values are calculated for CSS properties being affected by a transition effect.
|
|
627
|
+
*/
|
|
628
|
+
transitionTimingFunction?: TransitionTiming | BoxConditions<TransitionTiming>;
|
|
629
|
+
/**
|
|
630
|
+
* The transitionProperty property sets the CSS properties to which a transition effect should be applied.
|
|
631
|
+
*/
|
|
632
|
+
transitionProperty?: string | BoxConditions<string>;
|
|
633
|
+
/**
|
|
634
|
+
* The transitionDelay property specifies the duration to wait before starting a property's transition effect when its value changes.
|
|
635
|
+
*/
|
|
636
|
+
transitionDelay?: string | BoxConditions<string>;
|
|
637
|
+
/**
|
|
638
|
+
* The transitionDuration property sets the length of time a transition animation should take to complete. By default, the value is 0s, meaning that no animation will occur.
|
|
639
|
+
*/
|
|
640
|
+
transitionDuration?: BoxTransitionDurationProperties | BoxConditions<BoxTransitionDurationProperties>;
|
|
641
|
+
/**
|
|
642
|
+
* The zIndex property specifies the stack order of the box.
|
|
643
|
+
*/
|
|
644
|
+
zIndex?: BoxZIndexProperties | BoxConditions<BoxZIndexProperties>;
|
|
645
|
+
/**
|
|
646
|
+
* The background property sets the background of the box.
|
|
647
|
+
*/
|
|
648
|
+
background?: BoxBackgroundProperties | BoxConditions<BoxBackgroundProperties>;
|
|
649
|
+
/**
|
|
650
|
+
* The backgroundImage property sets one or more background images on an element.
|
|
651
|
+
*/
|
|
652
|
+
backgroundImage?: string | BoxConditions<string>;
|
|
653
|
+
/**
|
|
654
|
+
* The backgroundPosition property sets the initial position for each background image.
|
|
655
|
+
* The position is relative to the position layer set by background-origin.
|
|
656
|
+
*/
|
|
657
|
+
backgroundPosition?: string | BoxConditions<string>;
|
|
658
|
+
/**
|
|
659
|
+
* The backgroundBlendMode property sets how an element's background images should blend with each
|
|
660
|
+
* other and with the element's background color.
|
|
661
|
+
*/
|
|
662
|
+
backgroundBlendMode?: string | BoxConditions<string>;
|
|
663
|
+
/**
|
|
664
|
+
* The backgroundRepeat property sets how background images are repeated. A background image can be repeated along the horizontal and vertical axes, or not repeated at all.
|
|
665
|
+
*/
|
|
666
|
+
backgroundRepeat?: string | BoxConditions<string>;
|
|
667
|
+
/**
|
|
668
|
+
* The textDecoration shorthand property sets the appearance of decorative lines on text.
|
|
669
|
+
*/
|
|
670
|
+
textDecoration?: TextDecoration | BoxConditions<TextDecoration>;
|
|
671
|
+
/**
|
|
672
|
+
* The backgroundSize property sets the size of the element's background image. The image can be left to its natural size, stretched, or constrained to fit the available space.
|
|
673
|
+
*/
|
|
674
|
+
backgroundSize?: string | BoxConditions<string>;
|
|
675
|
+
/**
|
|
676
|
+
* The p shorthand property sets the margin area on all four sides of an box.
|
|
677
|
+
*/
|
|
678
|
+
p?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
679
|
+
/**
|
|
680
|
+
* The pl shorthand property sets the width of the padding area to the left of an box.
|
|
681
|
+
*/
|
|
682
|
+
pl?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
683
|
+
/**
|
|
684
|
+
* The pl shorthand property sets the width of the padding area to the right of an box.
|
|
685
|
+
*/
|
|
686
|
+
pr?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
687
|
+
/**
|
|
688
|
+
* The pt shorthand property sets the height of the padding area on the top of an box.
|
|
689
|
+
*/
|
|
690
|
+
pt?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
691
|
+
/**
|
|
692
|
+
* The pb shorthand property sets the height of the padding area on the botton of an box.
|
|
693
|
+
*/
|
|
694
|
+
pb?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
695
|
+
/**
|
|
696
|
+
* The px shorthand property defines the width of the left and right padding area of a box.
|
|
697
|
+
*/
|
|
698
|
+
px?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
699
|
+
/**
|
|
700
|
+
* The py pt shorthand property sets the height of the padding area at the top and bottom of a box.
|
|
701
|
+
*/
|
|
702
|
+
py?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
703
|
+
/**
|
|
704
|
+
* The paddingX shorthand property defines the width of the left and right padding area of a box.
|
|
705
|
+
*/
|
|
706
|
+
paddingX?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
707
|
+
/**
|
|
708
|
+
* The paddingY pt shorthand property sets the height of the padding area at the top and bottom of a box.
|
|
709
|
+
*/
|
|
710
|
+
paddingY?: BoxSpacingProperties | BoxConditions<BoxSpacingProperties>;
|
|
711
|
+
/**
|
|
712
|
+
* The m shorthand property sets the margin area on all four sides of an box.
|
|
713
|
+
*/
|
|
714
|
+
m?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
715
|
+
/**
|
|
716
|
+
* The mr property sets the margin area on the right side of an box.
|
|
717
|
+
*/
|
|
718
|
+
mr?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
719
|
+
/**
|
|
720
|
+
* The ml property sets the margin area on the left side of an box.
|
|
721
|
+
*/
|
|
722
|
+
ml?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
723
|
+
/**
|
|
724
|
+
* The mt property sets the margin area on the top of an box.
|
|
725
|
+
*/
|
|
726
|
+
mt?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
727
|
+
/**
|
|
728
|
+
* The marginBottom property sets the margin area on the bottom of an box.
|
|
729
|
+
*/
|
|
730
|
+
mb?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
731
|
+
/**
|
|
732
|
+
* The mx property defines the margin area on the left and right side of a box.
|
|
733
|
+
*/
|
|
734
|
+
mx?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
735
|
+
/**
|
|
736
|
+
* The my property defines the margin area on the top and bottom of a box
|
|
737
|
+
*/
|
|
738
|
+
my?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
739
|
+
/**
|
|
740
|
+
* The marginX property defines the margin area on the left and right side of a box.
|
|
741
|
+
*/
|
|
742
|
+
marginX?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
743
|
+
/**
|
|
744
|
+
* The marginY property defines the margin area on the top and bottom of a box
|
|
745
|
+
*/
|
|
746
|
+
marginY?: BoxMarginProperties | BoxConditions<BoxMarginProperties>;
|
|
747
|
+
/**
|
|
748
|
+
* The fontSize property sets the size of the box.
|
|
749
|
+
* @default base
|
|
750
|
+
*/
|
|
751
|
+
fontSize?: BoxFontSizeProperties | BoxConditions<BoxFontSizeProperties>;
|
|
752
|
+
/**
|
|
753
|
+
* The fontWeight property sets how thick or thin characters in box should be displayed.
|
|
754
|
+
* @default regular
|
|
755
|
+
*/
|
|
756
|
+
fontWeight?: BoxFontWeightProperties | BoxConditions<BoxFontWeightProperties>;
|
|
757
|
+
/**
|
|
758
|
+
* The lineHeight property specifies the line height of the box.
|
|
759
|
+
* @default base
|
|
760
|
+
*/
|
|
761
|
+
lineHeight?: BoxLineHeightProperties | BoxConditions<BoxLineHeightProperties>;
|
|
762
|
+
/**
|
|
763
|
+
* The textAlign property specifies the horizontal alignment of box.
|
|
764
|
+
* @default left
|
|
765
|
+
*/
|
|
766
|
+
textAlign?: TextAlign | BoxConditions<TextAlign>;
|
|
767
|
+
}
|
|
768
|
+
declare const propertiesPopover: {
|
|
769
|
+
backgroundColor: {
|
|
770
|
+
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
771
|
+
"primary-interactiveHover": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
772
|
+
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
773
|
+
"danger-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
774
|
+
"neutral-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
775
|
+
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
776
|
+
"neutral-background": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
777
|
+
};
|
|
778
|
+
color: {
|
|
779
|
+
"primary-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
780
|
+
"primary-interactiveHover": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
781
|
+
"success-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
782
|
+
"danger-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
783
|
+
"neutral-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
784
|
+
"warning-surfaceHighlight": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
785
|
+
"neutral-background": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
786
|
+
};
|
|
787
|
+
padding: {
|
|
788
|
+
base: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
789
|
+
small: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
790
|
+
none: string;
|
|
791
|
+
};
|
|
792
|
+
zIndex: {
|
|
793
|
+
"100": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
794
|
+
"200": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
795
|
+
"300": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
796
|
+
"400": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
797
|
+
"500": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
798
|
+
"600": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
799
|
+
"700": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
800
|
+
"800": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
801
|
+
"900": `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
|
|
802
|
+
};
|
|
803
|
+
overflow: Overflow[];
|
|
804
|
+
};
|
|
805
|
+
export type PopoverColorProperties = keyof typeof propertiesPopover.color;
|
|
806
|
+
export type PopoverBackgroundColorProperties = keyof typeof propertiesPopover.backgroundColor;
|
|
807
|
+
export type PopoverPaddingProperties = keyof typeof propertiesPopover.padding;
|
|
808
|
+
export type PopoverZIndexProperties = keyof typeof propertiesPopover.zIndex;
|
|
809
|
+
export interface PopoverSprinkle {
|
|
810
|
+
/**
|
|
811
|
+
* The width property specifies the width of a popover's content area.
|
|
812
|
+
* @default fit-content
|
|
813
|
+
*/
|
|
814
|
+
width?: string | Conditions<string>;
|
|
815
|
+
/**
|
|
816
|
+
* The maxWidth property specifies the maximum width of a popover's content area.
|
|
817
|
+
*/
|
|
818
|
+
maxWidth?: string | Conditions<string>;
|
|
819
|
+
/**
|
|
820
|
+
* The height property specifies the height of a popover's content area.
|
|
821
|
+
*/
|
|
822
|
+
height?: string | Conditions<string>;
|
|
823
|
+
/**
|
|
824
|
+
* The zIndex property specifies the stack order of the popover.
|
|
825
|
+
*/
|
|
826
|
+
zIndex?: PopoverZIndexProperties | Conditions<PopoverZIndexProperties>;
|
|
827
|
+
/**
|
|
828
|
+
* The backgroundColor property sets the background color of the popover.
|
|
829
|
+
* @default neutral-background
|
|
830
|
+
* @examples ["neutral-interactive", { xs: "neutral-surface", md: "neutral-interactive" }]
|
|
831
|
+
*/
|
|
832
|
+
backgroundColor?: PopoverBackgroundColorProperties | Conditions<PopoverBackgroundColorProperties>;
|
|
833
|
+
/**
|
|
834
|
+
* The color property is used to set the color of the popover.
|
|
835
|
+
* @default neutral-background
|
|
836
|
+
*/
|
|
837
|
+
color?: PopoverColorProperties | Conditions<PopoverColorProperties>;
|
|
838
|
+
/**
|
|
839
|
+
* The padding properties are used to generate space around an popover's content area.
|
|
840
|
+
* @default base
|
|
841
|
+
*/
|
|
842
|
+
padding?: PopoverPaddingProperties | Conditions<PopoverPaddingProperties>;
|
|
843
|
+
/**
|
|
844
|
+
* The overflow shorthand property sets the desired behavior for an popover's content overflow.
|
|
845
|
+
*/
|
|
846
|
+
overflow?: Overflow | Conditions<Overflow>;
|
|
847
|
+
}
|
|
848
|
+
export interface BoxProperties extends BoxSprinkle {
|
|
849
|
+
/**
|
|
850
|
+
* Element to be rendered inside the Box component.
|
|
851
|
+
* @TJS-type React.ReactNode
|
|
852
|
+
*/
|
|
853
|
+
children?: ReactNode;
|
|
854
|
+
}
|
|
855
|
+
export type BoxBaseProps = BoxProperties & Omit<HTMLAttributes<HTMLElement>, "color">;
|
|
856
|
+
declare const Box: PolymorphicForwardRefComponent<"div", BoxBaseProps>;
|
|
857
|
+
export type BoxProps = ComponentPropsWithRef<typeof Box>;
|
|
858
|
+
export type PopoverPlacement = "top" | "right" | "bottom" | "left" | "bottom-start" | "bottom-end" | "left-start" | "left-end" | "right-start" | "right-end" | "top-start" | "top-end";
|
|
859
|
+
export interface PopoverProperties extends PopoverSprinkle {
|
|
860
|
+
/**
|
|
861
|
+
* An HTML element, or a function that returns one. It's used to set the position of the popover.
|
|
862
|
+
* @TJS-type React.ReactNode | ((data: { open: boolean, setVisibility: (visibility: boolean) => void }) => React.ReactNode);
|
|
863
|
+
*/
|
|
864
|
+
children: ReactNode | ((data: {
|
|
865
|
+
open: boolean;
|
|
866
|
+
setVisibility: (visibility: boolean) => void;
|
|
867
|
+
}) => ReactNode);
|
|
868
|
+
/**
|
|
869
|
+
* The content of the popover.
|
|
870
|
+
* @TJS-type React.ReactNode
|
|
871
|
+
*/
|
|
872
|
+
content: ReactNode;
|
|
873
|
+
/**
|
|
874
|
+
* If true, the component is shown.
|
|
875
|
+
*/
|
|
876
|
+
visible?: boolean;
|
|
877
|
+
/**
|
|
878
|
+
* Function to control popover opening and closing.
|
|
879
|
+
* @TJS-type (visible: boolean) => void;
|
|
880
|
+
*/
|
|
881
|
+
onVisibility?: (visible: boolean) => void;
|
|
882
|
+
/**
|
|
883
|
+
* Conditional for displaying the popover arrow.
|
|
884
|
+
* @default true
|
|
885
|
+
*/
|
|
886
|
+
arrow?: boolean;
|
|
887
|
+
/**
|
|
888
|
+
* A common feature of select dropdowns is that the dropdown matches the width of the reference regardless of its contents.
|
|
889
|
+
* @default false
|
|
890
|
+
*/
|
|
891
|
+
matchReferenceWidth?: boolean;
|
|
892
|
+
/**
|
|
893
|
+
* Position of the popover.
|
|
894
|
+
* @default bottom
|
|
895
|
+
*/
|
|
896
|
+
position?: PopoverPlacement;
|
|
897
|
+
/**
|
|
898
|
+
* Adds hover event listeners that change the open state, like CSS :hover.
|
|
899
|
+
* @default false
|
|
900
|
+
*/
|
|
901
|
+
enabledHover?: boolean;
|
|
902
|
+
/**
|
|
903
|
+
* Adds click event listeners that change the open state.
|
|
904
|
+
* @default true
|
|
905
|
+
*/
|
|
906
|
+
enabledClick?: boolean;
|
|
907
|
+
/**
|
|
908
|
+
* Adds listeners that dismiss (close) the floating element.
|
|
909
|
+
* @default true
|
|
910
|
+
*/
|
|
911
|
+
enabledDismiss?: boolean;
|
|
912
|
+
/**
|
|
913
|
+
* Offest displaces the floating element from its core placement along the specified axes.
|
|
914
|
+
* @default 10
|
|
915
|
+
*/
|
|
916
|
+
offset?: number;
|
|
917
|
+
/**
|
|
918
|
+
* When enabled, renders an invisible overlay that prevents accidental clicks on elements behind the popover.
|
|
919
|
+
* @default false
|
|
920
|
+
*/
|
|
921
|
+
renderOverlay?: boolean;
|
|
922
|
+
}
|
|
923
|
+
export type PopoverProps = PopoverProperties & Omit<HTMLAttributes<HTMLDivElement>, "children" | "content">;
|
|
924
|
+
export interface SplitButtonActionProperties {
|
|
925
|
+
/**
|
|
926
|
+
* The content of the action item.
|
|
927
|
+
* @TJS-type React.ReactNode
|
|
928
|
+
*/
|
|
929
|
+
children: ReactNode;
|
|
930
|
+
/**
|
|
931
|
+
* Optional icon to display before the action text.
|
|
932
|
+
* @TJS-type React.ReactNode
|
|
933
|
+
*/
|
|
934
|
+
icon?: ReactNode;
|
|
935
|
+
/**
|
|
936
|
+
* Callback function when the action is clicked.
|
|
937
|
+
* @TJS-type () => void;
|
|
938
|
+
*/
|
|
939
|
+
onClick?: () => void;
|
|
940
|
+
/**
|
|
941
|
+
* Disables the action item.
|
|
942
|
+
* @default false
|
|
943
|
+
*/
|
|
944
|
+
disabled?: boolean;
|
|
945
|
+
}
|
|
946
|
+
export type SplitButtonActionProps = SplitButtonActionProperties & Pick<BoxProps, "backgroundColor" | "borderWidth" | "display" | "alignItems" | "gap" | "p" | "borderRadius">;
|
|
947
|
+
export declare const SplitButtonAction: React.FC<SplitButtonActionProps>;
|
|
948
|
+
export interface SplitButtonPrimaryProperties {
|
|
949
|
+
/**
|
|
950
|
+
* The content of the primary button.
|
|
951
|
+
* @TJS-type React.ReactNode
|
|
952
|
+
*/
|
|
953
|
+
children: ReactNode;
|
|
954
|
+
/**
|
|
955
|
+
* Callback function when the primary button is clicked.
|
|
956
|
+
* @TJS-type () => void;
|
|
957
|
+
*/
|
|
958
|
+
onClick?: () => void;
|
|
959
|
+
}
|
|
960
|
+
export type SplitButtonPrimaryProps = SplitButtonPrimaryProperties & Omit<ButtonHTMLAttributes<HTMLButtonElement>, "onClick" | "children">;
|
|
961
|
+
export declare const SplitButtonPrimary: React.FC<SplitButtonPrimaryProps>;
|
|
962
|
+
export interface SplitButtonSecondaryProperties {
|
|
963
|
+
/**
|
|
964
|
+
* The content of the secondary dropdown menu.
|
|
965
|
+
* @TJS-type React.ReactNode
|
|
966
|
+
*/
|
|
967
|
+
children: ReactNode;
|
|
968
|
+
/**
|
|
969
|
+
* Accessible label for the dropdown button.
|
|
970
|
+
* @default "Show more actions"
|
|
971
|
+
*/
|
|
972
|
+
ariaLabel?: string;
|
|
973
|
+
}
|
|
974
|
+
export type SplitButtonSecondaryProps = SplitButtonSecondaryProperties & Omit<ButtonHTMLAttributes<HTMLButtonElement>, "children">;
|
|
975
|
+
export declare const SplitButtonSecondary: React.FC<SplitButtonSecondaryProps>;
|
|
976
|
+
export interface SplitButtonComponents {
|
|
977
|
+
Action: typeof SplitButtonAction;
|
|
978
|
+
Primary: typeof SplitButtonPrimary;
|
|
979
|
+
Secondary: typeof SplitButtonSecondary;
|
|
980
|
+
}
|
|
981
|
+
export interface SplitButtonProperties {
|
|
982
|
+
/**
|
|
983
|
+
* The subcomponents (Primary and Secondary).
|
|
984
|
+
* @TJS-type React.ReactNode
|
|
985
|
+
*/
|
|
986
|
+
children: ReactNode;
|
|
987
|
+
/**
|
|
988
|
+
* Disables the entire split button.
|
|
989
|
+
* @default false
|
|
990
|
+
*/
|
|
991
|
+
disabled?: boolean;
|
|
992
|
+
/**
|
|
993
|
+
* Controls the visibility of the popover.
|
|
994
|
+
*/
|
|
995
|
+
open?: boolean;
|
|
996
|
+
/**
|
|
997
|
+
* Callback function to control popover opening and closing.
|
|
998
|
+
* @TJS-type (open: boolean) => void;
|
|
999
|
+
*/
|
|
1000
|
+
onOpenChange?: (open: boolean) => void;
|
|
1001
|
+
/**
|
|
1002
|
+
* Position of the popover relative to the button.
|
|
1003
|
+
* @default bottom-end
|
|
1004
|
+
*/
|
|
1005
|
+
popoverPosition?: PopoverProps["position"];
|
|
1006
|
+
}
|
|
1007
|
+
export type SplitButtonProps = SplitButtonProperties & Omit<BoxProps, "children" | "display" | "gap" | "position">;
|
|
1008
|
+
/**
|
|
1009
|
+
* SplitButton component allows users to perform actions by clicking a primary button and displaying a dropdown menu with additional actions.
|
|
1010
|
+
*/
|
|
1011
|
+
export declare const SplitButton: React.FC<SplitButtonProps> & SplitButtonComponents;
|
|
1012
|
+
|
|
1013
|
+
export {};
|