@marigold/components 0.6.0 → 0.9.0

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2021 Marigold UI
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/dist/index.d.ts CHANGED
@@ -1,16 +1,21 @@
1
- import { Theme as Theme$1, ThemeProviderProps, BoxOwnProps, ResponsiveStyleValue, CSSObject } from '@marigold/system';
1
+ import { Theme as Theme$1, ThemeProviderProps, ThemeExtension, ThemeComponentProps, ThemeExtensionsWithParts, BoxOwnProps, CSSObject, StateAttrProps, ResponsiveStyleValue } from '@marigold/system';
2
2
  export { Box, BoxOwnProps, BoxProps, StyleProps, ThemeProvider, useTheme } from '@marigold/system';
3
- import React from 'react';
4
- import { ComponentProps, PolymorphicPropsWithRef, PolymorphicComponentWithRef, PolymorphicProps, PolymorphicComponent } from '@marigold/types';
5
- import { ToggleProps } from '@react-types/checkbox';
3
+ import React, { ReactNode, Key, LabelHTMLAttributes, HTMLAttributes, ReactChild } from 'react';
4
+ import { ComponentProps, PolymorphicPropsWithRef, PolymorphicComponentWithRef, PolymorphicProps, PolymorphicComponent, NonZeroPercentage } from '@marigold/types';
5
+ import * as _react_types_shared from '@react-types/shared';
6
+ import { PressEvents, CollectionElement, SingleSelection, Node } from '@react-types/shared';
7
+ import { AriaCheckboxProps, AriaCheckboxGroupProps, ToggleProps } from '@react-types/checkbox';
8
+ import { CheckboxGroupState } from '@react-stately/checkbox';
6
9
  import { SeparatorProps } from '@react-aria/separator';
10
+ import { AriaTextFieldProps } from '@react-types/textfield';
7
11
  import { AriaSelectProps } from '@react-types/select';
8
- import { SingleSelection } from '@react-types/shared';
9
12
  import { AriaSwitchProps } from '@react-types/switch';
10
- import { AriaTextFieldProps } from '@react-types/textfield';
13
+ import { TableProps as TableProps$1 } from '@react-aria/table';
14
+ import { TableState, TableStateProps, TableBody, Cell, Column, TableHeader, Row } from '@react-stately/table';
11
15
  import { TooltipTriggerProps } from '@react-types/tooltip';
16
+ import { aspect, size } from '@marigold/tokens';
12
17
  import * as _react_stately_overlays from '@react-stately/overlays';
13
- import { OverlayProps } from '@react-aria/overlays';
18
+ import { OverlayProps as OverlayProps$1 } from '@react-aria/overlays';
14
19
  import { AriaDialogProps } from '@react-types/dialog';
15
20
  export { VisuallyHidden } from '@react-aria/visually-hidden';
16
21
  export { SSRProvider } from '@react-aria/ssr';
@@ -27,158 +32,222 @@ interface MarigoldProviderProps<T extends Theme$1> extends ThemeProviderProps<T>
27
32
  }
28
33
  declare function MarigoldProvider<T extends Theme$1>({ theme, children, }: MarigoldProviderProps<T>): JSX.Element;
29
34
 
