@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.
Files changed (134) hide show
  1. package/dist/components/AccountInfo/AccountInfo.d.ts +4 -4
  2. package/dist/components/AccountInfo/AccountInfo.styles.d.ts +60 -56
  3. package/dist/components/AddButton/AddButton.d.ts +6 -6
  4. package/dist/components/AddButton/AddButton.styles.d.ts +23 -23
  5. package/dist/components/Button/Button.d.ts +19 -33
  6. package/dist/components/Button/Button.styles.d.ts +144 -144
  7. package/dist/components/Checkbox/Checkbox.d.ts +16 -27
  8. package/dist/components/Checkbox/Checkbox.styles.d.ts +39 -42
  9. package/dist/components/CloseButton/CloseButton.d.ts +4 -4
  10. package/dist/components/CloseButton/CloseButton.styles.d.ts +22 -22
  11. package/dist/components/Colors/Colors.styles.d.ts +28 -28
  12. package/dist/components/CssBaseline/CssBaseline.d.ts +1 -1
  13. package/dist/components/CssBaseline/CssBaseline.styles.d.ts +7 -7
  14. package/dist/components/DateInput/DateInput.d.ts +8 -9
  15. package/dist/components/DateInput/DateInput.styles.d.ts +7 -7
  16. package/dist/components/DatePicker/DatePicker.d.ts +29 -36
  17. package/dist/components/DatePicker/DatePicker.styles.d.ts +38 -34
  18. package/dist/components/DatePicker/DatePickerHeader/DatePickerHeader.d.ts +9 -9
  19. package/dist/components/DatePicker/DatePickerHeader/DatePickerHeader.styles.d.ts +59 -59
  20. package/dist/components/DatePicker/DatePickerInput/DatePickerInput.d.ts +7 -9
  21. package/dist/components/DatePicker/DatePickerInput/DatePickerInput.styles.d.ts +16 -16
  22. package/dist/components/Description/Description.d.ts +6 -6
  23. package/dist/components/Description/Description.styles.d.ts +18 -18
  24. package/dist/components/FiltersPane/FilterInterval/FilterInterval.d.ts +19 -19
  25. package/dist/components/FiltersPane/FilterInterval/FilterInterval.styles.d.ts +44 -44
  26. package/dist/components/FiltersPane/FilterMultiSelect/FilterMultiSelect.d.ts +2 -8
  27. package/dist/components/FiltersPane/FilterSelect/FilterSelect.d.ts +17 -35
  28. package/dist/components/FiltersPane/FilterSelect/FilterSelect.styles.d.ts +111 -111
  29. package/dist/components/FiltersPane/FilterSelect/locales.d.ts +6 -10
  30. package/dist/components/FiltersPane/FilterValueView/FilterValueView.d.ts +1 -9
  31. package/dist/components/FiltersPane/FilterValueView/FilterValueView.styles.d.ts +8 -8
  32. package/dist/components/FiltersPane/FilterWithDates/FilterWithDates.d.ts +13 -21
  33. package/dist/components/FiltersPane/FilterWithDates/FilterWithDates.styles.d.ts +41 -41
  34. package/dist/components/FiltersPane/FilterWithPeriod/FilterWithPeriod.d.ts +8 -8
  35. package/dist/components/FiltersPane/FilterWithPeriod/FilterWithPeriod.styles.d.ts +7 -7
  36. package/dist/components/FiltersPane/FilterWrapper/FilterWrapper.d.ts +18 -41
  37. package/dist/components/FiltersPane/FilterWrapper/FilterWrapper.styles.d.ts +92 -92
  38. package/dist/components/FiltersPane/FiltersPane.d.ts +15 -34
  39. package/dist/components/FiltersPane/FiltersPane.styles.d.ts +50 -50
  40. package/dist/components/FiltersPane/FiltersPaneSearch/FiltersPaneSearch.d.ts +18 -37
  41. package/dist/components/FiltersPane/FiltersPaneSearch/FiltersPaneSearch.styles.d.ts +82 -82
  42. package/dist/components/FiltersPane/locales.d.ts +22 -28
  43. package/dist/components/FiltersPane/types.d.ts +38 -65
  44. package/dist/components/Flag/Flag.d.ts +2 -2
  45. package/dist/components/Flag/Flag.styles.d.ts +8 -8
  46. package/dist/components/FlexibleTable/FlexibleTable.d.ts +20 -45
  47. package/dist/components/FlexibleTable/FlexibleTable.styles.d.ts +93 -93
  48. package/dist/components/FlexibleTable/TableRow.d.ts +21 -38
  49. package/dist/components/FlexibleTable/TableValue.d.ts +16 -28
  50. package/dist/components/FlexibleTable/types.d.ts +31 -37
  51. package/dist/components/Icon/ComplexIconBoilerplate.d.ts +1 -1
  52. package/dist/components/Icon/Icon.d.ts +2 -2
  53. package/dist/components/Icon/Icon.styles.d.ts +4 -4
  54. package/dist/components/Icon/IconBoilerplate.d.ts +1 -1
  55. package/dist/components/Icon/complexIcons/icons.d.ts +1 -1
  56. package/dist/components/Icon/icons/icons.d.ts +5 -97
  57. package/dist/components/IncrementInput/ChangeButton.d.ts +5 -5
  58. package/dist/components/IncrementInput/IncrementInput.d.ts +3 -4
  59. package/dist/components/IncrementInput/IncrementInput.styles.d.ts +52 -52
  60. package/dist/components/Input/Input.d.ts +37 -48
  61. package/dist/components/Input/Input.styles.d.ts +242 -242
  62. package/dist/components/List/List.d.ts +12 -12
  63. package/dist/components/List/List.styles.d.ts +35 -35
  64. package/dist/components/Modal/Modal.d.ts +19 -19
  65. package/dist/components/Modal/Modal.styles.d.ts +235 -235
  66. package/dist/components/MoreMenu/MoreMenu.d.ts +7 -7
  67. package/dist/components/MoreMenu/MoreMenu.styles.d.ts +45 -45
  68. package/dist/components/MultiSelect/MultiSelect.d.ts +13 -28
  69. package/dist/components/MultiSelect/MultiSelect.styles.d.ts +38 -38
  70. package/dist/components/MultiSelect/MultiSelectInput/MultiSelectInput.d.ts +6 -12
  71. package/dist/components/MultiSelect/MultiSelectInput/MultiSelectInput.styles.d.ts +58 -58
  72. package/dist/components/MultiSelectList/MultiSelectList.d.ts +20 -43
  73. package/dist/components/MultiSelectList/MultiSelectList.styles.d.ts +90 -90
  74. package/dist/components/MultiSelectList/locales.d.ts +6 -10
  75. package/dist/components/Notification/Notification.d.ts +9 -14
  76. package/dist/components/Notification/Notification.styles.d.ts +30 -33
  77. package/dist/components/NumberInput/NumberInput.d.ts +10 -16
  78. package/dist/components/NumberInput/helpers.d.ts +2 -10
  79. package/dist/components/PhoneInput/PhoneInput.d.ts +7 -14
  80. package/dist/components/PhoneInput/PhoneInput.styles.d.ts +60 -60
  81. package/dist/components/PhoneInput/PhoneInputCountryList/PhoneInputCountryList.d.ts +7 -7
  82. package/dist/components/PhoneInput/PhoneInputCountryList/PhoneInputCountryList.styles.d.ts +74 -78
  83. package/dist/components/PhoneInput/types.d.ts +11 -11
  84. package/dist/components/RadioButton/RadioButton.d.ts +8 -18
  85. package/dist/components/RadioButton/RadioButton.styles.d.ts +25 -25
  86. package/dist/components/ScrollIntoViewIfNeeded/ScrollIntoViewIfNeeded.d.ts +374 -634
  87. package/dist/components/SearchInput/SearchInput.d.ts +2 -12
  88. package/dist/components/SearchInput/SearchInput.styles.d.ts +32 -32
  89. package/dist/components/Select/Select.d.ts +22 -50
  90. package/dist/components/Select/Select.styles.d.ts +53 -53
  91. package/dist/components/Select/SelectList/SelectList.d.ts +15 -30
  92. package/dist/components/Select/SelectList/SelectList.styles.d.ts +35 -37
  93. package/dist/components/Select/helpers.d.ts +2 -9
  94. package/dist/components/SmartInput/SmartInput.d.ts +16 -28
  95. package/dist/components/SmartInput/helpers.d.ts +4 -8
  96. package/dist/components/Switch/Switch.d.ts +13 -26
  97. package/dist/components/Switch/Switch.styles.d.ts +58 -58
  98. package/dist/components/TextArea/TextArea.d.ts +23 -26
  99. package/dist/components/TextArea/TextArea.styles.d.ts +124 -124
  100. package/dist/components/TextWithInfo/TextWithInfo.d.ts +9 -9
  101. package/dist/components/TextWithInfo/TextWithInfo.styles.d.ts +40 -40
  102. package/dist/components/TextWithTooltip/TextWithTooltip.d.ts +12 -12
  103. package/dist/components/TextWithTooltip/TextWithTooltip.styles.d.ts +10 -10
  104. package/dist/components/ThemedPreloader/ThemedPreloader.d.ts +4 -4
  105. package/dist/components/ThemedPreloader/ThemedPreloader.styles.d.ts +10 -10
  106. package/dist/components/ThemedPreloader/components/DotsPreloader/DotsPreloader.d.ts +1 -1
  107. package/dist/components/ThemedPreloader/components/DotsPreloader/DotsPreloader.styles.d.ts +35 -35
  108. package/dist/components/ThemedPreloader/components/SvgPreloader/SvgPreloader.d.ts +2 -2
  109. package/dist/components/ThemedPreloader/components/SvgPreloader/SvgPreloader.styles.d.ts +5 -5
  110. package/dist/components/Toaster/Toaster.d.ts +11 -16
  111. package/dist/components/Toaster/Toaster.styles.d.ts +41 -41
  112. package/dist/components/Tooltip/Tooltip.d.ts +4 -4
  113. package/dist/components/Tooltip/Tooltip.styles.d.ts +27 -25
  114. package/dist/helpers/data-attributes.d.ts +4 -11
  115. package/dist/helpers/phone.d.ts +8 -28
  116. package/dist/helpers/utils.d.ts +7 -28
  117. package/dist/hooks/use-did-mount-effect.d.ts +1 -4
  118. package/dist/hooks/use-dropdown.d.ts +7 -14
  119. package/dist/hooks/use-is-mounted.d.ts +1 -1
  120. package/dist/hooks/use-on-click-outside.d.ts +4 -25
  121. package/dist/hooks/use-theme.d.ts +5 -10
  122. package/dist/hooks/use-tweak-styles.d.ts +1 -5
  123. package/dist/style.css +90 -205
  124. package/dist/theme.d.ts +55 -51
  125. package/dist/true-react-common-ui-kit.js +16713 -24318
  126. package/dist/true-react-common-ui-kit.js.map +1 -1
  127. package/dist/true-react-common-ui-kit.umd.cjs +18 -16
  128. package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
  129. package/dist/types.d.ts +23 -77
  130. package/package.json +1 -1
  131. package/src/components/Select/Select.tsx +21 -13
  132. package/src/components/Select/SelectList/SelectList.tsx +8 -6
  133. package/src/components/Select/helpers.ts +9 -6
  134. package/src/components/SmartInput/SmartInput.tsx +130 -127
