@sberbusiness/triplex-next 1.4.0 → 1.5.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/chunks/{AlertProcessSpoiler-BQv9QI6L.js → AlertProcessSpoiler-M7W9D-p3.js} +6 -6
- package/chunks/CalendarViewItem-Cs4qo2T0.js +105 -0
- package/chunks/Card.module-lZl8x0iL.js +17 -0
- package/chunks/{Chip-G6cGXuGj.js → Chip-DpSJGyYK.js} +10 -10
- package/chunks/{DropdownListItem-D2hzyBGc.js → DropdownListItem-SqymKZn5.js} +10 -10
- package/chunks/DropdownMobile.module-C_Jtpfxj.js +21 -0
- package/chunks/Footer.module-3tcvZGt3.js +9 -0
- package/chunks/{FormFieldInput-CO7yZP0Q.js → FormFieldInput-BSxKZxcq.js} +11 -11
- package/chunks/HeaderLayoutSidebar.module-DqrwTmWo.js +9 -0
- package/chunks/HeaderTabs.module-DegB0R8X.js +9 -0
- package/chunks/{HeaderTitle.module-BHyH17ZI.js → HeaderTitle.module-CEMLCR13.js} +2 -2
- package/chunks/IslandAccordion.module-DFvQwhSg.js +22 -0
- package/chunks/{LightBoxContent-DmoszkOx.js → LightBoxContent-DTTxRVLQ.js} +16 -16
- package/chunks/LightBoxControls.module-Dn4GtUtF.js +16 -0
- package/chunks/LightBoxSideOverlayClose.module-BUvFYJwr.js +8 -0
- package/chunks/{ListItemControlsButton-BoEiexyr.js → ListItemControlsButton-AbCEipFe.js} +10 -10
- package/chunks/ListItemTail.module-CZYSMJRz.js +12 -0
- package/chunks/ListMasterFooter.module-Bw6BVPVj.js +10 -0
- package/chunks/ModalWindow.module-DGcF8-xJ.js +17 -0
- package/chunks/Notification.module-Cj_Pd4DQ.js +21 -0
- package/chunks/Overlay.module-BqJXvoeX.js +18 -0
- package/chunks/Page.module-DUQ6i8Ez.js +12 -0
- package/chunks/{RightBorderArrow-BHW7rkmN.js → RightBorderArrow-Co_RT8lZ.js} +12 -12
- package/chunks/SMSInput.module-D1TiDw_A.js +16 -0
- package/chunks/StatusTracker.module-DetC6Udk.js +24 -0
- package/chunks/{SuggestFieldMobileDropdownHint-CMKMF0PQ.js → SuggestFieldMobileDropdownHint-nZwpz9Eo.js} +2 -2
- package/chunks/TableFooter.module-BF4P3QCw.js +13 -0
- package/chunks/TabsExtended.module-BciQYRi4.js +16 -0
- package/chunks/TabsLine.module-Cx0n_AdV.js +23 -0
- package/chunks/TooltipDesktop.module-DK06gaHe.js +19 -0
- package/chunks/TooltipMobileCloseButton-DTtQoE3B.js +20 -0
- package/chunks/{UploadZoneInput-pdhICY56.js → UploadZoneInput-C2-_7DoS.js} +3 -3
- package/chunks/{utils-B7AjUpy-.js → utils-CFlJg-k1.js} +5 -5
- package/chunks/{utils-DwX2_kEA.js → utils-CXhKCNyM.js} +14 -14
- package/chunks/utils-CoHHiBA8.js +24 -0
- package/chunks/utils-D9w2Kvyk.js +36 -0
- package/chunks/{utils-C9-tOm2Z.js → utils-Dhi5F6Da.js} +9 -9
- package/chunks/vendor-9KVE23Ri.js +14839 -0
- package/components/AbstractTree/AbstractTreeNode.js +1 -1
- package/components/AccordionBase/protected/AccordionBase.js +1 -1
- package/components/Alert/AlertContext/AlertContext.js +16 -16
- package/components/Alert/AlertProcess/AlertProcess.js +3 -3
- package/components/Alert/AlertProcess/components/AlertProcessSpoiler.js +2 -2
- package/components/Amount/Amount.js +8 -8
- package/components/AmountField/AmountField.js +2 -2
- package/components/Body/Body.js +3 -3
- package/components/Button/Button.js +18 -18
- package/components/Button/ButtonBase.js +1 -1
- package/components/Button/ButtonDropdown.js +54 -54
- package/components/Button/ButtonDropdownExtended.js +9 -9
- package/components/Button/ButtonIcon.js +13 -13
- package/components/Calendar/Calendar.js +183 -0
- package/components/Calendar/CalendarContext.js +22 -0
- package/components/Calendar/CalendarRange.js +28 -0
- package/components/Calendar/CalendarViewContext.js +8 -0
- package/components/Calendar/components/CalendarControls.js +98 -0
- package/components/Calendar/components/CalendarFooter.js +9 -0
- package/components/Calendar/components/CalendarTodayButton.js +31 -0
- package/components/Calendar/components/CalendarView.js +30 -0
- package/components/Calendar/components/CalendarViewDays.js +109 -0
- package/components/Calendar/components/CalendarViewItem.js +11 -0
- package/components/Calendar/components/CalendarViewMonths.js +64 -0
- package/components/Calendar/components/CalendarViewYears.js +64 -0
- package/components/Calendar/enums.js +7 -0
- package/components/Calendar/index.js +9 -0
- package/components/Calendar/types.js +2 -0
- package/components/Calendar/utils.js +38 -0
- package/components/Card/CardAction.js +14 -14
- 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 +7 -7
- package/components/Checkbox/Checkbox.js +12 -12
- package/components/Checkbox/CheckboxXGroup.js +12 -12
- package/components/Checkbox/CheckboxYGroup.js +2 -2
- package/components/CheckboxTreeExtended/CheckboxTreeExtended.js +1 -1
- package/components/CheckboxTreeExtended/components/CheckboxTreeExtendedCheckbox.js +1 -1
- package/components/CheckboxTreeExtended/components/CheckboxTreeExtendedNode.js +2 -2
- package/components/Chip/Chip.js +2 -2
- package/components/Chip/ChipClearButton.js +7 -7
- package/components/Chip/ChipDropdownArrow.js +4 -4
- package/components/Chip/ChipIcon.js +1 -1
- package/components/Chip/ChipOptions.js +7 -7
- package/components/Chip/ChipSelect.js +2 -2
- package/components/Chip/ChipSort.js +55 -0
- package/components/Chip/ChipSuggest/ChipSuggest.js +2 -2
- package/components/Chip/ChipSuggest/ChipSuggestDropdown.js +1 -1
- package/components/Chip/ChipSuggest/ChipSuggestTarget.js +1 -1
- package/components/Chip/ChipSuggest/desktop/ChipSuggestDesktopDropdownField.js +18 -18
- package/components/Chip/index.js +7 -5
- package/components/ChipGroup/ChipGroup.js +14 -14
- package/components/Col/Col.js +142 -142
- package/components/CollapsableTree/components/CollapsableTreeNode.js +6 -6
- package/components/DateField/DateField.js +135 -0
- package/components/DateField/DateFieldContext.js +12 -0
- package/components/DateField/DateFieldTarget.js +60 -0
- package/components/DateField/constants.js +5 -0
- package/components/DateField/index.js +5 -0
- package/components/DateField/types.js +2 -0
- package/components/DateField/utils.js +23 -0
- package/components/DatePickerExtended/DatePickerExtended.js +136 -0
- package/components/DatePickerExtended/DatePickerExtendedContext.js +11 -0
- package/components/DatePickerExtended/DatePickerExtendedDropdown.js +63 -0
- package/components/DesignTokens/DesignTokenUtils.js +2 -2
- package/components/DesignTokens/DesignTokensComponents.js +77 -70
- package/components/DesignTokens/DesignTokensComponentsThemeDark.js +71 -64
- package/components/DesignTokens/DesignTokensCore.js +1 -1
- package/components/DesignTokens/components/Calendar.js +109 -0
- package/components/DesignTokens/components/Divider.js +4 -4
- package/components/DesignTokens/components/ModalWindow.js +11 -0
- package/components/DesignTokens/components/index.js +132 -126
- package/components/Divider/Divider.js +21 -21
- package/components/Dropdown/desktop/DropdownDesktop.js +17 -17
- package/components/Dropdown/desktop/DropdownList.js +2 -2
- package/components/Dropdown/desktop/DropdownListItem.js +2 -2
- package/components/Dropdown/desktop/index.js +1 -1
- package/components/Dropdown/index.js +1 -1
- 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 +2 -2
- package/components/Dropdown/mobile/DropdownMobileList.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileListItem.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileLoader.js +2 -2
- package/components/Dropdown/mobile/DropdownMobileMaskedInput.js +11 -0
- package/components/Ellipsis/Ellipsis.js +8 -8
- package/components/ExpandAnimation/ExpandAnimation.js +21 -21
- package/components/Footer/Footer.js +1 -1
- 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 +21 -21
- package/components/FormField/components/FormFieldClear.js +12 -16
- package/components/FormField/components/FormFieldCounter.js +5 -5
- package/components/FormField/components/FormFieldDescription.js +6 -6
- package/components/FormField/components/FormFieldInput.js +2 -2
- package/components/FormField/components/FormFieldLabel.js +10 -10
- package/components/FormField/components/FormFieldMaskedInput.js +25 -29
- package/components/FormField/components/FormFieldPostfix.js +6 -6
- package/components/FormField/components/FormFieldPrefix.js +5 -5
- package/components/FormField/components/FormFieldTarget.js +17 -17
- package/components/FormField/components/FormFieldTextarea.js +9 -9
- package/components/FormField/index.js +1 -1
- package/components/Header/Header.js +1 -1
- 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 +9 -9
- package/components/Island/Island.js +2 -2
- package/components/Island/components/IslandBody.js +4 -4
- package/components/Island/components/IslandFooter.js +6 -6
- package/components/Island/components/IslandHeader.js +4 -4
- package/components/Island/utils.js +1 -1
- package/components/IslandAccordion/IslandAccordion.js +3 -3
- package/components/IslandAccordion/components/IslandAccordionContent.js +1 -1
- package/components/IslandAccordion/components/IslandAccordionFooter.js +2 -2
- package/components/IslandAccordion/components/IslandAccordionItem.js +3 -3
- package/components/LightBox/LightBox.js +16 -16
- package/components/LightBox/LightBoxContent.js +2 -2
- package/components/LightBox/LightBoxControls/LightBoxClose.js +2 -2
- package/components/LightBox/LightBoxControls/LightBoxControls.js +2 -2
- package/components/LightBox/LightBoxControls/LightBoxNext.js +2 -2
- package/components/LightBox/LightBoxControls/LightBoxPrev.js +2 -2
- package/components/LightBox/LightBoxSideOverlay/LightBoxSideOverlay.js +2 -2
- package/components/LightBox/LightBoxSideOverlay/LightBoxSideOverlayCloseDesktop.js +2 -2
- package/components/LightBox/LightBoxSideOverlay/LightBoxSideOverlayCloseMobile.js +2 -2
- package/components/LightBox/LightBoxSideOverlay/LightBoxSideOverlayLoader.js +1 -1
- package/components/LightBox/LightBoxTopOverlay/LightBoxTopOverlay.js +15 -15
- package/components/LightBox/LightBoxViewManager/LightBoxViewManager.js +1 -1
- package/components/Link/Link.js +20 -20
- package/components/List/List.js +7 -7
- package/components/List/ListSortable.js +1 -1
- package/components/List/components/ListEmptyState.js +2 -2
- package/components/List/components/ListItem.js +1 -1
- package/components/List/components/ListItemContent.js +7 -7
- package/components/List/components/ListItemControls.js +6 -6
- package/components/List/components/ListItemControlsButton.js +2 -2
- package/components/List/components/ListItemControlsButtonDropdown.js +2 -2
- package/components/List/components/ListItemLoading.js +5 -5
- package/components/List/components/ListItemSelectable.js +10 -10
- package/components/List/components/ListItemTable.js +7 -7
- package/components/List/components/ListItemTailLeft.js +2 -2
- package/components/List/components/ListItemTailRight.js +2 -2
- package/components/List/components/ListSortableItem.js +10 -10
- package/components/List/components/ListSortableItemControls.js +7 -7
- package/components/List/components/ListSortableItemTarget.js +6 -6
- 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 +10 -10
- package/components/Loader/LoaderSmall/LoaderSmall.js +6 -6
- package/components/LoaderScreen/LoaderScreen.js +13 -13
- package/components/Marker/Marker.js +2 -2
- package/components/Marker/utils.js +1 -1
- package/components/MarkerStatus/MarkerStatus.js +12 -12
- package/components/ModalWindow/ModalWindow.js +98 -0
- package/components/ModalWindow/components/ModalWindowBody.js +189 -0
- package/components/ModalWindow/components/ModalWindowClose.js +29 -0
- package/components/ModalWindow/components/ModalWindowContent.js +13 -0
- package/components/ModalWindow/components/ModalWindowFooter.js +10 -0
- package/components/ModalWindow/components/ModalWindowHeader.js +13 -0
- package/components/ModalWindow/components/ModalWindowViewManager.js +45 -0
- package/components/ModalWindow/index.js +17 -0
- package/components/MonthYearField/MonthYearField.js +66 -0
- package/components/MonthYearField/MonthYearFieldContext.js +9 -0
- package/components/MonthYearField/MonthYearFieldTarget.js +59 -0
- package/components/MonthYearField/constants.js +5 -0
- package/components/MonthYearField/index.js +5 -0
- package/components/MonthYearField/types.js +2 -0
- package/components/MonthYearField/utils.js +22 -0
- package/components/Notification/Notification.js +3 -3
- package/components/Notification/NotificationGrouped.js +1 -1
- package/components/Notification/components/NotificationBody.js +1 -1
- package/components/Notification/components/NotificationBodyContent.js +1 -1
- package/components/Notification/components/NotificationBodyList.js +2 -2
- package/components/Notification/components/NotificationClose.js +1 -1
- package/components/Notification/components/NotificationFooter.js +1 -1
- package/components/Notification/components/NotificationGroupedFooter.js +2 -2
- package/components/Notification/components/NotificationHeader.js +1 -1
- package/components/Notification/components/NotificationIcon.js +1 -1
- package/components/Notification/components/NotificationTime.js +1 -1
- package/components/NumberField/NumberFieldInput.js +1 -1
- package/components/OrderedList/OrderedList.js +5 -5
- package/components/OrderedList/OrderedListItem.js +8 -8
- 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 +2 -2
- package/components/Page/components/HeaderPage.js +2 -2
- package/components/Page/components/useStickyCornerRadius.js +1 -1
- package/components/Pagination/components/PaginationExtended.js +7 -7
- package/components/Pagination/components/PaginationNavigationButton.js +7 -7
- package/components/Pagination/components/PaginationNavigationExtended.js +2 -2
- package/components/Pagination/components/PaginationPageButton.js +6 -6
- package/components/Pagination/components/PaginationPageEllipsis.js +3 -3
- package/components/Pagination/components/PaginationSelect.js +8 -8
- package/components/Pagination/utils/paginationUtils.js +1 -1
- package/components/Radio/Radio.js +9 -9
- package/components/Radio/RadioXGroup.js +12 -12
- package/components/Radio/RadioYGroup.js +9 -9
- package/components/Row/Row.js +6 -6
- package/components/SMSInput/SMSInput.js +3 -3
- package/components/SMSInput/components/RefreshIcon.js +2 -2
- package/components/SMSInput/components/SMSInputInput.js +3 -3
- package/components/SMSInput/components/SMSInputRefresh.js +2 -2
- package/components/SMSInput/components/SMSInputSubmit.js +2 -2
- package/components/SMSInput/components/SMSInputTooltip.js +1 -1
- package/components/SegmentedControl/SegmentedControl.js +5 -5
- package/components/SegmentedControl/SegmentedControlSegment.js +8 -8
- package/components/SelectExtendedField/SelectExtendedField.js +11 -11
- package/components/SelectExtendedField/components/SelectExtendedFieldDropdown.js +1 -1
- package/components/SelectExtendedField/components/SelectExtendedFieldTarget.js +19 -19
- package/components/SelectField/SelectField.js +1 -1
- package/components/Skeleton/Skeleton.js +9 -9
- package/components/Spoiler/Spoiler.js +16 -16
- package/components/StatusTracker/StatusTracker.js +3 -3
- package/components/StatusTracker/components/StatusTrackerAlert.js +2 -2
- package/components/StatusTracker/components/StatusTrackerBody.js +2 -2
- package/components/StatusTracker/components/StatusTrackerButton.js +2 -2
- package/components/StatusTracker/components/StatusTrackerDescription.js +2 -2
- package/components/StatusTracker/components/StatusTrackerFooter.js +2 -2
- package/components/StatusTracker/components/StatusTrackerHeader.js +2 -2
- package/components/StatusTracker/components/StatusTrackerMedia.js +2 -2
- package/components/StatusTracker/components/StatusTrackerStatus.js +2 -2
- package/components/StatusTracker/components/StatusTrackerSum.js +2 -2
- package/components/StatusTracker/components/StatusTrackerTitle.js +2 -2
- package/components/Step/Step.js +7 -7
- package/components/Stepper/RightBorderArrow.js +1 -1
- package/components/Stepper/Stepper.js +56 -56
- package/components/Stepper/StepperExtended.js +2 -2
- package/components/Stepper/StepperStep.js +3 -3
- package/components/Stepper/StepperWrapper.js +3 -3
- package/components/Suggest/SuggestMobileDropdownContent.js +13 -13
- package/components/SuggestField/SuggestField.js +1 -1
- package/components/SuggestField/SuggestFieldTarget.js +1 -1
- package/components/SuggestField/SuggestFieldTargetPostfix.js +1 -1
- package/components/SuggestField/desktop/SuggestFieldDesktop.js +16 -16
- package/components/SuggestField/desktop/SuggestFieldDesktopDropdown.js +1 -1
- package/components/SuggestField/index.js +1 -1
- package/components/SuggestField/mobile/SuggestFieldMobile.js +2 -2
- package/components/SuggestField/mobile/SuggestFieldMobileDropdown.js +2 -2
- package/components/SuggestField/mobile/SuggestFieldMobileDropdownHint.js +1 -1
- package/components/SuggestField/mobile/index.js +1 -1
- package/components/SwipeableArea/SwipeableArea.js +20 -20
- package/components/Table/FilterPanel.js +3 -3
- package/components/Table/MasterTable.js +7 -7
- package/components/Table/NoColumns.js +6 -6
- package/components/Table/PaginationPanel.js +5 -5
- package/components/Table/TableBasic/TableBasic.js +2 -2
- package/components/Table/TableBasic/components/TableBasicBody.js +2 -2
- package/components/Table/TableBasic/components/TableBasicHeader.js +2 -2
- package/components/Table/TableBasic/components/TableBasicRow.js +2 -2
- package/components/Table/TableBasicSettings/TableBasicSettings.js +8 -8
- package/components/Table/TableBasicSettings/components/ColumnSettingsSortableListItemTarget.js +10 -10
- package/components/Table/TableBasicSettings/components/ColumnSettingsStaticListItem.js +2 -2
- package/components/Table/TableBasicSettings/components/TableBasicSettingsBody.js +7 -7
- package/components/Table/TableBasicSettings/components/TableBasicSettingsFooter.js +2 -2
- package/components/Table/TableBasicSettings/components/TableBasicSettingsHeader.js +2 -2
- package/components/Table/TableFooter/TableFooter.js +2 -2
- package/components/Table/TableFooter/components/TableFooterSummary.js +1 -1
- package/components/Table/TableFooter/components/TableFooterSummaryAmount.js +1 -1
- package/components/Table/TableFooter/components/TableFooterSummarySelectAllButton.js +1 -1
- package/components/Table/TableFooter/components/TableFooterSummarySelectedCount.js +1 -1
- package/components/Table/TabsLinePanel.js +2 -2
- package/components/Table/TabsLinePanelLinks.js +2 -2
- package/components/Table/utils.js +1 -1
- package/components/Tabs/Tabs.js +6 -6
- package/components/TabsExtended/TabsExtended.js +3 -3
- package/components/TabsExtended/components/TabsExtendedContent.js +2 -2
- package/components/TabsExtended/components/TabsExtendedDropdownWrapper.js +2 -2
- package/components/TabsExtended/components/TabsExtendedTab.js +2 -2
- package/components/TabsExtended/components/TabsExtendedTabButton.js +2 -2
- package/components/TabsExtended/components/TabsExtendedTabsWrapper.js +2 -2
- package/components/TabsExtended/utils.js +1 -1
- package/components/TabsLine/TabsLine.js +2 -2
- package/components/TabsLine/components/TabsLineDesktop.js +2 -2
- package/components/TabsLine/components/TabsLineDropdown.js +3 -3
- package/components/TabsLine/components/TabsLineItem.js +2 -2
- package/components/TabsLine/components/TabsLineMobile.js +9 -9
- package/components/Tag/Tag.js +18 -18
- package/components/TagGroup/TagGroup.js +10 -10
- package/components/TextField/TextField.js +1 -1
- package/components/TextareaField/TextareaField.js +1 -1
- package/components/ThemeProvider/ThemeProvider.js +4 -4
- package/components/ThemeProvider/components/ThemeProviderView.js +3 -3
- package/components/Tooltip/components/common/TooltipBody.js +2 -2
- package/components/Tooltip/components/common/TooltipLink.js +19 -19
- 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 +28 -32
- package/components/Tooltip/components/mobile/components/TooltipMobileCloseButton.js +6 -11
- package/components/Tooltip/components/mobile/components/TooltipMobileHeader.js +4 -4
- package/components/TreeView/TreeView.js +1 -1
- package/components/TreeView/components/TreeViewNode.js +1 -1
- package/components/Typography/Caption.js +13 -13
- package/components/Typography/Text.js +26 -26
- package/components/Typography/Title.js +17 -17
- package/components/Typography/utils.js +1 -1
- package/components/UnorderedList/UnorderedList.js +6 -6
- package/components/UnorderedList/UnorderedListItem.js +7 -7
- package/components/UploadZone/UploadZone.js +3 -3
- package/components/UploadZone/components/UploadZoneInput.js +2 -2
- package/components/WindowResizeListener/WindowResizeListener.js +1 -1
- package/components/index.js +423 -413
- package/consts/DateConst.js +14 -0
- package/index.d.ts +284 -4
- package/index.js +432 -422
- package/package.json +18 -1
- package/styles/triplex-next.css +501 -472
- package/types/DateTypes.js +2 -0
- package/utils/amountUtils.js +1 -1
- package/chunks/Card.module-kTbr6OQy.js +0 -17
- package/chunks/DropdownMobile.module-Fa_t6vz1.js +0 -21
- package/chunks/Footer.module-B3uFxh54.js +0 -9
- package/chunks/HeaderLayoutSidebar.module-CGCy_cim.js +0 -9
- package/chunks/HeaderTabs.module-DMuNfILv.js +0 -9
- package/chunks/IslandAccordion.module-7xAwgJVI.js +0 -22
- package/chunks/LightBoxControls.module-42gn-co3.js +0 -16
- package/chunks/LightBoxSideOverlayClose.module-B_oIB3rc.js +0 -8
- package/chunks/ListItemTail.module-BB5TJPEc.js +0 -12
- package/chunks/ListMasterFooter.module-DxZ_nXDV.js +0 -10
- package/chunks/Notification.module-C-HCMpAz.js +0 -21
- package/chunks/Overlay.module-q-oPhooa.js +0 -18
- package/chunks/Page.module-DjGbJ-Uw.js +0 -12
- package/chunks/SMSInput.module-Ci4GRnk_.js +0 -16
- package/chunks/StatusTracker.module-zTyojoH4.js +0 -24
- package/chunks/TableFooter.module-DrRycaTr.js +0 -13
- package/chunks/TabsExtended.module-Be8qpZYz.js +0 -16
- package/chunks/TabsLine.module-DKAp48Sx.js +0 -23
- package/chunks/TooltipDesktop.module-D72ObNia.js +0 -19
- package/chunks/utils-C-1ATq_g.js +0 -24
- package/chunks/utils-C8a4iCV0.js +0 -36
- package/chunks/vendor-Ba_pyhza.js +0 -12036
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
var F = Object.defineProperty;
|
|
2
|
+
var M = (l, d, e) => d in l ? F(l, d, { enumerable: !0, configurable: !0, writable: !0, value: e }) : l[d] = e;
|
|
3
|
+
var p = (l, d, e) => M(l, typeof d != "symbol" ? d + "" : d, e);
|
|
4
|
+
import { jsx as f, jsxs as b } from "react/jsx-runtime";
|
|
5
|
+
import { a as H, h as u, c as I } from "../../chunks/vendor-9KVE23Ri.js";
|
|
6
|
+
import V from "react";
|
|
7
|
+
import { globalLimitRange as _, dateFormatYYYYMMDD as O } from "../../consts/DateConst.js";
|
|
8
|
+
import { ECalendarPickType as g, ECalendarViewMode as h } from "./enums.js";
|
|
9
|
+
import { CalendarContext as C } from "./CalendarContext.js";
|
|
10
|
+
import { CalendarControls as x } from "./components/CalendarControls.js";
|
|
11
|
+
import { CalendarView as N } from "./components/CalendarView.js";
|
|
12
|
+
import { CalendarFooter as E } from "./components/CalendarFooter.js";
|
|
13
|
+
import { CalendarTodayButton as j } from "./components/CalendarTodayButton.js";
|
|
14
|
+
import { CalendarRange as q } from "./CalendarRange.js";
|
|
15
|
+
import { parsePickedDate as r, formatDate as k, getHeader as L } from "./utils.js";
|
|
16
|
+
const U = "calendar__7d4a02e3", $ = "adaptive__0f17d18d", R = {
|
|
17
|
+
calendar: U,
|
|
18
|
+
adaptive: $
|
|
19
|
+
};
|
|
20
|
+
class v extends V.PureComponent {
|
|
21
|
+
constructor(e) {
|
|
22
|
+
super(e);
|
|
23
|
+
// Уникальный идентификатор для связи периода с таблицей.
|
|
24
|
+
p(this, "periodId", `calendar-period-${H()}`);
|
|
25
|
+
/** Обработчик выбора даты. */
|
|
26
|
+
p(this, "handleDateSelect", (e) => {
|
|
27
|
+
if (this.props.isRange) {
|
|
28
|
+
let t;
|
|
29
|
+
if (this.props.pickedDate[0] && !this.props.pickedDate[1]) {
|
|
30
|
+
const a = r(this.props.pickedDate[0], this.props.format);
|
|
31
|
+
t = e.isBefore(a) ? [e, a] : [a, e];
|
|
32
|
+
} else
|
|
33
|
+
t = [e, null];
|
|
34
|
+
this.props.onDateChange(t);
|
|
35
|
+
} else
|
|
36
|
+
this.props.onDateChange(e);
|
|
37
|
+
});
|
|
38
|
+
/** Обработчик смены страницы. */
|
|
39
|
+
p(this, "handlePageChange", (e, t) => {
|
|
40
|
+
const { onPageChange: a } = this.props;
|
|
41
|
+
this.setState({
|
|
42
|
+
header: k(e, t),
|
|
43
|
+
viewDate: e
|
|
44
|
+
}), a == null || a(e, t);
|
|
45
|
+
});
|
|
46
|
+
/** Обработчик изменения вида отображения. */
|
|
47
|
+
p(this, "handleViewChange", (e, t) => {
|
|
48
|
+
const { onViewChange: a } = this.props;
|
|
49
|
+
this.setState({
|
|
50
|
+
header: k(e, t),
|
|
51
|
+
viewDate: e,
|
|
52
|
+
viewMode: t
|
|
53
|
+
}), a == null || a(e, t);
|
|
54
|
+
});
|
|
55
|
+
/** Рендер футера. */
|
|
56
|
+
p(this, "renderFooter", () => {
|
|
57
|
+
const { pickType: e, todayButtonProps: t } = this.props, { viewDate: a, viewMode: i } = this.state;
|
|
58
|
+
let o, s;
|
|
59
|
+
return e === g.datePick ? (o = u().startOf("day"), s = i === h.DAYS && a.isSame(o, "month")) : (o = u().startOf("month"), s = i === h.MONTHS && a.isSame(o, "year")), /* @__PURE__ */ f(E, { children: /* @__PURE__ */ f(
|
|
60
|
+
j,
|
|
61
|
+
{
|
|
62
|
+
todayDate: o,
|
|
63
|
+
currentPeriodSelected: s,
|
|
64
|
+
...typeof t == "function" ? t({ viewMode: i, currentPeriodSelected: s }) : t
|
|
65
|
+
}
|
|
66
|
+
) });
|
|
67
|
+
});
|
|
68
|
+
const { format: t, pickType: a, reversedPick: i } = this.props, o = this.props.isRange ? r(this.props.defaultDate, t) : r(this.props.pickedDate, t), s = this.getInitialViewDate(o);
|
|
69
|
+
let n;
|
|
70
|
+
i ? n = h.YEARS : a == g.monthYearPick ? n = h.MONTHS : n = h.DAYS;
|
|
71
|
+
const c = k(s, n);
|
|
72
|
+
this.state = {
|
|
73
|
+
header: c,
|
|
74
|
+
pickedDate: o,
|
|
75
|
+
viewDate: s,
|
|
76
|
+
viewMode: n
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
/** Получить изначальную дату для навигации. */
|
|
80
|
+
getInitialViewDate(e) {
|
|
81
|
+
const { defaultViewDate: t, format: a, limitRange: i } = this.props;
|
|
82
|
+
if (e && e.isValid())
|
|
83
|
+
return e.clone();
|
|
84
|
+
if (t) {
|
|
85
|
+
const s = r(t, a);
|
|
86
|
+
if (s && s.isValid())
|
|
87
|
+
return s.clone();
|
|
88
|
+
}
|
|
89
|
+
const o = u().startOf("day");
|
|
90
|
+
if (i) {
|
|
91
|
+
if (i.dateFrom && o.isBefore(i.dateFrom))
|
|
92
|
+
return i.dateFrom.clone();
|
|
93
|
+
if (i.dateTo && o.isAfter(i.dateTo))
|
|
94
|
+
return i.dateTo.clone();
|
|
95
|
+
}
|
|
96
|
+
return o;
|
|
97
|
+
}
|
|
98
|
+
componentDidUpdate(e, t) {
|
|
99
|
+
const { format: a } = this.props, { viewDate: i } = this.state, { viewDate: o } = t, s = this.props.isRange ? r(this.state.viewDate, a) : r(this.props.pickedDate, a), n = s == null ? void 0 : s.isValid(), c = n ? s : o, m = e.isRange ? r(t.viewDate, a) : r(e.pickedDate, a);
|
|
100
|
+
if (!(!n || m != null && m.isSame(c, "day"))) {
|
|
101
|
+
let D = {};
|
|
102
|
+
i && !i.isSame(s, "month") && (D = {
|
|
103
|
+
currentTab: h.DAYS,
|
|
104
|
+
header: L(c),
|
|
105
|
+
viewDate: c.clone()
|
|
106
|
+
}), this.setState({
|
|
107
|
+
...D,
|
|
108
|
+
pickedDate: s
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
render() {
|
|
113
|
+
const {
|
|
114
|
+
format: e,
|
|
115
|
+
pickType: t,
|
|
116
|
+
limitRange: a,
|
|
117
|
+
markedDays: i,
|
|
118
|
+
disabledDays: o,
|
|
119
|
+
dayHtmlAttributes: s,
|
|
120
|
+
monthHtmlAttributes: n,
|
|
121
|
+
yearHtmlAttributes: c,
|
|
122
|
+
prevButtonProps: m,
|
|
123
|
+
nextButtonProps: D,
|
|
124
|
+
viewButtonProps: P,
|
|
125
|
+
todayButtonProps: S
|
|
126
|
+
} = this.props, { viewMode: T, viewDate: Y, header: A } = this.state, B = I(R.calendar, {
|
|
127
|
+
[R.adaptive]: !this.props.isRange && !!this.props.adaptiveMode
|
|
128
|
+
});
|
|
129
|
+
let y, w;
|
|
130
|
+
return this.props.isRange ? w = [
|
|
131
|
+
r(this.props.pickedDate[0], e),
|
|
132
|
+
r(this.props.pickedDate[1], e)
|
|
133
|
+
] : y = r(this.props.pickedDate, e), /* @__PURE__ */ f("div", { className: B, "data-tx": "1.5.0", children: /* @__PURE__ */ b(
|
|
134
|
+
C.Provider,
|
|
135
|
+
{
|
|
136
|
+
value: {
|
|
137
|
+
format: e,
|
|
138
|
+
limitRange: a,
|
|
139
|
+
pickType: t,
|
|
140
|
+
markedDays: i,
|
|
141
|
+
disabledDays: o,
|
|
142
|
+
viewDate: Y,
|
|
143
|
+
viewMode: T,
|
|
144
|
+
periodId: this.periodId,
|
|
145
|
+
onDateSelect: this.handleDateSelect,
|
|
146
|
+
onPageChange: this.handlePageChange,
|
|
147
|
+
onViewChange: this.handleViewChange
|
|
148
|
+
},
|
|
149
|
+
children: [
|
|
150
|
+
/* @__PURE__ */ f(
|
|
151
|
+
x,
|
|
152
|
+
{
|
|
153
|
+
prevButtonProps: m,
|
|
154
|
+
nextButtonProps: D,
|
|
155
|
+
viewButtonProps: P,
|
|
156
|
+
children: A
|
|
157
|
+
}
|
|
158
|
+
),
|
|
159
|
+
/* @__PURE__ */ f(
|
|
160
|
+
N,
|
|
161
|
+
{
|
|
162
|
+
pickedDate: y,
|
|
163
|
+
pickedRange: w,
|
|
164
|
+
dayHtmlAttributes: s,
|
|
165
|
+
monthHtmlAttributes: n,
|
|
166
|
+
yearHtmlAttributes: c
|
|
167
|
+
}
|
|
168
|
+
),
|
|
169
|
+
S && this.renderFooter()
|
|
170
|
+
]
|
|
171
|
+
}
|
|
172
|
+
) });
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
p(v, "Range", q), p(v, "defaultProps", {
|
|
176
|
+
format: O,
|
|
177
|
+
limitRange: _,
|
|
178
|
+
pickType: g.datePick
|
|
179
|
+
}), p(v, "contextType", C);
|
|
180
|
+
export {
|
|
181
|
+
v as Calendar
|
|
182
|
+
};
|
|
183
|
+
//# sourceMappingURL=Calendar.js.map
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import e from "react";
|
|
2
|
+
import { h as a } from "../../chunks/vendor-9KVE23Ri.js";
|
|
3
|
+
import { globalLimitRange as t, dateFormatYYYYMMDD as o } from "../../consts/DateConst.js";
|
|
4
|
+
import { ECalendarViewMode as r, ECalendarPickType as i } from "./enums.js";
|
|
5
|
+
const l = e.createContext({
|
|
6
|
+
format: o,
|
|
7
|
+
limitRange: t,
|
|
8
|
+
pickType: i.datePick,
|
|
9
|
+
viewDate: a().startOf("day"),
|
|
10
|
+
viewMode: r.DAYS,
|
|
11
|
+
periodId: "",
|
|
12
|
+
onDateSelect: () => {
|
|
13
|
+
},
|
|
14
|
+
onPageChange: () => {
|
|
15
|
+
},
|
|
16
|
+
onViewChange: () => {
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
export {
|
|
20
|
+
l as CalendarContext
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=CalendarContext.js.map
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsxs as s, Fragment as d } from "react/jsx-runtime";
|
|
2
|
+
import { h as n } from "../../chunks/vendor-9KVE23Ri.js";
|
|
3
|
+
const h = ({
|
|
4
|
+
children: e,
|
|
5
|
+
defaultDate: t,
|
|
6
|
+
onRangeChange: a,
|
|
7
|
+
pickedRange: r,
|
|
8
|
+
...o
|
|
9
|
+
}) => /* @__PURE__ */ s(d, { children: [
|
|
10
|
+
e[0]({
|
|
11
|
+
...o,
|
|
12
|
+
isRange: !0,
|
|
13
|
+
defaultDate: t ?? n(),
|
|
14
|
+
onDateChange: a,
|
|
15
|
+
pickedDate: r
|
|
16
|
+
}),
|
|
17
|
+
e[1]({
|
|
18
|
+
...o,
|
|
19
|
+
isRange: !0,
|
|
20
|
+
defaultDate: (t ?? n()).add(1, "month"),
|
|
21
|
+
onDateChange: a,
|
|
22
|
+
pickedDate: r
|
|
23
|
+
})
|
|
24
|
+
] });
|
|
25
|
+
export {
|
|
26
|
+
h as CalendarRange
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=CalendarRange.js.map
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { jsxs as T, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import { useContext as D } from "react";
|
|
3
|
+
import B from "@sberbusiness/icons-next/CaretleftStrokeSrvIcon24";
|
|
4
|
+
import v from "@sberbusiness/icons-next/CaretrightStrokeSrvIcon24";
|
|
5
|
+
import { CalendarContext as w } from "../CalendarContext.js";
|
|
6
|
+
import { Button as H } from "../../Button/Button.js";
|
|
7
|
+
import { ButtonIcon as A } from "../../Button/ButtonIcon.js";
|
|
8
|
+
import { EButtonIconShape as E, EButtonTheme as L } from "../../Button/enums.js";
|
|
9
|
+
import { ECalendarViewMode as e } from "../enums.js";
|
|
10
|
+
import { globalLimitRange as O } from "../../../consts/DateConst.js";
|
|
11
|
+
import { EComponentSize as V } from "../../../enums/EComponentSize.js";
|
|
12
|
+
const U = "calendarControls__8319a1a8", j = {
|
|
13
|
+
calendarControls: U
|
|
14
|
+
}, Z = ({
|
|
15
|
+
children: m,
|
|
16
|
+
prevButtonProps: i = {},
|
|
17
|
+
nextButtonProps: d = {},
|
|
18
|
+
viewButtonProps: c = {}
|
|
19
|
+
}) => {
|
|
20
|
+
const { viewDate: a, viewMode: n, limitRange: u, periodId: S, onPageChange: h, onViewChange: p } = D(w), b = () => {
|
|
21
|
+
const { disabled: t, onClick: o, ...r } = typeof i == "function" ? i(n) : i;
|
|
22
|
+
return /* @__PURE__ */ s(
|
|
23
|
+
A,
|
|
24
|
+
{
|
|
25
|
+
shape: E.CIRCLE,
|
|
26
|
+
disabled: t || N(),
|
|
27
|
+
onClick: R(o),
|
|
28
|
+
...r,
|
|
29
|
+
children: /* @__PURE__ */ s(B, { paletteIndex: 5 })
|
|
30
|
+
}
|
|
31
|
+
);
|
|
32
|
+
}, g = () => {
|
|
33
|
+
const { disabled: t, onClick: o, ...r } = typeof d == "function" ? d(n) : d;
|
|
34
|
+
return /* @__PURE__ */ s(
|
|
35
|
+
A,
|
|
36
|
+
{
|
|
37
|
+
shape: E.CIRCLE,
|
|
38
|
+
disabled: t || Y(),
|
|
39
|
+
onClick: x(o),
|
|
40
|
+
...r,
|
|
41
|
+
children: /* @__PURE__ */ s(v, { paletteIndex: 5 })
|
|
42
|
+
}
|
|
43
|
+
);
|
|
44
|
+
}, I = () => {
|
|
45
|
+
const { onClick: t, ...o } = typeof c == "function" ? c(n) : c;
|
|
46
|
+
return /* @__PURE__ */ s(
|
|
47
|
+
H,
|
|
48
|
+
{
|
|
49
|
+
id: S,
|
|
50
|
+
"aria-live": "polite",
|
|
51
|
+
theme: L.LINK,
|
|
52
|
+
size: V.SM,
|
|
53
|
+
onClick: M(t),
|
|
54
|
+
...o,
|
|
55
|
+
children: m
|
|
56
|
+
}
|
|
57
|
+
);
|
|
58
|
+
}, N = () => {
|
|
59
|
+
const t = a.clone();
|
|
60
|
+
return n === e.DAYS ? t.startOf("month") : n === e.MONTHS ? t.startOf("year") : n === e.YEARS && t.startOf("year").subtract(5, "years"), t.subtract(1, "day").isBefore(u.dateFrom || O.dateFrom, "day");
|
|
61
|
+
}, Y = () => {
|
|
62
|
+
const t = a.clone();
|
|
63
|
+
return n === e.DAYS ? t.endOf("month") : n === e.MONTHS ? t.endOf("year") : n === e.YEARS && t.endOf("year").add(6, "years"), t.add(1, "day").isAfter(u.dateTo || O.dateTo, "day");
|
|
64
|
+
}, R = (t) => (o) => {
|
|
65
|
+
const r = C(), l = y(), f = a.clone().subtract(l, r);
|
|
66
|
+
h(f, n), t == null || t(o);
|
|
67
|
+
}, x = (t) => (o) => {
|
|
68
|
+
const r = C(), l = y(), f = a.clone().add(l, r);
|
|
69
|
+
h(f, n), t == null || t(o);
|
|
70
|
+
}, M = (t) => (o) => {
|
|
71
|
+
n === e.DAYS ? p(a, e.MONTHS) : n === e.MONTHS && p(a, e.YEARS), t == null || t(o);
|
|
72
|
+
}, C = () => {
|
|
73
|
+
switch (n) {
|
|
74
|
+
case e.DAYS:
|
|
75
|
+
return "month";
|
|
76
|
+
case e.MONTHS:
|
|
77
|
+
case e.YEARS:
|
|
78
|
+
return "year";
|
|
79
|
+
}
|
|
80
|
+
}, y = () => {
|
|
81
|
+
switch (n) {
|
|
82
|
+
case e.DAYS:
|
|
83
|
+
case e.MONTHS:
|
|
84
|
+
return 1;
|
|
85
|
+
case e.YEARS:
|
|
86
|
+
return 12;
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
return /* @__PURE__ */ T("div", { className: j.calendarControls, children: [
|
|
90
|
+
b(),
|
|
91
|
+
n === e.YEARS ? /* @__PURE__ */ s("span", { id: S, tabIndex: -1, "aria-live": "polite", children: m }) : I(),
|
|
92
|
+
g()
|
|
93
|
+
] });
|
|
94
|
+
};
|
|
95
|
+
export {
|
|
96
|
+
Z as CalendarControls
|
|
97
|
+
};
|
|
98
|
+
//# sourceMappingURL=CalendarControls.js.map
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
const a = "calendarFooter__99e0f409", r = {
|
|
3
|
+
calendarFooter: a
|
|
4
|
+
}, t = ({ children: o }) => /* @__PURE__ */ e("div", { className: r.calendarFooter, children: o });
|
|
5
|
+
t.displayName = "CalendarFooter";
|
|
6
|
+
export {
|
|
7
|
+
t as CalendarFooter
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=CalendarFooter.js.map
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { jsx as O } from "react/jsx-runtime";
|
|
2
|
+
import g, { useContext as E } from "react";
|
|
3
|
+
import { CalendarContext as N } from "../CalendarContext.js";
|
|
4
|
+
import { Button as R } from "../../Button/Button.js";
|
|
5
|
+
import { EButtonTheme as w } from "../../Button/enums.js";
|
|
6
|
+
import { ECalendarPickType as f, ECalendarViewMode as r } from "../enums.js";
|
|
7
|
+
import { isDateOutOfRange as l, isDayDisabled as x } from "../utils.js";
|
|
8
|
+
import { EComponentSize as A } from "../../../enums/EComponentSize.js";
|
|
9
|
+
const B = g.forwardRef(
|
|
10
|
+
({ todayDate: e, currentPeriodSelected: d, disabled: o, onClick: i, ...p }, u) => {
|
|
11
|
+
const { format: S, limitRange: t, pickType: n, viewMode: m, disabledDays: C, onPageChange: a, onViewChange: s, onDateSelect: c } = E(N), T = (M) => {
|
|
12
|
+
d ? c(e) : n === f.datePick ? m === r.DAYS ? a(e, r.DAYS) : s(e, r.DAYS) : m === r.MONTHS ? a(e, r.MONTHS) : s(e, r.MONTHS), i == null || i(M);
|
|
13
|
+
}, h = () => o !== void 0 ? o : n === f.datePick ? l(e, t, "day") || x(e.format(S), C) : l(e, t, "month");
|
|
14
|
+
return /* @__PURE__ */ O(
|
|
15
|
+
R,
|
|
16
|
+
{
|
|
17
|
+
theme: w.SECONDARY,
|
|
18
|
+
size: A.SM,
|
|
19
|
+
onClick: T,
|
|
20
|
+
disabled: h(),
|
|
21
|
+
...p,
|
|
22
|
+
ref: u
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
}
|
|
26
|
+
);
|
|
27
|
+
B.displayName = "CalendarTodayButton";
|
|
28
|
+
export {
|
|
29
|
+
B as CalendarTodayButton
|
|
30
|
+
};
|
|
31
|
+
//# sourceMappingURL=CalendarTodayButton.js.map
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { useContext as d, useRef as f } from "react";
|
|
3
|
+
import { CalendarContext as C } from "../CalendarContext.js";
|
|
4
|
+
import { CalendarViewContext as c } from "../CalendarViewContext.js";
|
|
5
|
+
import { ECalendarViewMode as o } from "../enums.js";
|
|
6
|
+
import { CalendarViewDays as l } from "./CalendarViewDays.js";
|
|
7
|
+
import { CalendarViewMonths as w } from "./CalendarViewMonths.js";
|
|
8
|
+
import { CalendarViewYears as p } from "./CalendarViewYears.js";
|
|
9
|
+
const Y = ({
|
|
10
|
+
dayHtmlAttributes: t,
|
|
11
|
+
monthHtmlAttributes: n,
|
|
12
|
+
yearHtmlAttributes: a,
|
|
13
|
+
...r
|
|
14
|
+
}) => {
|
|
15
|
+
const { viewMode: i } = d(C), m = f(!1), s = () => {
|
|
16
|
+
switch (i) {
|
|
17
|
+
case o.DAYS:
|
|
18
|
+
return /* @__PURE__ */ e(l, { dayHtmlAttributes: t, ...r });
|
|
19
|
+
case o.MONTHS:
|
|
20
|
+
return /* @__PURE__ */ e(w, { monthHtmlAttributes: n, ...r });
|
|
21
|
+
case o.YEARS:
|
|
22
|
+
return /* @__PURE__ */ e(p, { yearHtmlAttributes: a, ...r });
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
return /* @__PURE__ */ e(c.Provider, { value: { viewItemFocusedRef: m }, children: s() });
|
|
26
|
+
};
|
|
27
|
+
export {
|
|
28
|
+
Y as CalendarView
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=CalendarView.js.map
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { jsxs as L, jsx as d } from "react/jsx-runtime";
|
|
2
|
+
import { h as f, c as q } from "../../../chunks/vendor-9KVE23Ri.js";
|
|
3
|
+
import { useContext as N, useCallback as x, useState as z, useEffect as J } from "react";
|
|
4
|
+
import { isDateOutOfRange as I, isDayDisabled as Q } from "../utils.js";
|
|
5
|
+
import { WEEKDAYS_SET as X } from "../../../consts/DateConst.js";
|
|
6
|
+
import { CalendarViewContext as Z } from "../CalendarViewContext.js";
|
|
7
|
+
import { s as o, C as ee } from "../../../chunks/CalendarViewItem-Cs4qo2T0.js";
|
|
8
|
+
import { isKey as m } from "../../../utils/keyboard.js";
|
|
9
|
+
import { ECalendarDateMarkType as ae, ECalendarViewMode as M } from "../enums.js";
|
|
10
|
+
import { CalendarContext as te } from "../CalendarContext.js";
|
|
11
|
+
const ye = ({
|
|
12
|
+
pickedDate: i,
|
|
13
|
+
pickedRange: r,
|
|
14
|
+
dayHtmlAttributes: h = {}
|
|
15
|
+
}) => {
|
|
16
|
+
const { format: u, periodId: V, limitRange: S, viewDate: n, markedDays: y, disabledDays: C, onDateSelect: W, onPageChange: T } = N(te), { viewItemFocusedRef: A } = N(Z), _ = n.clone().startOf("month").startOf("week"), b = x(
|
|
17
|
+
(e) => I(e, S, "day") || Q(e.format(u), C),
|
|
18
|
+
[S, C, u]
|
|
19
|
+
), w = x(() => {
|
|
20
|
+
if (i && i.isSame(n, "month"))
|
|
21
|
+
return i;
|
|
22
|
+
{
|
|
23
|
+
const e = n.clone().startOf("month");
|
|
24
|
+
for (let a = 0; a < e.daysInMonth(); a++)
|
|
25
|
+
if (e.add(a, "day"), !b(e))
|
|
26
|
+
return e;
|
|
27
|
+
}
|
|
28
|
+
}, [i, n, b]), [O, E] = z(w());
|
|
29
|
+
J(() => {
|
|
30
|
+
A.current || E(w());
|
|
31
|
+
}, [n, A, w]);
|
|
32
|
+
const B = () => {
|
|
33
|
+
const e = f.weekdays(!0), a = f.weekdaysMin(!0);
|
|
34
|
+
return /* @__PURE__ */ d("thead", { children: /* @__PURE__ */ d("tr", { children: X.map((t) => /* @__PURE__ */ d(
|
|
35
|
+
"th",
|
|
36
|
+
{
|
|
37
|
+
className: o.calendarViewDaysHeader,
|
|
38
|
+
abbr: e[t],
|
|
39
|
+
children: a[t]
|
|
40
|
+
},
|
|
41
|
+
`calendar-table-header-${t}`
|
|
42
|
+
)) }) });
|
|
43
|
+
}, g = () => /* @__PURE__ */ d("tbody", { className: o.calendarViewDaysBody, children: [0, 1, 2, 3, 4, 5].map((e) => /* @__PURE__ */ d("tr", { children: [0, 1, 2, 3, 4, 5, 6].map((a) => P(e, a)) }, `calendar-table-row-${e}`)) }), P = (e, a) => {
|
|
44
|
+
const t = f(_).add(e * 7 + a, "day"), s = q({ [o.current]: F(t) }, $(t)), l = G(t), D = b(t), k = !D && v(t), H = K(t), p = Y(t);
|
|
45
|
+
return /* @__PURE__ */ d(
|
|
46
|
+
ee,
|
|
47
|
+
{
|
|
48
|
+
className: s,
|
|
49
|
+
...typeof h == "function" ? h({ marked: p !== void 0 }) : h,
|
|
50
|
+
date: t,
|
|
51
|
+
unit: "day",
|
|
52
|
+
active: l,
|
|
53
|
+
disabled: D,
|
|
54
|
+
tabbable: k,
|
|
55
|
+
muted: H,
|
|
56
|
+
markType: p,
|
|
57
|
+
onKeyDown: j(t),
|
|
58
|
+
onDateSelect: R,
|
|
59
|
+
children: t.date()
|
|
60
|
+
},
|
|
61
|
+
`calendar-table-data-${a}`
|
|
62
|
+
);
|
|
63
|
+
}, v = (e) => O ? e.isSame(O, "day") : !1, K = (e) => !e.isSame(n, "month"), F = (e) => e.isSame(f(), "day"), G = (e) => {
|
|
64
|
+
var a, t;
|
|
65
|
+
return r ? !!((a = r[0]) != null && a.isSame(e, "day") || (t = r[1]) != null && t.isSame(e, "day")) : !!i && e.isSame(i, "day");
|
|
66
|
+
}, Y = (e) => {
|
|
67
|
+
if (y) {
|
|
68
|
+
const a = e.format(u);
|
|
69
|
+
if (Array.isArray(y)) {
|
|
70
|
+
if (y.includes(a))
|
|
71
|
+
return ae.BASIC;
|
|
72
|
+
} else if (a in y)
|
|
73
|
+
return y[e.format(u)];
|
|
74
|
+
}
|
|
75
|
+
}, $ = (e) => {
|
|
76
|
+
if (!r || !r[0] || !r[1] || !e.isBetween(r[0], r[1], "day", "[]"))
|
|
77
|
+
return;
|
|
78
|
+
let a;
|
|
79
|
+
return r[0].isSame(r[1], "day") ? a = o.rangeSingle : e.isSame(r[0], "day") ? a = o.rangeStart : e.isSame(r[1], "day") ? a = o.rangeEnd : a = o.rangeBetween, a;
|
|
80
|
+
}, c = (e, a, t, s) => {
|
|
81
|
+
const l = e.clone(), D = {
|
|
82
|
+
add: f.fn.add.bind(l),
|
|
83
|
+
subtract: f.fn.subtract.bind(l)
|
|
84
|
+
}[a];
|
|
85
|
+
for (; D(t, s); ) {
|
|
86
|
+
if (I(l, S, "day"))
|
|
87
|
+
return e;
|
|
88
|
+
if (!b(l))
|
|
89
|
+
break;
|
|
90
|
+
}
|
|
91
|
+
return l;
|
|
92
|
+
}, j = (e) => (a) => {
|
|
93
|
+
const t = a.code || a.keyCode;
|
|
94
|
+
let s;
|
|
95
|
+
m(t, "ARROW_RIGHT") ? (s = c(e, "add", 1, "day"), a.preventDefault()) : m(t, "ARROW_LEFT") ? (s = c(e, "subtract", 1, "day"), a.preventDefault()) : m(t, "ARROW_DOWN") ? (s = c(e, "add", 1, "week"), a.preventDefault()) : m(t, "ARROW_UP") ? (s = c(e, "subtract", 1, "week"), a.preventDefault()) : m(t, "PAGE_DOWN") ? (s = c(e, "add", 1, "month"), a.preventDefault()) : m(t, "PAGE_UP") && (s = c(e, "subtract", 1, "month"), a.preventDefault()), s && U(s);
|
|
96
|
+
}, R = (e) => {
|
|
97
|
+
W(e);
|
|
98
|
+
}, U = (e) => {
|
|
99
|
+
E(e), e.isBefore(n, "month") ? (e = n.clone().subtract(1, "month"), T(e, M.DAYS)) : e.isAfter(n, "month") && (e = n.clone().add(1, "month"), T(e, M.DAYS));
|
|
100
|
+
};
|
|
101
|
+
return /* @__PURE__ */ L("table", { className: o.calendarViewDays, role: "grid", "aria-labelledby": V, children: [
|
|
102
|
+
B(),
|
|
103
|
+
g()
|
|
104
|
+
] });
|
|
105
|
+
};
|
|
106
|
+
export {
|
|
107
|
+
ye as CalendarViewDays
|
|
108
|
+
};
|
|
109
|
+
//# sourceMappingURL=CalendarViewDays.js.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import "../../../chunks/vendor-9KVE23Ri.js";
|
|
3
|
+
import "react";
|
|
4
|
+
import "../enums.js";
|
|
5
|
+
import "../CalendarViewContext.js";
|
|
6
|
+
import "../../../utils/keyboard.js";
|
|
7
|
+
import { C } from "../../../chunks/CalendarViewItem-Cs4qo2T0.js";
|
|
8
|
+
export {
|
|
9
|
+
C as CalendarViewItem
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=CalendarViewItem.js.map
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { jsx as f } from "react/jsx-runtime";
|
|
2
|
+
import { useContext as S, useCallback as O, useState as F, useEffect as G } from "react";
|
|
3
|
+
import { h } from "../../../chunks/vendor-9KVE23Ri.js";
|
|
4
|
+
import { CalendarContext as H } from "../CalendarContext.js";
|
|
5
|
+
import { CalendarViewContext as K } from "../CalendarViewContext.js";
|
|
6
|
+
import { isDateOutOfRange as R } from "../utils.js";
|
|
7
|
+
import { s as k, C as B } from "../../../chunks/CalendarViewItem-Cs4qo2T0.js";
|
|
8
|
+
import { isKey as l } from "../../../utils/keyboard.js";
|
|
9
|
+
import { ECalendarPickType as U, ECalendarViewMode as u } from "../enums.js";
|
|
10
|
+
const Z = ({ pickedDate: r, monthHtmlAttributes: T = {} }) => {
|
|
11
|
+
const { pickType: w, periodId: g, limitRange: m, viewDate: o, onDateSelect: A, onPageChange: D, onViewChange: P } = S(H), { viewItemFocusedRef: y } = S(K), x = h.monthsShort(), b = O(
|
|
12
|
+
(e) => R(e, m, "month"),
|
|
13
|
+
[m]
|
|
14
|
+
), d = O(() => {
|
|
15
|
+
if (r && r.isSame(o, "year"))
|
|
16
|
+
return r;
|
|
17
|
+
{
|
|
18
|
+
const e = o.clone().startOf("year");
|
|
19
|
+
for (let t = 0; t < 12; t++)
|
|
20
|
+
if (e.add(t, "month"), !b(e))
|
|
21
|
+
return e;
|
|
22
|
+
}
|
|
23
|
+
}, [r, o, b]), [p, C] = F(d());
|
|
24
|
+
G(() => {
|
|
25
|
+
y.current || C(d());
|
|
26
|
+
}, [o, y, d]);
|
|
27
|
+
const E = () => /* @__PURE__ */ f("tbody", { children: [0, 1, 2, 3].map((e) => /* @__PURE__ */ f("tr", { children: [0, 1, 2].map((t) => I(e, t)) }, `calendar-view-months-row-${e}`)) }), I = (e, t) => {
|
|
28
|
+
const n = e * 3 + t, a = o.clone().startOf("month").month(n), i = V(a), c = b(a), v = !c && W(a);
|
|
29
|
+
return /* @__PURE__ */ f(
|
|
30
|
+
B,
|
|
31
|
+
{
|
|
32
|
+
...T,
|
|
33
|
+
date: a,
|
|
34
|
+
unit: "month",
|
|
35
|
+
active: i,
|
|
36
|
+
disabled: c,
|
|
37
|
+
tabbable: v,
|
|
38
|
+
onKeyDown: _(a),
|
|
39
|
+
onDateSelect: M,
|
|
40
|
+
children: x[n]
|
|
41
|
+
},
|
|
42
|
+
`calendar-table-data-${t}`
|
|
43
|
+
);
|
|
44
|
+
}, V = (e) => r == null ? !1 : r.isSame(e, "month"), W = (e) => p ? e.isSame(p, "month") : !1, _ = (e) => (t) => {
|
|
45
|
+
const n = t.code || t.keyCode;
|
|
46
|
+
let a;
|
|
47
|
+
l(n, "ARROW_RIGHT") ? (a = s(e, "add", 1, "month"), t.preventDefault()) : l(n, "ARROW_LEFT") ? (a = s(e, "subtract", 1, "month"), t.preventDefault()) : l(n, "ARROW_DOWN") ? (a = s(e, "add", 3, "month"), t.preventDefault()) : l(n, "ARROW_UP") ? (a = s(e, "subtract", 3, "month"), t.preventDefault()) : l(n, "PAGE_DOWN") ? (a = s(e, "add", 1, "year"), t.preventDefault()) : l(n, "PAGE_UP") && (a = s(e, "subtract", 1, "year"), t.preventDefault()), a && N(a);
|
|
48
|
+
}, s = (e, t, n, a) => {
|
|
49
|
+
const i = e.clone(), c = {
|
|
50
|
+
add: h.fn.add.bind(i),
|
|
51
|
+
subtract: h.fn.subtract.bind(i)
|
|
52
|
+
}[t];
|
|
53
|
+
return c(n, a), R(i, m, "month") ? e : i;
|
|
54
|
+
}, M = (e) => {
|
|
55
|
+
w === U.monthYearPick ? A(e) : P(e, u.DAYS);
|
|
56
|
+
}, N = (e) => {
|
|
57
|
+
C(e), e.isBefore(o, "year") ? (e = o.clone().subtract(1, "year"), D(e, u.MONTHS)) : e.isAfter(o, "year") && (e = o.clone().add(1, "year"), D(e, u.MONTHS));
|
|
58
|
+
};
|
|
59
|
+
return /* @__PURE__ */ f("table", { className: k.calendarViewMonths, role: "grid", "aria-labelledby": g, children: E() });
|
|
60
|
+
};
|
|
61
|
+
export {
|
|
62
|
+
Z as CalendarViewMonths
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=CalendarViewMonths.js.map
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { jsx as f } from "react/jsx-runtime";
|
|
2
|
+
import { useContext as R, useCallback as C, useState as v, useEffect as F } from "react";
|
|
3
|
+
import { h as w } from "../../../chunks/vendor-9KVE23Ri.js";
|
|
4
|
+
import { CalendarContext as N } from "../CalendarContext.js";
|
|
5
|
+
import { CalendarViewContext as G } from "../CalendarViewContext.js";
|
|
6
|
+
import { isDateOutOfRange as O } from "../utils.js";
|
|
7
|
+
import { s as K, C as H } from "../../../chunks/CalendarViewItem-Cs4qo2T0.js";
|
|
8
|
+
import { isKey as i } from "../../../utils/keyboard.js";
|
|
9
|
+
import { ECalendarViewMode as y } from "../enums.js";
|
|
10
|
+
const Q = ({ pickedDate: s, yearHtmlAttributes: S = {} }) => {
|
|
11
|
+
const { periodId: g, limitRange: d, viewDate: n, onPageChange: m, onViewChange: A } = R(N), { viewItemFocusedRef: D } = R(G), T = n.year(), b = C(
|
|
12
|
+
(e) => O(e, d, "year"),
|
|
13
|
+
[d]
|
|
14
|
+
), u = C(() => {
|
|
15
|
+
if (s && s.isSame(n, "year"))
|
|
16
|
+
return s;
|
|
17
|
+
{
|
|
18
|
+
const e = n.clone().subtract(5, "year");
|
|
19
|
+
for (let a = 0; a < 12; a++)
|
|
20
|
+
if (e.add(a, "month"), !b(e))
|
|
21
|
+
return e;
|
|
22
|
+
}
|
|
23
|
+
}, [s, n, b]), [h, p] = v(u());
|
|
24
|
+
F(() => {
|
|
25
|
+
D.current || p(u());
|
|
26
|
+
}, [n, D, u]);
|
|
27
|
+
const E = () => /* @__PURE__ */ f("tbody", { children: [0, 1, 2, 3].map((e) => /* @__PURE__ */ f("tr", { children: [0, 1, 2].map((a) => x(e, a)) }, `calendar-view-years-row-${e}`)) }), x = (e, a) => {
|
|
28
|
+
const t = T + e * 3 + a - 5, r = n.clone().startOf("year").year(t), l = I(r), c = b(r), Y = !c && V(r);
|
|
29
|
+
return /* @__PURE__ */ f(
|
|
30
|
+
H,
|
|
31
|
+
{
|
|
32
|
+
...S,
|
|
33
|
+
date: r,
|
|
34
|
+
unit: "year",
|
|
35
|
+
active: l,
|
|
36
|
+
disabled: c,
|
|
37
|
+
tabbable: Y,
|
|
38
|
+
onKeyDown: W(r),
|
|
39
|
+
onDateSelect: _,
|
|
40
|
+
children: t
|
|
41
|
+
},
|
|
42
|
+
`calendar-table-data-${a}`
|
|
43
|
+
);
|
|
44
|
+
}, I = (e) => s == null ? !1 : s.isSame(e, "year"), V = (e) => h ? e.isSame(h, "year") : !1, W = (e) => (a) => {
|
|
45
|
+
const t = a.code || a.keyCode;
|
|
46
|
+
let r;
|
|
47
|
+
i(t, "ARROW_RIGHT") ? (r = o(e, "add", 1, "year"), a.preventDefault()) : i(t, "ARROW_LEFT") ? (r = o(e, "subtract", 1, "year"), a.preventDefault()) : i(t, "ARROW_DOWN") ? (r = o(e, "add", 3, "year"), a.preventDefault()) : i(t, "ARROW_UP") ? (r = o(e, "subtract", 3, "year"), a.preventDefault()) : i(t, "PAGE_DOWN") ? (r = o(e, "add", 12, "year"), a.preventDefault()) : i(t, "PAGE_UP") && (r = o(e, "subtract", 12, "year"), a.preventDefault()), r && P(r);
|
|
48
|
+
}, o = (e, a, t, r) => {
|
|
49
|
+
const l = e.clone(), c = {
|
|
50
|
+
add: w.fn.add.bind(l),
|
|
51
|
+
subtract: w.fn.subtract.bind(l)
|
|
52
|
+
}[a];
|
|
53
|
+
return c(t, r), O(l, d, "year") ? e : l;
|
|
54
|
+
}, _ = (e) => {
|
|
55
|
+
A(e, y.MONTHS);
|
|
56
|
+
}, P = (e) => {
|
|
57
|
+
p(e), e.year() + 5 < n.year() ? (e = n.clone().subtract(12, "years"), m(e, y.YEARS)) : e.year() - 6 > n.year() && (e = n.clone().add(12, "years"), m(e, y.YEARS));
|
|
58
|
+
};
|
|
59
|
+
return /* @__PURE__ */ f("table", { className: K.calendarViewYears, role: "grid", "aria-labelledby": g, children: E() });
|
|
60
|
+
};
|
|
61
|
+
export {
|
|
62
|
+
Q as CalendarViewYears
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=CalendarViewYears.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
var I = /* @__PURE__ */ ((A) => (A[A.datePick = 0] = "datePick", A[A.monthYearPick = 1] = "monthYearPick", A))(I || {}), N = /* @__PURE__ */ ((A) => (A.DAYS = "days", A.MONTHS = "months", A.YEARS = "years", A))(N || {}), S = /* @__PURE__ */ ((A) => (A[A.BASIC = 0] = "BASIC", A[A.STANDARD = 1] = "STANDARD", A[A.ATTENTION = 2] = "ATTENTION", A[A.CRITICAL = 3] = "CRITICAL", A))(S || {});
|
|
2
|
+
export {
|
|
3
|
+
S as ECalendarDateMarkType,
|
|
4
|
+
I as ECalendarPickType,
|
|
5
|
+
N as ECalendarViewMode
|
|
6
|
+
};
|
|
7
|
+
//# sourceMappingURL=enums.js.map
|