30
- interface BadgeThemeExtension<Value> {
31
- badge?: {
32
- [key: string]: Value;
33
- };
35
+ interface BadgeThemeExtension extends ThemeExtension<'Badge'> {
34
36
  }
35
37
  interface BadgeProps extends ComponentProps<'div'> {
38
+ children?: React.ReactNode;
36
39
  variant?: string;
37
- bgColor?: string;
38
- borderColor?: string;
40
+ size?: string;
39
41
  }
40
- declare const Badge: React.FC<BadgeProps>;
42
+ declare const Badge: ({ variant, size, children, ...props }: BadgeProps) => JSX.Element;
41
43
 
42
- interface ButtonThemeExtension<Value> {
43
- button?: {
44
- [key: string]: Value;
45
- };
44
+ interface ButtonThemeExtension extends ThemeExtension<'Button'> {
45
+ }
46
+ interface ButtonOwnProps extends PressEvents {
47
+ children?: ReactNode;
48
+ variant?: string;
49
+ size?: string;
46
50
  }
47
- interface ButtonProps extends PolymorphicPropsWithRef<BoxOwnProps, 'button'> {
51
+ interface ButtonProps extends PolymorphicPropsWithRef<ButtonOwnProps, 'button'> {
48
52
  }
49
- declare const Button: PolymorphicComponentWithRef<BoxOwnProps, 'button'>;
53
+ declare const Button: PolymorphicComponentWithRef<ButtonOwnProps, 'button'>;
50
54
 
51
- interface CardThemeExtension<Value> {
52
- card?: {
53
- [key: string]: Value;
54
- };
55
+ interface CardThemeExtension extends ThemeExtension<'Card'> {
55
56
  }
56
- interface CardProps extends ComponentProps<'div'> {
57
- title?: string;
58
- width?: ResponsiveStyleValue<string>;
59
- variant?: string;
57
+ interface CardProps extends ThemeComponentProps, ComponentProps<'div'> {
58
+ children?: ReactNode;
59
+ }
60
+ declare const Card: ({ children, variant, size, ...props }: CardProps) => JSX.Element;
61
+
62
+ interface CheckboxThemeExtension extends ThemeExtensionsWithParts<'Checkbox', [
63
+ 'container',
64
+ 'label',
65
+ 'checkbox'
66
+ ]> {
67
+ }
68
+ /**
69
+ * `react-aria` has a slightly different API for the above events.
70
+ * Thus, we adjust our regular props to match them.
71
+ */
72
+ declare type CustomCheckboxProps = 'value' | 'onChange' | 'onFocus' | 'onBlur';
73
+ interface CheckboxProps extends ThemeComponentProps, Omit<ComponentProps<'input'>, 'size' | 'type' | 'defaultValue' | CustomCheckboxProps>, Pick<AriaCheckboxProps, CustomCheckboxProps> {
74
+ children?: ReactNode;
75
+ indeterminate?: boolean;
76
+ error?: boolean;
60
77
  }
61
- declare const Card: React.FC<CardProps>;
78
+ declare const Checkbox: ({ size, variant, disabled, checked, defaultChecked, indeterminate, readOnly, required, error, ...props }: CheckboxProps) => JSX.Element;
62
79
 
63
- interface CheckboxIconProps {
80
+ interface CheckboxGroupContextProps extends CheckboxGroupState {
81
+ error?: boolean;
64
82
  variant?: string;
65
- checked?: boolean;
83
+ size?: string;
84
+ }
85
+ declare const CheckboxGroupContext: React.Context<CheckboxGroupContextProps>;
86
+ declare const useCheckboxGroupContext: () => CheckboxGroupContextProps;
87
+ interface CheckboxGroupThemeExtension extends ThemeExtensionsWithParts<'CheckboxGroup', ['container', 'group']> {
88
+ }
89
+ interface CheckboxGroupProps extends Omit<ComponentProps<'div'>, 'onChange'>, AriaCheckboxGroupProps {
90
+ children?: ReactNode;
91
+ variant?: string;
92
+ size?: string;
93
+ label?: ReactNode;
94
+ required?: boolean;
66
95
  disabled?: boolean;
67
- indeterminated?: boolean;
96
+ readOnly?: boolean;
68
97
  error?: boolean;
98
+ value?: string[];
99
+ defaultValue?: string[];
100
+ onChange?: (value: string[]) => void;
69
101
  }
102
+ declare const CheckboxGroup: ({ children, variant, size, required, disabled, readOnly, error, ...rest }: CheckboxGroupProps) => JSX.Element;
70
103
 
71
- interface CheckboxThemeExtension<Value> {
72
- checkbox?: {
73
- [key: string]: Value;
74
- };
104
+ interface ContentThemeExtension extends ThemeExtension<'Content'> {
75
105
  }
76
- declare type CheckboxInputProps = CheckboxIconProps & ToggleProps & ComponentProps<'input'>;
77
- interface CheckboxProps extends CheckboxInputProps {
78
- id: string;
79
- required?: boolean;
80
- labelVariant?: string;
81
- errorMessage?: string;
106
+ interface ContentProps extends ThemeComponentProps, ComponentProps<'section'> {
107
+ children?: ReactNode;
82
108
  }
83
- declare const Checkbox: React.FC<CheckboxProps>;
109
+ declare const Content: ({ children, variant, size, ...props }: ContentProps) => JSX.Element;
84
110
 
85
- interface DividerThemeExtension<Value> {
86
- divider?: {
87
- [key: string]: Value;
88
- };
111
+ interface DividerThemeExtension extends ThemeExtension<'Divider'> {
89
112
  }
90
113
  interface DividerProps extends SeparatorProps {
91
114
  variant?: string;
92
115
  }
93
- declare const Divider: React.FC<DividerProps>;
116
+ declare const Divider: ({ variant, ...props }: DividerProps) => JSX.Element;
94
117
 
95
- interface ImageThemeExtension<Value> {
96
- image?: {
97
- [key: string]: Value;
98
- };
118
+ interface FooterThemeExtension extends ThemeExtension<'Footer'> {
99
119
  }
100
- interface ImageProps extends ComponentProps<'img'> {
101
- variant?: string;
102
- children?: never;
120
+ interface FooterProps extends ThemeComponentProps, ComponentProps<'footer'> {
121
+ children?: ReactNode;
103
122
  }
104
- declare const Image: React.FC<ImageProps>;
123
+ declare const Footer: ({ children, variant, size, ...props }: FooterProps) => JSX.Element;
105
124
 
106
- interface InputThemeExtension<Value> {
107
- input?: {
108
- [key: string]: Value;
109
- };
125
+ interface HeaderThemeExtension extends ThemeExtension<'Header'> {
110
126
  }
111
- interface InputProps extends ComponentProps<'input'> {
112
- variant?: string;
127
+ interface HeaderProps extends ThemeComponentProps, ComponentProps<'header'> {
128
+ children?: ReactNode;
113
129
  }
114
- declare const Input: React.FC<InputProps>;
130
+ declare const Header: ({ children, variant, size, ...props }: HeaderProps) => JSX.Element;
115
131
 
116
- interface LabelThemeExtension<Value> {
117
- label?: {
118
- [key: string]: Value;
119
- };
132
+ interface HeadlineThemeExtension extends ThemeExtension<'Headline'> {
120
133
  }
121
- declare type LabelBaseProps = {
122
- htmlFor?: string;
134
+ interface HeadlineProps extends ThemeComponentProps, ComponentProps<'h1'> {
135
+ children?: ReactNode;
136
+ level?: '1' | '2' | '3' | '4' | '5' | '6';
137
+ }
138
+ declare const Headline: ({ children, variant, size, level, ...props }: HeadlineProps) => JSX.Element;
139
+
140
+ interface HelpTextThemeExtension extends ThemeExtensionsWithParts<'HelpText', ['container', 'icon']> {
141
+ }
142
+
143
+ interface ImageThemeExtension extends ThemeExtension<'Image'> {
144
+ }
145
+ interface ImageProps extends ComponentProps<'img'> {
123
146
  variant?: string;
124
- required?: boolean;
125
- color?: ResponsiveStyleValue<string>;
126
- } & ComponentProps<'label'>;
127
- declare const LabelBase: React.FC<LabelProps>;
128
- interface LabelProps extends LabelBaseProps {
129
- required?: boolean;
147
+ children?: never;
130
148
  }
131
- declare const Label: React.FC<LabelProps>;
149
+ declare const Image: ({ variant, ...props }: ImageProps) => JSX.Element;
132
150
 
133
- interface TextThemeExtension<Value> {
134
- text?: {
135
- [key: string]: Value;
136
- };
151
+ interface InputThemeExtension extends ThemeExtension<'Input'> {
137
152
  }
138
- interface TextOwnProps extends BoxOwnProps {
139
- align?: ResponsiveStyleValue<string>;
140
- color?: ResponsiveStyleValue<string>;
141
- cursor?: ResponsiveStyleValue<string>;
142
- size?: ResponsiveStyleValue<keyof Theme$1['fontSizes'] | string>;
143
- outline?: ResponsiveStyleValue<string>;
144
- userSelect?: ResponsiveStyleValue<string>;
153
+ interface InputOwnProps extends Omit<ComponentProps<'input'>, 'size'> {
154
+ size?: string;
155
+ variant?: string;
156
+ }
157
+ interface InputProps extends Omit<React.ComponentPropsWithRef<'input'>, 'size'>, InputOwnProps {
145
158
  }
146
- interface TextProps extends PolymorphicPropsWithRef<TextOwnProps, 'span'> {
159
+ declare const Input: React.ForwardRefExoticComponent<InputOwnProps & React.RefAttributes<HTMLInputElement>>;
160
+
161
+ interface LabelThemeExtension$1 extends ThemeExtension<'Label'> {
147
162
  }
148
- declare const Text: PolymorphicComponentWithRef<TextOwnProps, 'span'>;
149
163
 
150
- interface LinkThemeExtension<Value> {
151
- link?: Value;
164
+ interface LinkThemeExtension extends ThemeExtension<'Link'> {
152
165
  }
153
- interface LinkOwnProps extends TextOwnProps {
166
+ interface LinkOwnProps extends BoxOwnProps {
154
167
  disabled?: boolean;
168
+ variant?: string;
169
+ size?: string;
155
170
  }
156
171
  interface LinkProps extends PolymorphicProps<LinkOwnProps, 'a'> {
157
172
  }
158
173
  declare const Link: PolymorphicComponent<LinkOwnProps, "a">;
159
174
 
160
- interface MenuThemeExtension<Value> {
161
- menu?: Value;
175
+ interface MenuTriggerProps {
176
+ children: [trigger: ReactNode, menu: ReactNode];
177
+ disabled?: boolean;
178
+ }
179
+
180
+ interface MenuThemeExtension extends ThemeExtensionsWithParts<'Menu', ['container', 'item']> {
162
181
  }
163
- interface MenuProps {
182
+ interface MenuProps extends Omit<ComponentProps<'ul'>, 'onSelect' | 'size'> {
183
+ children: CollectionElement<object> | CollectionElement<object>[];
164
184
  variant?: string;
165
- label?: string;
166
- onClick: ComponentProps<typeof Button>['onClick'];
167
- show?: boolean;
168
- className?: string;
169
- title?: string;
185
+ size?: string;
186
+ onSelect?: (key: Key) => void;
187
+ }
188
+ declare const Menu: {
189
+ ({ variant, size, ...props }: MenuProps): JSX.Element;
190
+ Trigger: ({ disabled, children }: MenuTriggerProps) => JSX.Element;
191
+ Item: <T>(props: _react_types_shared.ItemProps<T>) => JSX.Element;
192
+ };
193
+
194
+ interface TextThemeExtension extends ThemeExtension<'Text'> {
195
+ }
196
+ interface TextProps extends ThemeComponentProps, ComponentProps<'p'>, Omit<BoxOwnProps, 'variant'> {
197
+ align?: CSSObject['textAlign'];
198
+ color?: string;
199
+ cursor?: string;
200
+ fontSize?: string;
201
+ outline?: string;
202
+ children?: React.ReactNode;
203
+ }
204
+ declare const Text: ({ variant, size, align, color, fontSize, cursor, outline, children, ...props }: TextProps) => JSX.Element;
205
+
206
+ interface FieldBaseProps {
207
+ children?: ReactNode;
208
+ variant?: string;
209
+ size?: string;
210
+ disabled?: boolean;
211
+ required?: boolean;
212
+ label?: ReactNode;
213
+ labelProps?: LabelHTMLAttributes<HTMLLabelElement>;
214
+ description?: ReactNode;
215
+ descriptionProps?: HTMLAttributes<HTMLElement>;
216
+ error?: boolean;
217
+ errorMessage?: ReactNode;
218
+ errorMessageProps?: HTMLAttributes<HTMLElement>;
219
+ stateProps?: StateAttrProps;
220
+ }
221
+
222
+ interface TextAreaThemeExtension extends ThemeExtension<'TextArea'> {
223
+ }
224
+ /**
225
+ * `react-aria` has a slightly different API for the above events.
226
+ * Thus, we adjust our regular props to match them.
227
+ */
228
+ declare type CustomTextAreEvents = 'onChange' | 'onFocus' | 'onBlur' | 'onCopy' | 'onSelect' | 'onPaste' | 'onCut' | 'onCompositionStart' | 'onCompositionUpdate' | 'onCompositionEnd' | 'onBeforeInput' | 'onInput';
229
+ interface TextAreaProps extends Omit<ComponentProps<'textarea'>, 'value' | 'defaultValue' | CustomTextAreEvents>, Pick<AriaTextFieldProps, CustomTextAreEvents>, Pick<FieldBaseProps, 'label' | 'description' | 'error' | 'errorMessage'> {
230
+ value?: string;
231
+ defaultValue?: string;
170
232
  }
171
- declare const Menu: React.FC<MenuProps>;
233
+ declare const TextArea: ({ disabled, required, readOnly, error, ...props }: TextAreaProps) => JSX.Element;
172
234
 
173
- interface MenuItemThemeExtension<Value> {
174
- menuItem?: {
235
+ interface LabelThemeExtension<Value> {
236
+ label?: {
175
237
  [key: string]: Value;
176
238
  };
177
239
  }
178
- interface MenuItemProps extends ComponentProps<typeof Link> {
240
+ declare type LabelBaseProps = {
241
+ htmlFor?: string;
179
242
  variant?: string;
243
+ required?: boolean;
244
+ color?: ResponsiveStyleValue<string>;
245
+ } & ComponentProps<'label'>;
246
+ declare const LabelBase: React.FC<LabelProps>;
247
+ interface LabelProps extends LabelBaseProps {
248
+ required?: boolean;
180
249
  }
181
- declare const MenuItem: React.FC<MenuItemProps>;
250
+ declare const Label: React.FC<LabelProps>;
182
251
 
183
252
  interface MessageThemeExtension<Value> {
184
253
  message?: {
@@ -258,18 +327,52 @@ declare type SwitchProps = {
258
327
  } & AriaSwitchProps & ToggleProps & ComponentProps<'input'>;
259
328
  declare const Switch: React.FC<SwitchProps>;
260
329
 
261
- interface TextareaThemeExtension<Value> {
262
- textarea?: {
263
- [key: string]: Value;
264
- };
265
- }
266
- declare type TextareaProps = {
330
+ interface TableCellProps {
331
+ item: Node<object>;
332
+ state: TableState<object>;
333
+ /**
334
+ * Wheter it is a cell with a checkbox or a regular data cell
335
+ */
336
+ isSelectionCell?: boolean;
337
+ align?: 'left' | 'center' | 'right';
338
+ css?: CSSObject;
339
+ }
340
+
341
+ interface TableColumnHeaderProps {
342
+ chilren?: ReactNode;
343
+ item: Node<object>;
344
+ state: TableState<object>;
345
+ isSelectionColumn?: boolean;
346
+ align?: 'left' | 'center' | 'right';
347
+ css?: CSSObject;
348
+ }
349
+
350
+ interface TableThemeExtension extends ThemeExtensionsWithParts<'Table', [
351
+ 'table',
352
+ 'header',
353
+ 'row',
354
+ 'cell'
355
+ ]> {
356
+ }
357
+ interface TableProps extends Pick<TableProps$1<object>, 'onRowAction' | 'onCellAction'>, TableStateProps<object> {
358
+ align?: TableCellProps['align'];
359
+ alignHeader?: TableColumnHeaderProps['align'];
267
360
  variant?: string;
268
- htmlFor: string;
269
- required?: boolean;
270
- error?: boolean;
271
- } & AriaTextFieldProps & ComponentProps<'textarea'>;
272
- declare const Textarea: React.FC<TextareaProps>;
361
+ size?: string;
362
+ }
363
+ declare const Table: Table;
364
+ /**
365
+ * Necessary since TypeScript can not infer the
366
+ * types of the @react-stately components correctly.
367
+ */
368
+ interface Table {
369
+ (props: TableProps): JSX.Element;
370
+ Body: typeof TableBody;
371
+ Cell: typeof Cell;
372
+ Column: typeof Column;
373
+ Header: typeof TableHeader;
374
+ Row: typeof Row;
375
+ }
273
376
 
274
377
  interface TooltipThemeExtension<Value> {
275
378
  tooltip?: {
@@ -296,31 +399,54 @@ interface ValidationMessageProps extends ComponentProps<'span'> {
296
399
  }
297
400
  declare const ValidationMessage: React.FC<ValidationMessageProps>;
298
401
 
299
- interface Theme extends Theme$1, RootThemeExtension<CSSObject>, BadgeThemeExtension<CSSObject>, ButtonThemeExtension<CSSObject>, CardThemeExtension<CSSObject>, CheckboxThemeExtension<CSSObject>, DividerThemeExtension<CSSObject>, ImageThemeExtension<CSSObject>, InputThemeExtension<CSSObject>, LabelThemeExtension<CSSObject>, LinkThemeExtension<CSSObject>, MenuThemeExtension<CSSObject>, MenuItemThemeExtension<CSSObject>, MessageThemeExtension<CSSObject>, RadioThemeExtension<CSSObject>, SelectThemeExtension<CSSObject>, SliderThemeExtension<CSSObject>, SwitchThemeExtension<CSSObject>, TextThemeExtension<CSSObject>, TextareaThemeExtension<CSSObject>, TooltipThemeExtension<CSSObject>, ValidationMessageThemeExtension<CSSObject> {
402
+ interface ComponentStyles extends BadgeThemeExtension, ButtonThemeExtension, CardThemeExtension, CheckboxThemeExtension, CheckboxGroupThemeExtension, ContentThemeExtension, DividerThemeExtension, FooterThemeExtension, HeaderThemeExtension, HeadlineThemeExtension, HelpTextThemeExtension, ImageThemeExtension, InputThemeExtension, LabelThemeExtension$1, LabelThemeExtension$1, LinkThemeExtension, MenuThemeExtension, TableThemeExtension, TextThemeExtension, TextAreaThemeExtension {
403
+ }
404
+ interface Theme extends Theme$1, RootThemeExtension<CSSObject>, LabelThemeExtension<CSSObject>, MessageThemeExtension<CSSObject>, RadioThemeExtension<CSSObject>, SelectThemeExtension<CSSObject>, SliderThemeExtension<CSSObject>, SwitchThemeExtension<CSSObject>, TooltipThemeExtension<CSSObject>, ValidationMessageThemeExtension<CSSObject> {
405
+ components: ComponentStyles;
300
406
  }
301
407
 
302
- interface ActionGroupProps extends ComponentProps<'div'> {
408
+ interface AsideProps {
409
+ children: [ReactChild, ReactChild];
410
+ side?: 'left' | 'right';
411
+ sideWidth?: ResponsiveStyleValue<string>;
303
412
  space?: ResponsiveStyleValue<string>;
304
- verticalAlignment?: boolean;
413
+ stretch?: boolean;
414
+ wrap?: NonZeroPercentage;
415
+ }
416
+ declare const Aside: ({ children, sideWidth, space, side, stretch, wrap, }: AsideProps) => JSX.Element;
417
+
418
+ /**
419
+ * Based on https://theme-ui.com/components/aspect-ratio
420
+ */
421
+
422
+ interface AspectProps extends ComponentProps<'div'> {
423
+ children?: ReactNode;
424
+ ratio?: keyof typeof aspect;
425
+ maxWidth?: string;
305
426
  }
306
- declare const ActionGroup: React.FC<ActionGroupProps>;
427
+ declare const Aspect: ({ ratio, maxWidth, children, }: AspectProps) => JSX.Element;
307
428
 
308
- declare type WidthValues = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
309
- interface ColumnProps {
310
- className?: string;
311
- width?: WidthValues | WidthValues[];
429
+ interface BreakoutProps extends ComponentProps<'div'> {
430
+ horizontalAlign?: 'top' | 'bottom' | 'center';
431
+ verticalAlign?: 'left' | 'right' | 'center';
432
+ }
433
+ declare const Breakout: React.FC<BreakoutProps>;
434
+
435
+ interface CenterProps extends ComponentProps<'div'> {
436
+ maxWidth?: string;
437
+ space?: ResponsiveStyleValue<string>;
312
438
  }
313
- declare const Column: React.FC<ColumnProps>;
439
+ declare const Center: React.FC<CenterProps>;
314
440
 
315
441
  interface ColumnsProps {
316
- className?: string;
442
+ columns: Array<number>;
317
443
  space?: ResponsiveStyleValue<string>;
318
- horizontalAlign?: 'left' | 'right' | 'center';
319
- verticalAlign?: 'top' | 'bottom' | 'center';
444
+ columnLimit?: number;
445
+ collapseAt?: string;
320
446
  }
321
447
  declare const Columns: React.FC<ColumnsProps>;
322
448
 
323
- interface ModalDialogProps extends OverlayProps, AriaDialogProps {
449
+ interface ModalDialogProps extends OverlayProps$1, AriaDialogProps {
324
450
  variant?: string;
325
451
  backdropVariant?: string;
326
452
  }
@@ -340,29 +466,57 @@ declare const useDialogButtonProps: () => {
340
466
  openButtonRef: React.RefObject<HTMLElement>;
341
467
  };
342
468
 
343
- declare type FieldProps = {
344
- variant?: string;
345
- labelVariant?: string;
346
- htmlFor: string;
347
- required?: boolean;
348
- error?: boolean;
349
- } & AriaTextFieldProps & ComponentProps<'input'>;
350
- declare const Field: React.FC<FieldProps>;
351
-
352
469
  interface InlineProps {
353
470
  space?: ResponsiveStyleValue<string>;
354
471
  align?: 'top' | 'center' | 'bottom';
355
472
  }
356
473
  declare const Inline: React.FC<InlineProps>;
357
474
 
475
+ interface OverlayProps extends ComponentProps<'div'> {
476
+ children: ReactNode;
477
+ open?: boolean;
478
+ container?: Element;
479
+ }
480
+ declare const Overlay: ({ children, open, container, ...props }: OverlayProps) => JSX.Element | null;
481
+
482
+ interface PopoverProps extends Omit<OverlayProps$1, 'isOpen' | 'isDismissable' | 'isKeyboardDismissDisabled'> {
483
+ children?: ReactNode;
484
+ open?: boolean;
485
+ dismissable?: boolean;
486
+ keyboardDismissDisabled?: boolean;
487
+ }
488
+ declare const Popover: React.ForwardRefExoticComponent<PopoverProps & React.RefAttributes<unknown>>;
489
+
358
490
  interface StackProps {
491
+ as?: 'div' | 'ul' | 'ol';
359
492
  space?: ResponsiveStyleValue<string>;
360
493
  align?: 'left' | 'right' | 'center';
361
494
  }
362
495
  declare const Stack: React.FC<StackProps>;
363
496
 
497
+ interface TextFieldProps extends Omit<ComponentProps<'input'>, 'value' | 'defaultValue' | 'onChange' | 'onFocus' | 'onBlur'>,
498
+ /**
499
+ * `react-aria` has a slightly different API for `onChange`, `onFocus`
500
+ * and `onBlur` events. Thus, we adjust our regular props to match them.
501
+ */
502
+ Pick<AriaTextFieldProps, 'onChange' | 'onFocus' | 'onBlur'>, Pick<FieldBaseProps, 'label' | 'description' | 'error' | 'errorMessage'> {
503
+ value?: string;
504
+ defaultValue?: string;
505
+ }
506
+ declare const TextField: ({ disabled, required, readOnly, error, ...props }: TextFieldProps) => JSX.Element;
507
+
508
+ interface TilesProps {
509
+ space?: ResponsiveStyleValue<string>;
510
+ itemMinWidth?: ResponsiveStyleValue<string>;
511
+ }
512
+ declare const Tiles: React.FC<TilesProps>;
513
+
364
514
  interface ContainerProps extends ComponentProps<'div'> {
515
+ contentType?: 'content' | 'header';
516
+ size?: keyof typeof size.content | keyof typeof size.header;
517
+ align?: 'left' | 'right' | 'center';
518
+ alignContainer?: 'left' | 'right' | 'center';
365
519
  }
366
520
  declare const Container: React.FC<ContainerProps>;
367
521
 
368
- export { ActionGroup, ActionGroupProps, Badge, BadgeProps, BadgeThemeExtension, Button, ButtonProps, ButtonThemeExtension, Card, CardProps, CardThemeExtension, Checkbox, CheckboxProps, CheckboxThemeExtension, Column, ColumnProps, Columns, ColumnsProps, Container, ContainerProps, Dialog, DialogProps, Divider, DividerProps, DividerThemeExtension, Field, FieldProps, Image, ImageProps, ImageThemeExtension, Inline, InlineProps, Input, InputProps, InputThemeExtension, Label, LabelBase, LabelBaseProps, LabelProps, LabelThemeExtension, Link, LinkOwnProps, LinkProps, LinkThemeExtension, MarigoldProvider, MarigoldProviderProps, Menu, MenuItem, MenuItemProps, MenuItemThemeExtension, MenuProps, MenuThemeExtension, Message, MessageProps, MessageThemeExtension, Radio, RadioProps, RadioThemeExtension, RootThemeExtension, Select, SelectProps, SelectThemeExtension, Slider, SliderProps, SliderThemeExtension, Stack, StackProps, Switch, SwitchProps, SwitchThemeExtension, Text, TextOwnProps, TextProps, TextThemeExtension, Textarea, TextareaProps, TextareaThemeExtension, Theme, Tooltip, TooltipContext, TooltipProps, TooltipThemeExtension, TooltipTrigger, ValidationMessage, ValidationMessageProps, ValidationMessageThemeExtension, useDialogButtonProps };
522
+ export { Aside, AsideProps, Aspect, AspectProps, Badge, BadgeProps, BadgeThemeExtension, Breakout, BreakoutProps, Button, ButtonOwnProps, ButtonProps, ButtonThemeExtension, Card, CardProps, CardThemeExtension, Center, CenterProps, Checkbox, CheckboxGroup, CheckboxGroupContext, CheckboxGroupContextProps, CheckboxGroupThemeExtension, CheckboxProps, CheckboxThemeExtension, Columns, ColumnsProps, Container, ContainerProps, Content, ContentProps, ContentThemeExtension, CustomCheckboxProps, CustomTextAreEvents, Dialog, DialogProps, Divider, DividerProps, DividerThemeExtension, Footer, FooterProps, FooterThemeExtension, Header, HeaderProps, HeaderThemeExtension, Headline, HeadlineProps, HeadlineThemeExtension, Image, ImageProps, ImageThemeExtension, Inline, InlineProps, Input, InputOwnProps, InputProps, InputThemeExtension, Label, LabelBase, LabelBaseProps, LabelProps, LabelThemeExtension, Link, LinkOwnProps, LinkProps, LinkThemeExtension, MarigoldProvider, MarigoldProviderProps, Menu, MenuProps, MenuThemeExtension, Message, MessageProps, MessageThemeExtension, Overlay, OverlayProps, Popover, PopoverProps, Radio, RadioProps, RadioThemeExtension, RootThemeExtension, Select, SelectProps, SelectThemeExtension, Slider, SliderProps, SliderThemeExtension, Stack, StackProps, Switch, SwitchProps, SwitchThemeExtension, Table, TableProps, TableThemeExtension, Text, TextArea, TextAreaProps, TextAreaThemeExtension, TextField, TextFieldProps, TextProps, TextThemeExtension, Theme, Tiles, TilesProps, Tooltip, TooltipContext, TooltipProps, TooltipThemeExtension, TooltipTrigger, ValidationMessage, ValidationMessageProps, ValidationMessageThemeExtension, useCheckboxGroupContext, useDialogButtonProps };