@lumx/react 4.2.1-alpha.0 → 4.2.1-alpha.2
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/README.md +1 -2
- package/index.d.ts +240 -156
- package/index.js +57 -37
- package/index.js.map +1 -1
- package/package.json +3 -3
package/index.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { Kind as Kind$1, HorizontalAlignment, Size as Size$1, ColorPalette as ColorPalette$1,
|
|
1
|
+
import { Kind as Kind$1, HorizontalAlignment as HorizontalAlignment$1, Size as Size$1, ColorPalette as ColorPalette$1, GenericProps as GenericProps$1, Orientation as Orientation$1, Alignment as Alignment$1, AspectRatio, ColorWithVariants as ColorWithVariants$1, ColorVariant as ColorVariant$1, Typography as Typography$1, Emphasis as Emphasis$1, GlobalSize, TypographyInterface as TypographyInterface$1, Theme as Theme$1 } from '@lumx/core/js/constants';
|
|
2
2
|
export * from '@lumx/core/js/constants';
|
|
3
3
|
import * as _lumx_core_js_types from '@lumx/core/js/types';
|
|
4
|
-
import { GenericProps
|
|
4
|
+
import { GenericProps, HasTheme as HasTheme$1, ValueOf, HasAriaDisabled as HasAriaDisabled$1, HasCloseMode, Falsy, HasClassName as HasClassName$1, HeadingElement as HeadingElement$1, HasRequiredLinkHref, HasAriaLabelOrLabelledBy } from '@lumx/core/js/types';
|
|
5
5
|
export * from '@lumx/core/js/types';
|
|
6
6
|
import * as React$1 from 'react';
|
|
7
|
-
import React__default, { Ref, ReactElement, ReactNode, SyntheticEvent, MouseEventHandler, KeyboardEventHandler, AriaAttributes, InputHTMLAttributes, RefObject,
|
|
7
|
+
import React__default, { Ref, ReactElement, ReactNode, SyntheticEvent, MouseEventHandler, KeyboardEventHandler, AriaAttributes, InputHTMLAttributes, RefObject, CSSProperties, ImgHTMLAttributes, SetStateAction, Key, ElementType, ComponentProps } from 'react';
|
|
8
|
+
import { GenericProps as GenericProps$2 } from '@lumx/core/js/utils/disabledState';
|
|
8
9
|
|
|
9
10
|
/** LumX Component Type. */
|
|
10
11
|
type Comp<P, T = HTMLElement> = {
|
|
@@ -68,7 +69,7 @@ declare const AlertDialog: Comp<AlertDialogProps, HTMLDivElement>;
|
|
|
68
69
|
/**
|
|
69
70
|
* Defines the props of the component.
|
|
70
71
|
*/
|
|
71
|
-
interface AutocompleteProps extends GenericProps
|
|
72
|
+
interface AutocompleteProps extends GenericProps, HasTheme$1 {
|
|
72
73
|
/**
|
|
73
74
|
* Whether the suggestions list should display anchored to the input or to the wrapper.
|
|
74
75
|
* @see {@link DropdownProps#anchorToInput}
|
|
@@ -241,7 +242,7 @@ interface AutocompleteMultipleProps extends AutocompleteProps {
|
|
|
241
242
|
/** Selected values. */
|
|
242
243
|
values: any[];
|
|
243
244
|
/** Alignment of the chips in the autocomplete. */
|
|
244
|
-
chipsAlignment?: HorizontalAlignment;
|
|
245
|
+
chipsAlignment?: HorizontalAlignment$1;
|
|
245
246
|
/** Selected value render function. Default: Renders the value inside of a Chip. */
|
|
246
247
|
selectedChipRender(choice: any, index: number, onClear?: (event: React.MouseEvent, val: any) => void, isDisabled?: boolean): ReactNode | string;
|
|
247
248
|
}
|
|
@@ -261,7 +262,7 @@ type AvatarSize = Extract<Size$1, 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'>
|
|
|
261
262
|
/**
|
|
262
263
|
* Defines the props of the component.
|
|
263
264
|
*/
|
|
264
|
-
interface AvatarProps extends GenericProps
|
|
265
|
+
interface AvatarProps extends GenericProps, HasTheme$1 {
|
|
265
266
|
/** Action toolbar content. */
|
|
266
267
|
actions?: ReactNode;
|
|
267
268
|
/** Image alternative text. */
|
|
@@ -295,7 +296,7 @@ declare const Avatar: Comp<AvatarProps, HTMLDivElement>;
|
|
|
295
296
|
/**
|
|
296
297
|
* Defines the props of the component.
|
|
297
298
|
*/
|
|
298
|
-
interface BadgeProps extends GenericProps
|
|
299
|
+
interface BadgeProps extends GenericProps {
|
|
299
300
|
/** Badge content. */
|
|
300
301
|
children?: ReactNode;
|
|
301
302
|
/** Color variant. */
|
|
@@ -310,7 +311,7 @@ interface BadgeProps extends GenericProps$1 {
|
|
|
310
311
|
*/
|
|
311
312
|
declare const Badge: Comp<BadgeProps, HTMLDivElement>;
|
|
312
313
|
|
|
313
|
-
interface BadgeWrapperProps extends GenericProps
|
|
314
|
+
interface BadgeWrapperProps extends GenericProps {
|
|
314
315
|
/** Badge. */
|
|
315
316
|
badge: ReactElement;
|
|
316
317
|
/** Node to display the badge on */
|
|
@@ -318,6 +319,24 @@ interface BadgeWrapperProps extends GenericProps$1 {
|
|
|
318
319
|
}
|
|
319
320
|
declare const BadgeWrapper: Comp<BadgeWrapperProps, HTMLDivElement>;
|
|
320
321
|
|
|
322
|
+
/**
|
|
323
|
+
* Alignments.
|
|
324
|
+
*/
|
|
325
|
+
declare const Alignment: {
|
|
326
|
+
readonly bottom: "bottom";
|
|
327
|
+
readonly center: "center";
|
|
328
|
+
readonly end: "end";
|
|
329
|
+
readonly left: "left";
|
|
330
|
+
readonly right: "right";
|
|
331
|
+
readonly spaceAround: "space-around";
|
|
332
|
+
readonly spaceBetween: "space-between";
|
|
333
|
+
readonly spaceEvenly: "space-evenly";
|
|
334
|
+
readonly start: "start";
|
|
335
|
+
readonly top: "top";
|
|
336
|
+
};
|
|
337
|
+
type Alignment = ValueOf<typeof Alignment>;
|
|
338
|
+
type VerticalAlignment = Extract<Alignment, 'top' | 'center' | 'bottom'>;
|
|
339
|
+
type HorizontalAlignment = Extract<Alignment, 'right' | 'center' | 'left'>;
|
|
321
340
|
declare const Theme: {
|
|
322
341
|
readonly light: "light";
|
|
323
342
|
readonly dark: "dark";
|
|
@@ -338,6 +357,11 @@ declare const Size: {
|
|
|
338
357
|
readonly huge: "huge";
|
|
339
358
|
};
|
|
340
359
|
type Size = ValueOf<typeof Size>;
|
|
360
|
+
declare const Orientation: {
|
|
361
|
+
readonly horizontal: "horizontal";
|
|
362
|
+
readonly vertical: "vertical";
|
|
363
|
+
};
|
|
364
|
+
type Orientation = ValueOf<typeof Orientation>;
|
|
341
365
|
declare const Emphasis: {
|
|
342
366
|
readonly low: "low";
|
|
343
367
|
readonly medium: "medium";
|
|
@@ -476,16 +500,12 @@ interface HasTheme {
|
|
|
476
500
|
}
|
|
477
501
|
|
|
478
502
|
/**
|
|
479
|
-
*
|
|
503
|
+
* Framework-agnostic type for renderable content.
|
|
504
|
+
* Vue components should cast VNode[] from slots to this type.
|
|
505
|
+
*
|
|
506
|
+
* Note: Uses type-only import to avoid runtime dependencies.
|
|
480
507
|
*/
|
|
481
|
-
|
|
482
|
-
/**
|
|
483
|
-
* Any prop (particularly any supported prop for a HTML element).
|
|
484
|
-
*/
|
|
485
|
-
[propName: string]: any;
|
|
486
|
-
}
|
|
487
|
-
|
|
488
|
-
type JSXElement = boolean | number | string | React__default.JSX.Element | React__default.ReactNode | Iterable<JSXElement> | undefined | null;
|
|
508
|
+
type JSXElement = React__default.ReactNode;
|
|
489
509
|
|
|
490
510
|
/** Union type of all heading elements */
|
|
491
511
|
type HeadingElement = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
|
|
@@ -499,6 +519,8 @@ type KebabCase<S> = S extends `${infer C}${infer T}` ? T extends Uncapitalize<T>
|
|
|
499
519
|
/** Transform the component name into the lumx class name. */
|
|
500
520
|
type LumxClassName<TComponentName extends string> = `lumx-${KebabCase<TComponentName>}`;
|
|
501
521
|
|
|
522
|
+
type CommonRef = any;
|
|
523
|
+
|
|
502
524
|
type Booleanish = boolean | 'true' | 'false';
|
|
503
525
|
|
|
504
526
|
interface HasAriaDisabled {
|
|
@@ -506,11 +528,20 @@ interface HasAriaDisabled {
|
|
|
506
528
|
'aria-disabled'?: Booleanish;
|
|
507
529
|
}
|
|
508
530
|
|
|
531
|
+
type BaseClickableProps = {
|
|
532
|
+
children?: JSXElement;
|
|
533
|
+
isDisabled?: boolean;
|
|
534
|
+
disabled?: boolean;
|
|
535
|
+
'aria-disabled'?: Booleanish;
|
|
536
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
537
|
+
ref?: CommonRef;
|
|
538
|
+
};
|
|
539
|
+
|
|
509
540
|
/**
|
|
510
541
|
* Button size definition.
|
|
511
542
|
*/
|
|
512
543
|
type ButtonSize = Extract<Size, 's' | 'm'>;
|
|
513
|
-
interface BaseButtonProps extends
|
|
544
|
+
interface BaseButtonProps extends Pick<AriaAttributes, 'aria-expanded' | 'aria-haspopup' | 'aria-pressed' | 'aria-label'>, HasClassName, HasTheme, HasAriaDisabled, BaseClickableProps {
|
|
514
545
|
/** Color variant. */
|
|
515
546
|
color?: ColorPalette;
|
|
516
547
|
/** Emphasis variant. */
|
|
@@ -533,6 +564,14 @@ interface BaseButtonProps extends GenericProps, Pick<AriaAttributes, 'aria-expan
|
|
|
533
564
|
type?: 'submit' | 'reset' | 'button' | undefined;
|
|
534
565
|
/** Custom component for the link (can be used to inject router Link). */
|
|
535
566
|
linkAs?: 'a' | any;
|
|
567
|
+
/** whether the button is dispalyed in full width or not */
|
|
568
|
+
fullWidth?: boolean;
|
|
569
|
+
/** whether the button is currently active or not */
|
|
570
|
+
isActive?: boolean;
|
|
571
|
+
/** whether the button is currently focused or not */
|
|
572
|
+
isFocused?: boolean;
|
|
573
|
+
/** whether the button is currently focused or not */
|
|
574
|
+
isHovered?: boolean;
|
|
536
575
|
}
|
|
537
576
|
|
|
538
577
|
/**
|
|
@@ -547,7 +586,7 @@ declare const ButtonEmphasis: {
|
|
|
547
586
|
/**
|
|
548
587
|
* Defines the props of the component.
|
|
549
588
|
*/
|
|
550
|
-
interface ButtonProps extends /* @vue-ignore */ BaseButtonProps {
|
|
589
|
+
interface ButtonProps$1 extends /* @vue-ignore */ BaseButtonProps {
|
|
551
590
|
/** Left icon (SVG path). */
|
|
552
591
|
leftIcon?: string;
|
|
553
592
|
/** Right icon (SVG path). */
|
|
@@ -568,8 +607,10 @@ declare const CLASSNAME: LumxClassName<typeof COMPONENT_NAME>;
|
|
|
568
607
|
/**
|
|
569
608
|
* Component default props.
|
|
570
609
|
*/
|
|
571
|
-
declare const DEFAULT_PROPS: Partial<ButtonProps>;
|
|
610
|
+
declare const DEFAULT_PROPS: Partial<ButtonProps$1>;
|
|
572
611
|
|
|
612
|
+
interface ButtonProps extends ButtonProps$1, GenericProps$1 {
|
|
613
|
+
}
|
|
573
614
|
/**
|
|
574
615
|
* Button component.
|
|
575
616
|
*
|
|
@@ -579,7 +620,7 @@ declare const DEFAULT_PROPS: Partial<ButtonProps>;
|
|
|
579
620
|
*/
|
|
580
621
|
declare const Button: Comp<ButtonProps, HTMLButtonElement | HTMLAnchorElement>;
|
|
581
622
|
|
|
582
|
-
interface IconButtonProps$1 extends
|
|
623
|
+
interface IconButtonProps$1 extends BaseButtonProps {
|
|
583
624
|
/**
|
|
584
625
|
* Icon (SVG path).
|
|
585
626
|
* If `image` is also set, `image` will be used instead.
|
|
@@ -595,9 +636,13 @@ interface IconButtonProps$1 extends /* @vue-ignore */ BaseButtonProps {
|
|
|
595
636
|
* If you really don't want an aria-label, you can set an empty label (this is not recommended).
|
|
596
637
|
*/
|
|
597
638
|
label: string;
|
|
639
|
+
/**
|
|
640
|
+
* optional text to be displayed as the title of the HTML element
|
|
641
|
+
*/
|
|
642
|
+
title?: string;
|
|
598
643
|
}
|
|
599
644
|
|
|
600
|
-
interface IconButtonProps extends IconButtonProps$1 {
|
|
645
|
+
interface IconButtonProps extends IconButtonProps$1, GenericProps$1 {
|
|
601
646
|
/**
|
|
602
647
|
* Props to pass to the tooltip.
|
|
603
648
|
* If undefined or if tooltipProps.label is undefined, the label prop will be used as tooltip label.
|
|
@@ -618,13 +663,17 @@ declare const IconButton: Comp<IconButtonProps, HTMLButtonElement>;
|
|
|
618
663
|
/**
|
|
619
664
|
* Defines the props of the component
|
|
620
665
|
*/
|
|
621
|
-
interface ButtonGroupProps extends
|
|
666
|
+
interface ButtonGroupProps$1 extends HasClassName {
|
|
622
667
|
/**
|
|
623
668
|
* Children
|
|
624
669
|
*/
|
|
625
670
|
children?: JSXElement;
|
|
671
|
+
/** reference to the root element */
|
|
672
|
+
ref?: CommonRef;
|
|
626
673
|
}
|
|
627
674
|
|
|
675
|
+
interface ButtonGroupProps extends ButtonGroupProps$1, GenericProps {
|
|
676
|
+
}
|
|
628
677
|
/**
|
|
629
678
|
* ButtonGroup component.
|
|
630
679
|
*
|
|
@@ -637,7 +686,7 @@ declare const ButtonGroup: Comp<ButtonGroupProps, HTMLDivElement>;
|
|
|
637
686
|
/**
|
|
638
687
|
* Defines the props of the component.
|
|
639
688
|
*/
|
|
640
|
-
interface CheckboxProps extends GenericProps
|
|
689
|
+
interface CheckboxProps extends GenericProps, HasTheme$1, HasAriaDisabled$1 {
|
|
641
690
|
/** Helper text. */
|
|
642
691
|
helper?: string;
|
|
643
692
|
/** Native input id property. */
|
|
@@ -675,7 +724,7 @@ type ChipSize = Extract<Size$1, 's' | 'm'>;
|
|
|
675
724
|
/**
|
|
676
725
|
* Defines the props of the component.
|
|
677
726
|
*/
|
|
678
|
-
interface ChipProps extends GenericProps
|
|
727
|
+
interface ChipProps extends GenericProps, HasTheme$1, HasAriaDisabled$1 {
|
|
679
728
|
/** A component to be rendered after the content. */
|
|
680
729
|
after?: ReactNode;
|
|
681
730
|
/** A component to be rendered before the content. */
|
|
@@ -721,12 +770,12 @@ type useChipGroupNavigationType<C = any> = (chips: C[], onChipDeleted: (chip: C)
|
|
|
721
770
|
/**
|
|
722
771
|
* Defines the props of the component.
|
|
723
772
|
*/
|
|
724
|
-
interface ChipGroupProps extends GenericProps
|
|
773
|
+
interface ChipGroupProps extends GenericProps {
|
|
725
774
|
/**
|
|
726
775
|
* Chip horizontal alignment.
|
|
727
776
|
* @deprecated
|
|
728
777
|
*/
|
|
729
|
-
align?: HorizontalAlignment;
|
|
778
|
+
align?: HorizontalAlignment$1;
|
|
730
779
|
/** List of Chip. */
|
|
731
780
|
children: ReactNode;
|
|
732
781
|
}
|
|
@@ -745,7 +794,7 @@ type CommentBlockVariant = ValueOf<typeof CommentBlockVariant>;
|
|
|
745
794
|
/**
|
|
746
795
|
* Defines the props of the component.
|
|
747
796
|
*/
|
|
748
|
-
interface CommentBlockProps extends GenericProps
|
|
797
|
+
interface CommentBlockProps extends GenericProps, HasTheme$1 {
|
|
749
798
|
/** Action toolbar content. */
|
|
750
799
|
actions?: ReactNode;
|
|
751
800
|
/** Props to pass to the avatar. */
|
|
@@ -798,7 +847,7 @@ declare const CommentBlock: Comp<CommentBlockProps, HTMLDivElement>;
|
|
|
798
847
|
/**
|
|
799
848
|
* Defines the props of the component.
|
|
800
849
|
*/
|
|
801
|
-
interface DatePickerProps extends GenericProps
|
|
850
|
+
interface DatePickerProps extends GenericProps {
|
|
802
851
|
/** Default month. */
|
|
803
852
|
defaultMonth?: Date;
|
|
804
853
|
/** Locale (language or region) to use. */
|
|
@@ -853,7 +902,7 @@ declare const DatePickerControlled: Comp<DatePickerControlledProps, HTMLDivEleme
|
|
|
853
902
|
/**
|
|
854
903
|
* Defines the props of the component.
|
|
855
904
|
*/
|
|
856
|
-
interface DatePickerFieldProps extends Omit<TextFieldProps, 'value' | 'onChange'>, GenericProps
|
|
905
|
+
interface DatePickerFieldProps extends Omit<TextFieldProps, 'value' | 'onChange'>, GenericProps {
|
|
857
906
|
/** Default month. */
|
|
858
907
|
defaultMonth?: Date;
|
|
859
908
|
/** Locale (language or region) to use. */
|
|
@@ -883,7 +932,7 @@ declare const DatePickerField: Comp<DatePickerFieldProps, HTMLDivElement>;
|
|
|
883
932
|
/**
|
|
884
933
|
* Defines the props of the component.
|
|
885
934
|
*/
|
|
886
|
-
interface DialogProps extends GenericProps
|
|
935
|
+
interface DialogProps extends GenericProps {
|
|
887
936
|
/** Footer content. */
|
|
888
937
|
footer?: ReactNode;
|
|
889
938
|
/** Whether the divider between the dialog content and the footer is always displayed (instead of showing it on scroll). */
|
|
@@ -913,7 +962,7 @@ interface DialogProps extends GenericProps$1 {
|
|
|
913
962
|
/** Z-axis position. */
|
|
914
963
|
zIndex?: number;
|
|
915
964
|
/** Z-axis position. */
|
|
916
|
-
dialogProps?: GenericProps
|
|
965
|
+
dialogProps?: GenericProps;
|
|
917
966
|
/** On close callback. */
|
|
918
967
|
onClose?(): void;
|
|
919
968
|
/** Callback called when the open animation starts and the close animation finishes. */
|
|
@@ -936,7 +985,7 @@ declare const Dialog: Comp<DialogProps, HTMLDivElement>;
|
|
|
936
985
|
/**
|
|
937
986
|
* Defines the props of the component.
|
|
938
987
|
*/
|
|
939
|
-
interface DividerProps extends GenericProps
|
|
988
|
+
interface DividerProps extends GenericProps, HasTheme$1 {
|
|
940
989
|
}
|
|
941
990
|
/**
|
|
942
991
|
* Divider component.
|
|
@@ -950,7 +999,7 @@ declare const Divider: Comp<DividerProps, HTMLHRElement>;
|
|
|
950
999
|
/**
|
|
951
1000
|
* Defines the props of the component.
|
|
952
1001
|
*/
|
|
953
|
-
interface DragHandleProps extends GenericProps
|
|
1002
|
+
interface DragHandleProps extends GenericProps, HasTheme$1 {
|
|
954
1003
|
}
|
|
955
1004
|
/**
|
|
956
1005
|
* DragHandle component.
|
|
@@ -1008,7 +1057,7 @@ type FitAnchorWidth = ValueOf<typeof FitAnchorWidth>;
|
|
|
1008
1057
|
/**
|
|
1009
1058
|
* Defines the props of the component.
|
|
1010
1059
|
*/
|
|
1011
|
-
interface PopoverProps extends GenericProps
|
|
1060
|
+
interface PopoverProps extends GenericProps, HasTheme$1 {
|
|
1012
1061
|
/** Reference to the DOM element used to set the position of the popover. */
|
|
1013
1062
|
anchorRef: React.RefObject<HTMLElement>;
|
|
1014
1063
|
/** Customize the root element. (Must accept ref forwarding and props forwarding!). */
|
|
@@ -1069,7 +1118,7 @@ declare const Popover: Comp<PopoverProps, HTMLDivElement>;
|
|
|
1069
1118
|
/**
|
|
1070
1119
|
* Defines the props of the component.
|
|
1071
1120
|
*/
|
|
1072
|
-
interface DropdownProps extends GenericProps
|
|
1121
|
+
interface DropdownProps extends GenericProps {
|
|
1073
1122
|
/**
|
|
1074
1123
|
* Reference to the element around which the dropdown is placed.
|
|
1075
1124
|
* @see {@link PopoverProps#anchorRef}
|
|
@@ -1150,7 +1199,7 @@ declare const Dropdown: Comp<DropdownProps, HTMLDivElement>;
|
|
|
1150
1199
|
/**
|
|
1151
1200
|
* Defines the props of the component.
|
|
1152
1201
|
*/
|
|
1153
|
-
interface ExpansionPanelProps extends GenericProps
|
|
1202
|
+
interface ExpansionPanelProps extends GenericProps, HasCloseMode, HasTheme$1 {
|
|
1154
1203
|
/** Whether the expansion panel has a background. */
|
|
1155
1204
|
hasBackground?: boolean;
|
|
1156
1205
|
/** Whether the header has a divider. */
|
|
@@ -1179,7 +1228,54 @@ interface ExpansionPanelProps extends GenericProps$1, HasCloseMode, HasTheme$1 {
|
|
|
1179
1228
|
*/
|
|
1180
1229
|
declare const ExpansionPanel: Comp<ExpansionPanelProps, HTMLDivElement>;
|
|
1181
1230
|
|
|
1182
|
-
|
|
1231
|
+
/**
|
|
1232
|
+
* Defines the props of the component.
|
|
1233
|
+
*/
|
|
1234
|
+
interface TextProps$1 extends HasClassName {
|
|
1235
|
+
/**
|
|
1236
|
+
* Color variant.
|
|
1237
|
+
*/
|
|
1238
|
+
color?: ColorWithVariants;
|
|
1239
|
+
/**
|
|
1240
|
+
* Lightened or darkened variant of the selected color.
|
|
1241
|
+
*/
|
|
1242
|
+
colorVariant?: ColorVariant;
|
|
1243
|
+
/**
|
|
1244
|
+
* Typography variant.
|
|
1245
|
+
*/
|
|
1246
|
+
typography?: Typography;
|
|
1247
|
+
/**
|
|
1248
|
+
* Custom component to render the text.
|
|
1249
|
+
*/
|
|
1250
|
+
as: TextElement;
|
|
1251
|
+
/**
|
|
1252
|
+
* Control whether the text should truncate or not.
|
|
1253
|
+
* Setting as `true` will make the text truncate on a single line.
|
|
1254
|
+
* Setting as `{ lines: number }` will make the text truncate on a multiple lines.
|
|
1255
|
+
*/
|
|
1256
|
+
truncate?: boolean | {
|
|
1257
|
+
lines: number;
|
|
1258
|
+
};
|
|
1259
|
+
/**
|
|
1260
|
+
* Prevents text to wrap on multiple lines
|
|
1261
|
+
* (automatically activated when single line text truncate is activated).
|
|
1262
|
+
*/
|
|
1263
|
+
noWrap?: boolean;
|
|
1264
|
+
/**
|
|
1265
|
+
* WhiteSpace variant
|
|
1266
|
+
* Ignored when `noWrap` is set to true
|
|
1267
|
+
* Ignored when `truncate` is set to true or lines: 1
|
|
1268
|
+
* */
|
|
1269
|
+
whiteSpace?: WhiteSpace;
|
|
1270
|
+
/**
|
|
1271
|
+
* Children
|
|
1272
|
+
*/
|
|
1273
|
+
children?: JSXElement;
|
|
1274
|
+
/** list of styles to apply */
|
|
1275
|
+
style?: CSSProperties;
|
|
1276
|
+
}
|
|
1277
|
+
|
|
1278
|
+
interface FlagProps$1 extends HasClassName, HasTheme {
|
|
1183
1279
|
/** Color of the component. */
|
|
1184
1280
|
color?: ColorPalette;
|
|
1185
1281
|
/** Icon to use before the label. */
|
|
@@ -1188,9 +1284,13 @@ interface FlagProps$1 extends GenericProps, HasTheme {
|
|
|
1188
1284
|
children: JSXElement;
|
|
1189
1285
|
/** Enable text truncate on overflow */
|
|
1190
1286
|
truncate?: boolean;
|
|
1287
|
+
/** ref to the root element */
|
|
1288
|
+
ref?: CommonRef;
|
|
1289
|
+
/** Text component to use for rendering the label */
|
|
1290
|
+
Text: (props: TextProps$1) => any;
|
|
1191
1291
|
}
|
|
1192
1292
|
|
|
1193
|
-
interface FlagProps extends Omit<FlagProps$1, 'children'> {
|
|
1293
|
+
interface FlagProps extends GenericProps$1, Omit<FlagProps$1, 'children' | 'Text'> {
|
|
1194
1294
|
label: React.ReactNode;
|
|
1195
1295
|
}
|
|
1196
1296
|
/**
|
|
@@ -1203,18 +1303,17 @@ interface FlagProps extends Omit<FlagProps$1, 'children'> {
|
|
|
1203
1303
|
declare const Flag: Comp<FlagProps, HTMLDivElement>;
|
|
1204
1304
|
|
|
1205
1305
|
type MarginAutoAlignment = Extract<Alignment, 'top' | 'bottom' | 'right' | 'left'>;
|
|
1206
|
-
type GapSize = Extract<Size
|
|
1306
|
+
type GapSize = Extract<Size, 'tiny' | 'regular' | 'medium' | 'big' | 'huge'>;
|
|
1207
1307
|
type SpaceAlignment = Extract<Alignment, 'space-between' | 'space-evenly' | 'space-around'>;
|
|
1208
1308
|
type FlexVerticalAlignment = VerticalAlignment | SpaceAlignment;
|
|
1209
1309
|
type FlexHorizontalAlignment = HorizontalAlignment | SpaceAlignment;
|
|
1310
|
+
|
|
1210
1311
|
/**
|
|
1211
1312
|
* Defines the props of the component.
|
|
1212
1313
|
*/
|
|
1213
|
-
interface FlexBoxProps extends
|
|
1214
|
-
/** Customize the root element. */
|
|
1215
|
-
as?: React.ElementType;
|
|
1314
|
+
interface FlexBoxProps$1 extends HasClassName {
|
|
1216
1315
|
/** Children elements. */
|
|
1217
|
-
children?:
|
|
1316
|
+
children?: JSXElement;
|
|
1218
1317
|
/** Whether the "content filling space" is enabled or not. */
|
|
1219
1318
|
fillSpace?: boolean;
|
|
1220
1319
|
/** Gap space between flexbox items. */
|
|
@@ -1232,6 +1331,14 @@ interface FlexBoxProps extends GenericProps$1 {
|
|
|
1232
1331
|
/** Whether the "flex wrap" is enabled or not. */
|
|
1233
1332
|
wrap?: boolean;
|
|
1234
1333
|
}
|
|
1334
|
+
|
|
1335
|
+
/**
|
|
1336
|
+
* Defines the props of the component.
|
|
1337
|
+
*/
|
|
1338
|
+
interface FlexBoxProps extends FlexBoxProps$1, GenericProps {
|
|
1339
|
+
/** Customize the root element. */
|
|
1340
|
+
as?: React__default.ElementType;
|
|
1341
|
+
}
|
|
1235
1342
|
/**
|
|
1236
1343
|
* FlexBox component.
|
|
1237
1344
|
*
|
|
@@ -1345,58 +1452,15 @@ declare const GenericBlock: GenericBlock;
|
|
|
1345
1452
|
/**
|
|
1346
1453
|
* Defines the props of the component.
|
|
1347
1454
|
*/
|
|
1348
|
-
interface
|
|
1349
|
-
/**
|
|
1350
|
-
* Color variant.
|
|
1351
|
-
*/
|
|
1352
|
-
color?: ColorWithVariants;
|
|
1353
|
-
/**
|
|
1354
|
-
* Lightened or darkened variant of the selected color.
|
|
1355
|
-
*/
|
|
1356
|
-
colorVariant?: ColorVariant;
|
|
1357
|
-
/**
|
|
1358
|
-
* Typography variant.
|
|
1359
|
-
*/
|
|
1360
|
-
typography?: Typography;
|
|
1361
|
-
/**
|
|
1362
|
-
* Custom component to render the text.
|
|
1363
|
-
*/
|
|
1364
|
-
as: TextElement;
|
|
1365
|
-
/**
|
|
1366
|
-
* Control whether the text should truncate or not.
|
|
1367
|
-
* Setting as `true` will make the text truncate on a single line.
|
|
1368
|
-
* Setting as `{ lines: number }` will make the text truncate on a multiple lines.
|
|
1369
|
-
*/
|
|
1370
|
-
truncate?: boolean | {
|
|
1371
|
-
lines: number;
|
|
1372
|
-
};
|
|
1373
|
-
/**
|
|
1374
|
-
* Prevents text to wrap on multiple lines
|
|
1375
|
-
* (automatically activated when single line text truncate is activated).
|
|
1376
|
-
*/
|
|
1377
|
-
noWrap?: boolean;
|
|
1378
|
-
/**
|
|
1379
|
-
* WhiteSpace variant
|
|
1380
|
-
* Ignored when `noWrap` is set to true
|
|
1381
|
-
* Ignored when `truncate` is set to true or lines: 1
|
|
1382
|
-
* */
|
|
1383
|
-
whiteSpace?: WhiteSpace;
|
|
1384
|
-
/**
|
|
1385
|
-
* Children
|
|
1386
|
-
*/
|
|
1387
|
-
children?: JSXElement;
|
|
1388
|
-
}
|
|
1389
|
-
|
|
1390
|
-
/**
|
|
1391
|
-
* Defines the props of the component.
|
|
1392
|
-
*/
|
|
1393
|
-
interface HeadingProps extends Partial<TextProps> {
|
|
1455
|
+
interface HeadingProps$1 extends Partial<TextProps$1> {
|
|
1394
1456
|
/**
|
|
1395
1457
|
* Display a specific heading level instead of the one provided by parent context provider.
|
|
1396
1458
|
*/
|
|
1397
1459
|
as?: HeadingElement;
|
|
1398
1460
|
}
|
|
1399
1461
|
|
|
1462
|
+
interface HeadingProps extends HeadingProps$1, GenericProps {
|
|
1463
|
+
}
|
|
1400
1464
|
/**
|
|
1401
1465
|
* Renders a heading component.
|
|
1402
1466
|
* Extends the `Text` Component with the heading level automatically computed based on
|
|
@@ -1424,15 +1488,15 @@ type GridGutterSize = Extract<Size$1, 'regular' | 'big' | 'huge'>;
|
|
|
1424
1488
|
/**
|
|
1425
1489
|
* Defines the props of the component.
|
|
1426
1490
|
*/
|
|
1427
|
-
interface GridProps extends GenericProps
|
|
1491
|
+
interface GridProps extends GenericProps {
|
|
1428
1492
|
/** Orientation. */
|
|
1429
|
-
orientation?: Orientation;
|
|
1493
|
+
orientation?: Orientation$1;
|
|
1430
1494
|
/** Whether the children are wrapped or not. */
|
|
1431
1495
|
wrap?: string;
|
|
1432
1496
|
/** Vertical alignment. */
|
|
1433
|
-
vAlign?: Alignment;
|
|
1497
|
+
vAlign?: Alignment$1;
|
|
1434
1498
|
/** Horizontal alignment. */
|
|
1435
|
-
hAlign?: Alignment;
|
|
1499
|
+
hAlign?: Alignment$1;
|
|
1436
1500
|
/** Gutter size. */
|
|
1437
1501
|
gutter?: GridGutterSize;
|
|
1438
1502
|
/** Children */
|
|
@@ -1451,9 +1515,9 @@ type Columns = '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11'
|
|
|
1451
1515
|
/**
|
|
1452
1516
|
* Defines the props of the component.
|
|
1453
1517
|
*/
|
|
1454
|
-
interface GridItemProps extends GenericProps
|
|
1518
|
+
interface GridItemProps extends GenericProps {
|
|
1455
1519
|
/** Alignment. */
|
|
1456
|
-
align?: Alignment;
|
|
1520
|
+
align?: Alignment$1;
|
|
1457
1521
|
/** Order. */
|
|
1458
1522
|
order?: Columns;
|
|
1459
1523
|
/** Width. */
|
|
@@ -1474,7 +1538,7 @@ type GridColumnGapSize = Extract<Size$1, 'tiny' | 'regular' | 'big' | 'huge'>;
|
|
|
1474
1538
|
/**
|
|
1475
1539
|
* Defines the props of the component.
|
|
1476
1540
|
*/
|
|
1477
|
-
interface GridColumnProps extends GenericProps
|
|
1541
|
+
interface GridColumnProps extends GenericProps {
|
|
1478
1542
|
/** Customize the root element. */
|
|
1479
1543
|
as?: React.ElementType;
|
|
1480
1544
|
/** Children elements. */
|
|
@@ -1503,7 +1567,7 @@ type IconSizes = (typeof ICON_SIZES)[number];
|
|
|
1503
1567
|
/**
|
|
1504
1568
|
* Defines the props of the component.
|
|
1505
1569
|
*/
|
|
1506
|
-
interface IconProps extends
|
|
1570
|
+
interface IconProps$1 extends HasClassName, HasTheme {
|
|
1507
1571
|
/** Color variant. */
|
|
1508
1572
|
color?: ColorWithVariants;
|
|
1509
1573
|
/** Lightened or darkened variant of the selected icon color. */
|
|
@@ -1521,8 +1585,12 @@ interface IconProps extends GenericProps, HasTheme {
|
|
|
1521
1585
|
alt?: string;
|
|
1522
1586
|
/** Vertical alignment of the icon (only applies for icons nested in Text/Heading). */
|
|
1523
1587
|
verticalAlign?: null | 'middle';
|
|
1588
|
+
/** reference to the root element */
|
|
1589
|
+
ref?: CommonRef;
|
|
1524
1590
|
}
|
|
1525
1591
|
|
|
1592
|
+
interface IconProps extends IconProps$1, GenericProps {
|
|
1593
|
+
}
|
|
1526
1594
|
/**
|
|
1527
1595
|
* Icon component.
|
|
1528
1596
|
*
|
|
@@ -1579,9 +1647,9 @@ type ImgHTMLProps = ImgHTMLAttributes<HTMLImageElement>;
|
|
|
1579
1647
|
/**
|
|
1580
1648
|
* Defines the props of the component.
|
|
1581
1649
|
*/
|
|
1582
|
-
interface ThumbnailProps extends GenericProps
|
|
1650
|
+
interface ThumbnailProps extends GenericProps, HasTheme$1 {
|
|
1583
1651
|
/** Alignment of the thumbnail in it's parent (requires flex parent). */
|
|
1584
|
-
align?: HorizontalAlignment;
|
|
1652
|
+
align?: HorizontalAlignment$1;
|
|
1585
1653
|
/** Image alternative text. */
|
|
1586
1654
|
alt: string;
|
|
1587
1655
|
/** Image aspect ratio. */
|
|
@@ -1665,11 +1733,11 @@ type ImageBlockSize = Extract<Size$1, 'xl' | 'xxl'>;
|
|
|
1665
1733
|
/**
|
|
1666
1734
|
* Defines the props of the component.
|
|
1667
1735
|
*/
|
|
1668
|
-
interface ImageBlockProps extends GenericProps
|
|
1736
|
+
interface ImageBlockProps extends GenericProps, HasTheme$1, ImageCaptionMetadata {
|
|
1669
1737
|
/** Action toolbar content. */
|
|
1670
1738
|
actions?: ReactNode;
|
|
1671
1739
|
/** Alignment. */
|
|
1672
|
-
align?: HorizontalAlignment;
|
|
1740
|
+
align?: HorizontalAlignment$1;
|
|
1673
1741
|
/** Image alternative text. */
|
|
1674
1742
|
alt: string;
|
|
1675
1743
|
/** Caption position. */
|
|
@@ -1757,7 +1825,7 @@ declare const ImageLightbox: Comp<ImageLightboxProps, HTMLDivElement> & {
|
|
|
1757
1825
|
/**
|
|
1758
1826
|
* Defines the props of the component.
|
|
1759
1827
|
*/
|
|
1760
|
-
interface InlineListProps extends GenericProps
|
|
1828
|
+
interface InlineListProps extends GenericProps {
|
|
1761
1829
|
/**
|
|
1762
1830
|
* Text color.
|
|
1763
1831
|
*/
|
|
@@ -1791,13 +1859,17 @@ declare const InlineList: Comp<InlineListProps, HTMLElement>;
|
|
|
1791
1859
|
/**
|
|
1792
1860
|
* Defines the props of the component.
|
|
1793
1861
|
*/
|
|
1794
|
-
interface InputHelperProps extends
|
|
1862
|
+
interface InputHelperProps$1 extends HasClassName, HasTheme {
|
|
1795
1863
|
/** Helper content. */
|
|
1796
1864
|
children: JSXElement;
|
|
1797
1865
|
/** Helper variant. */
|
|
1798
1866
|
kind?: Kind;
|
|
1867
|
+
/** ref to the root element `p` */
|
|
1868
|
+
ref?: CommonRef;
|
|
1799
1869
|
}
|
|
1800
1870
|
|
|
1871
|
+
interface InputHelperProps extends InputHelperProps$1, GenericProps$2 {
|
|
1872
|
+
}
|
|
1801
1873
|
/**
|
|
1802
1874
|
* InputHelper component.
|
|
1803
1875
|
*
|
|
@@ -1807,7 +1879,7 @@ interface InputHelperProps extends GenericProps, HasTheme {
|
|
|
1807
1879
|
*/
|
|
1808
1880
|
declare const InputHelper: Comp<InputHelperProps, HTMLParagraphElement>;
|
|
1809
1881
|
|
|
1810
|
-
interface InputLabelProps extends
|
|
1882
|
+
interface InputLabelProps$1 extends HasClassName, HasTheme {
|
|
1811
1883
|
/** Typography variant. */
|
|
1812
1884
|
typography?: Typography;
|
|
1813
1885
|
/** Label content. */
|
|
@@ -1816,8 +1888,12 @@ interface InputLabelProps extends GenericProps, HasTheme {
|
|
|
1816
1888
|
htmlFor: string;
|
|
1817
1889
|
/** Whether the component is required or not. */
|
|
1818
1890
|
isRequired?: boolean;
|
|
1891
|
+
/** ref to the root element */
|
|
1892
|
+
ref?: CommonRef;
|
|
1819
1893
|
}
|
|
1820
1894
|
|
|
1895
|
+
interface InputLabelProps extends InputLabelProps$1, GenericProps$1 {
|
|
1896
|
+
}
|
|
1821
1897
|
/**
|
|
1822
1898
|
* InputLabel component.
|
|
1823
1899
|
*
|
|
@@ -1830,7 +1906,7 @@ declare const InputLabel: Comp<InputLabelProps, HTMLLabelElement>;
|
|
|
1830
1906
|
/**
|
|
1831
1907
|
* Defines the props of the component.
|
|
1832
1908
|
*/
|
|
1833
|
-
interface LightboxProps extends GenericProps
|
|
1909
|
+
interface LightboxProps extends GenericProps, HasTheme$1, Pick<AriaAttributes, 'aria-label' | 'aria-labelledby'> {
|
|
1834
1910
|
/** Props to pass to the close button (minus those already set by the Lightbox props). */
|
|
1835
1911
|
closeButtonProps?: Pick<IconButtonProps, 'label'> & Omit<IconButtonProps, 'label' | 'onClick' | 'icon' | 'emphasis' | 'color'>;
|
|
1836
1912
|
/** Whether the component is open or not. */
|
|
@@ -1861,7 +1937,7 @@ type HTMLAnchorProps = React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAn
|
|
|
1861
1937
|
/**
|
|
1862
1938
|
* Defines the props of the component.
|
|
1863
1939
|
*/
|
|
1864
|
-
interface LinkProps extends GenericProps
|
|
1940
|
+
interface LinkProps extends GenericProps, HasAriaDisabled$1 {
|
|
1865
1941
|
/** Color variant. */
|
|
1866
1942
|
color?: ColorWithVariants$1;
|
|
1867
1943
|
/** Lightened or darkened variant of the selected icon color. */
|
|
@@ -1901,7 +1977,7 @@ declare const Link: Comp<LinkProps, HTMLButtonElement | HTMLAnchorElement>;
|
|
|
1901
1977
|
/**
|
|
1902
1978
|
* Defines the props of the component.
|
|
1903
1979
|
*/
|
|
1904
|
-
interface LinkPreviewProps extends GenericProps
|
|
1980
|
+
interface LinkPreviewProps extends GenericProps, HasTheme$1 {
|
|
1905
1981
|
/** Description. */
|
|
1906
1982
|
description?: string;
|
|
1907
1983
|
/** Link URL. */
|
|
@@ -1944,7 +2020,7 @@ type useKeyboardListNavigationType = <I>(items: I[], ref: RefObject<HTMLElement>
|
|
|
1944
2020
|
/**
|
|
1945
2021
|
* Defines the props of the component.
|
|
1946
2022
|
*/
|
|
1947
|
-
interface ListProps extends GenericProps
|
|
2023
|
+
interface ListProps extends GenericProps {
|
|
1948
2024
|
/** List content (should be ListItem, ListSubheader or ListDivider). */
|
|
1949
2025
|
children: ReactNode;
|
|
1950
2026
|
/**
|
|
@@ -1973,7 +2049,7 @@ type ListItemSize = Extract<Size$1, 'tiny' | 'regular' | 'big' | 'huge'>;
|
|
|
1973
2049
|
/**
|
|
1974
2050
|
* Defines the props of the component.
|
|
1975
2051
|
*/
|
|
1976
|
-
interface ListItemProps extends GenericProps
|
|
2052
|
+
interface ListItemProps extends GenericProps, HasAriaDisabled$1 {
|
|
1977
2053
|
/** A component to be rendered after the content. */
|
|
1978
2054
|
after?: ReactNode;
|
|
1979
2055
|
/** A component to be rendered before the content. */
|
|
@@ -2016,7 +2092,7 @@ declare const ListItem: Comp<ListItemProps, HTMLLIElement>;
|
|
|
2016
2092
|
/**
|
|
2017
2093
|
* Defines the props of the component.
|
|
2018
2094
|
*/
|
|
2019
|
-
type ListDividerProps = GenericProps
|
|
2095
|
+
type ListDividerProps = GenericProps;
|
|
2020
2096
|
/**
|
|
2021
2097
|
* ListDivider component.
|
|
2022
2098
|
*
|
|
@@ -2024,12 +2100,12 @@ type ListDividerProps = GenericProps$1;
|
|
|
2024
2100
|
* @param ref Component ref.
|
|
2025
2101
|
* @return React element.
|
|
2026
2102
|
*/
|
|
2027
|
-
declare const ListDivider: Comp<GenericProps
|
|
2103
|
+
declare const ListDivider: Comp<GenericProps, HTMLLIElement>;
|
|
2028
2104
|
|
|
2029
2105
|
/**
|
|
2030
2106
|
* Defines the props of the component.
|
|
2031
2107
|
*/
|
|
2032
|
-
interface ListSubheaderProps extends GenericProps
|
|
2108
|
+
interface ListSubheaderProps extends GenericProps {
|
|
2033
2109
|
/** Content. */
|
|
2034
2110
|
children: string | ReactNode;
|
|
2035
2111
|
}
|
|
@@ -2045,7 +2121,7 @@ declare const ListSubheader: Comp<ListSubheaderProps, HTMLLIElement>;
|
|
|
2045
2121
|
/**
|
|
2046
2122
|
* Defines the props of the component.
|
|
2047
2123
|
*/
|
|
2048
|
-
interface MessageProps extends
|
|
2124
|
+
interface MessageProps$1 extends HasClassName {
|
|
2049
2125
|
/** Content. */
|
|
2050
2126
|
children?: JSXElement;
|
|
2051
2127
|
/** Whether the message has a background or not. */
|
|
@@ -2054,6 +2130,8 @@ interface MessageProps extends GenericProps {
|
|
|
2054
2130
|
kind?: Kind;
|
|
2055
2131
|
/** Message custom icon SVG path. */
|
|
2056
2132
|
icon?: string;
|
|
2133
|
+
/** Reference to the message container element. */
|
|
2134
|
+
ref?: CommonRef;
|
|
2057
2135
|
/**
|
|
2058
2136
|
* Displays a close button.
|
|
2059
2137
|
*
|
|
@@ -2067,6 +2145,10 @@ interface MessageProps extends GenericProps {
|
|
|
2067
2145
|
};
|
|
2068
2146
|
}
|
|
2069
2147
|
|
|
2148
|
+
interface MessageProps extends Omit<MessageProps$1, 'children' | 'ref'> {
|
|
2149
|
+
/** Content. */
|
|
2150
|
+
children?: React.ReactNode;
|
|
2151
|
+
}
|
|
2070
2152
|
/**
|
|
2071
2153
|
* Message component.
|
|
2072
2154
|
*
|
|
@@ -2079,7 +2161,7 @@ declare const Message: Comp<MessageProps, HTMLDivElement>;
|
|
|
2079
2161
|
/**
|
|
2080
2162
|
* Defines the props of the component.
|
|
2081
2163
|
*/
|
|
2082
|
-
interface MosaicProps extends GenericProps
|
|
2164
|
+
interface MosaicProps extends GenericProps, HasTheme$1 {
|
|
2083
2165
|
/** Thumbnails. */
|
|
2084
2166
|
thumbnails: ThumbnailProps[];
|
|
2085
2167
|
/** On image click callback. */
|
|
@@ -2124,7 +2206,7 @@ declare const NavigationItem: (<E extends ElementType = "a">(props: React$1.Prop
|
|
|
2124
2206
|
type NavigationProps = React.ComponentProps<'nav'> & HasClassName$1 & HasTheme$1 & {
|
|
2125
2207
|
/** Content of the navigation. These components should be of type NavigationItem to be rendered */
|
|
2126
2208
|
children?: React.ReactNode;
|
|
2127
|
-
orientation?: Orientation;
|
|
2209
|
+
orientation?: Orientation$1;
|
|
2128
2210
|
} & HasAriaLabelOrLabelledBy;
|
|
2129
2211
|
type SubComponents = {
|
|
2130
2212
|
Section: typeof NavigationSection;
|
|
@@ -2135,7 +2217,7 @@ declare const Navigation: Comp<NavigationProps, HTMLElement> & SubComponents;
|
|
|
2135
2217
|
/**
|
|
2136
2218
|
* Defines the props of the component.
|
|
2137
2219
|
*/
|
|
2138
|
-
interface NotificationProps extends GenericProps
|
|
2220
|
+
interface NotificationProps extends GenericProps, HasTheme$1 {
|
|
2139
2221
|
/** Action button label. */
|
|
2140
2222
|
actionLabel?: string;
|
|
2141
2223
|
/** Content. */
|
|
@@ -2179,7 +2261,7 @@ declare const PopoverDialog: Comp<PopoverDialogProps, HTMLDivElement>;
|
|
|
2179
2261
|
/**
|
|
2180
2262
|
* Defines the props of the component.
|
|
2181
2263
|
*/
|
|
2182
|
-
interface PostBlockProps extends GenericProps
|
|
2264
|
+
interface PostBlockProps extends GenericProps, HasTheme$1 {
|
|
2183
2265
|
/** Action toolbar content. */
|
|
2184
2266
|
actions?: ReactNode;
|
|
2185
2267
|
/** Attachment content. */
|
|
@@ -2189,7 +2271,7 @@ interface PostBlockProps extends GenericProps$1, HasTheme$1 {
|
|
|
2189
2271
|
/** Metadata content. */
|
|
2190
2272
|
meta?: ReactNode;
|
|
2191
2273
|
/** Orientation. */
|
|
2192
|
-
orientation?: Orientation;
|
|
2274
|
+
orientation?: Orientation$1;
|
|
2193
2275
|
/** Tag content. */
|
|
2194
2276
|
tags?: ReactNode;
|
|
2195
2277
|
/** Content (string, or sanitized html). */
|
|
@@ -2223,7 +2305,7 @@ type ProgressVariant = ValueOf<typeof ProgressVariant>;
|
|
|
2223
2305
|
/**
|
|
2224
2306
|
* Defines the props of the component.
|
|
2225
2307
|
*/
|
|
2226
|
-
interface ProgressProps extends GenericProps
|
|
2308
|
+
interface ProgressProps extends GenericProps, HasTheme$1 {
|
|
2227
2309
|
/** Progress variant. */
|
|
2228
2310
|
variant?: ProgressVariant;
|
|
2229
2311
|
}
|
|
@@ -2244,7 +2326,7 @@ type ProgressCircularSize = Extract<Size$1, 'xxs' | 'xs' | 's' | 'm'>;
|
|
|
2244
2326
|
/**
|
|
2245
2327
|
* Defines the props of the component.
|
|
2246
2328
|
*/
|
|
2247
|
-
interface ProgressCircularProps extends GenericProps
|
|
2329
|
+
interface ProgressCircularProps extends GenericProps, HasTheme$1 {
|
|
2248
2330
|
/**
|
|
2249
2331
|
* Progress circular size.
|
|
2250
2332
|
*/
|
|
@@ -2264,7 +2346,7 @@ interface ProgressCircularProps extends GenericProps$1, HasTheme$1 {
|
|
|
2264
2346
|
*/
|
|
2265
2347
|
declare const ProgressCircular: Comp<ProgressCircularProps, HTMLDivElement>;
|
|
2266
2348
|
|
|
2267
|
-
interface ProgressLinearProps extends GenericProps
|
|
2349
|
+
interface ProgressLinearProps extends GenericProps, HasTheme$1 {
|
|
2268
2350
|
}
|
|
2269
2351
|
/**
|
|
2270
2352
|
* ProgressLinear component.
|
|
@@ -2303,7 +2385,7 @@ declare const ProgressTrackerProvider: React.FC<ProgressTrackerProviderProps>;
|
|
|
2303
2385
|
/**
|
|
2304
2386
|
* Defines the props of the component.
|
|
2305
2387
|
*/
|
|
2306
|
-
interface ProgressTrackerProps extends GenericProps
|
|
2388
|
+
interface ProgressTrackerProps extends GenericProps {
|
|
2307
2389
|
/** ARIA label (purpose of the set of steps). */
|
|
2308
2390
|
['aria-label']: string;
|
|
2309
2391
|
/** Step list. */
|
|
@@ -2323,7 +2405,7 @@ declare const ProgressTracker: Comp<ProgressTrackerProps, HTMLDivElement>;
|
|
|
2323
2405
|
/**
|
|
2324
2406
|
* Defines the props of the component.
|
|
2325
2407
|
*/
|
|
2326
|
-
interface ProgressTrackerStepProps extends GenericProps
|
|
2408
|
+
interface ProgressTrackerStepProps extends GenericProps {
|
|
2327
2409
|
/** Children are not supported. */
|
|
2328
2410
|
children?: never;
|
|
2329
2411
|
/** Whether the step should be in error state or not. */
|
|
@@ -2355,7 +2437,7 @@ declare const ProgressTrackerStep: Comp<ProgressTrackerStepProps, HTMLButtonElem
|
|
|
2355
2437
|
/**
|
|
2356
2438
|
* Defines the props of the component.
|
|
2357
2439
|
*/
|
|
2358
|
-
interface ProgressTrackerStepPanelProps extends GenericProps
|
|
2440
|
+
interface ProgressTrackerStepPanelProps extends GenericProps {
|
|
2359
2441
|
/** Native id property. */
|
|
2360
2442
|
id?: string;
|
|
2361
2443
|
/** Whether the step is active or not. */
|
|
@@ -2377,7 +2459,7 @@ declare const ProgressTrackerStepPanel: Comp<ProgressTrackerStepPanelProps, HTML
|
|
|
2377
2459
|
/**
|
|
2378
2460
|
* Defines the props of the component.
|
|
2379
2461
|
*/
|
|
2380
|
-
interface RadioButtonProps extends GenericProps
|
|
2462
|
+
interface RadioButtonProps extends GenericProps, HasTheme$1, HasAriaDisabled$1 {
|
|
2381
2463
|
/** Helper text. */
|
|
2382
2464
|
helper?: string;
|
|
2383
2465
|
/** Native input id property. */
|
|
@@ -2411,7 +2493,7 @@ declare const RadioButton: Comp<RadioButtonProps, HTMLDivElement>;
|
|
|
2411
2493
|
/**
|
|
2412
2494
|
* Defines the props of the component.
|
|
2413
2495
|
*/
|
|
2414
|
-
interface RadioGroupProps extends GenericProps
|
|
2496
|
+
interface RadioGroupProps extends GenericProps {
|
|
2415
2497
|
/** RadioButton elements */
|
|
2416
2498
|
children: ReactNode;
|
|
2417
2499
|
}
|
|
@@ -2432,7 +2514,7 @@ declare const SelectVariant: {
|
|
|
2432
2514
|
readonly chip: "chip";
|
|
2433
2515
|
};
|
|
2434
2516
|
type SelectVariant = ValueOf<typeof SelectVariant>;
|
|
2435
|
-
interface CoreSelectProps extends GenericProps
|
|
2517
|
+
interface CoreSelectProps extends GenericProps, HasTheme$1 {
|
|
2436
2518
|
/** Props to pass to the clear button (minus those already set by the Select props). If not specified, the button won't be displayed. */
|
|
2437
2519
|
clearButtonProps?: Pick<IconButtonProps, 'label'> & Omit<IconButtonProps, 'label' | 'onClick' | 'icon' | 'emphasis'>;
|
|
2438
2520
|
/** Whether the select (input variant) is displayed with error style or not. */
|
|
@@ -2512,7 +2594,7 @@ declare const SelectMultiple: Comp<SelectMultipleProps, HTMLDivElement>;
|
|
|
2512
2594
|
/**
|
|
2513
2595
|
* Defines the props of the component.
|
|
2514
2596
|
*/
|
|
2515
|
-
interface SideNavigationProps extends GenericProps
|
|
2597
|
+
interface SideNavigationProps extends GenericProps, HasTheme$1 {
|
|
2516
2598
|
/** SideNavigationItem elements. */
|
|
2517
2599
|
children: ReactNode;
|
|
2518
2600
|
}
|
|
@@ -2528,7 +2610,7 @@ declare const SideNavigation: Comp<SideNavigationProps, HTMLUListElement>;
|
|
|
2528
2610
|
/**
|
|
2529
2611
|
* Defines the props of the component.
|
|
2530
2612
|
*/
|
|
2531
|
-
interface SideNavigationItemProps extends GenericProps
|
|
2613
|
+
interface SideNavigationItemProps extends GenericProps, HasCloseMode {
|
|
2532
2614
|
/** SideNavigationItem elements. */
|
|
2533
2615
|
children?: ReactNode;
|
|
2534
2616
|
/** Emphasis variant. */
|
|
@@ -2564,7 +2646,7 @@ declare const SideNavigationItem: Comp<SideNavigationItemProps, HTMLLIElement>;
|
|
|
2564
2646
|
/**
|
|
2565
2647
|
* Defines the props of the component.
|
|
2566
2648
|
*/
|
|
2567
|
-
interface SkeletonCircleProps extends GenericProps
|
|
2649
|
+
interface SkeletonCircleProps extends GenericProps, HasTheme$1 {
|
|
2568
2650
|
/** Size variant. */
|
|
2569
2651
|
size: GlobalSize;
|
|
2570
2652
|
/** The color of the skeleton. */
|
|
@@ -2591,7 +2673,7 @@ type SkeletonRectangleVariant = ValueOf<typeof SkeletonRectangleVariant>;
|
|
|
2591
2673
|
/**
|
|
2592
2674
|
* Defines the props of the component.
|
|
2593
2675
|
*/
|
|
2594
|
-
interface SkeletonRectangleProps extends GenericProps
|
|
2676
|
+
interface SkeletonRectangleProps extends GenericProps, HasTheme$1 {
|
|
2595
2677
|
/** Aspect ratio (use with width and not height). */
|
|
2596
2678
|
aspectRatio?: Extract<AspectRatio, 'square' | 'horizontal' | 'vertical' | 'wide'>;
|
|
2597
2679
|
/** Height size. */
|
|
@@ -2615,7 +2697,7 @@ declare const SkeletonRectangle: Comp<SkeletonRectangleProps, HTMLDivElement>;
|
|
|
2615
2697
|
/**
|
|
2616
2698
|
* Defines the props of the component.
|
|
2617
2699
|
*/
|
|
2618
|
-
interface SkeletonTypographyProps extends GenericProps
|
|
2700
|
+
interface SkeletonTypographyProps extends GenericProps, HasTheme$1 {
|
|
2619
2701
|
/** Typography variant. */
|
|
2620
2702
|
typography: TypographyInterface$1;
|
|
2621
2703
|
/** Width CSS property. */
|
|
@@ -2635,7 +2717,7 @@ declare const SkeletonTypography: Comp<SkeletonTypographyProps, HTMLDivElement>;
|
|
|
2635
2717
|
/**
|
|
2636
2718
|
* Defines the props of the component.
|
|
2637
2719
|
*/
|
|
2638
|
-
interface SliderProps extends GenericProps
|
|
2720
|
+
interface SliderProps extends GenericProps, HasTheme$1 {
|
|
2639
2721
|
/** Helper text. */
|
|
2640
2722
|
helper?: string;
|
|
2641
2723
|
/** Whether the min and max labels should be hidden or not. */
|
|
@@ -2694,7 +2776,7 @@ type SlideMode = ValueOf<typeof SlideMode>;
|
|
|
2694
2776
|
/**
|
|
2695
2777
|
* Defines the props of the component.
|
|
2696
2778
|
*/
|
|
2697
|
-
interface SlideshowProps extends GenericProps
|
|
2779
|
+
interface SlideshowProps extends GenericProps, Pick<SlidesProps, 'autoPlay' | 'slidesId' | 'id' | 'theme' | 'fillHeight' | 'groupBy' | 'slideGroupLabel'> {
|
|
2698
2780
|
/** Whether to use CSS transform translate or native scroll snap. */
|
|
2699
2781
|
slideMode?: SlideMode;
|
|
2700
2782
|
/** current slide active */
|
|
@@ -2720,7 +2802,7 @@ declare const Slideshow: Comp<SlideshowProps, HTMLDivElement>;
|
|
|
2720
2802
|
/**
|
|
2721
2803
|
* Defines the props of the component.
|
|
2722
2804
|
*/
|
|
2723
|
-
interface SlideshowItemProps extends GenericProps
|
|
2805
|
+
interface SlideshowItemProps extends GenericProps {
|
|
2724
2806
|
/** interval in which slides are automatically shown */
|
|
2725
2807
|
interval?: number;
|
|
2726
2808
|
/** Children */
|
|
@@ -2799,7 +2881,7 @@ interface UseSlideshowControls {
|
|
|
2799
2881
|
/**
|
|
2800
2882
|
* Defines the props of the component.
|
|
2801
2883
|
*/
|
|
2802
|
-
interface SlideshowControlsProps extends GenericProps
|
|
2884
|
+
interface SlideshowControlsProps extends GenericProps, HasTheme$1 {
|
|
2803
2885
|
/** Index of the current slide. */
|
|
2804
2886
|
activeIndex?: number;
|
|
2805
2887
|
/** Props to pass to the next button (minus those already set by the SlideshowControls props). */
|
|
@@ -2843,7 +2925,7 @@ declare const SlideshowControls: Comp<SlideshowControlsProps, HTMLDivElement> &
|
|
|
2843
2925
|
};
|
|
2844
2926
|
};
|
|
2845
2927
|
|
|
2846
|
-
interface SlidesProps extends GenericProps
|
|
2928
|
+
interface SlidesProps extends GenericProps, HasTheme$1 {
|
|
2847
2929
|
/** current slide active */
|
|
2848
2930
|
activeIndex: number;
|
|
2849
2931
|
/** slides id to be added to the wrapper */
|
|
@@ -2888,7 +2970,7 @@ declare const Slides: Comp<SlidesProps, HTMLDivElement>;
|
|
|
2888
2970
|
/**
|
|
2889
2971
|
* Defines the props of the component.
|
|
2890
2972
|
*/
|
|
2891
|
-
interface SwitchProps extends GenericProps
|
|
2973
|
+
interface SwitchProps extends GenericProps, HasTheme$1, HasAriaDisabled$1 {
|
|
2892
2974
|
/** Helper text. */
|
|
2893
2975
|
helper?: string;
|
|
2894
2976
|
/** Whether it is checked or not. */
|
|
@@ -2898,7 +2980,7 @@ interface SwitchProps extends GenericProps$1, HasTheme$1, HasAriaDisabled$1 {
|
|
|
2898
2980
|
/** Native input name property. */
|
|
2899
2981
|
name?: string;
|
|
2900
2982
|
/** Position of the switch relative to the label. */
|
|
2901
|
-
position?: Extract<Alignment, 'right' | 'left'>;
|
|
2983
|
+
position?: Extract<Alignment$1, 'right' | 'left'>;
|
|
2902
2984
|
/** Native input value property. */
|
|
2903
2985
|
value?: string;
|
|
2904
2986
|
/** On change callback. */
|
|
@@ -2920,7 +3002,7 @@ declare const Switch: Comp<SwitchProps, HTMLDivElement>;
|
|
|
2920
3002
|
/**
|
|
2921
3003
|
* Defines the props of the component.
|
|
2922
3004
|
*/
|
|
2923
|
-
interface TableProps extends GenericProps
|
|
3005
|
+
interface TableProps extends GenericProps, HasTheme$1 {
|
|
2924
3006
|
/** Whether the table has checkbox or thumbnail on first cell or not. */
|
|
2925
3007
|
hasBefore?: boolean;
|
|
2926
3008
|
/** Whether the table has dividers or not. */
|
|
@@ -2940,7 +3022,7 @@ declare const Table: Comp<TableProps, HTMLTableElement>;
|
|
|
2940
3022
|
/**
|
|
2941
3023
|
* Defines the props of the component.
|
|
2942
3024
|
*/
|
|
2943
|
-
interface TableBodyProps extends GenericProps
|
|
3025
|
+
interface TableBodyProps extends GenericProps {
|
|
2944
3026
|
/** Children */
|
|
2945
3027
|
children?: React.ReactNode;
|
|
2946
3028
|
}
|
|
@@ -2972,7 +3054,7 @@ type TableCellVariant = ValueOf<typeof TableCellVariant>;
|
|
|
2972
3054
|
/**
|
|
2973
3055
|
* Defines the props of the component.
|
|
2974
3056
|
*/
|
|
2975
|
-
interface TableCellProps extends GenericProps
|
|
3057
|
+
interface TableCellProps extends GenericProps {
|
|
2976
3058
|
/** Icon (SVG path).(thead only). */
|
|
2977
3059
|
icon?: string;
|
|
2978
3060
|
/** Whether the column is sortable or not (thead only). */
|
|
@@ -2998,7 +3080,7 @@ declare const TableCell: Comp<TableCellProps, HTMLTableCellElement>;
|
|
|
2998
3080
|
/**
|
|
2999
3081
|
* Defines the props of the component.
|
|
3000
3082
|
*/
|
|
3001
|
-
interface TableHeaderProps extends GenericProps
|
|
3083
|
+
interface TableHeaderProps extends GenericProps {
|
|
3002
3084
|
/** Children */
|
|
3003
3085
|
children?: React.ReactNode;
|
|
3004
3086
|
}
|
|
@@ -3014,7 +3096,7 @@ declare const TableHeader: Comp<TableHeaderProps, HTMLTableSectionElement>;
|
|
|
3014
3096
|
/**
|
|
3015
3097
|
* Defines the props of the component.
|
|
3016
3098
|
*/
|
|
3017
|
-
interface TableRowProps extends GenericProps
|
|
3099
|
+
interface TableRowProps extends GenericProps {
|
|
3018
3100
|
/** Whether the component is clickable or not. */
|
|
3019
3101
|
isClickable?: boolean;
|
|
3020
3102
|
/** Whether the component is disabled or not. */
|
|
@@ -3063,7 +3145,7 @@ declare enum TabListLayout {
|
|
|
3063
3145
|
/**
|
|
3064
3146
|
* Defines the props of the component.
|
|
3065
3147
|
*/
|
|
3066
|
-
interface TabListProps extends GenericProps
|
|
3148
|
+
interface TabListProps extends GenericProps, HasTheme$1 {
|
|
3067
3149
|
/** ARIA label (purpose of the set of tabs). */
|
|
3068
3150
|
['aria-label']: string;
|
|
3069
3151
|
/** Tab list. */
|
|
@@ -3071,7 +3153,7 @@ interface TabListProps extends GenericProps$1, HasTheme$1 {
|
|
|
3071
3153
|
/** Layout of the tabs in the list. */
|
|
3072
3154
|
layout?: TabListLayout;
|
|
3073
3155
|
/** Position of the tabs in the list (requires 'clustered' layout). */
|
|
3074
|
-
position?: Alignment;
|
|
3156
|
+
position?: Alignment$1;
|
|
3075
3157
|
}
|
|
3076
3158
|
/**
|
|
3077
3159
|
* TabList component.
|
|
@@ -3087,7 +3169,7 @@ declare const TabList: Comp<TabListProps, HTMLDivElement>;
|
|
|
3087
3169
|
/**
|
|
3088
3170
|
* Defines the props of the component.
|
|
3089
3171
|
*/
|
|
3090
|
-
interface TabProps extends GenericProps
|
|
3172
|
+
interface TabProps extends GenericProps {
|
|
3091
3173
|
/** Children are not supported. */
|
|
3092
3174
|
children?: never;
|
|
3093
3175
|
/** Icon (SVG path). */
|
|
@@ -3117,7 +3199,7 @@ declare const Tab: Comp<TabProps, HTMLButtonElement>;
|
|
|
3117
3199
|
/**
|
|
3118
3200
|
* Defines the props of the component.
|
|
3119
3201
|
*/
|
|
3120
|
-
interface TabPanelProps extends GenericProps
|
|
3202
|
+
interface TabPanelProps extends GenericProps {
|
|
3121
3203
|
/** Native id property */
|
|
3122
3204
|
id?: string;
|
|
3123
3205
|
/** Whether the tab is active or not. */
|
|
@@ -3136,6 +3218,8 @@ interface TabPanelProps extends GenericProps$1 {
|
|
|
3136
3218
|
*/
|
|
3137
3219
|
declare const TabPanel: Comp<TabPanelProps, HTMLDivElement>;
|
|
3138
3220
|
|
|
3221
|
+
interface TextProps extends TextProps$1, GenericProps {
|
|
3222
|
+
}
|
|
3139
3223
|
/**
|
|
3140
3224
|
* Text component.
|
|
3141
3225
|
*
|
|
@@ -3148,7 +3232,7 @@ declare const Text: Comp<TextProps, HTMLElement>;
|
|
|
3148
3232
|
/**
|
|
3149
3233
|
* Defines the props of the component.
|
|
3150
3234
|
*/
|
|
3151
|
-
interface TextFieldProps extends GenericProps
|
|
3235
|
+
interface TextFieldProps extends GenericProps, HasTheme$1, HasAriaDisabled$1 {
|
|
3152
3236
|
/** Chip Group to be rendered before the main text input. */
|
|
3153
3237
|
chips?: ReactNode;
|
|
3154
3238
|
/** Props to pass to the clear button (minus those already set by the TextField props). If not specified, the button won't be displayed. */
|
|
@@ -3247,7 +3331,7 @@ declare const useFocusPointStyle: ({ image, aspectRatio, focusPoint, imgProps: {
|
|
|
3247
3331
|
/**
|
|
3248
3332
|
* Defines the props of the component.
|
|
3249
3333
|
*/
|
|
3250
|
-
interface ToolbarProps extends GenericProps
|
|
3334
|
+
interface ToolbarProps extends GenericProps {
|
|
3251
3335
|
/** After content (placed after the label). */
|
|
3252
3336
|
after?: ReactNode;
|
|
3253
3337
|
/** Before content (placed before the label). */
|
|
@@ -3271,7 +3355,7 @@ type TooltipPlacement = Extract<Placement, 'top' | 'right' | 'bottom' | 'left'>;
|
|
|
3271
3355
|
/**
|
|
3272
3356
|
* Defines the props of the component.
|
|
3273
3357
|
*/
|
|
3274
|
-
interface TooltipProps extends GenericProps
|
|
3358
|
+
interface TooltipProps extends GenericProps, HasCloseMode {
|
|
3275
3359
|
/** Anchor (element on which we activate the tooltip). */
|
|
3276
3360
|
children: ReactNode;
|
|
3277
3361
|
/** Delay (in ms) before closing the tooltip. */
|
|
@@ -3316,7 +3400,7 @@ interface FileInputProps extends Omit<React__default.ComponentProps<'input'>, 'o
|
|
|
3316
3400
|
/**
|
|
3317
3401
|
* Defines the props of the component.
|
|
3318
3402
|
*/
|
|
3319
|
-
interface UploaderProps extends GenericProps
|
|
3403
|
+
interface UploaderProps extends GenericProps, HasTheme$1, HasAriaDisabled$1 {
|
|
3320
3404
|
/** Image aspect ratio. */
|
|
3321
3405
|
aspectRatio?: AspectRatio;
|
|
3322
3406
|
/** Icon (SVG path). */
|
|
@@ -3350,7 +3434,7 @@ type UserBlockSize = Extract<Size$1, 'xs' | 's' | 'm' | 'l'>;
|
|
|
3350
3434
|
/**
|
|
3351
3435
|
* Defines the props of the component.
|
|
3352
3436
|
*/
|
|
3353
|
-
interface UserBlockProps extends GenericProps
|
|
3437
|
+
interface UserBlockProps extends GenericProps, HasTheme$1 {
|
|
3354
3438
|
/** Props to pass to the avatar. */
|
|
3355
3439
|
avatarProps?: Omit<AvatarProps, 'alt'>;
|
|
3356
3440
|
/** Additional fields used to describe the user. */
|
|
@@ -3364,9 +3448,9 @@ interface UserBlockProps extends GenericProps$1, HasTheme$1 {
|
|
|
3364
3448
|
/** User name. */
|
|
3365
3449
|
name?: React__default.ReactNode;
|
|
3366
3450
|
/** Props to pass to the name block. */
|
|
3367
|
-
nameProps?: GenericProps
|
|
3451
|
+
nameProps?: GenericProps;
|
|
3368
3452
|
/** Orientation. */
|
|
3369
|
-
orientation?: Orientation;
|
|
3453
|
+
orientation?: Orientation$1;
|
|
3370
3454
|
/** Simple action toolbar content. */
|
|
3371
3455
|
simpleAction?: ReactNode;
|
|
3372
3456
|
/** Size variant. */
|