@sberbusiness/triplex-next 1.1.0 → 1.2.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 +8 -8
- package/chunks/{AlertProcessSpoiler-Dp7FRT9y.js → AlertProcessSpoiler-B3Xzh0I2.js} +13 -13
- package/chunks/Card.module-Dh5vP2zv.js +17 -0
- package/chunks/DropdownListItem-B1GkU8rn.js +57 -0
- package/chunks/DropdownMobile.module-CYlB98Oc.js +21 -0
- package/chunks/Footer.module-Bk8QkaWN.js +11 -0
- package/chunks/{FormFieldInput-apk1b0w6.js → FormFieldInput-n8Ee4EcP.js} +23 -23
- package/chunks/HeaderLayoutSidebar.module-CDNHX5_G.js +9 -0
- package/chunks/HeaderTabs.module-yaGpurOU.js +9 -0
- package/chunks/HeaderTitle.module-XzB-YndL.js +9 -0
- package/chunks/{ListItemControlsButton-Cn3Vmrsn.js → ListItemControlsButton-BdtSkcyn.js} +10 -10
- package/chunks/ListItemTail.module-D_m5pMsh.js +12 -0
- package/chunks/ListMasterFooter.module-DXrsYZZo.js +10 -0
- package/chunks/Overlay.module-BghrPKKn.js +18 -0
- package/chunks/Page.module-D6xCdUbr.js +12 -0
- package/chunks/RightBorderArrow-BA2_2Ry3.js +146 -0
- package/chunks/SuggestFieldMobileDropdownHint-Dz-VDDoR.js +15 -0
- package/chunks/TableFooter.module-BzfTOGS_.js +13 -0
- package/chunks/TabsExtended.module-B3nvdhKr.js +16 -0
- package/chunks/TabsLine.module-Dlj__Yjk.js +23 -0
- package/chunks/TooltipDesktop.module-TiWl3v5C.js +19 -0
- package/chunks/{UploadZoneInput-R9729LZY.js → UploadZoneInput-CioKsqkV.js} +10 -10
- package/chunks/utils-B5p23Ple.js +26 -0
- package/chunks/utils-BtcCJ4_U.js +20 -0
- package/chunks/utils-D7E_PKCe.js +36 -0
- package/chunks/utils-DPXynVs1.js +72 -0
- package/chunks/utils-DjxtOr-n.js +48 -0
- package/chunks/vendor-CehxOAkM.js +11907 -0
- package/components/Alert/AlertContext/AlertContext.js +6 -6
- package/components/Alert/AlertProcess/AlertProcess.js +3 -3
- package/components/Alert/AlertProcess/components/AlertProcessSpoiler.js +2 -2
- package/components/Amount/Amount.js +37 -0
- package/components/Amount/index.js +5 -0
- package/components/AmountField/AmountBaseInputCore.js +46 -0
- package/components/AmountField/AmountBaseInputFormatter.js +57 -0
- package/components/AmountField/AmountBaseInputParser.js +110 -0
- package/components/AmountField/AmountField.js +76 -0
- package/components/AmountField/index.js +5 -0
- package/components/AmountField/utils.js +38 -0
- package/components/Body/Body.js +6 -6
- package/components/Button/Button.js +73 -72
- package/components/Button/ButtonBase.js +1 -1
- package/components/Button/ButtonDropdown.js +113 -127
- package/components/Button/ButtonDropdownExtended.js +2 -2
- package/components/Button/ButtonIcon.js +2 -2
- package/components/Card/CardAction.js +10 -10
- package/components/Card/CardStatic.js +3 -3
- package/components/Card/components/CardContent/CardContent.js +2 -2
- package/components/Card/components/CardContent/components/CardContentBody.js +2 -2
- package/components/Card/components/CardContent/components/CardContentFooter.js +2 -2
- package/components/Card/components/CardContent/components/CardContentHeader.js +2 -2
- package/components/Card/components/CardMedia.js +2 -2
- package/components/Card/utils.js +1 -1
- package/components/CarouselExtended/CarouselExtended.js +48 -0
- package/components/Checkbox/Checkbox.js +46 -30
- package/components/Checkbox/CheckboxXGroup.js +14 -14
- package/components/Checkbox/CheckboxYGroup.js +4 -4
- package/components/Checkbox/index.js +4 -6
- package/components/Chip/Chip.js +86 -0
- package/components/Chip/ChipClearButton.js +28 -0
- package/components/Chip/ChipDropdownArrow.js +18 -0
- package/components/Chip/ChipIcon.js +9 -0
- package/components/Chip/ChipOptions.js +27 -0
- package/components/Chip/enums.js +5 -0
- package/components/Chip/index.js +15 -0
- package/components/ChipGroup/ChipGroup.js +32 -0
- package/components/ChipGroup/index.js +5 -0
- package/components/Col/Col.js +142 -142
- package/components/DesignTokens/DesignTokenUtils.js +2 -2
- package/components/DesignTokens/DesignTokensComponents.js +89 -69
- package/components/DesignTokens/DesignTokensComponentsThemeDark.js +92 -77
- package/components/DesignTokens/components/Card.js +23 -20
- package/components/DesignTokens/components/Checkbox.js +32 -14
- package/components/DesignTokens/components/Chip.js +59 -0
- package/components/DesignTokens/components/Divider.js +9 -0
- package/components/DesignTokens/components/Dropdown.js +1 -1
- package/components/DesignTokens/components/DropdownList.js +2 -2
- package/components/DesignTokens/components/DropdownMobile.js +3 -3
- package/components/DesignTokens/components/FooterPage.js +3 -3
- package/components/DesignTokens/components/HeaderPage.js +4 -4
- package/components/DesignTokens/components/ListItemControlsButton.js +20 -5
- package/components/DesignTokens/components/Marker.js +20 -0
- package/components/DesignTokens/components/MarkerStatus.js +9 -0
- package/components/DesignTokens/components/Radio.js +22 -13
- package/components/DesignTokens/components/Stepper.js +71 -0
- package/components/DesignTokens/components/TableBasic.js +41 -0
- package/components/DesignTokens/components/Tabs.js +45 -15
- package/components/DesignTokens/components/TabsLine.js +32 -0
- package/components/DesignTokens/components/index.js +100 -79
- package/components/Divider/Divider.js +34 -0
- package/components/Divider/index.js +5 -0
- package/components/Dropdown/desktop/DropdownDesktop.js +52 -51
- package/components/Dropdown/desktop/DropdownList.js +66 -53
- package/components/Dropdown/desktop/DropdownListItem.js +2 -2
- package/components/Dropdown/desktop/index.js +9 -0
- package/components/Dropdown/index.js +33 -29
- package/components/Dropdown/mobile/DropdownMobile.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileBody.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileClose.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileFooter.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileHeader.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileInner.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileInput.js +9 -8
- package/components/Dropdown/mobile/DropdownMobileList.js +26 -17
- package/components/Dropdown/mobile/DropdownMobileListItem.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileLoader.js +20 -0
- package/components/Dropdown/mobile/index.js +5 -3
- package/components/Ellipsis/Ellipsis.js +27 -0
- package/components/Ellipsis/index.js +5 -0
- package/components/ExpandAnimation/ExpandAnimation.js +72 -0
- package/components/Footer/Footer.js +3 -3
- package/components/Footer/components/FooterDescription.js +2 -2
- package/components/Footer/components/FooterDescriptionContent.js +2 -2
- package/components/Footer/components/FooterDescriptionControls.js +2 -2
- package/components/FormField/FormField.js +34 -33
- package/components/FormField/FormFieldContext.js +8 -7
- package/components/FormField/components/FormFieldClear.js +24 -20
- package/components/FormField/components/FormFieldCounter.js +5 -5
- package/components/FormField/components/FormFieldDescription.js +5 -5
- package/components/FormField/components/FormFieldInput.js +2 -2
- package/components/FormField/components/FormFieldLabel.js +14 -14
- package/components/FormField/components/FormFieldMaskedInput.js +12 -12
- package/components/FormField/components/FormFieldPostfix.js +6 -6
- package/components/FormField/components/FormFieldPrefix.js +7 -7
- package/components/FormField/components/FormFieldTarget.js +22 -22
- package/components/FormField/components/FormFieldTextarea.js +6 -6
- package/components/FormField/index.js +1 -1
- package/components/Header/Header.js +12 -12
- package/components/Header/components/HeaderLayoutSidebar/HeaderLayoutSidebar.js +2 -2
- package/components/Header/components/HeaderLayoutSidebar/HeaderLayoutSidebarContent.js +2 -2
- package/components/Header/components/HeaderLayoutSidebar/HeaderLayoutSidebarSidebar.js +2 -2
- package/components/Header/components/HeaderSubheader/HeaderSubheader.js +6 -6
- package/components/Header/components/HeaderTabs/HeaderTabs.js +2 -2
- package/components/Header/components/HeaderTabs/HeaderTabsContent.js +2 -2
- package/components/Header/components/HeaderTabs/HeaderTabsControls.js +2 -2
- package/components/Header/components/HeaderTitle/HeaderTitle.js +2 -2
- package/components/Header/components/HeaderTitle/HeaderTitleContent.js +2 -2
- package/components/Header/components/HeaderTitle/HeaderTitleControls.js +2 -2
- package/components/HelpBox/HelpBox.js +94 -0
- package/components/Island/Island.js +25 -66
- package/components/Island/components/IslandBody.js +4 -4
- package/components/Island/components/IslandFooter.js +4 -4
- package/components/Island/components/IslandHeader.js +2 -2
- package/components/Island/enums.js +1 -3
- package/components/Island/index.js +4 -6
- package/components/Island/types.js +2 -0
- package/components/Island/utils.js +8 -0
- package/components/Link/Link.js +27 -27
- package/components/List/List.js +12 -20
- package/components/List/ListSortable.js +1 -1
- package/components/List/components/ListEmptyState.js +6 -6
- package/components/List/components/ListItem.js +1 -10
- package/components/List/components/ListItemContent.js +7 -7
- package/components/List/components/ListItemControls.js +7 -7
- package/components/List/components/ListItemControlsButton.js +2 -2
- package/components/List/components/ListItemControlsButtonDropdown.js +4 -2
- package/components/List/components/ListItemLoading.js +11 -9
- package/components/List/components/ListItemSelectable.js +5 -5
- package/components/List/components/ListItemTable.js +9 -9
- package/components/List/components/ListItemTailLeft.js +2 -2
- package/components/List/components/ListItemTailRight.js +2 -2
- package/components/List/components/ListSortableItem.js +2 -2
- package/components/List/components/ListSortableItemControls.js +2 -2
- package/components/List/components/ListSortableItemTarget.js +8 -8
- package/components/List/index.js +1 -1
- package/components/ListMaster/ListMaster.js +1 -1
- package/components/ListMaster/components/ListMasterBody.js +1 -1
- package/components/ListMaster/components/ListMasterChipGroup.js +5 -5
- package/components/ListMaster/components/ListMasterFooter.js +2 -2
- package/components/ListMaster/components/ListMasterFooterControls.js +2 -2
- package/components/ListMaster/components/ListMasterFooterDescription.js +2 -2
- package/components/ListMaster/components/ListMasterHeader.js +6 -6
- package/components/ListMaster/components/SelectionControls.js +3 -3
- package/components/Loader/LoaderMiddle/LoaderMiddle.js +5 -5
- package/components/Loader/LoaderSmall/LoaderSmall.js +24 -35
- package/components/LoaderWidget/LoaderWidget.js +15 -14
- package/components/Marker/Marker.js +20 -0
- package/components/Marker/enums.js +5 -0
- package/components/Marker/index.js +7 -0
- package/components/Marker/utils.js +6 -0
- package/components/MarkerStatus/MarkerStatus.js +36 -0
- package/components/MarkerStatus/index.js +5 -0
- package/components/OrderedList/OrderedList.js +25 -0
- package/components/OrderedList/OrderedListItem.js +27 -0
- package/components/OrderedList/index.js +7 -0
- package/components/OrderedList/types.js +2 -0
- package/components/Overlay/Overlay.js +2 -2
- package/components/Overlay/OverlayMask.js +2 -2
- package/components/Overlay/OverlayPanel.js +2 -2
- package/components/Page/Page.js +2 -2
- package/components/Page/components/BodyPage.js +2 -2
- package/components/Page/components/FooterPage.js +28 -31
- package/components/Page/components/HeaderPage.js +26 -29
- package/components/Page/components/useStickyCornerRadius.js +34 -0
- package/components/Pagination/components/PaginationExtended.js +3 -3
- package/components/Pagination/components/PaginationNavigationButton.js +5 -5
- package/components/Pagination/components/PaginationNavigationExtended.js +2 -2
- package/components/Pagination/components/PaginationPageButton.js +2 -2
- package/components/Pagination/components/PaginationPageEllipsis.js +3 -3
- package/components/Pagination/components/PaginationSelect.js +7 -7
- package/components/Pagination/utils/paginationUtils.js +1 -1
- package/components/Radio/Radio.js +29 -21
- package/components/Radio/RadioXGroup.js +10 -10
- package/components/Radio/RadioYGroup.js +5 -5
- package/components/Radio/index.js +4 -6
- package/components/Row/Row.js +6 -6
- package/components/SegmentedControl/SegmentedControl.js +36 -39
- package/components/SegmentedControl/SegmentedControlSegment.js +6 -6
- package/components/SelectExtendedField/SelectExtendedField.js +9 -9
- package/components/SelectExtendedField/components/SelectExtendedFieldDropdown.js +5 -2
- package/components/SelectExtendedField/components/SelectExtendedFieldDropdownDefault.js +22 -18
- package/components/SelectExtendedField/components/SelectExtendedFieldTarget.js +38 -37
- package/components/SelectField/SelectField.js +62 -0
- package/components/SelectField/index.js +5 -0
- package/components/Skeleton/Skeleton.js +11 -11
- package/components/Stepper/RightBorderArrow.js +7 -0
- package/components/Stepper/Stepper.js +103 -0
- package/components/Stepper/StepperExtended.js +26 -0
- package/components/Stepper/StepperExtendedContext.js +12 -0
- package/components/Stepper/StepperStep.js +88 -0
- package/components/Stepper/StepperStepIcon.js +23 -0
- package/components/Stepper/StepperWrapper.js +12 -0
- package/components/Stepper/enums.js +7 -0
- package/components/Stepper/index.js +11 -0
- package/components/SuggestField/SuggestField.js +64 -0
- package/components/SuggestField/SuggestFieldTarget.js +67 -0
- package/components/SuggestField/SuggestFieldTargetPostfix.js +28 -0
- package/components/SuggestField/desktop/SuggestFieldDesktop.js +196 -0
- package/components/SuggestField/desktop/SuggestFieldDesktopDropdown.js +76 -0
- package/components/SuggestField/desktop/index.js +7 -0
- package/components/SuggestField/desktop/types.js +2 -0
- package/components/SuggestField/index.js +17 -0
- package/components/SuggestField/mobile/SuggestFieldMobile.js +79 -0
- package/components/SuggestField/mobile/SuggestFieldMobileDropdown.js +94 -0
- package/components/SuggestField/mobile/SuggestFieldMobileDropdownHint.js +10 -0
- package/components/SuggestField/mobile/SuggestFieldMobileTarget.js +30 -0
- package/components/SuggestField/mobile/index.js +11 -0
- package/components/SuggestField/mobile/types.js +2 -0
- package/components/SuggestField/types.js +2 -0
- package/components/SwipeableArea/SwipeableArea.js +21 -21
- package/components/Table/FilterPanel.js +18 -0
- package/components/Table/MasterTable.js +49 -0
- package/components/Table/MasterTableContext.js +11 -0
- package/components/Table/NoColumns.js +17 -0
- package/components/Table/PaginationPanel.js +18 -0
- package/components/Table/TableBasic/TableBasic.js +51 -0
- package/components/Table/TableBasic/components/TableBasicBody.js +18 -0
- package/components/Table/TableBasic/components/TableBasicHeader.js +83 -0
- package/components/Table/TableBasic/components/TableBasicRow.js +53 -0
- package/components/Table/TableBasic/enums.js +8 -0
- package/components/Table/TableBasic/types.js +2 -0
- package/components/Table/TableBasicSettings/TableBasicSettings.js +58 -0
- package/components/Table/TableBasicSettings/components/ColumnSettings.js +20 -0
- package/components/Table/TableBasicSettings/components/ColumnSettingsSortableList.js +24 -0
- package/components/Table/TableBasicSettings/components/ColumnSettingsSortableListItem.js +25 -0
- package/components/Table/TableBasicSettings/components/ColumnSettingsSortableListItemTarget.js +29 -0
- package/components/Table/TableBasicSettings/components/ColumnSettingsStaticList.js +17 -0
- package/components/Table/TableBasicSettings/components/ColumnSettingsStaticListItem.js +14 -0
- package/components/Table/TableBasicSettings/components/TableBasicSettingsBody.js +13 -0
- package/components/Table/TableBasicSettings/components/TableBasicSettingsFooter.js +13 -0
- package/components/Table/TableBasicSettings/components/TableBasicSettingsHeader.js +26 -0
- package/components/Table/TableFooter/TableFooter.js +14 -0
- package/components/Table/TableFooter/components/TableFooterSummary.js +19 -0
- package/components/Table/TableFooter/components/TableFooterSummaryAmount.js +18 -0
- package/components/Table/TableFooter/components/TableFooterSummarySelectAllButton.js +31 -0
- package/components/Table/TableFooter/components/TableFooterSummarySelectedCount.js +8 -0
- package/components/Table/TabsLinePanel.js +12 -0
- package/components/Table/TabsLinePanelLinks.js +14 -0
- package/components/Table/index.js +26 -0
- package/components/Table/utils.js +8 -0
- package/components/Tabs/Tabs.js +75 -0
- package/components/Tabs/index.js +5 -0
- package/components/TabsExtended/TabsExtended.js +37 -21
- package/components/TabsExtended/TabsExtendedContext.js +6 -4
- package/components/TabsExtended/components/TabsExtendedContent.js +19 -15
- package/components/TabsExtended/components/TabsExtendedDropdownWrapper.js +2 -2
- package/components/TabsExtended/components/TabsExtendedTab.js +2 -2
- package/components/TabsExtended/components/TabsExtendedTabButton.js +17 -15
- package/components/TabsExtended/components/TabsExtendedTabsWrapper.js +7 -7
- package/components/TabsExtended/components/index.js +15 -0
- package/components/TabsExtended/enums.js +2 -2
- package/components/TabsExtended/index.js +15 -3
- package/components/TabsExtended/utils.js +9 -0
- package/components/TabsLine/TabsLine.js +48 -0
- package/components/TabsLine/components/TabsLineDesktop.js +81 -0
- package/components/TabsLine/components/TabsLineDropdown.js +151 -0
- package/components/TabsLine/components/TabsLineItem.js +26 -0
- package/components/TabsLine/components/TabsLineMobile.js +21 -0
- package/components/TabsLine/components/index.js +11 -0
- package/components/TabsLine/index.js +13 -0
- package/components/TabsLine/types.js +2 -0
- package/components/TextField/TextField.js +1 -1
- package/components/ThemeProvider/ThemeProvider.js +1 -1
- package/components/ThemeProvider/components/ThemeProviderView.js +4 -4
- package/components/Tooltip/components/common/TooltipBody.js +2 -2
- package/components/Tooltip/components/common/TooltipLink.js +11 -11
- package/components/Tooltip/components/common/TooltipXButton.js +1 -1
- package/components/Tooltip/components/desktop/components/TooltipDesktopBase.js +2 -2
- package/components/Tooltip/components/desktop/components/TooltipDesktopTip.js +2 -2
- package/components/Tooltip/components/mobile/TooltipMobile.js +7 -7
- package/components/Typography/Caption.js +17 -17
- package/components/Typography/Text.js +20 -20
- package/components/Typography/Title.js +15 -15
- package/components/Typography/utils.js +1 -1
- package/components/UnorderedList/UnorderedList.js +25 -0
- package/components/UnorderedList/UnorderedListItem.js +27 -0
- package/components/UnorderedList/index.js +7 -0
- package/components/UnorderedList/types.js +2 -0
- package/components/UploadZone/UploadZone.js +3 -3
- package/components/UploadZone/components/UploadZoneInput.js +2 -2
- package/components/index.js +366 -275
- package/consts/AmountConst.js +10 -0
- package/consts/DataTestId.js +19 -0
- package/enums/EComponentSize.js +5 -0
- package/enums/index.js +7 -0
- package/index.d.ts +1029 -124
- package/index.js +361 -268
- package/package.json +69 -2
- package/styles/triplex-next.css +436 -354
- package/types/CoreTypes.js +2 -0
- package/utils/amountUtils.js +34 -0
- package/utils/classNameMaps.js +10 -0
- package/utils/html/AriaAttributes.js +11 -0
- package/utils/html/DataAttributes.js +11 -0
- package/utils/inputUtils.js +11 -0
- package/utils/isNullOrUndefined.js +5 -0
- package/utils/scroll.js +13 -0
- package/utils/stringUtils.js +13 -0
- package/chunks/Card.module-Ddt7TQ9Z.js +0 -17
- package/chunks/DropdownListItem-y6Rvj_dd.js +0 -56
- package/chunks/DropdownMobile.module-DrQkghxs.js +0 -19
- package/chunks/Footer.module-CKfl241m.js +0 -11
- package/chunks/HeaderLayoutSidebar.module-DTXnksBK.js +0 -9
- package/chunks/HeaderTabs.module-DVh6MotJ.js +0 -9
- package/chunks/HeaderTitle.module-DOeVL9zC.js +0 -9
- package/chunks/ListItemTail.module-BnbT61OM.js +0 -12
- package/chunks/ListMasterFooter.module-C6QFamKQ.js +0 -10
- package/chunks/Overlay.module-BTSQ5G6t.js +0 -18
- package/chunks/Page.module-DfMBQJob.js +0 -16
- package/chunks/TabsExtended.module-okOlTNQG.js +0 -13
- package/chunks/TabsExtendedUtils-NCwWiX7O.js +0 -23
- package/chunks/TooltipDesktop.module-DTbnIWo1.js +0 -19
- package/chunks/utils-B0khB-Lq.js +0 -36
- package/chunks/vendor-D-uL_icH.js +0 -5895
- package/components/Checkbox/enum.js +0 -5
- package/components/Radio/enum.js +0 -5
- package/components/TabsExtended/TabsExtendedUtils.js +0 -8
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { jsxs as B, jsx as f } from "react/jsx-runtime";
|
|
2
|
+
import { useState as E, useRef as c, useEffect as I } from "react";
|
|
3
|
+
import { c as L } from "../../../chunks/vendor-CehxOAkM.js";
|
|
4
|
+
import { SuggestFieldMobileTarget as N } from "./SuggestFieldMobileTarget.js";
|
|
5
|
+
import { SuggestFieldMobileDropdown as R } from "./SuggestFieldMobileDropdown.js";
|
|
6
|
+
import { s as q } from "../../../chunks/SuggestFieldMobileDropdownHint-Dz-VDDoR.js";
|
|
7
|
+
function Q({
|
|
8
|
+
className: u,
|
|
9
|
+
value: r,
|
|
10
|
+
options: m,
|
|
11
|
+
size: a,
|
|
12
|
+
status: b,
|
|
13
|
+
label: x,
|
|
14
|
+
placeholder: n,
|
|
15
|
+
dropdownHint: g,
|
|
16
|
+
loading: s,
|
|
17
|
+
dropdownListLoading: w,
|
|
18
|
+
clearInputOnFocus: M,
|
|
19
|
+
onFilter: O,
|
|
20
|
+
onSelect: i,
|
|
21
|
+
onScrollEnd: D,
|
|
22
|
+
onTargetInputFocus: o,
|
|
23
|
+
onTargetInputBlur: S,
|
|
24
|
+
renderTarget: l,
|
|
25
|
+
renderTargetInput: h,
|
|
26
|
+
renderTargetLabel: j,
|
|
27
|
+
renderTargetPrefix: v,
|
|
28
|
+
renderTargetPostfix: C,
|
|
29
|
+
...F
|
|
30
|
+
}) {
|
|
31
|
+
const [e, d] = E(!1), t = c(null), p = c(!1), P = l === void 0 ? N : l;
|
|
32
|
+
I(() => {
|
|
33
|
+
p.current && !e && t.current && t.current.scrollIntoView({ block: "center" }), p.current = e;
|
|
34
|
+
}, [e]);
|
|
35
|
+
const V = () => i(void 0), k = (y) => {
|
|
36
|
+
d(!0), o == null || o(y);
|
|
37
|
+
};
|
|
38
|
+
return /* @__PURE__ */ B("div", { className: L(q.suggestFieldMobile, u), ...F, ref: t, children: [
|
|
39
|
+
/* @__PURE__ */ f(
|
|
40
|
+
P,
|
|
41
|
+
{
|
|
42
|
+
size: a,
|
|
43
|
+
status: b,
|
|
44
|
+
inputValue: r ? r.label : "",
|
|
45
|
+
label: x,
|
|
46
|
+
placeholder: n,
|
|
47
|
+
loading: s,
|
|
48
|
+
onClear: V,
|
|
49
|
+
onInputFocus: k,
|
|
50
|
+
onInputBlur: S,
|
|
51
|
+
renderInput: h,
|
|
52
|
+
renderLabel: j,
|
|
53
|
+
renderPrefix: v,
|
|
54
|
+
renderPostfix: C
|
|
55
|
+
}
|
|
56
|
+
),
|
|
57
|
+
/* @__PURE__ */ f(
|
|
58
|
+
R,
|
|
59
|
+
{
|
|
60
|
+
value: r,
|
|
61
|
+
options: m,
|
|
62
|
+
placeholder: n,
|
|
63
|
+
dropdownHint: g,
|
|
64
|
+
opened: e,
|
|
65
|
+
loading: s,
|
|
66
|
+
dropdownListLoading: w,
|
|
67
|
+
clearInputOnFocus: M,
|
|
68
|
+
setOpened: d,
|
|
69
|
+
onFilter: O,
|
|
70
|
+
onSelect: i,
|
|
71
|
+
onScrollEnd: D
|
|
72
|
+
}
|
|
73
|
+
)
|
|
74
|
+
] });
|
|
75
|
+
}
|
|
76
|
+
export {
|
|
77
|
+
Q as SuggestFieldMobile
|
|
78
|
+
};
|
|
79
|
+
//# sourceMappingURL=SuggestFieldMobile.js.map
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { jsx as t, jsxs as m, Fragment as x } from "react/jsx-runtime";
|
|
2
|
+
import y, { useState as H, useRef as p, useEffect as V } from "react";
|
|
3
|
+
import { Dropdown as j } from "../../Dropdown/Dropdown.js";
|
|
4
|
+
import "../../Dropdown/DropdownListContext.js";
|
|
5
|
+
import "../../Dropdown/desktop/DropdownDesktop.js";
|
|
6
|
+
import "../../Dropdown/desktop/DropdownList.js";
|
|
7
|
+
import "../../../chunks/DropdownListItem-B1GkU8rn.js";
|
|
8
|
+
import "../../Dropdown/mobile/DropdownMobile.js";
|
|
9
|
+
import { DropdownMobileBody as k } from "../../Dropdown/mobile/DropdownMobileBody.js";
|
|
10
|
+
import { DropdownMobileClose as _ } from "../../Dropdown/mobile/DropdownMobileClose.js";
|
|
11
|
+
import "../../Dropdown/mobile/DropdownMobileFooter.js";
|
|
12
|
+
import { DropdownMobileHeader as N } from "../../Dropdown/mobile/DropdownMobileHeader.js";
|
|
13
|
+
import "../../Dropdown/mobile/DropdownMobileInner.js";
|
|
14
|
+
import { DropdownMobileInput as O } from "../../Dropdown/mobile/DropdownMobileInput.js";
|
|
15
|
+
import { DropdownMobileList as P } from "../../Dropdown/mobile/DropdownMobileList.js";
|
|
16
|
+
import { DropdownMobileListItem as T } from "../../Dropdown/mobile/DropdownMobileListItem.js";
|
|
17
|
+
import { DropdownMobileLoader as q } from "../../Dropdown/mobile/DropdownMobileLoader.js";
|
|
18
|
+
import { s as z, S as A } from "../../../chunks/SuggestFieldMobileDropdownHint-Dz-VDDoR.js";
|
|
19
|
+
const E = ({
|
|
20
|
+
value: o,
|
|
21
|
+
options: c,
|
|
22
|
+
placeholder: f,
|
|
23
|
+
dropdownHint: l,
|
|
24
|
+
opened: g,
|
|
25
|
+
loading: h,
|
|
26
|
+
dropdownListLoading: a,
|
|
27
|
+
clearInputOnFocus: b,
|
|
28
|
+
setOpened: n,
|
|
29
|
+
onSelect: s,
|
|
30
|
+
onFilter: w,
|
|
31
|
+
onScrollEnd: d
|
|
32
|
+
}, D) => {
|
|
33
|
+
const [M, e] = H((o == null ? void 0 : o.label) || ""), F = p(null), u = p(null);
|
|
34
|
+
V(() => {
|
|
35
|
+
e((o == null ? void 0 : o.label) || "");
|
|
36
|
+
}, [o]);
|
|
37
|
+
const C = () => {
|
|
38
|
+
e(b === !1 && (o == null ? void 0 : o.label) || "");
|
|
39
|
+
}, I = (r) => {
|
|
40
|
+
const { value: i } = r.target;
|
|
41
|
+
e(i), w(i);
|
|
42
|
+
}, R = () => {
|
|
43
|
+
n(!1), s(o);
|
|
44
|
+
}, S = (r) => {
|
|
45
|
+
if (!d)
|
|
46
|
+
return;
|
|
47
|
+
const { clientHeight: i, scrollHeight: B, scrollTop: L } = r.target;
|
|
48
|
+
B - L === i && d();
|
|
49
|
+
};
|
|
50
|
+
return /* @__PURE__ */ t(
|
|
51
|
+
j,
|
|
52
|
+
{
|
|
53
|
+
setOpened: (r) => {
|
|
54
|
+
n(r), r || s(o);
|
|
55
|
+
},
|
|
56
|
+
opened: g,
|
|
57
|
+
targetRef: u,
|
|
58
|
+
ref: D,
|
|
59
|
+
mobileViewProps: {
|
|
60
|
+
children: /* @__PURE__ */ m(x, { children: [
|
|
61
|
+
/* @__PURE__ */ m(N, { closeButton: () => /* @__PURE__ */ t(_, { onClick: R }), children: [
|
|
62
|
+
/* @__PURE__ */ t(
|
|
63
|
+
O,
|
|
64
|
+
{
|
|
65
|
+
value: M,
|
|
66
|
+
placeholder: f,
|
|
67
|
+
autoFocus: !0,
|
|
68
|
+
onFocus: C,
|
|
69
|
+
onChange: I
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
h && /* @__PURE__ */ t(q, {})
|
|
73
|
+
] }),
|
|
74
|
+
/* @__PURE__ */ t(k, { className: z.suggestFieldMobileBody, onScroll: S, children: l ? /* @__PURE__ */ t(A, { children: l }) : /* @__PURE__ */ t(P, { loading: a, ref: F, children: c.map((r) => /* @__PURE__ */ t(
|
|
75
|
+
T,
|
|
76
|
+
{
|
|
77
|
+
id: r.id,
|
|
78
|
+
selected: r.id === (o == null ? void 0 : o.id),
|
|
79
|
+
onSelect: () => {
|
|
80
|
+
s(r), n(!1);
|
|
81
|
+
},
|
|
82
|
+
children: r.content || r.label
|
|
83
|
+
},
|
|
84
|
+
r.id
|
|
85
|
+
)) }) })
|
|
86
|
+
] })
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
);
|
|
90
|
+
}, mo = y.forwardRef(E);
|
|
91
|
+
export {
|
|
92
|
+
mo as SuggestFieldMobileDropdown
|
|
93
|
+
};
|
|
94
|
+
//# sourceMappingURL=SuggestFieldMobileDropdown.js.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import "../../Typography/Title.js";
|
|
3
|
+
import "../../Typography/Text.js";
|
|
4
|
+
import "../../Typography/Caption.js";
|
|
5
|
+
import "../../Typography/enums.js";
|
|
6
|
+
import { S as d } from "../../../chunks/SuggestFieldMobileDropdownHint-Dz-VDDoR.js";
|
|
7
|
+
export {
|
|
8
|
+
d as SuggestFieldMobileDropdownHint
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=SuggestFieldMobileDropdownHint.js.map
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { useCallback as s } from "react";
|
|
3
|
+
import { SuggestFieldTarget as e } from "../SuggestFieldTarget.js";
|
|
4
|
+
const c = ({
|
|
5
|
+
inputValue: o,
|
|
6
|
+
placeholder: l,
|
|
7
|
+
renderInput: t,
|
|
8
|
+
...n
|
|
9
|
+
}) => {
|
|
10
|
+
const u = s(
|
|
11
|
+
(a) => {
|
|
12
|
+
const i = t === void 0 ? e.Input : t;
|
|
13
|
+
return /* @__PURE__ */ r(i, { ...a, readOnly: !0 });
|
|
14
|
+
},
|
|
15
|
+
[t]
|
|
16
|
+
);
|
|
17
|
+
return /* @__PURE__ */ r(
|
|
18
|
+
e,
|
|
19
|
+
{
|
|
20
|
+
inputValue: o,
|
|
21
|
+
placeholder: l,
|
|
22
|
+
renderInput: u,
|
|
23
|
+
...n
|
|
24
|
+
}
|
|
25
|
+
);
|
|
26
|
+
};
|
|
27
|
+
export {
|
|
28
|
+
c as SuggestFieldMobileTarget
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=SuggestFieldMobileTarget.js.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { SuggestFieldMobile as r } from "./SuggestFieldMobile.js";
|
|
2
|
+
import { SuggestFieldMobileDropdown as g } from "./SuggestFieldMobileDropdown.js";
|
|
3
|
+
import { S as l } from "../../../chunks/SuggestFieldMobileDropdownHint-Dz-VDDoR.js";
|
|
4
|
+
import { SuggestFieldMobileTarget as p } from "./SuggestFieldMobileTarget.js";
|
|
5
|
+
export {
|
|
6
|
+
r as SuggestFieldMobile,
|
|
7
|
+
g as SuggestFieldMobileDropdown,
|
|
8
|
+
l as SuggestFieldMobileDropdownHint,
|
|
9
|
+
p as SuggestFieldMobileTarget
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { jsxs as j, jsx as
|
|
2
|
-
import z, { useState as
|
|
3
|
-
import { c as g } from "../../chunks/vendor-
|
|
4
|
-
const H = "
|
|
1
|
+
import { jsxs as j, jsx as _ } from "react/jsx-runtime";
|
|
2
|
+
import z, { useState as w, useRef as u, useEffect as M, useImperativeHandle as W } from "react";
|
|
3
|
+
import { c as g } from "../../chunks/vendor-CehxOAkM.js";
|
|
4
|
+
const H = "swipeableArea__a9ad1241", V = "content__77d1ab98", $ = "disableScroll__e934c8b8", k = "disablePointerEvents__4d7f67b0", q = "swipeAnimationFinish__b4f234b8", G = "leftContent__97131e93", J = "rightContent__c6cfb68e", s = {
|
|
5
5
|
swipeableArea: H,
|
|
6
6
|
content: V,
|
|
7
7
|
disableScroll: $,
|
|
@@ -9,9 +9,9 @@ const H = "swipeableArea__7ca9e38a", V = "content__ec0cec24", $ = "disableScroll
|
|
|
9
9
|
swipeAnimationFinish: q,
|
|
10
10
|
leftContent: G,
|
|
11
11
|
rightContent: J
|
|
12
|
-
}, p = 24,
|
|
12
|
+
}, p = 24, A = s.swipeAnimationFinish, K = s.disableScroll, Q = s.disablePointerEvents, N = { clientX: 0, clientY: 0 }, U = z.forwardRef(
|
|
13
13
|
({ children: L, className: I, leftSwipeableArea: m, rightSwipeableArea: C, ...y }, B) => {
|
|
14
|
-
const [S, a] =
|
|
14
|
+
const [S, a] = w(!1), [l, d] = w(), [o, e] = w(0), i = u(null), r = u(null), n = u(0), h = u(N), b = u(null), X = () => {
|
|
15
15
|
a(!0);
|
|
16
16
|
const t = n.current - o;
|
|
17
17
|
n.current === 0 ? t > 0 ? e(
|
|
@@ -23,14 +23,14 @@ const H = "swipeableArea__7ca9e38a", V = "content__ec0cec24", $ = "disableScroll
|
|
|
23
23
|
) : n.current < 0 && t < 0 && e(
|
|
24
24
|
Math.abs(t) > p ? 0 : -r.current.getBoundingClientRect().width
|
|
25
25
|
);
|
|
26
|
-
},
|
|
27
|
-
h.current = N, d(void 0), document.removeEventListener("touchend",
|
|
26
|
+
}, E = () => {
|
|
27
|
+
h.current = N, d(void 0), document.removeEventListener("touchend", E);
|
|
28
28
|
};
|
|
29
29
|
M(() => {
|
|
30
30
|
!l && o !== n.current && X();
|
|
31
31
|
}, [l]);
|
|
32
32
|
const x = (t) => {
|
|
33
|
-
h.current = { clientX: t.touches[0].clientX, clientY: t.touches[0].clientY }, n.current = o, document.addEventListener("touchend",
|
|
33
|
+
h.current = { clientX: t.touches[0].clientX, clientY: t.touches[0].clientY }, n.current = o, document.addEventListener("touchend", E);
|
|
34
34
|
}, O = (t) => {
|
|
35
35
|
if (t.touches.length != 1)
|
|
36
36
|
return;
|
|
@@ -56,11 +56,11 @@ const H = "swipeableArea__7ca9e38a", V = "content__ec0cec24", $ = "disableScroll
|
|
|
56
56
|
}, D = () => a(!1), P = () => r.current ? Math.abs(o) / r.current.getBoundingClientRect().width : 1, Y = () => i.current ? Math.abs(o) / i.current.getBoundingClientRect().width : 1;
|
|
57
57
|
M(() => {
|
|
58
58
|
const t = (c) => {
|
|
59
|
-
c.touches.length == 1 &&
|
|
59
|
+
c.touches.length == 1 && b.current && !b.current.contains(c.target) && (a(!0), e(0), d(void 0));
|
|
60
60
|
};
|
|
61
61
|
return document.addEventListener("touchstart", t), () => document.removeEventListener("touchstart", t);
|
|
62
62
|
}, []);
|
|
63
|
-
const
|
|
63
|
+
const R = () => {
|
|
64
64
|
i.current && (a(!0), e(i.current.getBoundingClientRect().width));
|
|
65
65
|
}, T = () => {
|
|
66
66
|
r.current && (a(!0), e(-r.current.getBoundingClientRect().width));
|
|
@@ -77,47 +77,47 @@ const H = "swipeableArea__7ca9e38a", V = "content__ec0cec24", $ = "disableScroll
|
|
|
77
77
|
T();
|
|
78
78
|
},
|
|
79
79
|
swipeRight: () => {
|
|
80
|
-
|
|
80
|
+
R();
|
|
81
81
|
}
|
|
82
82
|
}),
|
|
83
|
-
[v, T,
|
|
83
|
+
[v, T, R]
|
|
84
84
|
), /* @__PURE__ */ j(
|
|
85
85
|
"div",
|
|
86
86
|
{
|
|
87
87
|
className: g(s.swipeableArea, I),
|
|
88
88
|
...y,
|
|
89
|
-
"data-tx": "1.
|
|
90
|
-
ref:
|
|
89
|
+
"data-tx": "1.2.0",
|
|
90
|
+
ref: b,
|
|
91
91
|
children: [
|
|
92
|
-
typeof m < "u" ? /* @__PURE__ */
|
|
92
|
+
typeof m < "u" ? /* @__PURE__ */ _(
|
|
93
93
|
"div",
|
|
94
94
|
{
|
|
95
95
|
className: g(s.leftContent, {
|
|
96
|
-
[
|
|
96
|
+
[A]: S
|
|
97
97
|
}),
|
|
98
98
|
ref: i,
|
|
99
99
|
style: { opacity: Y() },
|
|
100
100
|
children: m
|
|
101
101
|
}
|
|
102
102
|
) : null,
|
|
103
|
-
typeof C < "u" ? /* @__PURE__ */
|
|
103
|
+
typeof C < "u" ? /* @__PURE__ */ _(
|
|
104
104
|
"div",
|
|
105
105
|
{
|
|
106
106
|
className: g(s.rightContent, {
|
|
107
|
-
[
|
|
107
|
+
[A]: S
|
|
108
108
|
}),
|
|
109
109
|
ref: r,
|
|
110
110
|
style: { opacity: P() },
|
|
111
111
|
children: C
|
|
112
112
|
}
|
|
113
113
|
) : null,
|
|
114
|
-
/* @__PURE__ */
|
|
114
|
+
/* @__PURE__ */ _(
|
|
115
115
|
"div",
|
|
116
116
|
{
|
|
117
117
|
className: g(s.content, {
|
|
118
118
|
[Q]: o !== 0,
|
|
119
119
|
[K]: l === "horizontal",
|
|
120
|
-
[
|
|
120
|
+
[A]: S
|
|
121
121
|
}),
|
|
122
122
|
onTouchStart: x,
|
|
123
123
|
onTouchMove: O,
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { c as r } from "../../chunks/vendor-CehxOAkM.js";
|
|
3
|
+
const s = "filterPanel__5caf2467", i = {
|
|
4
|
+
filterPanel: s
|
|
5
|
+
}, n = ({ children: e, className: l, ...t }) => /* @__PURE__ */ a(
|
|
6
|
+
"div",
|
|
7
|
+
{
|
|
8
|
+
className: r(i.filterPanel, l),
|
|
9
|
+
...t,
|
|
10
|
+
"data-tx": "1.2.0",
|
|
11
|
+
children: e
|
|
12
|
+
}
|
|
13
|
+
);
|
|
14
|
+
n.displayName = "FilterPanel";
|
|
15
|
+
export {
|
|
16
|
+
n as FilterPanel
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=FilterPanel.js.map
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { useState as i } from "react";
|
|
3
|
+
import { MasterTableContext as n } from "./MasterTableContext.js";
|
|
4
|
+
import { c as b } from "../../chunks/vendor-CehxOAkM.js";
|
|
5
|
+
import { NoColumns as p } from "./NoColumns.js";
|
|
6
|
+
import { FilterPanel as T } from "./FilterPanel.js";
|
|
7
|
+
import { TabsLinePanel as c } from "./TabsLinePanel.js";
|
|
8
|
+
import { TableBasic as f } from "./TableBasic/TableBasic.js";
|
|
9
|
+
import { TableBasicSettings as P } from "./TableBasicSettings/TableBasicSettings.js";
|
|
10
|
+
import { TableFooter as u } from "./TableFooter/TableFooter.js";
|
|
11
|
+
import { PaginationPanel as d } from "./PaginationPanel.js";
|
|
12
|
+
import "./TableBasicSettings/components/ColumnSettings.js";
|
|
13
|
+
import "./TableBasic/enums.js";
|
|
14
|
+
const x = "masterTable__486daaaa", g = {
|
|
15
|
+
masterTable: x
|
|
16
|
+
}, a = ({ children: t, className: o, loading: r = !1, ...m }) => {
|
|
17
|
+
const [s, l] = i([]);
|
|
18
|
+
return /* @__PURE__ */ e(
|
|
19
|
+
n.Provider,
|
|
20
|
+
{
|
|
21
|
+
value: {
|
|
22
|
+
columns: s,
|
|
23
|
+
loading: r,
|
|
24
|
+
setColumns: l
|
|
25
|
+
},
|
|
26
|
+
children: /* @__PURE__ */ e(
|
|
27
|
+
"div",
|
|
28
|
+
{
|
|
29
|
+
className: b(g.masterTable, o),
|
|
30
|
+
...m,
|
|
31
|
+
"data-tx": "1.2.0",
|
|
32
|
+
children: t
|
|
33
|
+
}
|
|
34
|
+
)
|
|
35
|
+
}
|
|
36
|
+
);
|
|
37
|
+
};
|
|
38
|
+
a.displayName = "MasterTable";
|
|
39
|
+
a.NoColumns = p;
|
|
40
|
+
a.FilterPanel = T;
|
|
41
|
+
a.TabsLinePanel = c;
|
|
42
|
+
a.TableBasic = f;
|
|
43
|
+
a.TableBasicSettings = P;
|
|
44
|
+
a.TableFooter = u;
|
|
45
|
+
a.PaginationPanel = d;
|
|
46
|
+
export {
|
|
47
|
+
a as MasterTable
|
|
48
|
+
};
|
|
49
|
+
//# sourceMappingURL=MasterTable.js.map
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsxs as m, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { c as e } from "../../chunks/vendor-CehxOAkM.js";
|
|
3
|
+
import { Gap as l } from "../Gap/Gap.js";
|
|
4
|
+
import { ServicesetupSysIcon128 as r } from "@sberbusiness/icons-next";
|
|
5
|
+
const i = "noColumns__d20c00c1", a = "content__765b8db2", s = {
|
|
6
|
+
noColumns: i,
|
|
7
|
+
content: a
|
|
8
|
+
}, p = ({ children: n, className: t, ...c }) => /* @__PURE__ */ m("div", { className: e(s.noColumns, t), ...c, children: [
|
|
9
|
+
/* @__PURE__ */ o(r, {}),
|
|
10
|
+
/* @__PURE__ */ o(l, { size: 24 }),
|
|
11
|
+
/* @__PURE__ */ o("div", { className: s.content, children: n })
|
|
12
|
+
] });
|
|
13
|
+
p.displayName = "NoColumns";
|
|
14
|
+
export {
|
|
15
|
+
p as NoColumns
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=NoColumns.js.map
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { c as o } from "../../chunks/vendor-CehxOAkM.js";
|
|
3
|
+
const s = "paginationPanel__341856ca", e = {
|
|
4
|
+
paginationPanel: s
|
|
5
|
+
}, l = ({ children: a, className: n, ...i }) => /* @__PURE__ */ t(
|
|
6
|
+
"div",
|
|
7
|
+
{
|
|
8
|
+
className: o(e.paginationPanel, n),
|
|
9
|
+
...i,
|
|
10
|
+
"data-tx": "1.2.0",
|
|
11
|
+
children: a
|
|
12
|
+
}
|
|
13
|
+
);
|
|
14
|
+
l.displayName = "PaginationPanel";
|
|
15
|
+
export {
|
|
16
|
+
l as PaginationPanel
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=PaginationPanel.js.map
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { jsxs as d, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { useContext as N, useEffect as g } from "react";
|
|
3
|
+
import { i as C } from "../../../chunks/vendor-CehxOAkM.js";
|
|
4
|
+
import { MasterTableContext as E } from "../MasterTableContext.js";
|
|
5
|
+
import { s as o } from "../../../chunks/utils-DPXynVs1.js";
|
|
6
|
+
import { TableBasicHeader as j } from "./components/TableBasicHeader.js";
|
|
7
|
+
import { TableBasicBody as D } from "./components/TableBasicBody.js";
|
|
8
|
+
import { LoaderMiddle as c } from "../../Loader/LoaderMiddle/LoaderMiddle.js";
|
|
9
|
+
const F = ({
|
|
10
|
+
columns: t,
|
|
11
|
+
data: i,
|
|
12
|
+
highlightRowOnHover: m,
|
|
13
|
+
onOrderBy: p,
|
|
14
|
+
onClickRow: f,
|
|
15
|
+
renderNoColumns: n,
|
|
16
|
+
renderNoData: b,
|
|
17
|
+
headless: v,
|
|
18
|
+
...u
|
|
19
|
+
}) => {
|
|
20
|
+
const a = N(E), y = i.length === 0;
|
|
21
|
+
g(() => {
|
|
22
|
+
C(t, a.columns) || a.setColumns(t);
|
|
23
|
+
}, [t, a]);
|
|
24
|
+
const h = () => t.every((e) => e.hidden) && n ? n() : /* @__PURE__ */ d("table", { ...u, children: [
|
|
25
|
+
v || /* @__PURE__ */ r(j, { columns: t, onOrderBy: p }),
|
|
26
|
+
/* @__PURE__ */ r(
|
|
27
|
+
D,
|
|
28
|
+
{
|
|
29
|
+
columns: t,
|
|
30
|
+
data: i,
|
|
31
|
+
onClickRow: f,
|
|
32
|
+
highlightRowOnHover: m
|
|
33
|
+
}
|
|
34
|
+
)
|
|
35
|
+
] }, "table"), x = (e) => {
|
|
36
|
+
const { loading: s } = a;
|
|
37
|
+
return s && e ? l(T()) : !s && e ? l(b()) : s && !e ? B(/* @__PURE__ */ r(c, {})) : null;
|
|
38
|
+
}, B = (e) => /* @__PURE__ */ r("div", { className: o.spinnerWrapper, children: e }), l = (e) => /* @__PURE__ */ r("div", { className: o.footerEmptyData, children: e }), T = () => [
|
|
39
|
+
/* @__PURE__ */ r("div", { className: o.overlayCover }, "overlay"),
|
|
40
|
+
/* @__PURE__ */ r(c, {}, "spinner")
|
|
41
|
+
];
|
|
42
|
+
return /* @__PURE__ */ d("div", { className: o.tableBasic, children: [
|
|
43
|
+
h(),
|
|
44
|
+
x(y)
|
|
45
|
+
] });
|
|
46
|
+
};
|
|
47
|
+
F.displayName = "TableBasic";
|
|
48
|
+
export {
|
|
49
|
+
F as TableBasic
|
|
50
|
+
};
|
|
51
|
+
//# sourceMappingURL=TableBasic.js.map
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { TableBasicRow as b } from "./TableBasicRow.js";
|
|
3
|
+
import { c as p } from "../../../../chunks/vendor-CehxOAkM.js";
|
|
4
|
+
import { s as r } from "../../../../chunks/utils-DPXynVs1.js";
|
|
5
|
+
const B = ({ columns: c, data: o, highlightRowOnHover: t, onClickRow: e }) => {
|
|
6
|
+
if (o.length === 0)
|
|
7
|
+
return null;
|
|
8
|
+
const s = !!e, n = s || !!t, i = p({
|
|
9
|
+
[r.clickable]: s,
|
|
10
|
+
[r.hoverable]: n
|
|
11
|
+
}), m = o.map((l) => /* @__PURE__ */ a(b, { columns: c, data: l, onClickRow: e }, l.rowKey));
|
|
12
|
+
return /* @__PURE__ */ a("tbody", { className: i, children: m });
|
|
13
|
+
};
|
|
14
|
+
B.displayName = "TableBasicBody";
|
|
15
|
+
export {
|
|
16
|
+
B as TableBasicBody
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=TableBasicBody.js.map
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { jsx as r, jsxs as h, Fragment as m } from "react/jsx-runtime";
|
|
2
|
+
import { SortdecreaseStrokeSrvIcon16 as x, SortincreaseStrokeSrvIcon16 as I, SortStrokeSrvIcon16 as D } from "@sberbusiness/icons-next";
|
|
3
|
+
import { isNullOrUndefined as p } from "../../../../utils/isNullOrUndefined.js";
|
|
4
|
+
import { getAriaHTMLAttributes as H } from "../../../../utils/html/AriaAttributes.js";
|
|
5
|
+
import { getDataHTMLAttributes as y } from "../../../../utils/html/DataAttributes.js";
|
|
6
|
+
import { ECellType as b, EHorizontalAlign as s, EOrderDirection as t } from "../enums.js";
|
|
7
|
+
import { c as T } from "../../../../chunks/vendor-CehxOAkM.js";
|
|
8
|
+
import { m as z, s as n } from "../../../../chunks/utils-DPXynVs1.js";
|
|
9
|
+
import { Text as B } from "../../../Typography/Text.js";
|
|
10
|
+
import { ETextSize as v } from "../../../Typography/enums.js";
|
|
11
|
+
const w = ({ columns: u, onOrderBy: l }) => {
|
|
12
|
+
const N = !p(l), f = (e) => {
|
|
13
|
+
let o;
|
|
14
|
+
switch (e.orderDirection) {
|
|
15
|
+
case t.NONE: {
|
|
16
|
+
o = /* @__PURE__ */ r(D, { paletteIndex: 0 });
|
|
17
|
+
break;
|
|
18
|
+
}
|
|
19
|
+
case t.ASC: {
|
|
20
|
+
o = /* @__PURE__ */ r(I, { paletteIndex: 0 });
|
|
21
|
+
break;
|
|
22
|
+
}
|
|
23
|
+
case t.DESC: {
|
|
24
|
+
o = /* @__PURE__ */ r(x, { paletteIndex: 0 });
|
|
25
|
+
break;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
const i = T(n.orderButton, {
|
|
29
|
+
[n.alignLeft]: e.horizontalAlign === s.RIGHT,
|
|
30
|
+
[n.alignRight]: e.horizontalAlign !== s.RIGHT,
|
|
31
|
+
[n.sorted]: e.orderDirection !== t.NONE
|
|
32
|
+
});
|
|
33
|
+
return /* @__PURE__ */ r("span", { className: i, children: o });
|
|
34
|
+
}, A = (e, o) => {
|
|
35
|
+
if (e.hidden)
|
|
36
|
+
return null;
|
|
37
|
+
const i = e.width ? { maxWidth: e.width, minWidth: e.width, width: e.width } : void 0, a = o && !p(e.orderDirection), E = a ? () => {
|
|
38
|
+
S(e.fieldKey, e.orderDirection);
|
|
39
|
+
} : void 0, d = a && f(e), C = z(e.horizontalAlign), O = T(n.thBlock, "hoverable", {
|
|
40
|
+
[n.checkboxType]: e.cellType === b.CHECKBOX,
|
|
41
|
+
[n.order]: a
|
|
42
|
+
}), c = [b.TEXT, void 0].includes(e.cellType) ? /* @__PURE__ */ r(B, { size: v.B3, children: e.label }) : e.label, g = e.horizontalAlign === s.RIGHT ? /* @__PURE__ */ h(m, { children: [
|
|
43
|
+
d,
|
|
44
|
+
c
|
|
45
|
+
] }) : /* @__PURE__ */ h(m, { children: [
|
|
46
|
+
c,
|
|
47
|
+
d
|
|
48
|
+
] });
|
|
49
|
+
return /* @__PURE__ */ r("th", { className: C, title: e.title, style: i, children: /* @__PURE__ */ r(
|
|
50
|
+
"span",
|
|
51
|
+
{
|
|
52
|
+
className: O,
|
|
53
|
+
onClick: E,
|
|
54
|
+
...!!e.ariaAttributes && H(e.ariaAttributes),
|
|
55
|
+
...!!e.dataAttributes && y(e.dataAttributes),
|
|
56
|
+
children: g
|
|
57
|
+
}
|
|
58
|
+
) }, e.fieldKey);
|
|
59
|
+
}, S = (e, o) => {
|
|
60
|
+
let i;
|
|
61
|
+
switch (o) {
|
|
62
|
+
case t.NONE: {
|
|
63
|
+
i = t.ASC;
|
|
64
|
+
break;
|
|
65
|
+
}
|
|
66
|
+
case t.ASC: {
|
|
67
|
+
i = t.DESC;
|
|
68
|
+
break;
|
|
69
|
+
}
|
|
70
|
+
case t.DESC: {
|
|
71
|
+
i = t.NONE;
|
|
72
|
+
break;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
l && l({ direction: i, fieldKey: e });
|
|
76
|
+
}, k = u.map((e) => A(e, N));
|
|
77
|
+
return /* @__PURE__ */ r("thead", { children: /* @__PURE__ */ r("tr", { children: k }) });
|
|
78
|
+
};
|
|
79
|
+
w.displayName = "TableBasicHeader";
|
|
80
|
+
export {
|
|
81
|
+
w as TableBasicHeader
|
|
82
|
+
};
|
|
83
|
+
//# sourceMappingURL=TableBasicHeader.js.map
|