@@ -1,91 +1,91 @@
1
1
  import { ComponentStyles } from '../../../types';
2
2
  export declare const styles: {
3
- root: {
4
- display: string;
5
- position: string;
6
- backgroundColor: string;
7
- border: (string | number)[];
8
- borderRadius: number;
9
- paddingRight: number;
10
- transition: string;
11
- transitionProperty: string;
12
- };
13
- focused: {
14
- backgroundColor: '#ffffff';
15
- borderColor: '#d0d6e1';
16
- };
17
- disabled: {
18
- '& $selectBlock': {
19
- cursor: string;
20
- };
21
- };
22
- selectWrapper: {
23
- position: string;
24
- display: string;
25
- flexShrink: number;
26
- };
27
- selectBlock: {
28
- display: string;
29
- alignItems: string;
30
- gap: number;
31
- cursor: string;
32
- height: string;
33
- };
34
- selectLabel: {
35
- flexShrink: number;
36
- fontSize: number;
37
- userSelect: string;
38
- };
39
- chevronIcon: {
40
- flexShrink: number;
41
- width: number;
42
- height: number;
43
- marginRight: number;
44
- transition: string;
45
- opacity: number;
46
- };
47
- open: {
48
- transform: string;
49
- };
50
- dropdown: {
51
- position: string;
52
- top: number;
53
- right: number;
54
- zIndex: number;
55
- minWidth: number;
56
- marginTop: number;
57
- borderRadius: 6;
58
- backgroundColor: '#ffffff';
59
- overflow: string;
60
- };
61
- dropdownInput: {
62
- borderBottom: (string | number)[];
63
- };
64
- active: {
65
- fontWeight: string;
66
- };
67
- tweakSearchInput: {
68
- tweakInput: {
69
- inputWrapper: {
3
+ root: {
4
+ display: string;
5
+ position: string;
70
6
  backgroundColor: string;
71
- border: string;
72
- height: number;
7
+ border: (string | number)[];
8
+ borderRadius: number;
9
+ paddingRight: number;
10
+ transition: string;
11
+ transitionProperty: string;
12
+ };
13
+ focused: {
14
+ backgroundColor: "#ffffff";
15
+ borderColor: "#d0d6e1";
16
+ };
17
+ disabled: {
18
+ '& $selectBlock': {
19
+ cursor: string;
20
+ };
21
+ };
22
+ selectWrapper: {
23
+ position: string;
24
+ display: string;
25
+ flexShrink: number;
26
+ };
27
+ selectBlock: {
28
+ display: string;
29
+ alignItems: string;
30
+ gap: number;
31
+ cursor: string;
32
+ height: string;
33
+ };
34
+ selectLabel: {
35
+ flexShrink: number;
73
36
  fontSize: number;
37
+ userSelect: string;
38
+ };
39
+ chevronIcon: {
40
+ flexShrink: number;
41
+ width: number;
42
+ height: number;
43
+ marginRight: number;
44
+ transition: string;
45
+ opacity: number;
46
+ };
47
+ open: {
48
+ transform: string;
49
+ };
50
+ dropdown: {
51
+ position: string;
52
+ top: number;
53
+ right: number;
54
+ zIndex: number;
74
55
  minWidth: number;
75
- };
76
- focused: {
77
- backgroundColor: string;
78
- border: string;
79
- };
56
+ marginTop: number;
57
+ borderRadius: 6;
58
+ backgroundColor: "#ffffff";
59
+ overflow: string;
80
60
  };
81
- };
82
- tweakSelect: {
83
- root: {
84
- borderRadius: number;
85
- borderBottomLeftRadius: number;
86
- borderBottomRightRadius: number;
87
- boxShadow: string;
61
+ dropdownInput: {
62
+ borderBottom: (string | number)[];
63
+ };
64
+ active: {
65
+ fontWeight: string;
66
+ };
67
+ tweakSearchInput: {
68
+ tweakInput: {
69
+ inputWrapper: {
70
+ backgroundColor: string;
71
+ border: string;
72
+ height: number;
73
+ fontSize: number;
74
+ minWidth: number;
75
+ };
76
+ focused: {
77
+ backgroundColor: string;
78
+ border: string;
79
+ };
80
+ };
81
+ };
82
+ tweakSelect: {
83
+ root: {
84
+ borderRadius: number;
85
+ borderBottomLeftRadius: number;
86
+ borderBottomRightRadius: number;
87
+ boxShadow: string;
88
+ };
88
89
  };
89
- };
90
90
  };
91
91
  export declare type FiltersPaneSearchStyles = ComponentStyles<typeof styles>;
@@ -1,34 +1,28 @@
1
1
  export interface IFilterLocale {
2
- clear: string;
3
- all: string;
4
- other: string;
5
- chosen: string;
6
- searchPlaceholder: string;
7
- displayedFields: string;
8
- nothingFound: string;
9
- from: string;
10
- to: string;
11
- back: string;
12
- months: string[];
13
- periods: {
14
- [key: string]: string;
15
- THIS_MONTH: string;
16
- LAST_MONTH: string;
17
- THIS_YEAR: string;
18
- LAST_YEAR: string;
19
- CUSTOM: string;
20
- };
2
+ clear: string;
3
+ all: string;
4
+ other: string;
5
+ chosen: string;
6
+ searchPlaceholder: string;
7
+ displayedFields: string;
8
+ nothingFound: string;
9
+ from: string;
10
+ to: string;
11
+ back: string;
12
+ months: string[];
13
+ periods: {
14
+ [key: string]: string;
15
+ THIS_MONTH: string;
16
+ LAST_MONTH: string;
17
+ THIS_YEAR: string;
18
+ LAST_YEAR: string;
19
+ CUSTOM: string;
20
+ };
21
21
  }
22
- export declare type IPartialFilterLocale = Partial<
23
- Omit<IFilterLocale, 'periods'>
24
- > & {
25
- periods?: Partial<IFilterLocale['periods']>;
22
+ export declare type IPartialFilterLocale = Partial<Omit<IFilterLocale, 'periods'>> & {
23
+ periods?: Partial<IFilterLocale['periods']>;
26
24
  };
27
25
  export declare const FilterLocales: Record<string, IFilterLocale>;
28
26
  export declare type IFilterLocaleKey = keyof typeof FilterLocales;
29
27
  export declare const DEFAULT_LOCALE: IFilterLocaleKey;
30
- export declare const getLocale: (
31
- key?: IFilterLocaleKey,
32
- custom?: IPartialFilterLocale,
33
- custom2?: IPartialFilterLocale,
34
- ) => IFilterLocale;
28
+ export declare const getLocale: (key?: IFilterLocaleKey, custom?: IPartialFilterLocale, custom2?: IPartialFilterLocale) => IFilterLocale;
@@ -6,99 +6,72 @@ import { IFilterWithDatesProps } from './FilterWithDates';
6
6
  import { IFilterWithPeriodProps } from './FilterWithPeriod';
7
7
  import { IFilterLocaleKey, IPartialFilterLocale } from './locales';
8
8
  import { IMultiSelectListValues } from '../MultiSelectList';
9
- export declare const PERIODS: readonly [
10
- 'THIS_MONTH',
11
- 'LAST_MONTH',
12
- 'THIS_YEAR',
13
- 'LAST_YEAR',
14
- 'CUSTOM',
15
- ];
9
+ export declare const PERIODS: readonly ["THIS_MONTH", "LAST_MONTH", "THIS_YEAR", "LAST_YEAR", "CUSTOM"];
16
10
  export declare type IPeriodType = (typeof PERIODS)[number];
17
- export declare type IFilterMultiSelectValues<Option = string> =
18
- IMultiSelectListValues<Option>;
11
+ export declare type IFilterMultiSelectValues<Option = string> = IMultiSelectListValues<Option>;
19
12
  export declare type IPeriodsList = Array<IPeriodType | [string, IPeriodGetter]>;
20
13
  export interface IFiltersPaneSearchPayload<Value> {
21
- value?: string;
22
- field?: Value;
14
+ value?: string;
15
+ field?: Value;
23
16
  }
24
17
  export interface IFilterValueViewProps<Value> {
25
- value?: Value;
26
- filter: ConfigItem<Value>;
18
+ value?: Value;
19
+ filter: ConfigItem<Value>;
27
20
  }
28
21
  export interface IDatePeriod {
29
- from: Date | null;
30
- to: Date | null;
22
+ from: Date | null;
23
+ to: Date | null;
31
24
  }
32
25
  export interface IPeriod extends IDatePeriod {
33
- periodType: string;
34
- label?: string;
26
+ periodType: string;
27
+ label?: string;
35
28
  }
36
29
  export declare type IPeriodGetter = () => IDatePeriod;
37
30
  export declare type IFilterWithDatesValue = IDatePeriod;
38
- export declare type MultiSelectOptionType<Value> = Value | undefined extends
39
- | IFilterMultiSelectValues<infer Option>
40
- | undefined
41
- ? Option
42
- : unknown;
31
+ export declare type MultiSelectOptionType<Value> = Value | undefined extends IFilterMultiSelectValues<infer Option> | undefined ? Option : unknown;
43
32
  export interface IConfigItemBasicBase<Value> {
44
- name: string;
45
- isInline?: boolean;
46
- requiredFilledFilters?: string[];
47
- localeKey?: IFilterLocaleKey;
48
- locale?: IPartialFilterLocale;
49
- getSelectedValueView?: (v: Value) => ReactNode;
33
+ name: string;
34
+ isInline?: boolean;
35
+ requiredFilledFilters?: string[];
36
+ localeKey?: IFilterLocaleKey;
37
+ locale?: IPartialFilterLocale;
38
+ getSelectedValueView?: (v: Value) => ReactNode;
50
39
  }
51
40
  export declare type IIntervalConfigItem<Value> = IConfigItemBasicBase<Value> & {
52
- type: 'interval';
41
+ type: 'interval';
53
42
  } & Omit<IFilterIntervalProps, 'value' | 'onChange' | 'labelName'>;
54
43
  export interface IBooleanConfigItem<Value> extends IConfigItemBasicBase<Value> {
55
- type: 'boolean';
44
+ type: 'boolean';
56
45
  }
57
- export declare type IMultiSelectConfigItem<Value> =
58
- IConfigItemBasicBase<Value> & {
46
+ export declare type IMultiSelectConfigItem<Value> = IConfigItemBasicBase<Value> & {
59
47
  type: 'multiSelect';
60
- } & Omit<
61
- IFilterMultiSelectProps<Value, MultiSelectOptionType<Value>>,
62
- 'value' | 'onChange'
63
- >;
48
+ } & Omit<IFilterMultiSelectProps<Value, MultiSelectOptionType<Value>>, 'value' | 'onChange'>;
64
49
  export declare type ISelectConfigItem<Value> = IConfigItemBasicBase<Value> & {
65
- type: 'select';
50
+ type: 'select';
66
51
  } & Omit<IFilterSelectProps<Value>, 'value' | 'onChange'>;
67
- export declare type IDateRangeWithoutPeriodConfigItem<Value> =
68
- IConfigItemBasicBase<Value> & {
52
+ export declare type IDateRangeWithoutPeriodConfigItem<Value> = IConfigItemBasicBase<Value> & {
69
53
  type: 'dateRangeWithoutPeriod';
70
54
  dateFormat?: string;
71
- } & Omit<
72
- IFilterWithDatesProps,
73
- 'value' | 'onChange' | 'onStartBtnSubmit' | 'onEndBtnSubmit'
74
- >;
75
- export declare type IDateRangeConfigItem<Value> =
76
- IConfigItemBasicBase<Value> & {
55
+ } & Omit<IFilterWithDatesProps, 'value' | 'onChange' | 'onStartBtnSubmit' | 'onEndBtnSubmit'>;
56
+ export declare type IDateRangeConfigItem<Value> = IConfigItemBasicBase<Value> & {
77
57
  type: 'dateRange';
78
58
  dateFormat?: string;
79
- } & Omit<IFilterWithPeriodProps, 'value' | 'onChange' | 'setIsOpen'>;
59
+ } & Omit<IFilterWithPeriodProps, 'value' | 'onChange' | 'setIsOpen'>;
80
60
  export declare type CustomComponent<Value> = FC<{
81
- value?: Value;
82
- onChange: (v?: Value) => void;
83
- onClose?: () => void;
84
- filter: ICustomConfigItem<Value>;
85
- localeKey?: IFilterLocaleKey;
86
- locale?: IPartialFilterLocale;
61
+ value?: Value;
62
+ onChange: (v?: Value) => void;
63
+ onClose?: () => void;
64
+ filter: ICustomConfigItem<Value>;
65
+ localeKey?: IFilterLocaleKey;
66
+ locale?: IPartialFilterLocale;
87
67
  }>;
88
68
  export interface ICustomConfigItem<Value> extends IConfigItemBasicBase<Value> {
89
- [key: string]: any;
90
- type: 'custom';
91
- component: CustomComponent<Value>;
92
- valueViewType?: 'range' | 'multiple';
69
+ [key: string]: any;
70
+ type: 'custom';
71
+ component: CustomComponent<Value>;
72
+ valueViewType?: 'range' | 'multiple';
93
73
  }
94
- export declare type ConfigItem<Value> =
95
- | ISelectConfigItem<Value>
96
- | IMultiSelectConfigItem<Value>
97
- | ICustomConfigItem<Value>
98
- | IDateRangeWithoutPeriodConfigItem<Value>
99
- | IDateRangeConfigItem<Value>
100
- | IIntervalConfigItem<Value>
101
- | IBooleanConfigItem<Value>;
74
+ export declare type ConfigItem<Value> = ISelectConfigItem<Value> | IMultiSelectConfigItem<Value> | ICustomConfigItem<Value> | IDateRangeWithoutPeriodConfigItem<Value> | IDateRangeConfigItem<Value> | IIntervalConfigItem<Value> | IBooleanConfigItem<Value>;
102
75
  export declare type ConfigType<Values> = {
103
- [K in keyof Values]: ConfigItem<Values[K]>;
76
+ [K in keyof Values]: ConfigItem<Values[K]>;
104
77
  };
@@ -2,7 +2,7 @@ import { FC } from 'react';
2
2
  import { ICommonProps } from '../../types';
3
3
  import { FlagStyles } from './Flag.styles';
4
4
  export interface IFlagProps extends ICommonProps {
5
- tweakStyles?: FlagStyles;
6
- countryCode?: string;
5
+ tweakStyles?: FlagStyles;
6
+ countryCode?: string;
7
7
  }
8
8
  export declare const Flag: FC<IFlagProps>;
@@ -1,12 +1,12 @@
1
1
  import { ComponentStyles } from '../../types';
2
2
  export declare const styles: {
3
- root: {
4
- border: (string | number)[];
5
- borderRadius: number;
6
- };
7
- noFlag: {
8
- width: number;
9
- color: '#505f79';
10
- };
3
+ root: {
4
+ border: (string | number)[];
5
+ borderRadius: number;
6
+ };
7
+ noFlag: {
8
+ width: number;
9
+ color: "#505f79";
10
+ };
11
11
  };
12
12
  export declare type FlagStyles = ComponentStyles<typeof styles>;
@@ -2,49 +2,24 @@ import React, { RefObject } from 'react';
2
2
  import { ICommonProps } from '../../types';
3
3
  import { FlexibleTableConfigType, IInfinityScrollConfig } from './types';
4
4
  import { FlexibleTableStyles } from './FlexibleTable.styles';
5
- export interface IFlexibleTableProps<Values extends Record<string, any>>
6
- extends ICommonProps {
7
- tweakStyles?: FlexibleTableStyles;
8
- content: Values[];
9
- headerContent?: Partial<Record<keyof Values, any>>;
10
- enabledColumns?: Array<keyof Values>;
11
- activeRows?: number[];
12
- config?: FlexibleTableConfigType<Values>;
13
- isHorizontallyScrollable?: boolean;
14
- isFirstColumnSticky?: boolean;
15
- infinityScrollConfig?: IInfinityScrollConfig;
16
- uniqueField?: keyof Values;
17
- onHeadClick?: (column: keyof Values) => void;
18
- onRowClick?: (id: string) => void;
19
- onRowHover?: (id?: string) => void;
20
- rowAttributes?: Array<keyof Values>;
21
- refForScroll?: RefObject<HTMLDivElement>;
22
- nothingFoundContent?: React.ReactNode;
23
- expandableRowComponent?: (
24
- item: Values,
25
- isOpen: boolean,
26
- close: () => void,
27
- ) => React.ReactNode;
28
- testId?: string;
5
+ export interface IFlexibleTableProps<Values extends Record<string, any>> extends ICommonProps {
6
+ tweakStyles?: FlexibleTableStyles;
7
+ content: Values[];
8
+ headerContent?: Partial<Record<keyof Values, any>>;
9
+ enabledColumns?: Array<keyof Values>;
10
+ activeRows?: number[];
11
+ config?: FlexibleTableConfigType<Values>;
12
+ isHorizontallyScrollable?: boolean;
13
+ isFirstColumnSticky?: boolean;
14
+ infinityScrollConfig?: IInfinityScrollConfig;
15
+ uniqueField?: keyof Values;
16
+ onHeadClick?: (column: keyof Values) => void;
17
+ onRowClick?: (id: string) => void;
18
+ onRowHover?: (id?: string) => void;
19
+ rowAttributes?: Array<keyof Values>;
20
+ refForScroll?: RefObject<HTMLDivElement>;
21
+ nothingFoundContent?: React.ReactNode;
22
+ expandableRowComponent?: (item: Values, isOpen: boolean, close: () => void) => React.ReactNode;
23
+ testId?: string;
29
24
  }
30
- export declare function FlexibleTable<Values extends Record<string, any>>({
31
- data,
32
- tweakStyles,
33
- content,
34
- headerContent,
35
- config,
36
- activeRows,
37
- enabledColumns,
38
- isHorizontallyScrollable,
39
- isFirstColumnSticky,
40
- infinityScrollConfig,
41
- uniqueField,
42
- onHeadClick,
43
- onRowHover,
44
- onRowClick,
45
- refForScroll,
46
- rowAttributes,
47
- nothingFoundContent,
48
- testId,
49
- expandableRowComponent,
50
- }: IFlexibleTableProps<Values>): JSX.Element;
25
+ export declare function FlexibleTable<Values extends Record<string, any>>({ data, tweakStyles, content, headerContent, config, activeRows, enabledColumns, isHorizontallyScrollable, isFirstColumnSticky, infinityScrollConfig, uniqueField, onHeadClick, onRowHover, onRowClick, refForScroll, rowAttributes, nothingFoundContent, testId, expandableRowComponent, }: IFlexibleTableProps<Values>): JSX.Element;
@@ -1,101 +1,101 @@
1
1
  import { ComponentStyles } from '../../types';
2
2
  export declare const styles: {
3
- root: {
4
- position: string;
5
- width: string;
6
- borderCollapse: string;
7
- borderSpacing: number;
8
- };
9
- row: {
10
- position: string;
11
- };
12
- scroll: {
13
- overflow: string;
14
- maxHeight: string;
15
- };
16
- horizontallyScrolled: {
17
- '& $cellSticky': {
18
- boxShadow: string;
3
+ root: {
4
+ position: string;
5
+ width: string;
6
+ borderCollapse: string;
7
+ borderSpacing: number;
19
8
  };
20
- '& $headerSticky::before': {
21
- boxShadow: string;
9
+ row: {
10
+ position: string;
22
11
  };
23
- };
24
- loader: {
25
- position: string;
26
- left: number;
27
- maxWidth: string;
28
- height: number;
29
- display: string;
30
- justifyContent: string;
31
- alignItems: string;
32
- };
33
- headerRow: {
34
- verticalAlign: string;
35
- };
36
- activeRow: {};
37
- cell: {
38
- position: string;
39
- boxSizing: string;
40
- padding: number[];
41
- fontSize: number;
42
- lineHeight: number;
43
- zIndex: number;
44
- verticalAlign: string;
45
- };
46
- cellSticky: {
47
- zIndex: number;
48
- paddingLeft: number;
49
- paddingRight: number;
50
- transition: string[];
51
- };
52
- cellSecond: {
53
- paddingLeft: number;
54
- };
55
- header: {
56
- position: string;
57
- boxSizing: string;
58
- top: number;
59
- zIndex: number;
60
- fontSize: number;
61
- fontWeight: string;
62
- padding: number[];
63
- };
64
- headerSticky: {
65
- zIndex: number;
66
- left: number;
67
- paddingLeft: number;
68
- paddingRight: number;
69
- '&::before': {
70
- content: string;
71
- display: string;
72
- width: string;
73
- height: string;
74
- position: string;
75
- left: number;
76
- top: number;
77
- background: string;
78
- pointerEvents: string;
79
- zIndex: number;
80
- transition: string[];
12
+ scroll: {
13
+ overflow: string;
14
+ maxHeight: string;
81
15
  };
82
- '&::after': {
83
- content: string;
84
- display: string;
85
- width: number;
86
- height: string;
87
- position: string;
88
- left: string;
89
- top: number;
90
- background: string;
91
- zIndex: number;
16
+ horizontallyScrolled: {
17
+ '& $cellSticky': {
18
+ boxShadow: string;
19
+ };
20
+ '& $headerSticky::before': {
21
+ boxShadow: string;
22
+ };
23
+ };
24
+ loader: {
25
+ position: string;
26
+ left: number;
27
+ maxWidth: string;
28
+ height: number;
29
+ display: string;
30
+ justifyContent: string;
31
+ alignItems: string;
32
+ };
33
+ headerRow: {
34
+ verticalAlign: string;
35
+ };
36
+ activeRow: {};
37
+ cell: {
38
+ position: string;
39
+ boxSizing: string;
40
+ padding: number[];
41
+ fontSize: number;
42
+ lineHeight: number;
43
+ zIndex: number;
44
+ verticalAlign: string;
45
+ };
46
+ cellSticky: {
47
+ zIndex: number;
48
+ paddingLeft: number;
49
+ paddingRight: number;
50
+ transition: string[];
51
+ };
52
+ cellSecond: {
53
+ paddingLeft: number;
54
+ };
55
+ header: {
56
+ position: string;
57
+ boxSizing: string;
58
+ top: number;
59
+ zIndex: number;
60
+ fontSize: number;
61
+ fontWeight: string;
62
+ padding: number[];
63
+ };
64
+ headerSticky: {
65
+ zIndex: number;
66
+ left: number;
67
+ paddingLeft: number;
68
+ paddingRight: number;
69
+ '&::before': {
70
+ content: string;
71
+ display: string;
72
+ width: string;
73
+ height: string;
74
+ position: string;
75
+ left: number;
76
+ top: number;
77
+ background: string;
78
+ pointerEvents: string;
79
+ zIndex: number;
80
+ transition: string[];
81
+ };
82
+ '&::after': {
83
+ content: string;
84
+ display: string;
85
+ width: number;
86
+ height: string;
87
+ position: string;
88
+ left: string;
89
+ top: number;
90
+ background: string;
91
+ zIndex: number;
92
+ };
93
+ };
94
+ headerSecond: {
95
+ paddingLeft: number;
96
+ };
97
+ editableRow: {
98
+ cursor: string;
92
99
  };
93
- };
94
- headerSecond: {
95
- paddingLeft: number;
96
- };
97
- editableRow: {
98
- cursor: string;
99
- };
100
100
  };
101
101
  export declare type FlexibleTableStyles = ComponentStyles<typeof styles>;