@true-engineering/true-react-common-ui-kit 1.0.2 → 1.1.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/dist/components/AccountInfo/AccountInfo.d.ts +4 -4
- package/dist/components/AccountInfo/AccountInfo.styles.d.ts +60 -56
- package/dist/components/AddButton/AddButton.d.ts +6 -6
- package/dist/components/AddButton/AddButton.styles.d.ts +23 -23
- package/dist/components/Button/Button.d.ts +19 -33
- package/dist/components/Button/Button.styles.d.ts +144 -144
- package/dist/components/Checkbox/Checkbox.d.ts +16 -27
- package/dist/components/Checkbox/Checkbox.styles.d.ts +39 -42
- package/dist/components/CloseButton/CloseButton.d.ts +4 -4
- package/dist/components/CloseButton/CloseButton.styles.d.ts +22 -22
- package/dist/components/Colors/Colors.styles.d.ts +28 -28
- package/dist/components/CssBaseline/CssBaseline.d.ts +1 -1
- package/dist/components/CssBaseline/CssBaseline.styles.d.ts +7 -7
- package/dist/components/DateInput/DateInput.d.ts +8 -9
- package/dist/components/DateInput/DateInput.styles.d.ts +7 -7
- package/dist/components/DatePicker/DatePicker.d.ts +29 -36
- package/dist/components/DatePicker/DatePicker.styles.d.ts +38 -34
- package/dist/components/DatePicker/DatePickerHeader/DatePickerHeader.d.ts +9 -9
- package/dist/components/DatePicker/DatePickerHeader/DatePickerHeader.styles.d.ts +59 -59
- package/dist/components/DatePicker/DatePickerInput/DatePickerInput.d.ts +7 -9
- package/dist/components/DatePicker/DatePickerInput/DatePickerInput.styles.d.ts +16 -16
- package/dist/components/Description/Description.d.ts +6 -6
- package/dist/components/Description/Description.styles.d.ts +18 -18
- package/dist/components/FiltersPane/FilterInterval/FilterInterval.d.ts +19 -19
- package/dist/components/FiltersPane/FilterInterval/FilterInterval.styles.d.ts +44 -44
- package/dist/components/FiltersPane/FilterMultiSelect/FilterMultiSelect.d.ts +2 -8
- package/dist/components/FiltersPane/FilterSelect/FilterSelect.d.ts +17 -35
- package/dist/components/FiltersPane/FilterSelect/FilterSelect.styles.d.ts +111 -111
- package/dist/components/FiltersPane/FilterSelect/locales.d.ts +6 -10
- package/dist/components/FiltersPane/FilterValueView/FilterValueView.d.ts +1 -9
- package/dist/components/FiltersPane/FilterValueView/FilterValueView.styles.d.ts +8 -8
- package/dist/components/FiltersPane/FilterWithDates/FilterWithDates.d.ts +13 -21
- package/dist/components/FiltersPane/FilterWithDates/FilterWithDates.styles.d.ts +41 -41
- package/dist/components/FiltersPane/FilterWithPeriod/FilterWithPeriod.d.ts +8 -8
- package/dist/components/FiltersPane/FilterWithPeriod/FilterWithPeriod.styles.d.ts +7 -7
- package/dist/components/FiltersPane/FilterWrapper/FilterWrapper.d.ts +18 -41
- package/dist/components/FiltersPane/FilterWrapper/FilterWrapper.styles.d.ts +92 -92
- package/dist/components/FiltersPane/FiltersPane.d.ts +15 -34
- package/dist/components/FiltersPane/FiltersPane.styles.d.ts +50 -50
- package/dist/components/FiltersPane/FiltersPaneSearch/FiltersPaneSearch.d.ts +18 -37
- package/dist/components/FiltersPane/FiltersPaneSearch/FiltersPaneSearch.styles.d.ts +82 -82
- package/dist/components/FiltersPane/locales.d.ts +22 -28
- package/dist/components/FiltersPane/types.d.ts +38 -65
- package/dist/components/Flag/Flag.d.ts +2 -2
- package/dist/components/Flag/Flag.styles.d.ts +8 -8
- package/dist/components/FlexibleTable/FlexibleTable.d.ts +20 -45
- package/dist/components/FlexibleTable/FlexibleTable.styles.d.ts +93 -93
- package/dist/components/FlexibleTable/TableRow.d.ts +21 -38
- package/dist/components/FlexibleTable/TableValue.d.ts +16 -28
- package/dist/components/FlexibleTable/types.d.ts +31 -37
- package/dist/components/Icon/ComplexIconBoilerplate.d.ts +1 -1
- package/dist/components/Icon/Icon.d.ts +2 -2
- package/dist/components/Icon/Icon.styles.d.ts +4 -4
- package/dist/components/Icon/IconBoilerplate.d.ts +1 -1
- package/dist/components/Icon/complexIcons/icons.d.ts +1 -1
- package/dist/components/Icon/icons/icons.d.ts +5 -97
- package/dist/components/IncrementInput/ChangeButton.d.ts +5 -5
- package/dist/components/IncrementInput/IncrementInput.d.ts +3 -4
- package/dist/components/IncrementInput/IncrementInput.styles.d.ts +52 -52
- package/dist/components/Input/Input.d.ts +37 -48
- package/dist/components/Input/Input.styles.d.ts +242 -242
- package/dist/components/List/List.d.ts +12 -12
- package/dist/components/List/List.styles.d.ts +35 -35
- package/dist/components/Modal/Modal.d.ts +19 -19
- package/dist/components/Modal/Modal.styles.d.ts +235 -235
- package/dist/components/MoreMenu/MoreMenu.d.ts +7 -7
- package/dist/components/MoreMenu/MoreMenu.styles.d.ts +45 -45
- package/dist/components/MultiSelect/MultiSelect.d.ts +13 -28
- package/dist/components/MultiSelect/MultiSelect.styles.d.ts +38 -38
- package/dist/components/MultiSelect/MultiSelectInput/MultiSelectInput.d.ts +6 -12
- package/dist/components/MultiSelect/MultiSelectInput/MultiSelectInput.styles.d.ts +58 -58
- package/dist/components/MultiSelectList/MultiSelectList.d.ts +20 -43
- package/dist/components/MultiSelectList/MultiSelectList.styles.d.ts +90 -90
- package/dist/components/MultiSelectList/locales.d.ts +6 -10
- package/dist/components/Notification/Notification.d.ts +9 -14
- package/dist/components/Notification/Notification.styles.d.ts +30 -33
- package/dist/components/NumberInput/NumberInput.d.ts +10 -16
- package/dist/components/NumberInput/helpers.d.ts +2 -10
- package/dist/components/PhoneInput/PhoneInput.d.ts +7 -14
- package/dist/components/PhoneInput/PhoneInput.styles.d.ts +60 -60
- package/dist/components/PhoneInput/PhoneInputCountryList/PhoneInputCountryList.d.ts +7 -7
- package/dist/components/PhoneInput/PhoneInputCountryList/PhoneInputCountryList.styles.d.ts +74 -78
- package/dist/components/PhoneInput/types.d.ts +11 -11
- package/dist/components/RadioButton/RadioButton.d.ts +8 -18
- package/dist/components/RadioButton/RadioButton.styles.d.ts +25 -25
- package/dist/components/ScrollIntoViewIfNeeded/ScrollIntoViewIfNeeded.d.ts +374 -634
- package/dist/components/SearchInput/SearchInput.d.ts +2 -12
- package/dist/components/SearchInput/SearchInput.styles.d.ts +32 -32
- package/dist/components/Select/Select.d.ts +22 -50
- package/dist/components/Select/Select.styles.d.ts +53 -53
- package/dist/components/Select/SelectList/SelectList.d.ts +15 -30
- package/dist/components/Select/SelectList/SelectList.styles.d.ts +35 -37
- package/dist/components/Select/helpers.d.ts +2 -9
- package/dist/components/SmartInput/SmartInput.d.ts +16 -28
- package/dist/components/SmartInput/helpers.d.ts +4 -8
- package/dist/components/Switch/Switch.d.ts +13 -26
- package/dist/components/Switch/Switch.styles.d.ts +58 -58
- package/dist/components/TextArea/TextArea.d.ts +23 -26
- package/dist/components/TextArea/TextArea.styles.d.ts +124 -124
- package/dist/components/TextWithInfo/TextWithInfo.d.ts +9 -9
- package/dist/components/TextWithInfo/TextWithInfo.styles.d.ts +40 -40
- package/dist/components/TextWithTooltip/TextWithTooltip.d.ts +12 -12
- package/dist/components/TextWithTooltip/TextWithTooltip.styles.d.ts +10 -10
- package/dist/components/ThemedPreloader/ThemedPreloader.d.ts +4 -4
- package/dist/components/ThemedPreloader/ThemedPreloader.styles.d.ts +10 -10
- package/dist/components/ThemedPreloader/components/DotsPreloader/DotsPreloader.d.ts +1 -1
- package/dist/components/ThemedPreloader/components/DotsPreloader/DotsPreloader.styles.d.ts +35 -35
- package/dist/components/ThemedPreloader/components/SvgPreloader/SvgPreloader.d.ts +2 -2
- package/dist/components/ThemedPreloader/components/SvgPreloader/SvgPreloader.styles.d.ts +5 -5
- package/dist/components/Toaster/Toaster.d.ts +11 -16
- package/dist/components/Toaster/Toaster.styles.d.ts +41 -41
- package/dist/components/Tooltip/Tooltip.d.ts +4 -4
- package/dist/components/Tooltip/Tooltip.styles.d.ts +27 -25
- package/dist/helpers/data-attributes.d.ts +4 -11
- package/dist/helpers/phone.d.ts +8 -28
- package/dist/helpers/utils.d.ts +7 -28
- package/dist/hooks/use-did-mount-effect.d.ts +1 -4
- package/dist/hooks/use-dropdown.d.ts +7 -14
- package/dist/hooks/use-is-mounted.d.ts +1 -1
- package/dist/hooks/use-on-click-outside.d.ts +4 -25
- package/dist/hooks/use-theme.d.ts +5 -10
- package/dist/hooks/use-tweak-styles.d.ts +1 -5
- package/dist/style.css +90 -205
- package/dist/theme.d.ts +55 -51
- package/dist/true-react-common-ui-kit.js +16713 -24318
- package/dist/true-react-common-ui-kit.js.map +1 -1
- package/dist/true-react-common-ui-kit.umd.cjs +18 -16
- package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
- package/dist/types.d.ts +23 -77
- package/package.json +1 -1
- package/src/components/Select/Select.tsx +21 -13
- package/src/components/Select/SelectList/SelectList.tsx +8 -6
- package/src/components/Select/helpers.ts +9 -6
- package/src/components/SmartInput/SmartInput.tsx +130 -127
|
@@ -1,45 +1,28 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { FlexibleTableConfigType } from './types';
|
|
3
3
|
import { ICommonProps } from '../../types';
|
|
4
|
-
interface ITableRowProps<Values extends Record<string, any>>
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
cell: {
|
|
25
|
-
root: string;
|
|
26
|
-
sticky: string;
|
|
27
|
-
second: string;
|
|
4
|
+
interface ITableRowProps<Values extends Record<string, any>> extends ICommonProps {
|
|
5
|
+
item: Values;
|
|
6
|
+
uniqueField?: keyof Values;
|
|
7
|
+
isFirstColumnSticky?: boolean;
|
|
8
|
+
isActive: boolean;
|
|
9
|
+
config?: FlexibleTableConfigType<Values>;
|
|
10
|
+
enabledColumns?: Array<keyof Values>;
|
|
11
|
+
rowAttributes?: Array<keyof Values>;
|
|
12
|
+
expandableRowComponent?: (item: Values, isOpen: boolean, close: () => void) => React.ReactNode;
|
|
13
|
+
onRowHover?: (id?: string) => void;
|
|
14
|
+
onRowClick?: (id: string) => void;
|
|
15
|
+
classes: {
|
|
16
|
+
root: string;
|
|
17
|
+
active: string;
|
|
18
|
+
editable: string;
|
|
19
|
+
cell: {
|
|
20
|
+
root: string;
|
|
21
|
+
sticky: string;
|
|
22
|
+
second: string;
|
|
23
|
+
};
|
|
28
24
|
};
|
|
29
|
-
};
|
|
30
25
|
}
|
|
31
|
-
declare function TableRow<Values extends Record<string, any>>({
|
|
32
|
-
item,
|
|
33
|
-
uniqueField,
|
|
34
|
-
isFirstColumnSticky,
|
|
35
|
-
isActive,
|
|
36
|
-
config,
|
|
37
|
-
enabledColumns,
|
|
38
|
-
onRowHover,
|
|
39
|
-
onRowClick,
|
|
40
|
-
rowAttributes,
|
|
41
|
-
expandableRowComponent,
|
|
42
|
-
classes,
|
|
43
|
-
}: ITableRowProps<Values>): JSX.Element;
|
|
26
|
+
declare function TableRow<Values extends Record<string, any>>({ item, uniqueField, isFirstColumnSticky, isActive, config, enabledColumns, onRowHover, onRowClick, rowAttributes, expandableRowComponent, classes, }: ITableRowProps<Values>): JSX.Element;
|
|
44
27
|
declare const _default: typeof TableRow;
|
|
45
28
|
export default _default;
|
|
@@ -1,33 +1,21 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import type { ICommonProps } from '../../types';
|
|
3
3
|
import type { FlexibleTableConfigType } from './types';
|
|
4
|
-
interface ITableValueProps<Values extends Record<string, any>>
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
onSetNestedComponent: (component?: ReactNode) => void;
|
|
4
|
+
interface ITableValueProps<Values extends Record<string, any>> extends ICommonProps {
|
|
5
|
+
item: Values;
|
|
6
|
+
columnName: keyof Values;
|
|
7
|
+
config?: FlexibleTableConfigType<Values>;
|
|
8
|
+
classes: {
|
|
9
|
+
root: string;
|
|
10
|
+
sticky: string;
|
|
11
|
+
second: string;
|
|
12
|
+
};
|
|
13
|
+
isFocusedRow?: boolean;
|
|
14
|
+
isSecond?: boolean;
|
|
15
|
+
isSticky?: boolean;
|
|
16
|
+
isNestedComponentExpanded: boolean;
|
|
17
|
+
isRowNestedComponentExpanded: boolean;
|
|
18
|
+
onSetNestedComponent: (component?: ReactNode) => void;
|
|
20
19
|
}
|
|
21
|
-
declare function TableValue<Values extends Record<string, any>>({
|
|
22
|
-
item,
|
|
23
|
-
columnName,
|
|
24
|
-
config,
|
|
25
|
-
classes,
|
|
26
|
-
isFocusedRow,
|
|
27
|
-
isSecond,
|
|
28
|
-
isSticky,
|
|
29
|
-
isNestedComponentExpanded,
|
|
30
|
-
isRowNestedComponentExpanded,
|
|
31
|
-
onSetNestedComponent,
|
|
32
|
-
}: ITableValueProps<Values>): JSX.Element;
|
|
20
|
+
declare function TableValue<Values extends Record<string, any>>({ item, columnName, config, classes, isFocusedRow, isSecond, isSticky, isNestedComponentExpanded, isRowNestedComponentExpanded, onSetNestedComponent, }: ITableValueProps<Values>): JSX.Element;
|
|
33
21
|
export default TableValue;
|
|
@@ -1,50 +1,44 @@
|
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
|
2
2
|
export declare type ITextAlignment = 'left' | 'center' | 'right';
|
|
3
|
-
export declare type IVerticalAlignment =
|
|
4
|
-
| 'middle'
|
|
5
|
-
| 'top'
|
|
6
|
-
| 'bottom'
|
|
7
|
-
| 'baseline'
|
|
8
|
-
| 'sub'
|
|
9
|
-
| string;
|
|
3
|
+
export declare type IVerticalAlignment = 'middle' | 'top' | 'bottom' | 'baseline' | 'sub' | string;
|
|
10
4
|
export declare type IPosition = 'sticky' | 'absolute' | 'relative' | 'static';
|
|
11
5
|
export declare type ITitleComponent<Value> = FC<{
|
|
12
|
-
|
|
6
|
+
value?: Value;
|
|
13
7
|
}>;
|
|
14
8
|
export declare type IValueComponent<Values, Value> = FC<{
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
9
|
+
value?: Value;
|
|
10
|
+
row: Values;
|
|
11
|
+
isFocusedRow?: boolean;
|
|
12
|
+
isNestedComponentExpanded: boolean;
|
|
13
|
+
isRowNestedComponentExpanded: boolean;
|
|
14
|
+
onSetNestedComponent: (component?: ReactNode) => void;
|
|
21
15
|
}>;
|
|
22
16
|
export declare type FlexibleTableConfigType<Values> = {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
17
|
+
[Key in keyof Values]?: {
|
|
18
|
+
title?: ReactNode;
|
|
19
|
+
titleComponent?: ITitleComponent<any>;
|
|
20
|
+
component?: IValueComponent<Values, Values[Key]>;
|
|
21
|
+
dateFormat?: string;
|
|
22
|
+
minWidth?: string | number;
|
|
23
|
+
width?: string | number;
|
|
24
|
+
maxWidth?: string | number;
|
|
25
|
+
titleAlign?: ITextAlignment;
|
|
26
|
+
cellAlign?: ITextAlignment;
|
|
27
|
+
cellVerticalAlign?: IVerticalAlignment;
|
|
28
|
+
position?: IPosition;
|
|
29
|
+
right?: number;
|
|
30
|
+
left?: number;
|
|
31
|
+
};
|
|
38
32
|
};
|
|
39
33
|
export interface IInfinityScrollConfig {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
34
|
+
activePage: number;
|
|
35
|
+
totalPages: number;
|
|
36
|
+
isLoading: boolean;
|
|
37
|
+
isLastPage: boolean;
|
|
38
|
+
onInfinityScroll: (skip: number) => void;
|
|
45
39
|
}
|
|
46
40
|
export interface INestedComponent {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
41
|
+
isOpen: boolean;
|
|
42
|
+
component?: ReactNode;
|
|
43
|
+
cellKey?: string;
|
|
50
44
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
import { IComplexIcon } from './complexIcons';
|
|
3
3
|
interface IComplexIconBoilerplateProps {
|
|
4
|
-
|
|
4
|
+
type: IComplexIcon;
|
|
5
5
|
}
|
|
6
6
|
declare const ComplexIconBoilerplate: FC<IComplexIconBoilerplateProps>;
|
|
7
7
|
export default ComplexIconBoilerplate;
|
|
@@ -5,7 +5,7 @@ import { IComplexIcon } from './complexIcons';
|
|
|
5
5
|
import { IconStyles } from './Icon.styles';
|
|
6
6
|
export declare type IIconType = ICommonIcon | IComplexIcon;
|
|
7
7
|
export interface IIconProps extends ICommonProps {
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
tweakStyles?: IconStyles;
|
|
9
|
+
type: IIconType;
|
|
10
10
|
}
|
|
11
11
|
export declare const Icon: React.FC<IIconProps>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ComponentStyles } from '../../types';
|
|
2
2
|
export declare const styles: {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
root: {
|
|
4
|
+
display: string;
|
|
5
|
+
alignItems: string;
|
|
6
|
+
};
|
|
7
7
|
};
|
|
8
8
|
export declare type IconStyles = ComponentStyles<typeof styles>;
|
|
@@ -1,101 +1,9 @@
|
|
|
1
1
|
import { SVGAttributes } from 'react';
|
|
2
2
|
export interface ISvgIcon {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
viewBox?: string;
|
|
4
|
+
paths?: Array<SVGAttributes<never>>;
|
|
5
|
+
circles?: Array<SVGAttributes<never>>;
|
|
6
|
+
rects?: Array<SVGAttributes<never>>;
|
|
7
7
|
}
|
|
8
|
-
export declare const icons: Record<
|
|
9
|
-
| 'direction'
|
|
10
|
-
| 'filter'
|
|
11
|
-
| 'search'
|
|
12
|
-
| 'repeat'
|
|
13
|
-
| 'link'
|
|
14
|
-
| 'sort'
|
|
15
|
-
| 'document'
|
|
16
|
-
| 'vendor-service'
|
|
17
|
-
| 'aircraft-takeoff'
|
|
18
|
-
| 'archive'
|
|
19
|
-
| 'arrow'
|
|
20
|
-
| 'arrow-right'
|
|
21
|
-
| 'baggage'
|
|
22
|
-
| 'balloon'
|
|
23
|
-
| 'bluetooth'
|
|
24
|
-
| 'bonus'
|
|
25
|
-
| 'book'
|
|
26
|
-
| 'box'
|
|
27
|
-
| 'business'
|
|
28
|
-
| 'calendar'
|
|
29
|
-
| 'cancel'
|
|
30
|
-
| 'check'
|
|
31
|
-
| 'check-big'
|
|
32
|
-
| 'check-all'
|
|
33
|
-
| 'chevron-down'
|
|
34
|
-
| 'chevron-left'
|
|
35
|
-
| 'chevron-right'
|
|
36
|
-
| 'chevron-up'
|
|
37
|
-
| 'chevron-down-small'
|
|
38
|
-
| 'chevron-left-small'
|
|
39
|
-
| 'chevron-right-small'
|
|
40
|
-
| 'chevron-up-small'
|
|
41
|
-
| 'circle-check'
|
|
42
|
-
| 'close'
|
|
43
|
-
| 'close-large'
|
|
44
|
-
| 'close-window'
|
|
45
|
-
| 'copy'
|
|
46
|
-
| 'copy-outline'
|
|
47
|
-
| 'crane'
|
|
48
|
-
| 'danger'
|
|
49
|
-
| 'download'
|
|
50
|
-
| 'email'
|
|
51
|
-
| 'eye'
|
|
52
|
-
| 'eye-closed'
|
|
53
|
-
| 'female'
|
|
54
|
-
| 'food'
|
|
55
|
-
| 'information'
|
|
56
|
-
| 'insurance'
|
|
57
|
-
| 'list'
|
|
58
|
-
| 'lock'
|
|
59
|
-
| 'lock-open'
|
|
60
|
-
| 'male'
|
|
61
|
-
| 'menu'
|
|
62
|
-
| 'minus'
|
|
63
|
-
| 'burger-menu'
|
|
64
|
-
| 'pencil'
|
|
65
|
-
| 'pin'
|
|
66
|
-
| 'plane'
|
|
67
|
-
| 'plane-circle'
|
|
68
|
-
| 'plus'
|
|
69
|
-
| 'print'
|
|
70
|
-
| 'question'
|
|
71
|
-
| 'refresh'
|
|
72
|
-
| 'rocket'
|
|
73
|
-
| 'round-trip'
|
|
74
|
-
| 'vendor-logo'
|
|
75
|
-
| 'scan'
|
|
76
|
-
| 'send-email'
|
|
77
|
-
| 'settings'
|
|
78
|
-
| 'sign-out'
|
|
79
|
-
| 'size'
|
|
80
|
-
| 'sort-asc'
|
|
81
|
-
| 'sort-desc'
|
|
82
|
-
| 'sort-list-asc'
|
|
83
|
-
| 'sort-list-desc'
|
|
84
|
-
| 'star'
|
|
85
|
-
| 'status-error'
|
|
86
|
-
| 'status-info'
|
|
87
|
-
| 'status-not-ok'
|
|
88
|
-
| 'status-ok'
|
|
89
|
-
| 'status-warning'
|
|
90
|
-
| 'three-circles'
|
|
91
|
-
| 'ticket-revert'
|
|
92
|
-
| 'ticket'
|
|
93
|
-
| 'time'
|
|
94
|
-
| 'trash-can'
|
|
95
|
-
| 'upgrade'
|
|
96
|
-
| 'user'
|
|
97
|
-
| 'user-group'
|
|
98
|
-
| 'voucher',
|
|
99
|
-
ISvgIcon
|
|
100
|
-
>;
|
|
8
|
+
export declare const icons: Record<"direction" | "filter" | "search" | "repeat" | "link" | "sort" | "document" | "vendor-service" | "aircraft-takeoff" | "archive" | "arrow" | "arrow-right" | "baggage" | "balloon" | "bluetooth" | "bonus" | "book" | "box" | "business" | "calendar" | "cancel" | "check" | "check-big" | "check-all" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up" | "chevron-down-small" | "chevron-left-small" | "chevron-right-small" | "chevron-up-small" | "circle-check" | "close" | "close-large" | "close-window" | "copy" | "copy-outline" | "crane" | "danger" | "download" | "email" | "eye" | "eye-closed" | "female" | "food" | "information" | "insurance" | "list" | "lock" | "lock-open" | "male" | "menu" | "minus" | "burger-menu" | "pencil" | "pin" | "plane" | "plane-circle" | "plus" | "print" | "question" | "refresh" | "rocket" | "round-trip" | "vendor-logo" | "scan" | "send-email" | "settings" | "sign-out" | "size" | "sort-asc" | "sort-desc" | "sort-list-asc" | "sort-list-desc" | "star" | "status-error" | "status-info" | "status-not-ok" | "status-ok" | "status-warning" | "three-circles" | "ticket-revert" | "ticket" | "time" | "trash-can" | "upgrade" | "user" | "user-group" | "voucher", ISvgIcon>;
|
|
101
9
|
export declare type ICommonIcon = keyof typeof icons;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
import { Classes } from 'jss';
|
|
3
3
|
interface IChangeButtonProps {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
type: 'plus' | 'minus';
|
|
5
|
+
isButtonDisabled: boolean;
|
|
6
|
+
isInvalid?: boolean;
|
|
7
|
+
classes: Classes<'button' | 'disabledButton' | 'errorButton'>;
|
|
8
|
+
onClick: () => void;
|
|
9
9
|
}
|
|
10
10
|
export declare const ChangeButton: FC<IChangeButtonProps>;
|
|
11
11
|
export {};
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
import { INumberInputProps } from '../NumberInput';
|
|
3
3
|
import { IncrementInputStyles } from './IncrementInput.styles';
|
|
4
|
-
export interface IIncrementInputProps
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
step?: number;
|
|
4
|
+
export interface IIncrementInputProps extends Omit<INumberInputProps, 'canBeFloat' | 'precision'> {
|
|
5
|
+
tweakStyles?: IncrementInputStyles;
|
|
6
|
+
step?: number;
|
|
8
7
|
}
|
|
9
8
|
export declare const IncrementInput: FC<IIncrementInputProps>;
|
|
@@ -2,62 +2,62 @@ import { ComponentStyles } from '../../types';
|
|
|
2
2
|
export declare const BUTTONS_WIDTH = 36;
|
|
3
3
|
export declare const BUTTONS_GAP = 2;
|
|
4
4
|
export declare const styles: {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
};
|
|
10
|
-
buttons: {
|
|
11
|
-
display: string;
|
|
12
|
-
flexDirection: string;
|
|
13
|
-
width: number;
|
|
14
|
-
position: string;
|
|
15
|
-
right: number;
|
|
16
|
-
top: number;
|
|
17
|
-
bottom: number;
|
|
18
|
-
zIndex: number;
|
|
19
|
-
};
|
|
20
|
-
button: {
|
|
21
|
-
width: string;
|
|
22
|
-
height: number;
|
|
23
|
-
border: string;
|
|
24
|
-
outline: string;
|
|
25
|
-
backgroundColor: '#f6f8fc';
|
|
26
|
-
transition: string;
|
|
27
|
-
color: '#505f79';
|
|
28
|
-
cursor: string;
|
|
29
|
-
display: string;
|
|
30
|
-
alignItems: string;
|
|
31
|
-
justifyContent: string;
|
|
32
|
-
padding: number[];
|
|
33
|
-
'&:hover, &:focus': {
|
|
34
|
-
backgroundColor: '#dde3ed';
|
|
5
|
+
root: {
|
|
6
|
+
display: string;
|
|
7
|
+
alignItems: string;
|
|
8
|
+
position: string;
|
|
35
9
|
};
|
|
36
|
-
|
|
37
|
-
|
|
10
|
+
buttons: {
|
|
11
|
+
display: string;
|
|
12
|
+
flexDirection: string;
|
|
13
|
+
width: number;
|
|
14
|
+
position: string;
|
|
15
|
+
right: number;
|
|
16
|
+
top: number;
|
|
17
|
+
bottom: number;
|
|
18
|
+
zIndex: number;
|
|
38
19
|
};
|
|
39
|
-
|
|
40
|
-
|
|
20
|
+
button: {
|
|
21
|
+
width: string;
|
|
22
|
+
height: number;
|
|
23
|
+
border: string;
|
|
24
|
+
outline: string;
|
|
25
|
+
backgroundColor: "#f6f8fc";
|
|
26
|
+
transition: string;
|
|
27
|
+
color: "#505f79";
|
|
28
|
+
cursor: string;
|
|
29
|
+
display: string;
|
|
30
|
+
alignItems: string;
|
|
31
|
+
justifyContent: string;
|
|
32
|
+
padding: number[];
|
|
33
|
+
'&:hover, &:focus': {
|
|
34
|
+
backgroundColor: "#dde3ed";
|
|
35
|
+
};
|
|
36
|
+
'&:active': {
|
|
37
|
+
backgroundColor: "#95a0b3";
|
|
38
|
+
};
|
|
39
|
+
'&:first-child': {
|
|
40
|
+
marginBottom: number;
|
|
41
|
+
};
|
|
41
42
|
};
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
43
|
+
disabledButton: {
|
|
44
|
+
backgroundColor: "#ffffff";
|
|
45
|
+
color: "#95a0b3";
|
|
46
|
+
cursor: string;
|
|
47
|
+
'&:hover': {
|
|
48
|
+
backgroundColor: "#ffffff";
|
|
49
|
+
};
|
|
49
50
|
};
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
51
|
+
errorButton: {};
|
|
52
|
+
tweakInput: {
|
|
53
|
+
input: {
|
|
54
|
+
'&:not($withControls)': {
|
|
55
|
+
paddingRight: number;
|
|
56
|
+
};
|
|
57
|
+
};
|
|
58
|
+
controls: {
|
|
59
|
+
paddingRight: number;
|
|
60
|
+
};
|
|
57
61
|
};
|
|
58
|
-
controls: {
|
|
59
|
-
paddingRight: number;
|
|
60
|
-
};
|
|
61
|
-
};
|
|
62
62
|
};
|
|
63
63
|
export declare type IncrementInputStyles = ComponentStyles<typeof styles>;
|
|
@@ -5,52 +5,41 @@ import { ICommonProps } from '../../types';
|
|
|
5
5
|
import { InputStyles } from './Input.styles';
|
|
6
6
|
export declare const DEFAULT_SIZE = 6;
|
|
7
7
|
export interface IInputProps extends ICommonProps {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
maxLength?: number;
|
|
45
|
-
testId?: string;
|
|
46
|
-
tabIndex?: number;
|
|
47
|
-
onChange(value: string, event: FormEvent<HTMLInputElement>): void;
|
|
48
|
-
onFocus?(event: FocusEvent<HTMLInputElement>): void;
|
|
49
|
-
onBlur?(event: FocusEvent<HTMLInputElement>): void;
|
|
50
|
-
onPaste?(event: ClipboardEvent<HTMLInputElement>): void;
|
|
51
|
-
onIconClick?(): void;
|
|
52
|
-
onKeyDown?(event: KeyboardEvent<HTMLInputElement>): void;
|
|
8
|
+
tweakStyles?: InputStyles;
|
|
9
|
+
value?: string;
|
|
10
|
+
label?: string;
|
|
11
|
+
placeholder?: string;
|
|
12
|
+
type?: 'text' | 'password' | 'email' | 'number';
|
|
13
|
+
isDisabled?: boolean;
|
|
14
|
+
hasFloatingLabel?: boolean;
|
|
15
|
+
isReadonly?: boolean;
|
|
16
|
+
isInvalid?: boolean;
|
|
17
|
+
isActive?: boolean;
|
|
18
|
+
isClearable?: boolean;
|
|
19
|
+
infoMessage?: string;
|
|
20
|
+
errorMessage?: string;
|
|
21
|
+
errorPosition?: 'top' | 'bottom';
|
|
22
|
+
inlineStyle?: 'top' | 'bottom' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right' | 'left' | 'right' | 'middle';
|
|
23
|
+
border?: 'top' | 'bottom' | 'left' | 'right';
|
|
24
|
+
isRequired?: boolean;
|
|
25
|
+
isLoading?: boolean;
|
|
26
|
+
isAutoSizeable?: boolean;
|
|
27
|
+
defaultSize?: number;
|
|
28
|
+
iconType?: IIconProps['type'];
|
|
29
|
+
units?: string;
|
|
30
|
+
name?: string;
|
|
31
|
+
mask?: ReactInputMaskProps['mask'];
|
|
32
|
+
maskPlaceholder?: ReactInputMaskProps['maskPlaceholder'];
|
|
33
|
+
hasRequiredLabel?: boolean;
|
|
34
|
+
shouldFocusOnMount?: boolean;
|
|
35
|
+
maxLength?: number;
|
|
36
|
+
testId?: string;
|
|
37
|
+
tabIndex?: number;
|
|
38
|
+
onChange(value: string, event: FormEvent<HTMLInputElement>): void;
|
|
39
|
+
onFocus?(event: FocusEvent<HTMLInputElement>): void;
|
|
40
|
+
onBlur?(event: FocusEvent<HTMLInputElement>): void;
|
|
41
|
+
onPaste?(event: ClipboardEvent<HTMLInputElement>): void;
|
|
42
|
+
onIconClick?(): void;
|
|
43
|
+
onKeyDown?(event: KeyboardEvent<HTMLInputElement>): void;
|
|
53
44
|
}
|
|
54
|
-
export declare const Input: import(
|
|
55
|
-
IInputProps & import('react').RefAttributes<HTMLInputElement>
|
|
56
|
-
>;
|
|
45
|
+
export declare const Input: import("react").ForwardRefExoticComponent<IInputProps & import("react").RefAttributes<HTMLInputElement>>;
|