@wavv/ui 1.9.15 → 1.9.16
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/build/cjs/index.js +4 -4
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/types/components/Button/Button.d.ts +3 -3
- package/build/cjs/types/components/Button/ButtonLoader.d.ts +1 -1
- package/build/cjs/types/components/ChartHelpers.d.ts +2 -2
- package/build/cjs/types/components/Dropdown/Dropdown.d.ts +1 -1
- package/build/cjs/types/components/Dropdown/DropdownUtils.d.ts +3 -0
- package/build/cjs/types/components/Form.d.ts +12 -19
- package/build/cjs/types/components/MessageHr.d.ts +2 -2
- package/build/cjs/types/components/Options.d.ts +3 -1
- package/build/cjs/types/hooks/useSelect.d.ts +1 -1
- package/build/esm/index.js +4 -4
- package/build/esm/index.js.map +1 -1
- package/build/esm/types/components/Button/Button.d.ts +3 -3
- package/build/esm/types/components/Button/ButtonLoader.d.ts +1 -1
- package/build/esm/types/components/ChartHelpers.d.ts +2 -2
- package/build/esm/types/components/Dropdown/Dropdown.d.ts +1 -1
- package/build/esm/types/components/Dropdown/DropdownUtils.d.ts +3 -0
- package/build/esm/types/components/Form.d.ts +12 -19
- package/build/esm/types/components/MessageHr.d.ts +2 -2
- package/build/esm/types/components/Options.d.ts +3 -1
- package/build/esm/types/hooks/useSelect.d.ts +1 -1
- package/build/index.d.ts +81 -80
- package/build/types/components/Button/Button.d.ts +3 -3
- package/build/types/components/Button/ButtonLoader.d.ts +1 -1
- package/build/types/components/ChartHelpers.d.ts +2 -2
- package/build/types/components/Dropdown/Dropdown.d.ts +1 -1
- package/build/types/components/Dropdown/DropdownUtils.d.ts +3 -0
- package/build/types/components/Form.d.ts +12 -19
- package/build/types/components/MessageHr.d.ts +2 -2
- package/build/types/components/Options.d.ts +3 -1
- package/build/types/hooks/useSelect.d.ts +1 -1
- package/package.json +13 -13
|
@@ -4,14 +4,14 @@ import { BasicButtonProps, ButtonComponentProps } from './ButtonTypes';
|
|
|
4
4
|
/** Button Component */
|
|
5
5
|
declare const Button: {
|
|
6
6
|
(props: ButtonComponentProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
-
Group: ({ children, disabled, outline, size, small, large, secondary, negative, positive, caution, collapse, ...props }: {
|
|
8
|
-
children: (import("react").ReactElement<BasicButtonProps | ButtonComponentProps, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<import("
|
|
7
|
+
Group: ({ children, disabled, outline, size, small, large, secondary, negative, positive, caution, collapse, ...props }: ({
|
|
8
|
+
children: (import("react").ReactElement<BasicButtonProps | ButtonComponentProps, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<import("../Tooltip").TooltipProps, string | import("react").JSXElementConstructor<any>>) | (import("react").ReactElement<BasicButtonProps | ButtonComponentProps, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<import("../Tooltip").TooltipProps, string | import("react").JSXElementConstructor<any>>)[];
|
|
9
9
|
disabled?: boolean | undefined;
|
|
10
10
|
size?: "small" | "large" | "medium" | undefined;
|
|
11
11
|
small?: boolean | undefined;
|
|
12
12
|
large?: boolean | undefined;
|
|
13
13
|
outline?: boolean | undefined;
|
|
14
14
|
collapse?: boolean | undefined;
|
|
15
|
-
} & import("./ButtonTypes").ButtonStyles & Margin & import("../types").Width) => import("react/jsx-runtime").JSX.Element | null;
|
|
15
|
+
} & import("./ButtonTypes").ButtonStyles) & Margin & import("../types").Width) => import("react/jsx-runtime").JSX.Element | null;
|
|
16
16
|
};
|
|
17
17
|
export default Button;
|
|
@@ -30,7 +30,7 @@ export declare const ChartContainer: import("@emotion/styled").StyledComponent<{
|
|
|
30
30
|
export declare const TooltipContent: ({ active, payload, label }: TooltipProps<number, string>) => import("react/jsx-runtime").JSX.Element | null;
|
|
31
31
|
export declare const Tooltip: () => import("react/jsx-runtime").JSX.Element;
|
|
32
32
|
export declare const LegendContent: ({ payload, toggleData, }: {
|
|
33
|
-
payload?: Payload[]
|
|
34
|
-
toggleData?: (
|
|
33
|
+
payload?: Payload[];
|
|
34
|
+
toggleData?: (item: Payload) => void;
|
|
35
35
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
36
36
|
export {};
|
|
@@ -80,6 +80,6 @@ type DropdownProps<OptionType> = {
|
|
|
80
80
|
} & WidthHeight & Margin & RestInputProps;
|
|
81
81
|
declare const Dropdown: {
|
|
82
82
|
<OptionType extends OptionItem>({ onChange, onTextChange, afterShow, afterHide, onFocus, onBlur, onError, placeholder, placeholderColor, value, options, children, borderless, borderColor, backgroundColor, hideIcon, clearOnSelect, textOnly, width, height, isLoading, margin, marginTop, marginBottom, marginRight, marginLeft, label, id, name, trigger, centerY, centerX, offsetY, offsetX, direction, fontSize, description, disabled, invalid, search, filter, restrictInput, inputRef, optionsParent, ...props }: DropdownProps<OptionType>): import("react/jsx-runtime").JSX.Element;
|
|
83
|
-
Item<OptionType_1 extends OptionItem>({ value, displayText, setValue, close, children, contentPosition, color, accented, onClick, id, }: DropdownItemProps<OptionType_1>): import("react/jsx-runtime").JSX.Element;
|
|
83
|
+
Item<OptionType_1 extends OptionItem>({ value, displayText, setValue, close, children, contentPosition, color, accented, onClick, id, section, }: DropdownItemProps<OptionType_1>): import("react/jsx-runtime").JSX.Element;
|
|
84
84
|
};
|
|
85
85
|
export default Dropdown;
|
|
@@ -5,6 +5,7 @@ export type OptionItem = {
|
|
|
5
5
|
label: string;
|
|
6
6
|
header?: string;
|
|
7
7
|
body?: string;
|
|
8
|
+
type?: 'section';
|
|
8
9
|
leftElement?: ReactElement;
|
|
9
10
|
rightElement?: ReactElement;
|
|
10
11
|
onClick?: (event?: MouseEvent | Event) => void;
|
|
@@ -29,6 +30,8 @@ export type DropdownItemProps<OptionType> = {
|
|
|
29
30
|
onClick?: (event: MouseEvent) => void;
|
|
30
31
|
/** The id of the Item element */
|
|
31
32
|
id: number | string;
|
|
33
|
+
/** Sets the Item as a section separator */
|
|
34
|
+
section?: boolean;
|
|
32
35
|
};
|
|
33
36
|
export type SetEvent = MouseEvent | ChangeEvent | KeyboardEvent;
|
|
34
37
|
export type SetValueFunc = <OptionType extends OptionItem>(selection: OptionType | string | null, event?: SetEvent) => void;
|
|
@@ -9,14 +9,7 @@ type FormProps = {
|
|
|
9
9
|
declare const Form: {
|
|
10
10
|
({ children, rows, columns, rowGap, columnGap, onSubmit, ...rest }: FormProps): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
Group({ children, rows, columns, rowGap, columnGap, disabled, ...rest }: FormGroupProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
-
Field({ children, inline, align, disabled, ...props }: {
|
|
13
|
-
/** Sets the flexDirection of the Field to 'row' instead of 'column' */
|
|
14
|
-
inline?: boolean | undefined;
|
|
15
|
-
/** Sets the vertical alignment of the Field's contents */
|
|
16
|
-
align?: "center" | "top" | "bottom" | undefined;
|
|
17
|
-
/** Disables pointer events and reduces the opacity of the Field's contents */
|
|
18
|
-
disabled?: boolean | undefined;
|
|
19
|
-
} & Margin & {
|
|
12
|
+
Field({ children, inline, align, disabled, ...props }: FieldProps & {
|
|
20
13
|
children?: ReactNode;
|
|
21
14
|
}): import("react/jsx-runtime").JSX.Element;
|
|
22
15
|
Input: import("react").ForwardRefExoticComponent<(Omit<{
|
|
@@ -26,8 +19,8 @@ declare const Form: {
|
|
|
26
19
|
placeholderColor?: string | undefined;
|
|
27
20
|
description?: string | undefined;
|
|
28
21
|
isLoading?: boolean | undefined;
|
|
29
|
-
iconLeft?: import("
|
|
30
|
-
iconRight?: import("
|
|
22
|
+
iconLeft?: import("./helpers/getIcon").IconType | undefined;
|
|
23
|
+
iconRight?: import("./helpers/getIcon").IconType | undefined;
|
|
31
24
|
invalid?: boolean | undefined;
|
|
32
25
|
borderless?: boolean | undefined;
|
|
33
26
|
borderRadius?: string | number | undefined;
|
|
@@ -59,8 +52,8 @@ declare const Form: {
|
|
|
59
52
|
placeholderColor?: string | undefined;
|
|
60
53
|
description?: string | undefined;
|
|
61
54
|
isLoading?: boolean | undefined;
|
|
62
|
-
iconLeft?: import("
|
|
63
|
-
iconRight?: import("
|
|
55
|
+
iconLeft?: import("./helpers/getIcon").IconType | undefined;
|
|
56
|
+
iconRight?: import("./helpers/getIcon").IconType | undefined;
|
|
64
57
|
invalid?: boolean | undefined;
|
|
65
58
|
borderless?: boolean | undefined;
|
|
66
59
|
borderRadius?: string | number | undefined;
|
|
@@ -87,7 +80,7 @@ declare const Form: {
|
|
|
87
80
|
onChange?: ((event: import("react").ChangeEvent<HTMLInputElement>, formatted: string, raw: string) => void) | undefined;
|
|
88
81
|
} & Margin & import("./types").Padding, "ref">) & import("react").RefAttributes<import("./types").InputRef>>;
|
|
89
82
|
Dropdown: {
|
|
90
|
-
<OptionType extends import("
|
|
83
|
+
<OptionType extends import("./Dropdown").DropdownOption>({ onChange, onTextChange, afterShow, afterHide, onFocus, onBlur, onError, placeholder, placeholderColor, value, options, children, borderless, borderColor, backgroundColor, hideIcon, clearOnSelect, textOnly, width, height, isLoading, margin, marginTop, marginBottom, marginRight, marginLeft, label, id, name, trigger, centerY, centerX, offsetY, offsetX, direction, fontSize, description, disabled, invalid, search, filter, restrictInput, inputRef, optionsParent, ...props }: {
|
|
91
84
|
children?: ReactNode;
|
|
92
85
|
onChange?: ((item: OptionType | null) => void) | undefined;
|
|
93
86
|
onTextChange?: ((text: string) => void) | undefined;
|
|
@@ -125,8 +118,8 @@ declare const Form: {
|
|
|
125
118
|
restrictInput?: boolean | ((text: string) => boolean) | undefined;
|
|
126
119
|
inputRef?: import("react").RefObject<import("./types").InputRef> | undefined;
|
|
127
120
|
optionsParent?: string | undefined;
|
|
128
|
-
} & import("./types").Width & import("./types").Height & Margin & import("
|
|
129
|
-
Item<OptionType_1 extends import("
|
|
121
|
+
} & import("./types").Width & import("./types").Height & Margin & import("./Dropdown").InputProps): import("react/jsx-runtime").JSX.Element;
|
|
122
|
+
Item<OptionType_1 extends import("./Dropdown").DropdownOption>({ value, displayText, setValue, close, children, contentPosition, color, accented, onClick, id, section, }: import("./Dropdown/DropdownUtils").DropdownItemProps<OptionType_1>): import("react/jsx-runtime").JSX.Element;
|
|
130
123
|
};
|
|
131
124
|
Radio: ({ id, label, labelPosition, checked, disabled, margin, marginTop, marginBottom, marginRight, marginLeft, ...props }: {
|
|
132
125
|
id?: string | undefined;
|
|
@@ -142,7 +135,7 @@ declare const Form: {
|
|
|
142
135
|
disabled?: boolean | undefined;
|
|
143
136
|
checked?: boolean | undefined;
|
|
144
137
|
onChange: (val: boolean) => void;
|
|
145
|
-
} & Margin & import("./types").As & import("
|
|
138
|
+
} & Margin & import("./types").As & import("./FormControl").CheckboxAttributes) => import("react/jsx-runtime").JSX.Element;
|
|
146
139
|
Checkbox: ({ id, label, labelPosition, checked, partial, disabled, onChange, margin, marginTop, marginBottom, marginRight, marginLeft, ...props }: {
|
|
147
140
|
id?: string | undefined;
|
|
148
141
|
label?: string | undefined;
|
|
@@ -151,11 +144,11 @@ declare const Form: {
|
|
|
151
144
|
checked?: boolean | undefined;
|
|
152
145
|
partial?: boolean | undefined;
|
|
153
146
|
onChange: (val: boolean) => void;
|
|
154
|
-
} & Margin & import("./types").As & import("
|
|
147
|
+
} & Margin & import("./types").As & import("./FormControl").CheckboxAttributes) => import("react/jsx-runtime").JSX.Element;
|
|
155
148
|
Label: ({ children, iconLeft, iconRight, disabled, pill, ...rest }: {
|
|
156
149
|
children?: ReactNode;
|
|
157
|
-
iconLeft?: import("
|
|
158
|
-
iconRight?: import("
|
|
150
|
+
iconLeft?: import("./helpers/getIcon").IconType | undefined;
|
|
151
|
+
iconRight?: import("./helpers/getIcon").IconType | undefined;
|
|
159
152
|
pill?: boolean | undefined;
|
|
160
153
|
disabled?: boolean | undefined;
|
|
161
154
|
} & Margin) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,10 +2,10 @@ declare const MessageHr: ({ text, color, style, }: {
|
|
|
2
2
|
/** The text to be displayed */
|
|
3
3
|
text: string | number;
|
|
4
4
|
/** The color of the text displayed */
|
|
5
|
-
color?: string
|
|
5
|
+
color?: string;
|
|
6
6
|
/** Sets the style prop of the text */
|
|
7
7
|
style?: {
|
|
8
8
|
[key: string]: string | number;
|
|
9
|
-
}
|
|
9
|
+
};
|
|
10
10
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export default MessageHr;
|
|
@@ -23,7 +23,7 @@ type OptionsProps = {
|
|
|
23
23
|
} & Width;
|
|
24
24
|
declare const Options: {
|
|
25
25
|
({ id, children, containerRef, parentSelector, width, maxHeight, offsetY, offsetX, centerY, centerX, direction, }: OptionsProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
-
Item({ children, id, onClick, selected, noSelect, contentPosition, color, accented, ...props }: OptionsItemProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
Item({ children, id, onClick, selected, noSelect, contentPosition, color, accented, section, ...props }: OptionsItemProps): import("react/jsx-runtime").JSX.Element;
|
|
27
27
|
};
|
|
28
28
|
type OptionsItemProps = {
|
|
29
29
|
children?: ReactNode;
|
|
@@ -41,5 +41,7 @@ type OptionsItemProps = {
|
|
|
41
41
|
color?: string;
|
|
42
42
|
/** Sets the Option text color to theme.accent */
|
|
43
43
|
accented?: boolean;
|
|
44
|
+
/** Sets the Option as a section separator */
|
|
45
|
+
section?: boolean;
|
|
44
46
|
};
|
|
45
47
|
export default Options;
|
|
@@ -13,7 +13,7 @@ type UseSelectProps<OptionType> = {
|
|
|
13
13
|
isOpen: boolean;
|
|
14
14
|
/** The condition for when the select element is focused */
|
|
15
15
|
isFocused?: boolean;
|
|
16
|
-
/** The text from a search
|
|
16
|
+
/** The text from a search Dropdown */
|
|
17
17
|
searchText?: string;
|
|
18
18
|
};
|
|
19
19
|
declare const useSelect: <OptionType extends OptionItem>({ options, select, close, open, searchText, isOpen, isFocused, }: UseSelectProps<OptionType>) => readonly [number, import("react").RefObject<HTMLDivElement>];
|