@moysklad/uikit 30.4.0 → 31.20.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/README.md +9 -4
- package/dist/colorVariables.css +23 -1
- package/dist/components/AutoComplete/AutoComplete.js +2 -2
- package/dist/components/BentoBlock/BentoBlock.d.ts +15 -0
- package/dist/components/BentoBlock/BentoBlock.js +20 -0
- package/dist/components/BentoBlock/BentoBlock.module.js +9 -0
- package/dist/components/BentoBlock/BentoBlock_module.css +50 -0
- package/dist/components/BentoBlock/consts.d.ts +14 -0
- package/dist/components/BentoBlock/consts.js +15 -0
- package/dist/components/Button/Button.d.ts +5 -2
- package/dist/components/Button/Button.js +28 -19
- package/dist/components/Button/Button_module.css +16 -14
- package/dist/components/Checkbox/Checkbox.js +1 -1
- package/dist/components/DateRange/ArrowButton/ArrowButton.module.js +6 -0
- package/dist/components/DateRange/ArrowButton/ArrowButton_module.css +26 -0
- package/dist/components/DateRange/ArrowButton/index.d.ts +8 -0
- package/dist/components/DateRange/ArrowButton/index.js +23 -0
- package/dist/components/DateRange/Calendar/index.d.ts +12 -0
- package/dist/components/DateRange/Calendar/index.js +22 -0
- package/dist/components/DateRange/DateRange.d.ts +6 -0
- package/dist/components/DateRange/DateRange.js +51 -0
- package/dist/components/DateRange/DateRangeDefaultTrigger/DateRangeDefaultTrigger.d.ts +44 -0
- package/dist/components/DateRange/DateRangeDefaultTrigger/DateRangeDefaultTrigger.js +128 -0
- package/dist/components/DateRange/DateRangeDefaultTrigger/DateRangeDefaultTrigger.module.js +19 -0
- package/dist/components/DateRange/DateRangeDefaultTrigger/DateRangeDefaultTrigger_module.css +170 -0
- package/dist/components/DateRange/DateRangeDefaultTrigger.module.js +12 -0
- package/dist/components/DateRange/DateRangeDefaultTrigger_module.css +43 -0
- package/dist/components/DateRange/DateRangeInput/DateRangeInput.d.ts +4 -0
- package/dist/components/DateRange/DateRangeInput/DateRangeInput.js +69 -0
- package/dist/components/DateRange/Day/Day.module.js +16 -0
- package/dist/components/DateRange/Day/Day_module.css +80 -0
- package/dist/components/DateRange/Day/index.d.ts +12 -0
- package/dist/components/DateRange/Day/index.js +39 -0
- package/dist/components/DateRange/DropdownContent/DropdownContent.module.js +10 -0
- package/dist/components/DateRange/DropdownContent/DropdownContent_module.css +34 -0
- package/dist/components/DateRange/DropdownContent/index.d.ts +24 -0
- package/dist/components/DateRange/DropdownContent/index.js +132 -0
- package/dist/components/DateRange/InputContent/InputContent.module.js +9 -0
- package/dist/components/DateRange/InputContent/InputContent_module.css +31 -0
- package/dist/components/DateRange/InputContent/index.d.ts +12 -0
- package/dist/components/DateRange/InputContent/index.js +59 -0
- package/dist/components/DateRange/Month/Month.module.js +7 -0
- package/dist/components/DateRange/Month/Month_module.css +17 -0
- package/dist/components/DateRange/Month/index.d.ts +15 -0
- package/dist/components/DateRange/Month/index.js +158 -0
- package/dist/components/DateRange/Month/utils.d.ts +2 -0
- package/dist/components/DateRange/Month/utils.js +8 -0
- package/dist/components/DateRange/MonthHeader/MonthHeader.module.js +5 -0
- package/dist/components/DateRange/MonthHeader/MonthHeader_module.css +10 -0
- package/dist/components/DateRange/MonthHeader/index.d.ts +5 -0
- package/dist/components/DateRange/MonthHeader/index.js +26 -0
- package/dist/components/DateRange/MonthList/MonthList.module.js +7 -0
- package/dist/components/DateRange/MonthList/MonthList_module.css +25 -0
- package/dist/components/DateRange/MonthList/index.d.ts +11 -0
- package/dist/components/DateRange/MonthList/index.js +91 -0
- package/dist/components/DateRange/PeriodVariantList/PeriodVariantList.module.js +9 -0
- package/dist/components/DateRange/PeriodVariantList/PeriodVariantList_module.css +18 -0
- package/dist/components/DateRange/PeriodVariantList/index.d.ts +18 -0
- package/dist/components/DateRange/PeriodVariantList/index.js +83 -0
- package/dist/components/DateRange/SideMenu/SideMenu.module.js +6 -0
- package/dist/components/DateRange/SideMenu/SideMenu_module.css +18 -0
- package/dist/components/DateRange/SideMenu/index.d.ts +13 -0
- package/dist/components/DateRange/SideMenu/index.js +73 -0
- package/dist/components/DateRange/TooltipedText/index.d.ts +8 -0
- package/dist/components/DateRange/TooltipedText/index.js +30 -0
- package/dist/components/DateRange/Year/Year.module.js +11 -0
- package/dist/components/DateRange/Year/Year_module.css +60 -0
- package/dist/components/DateRange/Year/index.d.ts +8 -0
- package/dist/components/DateRange/Year/index.js +47 -0
- package/dist/components/DateRange/YearsList/YearsList.module.js +5 -0
- package/dist/components/DateRange/YearsList/YearsList_module.css +15 -0
- package/dist/components/DateRange/YearsList/index.d.ts +12 -0
- package/dist/components/DateRange/YearsList/index.js +47 -0
- package/dist/components/DateRange/consts.d.ts +20 -0
- package/dist/components/DateRange/consts.js +81 -0
- package/dist/components/DateRange/formatDateRangeValue.d.ts +24 -0
- package/dist/components/DateRange/formatDateRangeValue.js +116 -0
- package/dist/components/DateRange/hooks/useCalendar.d.ts +13 -0
- package/dist/components/DateRange/hooks/useCalendar.js +88 -0
- package/dist/components/DateRange/hooks/useDateRange.d.ts +392 -0
- package/dist/components/DateRange/hooks/useDateRange.js +36 -0
- package/dist/components/DateRange/hooks/useDateRangeDropdown.d.ts +47 -0
- package/dist/components/DateRange/hooks/useDateRangeDropdown.js +117 -0
- package/dist/components/DateRange/hooks/useDateRangeValue.d.ts +56 -0
- package/dist/components/DateRange/hooks/useDateRangeValue.js +173 -0
- package/dist/components/DateRange/hooks/useMaskInput.d.ts +18 -0
- package/dist/components/DateRange/hooks/useMaskInput.js +169 -0
- package/dist/components/DateRange/hooks/useMonthList.d.ts +12 -0
- package/dist/components/DateRange/hooks/useMonthList.js +80 -0
- package/dist/components/DateRange/hooks/useSideMenu.d.ts +14 -0
- package/dist/components/DateRange/hooks/useSideMenu.js +113 -0
- package/dist/components/DateRange/index.d.ts +1 -0
- package/dist/components/DateRange/index.js +1 -0
- package/dist/components/DateRange/locale/en-US.d.ts +2 -0
- package/dist/components/DateRange/locale/en-US.js +82 -0
- package/dist/components/DateRange/locale/index.d.ts +4 -0
- package/dist/components/DateRange/locale/index.js +3 -0
- package/dist/components/DateRange/locale/ru-RU.d.ts +2 -0
- package/dist/components/DateRange/locale/ru-RU.js +82 -0
- package/dist/components/DateRange/locale/types.d.ts +9 -0
- package/dist/components/DateRange/locale/types.js +7 -0
- package/dist/components/DateRange/locale/useLocale.d.ts +8 -0
- package/dist/components/DateRange/locale/useLocale.js +31 -0
- package/dist/components/DateRange/props.d.ts +39 -0
- package/dist/components/DateRange/props.js +0 -0
- package/dist/components/DateRange/types.d.ts +126 -0
- package/dist/components/DateRange/types.js +13 -0
- package/dist/components/DateRange/utils.d.ts +33 -0
- package/dist/components/DateRange/utils.js +105 -0
- package/dist/components/Datepicker/Datepicker.d.ts +3 -1
- package/dist/components/Datepicker/Datepicker.js +4 -2
- package/dist/components/EditableDate/DropdownContent/DropdownContent.d.ts +9 -0
- package/dist/components/EditableDate/DropdownContent/DropdownContent.js +36 -0
- package/dist/components/EditableDate/EditableDate.d.ts +9 -0
- package/dist/components/EditableDate/EditableDate.js +142 -0
- package/dist/components/EditableDate/EditableDate.module.js +7 -0
- package/dist/components/EditableDate/EditableDate_module.css +32 -0
- package/dist/components/EditableTitle/EditableTitle.d.ts +7 -2
- package/dist/components/EditableTitle/EditableTitle.js +63 -31
- package/dist/components/EditableTitle/EditableTitle.module.js +1 -0
- package/dist/components/EditableTitle/EditableTitle_module.css +6 -0
- package/dist/components/EmptyState/EmptyState.d.ts +1 -1
- package/dist/components/EmptyStateLarge/EmptyStateLarge_module.css +2 -2
- package/dist/components/Help/Help_module.css +1 -1
- package/dist/components/Informer/Informer.d.ts +37 -0
- package/dist/components/Informer/Informer.js +36 -0
- package/dist/components/Informer/Informer.module.js +7 -0
- package/dist/components/Informer/Informer_module.css +24 -0
- package/dist/components/Input/Input.js +10 -5
- package/dist/components/Input/components/InfoBlock.d.ts +3 -1
- package/dist/components/Input/components/InfoBlock.js +7 -4
- package/dist/components/InputUnit/InputUnit.js +4 -4
- package/dist/components/LabelValue/LabelValue.d.ts +14 -10
- package/dist/components/LabelValue/LabelValue.js +46 -25
- package/dist/components/LabelValue/LabelValue.module.js +10 -4
- package/dist/components/LabelValue/LabelValue_module.css +53 -19
- package/dist/components/LabelValue/ValueBlock/ValueBlock.d.ts +2 -0
- package/dist/components/LabelValue/ValueBlock/ValueBlock.js +82 -0
- package/dist/components/LabelValue/ValueBlockWrapper.d.ts +5 -0
- package/dist/components/LabelValue/ValueBlockWrapper.js +13 -0
- package/dist/components/LabelValue/ValueIcon.d.ts +4 -0
- package/dist/components/LabelValue/ValueIcon.js +9 -0
- package/dist/components/LabelValue/ValueText.d.ts +10 -0
- package/dist/components/LabelValue/ValueText.js +24 -0
- package/dist/components/LabelValue/ValueTextWithHint.d.ts +12 -0
- package/dist/components/LabelValue/ValueTextWithHint.js +29 -0
- package/dist/components/LabelValue/hooks/useValueBlock.d.ts +29 -0
- package/dist/components/LabelValue/hooks/useValueBlock.js +72 -0
- package/dist/components/LabelValue/{ValueBlock/index.d.ts → types.d.ts} +8 -4
- package/dist/components/LabelValue/types.js +0 -0
- package/dist/components/LabelValueDate/LabelValueDate.js +2 -2
- package/dist/components/LabelValueFile/DeleteButton/DeleteButton.d.ts +9 -0
- package/dist/components/LabelValueFile/DeleteButton/DeleteButton.js +17 -0
- package/dist/components/LabelValueFile/FilePreviewIcon/FilePreviewIcon.d.ts +7 -0
- package/dist/components/LabelValueFile/FilePreviewIcon/FilePreviewIcon.js +15 -0
- package/dist/components/LabelValueFile/FilePreviewIcon/FilePreviewIcon.module.js +6 -0
- package/dist/components/LabelValueFile/FilePreviewIcon/FilePreviewIcon_module.css +10 -0
- package/dist/components/LabelValueFile/ImagePreview/ImagePreview.d.ts +8 -0
- package/dist/components/LabelValueFile/ImagePreview/ImagePreview.js +53 -0
- package/dist/components/LabelValueFile/ImagePreview/ImagePreview.module.js +6 -0
- package/dist/components/LabelValueFile/ImagePreview/ImagePreview_module.css +13 -0
- package/dist/components/LabelValueFile/LabelValueFile.d.ts +7 -0
- package/dist/components/LabelValueFile/LabelValueFile.js +42 -0
- package/dist/components/LabelValueFile/LabelValueFile.module.js +12 -0
- package/dist/components/LabelValueFile/LabelValueFile_module.css +57 -0
- package/dist/components/LabelValueFile/ValueBlock/ValueBlock.d.ts +15 -0
- package/dist/components/LabelValueFile/ValueBlock/ValueBlock.js +130 -0
- package/dist/components/LabelValueFile/ValueBlock/ValueBlock.module.js +7 -0
- package/dist/components/LabelValueFile/ValueBlock/ValueBlock_module.css +17 -0
- package/dist/components/LabelValueInput/DropdownConnent/DropdownContent.d.ts +2 -0
- package/dist/components/LabelValueInput/DropdownConnent/DropdownContent.js +2 -0
- package/dist/components/LabelValueLink/LabelValueLink.d.ts +2 -0
- package/dist/components/LabelValueLink/LabelValueLink.js +76 -0
- package/dist/components/LabelValueLink/LabelValueLink.module.js +6 -0
- package/dist/components/LabelValueLink/LabelValueLink_module.css +11 -0
- package/dist/components/LabelValueLink/ValueBlock/LabelValueLinkValueBlock.d.ts +2 -0
- package/dist/components/LabelValueLink/ValueBlock/LabelValueLinkValueBlock.js +117 -0
- package/dist/components/LabelValueLink/ValueBlock/LabelValueLinkValueBlock.module.js +6 -0
- package/dist/components/LabelValueLink/ValueBlock/LabelValueLinkValueBlock_module.css +8 -0
- package/dist/components/LabelValueLink/normalizeLinkValue.d.ts +1 -0
- package/dist/components/LabelValueLink/normalizeLinkValue.js +10 -0
- package/dist/components/LabelValueLink/useLinkDropdownValue.d.ts +15 -0
- package/dist/components/LabelValueLink/useLinkDropdownValue.js +26 -0
- package/dist/components/LabelValueSelect/Input/index.js +1 -1
- package/dist/components/LabelValueSelect/LabelValueSelect.d.ts +4 -2
- package/dist/components/Layout/Layout.d.ts +13 -0
- package/dist/components/Layout/Layout.js +41 -0
- package/dist/components/Layout/Layout.module.js +15 -0
- package/dist/components/Layout/Layout_module.css +77 -0
- package/dist/components/Link/Link.d.ts +5 -6
- package/dist/components/Link/Link.js +35 -9
- package/dist/components/Link/Link.module.js +1 -0
- package/dist/components/Link/Link_module.css +9 -0
- package/dist/components/MentionsTextfield/Mentions/style.css +2 -6
- package/dist/components/MentionsTextfield/MentionsTextfield.js +2 -1
- package/dist/components/Multiselect/AllSelectedChip/AllSelectedChip.d.ts +8 -0
- package/dist/components/Multiselect/AllSelectedChip/AllSelectedChip.js +13 -0
- package/dist/components/Multiselect/AllSelectedChip/AllSelectedChip.module.js +5 -0
- package/dist/components/Multiselect/AllSelectedChip/AllSelectedChip_module.css +9 -0
- package/dist/components/Multiselect/DropdownContent/MultiselectDropdownContent.d.ts +12 -1
- package/dist/components/Multiselect/DropdownContent/MultiselectDropdownContent.js +20 -15
- package/dist/components/Multiselect/Input/Input.d.ts +6 -2
- package/dist/components/Multiselect/Input/Input.js +18 -4
- package/dist/components/Multiselect/Multiselect.d.ts +4 -2
- package/dist/components/Multiselect/Multiselect.js +14 -2
- package/dist/components/Multiselect/ShortDropdownContent/ShortDropdownContent.js +2 -1
- package/dist/components/Multiselect/TextField/MultiselectTextField.d.ts +5 -1
- package/dist/components/Multiselect/TextField/MultiselectTextField.js +15 -2
- package/dist/components/Multiselect/lib/consts.d.ts +1 -1
- package/dist/components/Multiselect/lib/consts.js +1 -1
- package/dist/components/Multiselect/lib/helpers.d.ts +24 -0
- package/dist/components/Multiselect/lib/helpers.js +15 -0
- package/dist/components/Multiselect/types.d.ts +2 -0
- package/dist/components/Panel/Panel.d.ts +34 -0
- package/dist/components/Panel/Panel.js +39 -0
- package/dist/components/Panel/Panel.module.js +6 -0
- package/dist/components/Panel/Panel_module.css +17 -0
- package/dist/components/Radiobutton/Radiobutton.js +1 -1
- package/dist/components/Radiobutton/Radiobutton_module.css +5 -0
- package/dist/components/SearchInput/SearchInput_module.css +1 -1
- package/dist/components/Select/ArchivedInputValue/ArchivedInputValue.d.ts +3 -4
- package/dist/components/Select/ArchivedInputValue/ArchivedInputValue.js +19 -24
- package/dist/components/Select/ArchivedInputValue/ArchivedInputValue.module.js +1 -2
- package/dist/components/Select/ArchivedInputValue/ArchivedInputValue_module.css +5 -12
- package/dist/components/Select/Combobox/Combobox.d.ts +3 -1
- package/dist/components/Select/Combobox/Combobox.js +19 -8
- package/dist/components/Select/Combobox/Combobox.module.js +4 -3
- package/dist/components/Select/Combobox/Combobox_module.css +15 -9
- package/dist/components/Select/OptionsList/OptionsList.d.ts +3 -1
- package/dist/components/Select/OptionsList/OptionsList.js +37 -21
- package/dist/components/Select/OptionsList/OptionsList.module.js +2 -0
- package/dist/components/Select/OptionsList/OptionsList_module.css +15 -0
- package/dist/components/Select/Select.d.ts +2 -3
- package/dist/components/Select/Select.js +17 -7
- package/dist/components/Select/Select_module.css +5 -0
- package/dist/components/Select/ShortVariant/ShortVariant.js +1 -1
- package/dist/components/StatusBadge/StatusBadge.d.ts +28 -0
- package/dist/components/StatusBadge/StatusBadge.js +167 -0
- package/dist/components/StatusBadge/StatusBadge.module.js +37 -0
- package/dist/components/StatusBadge/StatusBadge_module.css +149 -0
- package/dist/components/StatusBadge/utils/StatusBadgeColor.d.ts +21 -0
- package/dist/components/StatusBadge/utils/StatusBadgeColor.js +20 -0
- package/dist/components/StatusBadge/utils/getStatusBadgeColor.d.ts +2 -0
- package/dist/components/StatusBadge/utils/getStatusBadgeColor.js +8 -0
- package/dist/components/Textfield/Textfield.d.ts +7 -2
- package/dist/components/Textfield/Textfield.js +2 -1
- package/dist/components/Textfield/components/Container/Container.d.ts +2 -0
- package/dist/components/Textfield/components/Container/Container.js +17 -6
- package/dist/components/Textfield/components/Container/Container.module.js +2 -1
- package/dist/components/Textfield/components/Container/Container_module.css +4 -0
- package/dist/components/Toggle/Toggle.js +1 -1
- package/dist/components/ViewersStack/ViewersStack.js +5 -3
- package/dist/components/_shared/CustomDatepickerDropdownContent/CustomDatepickerDropdownContent.d.ts +12 -0
- package/dist/components/{LabelValueDate/DropdownContent/index.js → _shared/CustomDatepickerDropdownContent/CustomDatepickerDropdownContent.js} +10 -10
- package/dist/components/_shared/CustomDatepickerDropdownContent/CustomDatepickerDropdownContent.module.js +9 -0
- package/dist/components/{LabelValueDate/DropdownContent/DropdownContent_module.css → _shared/CustomDatepickerDropdownContent/CustomDatepickerDropdownContent_module.css} +6 -6
- package/dist/components/_shared/FieldLabel/FieldLabel.d.ts +18 -0
- package/dist/components/{FieldLabel → _shared/FieldLabel}/FieldLabel.js +19 -12
- package/dist/components/_shared/FieldLabel/FieldLabel.module.js +11 -0
- package/dist/components/{FieldLabel → _shared/FieldLabel}/FieldLabel_module.css +8 -8
- package/dist/components/{FieldLabel → _shared/FieldLabel}/components/HelpButton.d.ts +1 -1
- package/dist/components/{FieldLabel → _shared/FieldLabel}/components/HelpButton.js +2 -2
- package/dist/components/{FieldLabel → _shared/FieldLabel}/components/HelpButton.module.js +1 -1
- package/dist/components/{FieldLabel → _shared/FieldLabel}/components/HelpButton_module.css +1 -1
- package/dist/components/{FieldRow → _shared/FieldRow}/FieldRow.d.ts +1 -1
- package/dist/components/{FieldRow → _shared/FieldRow}/FieldRow.js +1 -1
- package/dist/components/{FieldRow → _shared/FieldRow}/FieldRow.module.js +3 -3
- package/dist/components/{FieldRow → _shared/FieldRow}/FieldRow_module.css +3 -3
- package/dist/components/{Info → _shared/Info}/Info.d.ts +3 -1
- package/dist/components/{Info → _shared/Info}/Info.js +9 -6
- package/dist/components/_shared/Info/Info.module.js +9 -0
- package/dist/components/{Info → _shared/Info}/Info_module.css +6 -6
- package/dist/components/_shared/Info/types/index.d.ts +6 -0
- package/dist/components/_shared/Info/types/index.js +5 -0
- package/dist/components/{InputClear → _shared/InputClear}/InputClear.d.ts +1 -1
- package/dist/components/{InputClear → _shared/InputClear}/InputClear.js +2 -2
- package/dist/components/{InputClear → _shared/InputClear}/InputClear.module.js +3 -3
- package/dist/components/{InputClear → _shared/InputClear}/InputClear_module.css +5 -5
- package/dist/components/_shared/utils/polymorphicClickableTypes.d.ts +17 -0
- package/dist/components/_shared/utils/polymorphicClickableTypes.js +7 -0
- package/dist/data-grid/Filters/DateRangeFilter/DropdownContent/index.js +3 -3
- package/dist/data-grid/Filters/DateRangeFilter/InputContent/index.js +29 -26
- package/dist/data-grid/Filters/DateRangeFilter/PeriodVariantList/index.js +5 -3
- package/dist/data-grid/Filters/DateRangeFilter/Year/index.js +3 -3
- package/dist/data-grid/Filters/DateRangeFilter/consts.js +6 -6
- package/dist/data-grid/Filters/DateRangeFilter/hooks/useMaskInput.js +6 -6
- package/dist/data-grid/Filters/DateRangeFilter/hooks/useSideMenu.js +1 -4
- package/dist/data-grid/Filters/DateRangeFilter/types.d.ts +68 -56
- package/dist/data-grid/Filters/FiltersContainer/FiltersContainer.js +2 -1
- package/dist/data-grid/Filters/FiltersContainer/utils/useRenderParams.d.ts +1 -0
- package/dist/data-grid/Filters/FiltersContainer/utils/useRenderParams.js +14 -6
- package/dist/data-grid/Filters/MultiselectFilter/MultiselectFilter.js +2 -2
- package/dist/data-grid/Filters/OutlineInput/OutlineInput.js +2 -2
- package/dist/data-grid/Filters/OutlineInput/OutlineInput_module.css +1 -1
- package/dist/data-grid/Table/Table_module.css +0 -1
- package/dist/data-grid/cells/ImageCell/ImageMiniature/ImageMiniature_module.css +1 -1
- package/dist/data-grid/cells/components/TableNumberInput/TableNumberInput.d.ts +1 -0
- package/dist/data-grid/cells/components/TableNumberInput/TableNumberInput.js +17 -5
- package/dist/data-grid/cells/components/TableSelect/TableSelect.js +3 -2
- package/dist/data-grid/headers/components/Dropdown/Dropdown.d.ts +3 -0
- package/dist/data-grid/headers/components/HeaderBuilder/HeaderBuilder.js +1 -0
- package/dist/data-grid/index.d.ts +0 -4
- package/dist/data-grid/locale/en-US.js +68 -56
- package/dist/data-grid/locale/ru-RU.js +68 -56
- package/dist/data-grid/locale/useLocale.d.ts +6 -1
- package/dist/data-grid/locale/useLocale.js +14 -5
- package/dist/hooks/useIsElementOverflowing/index.d.ts +1 -0
- package/dist/hooks/useIsElementOverflowing/index.js +8 -2
- package/dist/hooks/useOverflowHint/index.d.ts +7 -0
- package/dist/hooks/useOverflowHint/index.js +16 -0
- package/dist/hooks/useTextField/useTextField.d.ts +1 -1
- package/dist/icon/components/MsLogo12Icon.d.ts +8 -0
- package/dist/icon/components/MsLogo12Icon.js +28 -0
- package/dist/icon/components/MsLogo16Icon.d.ts +8 -0
- package/dist/icon/components/MsLogo16Icon.js +26 -0
- package/dist/icon/components/MsLogo20Icon.d.ts +8 -0
- package/dist/icon/components/MsLogo20Icon.js +28 -0
- package/dist/icon/components/Phone12Icon.d.ts +8 -0
- package/dist/icon/components/Phone12Icon.js +18 -0
- package/dist/icon/components/Phone16Icon.d.ts +8 -0
- package/dist/icon/components/Phone16Icon.js +17 -0
- package/dist/icon/components/Phone20Icon.d.ts +8 -0
- package/dist/icon/components/Phone20Icon.js +18 -0
- package/dist/icon/index.d.ts +6 -0
- package/dist/icon/index.js +6 -0
- package/dist/index.d.ts +9 -1
- package/dist/index.js +8 -0
- package/dist/utils/checkIsArchivedValue.d.ts +2 -0
- package/dist/utils/checkIsArchivedValue.js +5 -0
- package/dist/utils/utils.d.ts +1 -0
- package/dist/utils/utils.js +1 -0
- package/package.json +70 -13
- package/dist/components/FieldLabel/FieldLabel.d.ts +0 -17
- package/dist/components/FieldLabel/FieldLabel.module.js +0 -11
- package/dist/components/Info/Info.module.js +0 -9
- package/dist/components/LabelValue/ValueBlock/index.js +0 -138
- package/dist/components/LabelValue/hooks/useTooltip.d.ts +0 -8
- package/dist/components/LabelValue/hooks/useTooltip.js +0 -16
- package/dist/components/LabelValueDate/DropdownContent/DropdownContent.module.js +0 -9
- package/dist/components/LabelValueDate/DropdownContent/index.d.ts +0 -12
- package/dist/components/MentionsTextfield/OptionForStory/OptionForStory.d.ts +0 -7
- package/dist/components/MentionsTextfield/OptionForStory/OptionForStory.js +0 -27
- package/dist/components/MentionsTextfield/OptionForStory/OptionForStory.module.js +0 -8
- package/dist/components/MentionsTextfield/OptionForStory/OptionForStory_module.css +0 -25
- package/dist/components/MentionsTextfield/OptionForStory/index.d.ts +0 -1
- package/dist/components/MentionsTextfield/OptionForStory/index.js +0 -1
- package/dist/components/Textfield/components/Label/Label.d.ts +0 -11
- package/dist/components/Textfield/components/Label/Label.js +0 -38
- package/dist/components/Textfield/components/Label/Label.module.js +0 -7
- package/dist/components/Textfield/components/Label/Label_module.css +0 -17
- package/dist/components/Textfield/components/Label/index.d.ts +0 -1
- package/dist/components/Textfield/components/Label/index.js +0 -1
- /package/dist/components/{FieldLabel → _shared/FieldLabel}/FieldLabel.constants.d.ts +0 -0
- /package/dist/components/{FieldLabel → _shared/FieldLabel}/FieldLabel.constants.js +0 -0
- /package/dist/components/{FieldLabel → _shared/FieldLabel}/components/index.d.ts +0 -0
- /package/dist/components/{FieldLabel → _shared/FieldLabel}/components/index.js +0 -0
|
@@ -29,68 +29,80 @@ export interface DateRangeFilterNoDateValue extends DateRangeFilterValue {
|
|
|
29
29
|
value: null;
|
|
30
30
|
}
|
|
31
31
|
export interface DateRangeFilterLocale {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
dayQuickFilters: {
|
|
41
|
-
yesterday: string;
|
|
42
|
-
today: string;
|
|
43
|
-
};
|
|
44
|
-
footer: {
|
|
45
|
-
timeSelectionToggle: string;
|
|
46
|
-
timeSelectionToggleHint: string;
|
|
47
|
-
clearFilterButton: string;
|
|
48
|
-
};
|
|
49
|
-
slider: {
|
|
50
|
-
day: {
|
|
51
|
-
title: string;
|
|
52
|
-
placeholder: string;
|
|
53
|
-
dateFormat: string;
|
|
32
|
+
translate: {
|
|
33
|
+
radiobuttons: {
|
|
34
|
+
period: string;
|
|
35
|
+
day: string;
|
|
36
|
+
week: string;
|
|
37
|
+
month: string;
|
|
38
|
+
anyDate: string;
|
|
39
|
+
noDate: string;
|
|
54
40
|
};
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
41
|
+
dayQuickFilters: {
|
|
42
|
+
yesterday: string;
|
|
43
|
+
today: string;
|
|
44
|
+
};
|
|
45
|
+
footer: {
|
|
46
|
+
timeSelectionToggle: string;
|
|
47
|
+
timeSelectionToggleHint: string;
|
|
48
|
+
clearFilterButton: string;
|
|
49
|
+
};
|
|
50
|
+
slider: {
|
|
51
|
+
day: {
|
|
52
|
+
title: string;
|
|
53
|
+
placeholder: string;
|
|
54
|
+
};
|
|
55
|
+
week: {
|
|
56
|
+
title: string;
|
|
57
|
+
placeholder: string;
|
|
67
58
|
};
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
59
|
+
month: {
|
|
60
|
+
title: string;
|
|
61
|
+
placeholder: string;
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
format: {
|
|
66
|
+
slider: {
|
|
67
|
+
day: {
|
|
68
|
+
dateFormat: string;
|
|
69
|
+
};
|
|
70
|
+
week: {
|
|
71
|
+
dateFormat: {
|
|
72
|
+
sameMonth: {
|
|
73
|
+
firstDate: string;
|
|
74
|
+
endDate: string;
|
|
75
|
+
};
|
|
76
|
+
differentMonth: {
|
|
77
|
+
firstDate: string;
|
|
78
|
+
endDate: string;
|
|
79
|
+
};
|
|
72
80
|
};
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
81
|
+
tooltipDateFormat: {
|
|
82
|
+
sameMonth: {
|
|
83
|
+
firstDate: string;
|
|
84
|
+
endDate: string;
|
|
85
|
+
};
|
|
86
|
+
differentMonth: {
|
|
87
|
+
firstDate: string;
|
|
88
|
+
endDate: string;
|
|
89
|
+
};
|
|
76
90
|
};
|
|
77
91
|
};
|
|
92
|
+
month: {
|
|
93
|
+
dateFormat: string;
|
|
94
|
+
};
|
|
78
95
|
};
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
dateFormat: string;
|
|
96
|
+
inputMask: {
|
|
97
|
+
withTime: string;
|
|
98
|
+
withoutTime: string;
|
|
83
99
|
};
|
|
100
|
+
emptyDate: {
|
|
101
|
+
withTime: string;
|
|
102
|
+
withoutTime: string;
|
|
103
|
+
};
|
|
104
|
+
dateFormat: string;
|
|
105
|
+
dateWithTimeFormat: string;
|
|
106
|
+
monthCalendarFormat: string;
|
|
84
107
|
};
|
|
85
|
-
inputMask: {
|
|
86
|
-
withTime: string;
|
|
87
|
-
withoutTime: string;
|
|
88
|
-
};
|
|
89
|
-
emptyDate: {
|
|
90
|
-
withTime: string;
|
|
91
|
-
withoutTime: string;
|
|
92
|
-
};
|
|
93
|
-
dateFormat: string;
|
|
94
|
-
dateWithTimeFormat: string;
|
|
95
|
-
monthCalendarFormat: string;
|
|
96
108
|
}
|
|
@@ -24,7 +24,8 @@ const FiltersContainer = (props)=>{
|
|
|
24
24
|
});
|
|
25
25
|
const { getRenderParams, getFilterValue, getFilterContainOption, filtersState, changeFiltersState } = useRenderParams({
|
|
26
26
|
initialState: filters,
|
|
27
|
-
values: props.values
|
|
27
|
+
values: props.values,
|
|
28
|
+
onChange: props.onChange
|
|
28
29
|
});
|
|
29
30
|
const getInitialValue = (filter)=>{
|
|
30
31
|
if (filter.initialValue) return filter.initialValue;
|
|
@@ -3,6 +3,7 @@ import type { Filter, FilterContainerValues, FilterProps, FilterValue, RenderVal
|
|
|
3
3
|
interface UseRenderParamsArgs {
|
|
4
4
|
initialState: Filter[];
|
|
5
5
|
values?: Map<string, FilterContainerValues>;
|
|
6
|
+
onChange?: (values: Map<string, FilterContainerValues>) => void;
|
|
6
7
|
}
|
|
7
8
|
export declare const useRenderParams: (args: UseRenderParamsArgs) => {
|
|
8
9
|
getRenderParams: (filter: Filter) => RenderValueParams<FilterProps>;
|
|
@@ -12,6 +12,13 @@ const getInitialFiltersState = (initialState)=>{
|
|
|
12
12
|
};
|
|
13
13
|
const useRenderParams = (args)=>{
|
|
14
14
|
const [filtersState, setFiltersState] = useState(()=>args.values ?? getInitialFiltersState(args.initialState));
|
|
15
|
+
const modifyFiltersState = (modifier)=>{
|
|
16
|
+
setFiltersState((filtersState)=>{
|
|
17
|
+
const modifiedState = modifier(filtersState);
|
|
18
|
+
args.onChange?.(modifiedState);
|
|
19
|
+
return modifiedState;
|
|
20
|
+
});
|
|
21
|
+
};
|
|
15
22
|
useEffect(()=>{
|
|
16
23
|
if (args.values) setFiltersState(args.values);
|
|
17
24
|
}, [
|
|
@@ -34,7 +41,7 @@ const useRenderParams = (args)=>{
|
|
|
34
41
|
const getSelectFilterRenderParams = (filter)=>({
|
|
35
42
|
value: getFilterValue(filter),
|
|
36
43
|
onChange: (value)=>{
|
|
37
|
-
|
|
44
|
+
modifyFiltersState((state)=>{
|
|
38
45
|
const newState = new Map(state);
|
|
39
46
|
const prevFilterState = state.get(filter.id);
|
|
40
47
|
newState.set(filter.id, {
|
|
@@ -48,7 +55,7 @@ const useRenderParams = (args)=>{
|
|
|
48
55
|
const getInputFilterRenderParams = (filter)=>({
|
|
49
56
|
value: getFilterValue(filter) ?? '',
|
|
50
57
|
onChange: (value)=>{
|
|
51
|
-
|
|
58
|
+
modifyFiltersState((state)=>{
|
|
52
59
|
const newState = new Map(state);
|
|
53
60
|
const prevFilterState = state.get(filter.id);
|
|
54
61
|
newState.set(filter.id, {
|
|
@@ -62,7 +69,7 @@ const useRenderParams = (args)=>{
|
|
|
62
69
|
const getMultiselectFilterRenderParams = (filter)=>({
|
|
63
70
|
value: getFilterValue(filter) ?? [],
|
|
64
71
|
onChange: (value)=>{
|
|
65
|
-
|
|
72
|
+
modifyFiltersState((state)=>{
|
|
66
73
|
const newState = new Map(state);
|
|
67
74
|
const prevFilterState = state.get(filter.id);
|
|
68
75
|
newState.set(filter.id, {
|
|
@@ -76,7 +83,7 @@ const useRenderParams = (args)=>{
|
|
|
76
83
|
const getDateRangeFilterRenderParams = (filter)=>({
|
|
77
84
|
value: getFilterValue(filter),
|
|
78
85
|
onChange: (value)=>{
|
|
79
|
-
|
|
86
|
+
modifyFiltersState((state)=>{
|
|
80
87
|
const newState = new Map(state);
|
|
81
88
|
const prevFilterState = state.get(filter.id);
|
|
82
89
|
newState.set(filter.id, {
|
|
@@ -90,7 +97,7 @@ const useRenderParams = (args)=>{
|
|
|
90
97
|
const getRangeFilterRenderParams = (filter)=>({
|
|
91
98
|
value: getFilterValue(filter),
|
|
92
99
|
onChange: (value)=>{
|
|
93
|
-
|
|
100
|
+
modifyFiltersState((state)=>{
|
|
94
101
|
const newState = new Map(state);
|
|
95
102
|
const prevFilterState = state.get(filter.id);
|
|
96
103
|
newState.set(filter.id, {
|
|
@@ -104,7 +111,7 @@ const useRenderParams = (args)=>{
|
|
|
104
111
|
const getContainOptionRenderParams = (filter, defaultValue)=>({
|
|
105
112
|
selectedContainOption: filtersState.get(filter.id)?.selectedContainOption,
|
|
106
113
|
onChangeContainOption: (selectedContainOption)=>{
|
|
107
|
-
|
|
114
|
+
modifyFiltersState((state)=>{
|
|
108
115
|
const newState = new Map(state);
|
|
109
116
|
const prevFilterState = state.get(filter.id);
|
|
110
117
|
newState.set(filter.id, {
|
|
@@ -148,6 +155,7 @@ const useRenderParams = (args)=>{
|
|
|
148
155
|
const getFilterContainOption = (filter, values)=>(values ?? filtersState).get(filter.id)?.selectedContainOption;
|
|
149
156
|
const changeFiltersState = (filtersState)=>{
|
|
150
157
|
setFiltersState(filtersState);
|
|
158
|
+
args.onChange?.(filtersState);
|
|
151
159
|
};
|
|
152
160
|
return {
|
|
153
161
|
getRenderParams,
|
|
@@ -10,7 +10,7 @@ import { ContainOptionsList } from "../ContainOptionsList/index.js";
|
|
|
10
10
|
import { OutlineInput } from "../OutlineInput/index.js";
|
|
11
11
|
import { InputContent } from "./InputContent/index.js";
|
|
12
12
|
import MultiselectFilter_module from "./MultiselectFilter.module.js";
|
|
13
|
-
const MultiselectFilter = /*#__PURE__*/ forwardRef(({ items, values, containOptions, selectedContainOption, showSelectAllCheckbox, selectAllCheckboxText, closeDropdownOnCreateButtonClick, getManyItemsChipText, getNotFoundText, showCreateButton, getCreateButtonText, onCreateButtonClick, createButtonIcon, limit, getLimitText, loadingText, onSearch, tooltipDelay, dropdownZIndex, renderItem, optionsClassName, inputText, hideOptions, onChangeContainOption, onChange, onDropdownVisibleChange, ...props }, ref)=>{
|
|
13
|
+
const MultiselectFilter = /*#__PURE__*/ forwardRef(({ items, values, containOptions, selectedContainOption, showSelectAllCheckbox, selectAllCheckboxText, closeDropdownOnCreateButtonClick, getManyItemsChipText, getOtherText, getNotFoundText, showCreateButton, getCreateButtonText, onCreateButtonClick, createButtonIcon, limit, getLimitText, loadingText, onSearch, tooltipDelay, dropdownZIndex, renderItem, optionsClassName, inputText, hideOptions, onChangeContainOption, onChange, onDropdownVisibleChange, ...props }, ref)=>{
|
|
14
14
|
const [isDropdownOpen, setIsDropdownOpen] = useState(false);
|
|
15
15
|
const dropdownId = useId();
|
|
16
16
|
const outlineInputRef = useRef(null);
|
|
@@ -115,7 +115,7 @@ const MultiselectFilter = /*#__PURE__*/ forwardRef(({ items, values, containOpti
|
|
|
115
115
|
chipRefs: chipRefs,
|
|
116
116
|
onItemDelete: handleDeleteItemFromInputContent,
|
|
117
117
|
onDeleteFirstItem: handleDeleteFirstItemFromInputContent,
|
|
118
|
-
getOtherText:
|
|
118
|
+
getOtherText: getOtherText
|
|
119
119
|
}),
|
|
120
120
|
staticActions: /*#__PURE__*/ jsx("div", {
|
|
121
121
|
onFocus: (e)=>e.preventDefault(),
|
|
@@ -5,7 +5,7 @@ import { Text, TextTag } from "../../../components/Text/Text.js";
|
|
|
5
5
|
import { useId } from "../../../hooks/useId/index.js";
|
|
6
6
|
import OutlineInput_module from "./OutlineInput.module.js";
|
|
7
7
|
const DEFAULT_FOCUSED_WIDTH = 256;
|
|
8
|
-
const OutlineInput = /*#__PURE__*/ forwardRef(({ id, className, value, label, name, testId, error, disabled, actions, focusedWidth, style, tabIndex, inputRef: inputRefProp, inputContent, focusedState, onClick, renderCustomInput, staticActions, ...props }, ref)=>{
|
|
8
|
+
const OutlineInput = /*#__PURE__*/ forwardRef(({ id, className, value, label, name, testId, error, disabled, actions, focusedWidth, style, tabIndex, inputRef: inputRefProp, inputContent, focusedState, onClick, renderCustomInput, onChange, staticActions, ...props }, ref)=>{
|
|
9
9
|
const containerRef = useRef(null);
|
|
10
10
|
const inputRef = useRef(null);
|
|
11
11
|
const inputId = useId(id);
|
|
@@ -82,7 +82,7 @@ const OutlineInput = /*#__PURE__*/ forwardRef(({ id, className, value, label, na
|
|
|
82
82
|
onKeyUp: props.onKeyUp,
|
|
83
83
|
ref: assignInputRef,
|
|
84
84
|
value,
|
|
85
|
-
onChange
|
|
85
|
+
onChange
|
|
86
86
|
}),
|
|
87
87
|
actions ? /*#__PURE__*/ jsx("div", {
|
|
88
88
|
className: OutlineInput_module.actionsContainer,
|
|
@@ -86,7 +86,7 @@
|
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
.wrapper-rrsJYW:focus-within, .wrapper-rrsJYW.focused-czIkxi {
|
|
89
|
-
--input-filter-border: var(--
|
|
89
|
+
--input-filter-border: var(--border-focused, #091739);
|
|
90
90
|
--input-filter-label: var(--text-primary, #9fa7af);
|
|
91
91
|
outline: none;
|
|
92
92
|
}
|
|
@@ -13,6 +13,7 @@ export interface TableNumberInputProps extends Omit<TableInputProps, OmittedTabl
|
|
|
13
13
|
defaultFormatterOptions?: DefaultFormatterOptions;
|
|
14
14
|
formatter?: (value: number | null) => string;
|
|
15
15
|
suffix?: string;
|
|
16
|
+
allowBlurWhenValueNotChange?: boolean;
|
|
16
17
|
}
|
|
17
18
|
export declare const TableNumberInput: React.MemoExoticComponent<React.ForwardRefExoticComponent<TableNumberInputProps & React.RefAttributes<HTMLDivElement>>>;
|
|
18
19
|
export {};
|
|
@@ -5,7 +5,7 @@ import { REGEX_COPY_PASTE_KEYS, RESERVED_CODES, RESERVED_KEYS } from "../../../.
|
|
|
5
5
|
import { TableInput } from "../TableInput/TableInput.js";
|
|
6
6
|
import { getRegex, numberFormatter, parser, sanitize } from "./utils.js";
|
|
7
7
|
import TableNumberInput_module from "./TableNumberInput.module.js";
|
|
8
|
-
const TableNumberInput = /*#__PURE__*/ memo(/*#__PURE__*/ forwardRef(({ value, allowNegative = true, allowDecimal = true, decimalSeparator, maximumFractionDigits = 2, defaultFormatterOptions, formatter, suffix, onBlur, onChange, onKeyDown, onPaste, inputRef: inputRefProp, ...rest }, ref)=>{
|
|
8
|
+
const TableNumberInput = /*#__PURE__*/ memo(/*#__PURE__*/ forwardRef(({ value, allowNegative = true, allowDecimal = true, decimalSeparator, maximumFractionDigits = 2, defaultFormatterOptions, formatter, suffix, onBlur, onChange, onKeyDown, onPaste, onInput, inputRef: inputRefProp, allowBlurWhenValueNotChange = true, ...rest }, ref)=>{
|
|
9
9
|
const inputRef = useRef(null);
|
|
10
10
|
const timeoutRef = useRef();
|
|
11
11
|
const getFormattedValue = useCallback((value)=>formatter ? formatter(value) : numberFormatter({
|
|
@@ -43,16 +43,20 @@ const TableNumberInput = /*#__PURE__*/ memo(/*#__PURE__*/ forwardRef(({ value, a
|
|
|
43
43
|
maximumFractionDigits,
|
|
44
44
|
suffix
|
|
45
45
|
]);
|
|
46
|
+
const formattedValue = getFormattedValue(value);
|
|
46
47
|
const handleBlur = useCallback((e)=>{
|
|
47
48
|
const sanitizedValue = getSanitizedValue(e.target.value);
|
|
48
49
|
const parsedValue = getParsedValue(sanitizedValue);
|
|
49
50
|
const formatted = getFormattedValue(parsedValue);
|
|
50
|
-
|
|
51
|
+
if (!allowBlurWhenValueNotChange && formattedValue === formatted) return;
|
|
51
52
|
if (inputRef.current) inputRef.current.value = formatted;
|
|
53
|
+
onBlur?.(e, parsedValue);
|
|
52
54
|
}, [
|
|
53
|
-
getFormattedValue,
|
|
54
55
|
getSanitizedValue,
|
|
55
56
|
getParsedValue,
|
|
57
|
+
getFormattedValue,
|
|
58
|
+
formattedValue,
|
|
59
|
+
allowBlurWhenValueNotChange,
|
|
56
60
|
onBlur
|
|
57
61
|
]);
|
|
58
62
|
const handleChange = useCallback((e)=>{
|
|
@@ -89,15 +93,23 @@ const TableNumberInput = /*#__PURE__*/ memo(/*#__PURE__*/ forwardRef(({ value, a
|
|
|
89
93
|
const currentValue = input.value;
|
|
90
94
|
const newValue = currentValue.substring(0, start) + pasteData + currentValue.substring(end);
|
|
91
95
|
const sanitizedValue = getSanitizedValue(newValue);
|
|
92
|
-
|
|
96
|
+
input.value = sanitizedValue;
|
|
93
97
|
const newCursorPos = start + sanitizedValue.length;
|
|
94
98
|
clearTimeout(timeoutRef.current);
|
|
95
99
|
timeoutRef.current = setTimeout(()=>{
|
|
96
100
|
input.setSelectionRange(newCursorPos, newCursorPos);
|
|
97
101
|
}, 0);
|
|
102
|
+
const changeEvent = {
|
|
103
|
+
target: input,
|
|
104
|
+
currentTarget: input
|
|
105
|
+
};
|
|
106
|
+
handleChange(changeEvent);
|
|
107
|
+
onInput?.(changeEvent);
|
|
98
108
|
onPaste?.(e);
|
|
99
109
|
}, [
|
|
100
110
|
getSanitizedValue,
|
|
111
|
+
handleChange,
|
|
112
|
+
onInput,
|
|
101
113
|
onPaste
|
|
102
114
|
]);
|
|
103
115
|
useEffect(()=>{
|
|
@@ -109,7 +121,6 @@ const TableNumberInput = /*#__PURE__*/ memo(/*#__PURE__*/ forwardRef(({ value, a
|
|
|
109
121
|
useEffect(()=>()=>{
|
|
110
122
|
clearTimeout(timeoutRef.current);
|
|
111
123
|
}, []);
|
|
112
|
-
const formattedValue = getFormattedValue(value);
|
|
113
124
|
return /*#__PURE__*/ jsx(TableInput, {
|
|
114
125
|
ref: ref,
|
|
115
126
|
inputRef: mergeRefs([
|
|
@@ -122,6 +133,7 @@ const TableNumberInput = /*#__PURE__*/ memo(/*#__PURE__*/ forwardRef(({ value, a
|
|
|
122
133
|
onBlur: handleBlur,
|
|
123
134
|
onKeyDown: handleKeyDown,
|
|
124
135
|
onPaste: handlePaste,
|
|
136
|
+
onInput: onInput,
|
|
125
137
|
...rest
|
|
126
138
|
});
|
|
127
139
|
}));
|
|
@@ -6,11 +6,11 @@ import { Down12Icon, RemoveClose12Icon } from "../../../../icon/index.js";
|
|
|
6
6
|
import { TableInput } from "../TableInput/TableInput.js";
|
|
7
7
|
import { ActionButton } from "./ActionButton/ActionButton.js";
|
|
8
8
|
import TableSelect_module from "./TableSelect.module.js";
|
|
9
|
-
const TableSelectComponent = ({ inputProps, name, renderActions, customOnArrowBtnClick, ...selectProps }, ref)=>{
|
|
9
|
+
const TableSelectComponent = ({ inputProps, name, renderActions, customOnArrowBtnClick, clearable = true, ...selectProps }, ref)=>{
|
|
10
10
|
const inputRef = useRef(null);
|
|
11
11
|
const actionsRenderer = ({ clearHandler, toggleHandler })=>/*#__PURE__*/ jsxs(Fragment, {
|
|
12
12
|
children: [
|
|
13
|
-
!!selectProps.value && !selectProps.disabled && /*#__PURE__*/ jsxs(Fragment, {
|
|
13
|
+
clearable && !!selectProps.value && !selectProps.disabled && /*#__PURE__*/ jsxs(Fragment, {
|
|
14
14
|
children: [
|
|
15
15
|
/*#__PURE__*/ jsx("button", {
|
|
16
16
|
"data-test-id": selectProps.testId ? `${selectProps.testId}-clear-button` : void 0,
|
|
@@ -95,6 +95,7 @@ const TableSelectComponent = ({ inputProps, name, renderActions, customOnArrowBt
|
|
|
95
95
|
searchable: true,
|
|
96
96
|
renderInput: inputRenderer,
|
|
97
97
|
ref: ref,
|
|
98
|
+
clearable: clearable,
|
|
98
99
|
...selectProps
|
|
99
100
|
});
|
|
100
101
|
};
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { type HTMLAttributes, type RefObject } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* @deprecated Use { Dropdown } from @lognex/uikit instead
|
|
4
|
+
*/
|
|
2
5
|
export declare const Dropdown: import("react").ForwardRefExoticComponent<{
|
|
3
6
|
buttonRef: RefObject<HTMLElement>;
|
|
4
7
|
align?: "left" | "right";
|
|
@@ -115,6 +115,7 @@ const HeaderBuilder = /*#__PURE__*/ memo(({ children, sortDirection, btnClass, i
|
|
|
115
115
|
}),
|
|
116
116
|
Boolean(sortDirection) && /*#__PURE__*/ jsx("div", {
|
|
117
117
|
className: HeaderBuilder_module.wrapper,
|
|
118
|
+
"data-test-id": testId ? `${testId}-header-sort-icon` : 'header-sort-icon',
|
|
118
119
|
children: /*#__PURE__*/ jsx(ArrowIcon, {
|
|
119
120
|
className: cn(HeaderBuilder_module.arrow, 'asc' === sortDirection && HeaderBuilder_module.rotated)
|
|
120
121
|
})
|
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
export * from './base';
|
|
2
|
-
export * from './base';
|
|
3
|
-
export * from './cells';
|
|
4
2
|
export * from './cells';
|
|
5
3
|
export * from './ColumnSettings';
|
|
6
4
|
export * from './Filters';
|
|
7
5
|
export * from './headers';
|
|
8
|
-
export * from './headers';
|
|
9
|
-
export * from './hooks';
|
|
10
6
|
export * from './hooks';
|
|
11
7
|
export * from './Pagination';
|
|
12
8
|
export * from './SavedFilters';
|
|
@@ -48,69 +48,81 @@ const enLocaleValues = {
|
|
|
48
48
|
selectedOrdersLabel: (count)=>1 === count ? `${count} order` : `${count} orders`
|
|
49
49
|
},
|
|
50
50
|
DateRangeFilter: {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
dayQuickFilters: {
|
|
60
|
-
yesterday: 'Yesterday',
|
|
61
|
-
today: 'Today'
|
|
62
|
-
},
|
|
63
|
-
footer: {
|
|
64
|
-
timeSelectionToggle: 'Set time',
|
|
65
|
-
timeSelectionToggleHint: 'Setting time is available only in period mode',
|
|
66
|
-
clearFilterButton: 'Clear filter'
|
|
67
|
-
},
|
|
68
|
-
slider: {
|
|
69
|
-
day: {
|
|
70
|
-
title: 'Day',
|
|
71
|
-
placeholder: 'Select day',
|
|
72
|
-
dateFormat: 'MMMM d, yyyy'
|
|
51
|
+
translate: {
|
|
52
|
+
radiobuttons: {
|
|
53
|
+
period: 'Period',
|
|
54
|
+
day: 'Day',
|
|
55
|
+
week: 'Week',
|
|
56
|
+
month: 'Month',
|
|
57
|
+
anyDate: 'Any date specified',
|
|
58
|
+
noDate: 'No date specified'
|
|
73
59
|
},
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
60
|
+
dayQuickFilters: {
|
|
61
|
+
yesterday: 'Yesterday',
|
|
62
|
+
today: 'Today'
|
|
63
|
+
},
|
|
64
|
+
footer: {
|
|
65
|
+
timeSelectionToggle: 'Set time',
|
|
66
|
+
timeSelectionToggleHint: 'Setting time is available only in period mode',
|
|
67
|
+
clearFilterButton: 'Clear filter'
|
|
68
|
+
},
|
|
69
|
+
slider: {
|
|
70
|
+
day: {
|
|
71
|
+
title: 'Day',
|
|
72
|
+
placeholder: 'Select day'
|
|
73
|
+
},
|
|
74
|
+
week: {
|
|
75
|
+
title: 'Week',
|
|
76
|
+
placeholder: 'Select week'
|
|
86
77
|
},
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
78
|
+
month: {
|
|
79
|
+
title: 'Month',
|
|
80
|
+
placeholder: 'Select month'
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
},
|
|
84
|
+
format: {
|
|
85
|
+
slider: {
|
|
86
|
+
day: {
|
|
87
|
+
dateFormat: 'MMMM d, yyyy'
|
|
88
|
+
},
|
|
89
|
+
week: {
|
|
90
|
+
dateFormat: {
|
|
91
|
+
sameMonth: {
|
|
92
|
+
firstDate: 'MMMM d',
|
|
93
|
+
endDate: 'd, yyyy'
|
|
94
|
+
},
|
|
95
|
+
differentMonth: {
|
|
96
|
+
firstDate: 'MMM d',
|
|
97
|
+
endDate: 'MMM d, yyyy'
|
|
98
|
+
}
|
|
91
99
|
},
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
100
|
+
tooltipDateFormat: {
|
|
101
|
+
sameMonth: {
|
|
102
|
+
firstDate: 'MMMM d',
|
|
103
|
+
endDate: 'd, yyyy'
|
|
104
|
+
},
|
|
105
|
+
differentMonth: {
|
|
106
|
+
firstDate: 'MMM d',
|
|
107
|
+
endDate: 'MMM d, yyyy'
|
|
108
|
+
}
|
|
95
109
|
}
|
|
110
|
+
},
|
|
111
|
+
month: {
|
|
112
|
+
dateFormat: 'LLLL yyyy'
|
|
96
113
|
}
|
|
97
114
|
},
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
115
|
+
dateFormat: 'MM/dd/yyyy',
|
|
116
|
+
monthCalendarFormat: 'LLL',
|
|
117
|
+
dateWithTimeFormat: 'MM/dd/yyyy HH:mm',
|
|
118
|
+
emptyDate: {
|
|
119
|
+
withTime: '__/__/____ __:__',
|
|
120
|
+
withoutTime: '__/__/____'
|
|
121
|
+
},
|
|
122
|
+
inputMask: {
|
|
123
|
+
withTime: '99/99/9999 99:99',
|
|
124
|
+
withoutTime: '99/99/9999'
|
|
102
125
|
}
|
|
103
|
-
},
|
|
104
|
-
dateFormat: 'MM/dd/yyyy',
|
|
105
|
-
monthCalendarFormat: 'LLL',
|
|
106
|
-
dateWithTimeFormat: 'MM/dd/yyyy HH:mm',
|
|
107
|
-
emptyDate: {
|
|
108
|
-
withTime: '__/__/____ __:__',
|
|
109
|
-
withoutTime: '__/__/____'
|
|
110
|
-
},
|
|
111
|
-
inputMask: {
|
|
112
|
-
withTime: '99/99/9999 99:99',
|
|
113
|
-
withoutTime: '99/99/9999'
|
|
114
126
|
}
|
|
115
127
|
}
|
|
116
128
|
};
|