opus-toolkit-components 1.9.3 → 1.9.5
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.
|
@@ -1,35 +1,98 @@
|
|
|
1
|
-
export interface DropdownItem {
|
|
2
|
-
label: string;
|
|
3
|
-
value: string | number;
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
export interface DropdownChangeEvent {
|
|
7
|
-
target: {
|
|
8
|
-
name: string;
|
|
9
|
-
value: string | number;
|
|
10
|
-
};
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export type IconComponent = (
|
|
14
|
-
props: React.SVGProps<SVGSVGElement>,
|
|
15
|
-
) => JSX.Element;
|
|
16
|
-
|
|
17
|
-
export interface DropdownProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
18
|
-
items?: DropdownItem[];
|
|
19
|
-
label?: string;
|
|
20
|
-
isValid?: boolean;
|
|
21
|
-
required?: boolean;
|
|
22
|
-
placeholder?: string;
|
|
23
|
-
name?: string;
|
|
24
|
-
className?: string;
|
|
25
|
-
title?: string;
|
|
26
|
-
tabIndex?: string | number;
|
|
27
|
-
onChange?: (event: DropdownChangeEvent) => void;
|
|
28
|
-
value?: string | number;
|
|
29
|
-
Icon?: IconComponent;
|
|
30
|
-
errorMessage?: string;
|
|
31
|
-
disabled?: boolean;
|
|
32
|
-
dataCy?: string;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
export const Dropdown: React.ComponentType<DropdownProps>;
|
|
1
|
+
export interface DropdownItem {
|
|
2
|
+
label: string;
|
|
3
|
+
value: string | number;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
export interface DropdownChangeEvent {
|
|
7
|
+
target: {
|
|
8
|
+
name: string;
|
|
9
|
+
value: string | number;
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export type IconComponent = (
|
|
14
|
+
props: React.SVGProps<SVGSVGElement>,
|
|
15
|
+
) => JSX.Element;
|
|
16
|
+
|
|
17
|
+
export interface DropdownProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
18
|
+
items?: DropdownItem[];
|
|
19
|
+
label?: string;
|
|
20
|
+
isValid?: boolean;
|
|
21
|
+
required?: boolean;
|
|
22
|
+
placeholder?: string;
|
|
23
|
+
name?: string;
|
|
24
|
+
className?: string;
|
|
25
|
+
title?: string;
|
|
26
|
+
tabIndex?: string | number;
|
|
27
|
+
onChange?: (event: DropdownChangeEvent) => void;
|
|
28
|
+
value?: string | number;
|
|
29
|
+
Icon?: IconComponent;
|
|
30
|
+
errorMessage?: string;
|
|
31
|
+
disabled?: boolean;
|
|
32
|
+
dataCy?: string;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export const Dropdown: React.ComponentType<DropdownProps>;
|
|
36
|
+
|
|
37
|
+
export interface SearchDropdownProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
38
|
+
items?: DropdownItem[];
|
|
39
|
+
label?: string;
|
|
40
|
+
isValid?: boolean;
|
|
41
|
+
required?: boolean;
|
|
42
|
+
placeholder?: string;
|
|
43
|
+
searchPlaceholder?: string;
|
|
44
|
+
name?: string;
|
|
45
|
+
className?: string;
|
|
46
|
+
title?: string;
|
|
47
|
+
tabIndex?: string | number;
|
|
48
|
+
onChange?: (event: DropdownChangeEvent) => void;
|
|
49
|
+
value?: string | number;
|
|
50
|
+
Icon?: IconComponent;
|
|
51
|
+
errorMessage?: string;
|
|
52
|
+
disabled?: boolean;
|
|
53
|
+
noResultsText?: string;
|
|
54
|
+
dataCy?: string;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export const SearchDropdown: React.ComponentType<SearchDropdownProps>;
|
|
58
|
+
|
|
59
|
+
export interface SearchMultiSelectDropdownChangeEvent {
|
|
60
|
+
target: {
|
|
61
|
+
name: string;
|
|
62
|
+
value: Array<string | number>;
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export interface SearchMultiSelectDropdownProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
67
|
+
items?: DropdownItem[];
|
|
68
|
+
label?: string;
|
|
69
|
+
isValid?: boolean;
|
|
70
|
+
required?: boolean;
|
|
71
|
+
placeholder?: string;
|
|
72
|
+
searchPlaceholder?: string;
|
|
73
|
+
name?: string;
|
|
74
|
+
className?: string;
|
|
75
|
+
title?: string;
|
|
76
|
+
tabIndex?: string | number;
|
|
77
|
+
onChange?: (event: SearchMultiSelectDropdownChangeEvent) => void;
|
|
78
|
+
onApply?: (event: SearchMultiSelectDropdownChangeEvent) => void;
|
|
79
|
+
value?: Array<string | number>;
|
|
80
|
+
Icon?: IconComponent;
|
|
81
|
+
errorMessage?: string;
|
|
82
|
+
disabled?: boolean;
|
|
83
|
+
noResultsText?: string;
|
|
84
|
+
applyButtonText?: string;
|
|
85
|
+
footer?:
|
|
86
|
+
| React.ReactNode
|
|
87
|
+
| ((context: {
|
|
88
|
+
close: () => void;
|
|
89
|
+
searchTerm: string;
|
|
90
|
+
filteredItems: DropdownItem[];
|
|
91
|
+
selectedItems: DropdownItem[];
|
|
92
|
+
selectedValues: Array<string | number>;
|
|
93
|
+
applySelection: () => void;
|
|
94
|
+
}) => React.ReactNode);
|
|
95
|
+
dataCy?: string;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export const SearchMultiSelectDropdown: React.ComponentType<SearchMultiSelectDropdownProps>;
|
|
@@ -1,38 +1,30 @@
|
|
|
1
|
-
export interface
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
panelClassName?: string;
|
|
32
|
-
bodyClassName?: string;
|
|
33
|
-
className?: string;
|
|
34
|
-
dataCy?: string;
|
|
35
|
-
name?: string;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export const FilterPopover: React.ComponentType<FilterPopoverProps>;
|
|
1
|
+
export interface PopoverRenderContext {
|
|
2
|
+
isOpen: boolean;
|
|
3
|
+
openPopover: () => void;
|
|
4
|
+
closePopover: () => void;
|
|
5
|
+
togglePopover: () => void;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export interface PopoverProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
9
|
+
icon?: React.ReactNode;
|
|
10
|
+
triggerTitle?: string;
|
|
11
|
+
header?: React.ReactNode;
|
|
12
|
+
hideHeader?: boolean;
|
|
13
|
+
body?: React.ReactNode | ((context: PopoverRenderContext) => React.ReactNode);
|
|
14
|
+
hideFooter?: boolean;
|
|
15
|
+
children?:
|
|
16
|
+
| React.ReactNode
|
|
17
|
+
| ((context: PopoverRenderContext) => React.ReactNode);
|
|
18
|
+
footer?:
|
|
19
|
+
| React.ReactNode
|
|
20
|
+
| ((context: PopoverRenderContext) => React.ReactNode);
|
|
21
|
+
panelClassName?: string;
|
|
22
|
+
headerClassName?: string;
|
|
23
|
+
bodyClassName?: string;
|
|
24
|
+
footerClassName?: string;
|
|
25
|
+
className?: string;
|
|
26
|
+
dataCy?: string;
|
|
27
|
+
name?: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export const Popover: React.ComponentType<PopoverProps>;
|
|
@@ -1,29 +1,30 @@
|
|
|
1
|
-
export interface RadioOption {
|
|
2
|
-
value: string | number;
|
|
3
|
-
label: string;
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
export interface RadioChangeEvent {
|
|
7
|
-
target: {
|
|
8
|
-
name: string;
|
|
9
|
-
value: string | number;
|
|
10
|
-
};
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export interface RadioButtonProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
14
|
-
label: string;
|
|
15
|
-
options?: RadioOption[];
|
|
16
|
-
name: string;
|
|
17
|
-
value?: string | number;
|
|
18
|
-
onChange?: (event: RadioChangeEvent) => void;
|
|
19
|
-
className?: string;
|
|
20
|
-
tabIndex?: string | number;
|
|
21
|
-
title?: string;
|
|
22
|
-
isValid?: boolean;
|
|
23
|
-
errorMessage?: string;
|
|
24
|
-
required?: boolean;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
1
|
+
export interface RadioOption {
|
|
2
|
+
value: string | number;
|
|
3
|
+
label: string;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
export interface RadioChangeEvent {
|
|
7
|
+
target: {
|
|
8
|
+
name: string;
|
|
9
|
+
value: string | number;
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface RadioButtonProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
14
|
+
label: string;
|
|
15
|
+
options?: RadioOption[];
|
|
16
|
+
name: string;
|
|
17
|
+
value?: string | number;
|
|
18
|
+
onChange?: (event: RadioChangeEvent) => void;
|
|
19
|
+
className?: string;
|
|
20
|
+
tabIndex?: string | number;
|
|
21
|
+
title?: string;
|
|
22
|
+
isValid?: boolean;
|
|
23
|
+
errorMessage?: string;
|
|
24
|
+
required?: boolean;
|
|
25
|
+
hideLabel?: boolean;
|
|
26
|
+
dataCy?: string;
|
|
27
|
+
disabled?: boolean;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export const RadioButton: React.FC<RadioButtonProps>;
|