@digital-ai/dot-components 1.1.0 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dot-components.esm.js +4075 -5126
- package/dot-components.umd.js +4201 -5245
- package/fonts/dot.woff +0 -0
- package/fonts/selection.json +651 -444
- package/lib/components/BaseButtonProps.d.ts +3 -1
- package/lib/components/app-logo/AppLogo.d.ts +11 -0
- package/lib/components/app-toolbar/AppToolbar.d.ts +5 -1
- package/lib/components/app-toolbar/AppToolbar.styles.d.ts +1 -0
- package/lib/components/auto-complete/AutoComplete.d.ts +11 -1
- package/lib/components/avatar/Avatar.d.ts +3 -1
- package/lib/components/badge/Badge.d.ts +14 -0
- package/lib/components/badge/Badge.styles.d.ts +3 -0
- package/lib/components/button/Button.d.ts +2 -2
- package/lib/components/button/IconButton.d.ts +6 -2
- package/lib/components/dynamic-form/DynamicForm.d.ts +11 -0
- package/lib/components/dynamic-form/DynamicForm.styles.d.ts +2 -0
- package/lib/components/dynamic-form/constants.d.ts +4 -0
- package/lib/components/dynamic-form/helpers.d.ts +38 -0
- package/lib/components/dynamic-form/models.d.ts +68 -0
- package/lib/components/dynamic-form/sample.d.ts +4 -0
- package/lib/components/dynamic-form/validation.d.ts +25 -0
- package/lib/components/icon/Icon.d.ts +5 -3
- package/lib/components/index.d.ts +12 -7
- package/lib/components/input-form-fields/InputText.d.ts +4 -1
- package/lib/components/link/Link.d.ts +4 -2
- package/lib/components/list/List.d.ts +17 -5
- package/lib/components/list/List.styles.d.ts +1 -0
- package/lib/components/menu/Menu.d.ts +9 -1
- package/lib/components/menu/Menu.styles.d.ts +1 -0
- package/lib/components/progress/Progress.d.ts +4 -2
- package/lib/components/sidebar/Sidebar.d.ts +9 -1
- package/lib/components/split-button/SplitButton.d.ts +1 -1
- package/lib/components/split-button/SplitButton.styles.d.ts +1 -1
- package/lib/components/table/Table.stories.data.d.ts +13 -5
- package/lib/components/table/Table.styles.d.ts +2 -0
- package/lib/components/table/TableCell.d.ts +4 -2
- package/lib/components/table/TableRow.d.ts +6 -2
- package/lib/components/tooltip/Tooltip.d.ts +9 -0
- package/lib/theme-provider/colors/agility-dark-theme-colors.d.ts +9 -0
- package/lib/theme-provider/colors/agility-light-theme-colors.d.ts +11 -0
- package/lib/theme-provider/colors/light-theme-colors.d.ts +2 -1
- package/package.json +1 -1
|
@@ -22,11 +22,11 @@ export declare const defaultColumns: ({
|
|
|
22
22
|
sortable?: undefined;
|
|
23
23
|
} | {
|
|
24
24
|
id: string;
|
|
25
|
+
label: string;
|
|
25
26
|
sortable: boolean;
|
|
26
|
-
width
|
|
27
|
-
align: string;
|
|
28
|
-
label?: undefined;
|
|
27
|
+
width?: undefined;
|
|
29
28
|
truncate?: undefined;
|
|
29
|
+
align?: undefined;
|
|
30
30
|
})[];
|
|
31
31
|
export declare const defaultData: ({
|
|
32
32
|
id: string;
|
|
@@ -35,7 +35,11 @@ export declare const defaultData: ({
|
|
|
35
35
|
title: string;
|
|
36
36
|
hometown: string;
|
|
37
37
|
fans: number;
|
|
38
|
-
delete:
|
|
38
|
+
delete: {
|
|
39
|
+
children: JSX.Element;
|
|
40
|
+
key: string;
|
|
41
|
+
onclick: () => void;
|
|
42
|
+
}[];
|
|
39
43
|
};
|
|
40
44
|
} | {
|
|
41
45
|
id: string;
|
|
@@ -43,7 +47,11 @@ export declare const defaultData: ({
|
|
|
43
47
|
title: string;
|
|
44
48
|
hometown: string;
|
|
45
49
|
fans: number;
|
|
46
|
-
delete:
|
|
50
|
+
delete: {
|
|
51
|
+
children: JSX.Element;
|
|
52
|
+
key: string;
|
|
53
|
+
onclick: () => void;
|
|
54
|
+
}[];
|
|
47
55
|
};
|
|
48
56
|
selected?: undefined;
|
|
49
57
|
})[];
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { Paper } from '@material-ui/core';
|
|
2
3
|
export declare const rootClassName = "dot-table";
|
|
3
4
|
export declare const StyledPaper: import("styled-components").StyledComponent<typeof Paper, any, {}, never>;
|
|
4
5
|
export declare const StyledTableContainer: import("styled-components").StyledComponent<import("@material-ui/core/OverridableComponent").OverridableComponent<import("@material-ui/core").TableContainerTypeMap<{}, "div">>, any, {}, never>;
|
|
6
|
+
export declare const StyledMenu: import("styled-components").StyledComponent<({ anchorEl, ariaLabel, className, "data-testid": dataTestId, dense, disablePortal, id, loading, maxVisibleItems, menuItemHeight, menuItems, menuPlacement, onLeave, onSelect, open, }: import("../menu/Menu").MenuProps) => JSX.Element, any, {}, never>;
|
|
@@ -1,14 +1,16 @@
|
|
|
1
|
-
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
2
|
import { CommonProps } from '../CommonProps';
|
|
3
3
|
export declare type textAlignment = 'center' | 'inherit' | 'justify' | 'left' | 'right';
|
|
4
4
|
export interface CellProps extends CommonProps {
|
|
5
5
|
align?: textAlignment;
|
|
6
|
+
cellKey?: string;
|
|
6
7
|
colspan?: number;
|
|
7
8
|
id?: string;
|
|
8
9
|
noWrap?: boolean;
|
|
9
10
|
value?: any;
|
|
11
|
+
onActionMenuTrigger?: (el: HTMLElement, menuItem: Array<ReactNode>) => void;
|
|
10
12
|
}
|
|
11
13
|
/**
|
|
12
14
|
* A wrapper component around the TableCell component from @material-ui.
|
|
13
15
|
*/
|
|
14
|
-
export declare const DotBodyCell: ({ ariaLabel, align, className, colspan, "data-testid": dataTestId,
|
|
16
|
+
export declare const DotBodyCell: ({ ariaLabel, align, cellKey, className, colspan, "data-testid": dataTestId, noWrap, value, onActionMenuTrigger, }: CellProps) => JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MouseEvent } from 'react';
|
|
1
|
+
import { MouseEvent, ReactNode } from 'react';
|
|
2
2
|
import { DotColumnHeader } from './TableHeader';
|
|
3
3
|
import { CommonProps } from '../CommonProps';
|
|
4
4
|
import { TableRowProps } from './Table';
|
|
@@ -11,8 +11,12 @@ export interface RowProps extends CommonProps {
|
|
|
11
11
|
columns: Array<DotColumnHeader>;
|
|
12
12
|
/** The table body row data */
|
|
13
13
|
data: TableRowProps;
|
|
14
|
+
/** Event callback of action button of menu */
|
|
15
|
+
onActionMenuTrigger: (el: HTMLElement, menuItem: Array<ReactNode>) => void;
|
|
14
16
|
/** Event callback */
|
|
15
17
|
onClick?: (event: MouseEvent, id: string) => void;
|
|
18
|
+
/** uniques key of table cell */
|
|
19
|
+
rowKey: string;
|
|
16
20
|
/** if the row is selected */
|
|
17
21
|
selected?: boolean;
|
|
18
22
|
}
|
|
@@ -20,5 +24,5 @@ export interface RowProps extends CommonProps {
|
|
|
20
24
|
* A wrapper component around the TableRow component from @material-ui. This component can be used
|
|
21
25
|
* for manipulating data prior to displaying the data inside the table
|
|
22
26
|
*/
|
|
23
|
-
export declare const DotTableRow: ({ columns, data, onClick, selected }: RowProps) => JSX.Element;
|
|
27
|
+
export declare const DotTableRow: ({ columns, data, onActionMenuTrigger, onClick, rowKey, selected, }: RowProps) => JSX.Element;
|
|
24
28
|
export declare const EmptyDotRow: ({ cols, message, }: EmptyRowProps) => JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactNode, ReactElement } from 'react';
|
|
2
|
+
import { CommonProps } from '../CommonProps';
|
|
3
|
+
export declare type tooltipPlacement = 'bottom-end' | 'bottom-start' | 'bottom' | 'left-end' | 'left-start' | 'left' | 'right-end' | 'right-start' | 'right' | 'top-end' | 'top-start' | 'top';
|
|
4
|
+
export interface TooltipProps extends CommonProps {
|
|
5
|
+
children: ReactElement;
|
|
6
|
+
placement?: tooltipPlacement;
|
|
7
|
+
title?: ReactNode | string | number;
|
|
8
|
+
}
|
|
9
|
+
export declare const DotTooltip: ({ ariaLabel, children, className, "data-testid": dataTestId, placement, title, }: TooltipProps) => JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const n0 = "#050A0A";
|
|
2
|
+
export declare const n50 = "#14262E";
|
|
3
|
+
export declare const n100 = "#244451";
|
|
4
|
+
export declare const n200 = "#336275";
|
|
5
|
+
export declare const n300 = "#7CB0C5";
|
|
6
|
+
export declare const n400 = "#9FC5D5";
|
|
7
|
+
export declare const n500 = "#E6F0F4";
|
|
8
|
+
export declare const n600 = "#C3DBE4";
|
|
9
|
+
export declare const n700 = "#FFFFFF";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const n0 = "#E6F0F4";
|
|
2
|
+
export declare const n50 = "#FFFFFF";
|
|
3
|
+
export declare const n100 = "#C3DBE4";
|
|
4
|
+
export declare const n200 = "#9FC5D5";
|
|
5
|
+
export declare const n300 = "#7CB0C5";
|
|
6
|
+
export declare const n400 = "#589BB6";
|
|
7
|
+
export declare const n500 = "#438098";
|
|
8
|
+
export declare const n600 = "#326174";
|
|
9
|
+
export declare const n700 = "#244451";
|
|
10
|
+
export declare const n800 = "#14262E";
|
|
11
|
+
export declare const n900 = "#000000";
|
|
@@ -97,4 +97,5 @@ export declare const pA100 = "#ff9cd1";
|
|
|
97
97
|
export declare const pA200 = "#ff69b9";
|
|
98
98
|
export declare const pA400 = "#ff36a2";
|
|
99
99
|
export declare const pA700 = "#ff1d96";
|
|
100
|
-
export declare const agilityGreen = "#
|
|
100
|
+
export declare const agilityGreen = "#79b522";
|
|
101
|
+
export declare const agilityLightGreen = "#e4efd3";
|