@digital-ai/dot-components 1.0.8 → 1.0.12
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 +7 -5
- package/dot-components.esm.js +6146 -3699
- package/dot-components.umd.js +6239 -3666
- package/index.d.ts +1 -0
- package/lib/components/CommonProps.d.ts +2 -0
- package/lib/components/accordion/Accordion.d.ts +1 -1
- package/lib/components/action-toolbar/ActionToolbar.d.ts +1 -1
- package/lib/components/alert-banner/AlertBanner.d.ts +1 -1
- package/lib/components/app-toolbar/AppToolbar.d.ts +5 -2
- package/lib/components/app-toolbar/AppToolbar.styles.d.ts +1 -1
- package/lib/components/auto-complete/AutoComplete.d.ts +3 -3
- package/lib/components/avatar/Avatar.d.ts +2 -2
- package/lib/components/avatar-group/AvatarGroup.d.ts +1 -1
- package/lib/components/breadcrumbs/Breadcrumbs.d.ts +6 -2
- package/lib/components/button/Button.d.ts +1 -1
- package/lib/components/button/IconButton.d.ts +1 -1
- package/lib/components/button-toggle/ButtonToggle.d.ts +0 -2
- package/lib/components/card/Card.d.ts +2 -1
- package/lib/components/card/CardContent.d.ts +2 -1
- package/lib/components/card/CardFooter.d.ts +2 -1
- package/lib/components/card/CardHeader.d.ts +1 -1
- package/lib/components/checkbox/Checkbox.d.ts +0 -2
- package/lib/components/checkbox/CheckboxGroup.d.ts +1 -1
- package/lib/components/chip/Chip.d.ts +1 -1
- package/lib/components/compareSize.d.ts +1 -0
- package/lib/components/confirmation-dialog/ConfirmationDialog.d.ts +1 -1
- package/lib/components/dialog/Dialog.d.ts +1 -1
- package/lib/components/drawer/Drawer.d.ts +1 -1
- package/lib/components/empty-state/EmptyState.d.ts +1 -1
- package/lib/components/form/Form.d.ts +3 -1
- package/lib/components/form-group/FormGroup.d.ts +0 -2
- package/lib/components/helpers.d.ts +3 -0
- package/lib/components/icon/Icon.d.ts +1 -1
- package/lib/components/index.d.ts +3 -2
- package/lib/components/inline-edit/InlineEdit.d.ts +1 -1
- package/lib/components/input-form-fields/InputSelect.d.ts +1 -1
- package/lib/components/link/Link.d.ts +4 -4
- package/lib/components/list/List.d.ts +1 -3
- package/lib/components/list/List.styles.d.ts +4 -4
- package/lib/components/menu/Menu.d.ts +3 -1
- package/lib/components/navigation-rail/NavigationRail.d.ts +3 -1
- package/lib/components/pill/Pill.d.ts +1 -1
- package/lib/components/progress/Progress.d.ts +1 -1
- package/lib/components/radio/RadioButton.d.ts +1 -1
- package/lib/components/radio/RadioGroup.d.ts +0 -2
- package/lib/components/sidebar/Sidebar.d.ts +1 -1
- package/lib/components/skeleton/Skeleton.d.ts +1 -1
- package/lib/components/snackbar/Snackbar.d.ts +1 -1
- package/lib/components/split-button/SplitButton.styles.d.ts +1 -1
- package/lib/components/switch/Switch.d.ts +0 -2
- package/lib/components/table/Table.d.ts +3 -2
- package/lib/components/table/Table.stories.data.d.ts +20 -2
- package/lib/components/table/TableBody.d.ts +1 -3
- package/lib/components/table/TableCell.d.ts +6 -3
- package/lib/components/table/TableHeader.d.ts +11 -2
- package/lib/components/table/TablePagination.d.ts +1 -1
- package/lib/components/typography/Typography.d.ts +1 -1
- package/lib/theme-provider/ThemeProvider.d.ts +2 -38
- package/lib/theme-provider/common/variables.d.ts +6 -0
- package/package.json +3 -6
package/index.d.ts
CHANGED
|
@@ -20,4 +20,4 @@ export interface AccordionProps extends CommonProps {
|
|
|
20
20
|
/** The text within the expanded Accordion */
|
|
21
21
|
summary: ReactNode;
|
|
22
22
|
}
|
|
23
|
-
export declare const DotAccordion: ({ actions, children, className, "data-testid": dataTestId, defaultExpanded, disabled, hasElevation, square, startIcon, summary, noWrap, }: AccordionProps) => JSX.Element;
|
|
23
|
+
export declare const DotAccordion: ({ actions, ariaLabel, children, className, "data-testid": dataTestId, defaultExpanded, disabled, hasElevation, square, startIcon, summary, noWrap, }: AccordionProps) => JSX.Element;
|
|
@@ -7,4 +7,4 @@ export interface DotActionBarProps extends CommonProps {
|
|
|
7
7
|
/** DotActionBarVarient dense and regular for toolbar height */
|
|
8
8
|
variant?: DotActionBarVarient;
|
|
9
9
|
}
|
|
10
|
-
export declare const DotActionToolbar: ({ children, variant, }: DotActionBarProps) => JSX.Element;
|
|
10
|
+
export declare const DotActionToolbar: ({ ariaLabel, children, className, "data-testid": dataTestId, variant, }: DotActionBarProps) => JSX.Element;
|
|
@@ -7,4 +7,4 @@ export interface AlertBannerProps extends CommonProps {
|
|
|
7
7
|
onClose?: (event: MouseEvent) => void;
|
|
8
8
|
severity: AlertBannerSeverity;
|
|
9
9
|
}
|
|
10
|
-
export declare const DotAlertBanner: ({ action, children, className, "data-testid": dataTestId, onClose, severity, }: AlertBannerProps) => JSX.Element;
|
|
10
|
+
export declare const DotAlertBanner: ({ action, ariaLabel, children, className, "data-testid": dataTestId, onClose, severity, }: AlertBannerProps) => JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
import { IconButtonProps } from '../button/IconButton';
|
|
4
|
+
import { ListItemProps } from '../list/List';
|
|
4
5
|
export interface AppToolbarProps extends CommonProps {
|
|
5
6
|
/** Product name displayed next to Digital.ai logo */
|
|
6
7
|
appName?: string;
|
|
@@ -12,11 +13,13 @@ export interface AppToolbarProps extends CommonProps {
|
|
|
12
13
|
children?: ReactNode;
|
|
13
14
|
/** Allow to display custom logo */
|
|
14
15
|
customLogo?: ReactNode;
|
|
15
|
-
/** If provided will display
|
|
16
|
+
/** If provided will overwrite `mainMenuItems` and display within the main menu drawer */
|
|
16
17
|
mainMenu?: ReactNode;
|
|
18
|
+
/** If provided will display the menu items within the main menu drawer */
|
|
19
|
+
mainMenuItems?: Array<ListItemProps>;
|
|
17
20
|
/** Width of main menu drawer if mainMenu provided, defaults to 240px */
|
|
18
21
|
mainMenuWidth?: number;
|
|
19
22
|
/** Array of nav items to be displayed on the right side */
|
|
20
23
|
navItems?: Array<IconButtonProps>;
|
|
21
24
|
}
|
|
22
|
-
export declare const DotAppToolbar: ({ avatar, borderColor, appName, children, className, customLogo, "data-testid": dataTestId, navItems, mainMenu, mainMenuWidth, }: AppToolbarProps) => JSX.Element;
|
|
25
|
+
export declare const DotAppToolbar: ({ ariaLabel, avatar, borderColor, appName, children, className, customLogo, "data-testid": dataTestId, navItems, mainMenu, mainMenuItems, mainMenuWidth, }: AppToolbarProps) => JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
export declare const rootClassName = "dot-app-toolbar";
|
|
3
|
-
export declare const StyledMainMenu: import("styled-components").StyledComponent<({ anchor, className, children, "data-testid": dataTestId, height, ModalProps, onClose, open, PaperProps, variant, width, }: import("../drawer/Drawer").DrawerProps) => JSX.Element, any, {}, never>;
|
|
3
|
+
export declare const StyledMainMenu: import("styled-components").StyledComponent<({ anchor, ariaLabel, className, children, "data-testid": dataTestId, height, ModalProps, onClose, open, PaperProps, variant, width, }: import("../drawer/Drawer").DrawerProps) => JSX.Element, any, {}, never>;
|
|
4
4
|
export declare const StyledAppToolbar: import("styled-components").StyledComponent<"header", any, {}, never>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ChangeEvent, Ref } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export declare type autoCompleteSize = 'medium' | 'small';
|
|
4
|
-
export declare type AutoCompleteValue = string | AutoCompleteOption | AutoCompleteOption[];
|
|
4
|
+
export declare type AutoCompleteValue = string | string[] | AutoCompleteOption | AutoCompleteOption[];
|
|
5
5
|
export interface AutoCompleteOption {
|
|
6
6
|
group?: string;
|
|
7
7
|
title: string;
|
|
@@ -34,7 +34,7 @@ export interface AutoCompleteProps extends CommonProps {
|
|
|
34
34
|
/** A function that should be executed when the value of the input changes */
|
|
35
35
|
onChange?: (event: ChangeEvent<unknown>, value: AutoCompleteValue, reason: string) => void;
|
|
36
36
|
/** pre-defined options available to the user */
|
|
37
|
-
options
|
|
37
|
+
options?: Array<AutoCompleteOption>;
|
|
38
38
|
/** Placeholder text always displayed inside the input field */
|
|
39
39
|
placeholder?: string;
|
|
40
40
|
/** Determines the padding within the input field 'medium' or 'small' */
|
|
@@ -42,4 +42,4 @@ export interface AutoCompleteProps extends CommonProps {
|
|
|
42
42
|
/** value if this is a controlled component */
|
|
43
43
|
value?: AutoCompleteValue;
|
|
44
44
|
}
|
|
45
|
-
export declare const DotAutoComplete: ({ autoFocus, className, "data-testid": dataTestId, defaultValue, disabled, error, freesolo, group, helperText, inputId, inputRef, label, multiple, onChange, options, placeholder, size, value, }: AutoCompleteProps) => JSX.Element;
|
|
45
|
+
export declare const DotAutoComplete: ({ ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, disabled, error, freesolo, group, helperText, inputId, inputRef, label, multiple, onChange, options, placeholder, size, value, }: AutoCompleteProps) => JSX.Element;
|
|
@@ -17,7 +17,7 @@ export interface AvatarProps extends CommonProps {
|
|
|
17
17
|
onClick?: (event: MouseEvent) => void;
|
|
18
18
|
/** Size of avatar displayed */
|
|
19
19
|
size?: AvatarSize;
|
|
20
|
-
/** To be used to override
|
|
20
|
+
/** To be used to override styles inline */
|
|
21
21
|
style?: CSSProperties;
|
|
22
22
|
/** The text to be displayed. Only the first 2 letters will be displayed. */
|
|
23
23
|
text?: string;
|
|
@@ -26,4 +26,4 @@ export interface AvatarProps extends CommonProps {
|
|
|
26
26
|
/** The shape of the avatar */
|
|
27
27
|
variant?: AvatarVariant;
|
|
28
28
|
}
|
|
29
|
-
export declare const DotAvatar: ({ alt, className, color, "data-testid": dataTestId, iconId, imageSrc, onClick, size, text, type, variant, style, }: AvatarProps) => JSX.Element;
|
|
29
|
+
export declare const DotAvatar: ({ alt, ariaLabel, className, color, "data-testid": dataTestId, iconId, imageSrc, onClick, size, text, type, variant, style, }: AvatarProps) => JSX.Element;
|
|
@@ -10,4 +10,4 @@ export interface AvatarGroupProps extends CommonProps {
|
|
|
10
10
|
/** Spacing between avatars */
|
|
11
11
|
spacing?: AvatarGroupSpacing;
|
|
12
12
|
}
|
|
13
|
-
export declare const DotAvatarGroup: ({ avatars, className, "data-testid": dataTestId, max, spacing, }: AvatarGroupProps) => JSX.Element;
|
|
13
|
+
export declare const DotAvatarGroup: ({ ariaLabel, avatars, className, "data-testid": dataTestId, max, spacing, }: AvatarGroupProps) => JSX.Element;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { LinkUnderline } from '../link/Link';
|
|
3
2
|
import { CommonProps } from '../CommonProps';
|
|
3
|
+
import { LinkUnderline } from '../link/Link';
|
|
4
4
|
export declare type BreadcrumbItem = {
|
|
5
|
+
/** Defines a string value that labels the current element **/
|
|
6
|
+
ariaLabel?: string;
|
|
5
7
|
/** link the breadcrumb goes to */
|
|
6
8
|
href?: string;
|
|
7
9
|
onClick?: (event: React.MouseEvent<HTMLAnchorElement>) => void;
|
|
@@ -17,5 +19,7 @@ export interface BreadcrumbProps extends CommonProps {
|
|
|
17
19
|
items: Array<BreadcrumbItem>;
|
|
18
20
|
/** determines the maximum number of items to display */
|
|
19
21
|
maxItems?: number;
|
|
22
|
+
/** minimum width before `maxItems` will be adjusted */
|
|
23
|
+
minWidth?: number;
|
|
20
24
|
}
|
|
21
|
-
export declare const DotBreadcrumbs: ({ className, "data-testid": dataTestId, expansionMenu, items, maxItems, }: BreadcrumbProps) => JSX.Element;
|
|
25
|
+
export declare const DotBreadcrumbs: ({ className, "data-testid": dataTestId, expansionMenu, items, maxItems, minWidth, }: BreadcrumbProps) => JSX.Element;
|
|
@@ -9,4 +9,4 @@ export interface ButtonProps extends BaseButtonProps {
|
|
|
9
9
|
startIcon?: ReactNode;
|
|
10
10
|
}
|
|
11
11
|
/** This component wraps the Button component from @material-ui. */
|
|
12
|
-
export declare const DotButton: ({ autoFocus, children, className, "data-testid": dataTestId, disabled, disableRipple, endIcon, fullWidth, isSubmit, onClick, size, startIcon, titleTooltip, type, }: ButtonProps) => JSX.Element;
|
|
12
|
+
export declare const DotButton: ({ ariaLabel, autoFocus, children, className, "data-testid": dataTestId, disabled, disableRipple, endIcon, fullWidth, isSubmit, onClick, size, startIcon, titleTooltip, type, }: ButtonProps) => JSX.Element;
|
|
@@ -17,4 +17,4 @@ export interface IconButtonProps extends CommonProps {
|
|
|
17
17
|
titleTooltip?: string;
|
|
18
18
|
}
|
|
19
19
|
/** This component wraps the IconButton component from @material-ui. */
|
|
20
|
-
export declare const DotIconButton: ({ className, color, "data-testid": dataTestId, disabled, iconId, onClick, titleTooltip, size, }: IconButtonProps) => JSX.Element;
|
|
20
|
+
export declare const DotIconButton: ({ ariaLabel, className, color, "data-testid": dataTestId, disabled, iconId, onClick, titleTooltip, size, }: IconButtonProps) => JSX.Element;
|
|
@@ -4,8 +4,6 @@ export declare type ButtonToggleSize = 'small' | 'medium' | 'large';
|
|
|
4
4
|
export declare type ButtonToggleOrientation = 'horizontal' | 'vertical';
|
|
5
5
|
declare type ButtonToggleValue = string | number | boolean;
|
|
6
6
|
export interface ButtonToggleProps extends CommonProps {
|
|
7
|
-
/** accessibility label */
|
|
8
|
-
ariaLabel: string;
|
|
9
7
|
/** button props for each toggle button options*/
|
|
10
8
|
buttonOptions: {
|
|
11
9
|
ariaLabel: string;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export interface CardProps extends CommonProps {
|
|
4
|
+
/** The content for the Card.*/
|
|
4
5
|
children: ReactNode;
|
|
5
6
|
}
|
|
6
|
-
export declare const DotCard: ({ children, className, "data-testid": dataTestId, }: CardProps) => JSX.Element;
|
|
7
|
+
export declare const DotCard: ({ ariaLabel, children, className, "data-testid": dataTestId, }: CardProps) => JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export interface CardContentProps extends CommonProps {
|
|
4
|
+
/** The content for the CardContent.*/
|
|
4
5
|
children: ReactNode;
|
|
5
6
|
}
|
|
6
|
-
export declare const DotCardContent: ({ children, className, "data-testid": dataTestId, }: CardContentProps) => JSX.Element;
|
|
7
|
+
export declare const DotCardContent: ({ ariaLabel, children, className, "data-testid": dataTestId, }: CardContentProps) => JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export interface CardFooterProps extends CommonProps {
|
|
4
|
+
/** The content for the CardFooter.*/
|
|
4
5
|
children: ReactNode;
|
|
5
6
|
}
|
|
6
|
-
export declare const DotCardFooter: ({ children, className, "data-testid": dataTestId, }: CardFooterProps) => JSX.Element;
|
|
7
|
+
export declare const DotCardFooter: ({ ariaLabel, children, className, "data-testid": dataTestId, }: CardFooterProps) => JSX.Element;
|
|
@@ -16,4 +16,4 @@ export interface CardHeaderProps extends CommonProps {
|
|
|
16
16
|
/** Card title size */
|
|
17
17
|
titleSize?: TitleSize;
|
|
18
18
|
}
|
|
19
|
-
export declare const DotCardHeader: ({ action, avatar, className, "data-testid": dataTestId, subheader, subheaderSize, title, titleSize, }: CardHeaderProps) => JSX.Element;
|
|
19
|
+
export declare const DotCardHeader: ({ action, ariaLabel, avatar, className, "data-testid": dataTestId, subheader, subheaderSize, title, titleSize, }: CardHeaderProps) => JSX.Element;
|
|
@@ -3,8 +3,6 @@ import { RadioButtonProps } from '../radio/RadioButton';
|
|
|
3
3
|
export declare type CheckboxSize = 'medium' | 'small';
|
|
4
4
|
export declare type CheckboxLabelPlacement = 'bottom' | 'end' | 'start';
|
|
5
5
|
export interface CheckboxProps extends RadioButtonProps {
|
|
6
|
-
/** accessibility label */
|
|
7
|
-
ariaLabel?: string;
|
|
8
6
|
/** accessibility labelled by */
|
|
9
7
|
ariaLabelledby?: string;
|
|
10
8
|
/** If true, the ripple effect will be disabled. */
|
|
@@ -13,4 +13,4 @@ export interface CheckboxGroupProps extends RadioGroupBaseProps {
|
|
|
13
13
|
/** if true use parent for selecting/deselecting all */
|
|
14
14
|
showSelectAll?: boolean;
|
|
15
15
|
}
|
|
16
|
-
export declare function DotCheckboxGroup({ ariaLabel, className, defaultValues, disableGroup, endIcon, error, groupLabel, helperText, name, labelPlacement, onChange, options, showSelectAll, required, row, selectAllLabel, startIcon, size, }: CheckboxGroupProps): JSX.Element;
|
|
16
|
+
export declare function DotCheckboxGroup({ ariaLabel, className, 'data-testid': dataTestId, defaultValues, disableGroup, endIcon, error, groupLabel, helperText, name, labelPlacement, onChange, options, showSelectAll, required, row, selectAllLabel, startIcon, size, }: CheckboxGroupProps): JSX.Element;
|
|
@@ -23,4 +23,4 @@ export interface ChipProps extends CommonProps {
|
|
|
23
23
|
/** The icon to display on the chip */
|
|
24
24
|
startIcon?: ReactElement;
|
|
25
25
|
}
|
|
26
|
-
export declare const DotChip: ({ avatar, children, className, "data-testid": dataTestId, disabled, error, isClickable, isDeletable, onClick, onDelete, size, startIcon, }: ChipProps) => JSX.Element;
|
|
26
|
+
export declare const DotChip: ({ ariaLabel, avatar, children, className, "data-testid": dataTestId, disabled, error, isClickable, isDeletable, onClick, onDelete, size, startIcon, }: ChipProps) => JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const compareWidth: (parentEl: Element | HTMLElement, childEl: Element | HTMLElement) => boolean;
|
|
@@ -17,4 +17,4 @@ export interface ConfirmationDialogProps extends CommonProps {
|
|
|
17
17
|
/** The dialog title */
|
|
18
18
|
title?: ReactNode;
|
|
19
19
|
}
|
|
20
|
-
export declare const DotConfirmationDialog: ({ cancelButtonProps, className, "data-testid": dataTestId, message, onCancel, onSubmit, submitButtonProps, open, title, }: ConfirmationDialogProps) => JSX.Element;
|
|
20
|
+
export declare const DotConfirmationDialog: ({ ariaLabel, cancelButtonProps, className, "data-testid": dataTestId, message, onCancel, onSubmit, submitButtonProps, open, title, }: ConfirmationDialogProps) => JSX.Element;
|
|
@@ -35,4 +35,4 @@ export interface DialogProps extends CommonProps {
|
|
|
35
35
|
/** dialog heading */
|
|
36
36
|
title: ReactNode;
|
|
37
37
|
}
|
|
38
|
-
export declare const DotDialog: ({ cancelButtonProps, className, "data-testid": dataTestId, children, closeIconVisible, closeOnClickAway, hasPrimaryAction, onCancel, onSubmit, open, submitButtonProps, title, }: DialogProps) => JSX.Element;
|
|
38
|
+
export declare const DotDialog: ({ ariaLabel, cancelButtonProps, className, "data-testid": dataTestId, children, closeIconVisible, closeOnClickAway, hasPrimaryAction, onCancel, onSubmit, open, submitButtonProps, title, }: DialogProps) => JSX.Element;
|
|
@@ -29,4 +29,4 @@ export interface DrawerProps extends CommonProps {
|
|
|
29
29
|
/** The width of the drawer when anchor is 'left' or 'right' */
|
|
30
30
|
width?: string;
|
|
31
31
|
}
|
|
32
|
-
export declare const DotDrawer: ({ anchor, className, children, "data-testid": dataTestId, height, ModalProps, onClose, open, PaperProps, variant, width, }: DrawerProps) => JSX.Element;
|
|
32
|
+
export declare const DotDrawer: ({ anchor, ariaLabel, className, children, "data-testid": dataTestId, height, ModalProps, onClose, open, PaperProps, variant, width, }: DrawerProps) => JSX.Element;
|
|
@@ -13,4 +13,4 @@ export interface EmptyStateProps extends CommonProps {
|
|
|
13
13
|
/** title text displayed */
|
|
14
14
|
title: string;
|
|
15
15
|
}
|
|
16
|
-
export declare const DotEmptyState: ({ buttonProps, className, "data-testid": dataTestId, imageAltText, imageSrc, subtitle, title, }: EmptyStateProps) => JSX.Element;
|
|
16
|
+
export declare const DotEmptyState: ({ ariaLabel, buttonProps, className, "data-testid": dataTestId, imageAltText, imageSrc, subtitle, title, }: EmptyStateProps) => JSX.Element;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { FormEvent, ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export interface FormProps extends CommonProps {
|
|
4
|
+
/** The content for the Form. **/
|
|
4
5
|
children: ReactNode;
|
|
6
|
+
/** Callback function when form is submitted **/
|
|
5
7
|
onSubmit: (event: FormEvent) => void;
|
|
6
8
|
}
|
|
7
|
-
export declare const DotForm: ({ children, className, "data-testid": dataTestId, onSubmit, }: FormProps) => JSX.Element;
|
|
9
|
+
export declare const DotForm: ({ ariaLabel, children, className, "data-testid": dataTestId, onSubmit, }: FormProps) => JSX.Element;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export interface FormGroupProps extends CommonProps {
|
|
4
|
-
/** accessibility label */
|
|
5
|
-
ariaLabel?: string;
|
|
6
4
|
/** The text for the button. Button text should be in sentence case. */
|
|
7
5
|
children: ReactNode;
|
|
8
6
|
/** changes layout to be horizontal if true */
|
|
@@ -9,4 +9,4 @@ export interface IconProps extends CommonProps {
|
|
|
9
9
|
/** Tooltip text displayed on hover */
|
|
10
10
|
title?: string;
|
|
11
11
|
}
|
|
12
|
-
export declare const DotIcon: ({ className, "data-testid": dataTestId, fontSize, iconId, title, }: IconProps) => JSX.Element;
|
|
12
|
+
export declare const DotIcon: ({ ariaLabel, className, "data-testid": dataTestId, fontSize, iconId, title, }: IconProps) => JSX.Element;
|
|
@@ -16,7 +16,7 @@ export { CheckboxProps, DotCheckbox } from './checkbox/Checkbox';
|
|
|
16
16
|
export { DotCheckboxGroup } from './checkbox/CheckboxGroup';
|
|
17
17
|
export { DotChip } from './chip/Chip';
|
|
18
18
|
export { DotConfirmationDialog } from './confirmation-dialog/ConfirmationDialog';
|
|
19
|
-
export { Cell } from './css-grid/CssCell';
|
|
19
|
+
export { Cell, CssCell } from './css-grid/CssCell';
|
|
20
20
|
export { CssGrid } from './css-grid/CssGrid';
|
|
21
21
|
export { CssGridDebug } from './css-grid/CssGridDebug';
|
|
22
22
|
export { DotDialog } from './dialog/Dialog';
|
|
@@ -44,8 +44,9 @@ export { DotSnackbarContainer, DotSnackbarProvider, useDotSnackbarContext, } fro
|
|
|
44
44
|
export { DotSplitButton } from './split-button/SplitButton';
|
|
45
45
|
export { DotSwitch } from './switch/Switch';
|
|
46
46
|
export { DotTable, TableRowProps } from './table/Table';
|
|
47
|
+
export { Order } from './table/TableBody';
|
|
47
48
|
export { DotHeaderRow, DotColumnHeader } from './table/TableHeader';
|
|
48
49
|
export { TableDataWithPagination } from './table/TableDataWithPagination';
|
|
49
|
-
export { DotTablePagination } from './table/TablePagination';
|
|
50
|
+
export { DotTablePagination, RowsPerPageOption } from './table/TablePagination';
|
|
50
51
|
export { DotTabs, TabProps } from './tabs/Tabs';
|
|
51
52
|
export { DotTypography, TypographyVariant } from './typography/Typography';
|
|
@@ -32,4 +32,4 @@ export interface InlineEditProps extends CommonProps {
|
|
|
32
32
|
/**
|
|
33
33
|
* @experimental This component is still in development
|
|
34
34
|
*/
|
|
35
|
-
export declare const DotInlineEdit: ({ autoFocus, className, "data-testid": dataTestId, disabled, error, fullWidth, helperText, name, onEditStateChange, onLabelChange, readOnly, required, size, value, }: InlineEditProps) => JSX.Element;
|
|
35
|
+
export declare const DotInlineEdit: ({ ariaLabel, autoFocus, className, "data-testid": dataTestId, disabled, error, fullWidth, helperText, name, onEditStateChange, onLabelChange, readOnly, required, size, value, }: InlineEditProps) => JSX.Element;
|
|
@@ -8,4 +8,4 @@ export interface InputSelectProps extends InputProps {
|
|
|
8
8
|
/** value of input field */
|
|
9
9
|
value?: string;
|
|
10
10
|
}
|
|
11
|
-
export declare const DotInputSelect: ({ autoFocus, className, "data-testid": dataTestId, defaultValue, disabled, endIcon, error, fullWidth, helperText, id, inputRef, label, name, onChange, options, required, size, startIcon, value, warning, }: InputSelectProps) => JSX.Element;
|
|
11
|
+
export declare const DotInputSelect: ({ ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, disabled, endIcon, error, fullWidth, helperText, id, inputRef, label, name, onChange, options, required, size, startIcon, value, warning, }: InputSelectProps) => JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MouseEvent, ReactNode } from 'react';
|
|
1
|
+
import { KeyboardEvent, MouseEvent, ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export declare type LinkColor = 'initial' | 'inherit' | 'primary' | 'secondary' | 'textPrimary' | 'textSecondary' | 'error';
|
|
4
4
|
export declare type LinkUnderline = 'always' | 'hover' | 'none';
|
|
@@ -11,9 +11,9 @@ export interface LinkProps extends CommonProps {
|
|
|
11
11
|
/** href for the link. */
|
|
12
12
|
href?: string;
|
|
13
13
|
/** event callback */
|
|
14
|
-
onClick?: (event: MouseEvent<
|
|
14
|
+
onClick?: (event: KeyboardEvent<Element> | MouseEvent<Element>) => void;
|
|
15
15
|
/** mouse enter event callback */
|
|
16
|
-
onMouseEnter?: (event: MouseEvent<
|
|
16
|
+
onMouseEnter?: (event: MouseEvent<Element>) => void;
|
|
17
17
|
/** specifies the relationship between the current document and the linked document */
|
|
18
18
|
rel?: string;
|
|
19
19
|
/** tab order for the link */
|
|
@@ -25,4 +25,4 @@ export interface LinkProps extends CommonProps {
|
|
|
25
25
|
/** underline the link */
|
|
26
26
|
underline?: LinkUnderline;
|
|
27
27
|
}
|
|
28
|
-
export declare const DotLink: ({ children, className, color, "data-testid": dataTestId, href, onClick, onMouseEnter, rel, tabIndex, target, title, underline, }: LinkProps) => JSX.Element;
|
|
28
|
+
export declare const DotLink: ({ ariaLabel, children, className, color, "data-testid": dataTestId, href, onClick, onMouseEnter, rel, tabIndex, target, title, underline, }: LinkProps) => JSX.Element;
|
|
@@ -19,8 +19,6 @@ export interface NestedListProps extends CommonProps {
|
|
|
19
19
|
type?: NestedListType;
|
|
20
20
|
}
|
|
21
21
|
export interface ListProps extends CommonProps {
|
|
22
|
-
/** aria-label passed to the list component */
|
|
23
|
-
ariaLabel?: string;
|
|
24
22
|
/** string or JSX element that is displayed inside the toolbar */
|
|
25
23
|
children?: ReactNode;
|
|
26
24
|
/** The component used for the root node. Either a string to use a HTML element or a component. */
|
|
@@ -65,4 +63,4 @@ export interface ListItemProps extends CommonProps {
|
|
|
65
63
|
title?: string;
|
|
66
64
|
}
|
|
67
65
|
export declare const DotList: ({ ariaLabel, children, className, component, "data-testid": dataTestId, dense, disablePadding, items, menuPlacement, nestedListType, }: ListProps) => JSX.Element;
|
|
68
|
-
export declare const DotListItem: ({ className, component, "data-testid": dataTestId, divider, endIconId, href, index, onClick, items, menuPlacement, nestedListType, selected, startIconId, text, title, }: ListItemProps) => JSX.Element;
|
|
66
|
+
export declare const DotListItem: ({ ariaLabel, className, component, "data-testid": dataTestId, divider, endIconId, href, index, onClick, items, menuPlacement, nestedListType, selected, startIconId, text, title, }: ListItemProps) => JSX.Element;
|
|
@@ -34,13 +34,13 @@ export declare const StyledListItem: import("@material-ui/core/OverridableCompon
|
|
|
34
34
|
disableTouchRipple?: boolean;
|
|
35
35
|
focusRipple?: boolean;
|
|
36
36
|
focusVisibleClassName?: string;
|
|
37
|
-
onFocusVisible?:
|
|
38
|
-
tabIndex?:
|
|
37
|
+
onFocusVisible?: import("react").FocusEventHandler<any>;
|
|
38
|
+
tabIndex?: string | number;
|
|
39
39
|
TouchRippleProps?: Partial<import("@material-ui/core/ButtonBase/TouchRipple").TouchRippleProps>;
|
|
40
40
|
} & import("@material-ui/core/OverridableComponent").CommonProps<import("@material-ui/core").ExtendButtonBaseTypeMap<import("@material-ui/core").ListItemTypeMap<{
|
|
41
41
|
button: true;
|
|
42
|
-
}, "div">>> & Pick<Pick<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "
|
|
43
|
-
ref?:
|
|
42
|
+
}, "div">>> & Pick<Pick<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "key" | keyof import("react").AnchorHTMLAttributes<HTMLAnchorElement>> & {
|
|
43
|
+
ref?: import("react").Ref<HTMLAnchorElement>;
|
|
44
44
|
}, "slot" | "title" | "type" | "ref" | "children" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "download" | "href" | "hrefLang" | "media" | "ping" | "rel" | "target" | "referrerPolicy">) => JSX.Element) & import("@material-ui/core/OverridableComponent").OverridableComponent<import("@material-ui/core").ExtendButtonBaseTypeMap<import("@material-ui/core").ListItemTypeMap<{
|
|
45
45
|
button: true;
|
|
46
46
|
}, "div">>>;
|
|
@@ -20,6 +20,8 @@ export interface MenuProps extends CommonProps {
|
|
|
20
20
|
onSelect?: (event: MouseEvent | KeyboardEvent, menuId: string, itemKey: string) => void;
|
|
21
21
|
}
|
|
22
22
|
export interface MenuItemProps {
|
|
23
|
+
/** Defines a string value that labels the current element **/
|
|
24
|
+
ariaLabel?: string;
|
|
23
25
|
/** The text displayed on the item */
|
|
24
26
|
children?: ReactNode;
|
|
25
27
|
/** Space delimited CSS classes to be attributed to the menu item */
|
|
@@ -27,4 +29,4 @@ export interface MenuItemProps {
|
|
|
27
29
|
/** A key that can be used to determine which item was clicked */
|
|
28
30
|
key?: string;
|
|
29
31
|
}
|
|
30
|
-
export declare const DotMenu: ({ anchorEl, className, "data-testid": dataTestId, disablePortal, id, menuItems, menuPlacement, onLeave, onSelect, open, }: MenuProps) => JSX.Element;
|
|
32
|
+
export declare const DotMenu: ({ anchorEl, ariaLabel, className, "data-testid": dataTestId, disablePortal, id, menuItems, menuPlacement, onLeave, onSelect, open, }: MenuProps) => JSX.Element;
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export declare type RailItemsPosition = 'flex-start' | 'center' | 'flex-end';
|
|
4
4
|
export interface RailItem {
|
|
5
|
+
/** Defines a string value that labels the current element **/
|
|
6
|
+
ariaLabel?: string;
|
|
5
7
|
/** Id of the icon shown in the rail item */
|
|
6
8
|
iconId: string;
|
|
7
9
|
/** text displayed or title text if icon used */
|
|
@@ -17,4 +19,4 @@ export interface NavigationRailProps extends CommonProps {
|
|
|
17
19
|
/** index of selected rail item */
|
|
18
20
|
selectedIndex?: number;
|
|
19
21
|
}
|
|
20
|
-
export declare const DotNavigationRail: ({ className, "data-testid": dataTestId, onChange, railItemPosition, railItems, selectedIndex, }: NavigationRailProps) => JSX.Element;
|
|
22
|
+
export declare const DotNavigationRail: ({ ariaLabel, className, "data-testid": dataTestId, onChange, railItemPosition, railItems, selectedIndex, }: NavigationRailProps) => JSX.Element;
|
|
@@ -14,4 +14,4 @@ export interface PillProps extends CommonProps {
|
|
|
14
14
|
/** Determines the status of the pill component */
|
|
15
15
|
status?: PillStatus;
|
|
16
16
|
}
|
|
17
|
-
export declare const DotPill: ({ backgroundcolor, className, "data-testid": dataTestId, label, labelcolor, size, status, }: PillProps) => JSX.Element;
|
|
17
|
+
export declare const DotPill: ({ ariaLabel, backgroundcolor, className, "data-testid": dataTestId, label, labelcolor, size, status, }: PillProps) => JSX.Element;
|
|
@@ -16,4 +16,4 @@ export interface ProgressProps extends CommonProps {
|
|
|
16
16
|
/** type of progress spinner displayed */
|
|
17
17
|
variant?: progressVariantOptions;
|
|
18
18
|
}
|
|
19
|
-
export declare const DotProgress: ({ color, className, "data-testid": dataTestId, size, thickness, title, value, variant, }: ProgressProps) => JSX.Element;
|
|
19
|
+
export declare const DotProgress: ({ ariaLabel, color, className, "data-testid": dataTestId, size, thickness, title, value, variant, }: ProgressProps) => JSX.Element;
|
|
@@ -28,4 +28,4 @@ export interface RadioButtonProps extends RadioButtonBaseProps {
|
|
|
28
28
|
/** A function that should be executed when the value of the radio buttom changes */
|
|
29
29
|
onChange?: (event: ChangeEvent<HTMLInputElement>, value: string) => void;
|
|
30
30
|
}
|
|
31
|
-
export declare function DotRadioButton({ checked, className, 'data-testid': dataTestId, disabled, id, inputRef, label, labelPlacement, name, onChange, required, size, value, }: RadioButtonProps): JSX.Element;
|
|
31
|
+
export declare function DotRadioButton({ ariaLabel, checked, className, 'data-testid': dataTestId, disabled, id, inputRef, label, labelPlacement, name, onChange, required, size, value, }: RadioButtonProps): JSX.Element;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { ChangeEvent, ReactNode } from 'react';
|
|
2
2
|
import { RadioButtonBaseProps, RadioButtonProps } from './RadioButton';
|
|
3
3
|
export interface RadioGroupBaseProps extends RadioButtonBaseProps {
|
|
4
|
-
/** accessibility label */
|
|
5
|
-
ariaLabel?: string;
|
|
6
4
|
/** if true makes all radio buttons disabled */
|
|
7
5
|
disableGroup?: boolean;
|
|
8
6
|
/** Icon placed before the children. */
|
|
@@ -36,4 +36,4 @@ export interface SidebarProps extends CommonProps {
|
|
|
36
36
|
/** If provided, will display an avatar next to the title text */
|
|
37
37
|
titleAvatarProps?: AvatarProps;
|
|
38
38
|
}
|
|
39
|
-
export declare const DotSidebar: ({ backItem, brandDesc, children, className, collapsable, "data-testid": dataTestId, displayBrand, goBack, navItems, nestedListType, open, title, titleAvatarProps, }: SidebarProps) => JSX.Element;
|
|
39
|
+
export declare const DotSidebar: ({ ariaLabel, backItem, brandDesc, children, className, collapsable, "data-testid": dataTestId, displayBrand, goBack, navItems, nestedListType, open, title, titleAvatarProps, }: SidebarProps) => JSX.Element;
|
|
@@ -11,4 +11,4 @@ export interface SkeletonProps extends CommonProps {
|
|
|
11
11
|
/** Determine width of skeleton */
|
|
12
12
|
width?: number | string;
|
|
13
13
|
}
|
|
14
|
-
export declare const DotSkeleton: ({ children, className, "data-testid": dataTestId, height, width, variant, }: SkeletonProps) => JSX.Element;
|
|
14
|
+
export declare const DotSkeleton: ({ ariaLabel, children, className, "data-testid": dataTestId, height, width, variant, }: SkeletonProps) => JSX.Element;
|
|
@@ -14,4 +14,4 @@ export interface SnackbarProps extends CommonProps {
|
|
|
14
14
|
severity: SnackbarSeverity;
|
|
15
15
|
width?: string;
|
|
16
16
|
}
|
|
17
|
-
export declare const DotSnackbar: ({
|
|
17
|
+
export declare const DotSnackbar: ({ action, ariaLabel, children, className, "data-testid": dataTestId, onClose, open, severity, width, }: SnackbarProps) => JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
export declare const rootClassName = "dot-split-button-group";
|
|
3
3
|
export declare const StyledSplitButtonGroup: import("styled-components").StyledComponent<import("@material-ui/core/OverridableComponent").OverridableComponent<import("@material-ui/core").ButtonGroupTypeMap<{}, "div">>, any, {}, never>;
|
|
4
|
-
export declare const StyledMenu: import("styled-components").StyledComponent<({ anchorEl, className, "data-testid": dataTestId, disablePortal, id, menuItems, menuPlacement, onLeave, onSelect, open, }: import("../menu/Menu").MenuProps) => JSX.Element, any, {}, never>;
|
|
4
|
+
export declare const StyledMenu: import("styled-components").StyledComponent<({ anchorEl, ariaLabel, className, "data-testid": dataTestId, disablePortal, id, menuItems, menuPlacement, onLeave, onSelect, open, }: import("../menu/Menu").MenuProps) => JSX.Element, any, {}, never>;
|
|
@@ -4,8 +4,6 @@ export declare type SwitchColor = 'default' | 'primary' | 'secondary';
|
|
|
4
4
|
export declare type SwitchSize = 'medium' | 'small';
|
|
5
5
|
export declare type SwitchLabelPlacement = 'bottom' | 'end' | 'start' | 'top';
|
|
6
6
|
export interface SwitchProps extends CommonProps {
|
|
7
|
-
/** accessibility label */
|
|
8
|
-
ariaLabel?: string;
|
|
9
7
|
/** determines the default state of the switch */
|
|
10
8
|
checked?: boolean;
|
|
11
9
|
/** color options available 'default', 'primary', 'secondary' */
|
|
@@ -12,7 +12,6 @@ export interface TableRowProps extends CommonProps {
|
|
|
12
12
|
rowData: any;
|
|
13
13
|
}
|
|
14
14
|
export interface TableProps extends CommonProps {
|
|
15
|
-
ariaLabel: string;
|
|
16
15
|
/** The table header columns */
|
|
17
16
|
columns: Array<DotColumnHeader>;
|
|
18
17
|
/** Total number of items for paginated table.
|
|
@@ -37,6 +36,8 @@ export interface TableProps extends CommonProps {
|
|
|
37
36
|
onRowClick?: (event: MouseEvent, id: string) => void;
|
|
38
37
|
/** Update data callback if data is managed by consumer */
|
|
39
38
|
onUpdateData?: (order: Order, orderBy: string, page: number, rowsPerPage: number) => void;
|
|
39
|
+
/** The zero-based index of the current page for paginated table */
|
|
40
|
+
page?: number;
|
|
40
41
|
/** Rows per page for paginated table */
|
|
41
42
|
rowsPerPage?: RowsPerPageOption;
|
|
42
43
|
/** Table is sortable */
|
|
@@ -53,4 +54,4 @@ export declare function stableSort<T>(array: T[], comparator: (order: T, orderBy
|
|
|
53
54
|
* A wrapper component around the Table component from @material-ui. This component can be used for
|
|
54
55
|
* creating a common structure for tables in the system.
|
|
55
56
|
*/
|
|
56
|
-
export declare const DotTable: ({ ariaLabel, className, columns, count, data, "data-testid": dataTestId, emptyMessage, loading, maxHeight, order, orderBy, onRowClick, onUpdateData, rowsPerPage, stickyHeader, sortable, toolbar, }: TableProps) => JSX.Element;
|
|
57
|
+
export declare const DotTable: ({ ariaLabel, className, columns, count, data, "data-testid": dataTestId, emptyMessage, loading, maxHeight, order, orderBy, onRowClick, onUpdateData, page, rowsPerPage, stickyHeader, sortable, toolbar, }: TableProps) => JSX.Element;
|
|
@@ -3,6 +3,14 @@ export declare const defaultColumns: ({
|
|
|
3
3
|
id: string;
|
|
4
4
|
label: string;
|
|
5
5
|
width: string;
|
|
6
|
+
truncate: boolean;
|
|
7
|
+
align?: undefined;
|
|
8
|
+
sortable?: undefined;
|
|
9
|
+
} | {
|
|
10
|
+
id: string;
|
|
11
|
+
label: string;
|
|
12
|
+
width: string;
|
|
13
|
+
truncate?: undefined;
|
|
6
14
|
align?: undefined;
|
|
7
15
|
sortable?: undefined;
|
|
8
16
|
} | {
|
|
@@ -10,6 +18,7 @@ export declare const defaultColumns: ({
|
|
|
10
18
|
label: string;
|
|
11
19
|
align: string;
|
|
12
20
|
width: string;
|
|
21
|
+
truncate?: undefined;
|
|
13
22
|
sortable?: undefined;
|
|
14
23
|
} | {
|
|
15
24
|
id: string;
|
|
@@ -17,6 +26,7 @@ export declare const defaultColumns: ({
|
|
|
17
26
|
width: string;
|
|
18
27
|
align: string;
|
|
19
28
|
label?: undefined;
|
|
29
|
+
truncate?: undefined;
|
|
20
30
|
})[];
|
|
21
31
|
export declare const defaultData: ({
|
|
22
32
|
id: string;
|
|
@@ -37,11 +47,19 @@ export declare const defaultData: ({
|
|
|
37
47
|
};
|
|
38
48
|
selected?: undefined;
|
|
39
49
|
})[];
|
|
40
|
-
export declare const paginatedColumns: {
|
|
50
|
+
export declare const paginatedColumns: ({
|
|
41
51
|
id: string;
|
|
42
52
|
label: string;
|
|
43
53
|
width: string;
|
|
44
|
-
|
|
54
|
+
truncate: boolean;
|
|
55
|
+
align?: undefined;
|
|
56
|
+
} | {
|
|
57
|
+
id: string;
|
|
58
|
+
label: string;
|
|
59
|
+
width: string;
|
|
60
|
+
align: string;
|
|
61
|
+
truncate?: undefined;
|
|
62
|
+
})[];
|
|
45
63
|
export declare const paginatedData: {
|
|
46
64
|
id: string;
|
|
47
65
|
rowData: {
|