hrm_ui_lib 2.1.0-alpha.17 → 2.1.0-alpha.18
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/assets/styles/styles.css +1 -1
- package/components/Alert/Alert.js +6 -11
- package/components/Alert/consts.js +1 -15
- package/components/Alert/index.js +1 -1
- package/components/Alert/types.js +0 -1
- package/components/Avatar/Avatar.js +2 -24
- package/components/Avatar/AvatarGroup.js +5 -21
- package/components/Avatar/index.js +1 -2
- package/components/Avatar/types.js +0 -1
- package/components/Badge/Badge.js +2 -7
- package/components/Badge/index.js +1 -1
- package/components/Badge/types.js +0 -1
- package/components/BadgeV2/BadgeV2.js +1 -14
- package/components/BadgeV2/index.js +1 -1
- package/components/BadgeV2/types.js +1 -5
- package/components/Breadcrumb/Breadcrumb.js +2 -7
- package/components/Breadcrumb/index.js +1 -1
- package/components/Breadcrumb/types.js +0 -1
- package/components/Button/Button.js +2 -31
- package/components/Button/consts.js +1 -14
- package/components/Button/index.js +1 -1
- package/components/Button/types.js +0 -1
- package/components/ButtonGroup/ButtonGroup.js +2 -16
- package/components/ButtonGroup/ButtonGroupItem.js +3 -23
- package/components/ButtonGroup/consts.js +1 -10
- package/components/ButtonGroup/index.js +1 -1
- package/components/ButtonGroup/types.js +0 -1
- package/components/Card/Card.js +1 -30
- package/components/Card/CardComponent/Card.js +3 -13
- package/components/Card/CardComponent/CardBody.js +2 -9
- package/components/Card/CardComponent/CardFooter.js +1 -6
- package/components/Card/CardComponent/CardHead.js +2 -23
- package/components/Card/CardContext.js +1 -6
- package/components/Card/index.js +1 -1
- package/components/Card/types.js +0 -1
- package/components/CardGroup/CardGroup.js +1 -24
- package/components/CardGroup/CardGroupComponent/CardBody.js +2 -8
- package/components/CardGroup/CardGroupComponent/CardGroup.js +2 -9
- package/components/CardGroup/CardGroupComponent/CardHead.js +3 -9
- package/components/CardGroup/CardGroupContext.js +1 -3
- package/components/CardGroup/index.js +1 -1
- package/components/CardGroup/types.js +0 -1
- package/components/Checkbox/Checkbox.js +6 -44
- package/components/Checkbox/consts.js +1 -4
- package/components/Checkbox/index.js +1 -1
- package/components/Checkbox/types.js +0 -1
- package/components/Chips/Chips.js +2 -25
- package/components/Chips/consts.js +1 -12
- package/components/Chips/index.js +1 -1
- package/components/Chips/types.js +1 -5
- package/components/Collapse/Collapse/Collapse.js +5 -19
- package/components/Collapse/Collapse/Title.js +2 -16
- package/components/Collapse/CollapseGroup/CollapseGroup.js +3 -25
- package/components/Collapse/CollapseItem/CollapseItem.js +10 -14
- package/components/Collapse/index.js +1 -3
- package/components/Collapse/types.js +0 -1
- package/components/Container/Container.js +2 -5
- package/components/Container/index.js +1 -1
- package/components/Container/types.js +0 -1
- package/components/Copy/Copy.js +3 -16
- package/components/Copy/index.js +1 -1
- package/components/Copy/types.js +0 -1
- package/components/Counter/Counter.js +2 -57
- package/components/Counter/index.js +1 -1
- package/components/Counter/types.js +0 -1
- package/components/DarkModeSwitcher/DarkModeSwitcher.js +5 -15
- package/components/DarkModeSwitcher/index.js +1 -1
- package/components/DarkModeSwitcher/types.js +1 -5
- package/components/DatePicker/CustomHeader/CustomHeader.js +7 -17
- package/components/DatePicker/CustomHeader/helpers.js +1 -11
- package/components/DatePicker/RangeDatePicker/RangeDatePicker.js +1 -8
- package/components/DatePicker/RangeDatePicker/RangeDatePickerDesktop.js +4 -76
- package/components/DatePicker/RangeDatePicker/RangeDatePickerMobile.js +8 -90
- package/components/DatePicker/RangeDatePicker/index.js +1 -1
- package/components/DatePicker/SimpleDatePicker/SimpleDatePicker.js +1 -10
- package/components/DatePicker/SimpleDatePicker/SimpleDatePickerDesktop.js +4 -48
- package/components/DatePicker/SimpleDatePicker/SimpleDatePickerMobile.js +5 -48
- package/components/DatePicker/SimpleDatePicker/index.js +1 -1
- package/components/DatePicker/TimePicker/MobileModalContent.js +4 -34
- package/components/DatePicker/TimePicker/TimePicker.js +1 -8
- package/components/DatePicker/TimePicker/TimePickerDesktop.js +4 -67
- package/components/DatePicker/TimePicker/TimePickerMobile.js +5 -29
- package/components/DatePicker/TimePicker/consts.js +1 -5
- package/components/DatePicker/TimePicker/helpers.js +1 -11
- package/components/DatePicker/TimePicker/index.js +1 -1
- package/components/DatePicker/hooks.js +1 -37
- package/components/DatePicker/index.js +1 -3
- package/components/DatePicker/localization.js +1 -44
- package/components/DatePicker/types.js +1 -5
- package/components/Divider/Divider.js +2 -9
- package/components/Divider/index.js +1 -1
- package/components/Divider/types.js +0 -1
- package/components/Empty/Empty.js +4 -11
- package/components/Empty/index.js +1 -1
- package/components/Empty/types.js +0 -1
- package/components/Feedback/Feedback.d.ts +3 -0
- package/components/Feedback/Feedback.js +3 -0
- package/components/Feedback/consts.d.ts +1 -0
- package/components/Feedback/consts.js +1 -0
- package/components/Feedback/index.d.ts +1 -0
- package/components/Feedback/index.js +1 -0
- package/components/Feedback/types.d.ts +5 -0
- package/components/Feedback/types.js +0 -0
- package/components/FileUpload/DropzoneFileUpload/DropzoneFileUpload.js +7 -67
- package/components/FileUpload/DropzoneFileUpload/ErrorItem.js +1 -21
- package/components/FileUpload/DropzoneFileUpload/FilePreview.js +2 -24
- package/components/FileUpload/DropzoneFileUpload/PreviewItem.js +7 -30
- package/components/FileUpload/DropzoneFileUpload/helpers.js +1 -79
- package/components/FileUpload/DropzoneFileUpload/index.js +1 -1
- package/components/FileUpload/FileUpload.js +6 -70
- package/components/FileUpload/UploadItems.js +6 -23
- package/components/FileUpload/index.js +1 -3
- package/components/FileUpload/types.js +1 -6
- package/components/FormContainer/FormContainer.js +1 -53
- package/components/FormContainer/index.js +1 -1
- package/components/FormContainer/types.js +0 -1
- package/components/FormField/FormField.js +3 -21
- package/components/FormField/index.js +1 -1
- package/components/FormField/types.js +0 -1
- package/components/Heading/Heading.js +2 -7
- package/components/Heading/index.js +1 -1
- package/components/Heading/types.js +0 -1
- package/components/Image/Image.js +1 -13
- package/components/Image/index.js +1 -1
- package/components/Image/types.js +0 -1
- package/components/Input/Input.js +9 -76
- package/components/Input/index.js +1 -1
- package/components/Input/types.js +0 -1
- package/components/Link/Link.js +2 -16
- package/components/Link/index.js +1 -1
- package/components/Link/types.js +0 -1
- package/components/Menu/Menu.js +3 -51
- package/components/Menu/NestedMenu.js +3 -52
- package/components/Menu/index.js +1 -2
- package/components/Menu/types.js +0 -1
- package/components/Modal/Modal.js +2 -40
- package/components/Modal/ModalConfirmation.js +4 -23
- package/components/Modal/ModalContent.js +5 -10
- package/components/Modal/index.js +1 -2
- package/components/Modal/types.js +0 -1
- package/components/More/More.js +3 -20
- package/components/More/index.js +1 -1
- package/components/More/types.js +0 -1
- package/components/Pagination/Pagination.js +2 -18
- package/components/Pagination/consts.js +1 -6
- package/components/Pagination/index.js +1 -1
- package/components/Pagination/types.js +0 -1
- package/components/Popover/Popover.js +1 -45
- package/components/Popover/PopoverDesktop.js +1 -18
- package/components/Popover/PopoverMobile.js +3 -8
- package/components/Popover/index.js +1 -1
- package/components/Popover/types.js +0 -1
- package/components/Progress/Progress.js +4 -22
- package/components/Progress/index.js +1 -1
- package/components/Progress/types.js +0 -1
- package/components/ProgressStep/ProgressStep.js +2 -10
- package/components/ProgressStep/Step.js +9 -54
- package/components/ProgressStep/consts.js +1 -7
- package/components/ProgressStep/index.js +1 -1
- package/components/ProgressStep/types.js +1 -5
- package/components/Radio/Radio.js +4 -21
- package/components/Radio/RadioGroup.js +4 -23
- package/components/Radio/index.js +1 -2
- package/components/Radio/types.js +0 -1
- package/components/SVGIcons/IconAdd.js +1 -8
- package/components/SVGIcons/IconAddCircle.js +1 -8
- package/components/SVGIcons/IconAddCircleFilled.js +1 -8
- package/components/SVGIcons/IconAddFilled.js +1 -8
- package/components/SVGIcons/IconAirplaneTakeOff.js +1 -8
- package/components/SVGIcons/IconAirplaneTakeOffFilled.js +1 -8
- package/components/SVGIcons/IconAlert.js +1 -8
- package/components/SVGIcons/IconAlertBadge.js +1 -8
- package/components/SVGIcons/IconAlertBadgeFilled.js +1 -8
- package/components/SVGIcons/IconAlertFilled.js +1 -8
- package/components/SVGIcons/IconAm.js +7 -8
- package/components/SVGIcons/IconAmd.js +1 -8
- package/components/SVGIcons/IconAmdFilled.js +1 -8
- package/components/SVGIcons/IconApple.js +1 -8
- package/components/SVGIcons/IconArrowDown.js +1 -8
- package/components/SVGIcons/IconArrowDownFilled.js +1 -8
- package/components/SVGIcons/IconArrowDownLeft.js +1 -8
- package/components/SVGIcons/IconArrowDownLeftFilled.js +1 -8
- package/components/SVGIcons/IconArrowDownload.js +1 -8
- package/components/SVGIcons/IconArrowDownloadFilled.js +1 -8
- package/components/SVGIcons/IconArrowEnter.js +1 -8
- package/components/SVGIcons/IconArrowEnterFilled.js +1 -8
- package/components/SVGIcons/IconArrowExit.js +1 -8
- package/components/SVGIcons/IconArrowExitFilled.js +1 -8
- package/components/SVGIcons/IconArrowExportLeftToRight.js +1 -8
- package/components/SVGIcons/IconArrowExportLeftToRightFilled.js +1 -8
- package/components/SVGIcons/IconArrowExportRightToLeft.js +1 -8
- package/components/SVGIcons/IconArrowExportRightToLeftFilled.js +1 -8
- package/components/SVGIcons/IconArrowExportUp.js +1 -8
- package/components/SVGIcons/IconArrowExportUpFilled.js +1 -8
- package/components/SVGIcons/IconArrowImport.js +1 -8
- package/components/SVGIcons/IconArrowImportFilled.js +1 -8
- package/components/SVGIcons/IconArrowLeft.js +1 -8
- package/components/SVGIcons/IconArrowLeftFilled.js +1 -8
- package/components/SVGIcons/IconArrowRepeatAll.js +1 -8
- package/components/SVGIcons/IconArrowRepeatAllFilled.js +1 -8
- package/components/SVGIcons/IconArrowReset.js +1 -8
- package/components/SVGIcons/IconArrowResetFilled.js +1 -8
- package/components/SVGIcons/IconArrowRight.js +1 -8
- package/components/SVGIcons/IconArrowRightFilled.js +1 -8
- package/components/SVGIcons/IconArrowSort.js +1 -8
- package/components/SVGIcons/IconArrowSortFilled.js +1 -8
- package/components/SVGIcons/IconArrowSync.js +1 -8
- package/components/SVGIcons/IconArrowSyncFilled.js +1 -8
- package/components/SVGIcons/IconArrowUp.js +1 -8
- package/components/SVGIcons/IconArrowUpFilled.js +1 -8
- package/components/SVGIcons/IconArrowUpLeft.js +1 -8
- package/components/SVGIcons/IconArrowUpLeftFilled.js +1 -8
- package/components/SVGIcons/IconArrowUpRight.js +1 -8
- package/components/SVGIcons/IconArrowUpRightFilled.js +1 -8
- package/components/SVGIcons/IconAttach.js +1 -8
- package/components/SVGIcons/IconAttachFilled.js +1 -8
- package/components/SVGIcons/IconBeach.js +1 -8
- package/components/SVGIcons/IconBeachFilled.js +1 -8
- package/components/SVGIcons/IconBook.js +1 -8
- package/components/SVGIcons/IconBookFilled.js +1 -8
- package/components/SVGIcons/IconBookmark.js +1 -8
- package/components/SVGIcons/IconBookmarkFilled.js +1 -8
- package/components/SVGIcons/IconBriefcase.js +1 -8
- package/components/SVGIcons/IconBriefcaseFilled.js +1 -8
- package/components/SVGIcons/IconBudgetTransfer.js +7 -8
- package/components/SVGIcons/IconBuilding.js +7 -8
- package/components/SVGIcons/IconBuildingBank.js +1 -8
- package/components/SVGIcons/IconBuildingBankFilled.js +1 -8
- package/components/SVGIcons/IconBuildingFilled.js +1 -8
- package/components/SVGIcons/IconBulletListAdd.js +1 -8
- package/components/SVGIcons/IconBulletListAddFilled.js +1 -8
- package/components/SVGIcons/IconCalculator.js +1 -8
- package/components/SVGIcons/IconCalculatorFilled.js +1 -8
- package/components/SVGIcons/IconCalendarClock.js +1 -8
- package/components/SVGIcons/IconCalendarClockFilled.js +1 -8
- package/components/SVGIcons/IconCalendarDay.js +1 -8
- package/components/SVGIcons/IconCalendarDayFilled.js +1 -8
- package/components/SVGIcons/IconCalendarEmpty.js +1 -8
- package/components/SVGIcons/IconCalendarLeft.js +1 -8
- package/components/SVGIcons/IconCalendarLeftFilled.js +1 -8
- package/components/SVGIcons/IconCalendarRight.js +1 -8
- package/components/SVGIcons/IconCalendarRightFilled.js +1 -8
- package/components/SVGIcons/IconCall.js +1 -8
- package/components/SVGIcons/IconCallFilled.js +1 -8
- package/components/SVGIcons/IconCard.js +1 -8
- package/components/SVGIcons/IconCardFilled.js +1 -8
- package/components/SVGIcons/IconCaretDown.js +1 -8
- package/components/SVGIcons/IconCaretDownFilled.js +1 -8
- package/components/SVGIcons/IconCaretDownRight.js +1 -8
- package/components/SVGIcons/IconCaretDownRightFilled.js +1 -8
- package/components/SVGIcons/IconCaretLeft.js +1 -8
- package/components/SVGIcons/IconCaretLeftFilled.js +1 -8
- package/components/SVGIcons/IconCaretRight.js +1 -8
- package/components/SVGIcons/IconCaretRightFilled.js +1 -8
- package/components/SVGIcons/IconCaretUp.js +1 -8
- package/components/SVGIcons/IconCaretUpFilled.js +1 -8
- package/components/SVGIcons/IconChartPerson.js +1 -8
- package/components/SVGIcons/IconChartPersonFilled.js +1 -8
- package/components/SVGIcons/IconChat.js +1 -8
- package/components/SVGIcons/IconChatFilled.js +1 -8
- package/components/SVGIcons/IconChatMultiple.js +1 -8
- package/components/SVGIcons/IconChatMultipleFilled.js +1 -8
- package/components/SVGIcons/IconCheckboxArrowRight.js +1 -8
- package/components/SVGIcons/IconCheckboxArrowRightFilled.js +1 -8
- package/components/SVGIcons/IconCheckmark.js +1 -8
- package/components/SVGIcons/IconCheckmarkCircle.js +1 -8
- package/components/SVGIcons/IconCheckmarkCircleFilled.js +1 -8
- package/components/SVGIcons/IconCheckmarkFilled.js +1 -8
- package/components/SVGIcons/IconChevronDoubleLeft.js +1 -8
- package/components/SVGIcons/IconChevronDoubleRight.js +1 -8
- package/components/SVGIcons/IconChevronDown.js +1 -8
- package/components/SVGIcons/IconChevronDownFilled.js +1 -8
- package/components/SVGIcons/IconChevronLeft.js +1 -8
- package/components/SVGIcons/IconChevronLeftFilled.js +1 -8
- package/components/SVGIcons/IconChevronRight.js +1 -8
- package/components/SVGIcons/IconChevronRightFilled.js +1 -8
- package/components/SVGIcons/IconChevronUp.js +1 -8
- package/components/SVGIcons/IconChevronUpDown.js +1 -8
- package/components/SVGIcons/IconChevronUpDownFilled.js +1 -8
- package/components/SVGIcons/IconChevronUpFilled.js +1 -8
- package/components/SVGIcons/IconClipboardDay.js +1 -8
- package/components/SVGIcons/IconClock.js +1 -8
- package/components/SVGIcons/IconClockDismiss.js +1 -8
- package/components/SVGIcons/IconClockDismissFilled.js +1 -8
- package/components/SVGIcons/IconClockFilled.js +1 -8
- package/components/SVGIcons/IconComment.js +1 -8
- package/components/SVGIcons/IconCommentFilled.js +1 -8
- package/components/SVGIcons/IconContractCard.js +1 -8
- package/components/SVGIcons/IconContractCardFilled.js +1 -8
- package/components/SVGIcons/IconCopy.js +1 -8
- package/components/SVGIcons/IconCopyFilled.js +1 -8
- package/components/SVGIcons/IconCubeTree.js +1 -8
- package/components/SVGIcons/IconCubeTreeFilled.js +1 -8
- package/components/SVGIcons/IconDatabase.js +1 -8
- package/components/SVGIcons/IconDatabaseFilled.js +1 -8
- package/components/SVGIcons/IconDelete.js +1 -8
- package/components/SVGIcons/IconDeleteFilled.js +1 -8
- package/components/SVGIcons/IconDeviceMeetingRoom.js +1 -8
- package/components/SVGIcons/IconDeviceMeetingRoomFilled.js +1 -8
- package/components/SVGIcons/IconDismiss.js +1 -8
- package/components/SVGIcons/IconDismissCircle.js +1 -8
- package/components/SVGIcons/IconDismissCircleFilled.js +1 -8
- package/components/SVGIcons/IconDismissFilled.js +1 -8
- package/components/SVGIcons/IconDocument.js +1 -8
- package/components/SVGIcons/IconDocumentBulletList.js +1 -8
- package/components/SVGIcons/IconDocumentBulletListFilled.js +1 -8
- package/components/SVGIcons/IconDocumentEdit.js +1 -8
- package/components/SVGIcons/IconDocumentEditFilled.js +1 -8
- package/components/SVGIcons/IconDocumentFilled.js +1 -8
- package/components/SVGIcons/IconDocumentPerson.js +1 -8
- package/components/SVGIcons/IconEdit.js +1 -8
- package/components/SVGIcons/IconEditFilled.js +1 -8
- package/components/SVGIcons/IconErrorCircle.js +1 -8
- package/components/SVGIcons/IconErrorCircleFilled.js +1 -8
- package/components/SVGIcons/IconEur.js +1 -8
- package/components/SVGIcons/IconEurFilled.js +1 -8
- package/components/SVGIcons/IconExpandUpLeft.js +1 -8
- package/components/SVGIcons/IconExpandUpLeftFilled.js +1 -8
- package/components/SVGIcons/IconExpandUpRight.js +1 -8
- package/components/SVGIcons/IconExpandUpRightFilled.js +1 -8
- package/components/SVGIcons/IconEyeOff.js +1 -8
- package/components/SVGIcons/IconEyeOffFilled.js +1 -8
- package/components/SVGIcons/IconEyeOn.js +1 -8
- package/components/SVGIcons/IconEyeOnFilled.js +1 -8
- package/components/SVGIcons/IconFacebook.js +3 -8
- package/components/SVGIcons/IconFastAcceleration.js +1 -8
- package/components/SVGIcons/IconFastAccelerationFilled.js +1 -8
- package/components/SVGIcons/IconFeed.js +1 -8
- package/components/SVGIcons/IconFeedFilled.js +1 -8
- package/components/SVGIcons/IconFilter.js +1 -8
- package/components/SVGIcons/IconFilterFilled.js +1 -8
- package/components/SVGIcons/IconFlag.js +1 -8
- package/components/SVGIcons/IconFlagFilled.js +1 -8
- package/components/SVGIcons/IconFolderLink.js +1 -8
- package/components/SVGIcons/IconFolderLinkFilled.js +1 -8
- package/components/SVGIcons/IconFood.js +1 -8
- package/components/SVGIcons/IconFoodFilled.js +1 -8
- package/components/SVGIcons/IconGb.js +11 -8
- package/components/SVGIcons/IconGlobe.js +1 -8
- package/components/SVGIcons/IconGlobeFilled.js +1 -8
- package/components/SVGIcons/IconGoogle.js +3 -8
- package/components/SVGIcons/IconHandOpenHeart.js +1 -8
- package/components/SVGIcons/IconHandOpenHeartFilled.js +1 -8
- package/components/SVGIcons/IconHeart.js +1 -8
- package/components/SVGIcons/IconHeartFilled.js +1 -8
- package/components/SVGIcons/IconHistory.js +1 -8
- package/components/SVGIcons/IconHistoryFilled.js +1 -8
- package/components/SVGIcons/IconHome.js +1 -8
- package/components/SVGIcons/IconHomeFilled.js +1 -8
- package/components/SVGIcons/IconImage.js +1 -8
- package/components/SVGIcons/IconImageFilled.js +1 -8
- package/components/SVGIcons/IconInfo.js +1 -8
- package/components/SVGIcons/IconInfoFilled.js +1 -8
- package/components/SVGIcons/IconInstagram.js +4 -8
- package/components/SVGIcons/IconKeyReset.js +1 -8
- package/components/SVGIcons/IconKeyResetFilled.js +1 -8
- package/components/SVGIcons/IconLibrary.js +1 -8
- package/components/SVGIcons/IconLibraryFilled.js +1 -8
- package/components/SVGIcons/IconLink.js +1 -8
- package/components/SVGIcons/IconLinkFilled.js +1 -8
- package/components/SVGIcons/IconLinkedin.js +1 -8
- package/components/SVGIcons/IconList.js +1 -8
- package/components/SVGIcons/IconListFilled.js +1 -8
- package/components/SVGIcons/IconLocation.js +1 -8
- package/components/SVGIcons/IconLocationFilled.js +1 -8
- package/components/SVGIcons/IconLockClosed.js +1 -8
- package/components/SVGIcons/IconLockClosedFilled.js +1 -8
- package/components/SVGIcons/IconLockOpen.js +1 -8
- package/components/SVGIcons/IconLockOpenFilled.js +1 -8
- package/components/SVGIcons/IconMail.js +1 -8
- package/components/SVGIcons/IconMailAdd.js +1 -8
- package/components/SVGIcons/IconMailAddFilled.js +1 -8
- package/components/SVGIcons/IconMailArrowForward.js +1 -8
- package/components/SVGIcons/IconMailArrowForwardFilled.js +1 -8
- package/components/SVGIcons/IconMailFilled.js +1 -8
- package/components/SVGIcons/IconMailLink.js +1 -8
- package/components/SVGIcons/IconMailLinkFilled.js +1 -8
- package/components/SVGIcons/IconMedium.js +1 -8
- package/components/SVGIcons/IconMoon.js +1 -8
- package/components/SVGIcons/IconMore.js +1 -8
- package/components/SVGIcons/IconMoreFilled.js +1 -8
- package/components/SVGIcons/IconMoreVertical.js +1 -8
- package/components/SVGIcons/IconMoreVerticalFilled.js +1 -8
- package/components/SVGIcons/IconNavigation.js +1 -8
- package/components/SVGIcons/IconNavigationFilled.js +1 -8
- package/components/SVGIcons/IconNotebook.js +1 -8
- package/components/SVGIcons/IconNotebookAdd.js +7 -8
- package/components/SVGIcons/IconNotebookAddFilled.js +6 -8
- package/components/SVGIcons/IconNotebookFilled.js +1 -8
- package/components/SVGIcons/IconOnlyEmployee.js +1 -8
- package/components/SVGIcons/IconOpen.js +1 -8
- package/components/SVGIcons/IconOpenFilled.js +1 -8
- package/components/SVGIcons/IconPatient.js +1 -8
- package/components/SVGIcons/IconPatientFilled.js +1 -8
- package/components/SVGIcons/IconPeople.js +1 -8
- package/components/SVGIcons/IconPeopleAdd.js +1 -8
- package/components/SVGIcons/IconPeopleAddFilled.js +1 -8
- package/components/SVGIcons/IconPeopleFilled.js +1 -8
- package/components/SVGIcons/IconPeopleList.js +1 -8
- package/components/SVGIcons/IconPeopleListFilled.js +1 -8
- package/components/SVGIcons/IconPeopleTeam.js +1 -8
- package/components/SVGIcons/IconPeopleTeamFilled.js +1 -8
- package/components/SVGIcons/IconPercent.js +1 -8
- package/components/SVGIcons/IconPerson.js +1 -8
- package/components/SVGIcons/IconPersonAccount.js +1 -8
- package/components/SVGIcons/IconPersonAccountFilled.js +1 -8
- package/components/SVGIcons/IconPersonAdd.js +1 -8
- package/components/SVGIcons/IconPersonAddFilled.js +1 -8
- package/components/SVGIcons/IconPersonArrowLeft.js +1 -8
- package/components/SVGIcons/IconPersonArrowLeftFilled.js +1 -8
- package/components/SVGIcons/IconPersonArrowRight.js +1 -8
- package/components/SVGIcons/IconPersonArrowRightFilled.js +1 -8
- package/components/SVGIcons/IconPersonBoard.js +1 -8
- package/components/SVGIcons/IconPersonFilled.js +1 -8
- package/components/SVGIcons/IconPersonMinus.js +1 -8
- package/components/SVGIcons/IconPersonStar.js +1 -8
- package/components/SVGIcons/IconPersonStarFilled.js +1 -8
- package/components/SVGIcons/IconPersonSubtract.js +1 -8
- package/components/SVGIcons/IconPersonSubtractFilled.js +1 -8
- package/components/SVGIcons/IconPhone.js +1 -8
- package/components/SVGIcons/IconPhoneFilled.js +1 -8
- package/components/SVGIcons/IconPlugConnected.js +1 -8
- package/components/SVGIcons/IconPos.js +1 -8
- package/components/SVGIcons/IconPosFilled.js +1 -8
- package/components/SVGIcons/IconProhibited.js +1 -8
- package/components/SVGIcons/IconProhibitedFilled.js +1 -8
- package/components/SVGIcons/IconProjectProduct.js +1 -8
- package/components/SVGIcons/IconQuestion.js +1 -8
- package/components/SVGIcons/IconQuestionFilled.js +1 -8
- package/components/SVGIcons/IconRedo.js +1 -8
- package/components/SVGIcons/IconRedoFilled.js +1 -8
- package/components/SVGIcons/IconRibbon.js +1 -8
- package/components/SVGIcons/IconRu.js +6 -8
- package/components/SVGIcons/IconRub.js +1 -8
- package/components/SVGIcons/IconRubFilled.js +1 -8
- package/components/SVGIcons/IconSave.js +1 -8
- package/components/SVGIcons/IconSaveFilled.js +1 -8
- package/components/SVGIcons/IconSavings.js +1 -8
- package/components/SVGIcons/IconSavingsFilled.js +1 -8
- package/components/SVGIcons/IconSearch.js +1 -8
- package/components/SVGIcons/IconSearchFilled.js +1 -8
- package/components/SVGIcons/IconSelectAllOff.js +1 -8
- package/components/SVGIcons/IconSelectAllOffFilled.js +1 -8
- package/components/SVGIcons/IconSelectAllOn.js +1 -8
- package/components/SVGIcons/IconSelectAllOnFilled.js +1 -8
- package/components/SVGIcons/IconSend.js +1 -8
- package/components/SVGIcons/IconSendFilled.js +1 -8
- package/components/SVGIcons/IconSettings.js +1 -8
- package/components/SVGIcons/IconSettingsFilled.js +1 -8
- package/components/SVGIcons/IconShare.js +1 -8
- package/components/SVGIcons/IconShareAndroid.js +1 -8
- package/components/SVGIcons/IconShareAndroidFilled.js +1 -8
- package/components/SVGIcons/IconShareFilled.js +1 -8
- package/components/SVGIcons/IconSignOut.js +1 -8
- package/components/SVGIcons/IconSignOutFilled.js +1 -8
- package/components/SVGIcons/IconSpinner.js +1 -8
- package/components/SVGIcons/IconSpinnerFilled.js +1 -8
- package/components/SVGIcons/IconStatus.js +1 -8
- package/components/SVGIcons/IconStatusFilled.js +1 -8
- package/components/SVGIcons/IconSubtract.js +1 -8
- package/components/SVGIcons/IconSubtractCircle.js +1 -8
- package/components/SVGIcons/IconSubtractCircleFilled.js +1 -8
- package/components/SVGIcons/IconSubtractFilled.js +1 -8
- package/components/SVGIcons/IconSun.js +10 -8
- package/components/SVGIcons/IconTableCellEdit.js +3 -8
- package/components/SVGIcons/IconTableCellEditFilled.js +5 -8
- package/components/SVGIcons/IconTelegram.js +3 -8
- package/components/SVGIcons/IconTimer.js +1 -8
- package/components/SVGIcons/IconTimerFilled.js +1 -8
- package/components/SVGIcons/IconTrophy.js +1 -8
- package/components/SVGIcons/IconTrophyFilled.js +1 -8
- package/components/SVGIcons/IconTwitter.js +1 -8
- package/components/SVGIcons/IconUndo.js +1 -8
- package/components/SVGIcons/IconUndoFilled.js +1 -8
- package/components/SVGIcons/IconUnitsEmployee.js +1 -8
- package/components/SVGIcons/IconUpload.js +1 -8
- package/components/SVGIcons/IconUs.js +11 -8
- package/components/SVGIcons/IconUsd.js +1 -8
- package/components/SVGIcons/IconUsdFilled.js +1 -8
- package/components/SVGIcons/IconUserMinus.js +1 -8
- package/components/SVGIcons/IconVacation.js +1 -8
- package/components/SVGIcons/IconVideo.js +1 -8
- package/components/SVGIcons/IconVideoFilled.js +1 -8
- package/components/SVGIcons/IconWallet.js +1 -8
- package/components/SVGIcons/IconWalletFilled.js +1 -8
- package/components/SVGIcons/IconWarning.js +1 -8
- package/components/SVGIcons/IconWarningFilled.js +1 -8
- package/components/SVGIcons/IconYoutube.js +1 -8
- package/components/Select/ButtonSelect/ButtonSelect.js +3 -45
- package/components/Select/FilterSelect/FilterDropdown.js +3 -15
- package/components/Select/FilterSelect/FilterGroupDropdown.js +4 -19
- package/components/Select/FilterSelect/FilterSelect.js +4 -72
- package/components/Select/MultiSelect/DesktopWrapper.js +1 -19
- package/components/Select/MultiSelect/MobileWrapper.js +2 -13
- package/components/Select/MultiSelect/MultiBase/MultiBase.js +5 -121
- package/components/Select/MultiSelect/MultiSelect.js +3 -68
- package/components/Select/MultiSelect/MultiSelectGrouped/MultiSelectGrouped.js +7 -96
- package/components/Select/MultiSelect/MultiSelectWithTabs/MultiSelectWithTabs.js +7 -71
- package/components/Select/MultiSelect/OptionsWrapper.js +1 -66
- package/components/Select/NestedSelect/NestedSelect.js +4 -58
- package/components/Select/ProfileDropdown/index.js +10 -13
- package/components/Select/Select/Select.js +1 -129
- package/components/Select/Select/SelectDesktop/index.js +2 -81
- package/components/Select/Select/SelectMobile/MobileTopContent.d.ts +2 -1
- package/components/Select/Select/SelectMobile/MobileTopContent.js +2 -18
- package/components/Select/Select/SelectMobile/index.js +5 -38
- package/components/Select/Select/helpers.js +1 -20
- package/components/Select/SharedComponents/Actions.js +3 -14
- package/components/Select/SharedComponents/ButtonSelectWrapper/Button/Button.js +3 -9
- package/components/Select/SharedComponents/ButtonSelectWrapper/ButtonSelectWrapper.js +3 -29
- package/components/Select/SharedComponents/ContentTop.js +3 -73
- package/components/Select/SharedComponents/Footer.js +6 -12
- package/components/Select/SharedComponents/InputSelectWrapper/InputSelectWrapper.js +3 -52
- package/components/Select/SharedComponents/Loading.js +2 -6
- package/components/Select/SharedComponents/index.js +1 -6
- package/components/Select/constants.js +1 -7
- package/components/Select/helper.js +0 -1
- package/components/Select/index.js +1 -6
- package/components/Select/localization.js +1 -29
- package/components/Select/types.js +0 -1
- package/components/SideSheet/Footer/Footer.js +5 -15
- package/components/SideSheet/SideSheet.js +8 -58
- package/components/SideSheet/index.js +1 -1
- package/components/SideSheet/types.js +0 -1
- package/components/Snackbar/Snackbar.js +5 -30
- package/components/Snackbar/consts.js +1 -14
- package/components/Snackbar/index.js +1 -1
- package/components/Snackbar/types.js +0 -1
- package/components/Status/Status.js +4 -18
- package/components/Status/index.js +1 -1
- package/components/Status/types.js +0 -1
- package/components/Stepper/Stepper.js +2 -29
- package/components/Stepper/index.js +1 -1
- package/components/Stepper/types.js +0 -1
- package/components/Switcher/Switcher.js +5 -22
- package/components/Switcher/index.js +1 -1
- package/components/Switcher/types.js +0 -1
- package/components/Tab/Tab.js +2 -20
- package/components/Tab/TabItem.js +3 -13
- package/components/Tab/index.js +1 -1
- package/components/Tab/types.js +0 -1
- package/components/Table/Header.js +4 -34
- package/components/Table/IndeterminateCheckbox.js +1 -15
- package/components/Table/Row.js +3 -35
- package/components/Table/Table.js +6 -74
- package/components/Table/index.js +1 -1
- package/components/Table/localization.js +1 -11
- package/components/Table/types.js +0 -1
- package/components/Table/utils.js +3 -38
- package/components/TableV2/AdvancedPagination.js +12 -62
- package/components/TableV2/ColumnHeader.js +6 -32
- package/components/TableV2/ColumnSettings.js +8 -33
- package/components/TableV2/IndeterminateCheckbox.js +2 -16
- package/components/TableV2/Table.js +8 -123
- package/components/TableV2/constants/index.js +1 -27
- package/components/TableV2/hooks/useTableColumnSettings.js +1 -17
- package/components/TableV2/hooks/useTableControl.js +1 -186
- package/components/TableV2/index.js +1 -3
- package/components/TableV2/loadTableSettings.js +1 -9
- package/components/TableV2/types.js +0 -1
- package/components/Text/Text.js +2 -7
- package/components/Text/index.js +1 -1
- package/components/Text/types.js +0 -1
- package/components/Textarea/Textarea.js +6 -41
- package/components/Textarea/index.js +1 -1
- package/components/Textarea/types.js +0 -1
- package/components/Tooltip/Tooltip.js +2 -54
- package/components/Tooltip/index.js +1 -1
- package/components/Tooltip/types.js +1 -11
- package/components/UnderConstruction/UnderConstruction.js +6 -11
- package/components/UnderConstruction/index.js +1 -1
- package/components/UnderConstruction/localization.js +1 -14
- package/components/UnderConstruction/types.js +0 -1
- package/consts/index.js +1 -107
- package/context/FormContextProvider.js +1 -6
- package/context/index.js +1 -2
- package/context/types.js +1 -8
- package/helperComponents/AnimatePresenceWrapper/AnimatePresenceWrapper.js +2 -7
- package/helperComponents/AnimatePresenceWrapper/index.js +1 -1
- package/helperComponents/CodeBlock/CodeBlock.js +2 -4
- package/helperComponents/CodeBlock/index.js +1 -1
- package/helperComponents/ErrorMessage/ErrorMessage.js +3 -9
- package/helperComponents/ErrorMessage/consts.js +1 -4
- package/helperComponents/ErrorMessage/index.js +1 -1
- package/helperComponents/ErrorMessage/types.js +0 -1
- package/helperComponents/GoToWebPage/GoToWebPage.js +1 -6
- package/helperComponents/IconDynamicComponent/IconDynamicComponent.js +1 -19
- package/helperComponents/IconDynamicComponent/index.js +1 -1
- package/helperComponents/Label/Label.js +1 -9
- package/helperComponents/Label/index.js +1 -1
- package/helperComponents/Label/types.js +0 -1
- package/helperComponents/Loader/Loader.js +2 -5
- package/helperComponents/Loader/index.js +1 -1
- package/helperComponents/Loader/types.js +0 -1
- package/helperComponents/OptionItem/OptionItem.js +5 -29
- package/helperComponents/OptionItem/index.js +1 -1
- package/helperComponents/OptionItem/types.js +0 -1
- package/helpers/check-authorization.js +1 -60
- package/helpers/current-week-work-days-range.js +1 -9
- package/helpers/download-file.js +1 -8
- package/helpers/format-date.js +1 -21
- package/helpers/get-module-prefix.js +1 -4
- package/helpers/index.js +1 -8
- package/helpers/isDeepEqual.js +1 -12
- package/helpers/locale.js +1 -12
- package/helpers/logout.js +1 -8
- package/helpers/storage.js +1 -19
- package/hooks/index.js +1 -12
- package/hooks/useAnimation.js +1 -33
- package/hooks/useChangePositionsOnScroll.js +1 -30
- package/hooks/useDispatchEventOnScroll.js +1 -9
- package/hooks/useEscapeKey.js +1 -16
- package/hooks/useFieldArray.js +1 -1
- package/hooks/useFormContext.js +1 -5
- package/hooks/useFormProps.js +1 -5
- package/hooks/useGetElemPositions.js +1 -17
- package/hooks/useGetElemSizes.js +1 -14
- package/hooks/useGetHasBottomSpace.js +1 -15
- package/hooks/useGetIsMobile.js +1 -37
- package/hooks/useGetTooltipPosition.js +1 -69
- package/hooks/useGetTooltipStyles.js +1 -47
- package/hooks/useHideBodyScroll.js +1 -26
- package/hooks/useHideOnScroll.js +1 -22
- package/hooks/useOnOutsideClick.js +1 -39
- package/hooks/useScreenSize.js +1 -28
- package/package.json +1 -1
- package/type/file-upload.js +1 -6
- package/type/index.js +1 -5
- package/type/locale.js +1 -12
- package/type/notification.js +1 -7
- package/type/status-code.js +1 -7
- package/type/svg-icons.js +0 -1
- package/utils/helpers.js +1 -83
|
@@ -1,90 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
13
|
-
// @ts-nocheck
|
|
14
|
-
import { forwardRef, useEffect, useState } from 'react';
|
|
15
|
-
import DatePicker from 'react-datepicker';
|
|
16
|
-
import { Input } from '../../Input';
|
|
17
|
-
import { DateFormat } from '../types';
|
|
18
|
-
import { useImportFilesDynamically } from '../hooks';
|
|
19
|
-
import { isSameDay } from '../../../utils/helpers';
|
|
20
|
-
import IconCalendarRight from '../../SVGIcons/IconCalendarRight';
|
|
21
|
-
import { Modal } from '../../Modal';
|
|
22
|
-
import { CustomHeader } from '../CustomHeader/CustomHeader';
|
|
23
|
-
import { formatDate } from '../../../helpers';
|
|
24
|
-
export const RangeDatePickerMobile = forwardRef((props, _ref) => {
|
|
25
|
-
const { value, currentDates = [], setFieldValue, name, changeHandler, dataId, format = DateFormat.LongDate, maxDate, minDate, locale = 'hy', disabled, placeholderText, dataIdPrefix, modalOptions } = props, rest = __rest(props, ["value", "currentDates", "setFieldValue", "name", "changeHandler", "dataId", "format", "maxDate", "minDate", "locale", "disabled", "placeholderText", "dataIdPrefix", "modalOptions"]);
|
|
26
|
-
useImportFilesDynamically(locale);
|
|
27
|
-
const startYear = minDate ? minDate.getFullYear() : 1900;
|
|
28
|
-
const endYear = maxDate ? maxDate.getFullYear() : new Date().getFullYear() + 5;
|
|
29
|
-
const dateInitialValue = value !== undefined && Array.isArray(value) ? value : currentDates;
|
|
30
|
-
const [rangeArray, setRangeDate] = useState(dateInitialValue);
|
|
31
|
-
const [isCalendarOpen, setIsCalendarOpen] = useState(false);
|
|
32
|
-
const [isApplied, setIsApplied] = useState(false);
|
|
33
|
-
const onChange = (date) => {
|
|
34
|
-
if (date && Array.isArray(date)) {
|
|
35
|
-
setRangeDate(date);
|
|
36
|
-
}
|
|
37
|
-
};
|
|
38
|
-
useEffect(() => {
|
|
39
|
-
setRangeDate(dateInitialValue);
|
|
40
|
-
}, [dateInitialValue]);
|
|
41
|
-
if (!Array.isArray(rangeArray)) {
|
|
42
|
-
return null;
|
|
43
|
-
}
|
|
44
|
-
const checkRange = () => {
|
|
45
|
-
const [startDate, endDate] = rangeArray;
|
|
46
|
-
if (!startDate || !endDate) {
|
|
47
|
-
onChange([null, null]);
|
|
48
|
-
}
|
|
49
|
-
};
|
|
50
|
-
const renderCurrentSelectedDate = (rangeArray) => {
|
|
51
|
-
if (isCalendarOpen && !isApplied) {
|
|
52
|
-
return;
|
|
53
|
-
}
|
|
54
|
-
const [startDate, endDate] = rangeArray;
|
|
55
|
-
const startDateFormatted = formatDate(startDate, format);
|
|
56
|
-
const endDateFormatted = formatDate(endDate, format);
|
|
57
|
-
if (isSameDay(startDate, endDate) || !endDate) {
|
|
58
|
-
return startDateFormatted;
|
|
59
|
-
}
|
|
60
|
-
return `${startDateFormatted} - ${endDateFormatted}`;
|
|
61
|
-
};
|
|
62
|
-
const openDatepicker = () => {
|
|
63
|
-
setIsCalendarOpen(true);
|
|
64
|
-
};
|
|
65
|
-
const closeDatepicker = () => {
|
|
66
|
-
setIsCalendarOpen(false);
|
|
67
|
-
};
|
|
68
|
-
const onApply = () => {
|
|
69
|
-
if (changeHandler) {
|
|
70
|
-
changeHandler(rangeArray);
|
|
71
|
-
}
|
|
72
|
-
if (setFieldValue && name) {
|
|
73
|
-
setFieldValue(name, rangeArray);
|
|
74
|
-
}
|
|
75
|
-
setIsApplied(true);
|
|
76
|
-
closeDatepicker();
|
|
77
|
-
};
|
|
78
|
-
const [startDate, endDate] = rangeArray;
|
|
79
|
-
return (_jsxs(_Fragment, { children: [_jsx(Input, { readOnly: true, onClick: openDatepicker, dataId: dataId, disabled: disabled, placeholder: placeholderText, currentValue: renderCurrentSelectedDate(rangeArray), rightIconProps: { Component: IconCalendarRight, onClick: openDatepicker } }), _jsxs(Modal, { isOpen: isCalendarOpen, title: modalOptions === null || modalOptions === void 0 ? void 0 : modalOptions.title, onClose: closeDatepicker, buttonProps: {
|
|
80
|
-
confirm: {
|
|
81
|
-
buttonText: modalOptions === null || modalOptions === void 0 ? void 0 : modalOptions.btnConfirmText,
|
|
82
|
-
onClick: onApply
|
|
83
|
-
},
|
|
84
|
-
cancel: {
|
|
85
|
-
buttonText: modalOptions === null || modalOptions === void 0 ? void 0 : modalOptions.btnCancelText,
|
|
86
|
-
onClick: closeDatepicker
|
|
87
|
-
}
|
|
88
|
-
}, closeIcon: true, children: [_jsxs("div", { className: "flexbox justify-content--between mb-16 gap-16", children: [_jsx(Input, { readOnly: true, value: formatDate(startDate, format) }), _jsx(Input, { readOnly: true, value: formatDate(endDate, format) })] }), _jsx(DatePicker, Object.assign({}, rest, { inline: true, locale: locale, minDate: minDate, maxDate: maxDate, startDate: startDate, endDate: endDate, selectsRange: true, disabled: disabled, onChange: onChange, onClickOutside: checkRange, renderCustomHeader: (props) => (_jsx(CustomHeader, Object.assign({}, props, { locale: locale, startYear: startYear, endYear: endYear, dataPrefix: dataIdPrefix, isMobile: true }))) }))] })] }));
|
|
89
|
-
});
|
|
90
|
-
RangeDatePickerMobile.displayName = 'RangeDatePickerMobile';
|
|
1
|
+
import{jsxs as f,Fragment as q,jsx as a}from"react/jsx-runtime";import{forwardRef as z,useState as D,useEffect as B}from"react";import G from"react-datepicker";import{Input as y}from"../../Input/Input.js";import{DateFormat as J}from"../types.js";import{useImportFilesDynamically as K}from"../hooks.js";import{isSameDay as Q}from"../../../utils/helpers.js";import U from"../../SVGIcons/IconCalendarRight.js";import{Modal as W}from"../../Modal/Modal.js";import"classnames";import"../../../consts/index.js";import"../../../context/types.js";import"../../../hooks/useScreenSize.js";import"react-hook-form";import"react-dom";import{CustomHeader as X}from"../CustomHeader/CustomHeader.js";import{formatDate as i}from"../../../helpers/format-date.js";import"react-toastify";import"../../Snackbar/consts.js";const Z=z((e,t)=>{const{value:r,currentDates:o=[],setFieldValue:s,name:n,changeHandler:l,dataId:m,format:c=J.LongDate,maxDate:d,minDate:p,locale:u="hy",disabled:x,placeholderText:j,dataIdPrefix:b,modalOptions:h,...C}=e;K(u);const g=p?p.getFullYear():1900,k=d?d.getFullYear():/* @__PURE__ */(new Date).getFullYear()+5,I=void 0!==r&&Array.isArray(r)?r:o,[v,F]=D(I),[A,M]=D(!1),[O,P]=D(!1),S=e=>{e&&Array.isArray(e)&&F(e)};if(B(()=>{F(I)},[I]),!Array.isArray(v))return null;const H=()=>{M(!0)},R=()=>{M(!1)},[T,Y]=v;/* @__PURE__ */
|
|
2
|
+
return f(q,{children:[
|
|
3
|
+
/* @__PURE__ */a(y,{readOnly:!0,onClick:H,dataId:m,disabled:x,placeholder:j,currentValue:(e=>{if(A&&!O)return;const[a,t]=e,r=i(a,c),o=i(t,c);return Q(a,t)||!t?r:`${r} - ${o}`})(v),rightIconProps:{Component:U,onClick:H}}),
|
|
4
|
+
/* @__PURE__ */f(W,{isOpen:A,title:null==h?void 0:h.title,onClose:R,buttonProps:{confirm:{buttonText:null==h?void 0:h.btnConfirmText,onClick:()=>{l&&l(v),s&&n&&s(n,v),P(!0),R()}},cancel:{buttonText:null==h?void 0:h.btnCancelText,onClick:R}},closeIcon:!0,children:[
|
|
5
|
+
/* @__PURE__ */f("div",{className:"flexbox justify-content--between mb-16 gap-16",children:[
|
|
6
|
+
/* @__PURE__ */a(y,{readOnly:!0,value:i(T,c)}),
|
|
7
|
+
/* @__PURE__ */a(y,{readOnly:!0,value:i(Y,c)})]}),
|
|
8
|
+
/* @__PURE__ */a(G,{...C,inline:!0,locale:u,minDate:p,maxDate:d,startDate:T,endDate:Y,selectsRange:!0,disabled:x,onChange:S,onClickOutside:()=>{const[e,a]=v;(!e||!a)&&S([null,null])},renderCustomHeader:e=>/* @__PURE__ */a(X,{...e,locale:u,startYear:g,endYear:k,dataPrefix:b,isMobile:!0})})]})]})});Z.displayName="RangeDatePickerMobile";export{Z as RangeDatePickerMobile};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import{RangeDatePicker as a}from"./RangeDatePicker.js";export{a as RangeDatePicker};
|
|
@@ -1,10 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { forwardRef } from 'react';
|
|
3
|
-
import { SimpleDatePickerDesktop } from './SimpleDatePickerDesktop';
|
|
4
|
-
import { useIsMobile } from '../../../hooks/useGetIsMobile';
|
|
5
|
-
import { SimpleDatePickerMobile } from './SimpleDatePickerMobile';
|
|
6
|
-
export const SimpleDatePicker = forwardRef((props, _ref) => {
|
|
7
|
-
const isMobile = useIsMobile();
|
|
8
|
-
return isMobile ? _jsx(SimpleDatePickerMobile, Object.assign({}, props)) : _jsx(SimpleDatePickerDesktop, Object.assign({}, props));
|
|
9
|
-
});
|
|
10
|
-
SimpleDatePicker.displayName = 'SimpleDatePicker';
|
|
1
|
+
import{jsx as i}from"react/jsx-runtime";import{forwardRef as r}from"react";import{SimpleDatePickerDesktop as o}from"./SimpleDatePickerDesktop.js";import{useIsMobile as m}from"../../../hooks/useGetIsMobile.js";import{SimpleDatePickerMobile as t}from"./SimpleDatePickerMobile.js";const p=r((e,r)=>m()?/* @__PURE__ */i(t,{...e}):/* @__PURE__ */i(o,{...e}));p.displayName="SimpleDatePicker";export{p as SimpleDatePicker};
|
|
@@ -1,48 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
-
t[p[i]] = s[p[i]];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
import { useRef } from 'react';
|
|
14
|
-
import dayjs from 'dayjs';
|
|
15
|
-
import DatePicker from 'react-datepicker';
|
|
16
|
-
import { Input } from '../../Input';
|
|
17
|
-
import { Label } from '../../../helperComponents/Label';
|
|
18
|
-
import { CustomHeader } from '../CustomHeader/CustomHeader';
|
|
19
|
-
import { useImportFilesDynamically } from '../hooks';
|
|
20
|
-
import IconCalendarRight from '../../SVGIcons/IconCalendarRight';
|
|
21
|
-
export const SimpleDatePickerDesktop = (props) => {
|
|
22
|
-
const { value, currentDate, setFieldValue, name, label, size, locale = 'hy', changeHandler, format = 'M/D/YYYY', required = false, dataId, hasError, placeholderText, minDate, maxDate, dataIdPrefix, helperText, inline } = props, rest = __rest(props, ["value", "currentDate", "setFieldValue", "name", "label", "size", "locale", "changeHandler", "format", "required", "dataId", "hasError", "placeholderText", "minDate", "maxDate", "dataIdPrefix", "helperText", "inline"]);
|
|
23
|
-
const startYear = minDate ? minDate.getFullYear() : 1900;
|
|
24
|
-
const endYear = maxDate ? maxDate.getFullYear() : new Date().getFullYear() + 5;
|
|
25
|
-
const calendarRef = useRef(null);
|
|
26
|
-
useImportFilesDynamically(locale);
|
|
27
|
-
const selectedDate = value !== undefined && Object.prototype.toString.call(value) === '[object Date]'
|
|
28
|
-
? value
|
|
29
|
-
: currentDate;
|
|
30
|
-
const openDatepicker = () => {
|
|
31
|
-
var _a, _b;
|
|
32
|
-
if (calendarRef.current) {
|
|
33
|
-
const isOpen = (_a = calendarRef.current) === null || _a === void 0 ? void 0 : _a.isCalendarOpen();
|
|
34
|
-
(_b = calendarRef.current) === null || _b === void 0 ? void 0 : _b.setOpen(!isOpen);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
const onChange = (date) => {
|
|
38
|
-
if (setFieldValue && name) {
|
|
39
|
-
setFieldValue(name, date);
|
|
40
|
-
}
|
|
41
|
-
if (changeHandler) {
|
|
42
|
-
changeHandler(date);
|
|
43
|
-
}
|
|
44
|
-
};
|
|
45
|
-
return (_jsxs("div", { className: "picker-container", children: [_jsx(Label, { text: label, required: required, invalid: hasError }), _jsx(DatePicker, Object.assign({ minDate: minDate, maxDate: maxDate, selected: dayjs(selectedDate).isValid() ? selectedDate : null, locale: locale,
|
|
46
|
-
// @ts-ignore
|
|
47
|
-
ref: calendarRef, customInput: _jsx(Input, { size: size, dataId: dataId, helperText: helperText, datePlaceHolderText: label ? '' : placeholderText, rightIconProps: { Component: IconCalendarRight, onClick: openDatepicker }, currentValue: selectedDate ? dayjs(selectedDate.toString()).format(format) : '' }), inline: inline }, rest, { onChange: onChange, renderCustomHeader: (props) => (_jsx(CustomHeader, Object.assign({}, props, { locale: locale, startYear: startYear, endYear: endYear, dataPrefix: dataIdPrefix }))) }))] }));
|
|
48
|
-
};
|
|
1
|
+
import{jsxs as R,jsx as a}from"react/jsx-runtime";import{useRef as S}from"react";import u from"dayjs";import T from"react-datepicker";import{Input as V}from"../../Input/Input.js";import{Label as q}from"../../../helperComponents/Label/Label.js";import{CustomHeader as w}from"../CustomHeader/CustomHeader.js";import{useImportFilesDynamically as z}from"../hooks.js";import E from"../../SVGIcons/IconCalendarRight.js";const U=e=>{const{value:r,currentDate:t,setFieldValue:o,name:l,label:n,size:s,locale:i="hy",changeHandler:m,format:c="M/D/YYYY",required:d=!1,dataId:p,hasError:f,placeholderText:x,minDate:h,maxDate:j,dataIdPrefix:D,helperText:I,inline:C,...g}=e,Y=h?h.getFullYear():1900,b=j?j.getFullYear():/* @__PURE__ */(new Date).getFullYear()+5,k=S(null);z(i);const v=void 0!==r&&"[object Date]"===Object.prototype.toString.call(r)?r:t;/* @__PURE__ */
|
|
2
|
+
return R("div",{className:"picker-container",children:[
|
|
3
|
+
/* @__PURE__ */a(q,{text:n,required:d,invalid:f}),
|
|
4
|
+
/* @__PURE__ */a(T,{minDate:h,maxDate:j,selected:u(v).isValid()?v:null,locale:i,ref:k,customInput:/* @__PURE__ */a(V,{size:s,dataId:p,helperText:I,datePlaceHolderText:n?"":x,rightIconProps:{Component:E,onClick:()=>{var e,a;if(k.current){const r=null==(e=k.current)?void 0:e.isCalendarOpen();null==(a=k.current)||a.setOpen(!r)}}},currentValue:v?u(v.toString()).format(c):""}),inline:C,...g,onChange:e=>{o&&l&&o(l,e),m&&m(e)},renderCustomHeader:e=>/* @__PURE__ */a(w,{...e,locale:i,startYear:Y,endYear:b,dataPrefix:D})})]})};export{U as SimpleDatePickerDesktop};
|
|
@@ -1,48 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
-
t[p[i]] = s[p[i]];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
// @ts-nocheck
|
|
14
|
-
import React from 'react';
|
|
15
|
-
import { Input } from '../../Input';
|
|
16
|
-
import IconCalendarRight from '../../SVGIcons/IconCalendarRight';
|
|
17
|
-
import dayjs from 'dayjs';
|
|
18
|
-
import { useImportFilesDynamically } from '../hooks';
|
|
19
|
-
import { Modal } from '../../Modal';
|
|
20
|
-
import { CustomHeader } from '../CustomHeader/CustomHeader';
|
|
21
|
-
import DatePicker from 'react-datepicker';
|
|
22
|
-
import { Label } from '../../../helperComponents/Label';
|
|
23
|
-
export const SimpleDatePickerMobile = (props) => {
|
|
24
|
-
const { size, dataId, helperText, label, placeholderText, format = 'M/D/YYYY', value, currentDate, minDate, maxDate, locale = 'hy', dataIdPrefix, modalOptions, name, changeHandler, setFieldValue, required, hasError } = props, rest = __rest(props, ["size", "dataId", "helperText", "label", "placeholderText", "format", "value", "currentDate", "minDate", "maxDate", "locale", "dataIdPrefix", "modalOptions", "name", "changeHandler", "setFieldValue", "required", "hasError"]);
|
|
25
|
-
const startYear = minDate ? minDate.getFullYear() : 1900;
|
|
26
|
-
const endYear = maxDate ? maxDate.getFullYear() : new Date().getFullYear() + 5;
|
|
27
|
-
const [isCalendarOpen, setIsCalendarOpen] = React.useState(false);
|
|
28
|
-
useImportFilesDynamically(locale);
|
|
29
|
-
const selectedDate = value !== undefined && Object.prototype.toString.call(value) === '[object Date]'
|
|
30
|
-
? value
|
|
31
|
-
: currentDate;
|
|
32
|
-
const openDatepicker = () => {
|
|
33
|
-
setIsCalendarOpen(true);
|
|
34
|
-
};
|
|
35
|
-
const closeDatepicker = () => {
|
|
36
|
-
setIsCalendarOpen(false);
|
|
37
|
-
};
|
|
38
|
-
const onChange = (date) => {
|
|
39
|
-
if (setFieldValue && name) {
|
|
40
|
-
setFieldValue(name, date);
|
|
41
|
-
}
|
|
42
|
-
if (changeHandler) {
|
|
43
|
-
changeHandler(date);
|
|
44
|
-
}
|
|
45
|
-
closeDatepicker();
|
|
46
|
-
};
|
|
47
|
-
return (_jsxs(_Fragment, { children: [_jsx(Label, { text: label, required: required, invalid: hasError }), _jsx(Input, { size: size, onClick: openDatepicker, dataId: dataId, readOnly: true, helperText: helperText, datePlaceHolderText: label ? '' : placeholderText, rightIconProps: { Component: IconCalendarRight, onClick: openDatepicker }, currentValue: selectedDate ? dayjs(selectedDate.toString()).format(format) : '' }), _jsx(Modal, { isOpen: isCalendarOpen, title: modalOptions === null || modalOptions === void 0 ? void 0 : modalOptions.title, onClose: closeDatepicker, withFooter: false, closeIcon: true, children: _jsx(DatePicker, Object.assign({ minDate: minDate, maxDate: maxDate, selected: dayjs(selectedDate).isValid() ? selectedDate : null, locale: locale, inline: true }, rest, { onChange: onChange, renderCustomHeader: (props) => (_jsx(CustomHeader, Object.assign({}, props, { locale: locale, startYear: startYear, endYear: endYear, dataPrefix: dataIdPrefix, isMobile: true }))) })) })] }));
|
|
48
|
-
};
|
|
1
|
+
import{jsxs as S,Fragment as v,jsx as e}from"react/jsx-runtime";import T from"react";import{Input as V}from"../../Input/Input.js";import w from"../../SVGIcons/IconCalendarRight.js";import D from"dayjs";import{useImportFilesDynamically as R}from"../hooks.js";import{Modal as q}from"../../Modal/Modal.js";import"classnames";import"../../../consts/index.js";import"../../../context/types.js";import"../../../hooks/useScreenSize.js";import"react-hook-form";import"react-dom";import{CustomHeader as z}from"../CustomHeader/CustomHeader.js";import E from"react-datepicker";import{Label as L}from"../../../helperComponents/Label/Label.js";const oe=t=>{const{size:o,dataId:r,helperText:a,label:l,placeholderText:i,format:s="M/D/YYYY",value:n,currentDate:m,minDate:d,maxDate:c,locale:p="hy",dataIdPrefix:u,modalOptions:h,name:f,changeHandler:j,setFieldValue:x,required:C,hasError:I,...g}=t,Y=d?d.getFullYear():1900,b=c?c.getFullYear():/* @__PURE__ */(new Date).getFullYear()+5,[k,y]=T.useState(!1);R(p);const F=void 0!==n&&"[object Date]"===Object.prototype.toString.call(n)?n:m,H=()=>{y(!0)},M=()=>{y(!1)};/* @__PURE__ */
|
|
2
|
+
return S(v,{children:[
|
|
3
|
+
/* @__PURE__ */e(L,{text:l,required:C,invalid:I}),
|
|
4
|
+
/* @__PURE__ */e(V,{size:o,onClick:H,dataId:r,readOnly:!0,helperText:a,datePlaceHolderText:l?"":i,rightIconProps:{Component:w,onClick:H},currentValue:F?D(F.toString()).format(s):""}),
|
|
5
|
+
/* @__PURE__ */e(q,{isOpen:k,title:null==h?void 0:h.title,onClose:M,withFooter:!1,closeIcon:!0,children:/* @__PURE__ */e(E,{minDate:d,maxDate:c,selected:D(F).isValid()?F:null,locale:p,inline:!0,...g,onChange:e=>{x&&f&&x(f,e),j&&j(e),M()},renderCustomHeader:t=>/* @__PURE__ */e(z,{...t,locale:p,startYear:Y,endYear:b,dataPrefix:u,isMobile:!0})})})]})};export{oe as SimpleDatePickerMobile};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import{SimpleDatePicker as i}from"./SimpleDatePicker.js";export{i as SimpleDatePicker};
|
|
@@ -1,34 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import { WheelPicker, WheelPickerWrapper } from '@ncdai/react-wheel-picker';
|
|
6
|
-
import '@ncdai/react-wheel-picker/style.css';
|
|
7
|
-
export const MobileModalContent = ({ onApply, isOpen, mobileTitle, modalApplyButtonText = 'Apply', closeTimePicker, dateInitialValue = new Date() }) => {
|
|
8
|
-
const [selectedHour, setSelectedHour] = useState(`${dateInitialValue.getHours()}`);
|
|
9
|
-
const [selectedMinute, setSelectedMinute] = useState(`${dateInitialValue.getMinutes()}`);
|
|
10
|
-
const applyDate = () => {
|
|
11
|
-
const selectedDate = new Date();
|
|
12
|
-
selectedDate.setHours(+selectedHour, +selectedMinute, 0);
|
|
13
|
-
onApply(selectedDate);
|
|
14
|
-
};
|
|
15
|
-
return (_jsx(Modal, { isOpen: isOpen, title: mobileTitle, onClose: closeTimePicker, className: "time-picker-mobile", buttonProps: {
|
|
16
|
-
confirm: {
|
|
17
|
-
buttonText: modalApplyButtonText,
|
|
18
|
-
onClick: applyDate,
|
|
19
|
-
className: 'time_apply_button'
|
|
20
|
-
}
|
|
21
|
-
}, closeIcon: true, children: _jsx("div", { className: "mobile_time_picker", children: _jsxs(WheelPickerWrapper, { className: "mobile_time_picker-wheel-picker", children: [_jsx(WheelPicker, { value: `${selectedHour}`, options: HOUR_OPTIONS, infinite: true, classNames: {
|
|
22
|
-
optionItem: 'mobile_time_picker-wheel-picker-item mobile_time_picker-wheel-picker-item__hour',
|
|
23
|
-
highlightWrapper: 'mobile_time_picker-wheel-picker-highlight',
|
|
24
|
-
highlightItem: 'mobile_time_picker-wheel-picker-highlight-item__hour'
|
|
25
|
-
}, onValueChange: (hour) => {
|
|
26
|
-
setSelectedHour(hour);
|
|
27
|
-
} }), _jsx(WheelPicker, { value: `${selectedMinute}`, options: MINUTE_OPTIONS, infinite: true, classNames: {
|
|
28
|
-
optionItem: 'mobile_time_picker-wheel-picker-item mobile_time_picker-wheel-picker-item__minute',
|
|
29
|
-
highlightWrapper: 'mobile_time_picker-wheel-picker-highlight',
|
|
30
|
-
highlightItem: 'mobile_time_picker-wheel-picker-highlight-item__minute'
|
|
31
|
-
}, onValueChange: (minute) => {
|
|
32
|
-
setSelectedMinute(minute);
|
|
33
|
-
} })] }) }) }));
|
|
34
|
-
};
|
|
1
|
+
import{jsx as i,jsxs as k}from"react/jsx-runtime";import{useState as m}from"react";import{Modal as u}from"../../Modal/Modal.js";import"classnames";import"../../../consts/index.js";import"../../../context/types.js";import"../../../hooks/useScreenSize.js";import"react-hook-form";import"dayjs";import"react-dom";import{HOUR_OPTIONS as g,MINUTE_OPTIONS as b}from"./consts.js";import{WheelPickerWrapper as w,WheelPicker as l}from"@ncdai/react-wheel-picker";import"@ncdai/react-wheel-picker/style.css";const T=({onApply:e,isOpen:t,mobileTitle:o,modalApplyButtonText:r="Apply",closeTimePicker:s,dateInitialValue:p=/* @__PURE__ */new Date})=>{const[c,a]=m(`${p.getHours()}`),[n,h]=m(`${p.getMinutes()}`);/* @__PURE__ */
|
|
2
|
+
return i(u,{isOpen:t,title:o,onClose:s,className:"time-picker-mobile",buttonProps:{confirm:{buttonText:r,onClick:()=>{const i=/* @__PURE__ */new Date;i.setHours(+c,+n,0),e(i)},className:"time_apply_button"}},closeIcon:!0,children:/* @__PURE__ */i("div",{className:"mobile_time_picker",children:/* @__PURE__ */k(w,{className:"mobile_time_picker-wheel-picker",children:[
|
|
3
|
+
/* @__PURE__ */i(l,{value:`${c}`,options:g,infinite:!0,classNames:{optionItem:"mobile_time_picker-wheel-picker-item mobile_time_picker-wheel-picker-item__hour",highlightWrapper:"mobile_time_picker-wheel-picker-highlight",highlightItem:"mobile_time_picker-wheel-picker-highlight-item__hour"},onValueChange:e=>{a(e)}}),
|
|
4
|
+
/* @__PURE__ */i(l,{value:`${n}`,options:b,infinite:!0,classNames:{optionItem:"mobile_time_picker-wheel-picker-item mobile_time_picker-wheel-picker-item__minute",highlightWrapper:"mobile_time_picker-wheel-picker-highlight",highlightItem:"mobile_time_picker-wheel-picker-highlight-item__minute"},onValueChange:e=>{h(e)}})]})})})};export{T as MobileModalContent};
|
|
@@ -1,8 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { useIsMobile } from '../../../hooks/useGetIsMobile';
|
|
3
|
-
import { TimePickerMobile } from './TimePickerMobile';
|
|
4
|
-
import { TimePickerDesktop } from './TimePickerDesktop';
|
|
5
|
-
export const TimePicker = (props) => {
|
|
6
|
-
const isMobile = useIsMobile();
|
|
7
|
-
return isMobile ? _jsx(TimePickerMobile, Object.assign({}, props)) : _jsx(TimePickerDesktop, Object.assign({}, props));
|
|
8
|
-
};
|
|
1
|
+
import{jsx as o}from"react/jsx-runtime";import{useIsMobile as e}from"../../../hooks/useGetIsMobile.js";import{TimePickerMobile as r}from"./TimePickerMobile.js";import{TimePickerDesktop as m}from"./TimePickerDesktop.js";const k=i=>e()?/* @__PURE__ */o(r,{...i}):/* @__PURE__ */o(m,{...i});export{k as TimePicker};
|
|
@@ -1,67 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
8
|
-
t[p[i]] = s[p[i]];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
import { useRef, useState } from 'react';
|
|
14
|
-
import dayjs from 'dayjs';
|
|
15
|
-
import DatePicker from 'react-datepicker';
|
|
16
|
-
import { Input } from '../../Input';
|
|
17
|
-
import { Label } from '../../../helperComponents/Label';
|
|
18
|
-
import { useImportFilesDynamically } from '../hooks';
|
|
19
|
-
import IconClock from '../../SVGIcons/IconClock';
|
|
20
|
-
export const TimePickerDesktop = (props) => {
|
|
21
|
-
const { value, currentTime, name, setFieldValue, label, size, dataId, changeHandler, required, format = 'HH:mm', locale = 'hy', hasError } = props, rest = __rest(props, ["value", "currentTime", "name", "setFieldValue", "label", "size", "dataId", "changeHandler", "required", "format", "locale", "hasError"]);
|
|
22
|
-
const [time, setTime] = useState();
|
|
23
|
-
const dateInitialValue = value !== undefined && Object.prototype.toString.call(value) === '[object Date]'
|
|
24
|
-
? value
|
|
25
|
-
: currentTime;
|
|
26
|
-
const calendarRef = useRef(null);
|
|
27
|
-
useImportFilesDynamically(locale);
|
|
28
|
-
const onChange = (date) => {
|
|
29
|
-
setTime(date ? dayjs(date).format('HH:mm') : '');
|
|
30
|
-
if (changeHandler) {
|
|
31
|
-
changeHandler(date);
|
|
32
|
-
}
|
|
33
|
-
if (setFieldValue && name) {
|
|
34
|
-
setFieldValue(name, date);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
const openDatepicker = () => {
|
|
38
|
-
var _a, _b;
|
|
39
|
-
if (calendarRef.current) {
|
|
40
|
-
const isOpen = (_a = calendarRef.current) === null || _a === void 0 ? void 0 : _a.isCalendarOpen();
|
|
41
|
-
(_b = calendarRef.current) === null || _b === void 0 ? void 0 : _b.setOpen(!isOpen);
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
const formatAndSetTime = () => {
|
|
45
|
-
const _date = new Date();
|
|
46
|
-
_date.setHours(0, 0);
|
|
47
|
-
if (!time || (time.includes(':') && time[2] !== ':')) {
|
|
48
|
-
onChange(_date);
|
|
49
|
-
return;
|
|
50
|
-
}
|
|
51
|
-
const t = time.replace(':', '');
|
|
52
|
-
if (t.length === 4) {
|
|
53
|
-
const hours = Number(t.slice(0, 2));
|
|
54
|
-
const minutes = Number(t.slice(2, 4));
|
|
55
|
-
if (hours < 24 && minutes < 60) {
|
|
56
|
-
_date.setHours(hours, minutes);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
onChange(_date);
|
|
60
|
-
};
|
|
61
|
-
const onInputChange = (e) => {
|
|
62
|
-
setTime(e.target.value);
|
|
63
|
-
};
|
|
64
|
-
return (_jsxs("div", { className: "picker-container input__inner", children: [_jsx(Label, { text: label, required: required, invalid: hasError }), _jsx(DatePicker, Object.assign({ selected: dayjs(dateInitialValue).isValid() ? dateInitialValue : null, locale: locale, showTimeSelect: true, showTimeSelectOnly: true, dateFormat: format,
|
|
65
|
-
// @ts-ignore
|
|
66
|
-
ref: calendarRef }, rest, { onChange: onChange, customInput: _jsx(Input, { handleChange: onInputChange, handleBlurEvent: formatAndSetTime, disabled: rest.disabled, dataId: dataId, size: size, rightIconProps: { Component: IconClock, onClick: openDatepicker } }) }))] }));
|
|
67
|
-
};
|
|
1
|
+
import{jsxs as S,jsx as a}from"react/jsx-runtime";import{useState as x,useRef as w}from"react";import b from"dayjs";import F from"react-datepicker";import{Input as N}from"../../Input/Input.js";import{Label as P}from"../../../helperComponents/Label/Label.js";import{useImportFilesDynamically as V}from"../hooks.js";import _ from"../../SVGIcons/IconClock.js";const J=e=>{const{value:t,currentTime:r,name:o,setFieldValue:n,label:s,size:l,dataId:i,changeHandler:c,required:m,format:u="HH:mm",locale:d="hy",hasError:p,...f}=e,[h,j]=x(),I=void 0!==t&&"[object Date]"===Object.prototype.toString.call(t)?t:r,v=w(null);V(d);const g=e=>{j(e?b(e).format("HH:mm"):""),c&&c(e),n&&o&&n(o,e)};/* @__PURE__ */
|
|
2
|
+
return S("div",{className:"picker-container input__inner",children:[
|
|
3
|
+
/* @__PURE__ */a(P,{text:s,required:m,invalid:p}),
|
|
4
|
+
/* @__PURE__ */a(F,{selected:b(I).isValid()?I:null,locale:d,showTimeSelect:!0,showTimeSelectOnly:!0,dateFormat:u,ref:v,...f,onChange:g,customInput:/* @__PURE__ */a(N,{handleChange:e=>{j(e.target.value)},handleBlurEvent:()=>{const e=/* @__PURE__ */new Date;if(e.setHours(0,0),!h||h.includes(":")&&":"!==h[2])return void g(e);const t=h.replace(":","");if(4===t.length){const r=Number(t.slice(0,2)),a=Number(t.slice(2,4));r<24&&a<60&&e.setHours(r,a)}g(e)},disabled:f.disabled,dataId:i,size:l,rightIconProps:{Component:_,onClick:()=>{var e,t;if(v.current){const r=null==(e=v.current)?void 0:e.isCalendarOpen();null==(t=v.current)||t.setOpen(!r)}}}})})]})};export{J as TimePickerDesktop};
|
|
@@ -1,29 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import dayjs from 'dayjs';
|
|
7
|
-
import { MobileModalContent } from './MobileModalContent';
|
|
8
|
-
export const TimePickerMobile = (props) => {
|
|
9
|
-
const { value, currentTime, format = 'HH:mm', label, required, hasError, size, placeholderText, dataId, changeHandler, setFieldValue, modalOptions, name } = props;
|
|
10
|
-
const selectedTime = value !== undefined && Object.prototype.toString.call(value) === '[object Date]'
|
|
11
|
-
? value
|
|
12
|
-
: currentTime;
|
|
13
|
-
const [isPickerOpen, setIsPickerOpen] = useState(false);
|
|
14
|
-
const openTimePicker = () => setIsPickerOpen(true);
|
|
15
|
-
const closeTimePicker = () => setIsPickerOpen(false);
|
|
16
|
-
const onChange = (date) => {
|
|
17
|
-
if (changeHandler) {
|
|
18
|
-
changeHandler(date);
|
|
19
|
-
}
|
|
20
|
-
if (setFieldValue && name) {
|
|
21
|
-
setFieldValue(name, date);
|
|
22
|
-
}
|
|
23
|
-
};
|
|
24
|
-
const onApply = (selectedTime) => {
|
|
25
|
-
onChange(selectedTime);
|
|
26
|
-
closeTimePicker();
|
|
27
|
-
};
|
|
28
|
-
return (_jsxs(_Fragment, { children: [_jsx(Label, { text: label, required: required, invalid: hasError }), _jsx(Input, { size: size, onClick: openTimePicker, dataId: dataId, readOnly: true, datePlaceHolderText: label ? '' : placeholderText, rightIconProps: { Component: IconCalendarRight, onClick: openTimePicker }, currentValue: selectedTime ? dayjs(selectedTime.toString()).format(format) : '' }), _jsx(MobileModalContent, { dateInitialValue: selectedTime, onApply: onApply, mobileTitle: modalOptions === null || modalOptions === void 0 ? void 0 : modalOptions.title, isOpen: isPickerOpen, closeTimePicker: closeTimePicker, modalApplyButtonText: modalOptions === null || modalOptions === void 0 ? void 0 : modalOptions.btnConfirmText })] }));
|
|
29
|
-
};
|
|
1
|
+
import{jsxs as I,Fragment as j,jsx as i}from"react/jsx-runtime";import{useState as y}from"react";import{Label as H}from"../../../helperComponents/Label/Label.js";import{Input as v}from"../../Input/Input.js";import M from"../../SVGIcons/IconCalendarRight.js";import S from"dayjs";import{MobileModalContent as V}from"./MobileModalContent.js";const E=e=>{const{value:t,currentTime:o,format:r="HH:mm",label:a,required:l,hasError:n,size:m,placeholderText:s,dataId:d,changeHandler:p,setFieldValue:c,modalOptions:u,name:b}=e,f=void 0!==t&&"[object Date]"===Object.prototype.toString.call(t)?t:o,[x,C]=y(!1),T=()=>C(!0),h=()=>C(!1);/* @__PURE__ */
|
|
2
|
+
return I(j,{children:[
|
|
3
|
+
/* @__PURE__ */i(H,{text:a,required:l,invalid:n}),
|
|
4
|
+
/* @__PURE__ */i(v,{size:m,onClick:T,dataId:d,readOnly:!0,datePlaceHolderText:a?"":s,rightIconProps:{Component:M,onClick:T},currentValue:f?S(f.toString()).format(r):""}),
|
|
5
|
+
/* @__PURE__ */i(V,{dateInitialValue:f,onApply:e=>{(e=>{p&&p(e),c&&b&&c(b,e)})(e),h()},mobileTitle:null==u?void 0:u.title,isOpen:x,closeTimePicker:h,modalApplyButtonText:null==u?void 0:u.btnConfirmText})]})};export{E as TimePickerMobile};
|
|
@@ -1,5 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
export const HOUR_LENGTH = 24;
|
|
3
|
-
export const MINUTE_LENGTH = 60;
|
|
4
|
-
export const HOUR_OPTIONS = createArray(HOUR_LENGTH);
|
|
5
|
-
export const MINUTE_OPTIONS = createArray(MINUTE_LENGTH);
|
|
1
|
+
import{createArray as o}from"./helpers.js";const t=24,r=60,O=o(t),T=o(r);export{t as HOUR_LENGTH,O as HOUR_OPTIONS,r as MINUTE_LENGTH,T as MINUTE_OPTIONS};
|
|
@@ -1,11 +1 @@
|
|
|
1
|
-
|
|
2
|
-
const value = i + add;
|
|
3
|
-
return {
|
|
4
|
-
label: value.toString().padStart(2, '0'),
|
|
5
|
-
value: value.toString()
|
|
6
|
-
};
|
|
7
|
-
});
|
|
8
|
-
export const meridiemOptions = [
|
|
9
|
-
{ label: 'AM', value: 'AM' },
|
|
10
|
-
{ label: 'PM', value: 'PM' }
|
|
11
|
-
];
|
|
1
|
+
const o=(a,e=0)=>Array.from({length:a},(a,r)=>{const t=r+e;return{label:t.toString().padStart(2,"0"),value:t.toString()}}),n=[{label:"AM",value:"AM"},{label:"PM",value:"PM"}];export{o as createArray,n as meridiemOptions};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import{TimePicker as i}from"./TimePicker.js";export{i as TimePicker};
|
|
@@ -1,37 +1 @@
|
|
|
1
|
-
|
|
2
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
-
});
|
|
9
|
-
};
|
|
10
|
-
import { useEffect, useState } from 'react';
|
|
11
|
-
import { registerLocale } from 'react-datepicker';
|
|
12
|
-
import { locale } from 'dayjs';
|
|
13
|
-
import { hy } from 'date-fns/locale/hy';
|
|
14
|
-
import { enGB } from 'date-fns/locale/en-GB';
|
|
15
|
-
import { ru } from 'date-fns/locale/ru';
|
|
16
|
-
import 'dayjs/locale/hy-am';
|
|
17
|
-
import 'dayjs/locale/ru';
|
|
18
|
-
import 'dayjs/locale/en';
|
|
19
|
-
import { DayJSLocale } from '../../type';
|
|
20
|
-
registerLocale('hy', hy);
|
|
21
|
-
registerLocale('en', enGB);
|
|
22
|
-
registerLocale('ru', ru);
|
|
23
|
-
export function useImportFilesDynamically(dayjsLocale) {
|
|
24
|
-
const [_, setIsFilesLoaded] = useState(false);
|
|
25
|
-
useEffect(() => {
|
|
26
|
-
if (dayjsLocale) {
|
|
27
|
-
;
|
|
28
|
-
(() => __awaiter(this, void 0, void 0, function* () {
|
|
29
|
-
setIsFilesLoaded(false);
|
|
30
|
-
locale(DayJSLocale[dayjsLocale]);
|
|
31
|
-
setTimeout(() => {
|
|
32
|
-
setIsFilesLoaded(true);
|
|
33
|
-
}, 0);
|
|
34
|
-
}))();
|
|
35
|
-
}
|
|
36
|
-
}, [dayjsLocale]);
|
|
37
|
-
}
|
|
1
|
+
import{useState as e,useEffect as m}from"react";import{registerLocale as r}from"react-datepicker";import{locale as i}from"dayjs";import{hy as f}from"date-fns/locale/hy";import{enGB as p}from"date-fns/locale/en-GB";import{ru as s}from"date-fns/locale/ru";import"dayjs/locale/hy-am";import"dayjs/locale/ru";import"dayjs/locale/en";import{DayJSLocale as l}from"../../type/locale.js";function x(a){const[o,r]=e(!1);m(()=>{a&&(async()=>{r(!1),i(l[a]),setTimeout(()=>{r(!0)},0)})()},[a])}r("hy",f),r("en",p),r("ru",s);export{x as useImportFilesDynamically};
|
|
@@ -1,3 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export * from './SimpleDatePicker';
|
|
3
|
-
export * from './RangeDatePicker';
|
|
1
|
+
import{TimePicker as o}from"./TimePicker/TimePicker.js";import{SimpleDatePicker as m}from"./SimpleDatePicker/SimpleDatePicker.js";import{RangeDatePicker as p}from"./RangeDatePicker/RangeDatePicker.js";export{p as RangeDatePicker,m as SimpleDatePicker,o as TimePicker};
|
|
@@ -1,44 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
en: [
|
|
3
|
-
'January',
|
|
4
|
-
'February',
|
|
5
|
-
'March',
|
|
6
|
-
'April',
|
|
7
|
-
'May',
|
|
8
|
-
'June',
|
|
9
|
-
'July',
|
|
10
|
-
'August',
|
|
11
|
-
'September',
|
|
12
|
-
'October',
|
|
13
|
-
'November',
|
|
14
|
-
'December'
|
|
15
|
-
],
|
|
16
|
-
ru: [
|
|
17
|
-
'Январь',
|
|
18
|
-
'Февраль',
|
|
19
|
-
'Март',
|
|
20
|
-
'Апрель',
|
|
21
|
-
'Май',
|
|
22
|
-
'Июнь',
|
|
23
|
-
'Июль',
|
|
24
|
-
'Август',
|
|
25
|
-
'Сентябрь',
|
|
26
|
-
'Октябрь',
|
|
27
|
-
'Ноябрь',
|
|
28
|
-
'Декабрь'
|
|
29
|
-
],
|
|
30
|
-
hy: [
|
|
31
|
-
'Հունվար',
|
|
32
|
-
'Փետրվար',
|
|
33
|
-
'Մարտ',
|
|
34
|
-
'Ապրիլ',
|
|
35
|
-
'Մայիս',
|
|
36
|
-
'Հունիս',
|
|
37
|
-
'Հուլիս',
|
|
38
|
-
'Օգոստոս',
|
|
39
|
-
'Սեպտեմբեր',
|
|
40
|
-
'Հոկտեմբեր',
|
|
41
|
-
'Նոյեմբեր',
|
|
42
|
-
'Դեկտեմբեր'
|
|
43
|
-
]
|
|
44
|
-
};
|
|
1
|
+
const e={en:["January","February","March","April","May","June","July","August","September","October","November","December"],ru:["Январь","Февраль","Март","Апрель","Май","Июнь","Июль","Август","Сентябрь","Октябрь","Ноябрь","Декабрь"],hy:["Հունվար","Փետրվար","Մարտ","Ապրիլ","Մայիս","Հունիս","Հուլիս","Օգոստոս","Սեպտեմբեր","Հոկտեմբեր","Նոյեմբեր","Դեկտեմբեր"]};export{e as MONTHS};
|
|
@@ -1,5 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
(function (DateFormat) {
|
|
3
|
-
DateFormat["LongDate"] = "MMMM D, YYYY";
|
|
4
|
-
DateFormat["ShortDate"] = "MMM D, YYYY";
|
|
5
|
-
})(DateFormat || (DateFormat = {}));
|
|
1
|
+
var M=/* @__PURE__ */(M=>(M.LongDate="MMMM D, YYYY",M.ShortDate="MMM D, YYYY",M))(M||{});export{M as DateFormat};
|
|
@@ -1,9 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
export const Divider = (props) => {
|
|
4
|
-
const { type = 'primary', isHorizontal, className, color = 'light-grey' } = props;
|
|
5
|
-
return (_jsx("hr", { className: classnames('divider', `divider--${type}`, `divider--${color}`, {
|
|
6
|
-
'divider--horizontal': isHorizontal,
|
|
7
|
-
'divider--vertical': !isHorizontal
|
|
8
|
-
}, className) }));
|
|
9
|
-
};
|
|
1
|
+
import{jsx as s}from"react/jsx-runtime";import t from"classnames";const m=r=>{const{type:i="primary",isHorizontal:e,className:a,color:o="light-grey"}=r;/* @__PURE__ */
|
|
2
|
+
return s("hr",{className:t("divider",`divider--${i}`,`divider--${o}`,{"divider--horizontal":e,"divider--vertical":!e},a)})};export{m as Divider};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import{Divider as i}from"./Divider.js";export{i as Divider};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import classNames from 'classnames';
|
|
6
|
-
// @ts-ignore
|
|
7
|
-
import noResultImage from '../../assets/images/no-result.svg';
|
|
8
|
-
export const Empty = (props) => {
|
|
9
|
-
const { size = 'large', mainMessage, paragraphMessage, buttonProps, className, illustration = noResultImage } = props;
|
|
10
|
-
return (_jsxs("div", { className: classNames(`no-result ${size == 'large' ? 'no-result--large' : 'no-result--small'}`, className), children: [_jsx("div", { className: "no-result__icon", children: _jsx(Image, { imagePath: illustration }) }), _jsxs("div", { className: "no-result__content", children: [mainMessage ? (_jsx(Text, { size: size == 'large' ? 'large' : 'small', weight: "bold", children: mainMessage })) : null, paragraphMessage ? (_jsx(Text, { size: size == 'large' ? 'small' : 'xsmall', children: paragraphMessage })) : null, buttonProps ? _jsx(Button, Object.assign({}, buttonProps, { size: "medium", className: "mt-4" })) : null] })] }));
|
|
11
|
-
};
|
|
1
|
+
import{jsxs as m,jsx as e}from"react/jsx-runtime";import{Text as t}from"../Text/Text.js";import{Image as c}from"../Image/Image.js";import{Button as u}from"../Button/Button.js";import g from"classnames";import p from"../../assets/images/no-result.svg.js";const _=s=>{const{size:a="large",mainMessage:l,paragraphMessage:r,buttonProps:o,className:n,illustration:i=p}=s;/* @__PURE__ */
|
|
2
|
+
return m("div",{className:g("no-result "+("large"==a?"no-result--large":"no-result--small"),n),children:[
|
|
3
|
+
/* @__PURE__ */e("div",{className:"no-result__icon",children:/* @__PURE__ */e(c,{imagePath:i})}),
|
|
4
|
+
/* @__PURE__ */m("div",{className:"no-result__content",children:[l?/* @__PURE__ */e(t,{size:"large"==a?"large":"small",weight:"bold",children:l}):null,r?/* @__PURE__ */e(t,{size:"large"==a?"small":"xsmall",children:r}):null,o?/* @__PURE__ */e(u,{...o,size:"medium",className:"mt-4"}):null]})]})};export{_ as Empty};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import{Empty as p}from"./Empty.js";export{p as Empty};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{jsxs as C,jsx as e}from"react/jsx-runtime";import{TEXT_BY_LANG as o}from"./consts.js";const d=({isMobile:n,language:a,surveyUrl:r})=>!r||window.self!==window.top||n?null:/* @__PURE__ */C("button",{id:"feedback-fab",type:"button","aria-label":"Open feedback survey",onClick:()=>{window.open(r,"_blank","noopener,noreferrer")},children:[
|
|
2
|
+
/* @__PURE__ */e("span",{className:"feedback-fab-icon","aria-hidden":"true",children:/* @__PURE__ */e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"20",height:"20",fill:"none",children:/* @__PURE__ */e("path",{d:"M12.4219 2C17.9447 2 22.4219 6.47715 22.4219 12C22.4219 17.5228 17.9447 22 12.4219 22C10.8036 22 9.2397 21.6146 7.83473 20.888L4.00892 21.9553C3.344 22.141 2.65446 21.7525 2.46878 21.0876C2.40734 20.8676 2.40737 20.6349 2.46882 20.4151L3.53649 16.5922C2.80824 15.186 2.42188 13.6203 2.42188 12C2.42188 6.47715 6.89903 2 12.4219 2ZM12.4219 3.5C7.72745 3.5 3.92188 7.30558 3.92188 12C3.92188 13.4696 4.29465 14.8834 4.99491 16.1375L5.14555 16.4072L4.03283 20.3914L8.01943 19.2792L8.28896 19.4295C9.54193 20.1281 10.9541 20.5 12.4219 20.5C17.1163 20.5 20.9219 16.6944 20.9219 12C20.9219 7.30558 17.1163 3.5 12.4219 3.5ZM9.17188 13H13.6701C14.0844 13 14.4201 13.3358 14.4201 13.75C14.4201 14.1297 14.138 14.4435 13.7719 14.4932L13.6701 14.5H9.17188C8.75766 14.5 8.42188 14.1642 8.42188 13.75C8.42188 13.3703 8.70403 13.0565 9.0701 13.0068L9.17188 13H13.6701H9.17188ZM9.17188 9.5H15.6764C16.0906 9.5 16.4264 9.83579 16.4264 10.25C16.4264 10.6297 16.1442 10.9435 15.7781 10.9932L15.6764 11H9.17188C8.75766 11 8.42188 10.6642 8.42188 10.25C8.42188 9.8703 8.70403 9.55651 9.0701 9.50685L9.17188 9.5H15.6764H9.17188Z",fill:"currentColor"})})}),
|
|
3
|
+
/* @__PURE__ */e("span",{className:"feedback-fab-text",children:o[a]||o["en-US"]})]});export{d as Feedback};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const TEXT_BY_LANG: Record<string, string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={"en-US":"Give Feedback","hy-AM":"Թողնել Կարծիք","ru-RU":"Оставить отзыв"};export{e as TEXT_BY_LANG};
|