@true-engineering/true-react-common-ui-kit 4.0.0-alpha31 → 4.0.0-alpha33
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/FiltersPane/index.d.ts +1 -0
- package/dist/components/FiltersPane/types.d.ts +2 -1
- package/dist/components/Select/Select.d.ts +2 -2
- package/dist/components/Select/types.d.ts +4 -0
- package/dist/true-react-common-ui-kit.js +5 -1
- package/dist/true-react-common-ui-kit.js.map +1 -1
- package/dist/true-react-common-ui-kit.umd.cjs +5 -1
- package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
- package/package.json +1 -1
- package/src/components/FiltersPane/index.ts +1 -0
- package/src/components/FiltersPane/types.ts +2 -1
- package/src/components/Select/Select.tsx +5 -4
- package/src/components/Select/types.ts +3 -0
|
@@ -27,7 +27,7 @@ export type IPeriodGetter = () => IDatePeriod;
|
|
|
27
27
|
export type IFilterWithDatesValue = IDatePeriod;
|
|
28
28
|
export type MultiSelectOptionType<Value> = Value | undefined extends IFilterMultiSelectValues<infer Option> | undefined ? Option : unknown;
|
|
29
29
|
export interface IConfigItemBasicBase<Value> {
|
|
30
|
-
name:
|
|
30
|
+
name: ReactNode;
|
|
31
31
|
isInline?: boolean;
|
|
32
32
|
isClearable?: boolean;
|
|
33
33
|
requiredFilledFilters?: string[];
|
|
@@ -37,6 +37,7 @@ export interface IConfigItemBasicBase<Value> {
|
|
|
37
37
|
}
|
|
38
38
|
export type IIntervalConfigItem<Value> = IConfigItemBasicBase<Value> & {
|
|
39
39
|
type: 'interval';
|
|
40
|
+
name: string;
|
|
40
41
|
} & Omit<IFilterIntervalProps, 'value' | 'onChange' | 'labelName'>;
|
|
41
42
|
export interface IBooleanConfigItem<Value> extends IConfigItemBasicBase<Value> {
|
|
42
43
|
type: 'boolean';
|
|
@@ -3,11 +3,11 @@ import { ICommonProps, IDropdownWithPopperOptions } from '../../types';
|
|
|
3
3
|
import { IIcon } from '../Icon';
|
|
4
4
|
import { IInputProps } from '../Input';
|
|
5
5
|
import { ISearchInputProps } from '../SearchInput';
|
|
6
|
-
import { IChangeSelectEvent, IMultipleSelectValue } from './types';
|
|
6
|
+
import { IChangeSelectEvent, IMultipleSelectValue, ISelectFooter } from './types';
|
|
7
7
|
import { ISelectStyles } from './Select.styles';
|
|
8
8
|
export interface ISelectProps<Value> extends Omit<IInputProps, 'value' | 'onChange' | 'onBlur' | 'type' | 'tweakStyles'>, ICommonProps<ISelectStyles> {
|
|
9
9
|
header?: ReactNode;
|
|
10
|
-
footer?:
|
|
10
|
+
footer?: ISelectFooter<Value>;
|
|
11
11
|
defaultOptionLabel?: ReactNode;
|
|
12
12
|
allOptionsLabel?: string;
|
|
13
13
|
noMatchesLabel?: string;
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { ChangeEvent, KeyboardEvent } from 'react';
|
|
2
|
+
import { IRenderNode } from '../../types';
|
|
2
3
|
import { IChangeInputEvent } from '../Input';
|
|
3
4
|
export type IMultipleSelectValue<Value> = Array<NonNullable<Value>>;
|
|
4
5
|
export type IChangeSelectEvent = IChangeInputEvent | ChangeEvent<HTMLElement> | KeyboardEvent;
|
|
6
|
+
export type ISelectFooter<T> = IRenderNode<{
|
|
7
|
+
filteredOptions: T[];
|
|
8
|
+
}>;
|
|
@@ -12580,7 +12580,9 @@ function Select(props) {
|
|
|
12580
12580
|
allOptionsLabel: shouldShowAllOption && allOptionsLabel,
|
|
12581
12581
|
areAllOptionsSelected,
|
|
12582
12582
|
customListHeader: customHeader,
|
|
12583
|
-
customListFooter: footer,
|
|
12583
|
+
customListFooter: applyAction(footer, {
|
|
12584
|
+
filteredOptions
|
|
12585
|
+
}),
|
|
12584
12586
|
noMatchesLabel,
|
|
12585
12587
|
focusedIndex: focusedListCellIndex,
|
|
12586
12588
|
activeValue: value,
|
|
@@ -32736,6 +32738,8 @@ export {
|
|
|
32736
32738
|
NewMoreMenu,
|
|
32737
32739
|
Notification,
|
|
32738
32740
|
NumberInput,
|
|
32741
|
+
PERIODS,
|
|
32742
|
+
PERIODS_GETTERS,
|
|
32739
32743
|
PhoneInput,
|
|
32740
32744
|
RadioButton,
|
|
32741
32745
|
SLIDE_UP_ANIMATION_DURATION,
|