@evolve.ui/core-components 1.0.1 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{BottomSheet-ZV_eq3xt.mjs → BottomSheet-CNVLnEoD.mjs} +3 -3
- package/BottomSheet-CNVLnEoD.mjs.map +1 -0
- package/{BottomSheet-emWP9Fct.cjs → BottomSheet-D5w0WZDl.cjs} +3 -3
- package/BottomSheet-D5w0WZDl.cjs.map +1 -0
- package/Button.cjs +1 -1
- package/Button.mjs +1 -1
- package/{CookieConsent-CIwm0bTz.mjs → CookieConsent-B9dg9WdC.mjs} +2 -2
- package/{CookieConsent-CIwm0bTz.mjs.map → CookieConsent-B9dg9WdC.mjs.map} +1 -1
- package/{CookieConsent-PIglB_bb.cjs → CookieConsent-BSXJHMwX.cjs} +2 -2
- package/{CookieConsent-PIglB_bb.cjs.map → CookieConsent-BSXJHMwX.cjs.map} +1 -1
- package/{Drawer-9HFG45OA.cjs → Drawer-3rA9dGCl.cjs} +2 -2
- package/{Drawer-9HFG45OA.cjs.map → Drawer-3rA9dGCl.cjs.map} +1 -1
- package/Drawer-CFZbwg0R.d.cts.map +1 -1
- package/Drawer-CFZbwg0R.d.mts.map +1 -1
- package/{Drawer-BkCPfK6P.mjs → Drawer-DzKEmewj.mjs} +2 -2
- package/{Drawer-BkCPfK6P.mjs.map → Drawer-DzKEmewj.mjs.map} +1 -1
- package/{FavoriteButton-CC3qL0lR.mjs → FavoriteButton-7nK77lQP.mjs} +6 -6
- package/FavoriteButton-7nK77lQP.mjs.map +1 -0
- package/{FavoriteButton-BGF-3dze.d.cts → FavoriteButton-B8r_qtlj.d.cts} +2 -2
- package/{FavoriteButton-BGF-3dze.d.cts.map → FavoriteButton-B8r_qtlj.d.cts.map} +1 -1
- package/{FavoriteButton-DliYzkfu.cjs → FavoriteButton-BkIaWfgD.cjs} +6 -6
- package/FavoriteButton-BkIaWfgD.cjs.map +1 -0
- package/{FavoriteButton-BZEGWrRo.d.mts → FavoriteButton-hIkGjcKH.d.mts} +2 -2
- package/{FavoriteButton-BZEGWrRo.d.mts.map → FavoriteButton-hIkGjcKH.d.mts.map} +1 -1
- package/{FileUpload-p_pl9NXr.mjs → FileUpload-BfZOMsLs.mjs} +6 -6
- package/FileUpload-BfZOMsLs.mjs.map +1 -0
- package/{FileUpload--e_UJ_ek.cjs → FileUpload-gjRbkgrL.cjs} +6 -6
- package/FileUpload-gjRbkgrL.cjs.map +1 -0
- package/IconButton.cjs +1 -1
- package/IconButton.mjs +1 -1
- package/{ImageSlider-BidXfnLj.cjs → ImageSlider-CAgxQffP.cjs} +3 -3
- package/ImageSlider-CAgxQffP.cjs.map +1 -0
- package/{ImageSlider-CDrg_TbL.mjs → ImageSlider-fdrJ6lIJ.mjs} +3 -3
- package/ImageSlider-fdrJ6lIJ.mjs.map +1 -0
- package/InfoIconTooltip.cjs +1 -1
- package/InfoIconTooltip.cjs.map +1 -1
- package/InfoIconTooltip.mjs +1 -1
- package/InfoIconTooltip.mjs.map +1 -1
- package/InlineButton-CRLbNJZ3.d.mts.map +1 -1
- package/InlineButton-DoXGLiSE.d.cts.map +1 -1
- package/Input.cjs +1 -1
- package/Input.cjs.map +1 -1
- package/Input.mjs +1 -1
- package/Input.mjs.map +1 -1
- package/JumpMenu-BXYZnPIH.cjs.map +1 -1
- package/JumpMenu-DcZjAiej.mjs.map +1 -1
- package/{Menu-Cxu8CaX1.mjs → Menu-Bn4smlEe.mjs} +2 -2
- package/Menu-Bn4smlEe.mjs.map +1 -0
- package/{Menu-ClUogmwE.cjs → Menu-DuDhtoNP.cjs} +2 -2
- package/Menu-DuDhtoNP.cjs.map +1 -0
- package/Modal-DM0aXJZ5.d.cts.map +1 -1
- package/Modal-DM0aXJZ5.d.mts.map +1 -1
- package/{Modal-C6gatdtT.mjs → Modal-DtxWd7Le.mjs} +3 -2
- package/{Modal-C6gatdtT.mjs.map → Modal-DtxWd7Le.mjs.map} +1 -1
- package/{Modal-CiBqXyiK.cjs → Modal-q4HhBAQU.cjs} +3 -2
- package/Modal-q4HhBAQU.cjs.map +1 -0
- package/{Pagination-bAtbN478.cjs → Pagination-Denb9_zB.cjs} +2 -2
- package/{Pagination-bAtbN478.cjs.map → Pagination-Denb9_zB.cjs.map} +1 -1
- package/{Pagination-DIpGKMLz.mjs → Pagination-Dyfeys4B.mjs} +2 -2
- package/{Pagination-DIpGKMLz.mjs.map → Pagination-Dyfeys4B.mjs.map} +1 -1
- package/PhoneInput-B5pkpkdt.mjs.map +1 -1
- package/PhoneInput-BXnkBME4.d.mts.map +1 -1
- package/PhoneInput-Bkrbrins.d.cts.map +1 -1
- package/PhoneInput-CUMPOSxJ.cjs.map +1 -1
- package/{ProgressCircle-BC81D9sU.cjs → ProgressCircle-B6R4dxoV.cjs} +2 -2
- package/{ProgressCircle-BC81D9sU.cjs.map → ProgressCircle-B6R4dxoV.cjs.map} +1 -1
- package/{ProgressCircle-ae8cvZhe.mjs → ProgressCircle-zSai1HTT.mjs} +2 -2
- package/{ProgressCircle-ae8cvZhe.mjs.map → ProgressCircle-zSai1HTT.mjs.map} +1 -1
- package/SearchInput-DYIPC8Cd.d.cts.map +1 -1
- package/SearchInput-IfEWePDQ.d.mts.map +1 -1
- package/{Select-BkZu8OLs.mjs → Select-CH_ZN88G.mjs} +2 -2
- package/Select-CH_ZN88G.mjs.map +1 -0
- package/{Select-BXDjzyDs.cjs → Select-DCCcyLT4.cjs} +2 -2
- package/Select-DCCcyLT4.cjs.map +1 -0
- package/{SplitButton-DcmmLW8j.cjs → SplitButton-B_Y253RU.cjs} +2 -2
- package/{SplitButton-DcmmLW8j.cjs.map → SplitButton-B_Y253RU.cjs.map} +1 -1
- package/{SplitButton-WE5ymwCQ.mjs → SplitButton-_poP9Ykq.mjs} +2 -2
- package/{SplitButton-WE5ymwCQ.mjs.map → SplitButton-_poP9Ykq.mjs.map} +1 -1
- package/{Table-M-rANdMt.mjs → Table-CQGtDpvH.mjs} +3 -3
- package/{Table-M-rANdMt.mjs.map → Table-CQGtDpvH.mjs.map} +1 -1
- package/{Table-CLlDragJ.cjs → Table-D4UYosb1.cjs} +3 -3
- package/{Table-CLlDragJ.cjs.map → Table-D4UYosb1.cjs.map} +1 -1
- package/Typography/InlineButton.cjs +1 -1
- package/Typography/InlineButton.cjs.map +1 -1
- package/Typography/InlineButton.mjs +1 -1
- package/Typography/InlineButton.mjs.map +1 -1
- package/{ViewMore-BBoUvo7p.cjs → ViewMore-BcoSRZSl.cjs} +14 -1
- package/ViewMore-BcoSRZSl.cjs.map +1 -0
- package/{ViewMore-BrZPuE4E.mjs → ViewMore-Be0TQZ_2.mjs} +14 -1
- package/ViewMore-Be0TQZ_2.mjs.map +1 -0
- package/bottomSheet.cjs +1 -1
- package/bottomSheet.mjs +1 -1
- package/{buttonColorClasses-C3hg1at8.cjs → buttonColorClasses-CQQmLYfk.cjs} +4 -4
- package/buttonColorClasses-CQQmLYfk.cjs.map +1 -0
- package/{buttonColorClasses-B7OU4aQA.mjs → buttonColorClasses-CQnqAJXl.mjs} +4 -4
- package/buttonColorClasses-CQnqAJXl.mjs.map +1 -0
- package/card/components/createFavoriteButton.cjs +1 -1
- package/card/components/createFavoriteButton.mjs +1 -1
- package/cookieConsent.cjs +1 -1
- package/cookieConsent.mjs +1 -1
- package/drawer.cjs +1 -1
- package/drawer.mjs +1 -1
- package/evolve-ui.entries.json +556 -0
- package/favoriteButton.cjs +1 -1
- package/favoriteButton.d.cts +1 -1
- package/favoriteButton.d.mts +1 -1
- package/favoriteButton.mjs +1 -1
- package/featureFlags/hooks.d.cts +1 -1
- package/featureFlags/hooks.d.mts +1 -1
- package/fileUpload.cjs +1 -1
- package/fileUpload.mjs +1 -1
- package/imageSlider.cjs +1 -1
- package/imageSlider.mjs +1 -1
- package/index.cjs +14 -14
- package/index.d.cts +1 -1
- package/index.d.mts +1 -1
- package/index.mjs +14 -14
- package/menu.cjs +1 -1
- package/menu.mjs +1 -1
- package/modal/useCloseModal.cjs +2 -1
- package/modal/useCloseModal.cjs.map +1 -1
- package/modal/useCloseModal.mjs +2 -1
- package/modal/useCloseModal.mjs.map +1 -1
- package/modal.cjs +1 -1
- package/modal.mjs +1 -1
- package/package.json +2 -4
- package/pagination.cjs +1 -1
- package/pagination.mjs +1 -1
- package/progressCircle.cjs +1 -1
- package/progressCircle.mjs +1 -1
- package/searchInput.cjs +4 -4
- package/searchInput.cjs.map +1 -1
- package/searchInput.mjs +4 -4
- package/searchInput.mjs.map +1 -1
- package/select.cjs +1 -1
- package/select.mjs +1 -1
- package/selectAsync.cjs +1 -1
- package/selectAsync.mjs +1 -1
- package/selectAsyncCreatable.cjs +1 -1
- package/selectAsyncCreatable.mjs +1 -1
- package/selectCreatable.cjs +1 -1
- package/selectCreatable.mjs +1 -1
- package/splitButton.cjs +1 -1
- package/splitButton.mjs +1 -1
- package/src/Accordion/Accordion.tsx +233 -0
- package/src/AddressDisplay/AddressDisplay.tsx +43 -0
- package/src/AddressDisplay/components/addressComponents.tsx +111 -0
- package/src/AddressDisplay/components/addressField.tsx +25 -0
- package/src/AddressDisplay/components/addressSection.tsx +8 -0
- package/src/AddressDisplay/components/getCountryValue.tsx +31 -0
- package/src/AddressDisplay/types.ts +26 -0
- package/src/AutomatedCarousel/AutomatedCarousel.tsx +163 -0
- package/src/AutomatedCarousel/automatedCarousel.types.ts +7 -0
- package/src/AutomatedCarousel/components/CarouselProgressBar/CarouselProgressBar.tsx +139 -0
- package/src/AutomatedCarousel/components/CarouselProgressBar/components/CarouselProgressBarUnit/CarouselProgressBarUnit.tsx +165 -0
- package/src/Badge/Badge.tsx +104 -0
- package/src/Badge/Badge.types.ts +58 -0
- package/src/Badge/ItemBadge.tsx +97 -0
- package/src/Badge/LiveStatusBadge.tsx +93 -0
- package/src/BannerNotification/BannerNotification.tsx +157 -0
- package/src/BannerNotification/components/BannerNotificationSkeleton.tsx +39 -0
- package/src/BannerNotification/components/CalloutIcon/BannerIcon.tsx +48 -0
- package/src/BannerNotification/utils/getRandomTooltipId.ts +3 -0
- package/src/BottomSheet/BottomSheet.tsx +476 -0
- package/src/BottomSheet/components/BottomSheetBackdrop/BottomSheetBackdrop.tsx +47 -0
- package/src/BottomSheet/components/BottomSheetContentArea/BottomSheetContentArea.tsx +93 -0
- package/src/BottomSheet/components/BottomSheetOverlay/BottomSheetOverlayTranslate3d.tsx +199 -0
- package/src/BottomSheet/components/SheetDescription/SheetDescription.tsx +22 -0
- package/src/BottomSheet/components/SheetTitle/SheetTitle.tsx +21 -0
- package/src/BottomSheet/components/index.tsx +5 -0
- package/src/BottomSheet/hooks/index.tsx +13 -0
- package/src/BottomSheet/hooks/useAriaHider.tsx +91 -0
- package/src/BottomSheet/hooks/useBottomSheetServices.tsx +224 -0
- package/src/BottomSheet/hooks/useDragHandler.tsx +282 -0
- package/src/BottomSheet/hooks/useFocusTrap.tsx +113 -0
- package/src/BottomSheet/hooks/useLayoutEffect.tsx +4 -0
- package/src/BottomSheet/hooks/useOptimizedResizeObserver.tsx +94 -0
- package/src/BottomSheet/hooks/useOptimizedScrollState.tsx +87 -0
- package/src/BottomSheet/hooks/useReady.tsx +34 -0
- package/src/BottomSheet/hooks/useReducedMotion.tsx +22 -0
- package/src/BottomSheet/hooks/useScrollLock.tsx +143 -0
- package/src/BottomSheet/hooks/useSnapPoints.tsx +355 -0
- package/src/BottomSheet/hooks/useSpring.tsx +47 -0
- package/src/BottomSheet/hooks/useSpringInterpolationsTranslate3d.tsx +101 -0
- package/src/BottomSheet/index.tsx +237 -0
- package/src/BottomSheet/state/atoms.ts +147 -0
- package/src/BottomSheet/state/useBottomSheetStateMachine.ts +246 -0
- package/src/BottomSheet/types.ts +172 -0
- package/src/BottomSheet/utils.ts +65 -0
- package/src/Breadcrumbs/Breadcrumbs.tsx +126 -0
- package/src/Button/Button.tsx +164 -0
- package/src/Button/Button.types.ts +80 -0
- package/src/Button/buttonColorClasses.ts +58 -0
- package/src/Callout/Callout.tsx +136 -0
- package/src/Callout/Callout.types.ts +29 -0
- package/src/Callout/components/CalloutIcon/CalloutIcon.tsx +56 -0
- package/src/Card/CardGrid.tsx +263 -0
- package/src/Card/SingleCard.tsx +22 -0
- package/src/Card/cardFactory.tsx +176 -0
- package/src/Card/components/createBadge.tsx +34 -0
- package/src/Card/components/createFavoriteButton.tsx +40 -0
- package/src/Card/components/createImage.tsx +64 -0
- package/src/Card/components/createInfo.tsx +84 -0
- package/src/Card/components/createName.tsx +63 -0
- package/src/Card/components/createPriceStatus.tsx +100 -0
- package/src/Card/components/types.ts +4 -0
- package/src/Card/hooks/useCardVisibilityTracking.ts +82 -0
- package/src/Card/sharedProps.ts +12 -0
- package/src/Card/types.ts +62 -0
- package/src/Carousel/Carousel.tsx +513 -0
- package/src/Carousel/Carousel.types.ts +43 -0
- package/src/Carousel/Carousel.utils.ts +63 -0
- package/src/Carousel/components/DotButton/DotButton.tsx +42 -0
- package/src/Carousel/components/NavigationButtons/NavigationButtons.tsx +77 -0
- package/src/Carousel/components/TitleSection/TitleSection.tsx +61 -0
- package/src/Carousel/components/TitleSection/components/SubHeaderLeft/SubHeaderLeft.tsx +53 -0
- package/src/Carousel/components/TitleSection/components/Title/Title.tsx +46 -0
- package/src/Carousel/index.ts +2 -0
- package/src/Carousel/testUtils.ts +10 -0
- package/src/Chips/Chip.tsx +153 -0
- package/src/Chips/ChipGroup.tsx +173 -0
- package/src/Chips/SuggestionChip.tsx +15 -0
- package/src/Chips/chipTypes.ts +113 -0
- package/src/Chips/index.ts +4 -0
- package/src/ChoiceListItem/Checkbox.tsx +69 -0
- package/src/ChoiceListItem/Radio.tsx +61 -0
- package/src/ChoiceListItem/choiceListItem.tsx +99 -0
- package/src/ChoiceListItem/common.tsx +148 -0
- package/src/ChoiceListItem/index.ts +3 -0
- package/src/Collapsible/Collapsible.tsx +58 -0
- package/src/Confetti/Confetti.tsx +270 -0
- package/src/Confetti/index.ts +2 -0
- package/src/ContentPager/ContentPager.tsx +189 -0
- package/src/ContentPager/components/Page.tsx +24 -0
- package/src/CookieConsent/components/CookieCategoryRow/CookieCategoryRow.tsx +30 -0
- package/src/CookieConsent/components/CookieConsent/CookieConsent.tsx +74 -0
- package/src/CookieConsent/components/CookieConsentBanner/CookieConsentBanner.tsx +51 -0
- package/src/CookieConsent/components/CookieConsentModal/CookieConsentModal.tsx +64 -0
- package/src/CookieConsent/hooks/useCookieConsent.ts +170 -0
- package/src/CookieConsent/hooks/useCookieConsentState.ts +142 -0
- package/src/CookieConsent/index.ts +16 -0
- package/src/CookieConsent/types/cookieConsent.types.ts +79 -0
- package/src/CookieConsent/types/index.ts +7 -0
- package/src/Countdown/Countdown.tsx +161 -0
- package/src/Countdown/Countdown.types.ts +4 -0
- package/src/Countdown/hooks/useGetCountdown.ts +103 -0
- package/src/DateTimeInput/dateInput/DateInput.tsx +199 -0
- package/src/DateTimeInput/datePicker/DatePicker.tsx +138 -0
- package/src/DateTimeInput/datePicker/components/calendar/Calendar.tsx +72 -0
- package/src/DateTimeInput/datePicker/index.ts +2 -0
- package/src/DateTimeInput/timeInput/TimeInput.tsx +128 -0
- package/src/DateTimeInput/timePicker/TimePicker.tsx +118 -0
- package/src/DateTimeInput/timePicker/components/TimePopover/AmPmSwitch.tsx +103 -0
- package/src/DateTimeInput/timePicker/components/TimePopover/TimeFieldInput.tsx +26 -0
- package/src/DateTimeInput/timePicker/components/TimePopover/TimePopover.tsx +84 -0
- package/src/DateTimeInput/timePicker/components/TimePopover/TimePopover.utils.ts +67 -0
- package/src/DateTimeInput/timePicker/components/TimePopover/TimePopoverActions.tsx +26 -0
- package/src/DateTimeInput/timePicker/index.ts +2 -0
- package/src/DateTimeInput/utils/getDisplayDate.ts +15 -0
- package/src/DateTimeInput/utils/getDisplayTime.ts +15 -0
- package/src/DateTimeInput/utils/index.ts +2 -0
- package/src/DateTimeInput/utils/parseTimeValue.ts +54 -0
- package/src/Drawer/Drawer.tsx +443 -0
- package/src/Drawer/atoms.ts +4 -0
- package/src/Drawer/components/DialogActions/DialogActions.tsx +33 -0
- package/src/Drawer/components/DialogContent/DialogContent.tsx +80 -0
- package/src/Drawer/components/DialogHeader/DialogHeader.tsx +68 -0
- package/src/EducationalPopover/EducationalPopover.tsx +174 -0
- package/src/FavoriteButton/FavoriteButton.tsx +64 -0
- package/src/FavoriteButton/components/IconOnlyFavoriteButton/IconOnlyFavoriteButton.tsx +83 -0
- package/src/FavoriteButton/components/LabeledAnimatedFavoriteButton/LabeledAnimatedFavoriteButton.tsx +186 -0
- package/src/FavoriteButton/components/LabeledFavoriteButton/LabeledFavoriteButton.tsx +71 -0
- package/src/FavoriteButton/components/SmallHeartStraightIcon/SmallHeartStraightIcon.tsx +14 -0
- package/src/FavoriteButton/hooks/useFavoriteButtonState.ts +30 -0
- package/src/FavoriteButton/index.ts +2 -0
- package/src/FavoriteButton/types/favoriteButton.ts +87 -0
- package/src/FeatureFlags/devTools/FeatureFlagDevToolsUI.tsx +226 -0
- package/src/FeatureFlags/devTools/getFeatureFlagCookieOverrides.ts +30 -0
- package/src/FeatureFlags/devTools/utils/cookies.ts +169 -0
- package/src/FeatureFlags/hooks/index.ts +2 -0
- package/src/FeatureFlags/hooks/useFeatureFlag.tsx +19 -0
- package/src/FeatureFlags/hooks/useFeatureFlags.tsx +15 -0
- package/src/FileUpload/components/FileCard/FileCard.tsx +50 -0
- package/src/FileUpload/components/FileDropzone/FileDropzone.tsx +221 -0
- package/src/FileUpload/components/FileDropzone/components/DropzoneContent/DropzoneContent.tsx +28 -0
- package/src/FileUpload/components/FileDropzone/components/DropzoneContent/DropzoneText.tsx +81 -0
- package/src/FileUpload/components/FileDropzone/components/FileDropzoneDebugger/FileDropzoneDebugger.tsx +40 -0
- package/src/FileUpload/components/FileDropzone/components/FileDropzoneDebugger/FileRejectionsDisplay.tsx +110 -0
- package/src/FileUpload/components/FileDropzoneOverlay/FileDropzoneOverlay.tsx +183 -0
- package/src/FileUpload/components/FileDropzoneOverlay/components/OverlayDropzoneContent.tsx +146 -0
- package/src/FileUpload/components/FileDropzoneOverlay/components/OverlayDropzoneDragText.tsx +42 -0
- package/src/FileUpload/components/FileDropzoneOverlay/styles.ts +79 -0
- package/src/FileUpload/components/FilePreviewList/FilePreviewList.tsx +251 -0
- package/src/FileUpload/components/FilePreviewList/virtualizerComponents/FilePreviewVirtualizedList/FilePreviewVirtualizedList.tsx +88 -0
- package/src/FileUpload/components/FileUpload/FileUpload.tsx +63 -0
- package/src/FileUpload/components/FileUploadCanvas/FileUploadCanvas.tsx +125 -0
- package/src/FileUpload/components/GridFileCard/GridFileCard.tsx +364 -0
- package/src/FileUpload/components/GridFileCard/utils/sortable.ts +48 -0
- package/src/FileUpload/components/ListFileCard/ListFileCard.tsx +259 -0
- package/src/FileUpload/components/types.ts +78 -0
- package/src/FileUpload/hooks/filePreview/useImageFilePreviewUrl.ts +62 -0
- package/src/FileUpload/hooks/index.ts +11 -0
- package/src/FileUpload/hooks/upload/useHandleDragEnter/useHandleDragEnter.ts +154 -0
- package/src/FileUpload/hooks/upload/useHandleDrop/createFileRejectionHelpers.ts +273 -0
- package/src/FileUpload/hooks/upload/useHandleDrop/useHandleDrop.ts +153 -0
- package/src/FileUpload/hooks/upload/useUploadAvailability/useUploadAvailability.ts +44 -0
- package/src/FileUpload/hooks/validation/createDropzoneValidator.ts +41 -0
- package/src/FileUpload/hooks/validation/useFileValidation.ts +25 -0
- package/src/FileUpload/hooks/validation/useFileValidationLogic.ts +107 -0
- package/src/FileUpload/hooks/validation/useValidationMessages.ts +92 -0
- package/src/FileUpload/hooks/validation/useValidationState.ts +171 -0
- package/src/FileUpload/index.ts +57 -0
- package/src/FileUpload/providers/FileUploadProvider.tsx +219 -0
- package/src/FileUpload/providers/UploadValidationProvider.tsx +159 -0
- package/src/FileUpload/testUtils/mockFilesAndImages.ts +64 -0
- package/src/FileUpload/testUtils/testUtils.ts +111 -0
- package/src/FileUpload/types/commonTypes.ts +267 -0
- package/src/FileUpload/types/index.ts +31 -0
- package/src/FileUpload/types/sharedTypes.ts +159 -0
- package/src/FileUpload/utils/constants.ts +79 -0
- package/src/FileUpload/utils/createMessageContext.ts +180 -0
- package/src/FileUpload/utils/getFileExtensionsFromAcceptedTypes.ts +73 -0
- package/src/FileUpload/utils/getFilePluralizationText.ts +68 -0
- package/src/FileUpload/utils/getMimeTypes.ts +26 -0
- package/src/FileUpload/utils/messageUtils.ts +41 -0
- package/src/FileUpload/utils/styles.ts +68 -0
- package/src/FormLabel/FormLabel.tsx +212 -0
- package/src/IconButton/IconButton.tsx +154 -0
- package/src/Icons/CreditCardIcon/CreditCardIcon.tsx +73 -0
- package/src/Icons/CreditCardIcon/cardIcons.tsx +270 -0
- package/src/Icons/IconBase.tsx +133 -0
- package/src/Icons/anyIcon.ts +3 -0
- package/src/Icons/generatedIcons/Archive.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowClockwise.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowDown.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowLeft.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowRight.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowSquareOut.tsx +51 -0
- package/src/Icons/generatedIcons/ArrowSquareRight.tsx +51 -0
- package/src/Icons/generatedIcons/ArrowUp.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowsCounterClockwise.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowsLeftRight.tsx +48 -0
- package/src/Icons/generatedIcons/ArrowsOutCardinal.tsx +48 -0
- package/src/Icons/generatedIcons/Bank.tsx +48 -0
- package/src/Icons/generatedIcons/Bell.tsx +51 -0
- package/src/Icons/generatedIcons/BookBookmark.tsx +51 -0
- package/src/Icons/generatedIcons/BookmarksSimple.tsx +51 -0
- package/src/Icons/generatedIcons/Broadcast.tsx +48 -0
- package/src/Icons/generatedIcons/CalendarBlank.tsx +48 -0
- package/src/Icons/generatedIcons/CalendarStar.tsx +51 -0
- package/src/Icons/generatedIcons/Camera.tsx +51 -0
- package/src/Icons/generatedIcons/CaretDown.tsx +48 -0
- package/src/Icons/generatedIcons/CaretLeft.tsx +48 -0
- package/src/Icons/generatedIcons/CaretRight.tsx +48 -0
- package/src/Icons/generatedIcons/CaretUp.tsx +48 -0
- package/src/Icons/generatedIcons/Certificate.tsx +51 -0
- package/src/Icons/generatedIcons/ChartBar.tsx +48 -0
- package/src/Icons/generatedIcons/Check.tsx +51 -0
- package/src/Icons/generatedIcons/CheckCircle.tsx +48 -0
- package/src/Icons/generatedIcons/CirclesFour.tsx +51 -0
- package/src/Icons/generatedIcons/Clock.tsx +48 -0
- package/src/Icons/generatedIcons/ClockCountdown.tsx +48 -0
- package/src/Icons/generatedIcons/Close.tsx +51 -0
- package/src/Icons/generatedIcons/CloudArrowUp.tsx +51 -0
- package/src/Icons/generatedIcons/CloudWarning.tsx +51 -0
- package/src/Icons/generatedIcons/Code.tsx +48 -0
- package/src/Icons/generatedIcons/Compass.tsx +51 -0
- package/src/Icons/generatedIcons/Confetti.tsx +51 -0
- package/src/Icons/generatedIcons/Copy.tsx +48 -0
- package/src/Icons/generatedIcons/CornersOut.tsx +48 -0
- package/src/Icons/generatedIcons/CreditCard.tsx +48 -0
- package/src/Icons/generatedIcons/Crown.tsx +51 -0
- package/src/Icons/generatedIcons/CrownSimple.tsx +51 -0
- package/src/Icons/generatedIcons/CurrencyCircleDollar.tsx +48 -0
- package/src/Icons/generatedIcons/CurrencyDollarSimple.tsx +51 -0
- package/src/Icons/generatedIcons/Desktop.tsx +51 -0
- package/src/Icons/generatedIcons/Detective.tsx +51 -0
- package/src/Icons/generatedIcons/DotOutline.tsx +46 -0
- package/src/Icons/generatedIcons/DotsSixVertical.tsx +51 -0
- package/src/Icons/generatedIcons/DotsThreeOutline.tsx +51 -0
- package/src/Icons/generatedIcons/DotsThreeOutlineVertical.tsx +51 -0
- package/src/Icons/generatedIcons/DownloadSimple.tsx +51 -0
- package/src/Icons/generatedIcons/EnvelopeSimple.tsx +48 -0
- package/src/Icons/generatedIcons/Eraser.tsx +51 -0
- package/src/Icons/generatedIcons/Eye.tsx +51 -0
- package/src/Icons/generatedIcons/EyeSlash.tsx +51 -0
- package/src/Icons/generatedIcons/FacebookLogo.tsx +48 -0
- package/src/Icons/generatedIcons/FileArchive.tsx +48 -0
- package/src/Icons/generatedIcons/FileArrowDown.tsx +48 -0
- package/src/Icons/generatedIcons/FileCsv.tsx +48 -0
- package/src/Icons/generatedIcons/FilePdf.tsx +48 -0
- package/src/Icons/generatedIcons/FileText.tsx +48 -0
- package/src/Icons/generatedIcons/Files.tsx +51 -0
- package/src/Icons/generatedIcons/Fire.tsx +51 -0
- package/src/Icons/generatedIcons/Flag.tsx +51 -0
- package/src/Icons/generatedIcons/FlagBannerFold.tsx +48 -0
- package/src/Icons/generatedIcons/FloppyDisk.tsx +51 -0
- package/src/Icons/generatedIcons/Gauge.tsx +51 -0
- package/src/Icons/generatedIcons/Gavel.tsx +51 -0
- package/src/Icons/generatedIcons/Gear.tsx +51 -0
- package/src/Icons/generatedIcons/GlobeHemisphereWest.tsx +51 -0
- package/src/Icons/generatedIcons/GoogleLogo.tsx +48 -0
- package/src/Icons/generatedIcons/GridNine.tsx +51 -0
- package/src/Icons/generatedIcons/HandCoins.tsx +51 -0
- package/src/Icons/generatedIcons/HandbagSimple.tsx +51 -0
- package/src/Icons/generatedIcons/Headset.tsx +51 -0
- package/src/Icons/generatedIcons/HeartStraight.tsx +51 -0
- package/src/Icons/generatedIcons/HourglassLow.tsx +48 -0
- package/src/Icons/generatedIcons/House.tsx +51 -0
- package/src/Icons/generatedIcons/Image.tsx +51 -0
- package/src/Icons/generatedIcons/ImageSquare.tsx +51 -0
- package/src/Icons/generatedIcons/ImagesSquare.tsx +51 -0
- package/src/Icons/generatedIcons/Info.tsx +48 -0
- package/src/Icons/generatedIcons/InstagramLogo.tsx +51 -0
- package/src/Icons/generatedIcons/Lightning.tsx +48 -0
- package/src/Icons/generatedIcons/Link.tsx +51 -0
- package/src/Icons/generatedIcons/LinkedinLogo.tsx +51 -0
- package/src/Icons/generatedIcons/List.tsx +48 -0
- package/src/Icons/generatedIcons/Lock.tsx +51 -0
- package/src/Icons/generatedIcons/LockOpen.tsx +51 -0
- package/src/Icons/generatedIcons/MagnifyingGlass.tsx +48 -0
- package/src/Icons/generatedIcons/MapPin.tsx +51 -0
- package/src/Icons/generatedIcons/MapPinSimpleArea.tsx +48 -0
- package/src/Icons/generatedIcons/Medal.tsx +48 -0
- package/src/Icons/generatedIcons/Megaphone.tsx +48 -0
- package/src/Icons/generatedIcons/Minus.tsx +45 -0
- package/src/Icons/generatedIcons/Money.tsx +51 -0
- package/src/Icons/generatedIcons/Notches.tsx +48 -0
- package/src/Icons/generatedIcons/NotePencil.tsx +48 -0
- package/src/Icons/generatedIcons/Package.tsx +51 -0
- package/src/Icons/generatedIcons/PaintBrush.tsx +51 -0
- package/src/Icons/generatedIcons/PaperPlaneTilt.tsx +51 -0
- package/src/Icons/generatedIcons/Paperclip.tsx +51 -0
- package/src/Icons/generatedIcons/Pause.tsx +51 -0
- package/src/Icons/generatedIcons/PencilLine.tsx +51 -0
- package/src/Icons/generatedIcons/PencilRuler.tsx +51 -0
- package/src/Icons/generatedIcons/PencilSimple.tsx +51 -0
- package/src/Icons/generatedIcons/Phone.tsx +51 -0
- package/src/Icons/generatedIcons/PinterestLogo.tsx +51 -0
- package/src/Icons/generatedIcons/Play.tsx +51 -0
- package/src/Icons/generatedIcons/Plus.tsx +51 -0
- package/src/Icons/generatedIcons/PlusCircle.tsx +48 -0
- package/src/Icons/generatedIcons/Printer.tsx +51 -0
- package/src/Icons/generatedIcons/Question.tsx +48 -0
- package/src/Icons/generatedIcons/Receipt.tsx +51 -0
- package/src/Icons/generatedIcons/Rows.tsx +51 -0
- package/src/Icons/generatedIcons/SealCheck.tsx +51 -0
- package/src/Icons/generatedIcons/SelectionSlash.tsx +48 -0
- package/src/Icons/generatedIcons/ShareNetwork.tsx +51 -0
- package/src/Icons/generatedIcons/ShieldCheck.tsx +51 -0
- package/src/Icons/generatedIcons/ShieldStar.tsx +51 -0
- package/src/Icons/generatedIcons/ShoppingCart.tsx +48 -0
- package/src/Icons/generatedIcons/ShuffleAngular.tsx +48 -0
- package/src/Icons/generatedIcons/SidebarSimple.tsx +48 -0
- package/src/Icons/generatedIcons/SlidersHorizontal.tsx +51 -0
- package/src/Icons/generatedIcons/Smiley.tsx +48 -0
- package/src/Icons/generatedIcons/Sparkle.tsx +51 -0
- package/src/Icons/generatedIcons/SpinnerGap.tsx +48 -0
- package/src/Icons/generatedIcons/StackPlus.tsx +48 -0
- package/src/Icons/generatedIcons/Star.tsx +51 -0
- package/src/Icons/generatedIcons/Storefront.tsx +51 -0
- package/src/Icons/generatedIcons/Swap.tsx +51 -0
- package/src/Icons/generatedIcons/Tag.tsx +51 -0
- package/src/Icons/generatedIcons/ThumbsDown.tsx +48 -0
- package/src/Icons/generatedIcons/ThumbsUp.tsx +48 -0
- package/src/Icons/generatedIcons/Toolbox.tsx +48 -0
- package/src/Icons/generatedIcons/Trash.tsx +48 -0
- package/src/Icons/generatedIcons/TrendUp.tsx +48 -0
- package/src/Icons/generatedIcons/Trophy.tsx +51 -0
- package/src/Icons/generatedIcons/Truck.tsx +51 -0
- package/src/Icons/generatedIcons/UploadSimple.tsx +51 -0
- package/src/Icons/generatedIcons/User.tsx +48 -0
- package/src/Icons/generatedIcons/Users.tsx +48 -0
- package/src/Icons/generatedIcons/UsersThree.tsx +51 -0
- package/src/Icons/generatedIcons/VideoCamera.tsx +51 -0
- package/src/Icons/generatedIcons/Warning.tsx +51 -0
- package/src/Icons/generatedIcons/WarningCircle.tsx +48 -0
- package/src/Icons/generatedIcons/WifiHigh.tsx +51 -0
- package/src/Icons/generatedIcons/XCircle.tsx +48 -0
- package/src/Icons/generatedIcons/XLogo.tsx +48 -0
- package/src/Icons/generatedIcons/YoutubeLogo.tsx +51 -0
- package/src/Icons/importedIcons.ts +152 -0
- package/src/Icons/index.ts +149 -0
- package/src/Icons/socialIcons/appleSocialIcon.tsx +50 -0
- package/src/Icons/socialIcons/facebookSocialIcon.tsx +41 -0
- package/src/Icons/socialIcons/googleSocialIcon.tsx +134 -0
- package/src/ImageCluster/ImageCluster.tsx +125 -0
- package/src/ImageSlider/ImageSlider.tsx +584 -0
- package/src/ImageSlider/ImageSlider.types.ts +90 -0
- package/src/ImageSlider/components/IndexIndicator/IndexIndicator.tsx +21 -0
- package/src/ImageSlider/components/NavigationButtons/NavigationButtons.tsx +113 -0
- package/src/ImageSlider/components/ResponsiveImage/ResponsiveImage.tsx +114 -0
- package/src/ImageSlider/components/ResponsiveImage/index.ts +1 -0
- package/src/ImageSlider/components/Thumbnails/Thumbnails.tsx +184 -0
- package/src/ImageSlider/constants.ts +59 -0
- package/src/ImageSlider/hooks/index.ts +3 -0
- package/src/ImageSlider/hooks/useImageSlider.ts +57 -0
- package/src/ImageSlider/hooks/useImageSliderNavigation.ts +133 -0
- package/src/ImageSlider/hooks/useImageSliderScrollHandler.ts +171 -0
- package/src/ImageSlider/index.ts +3 -0
- package/src/ImageSlider/utils/imageOptimization.ts +97 -0
- package/src/ImageSlider/utils/index.ts +1 -0
- package/src/InlineNotification/InlineNotification.tsx +95 -0
- package/src/JumpMenu/JumpMenu.tsx +395 -0
- package/src/JumpMenu/components/JumpMenuItem/JumpMenuItem.tsx +65 -0
- package/src/JumpMenu/hooks/useContainerTracking.ts +171 -0
- package/src/JumpMenu/hooks/useIntersectionObserver.ts +77 -0
- package/src/JumpMenu/hooks/useKeyboardNavigation.ts +102 -0
- package/src/JumpMenu/hooks/useResizeObserver.ts +53 -0
- package/src/JumpMenu/hooks/useSectionObserver.ts +102 -0
- package/src/JumpMenu/index.ts +2 -0
- package/src/JumpMenu/types/index.ts +19 -0
- package/src/Loading/Loading.tsx +39 -0
- package/src/Loading/components/LoadingDot/LoadingDot.tsx +16 -0
- package/src/LoadingSpinner/LoadingSpinner.tsx +20 -0
- package/src/Menu/Menu.tsx +372 -0
- package/src/Menu/components/MenuDivider/MenuDivider.tsx +5 -0
- package/src/Menu/components/MenuItem/MenuItem.tsx +298 -0
- package/src/Menu/context/menuContext.tsx +20 -0
- package/src/Menu/hooks/useMenu.tsx +18 -0
- package/src/Menu/index.ts +3 -0
- package/src/Modal/ComposableModal.tsx +321 -0
- package/src/Modal/Modal.tsx +231 -0
- package/src/Modal/components/BackButton/BackButton.tsx +43 -0
- package/src/Modal/components/Backdrop/Backdrop.tsx +62 -0
- package/src/Modal/components/CloseButton/CloseButton.tsx +55 -0
- package/src/Modal/components/ModalActions/ModalActions.tsx +135 -0
- package/src/Modal/components/ModalContent/ModalContent.tsx +163 -0
- package/src/Modal/components/ModalHeader/ModalHeader.tsx +84 -0
- package/src/Modal/components/ModalHeader/hooks/useHeaderAnimation.tsx +49 -0
- package/src/Modal/components/ModalProgressSteps/ModalProgressSteps.tsx +26 -0
- package/src/Modal/components/ModalSubTitle/ModalSubTitle.tsx +29 -0
- package/src/Modal/components/ModalTitle/ModalTitle.tsx +22 -0
- package/src/Modal/components/PreventModalScroll/PreventModalScroll.tsx +106 -0
- package/src/Modal/components/index.ts +12 -0
- package/src/Modal/context.ts +33 -0
- package/src/Modal/hooks/useCloseModal.ts +140 -0
- package/src/NotificationBadge/NotificationBadge.tsx +34 -0
- package/src/Pagination/AdvancedPagination.tsx +48 -0
- package/src/Pagination/Pagination.tsx +216 -0
- package/src/Pagination/components/AdvancedPaginator/AdvancedPaginator.tsx +52 -0
- package/src/Pagination/components/AdvancedPaginator/components/PageSelect/PageSelect.tsx +43 -0
- package/src/Pagination/components/ItemCountDisplay/ItemCountDisplay.tsx +32 -0
- package/src/Pagination/components/ItemCountSelect/ItemCountSelect.tsx +33 -0
- package/src/Pagination/index.tsx +3 -0
- package/src/Pagination/paginationProvider.tsx +234 -0
- package/src/Pagination/utils.tsx +36 -0
- package/src/PhoneInput/PhoneInput.tsx +515 -0
- package/src/PhoneInput/useDropdownLogic.tsx +163 -0
- package/src/ProgressCircle/ProgressCircle.tsx +246 -0
- package/src/ProgressCircle/hooks/useProgressStatusTransitions.ts +49 -0
- package/src/ProgressCircle/utils/progressCircle.constants.ts +27 -0
- package/src/ProgressSteps/ProgressSteps.tsx +160 -0
- package/src/SaveConfetti/SaveConfetti.tsx +277 -0
- package/src/SaveConfetti/index.ts +2 -0
- package/src/SearchInput/SearchInput.tsx +237 -0
- package/src/SegmentedControl/SegmentedControl.tsx +111 -0
- package/src/SegmentedControl/SegmentedControlGroup.tsx +94 -0
- package/src/SegmentedControl/index.ts +4 -0
- package/src/Select/Select.tsx +154 -0
- package/src/Select/SelectAsync.tsx +13 -0
- package/src/Select/SelectAsyncCreatable.tsx +14 -0
- package/src/Select/SelectCreatable.tsx +12 -0
- package/src/Select/reexportedComponents.tsx +5 -0
- package/src/Select/selectComponents.tsx +305 -0
- package/src/Skeleton/Skeleton.tsx +13 -0
- package/src/SplitButton/SplitButton.tsx +298 -0
- package/src/SplitButton/SplitButtonTrigger.tsx +55 -0
- package/src/StarRating/StarRating.tsx +165 -0
- package/src/StarRating/components/StarComponent/StarComponent.tsx +44 -0
- package/src/Table/Table.tsx +474 -0
- package/src/Table/components/TableHeader/TableHeader.tsx +166 -0
- package/src/Table/components/TablePagination/TablePagination.tsx +18 -0
- package/src/Table/components/TablePagination/components/ItemCountDisplay/ItemCountDisplay.tsx +17 -0
- package/src/Table/components/TablePagination/components/ItemCountSelect/ItemCountSelect.tsx +31 -0
- package/src/Table/components/TablePagination/components/TablePaginator/TablePaginator.tsx +37 -0
- package/src/Table/components/TablePagination/components/TablePaginator/components/PageSelect/PageSelect.tsx +32 -0
- package/src/Table/components/TableRow/TableRows.tsx +147 -0
- package/src/Table/components/TableRow/components/TableRowCell/TableRowCell.tsx +49 -0
- package/src/Table/components/TableShadow/TableShadow.tsx +46 -0
- package/src/Table/index.ts +2 -0
- package/src/Table/sharedState.ts +30 -0
- package/src/Table/sharedStyles.ts +1 -0
- package/src/Table/types.ts +55 -0
- package/src/Tabs/Tabs.tsx +358 -0
- package/src/TextArea/TextArea.tsx +159 -0
- package/src/TextInput/TextInput.tsx +173 -0
- package/src/Toast/Toast.tsx +64 -0
- package/src/Toast/components/ToastContainer/ToastContainer.tsx +48 -0
- package/src/Toast/index.ts +2 -0
- package/src/Toast/types/role.ts +1 -0
- package/src/Toast/utils/getIcon.tsx +41 -0
- package/src/ToggleSwitch/ToggleSwitch.tsx +188 -0
- package/src/Tooltip/InfoIconTooltip.tsx +47 -0
- package/src/Tooltip/Tooltip.tsx +41 -0
- package/src/Typography/InlineButton/InlineButton.tsx +167 -0
- package/src/Typography/Links/Links.tsx +113 -0
- package/src/Typography/Text/Text.tsx +239 -0
- package/src/ViewMore/ViewMore.tsx +226 -0
- package/src/WebRTCPlayer/WebRTCPlayer.tsx +325 -0
- package/src/WebRTCPlayer/adaptor/NativeWebRTCAdaptor.ts +588 -0
- package/src/WebRTCPlayer/hooks/useWebRTCStream.ts +571 -0
- package/src/WebRTCPlayer/index.ts +22 -0
- package/src/WebRTCPlayer/types.ts +95 -0
- package/src/breakpoints/index.tsx +1 -0
- package/src/breakpoints/utils.tsx +50 -0
- package/src/declarations.d.ts +7 -0
- package/src/grid/gridHighlighter.tsx +83 -0
- package/src/grid/index.ts +3 -0
- package/src/grid/pageGrid.tsx +37 -0
- package/src/grid/useSubGridCSS.tsx +214 -0
- package/src/hooks/useHorizontalScrollFade.ts +44 -0
- package/src/hooks/usePrevious.ts +14 -0
- package/src/index.ts +351 -0
- package/src/intl/index.ts +4 -0
- package/src/intl/utils.ts +67 -0
- package/src/mixins/horizontalScrollFadeMixin.ts +56 -0
- package/src/mixins/index.ts +18 -0
- package/src/mixins/propMixins.ts +389 -0
- package/src/providers/createContextProvider.ts +22 -0
- package/src/providers/designSystemProvider.tsx +218 -0
- package/src/providers/errorBoundaryProvider.tsx +179 -0
- package/src/providers/featureFlagProvider.tsx +18 -0
- package/src/providers/gridSizeProvider.tsx +23 -0
- package/src/providers/index.ts +12 -0
- package/src/providers/linkProvider.tsx +32 -0
- package/src/providers/normalize.tsx +93 -0
- package/src/providers/targets/DatePickerTarget.tsx +10 -0
- package/src/providers/targets/ModalTarget.tsx +14 -0
- package/src/providers/targets/TimePickerTarget.tsx +10 -0
- package/src/providers/themeContext.tsx +24 -0
- package/src/providers/windowSizeProvider.tsx +125 -0
- package/src/spacing/index.ts +1 -0
- package/src/spacing/spacing.ts +11 -0
- package/src/utils/countriesWithISOCodes.ts +1419 -0
- package/src/utils/dateTimeFormat.ts +257 -0
- package/src/utils/effectEventListener.ts +11 -0
- package/src/utils/formatFileSize.ts +18 -0
- package/src/utils/isClientSide.ts +1 -0
- package/src/utils/keepTransition.ts +15 -0
- package/src/utils/nodeEnv.ts +9 -0
- package/src/utils/smoothScrollTo.ts +65 -0
- package/src/utils/utilityTypes.ts +13 -0
- package/table.cjs +1 -1
- package/table.mjs +1 -1
- package/tabs.cjs +1 -1
- package/tabs.cjs.map +1 -1
- package/tabs.mjs +1 -1
- package/tabs.mjs.map +1 -1
- package/textArea.cjs.map +1 -1
- package/textArea.mjs.map +1 -1
- package/viewMore.cjs +1 -1
- package/viewMore.mjs +1 -1
- package/BottomSheet-ZV_eq3xt.mjs.map +0 -1
- package/BottomSheet-emWP9Fct.cjs.map +0 -1
- package/FavoriteButton-CC3qL0lR.mjs.map +0 -1
- package/FavoriteButton-DliYzkfu.cjs.map +0 -1
- package/FileUpload--e_UJ_ek.cjs.map +0 -1
- package/FileUpload-p_pl9NXr.mjs.map +0 -1
- package/ImageSlider-BidXfnLj.cjs.map +0 -1
- package/ImageSlider-CDrg_TbL.mjs.map +0 -1
- package/Menu-ClUogmwE.cjs.map +0 -1
- package/Menu-Cxu8CaX1.mjs.map +0 -1
- package/Modal-CiBqXyiK.cjs.map +0 -1
- package/Select-BXDjzyDs.cjs.map +0 -1
- package/Select-BkZu8OLs.mjs.map +0 -1
- package/ViewMore-BBoUvo7p.cjs.map +0 -1
- package/ViewMore-BrZPuE4E.mjs.map +0 -1
- package/buttonColorClasses-B7OU4aQA.mjs.map +0 -1
- package/buttonColorClasses-C3hg1at8.cjs.map +0 -1
|
@@ -61,7 +61,7 @@ type FavoriteButtonProps = BaseFavoriteButtonProps & {
|
|
|
61
61
|
/**
|
|
62
62
|
* When true, fires the nudge animation (wiggle + twirl + shimmer).
|
|
63
63
|
* Only meaningful for the `labeled-animated` variant.
|
|
64
|
-
* Reset to false after ~
|
|
64
|
+
* Reset to false after ~650ms to re-arm.
|
|
65
65
|
*/
|
|
66
66
|
isWiggling?: boolean;
|
|
67
67
|
/**
|
|
@@ -139,4 +139,4 @@ declare const FavoriteButton: import("react").ForwardRefExoticComponent<BaseFavo
|
|
|
139
139
|
} & import("react").RefAttributes<HTMLButtonElement>>;
|
|
140
140
|
//#endregion
|
|
141
141
|
export { BaseFavoriteButtonProps as a, IconOnlyFavoriteButtonProps as c, useFeatureFlag as i, LabeledFavoriteButtonProps as l, cn as n, FavoriteButtonProps as o, useFeatureFlags as r, FavoriteButtonVariant as s, FavoriteButton as t };
|
|
142
|
-
//# sourceMappingURL=FavoriteButton-
|
|
142
|
+
//# sourceMappingURL=FavoriteButton-B8r_qtlj.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FavoriteButton-
|
|
1
|
+
{"version":3,"file":"FavoriteButton-B8r_qtlj.d.cts","names":[],"sources":["../src/FavoriteButton/types/favoriteButton.ts","../src/FeatureFlags/hooks/useFeatureFlag.tsx","../src/FeatureFlags/hooks/useFeatureFlags.tsx","../src/FavoriteButton/FavoriteButton.tsx"],"mappings":";;;;;;;;;;;;;KAWY,qBAAA;;;;UAKK,uBAAA,SAAgC,IAAA,CAAK,oBAAA,CAAqB,iBAAA;EACvE,SAAA;EACA,IAAA;AAAA;;;;KAMQ,0BAAA,GAA6B,uBAAuB;;;;;EAK5D,cAAA;;;;;EAKA,KAAA;AAAA;;;;KAMQ,2BAAA,GAA8B,uBAAuB;;;;EAI7D,KAAK;AAAA;;;;KAMG,mBAAA,GAAsB,uBAAA;;;;;EAK9B,cAAA;;;;;;EAMA,YAAA;;;;;;EAMA,UAAA;;;;;EAKA,KAAA;EACA,YAAA,GAAe,cAAA,QAAsB,OAAA;IACjC,OAAA;EAAA;;;;;;;;;AA/DR;EA0EI,OAAA,GAAU,qBAAA;AAAA;;;;;;;;;;;;;;;;cCtED,cAAA,GAAkB,GAAW;;;;;;;;;;;;;cCH7B,eAAA,QAEZ,YAAA;;;;;;;;;;;;;;;;cCOY,cAAA,kBAAc,yBAAA,CA0CzB,uBAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_Icons = require("./Icons.cjs");
|
|
2
|
-
const require_buttonColorClasses = require("./buttonColorClasses-
|
|
2
|
+
const require_buttonColorClasses = require("./buttonColorClasses-CQQmLYfk.cjs");
|
|
3
3
|
const require_Button = require("./Button.cjs");
|
|
4
4
|
const require_Tooltip = require("./Tooltip.cjs");
|
|
5
5
|
const require_SaveConfetti = require("./SaveConfetti-DSJtuE3b.cjs");
|
|
@@ -43,7 +43,7 @@ const IconOnlyFavoriteButton = (0, react.forwardRef)(({ "aria-label": ariaLabel
|
|
|
43
43
|
className: (0, _evolve_ui_theme_system.cn)("group flex h-[30px] w-[30px] cursor-pointer items-center justify-center border border-solid", {
|
|
44
44
|
"rounded-container": shape === "square",
|
|
45
45
|
"rounded-full": shape === "circle"
|
|
46
|
-
}, "bg-background-primary text-surface-500", { "bg-background-primary text-critical-500": favorited }, "
|
|
46
|
+
}, "bg-background-primary text-surface-500", { "bg-background-primary text-critical-500": favorited }, "hui-focus-visible-outline focus-visible:outline-offset-1", "active:text-border-critical-400 active:bg-critical-50", "hover:bg-critical-50 hover:text-critical-400", "disabled:cursor-not-allowed disabled:bg-background-primary disabled:text-border-disabled", className),
|
|
47
47
|
"data-hui-id": "FavoriteButton",
|
|
48
48
|
disabled,
|
|
49
49
|
onClick,
|
|
@@ -87,7 +87,7 @@ const LabeledAnimatedFavoriteButton = (0, react.forwardRef)(({ "aria-label": ari
|
|
|
87
87
|
"aria-label": ariaLabel,
|
|
88
88
|
"aria-live": "polite",
|
|
89
89
|
"aria-pressed": favorited ?? false,
|
|
90
|
-
className: (0, _evolve_ui_theme_system.cn)("hui-focus-visible-outline relative flex max-w-full items-center justify-center whitespace-nowrap rounded-button text-center font-primary tracking-[var(--letter-spacing-button)] outline outline-1 -outline-offset-1 transition-colors disabled:text-text-disabled", favorited ? require_buttonColorClasses.outlinedCriticalClasses : require_buttonColorClasses.outlinedNeutralClasses, "gap-[4px] px-sm py-[13px] leading-[8px]", "h-[34px]", { "border-critical-500 text-critical-500": favorited }, "hover:border-critical-700 hover:bg-critical-50 hover:text-critical-700", "active:border-critical-900 active:bg-critical-100 active:text-critical-900", isWiggling && "animate-saveButtonWiggle
|
|
90
|
+
className: (0, _evolve_ui_theme_system.cn)("hui-focus-visible-outline relative flex max-w-full items-center justify-center whitespace-nowrap rounded-button text-center font-primary tracking-[var(--letter-spacing-button)] outline outline-1 -outline-offset-1 transition-colors disabled:text-text-disabled", favorited ? require_buttonColorClasses.outlinedCriticalClasses : require_buttonColorClasses.outlinedNeutralClasses, "gap-[4px] px-sm py-[13px] leading-[8px]", "h-[34px]", { "border-critical-500 text-critical-500": favorited }, "hover:border-critical-700 hover:bg-critical-50 hover:text-critical-700", "active:border-critical-900 active:bg-critical-100 active:text-critical-900", isWiggling && "animate-saveButtonWiggle", isWiggling && !favorited && "hui-fb-color-flash", isActivating && "animate-saveButtonPulse", className),
|
|
91
91
|
"data-hui-id": "FavoriteButton",
|
|
92
92
|
disabled,
|
|
93
93
|
onClick,
|
|
@@ -98,14 +98,14 @@ const LabeledAnimatedFavoriteButton = (0, react.forwardRef)(({ "aria-label": ari
|
|
|
98
98
|
style: BUTTON_INLINE_STYLES,
|
|
99
99
|
...restProps,
|
|
100
100
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
101
|
-
className: (0, _evolve_ui_theme_system.cn)("hui-fb-icon-frame relative flex items-center justify-center", isWiggling && !favorited && "text-critical-500", isWiggling && "animate-saveHeartTwirlBloom
|
|
101
|
+
className: (0, _evolve_ui_theme_system.cn)("hui-fb-icon-frame relative flex items-center justify-center", isWiggling && !favorited && "text-critical-500", isWiggling && "animate-saveHeartTwirlBloom"),
|
|
102
102
|
style: {
|
|
103
103
|
height: "14px",
|
|
104
104
|
perspective: "200px",
|
|
105
105
|
width: "14px"
|
|
106
106
|
},
|
|
107
107
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Icons.HeartStraight, {
|
|
108
|
-
className: (0, _evolve_ui_theme_system.cn)("[transform-style:preserve-3d]", isActivating && "animate-saveHeartPop
|
|
108
|
+
className: (0, _evolve_ui_theme_system.cn)("[transform-style:preserve-3d]", isActivating && "animate-saveHeartPop"),
|
|
109
109
|
color: "inherit",
|
|
110
110
|
size: "xs",
|
|
111
111
|
style: favorited || isActive || isWiggling ? "fill" : "bold"
|
|
@@ -201,4 +201,4 @@ Object.defineProperty(exports, "FavoriteButton", {
|
|
|
201
201
|
}
|
|
202
202
|
});
|
|
203
203
|
|
|
204
|
-
//# sourceMappingURL=FavoriteButton-
|
|
204
|
+
//# sourceMappingURL=FavoriteButton-BkIaWfgD.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FavoriteButton-BkIaWfgD.cjs","names":["HeartStraight","outlinedCriticalClasses","outlinedNeutralClasses","HeartStraight","SaveConfetti","HeartStraight","Button","Tooltip"],"sources":["../src/FavoriteButton/hooks/useFavoriteButtonState.ts","../src/FavoriteButton/components/IconOnlyFavoriteButton/IconOnlyFavoriteButton.tsx","../src/FavoriteButton/components/LabeledAnimatedFavoriteButton/LabeledAnimatedFavoriteButton.tsx","../src/FavoriteButton/components/SmallHeartStraightIcon/SmallHeartStraightIcon.tsx","../src/FavoriteButton/components/LabeledFavoriteButton/LabeledFavoriteButton.tsx","../src/FavoriteButton/FavoriteButton.tsx"],"sourcesContent":["import { useState } from 'react';\n\n/**\n * Custom hook for managing the active state of the FavoriteButton\n * @returns Object containing the active state and event handlers\n */\nexport const useFavoriteButtonState = () => {\n const [isActive, setIsActive] = useState(false);\n\n const handleMouseDown = () => {\n setIsActive(true);\n };\n\n const handleMouseUp = () => {\n setIsActive(false);\n };\n\n const handleMouseLeave = () => {\n if (isActive) {\n setIsActive(false);\n }\n };\n\n return {\n handleMouseDown,\n handleMouseLeave,\n handleMouseUp,\n isActive,\n };\n};\n","import { cn } from '@evolve.ui/theme-system';\nimport { forwardRef } from 'react';\n\nimport { HeartStraight } from '../../../Icons';\nimport { useFavoriteButtonState } from '../../hooks/useFavoriteButtonState';\nimport { IconOnlyFavoriteButtonProps } from '../../types/favoriteButton';\n\n/**\n * Icon-only variant of the FavoriteButton component\n * Displays only a heart icon in either a circle or square shape\n */\nexport const IconOnlyFavoriteButton = forwardRef<HTMLButtonElement, IconOnlyFavoriteButtonProps>(\n (\n {\n 'aria-label': ariaLabel = 'Favorite Toggle',\n className,\n disabled,\n favorited,\n onClick,\n shape,\n type,\n ...restProps\n },\n ref\n ) => {\n const { handleMouseDown, handleMouseLeave, handleMouseUp, isActive } = useFavoriteButtonState();\n\n return (\n <button\n aria-label={ariaLabel}\n aria-pressed={Boolean(favorited)}\n className={cn(\n // Base styles\n 'group flex h-[30px] w-[30px] cursor-pointer items-center justify-center border border-solid',\n // Shape styles\n {\n 'rounded-container': shape === 'square',\n 'rounded-full': shape === 'circle',\n },\n // Default state\n 'bg-background-primary text-surface-500',\n // Selected state\n {\n 'bg-background-primary text-critical-500': favorited,\n },\n // Focus state\n // Atomic: the bare-focus outline suppression had to go in the same edit as the de-prefix.\n // Prefixed,\n // the ring was 0,3,0 and beat it; bare it is 0,2,0 and would lose (DS-98 Phase 0).\n 'hui-focus-visible-outline focus-visible:outline-offset-1',\n // Active state - immediately show critical color when clicked\n 'active:text-border-critical-400 active:bg-critical-50',\n // Hover state\n 'hover:bg-critical-50 hover:text-critical-400',\n // Disabled state\n 'disabled:cursor-not-allowed disabled:bg-background-primary disabled:text-border-disabled',\n className\n )}\n data-hui-id=\"FavoriteButton\"\n disabled={disabled}\n onClick={onClick}\n onMouseDown={handleMouseDown}\n onMouseLeave={handleMouseLeave}\n onMouseUp={handleMouseUp}\n ref={ref}\n type={type as 'button' | 'submit' | 'reset' | undefined}\n {...restProps}\n >\n <HeartStraight\n className={cn(\n 'mt-[1px] bg-transparent text-current transition-transform duration-200 ease-in-out',\n {\n 'group-hover:scale-[1.125]': !disabled,\n }\n )}\n color=\"inherit\"\n size=\"sm\"\n style={favorited || isActive ? 'fill' : 'regular'}\n />\n </button>\n );\n }\n);\n","import { cn } from '@evolve.ui/theme-system';\nimport { ButtonHTMLAttributes, CSSProperties, forwardRef, useEffect, useImperativeHandle, useRef } from 'react';\n\nimport { outlinedCriticalClasses, outlinedNeutralClasses } from '../../../Button/buttonColorClasses';\nimport { HeartStraight } from '../../../Icons';\nimport { SaveConfetti, type SaveConfettiHandle } from '../../../SaveConfetti/SaveConfetti';\nimport { useFavoriteButtonState } from '../../hooks/useFavoriteButtonState';\n\n/**\n * Labeled-animated variant of the FavoriteButton component.\n *\n * Visually identical to the `labeled` variant but exposes `isWiggling` and\n * `isActivating` props that trigger the enhanced save-button nudge animations:\n *\n * - `isWiggling`: side-to-side wiggle (button), 3D twirl + bloom (heart icon),\n * color flash (critical fill pulse on heart when not favorited), and shimmer (label text).\n * During nudge the heart uses `fill` weight with critical color; at rest unfavorited uses `bold`.\n * Apply for ~650ms, then reset to false to re-arm.\n *\n * - `isActivating`: pulse (button) and heart pop (icon). Apply for ~500ms.\n *\n * Animation CSS is driven by Tailwind `animate-*` utilities from the theme plugin\n * (`theme.extend.animation`) — no runtime style injection. The shimmer uses the\n * `.hui-fb-shimmer` component class from the plugin for its multi-property CSS.\n * The heart-color flash uses `.hui-fb-color-flash` to animate fill on the nested\n * SVG path via a descendant selector. Icon weight: `bold` when unfavorited at rest,\n * `fill` during nudge, favorited, or active press — matching the static `labeled` variant at rest.\n *\n * Reduced motion is gated once at the registry level\n * (`theme-system/src/tailwind/reducedMotion.ts`), so these call sites deliberately carry no\n * `motion-reduce:` variants — adding them back would reintroduce a second mechanism. The\n * shimmer is the one exception: `.hui-fb-shimmer` also drops its gradient under reduce, because\n * the label is painted *by* that gradient (`-webkit-text-fill-color: transparent`) and would\n * otherwise be illegible.\n */\n\ntype Props = {\n /** Accessible label for screen readers. @default 'Favorite Toggle' */\n 'aria-label'?: string;\n /** Whether the item is currently favorited. */\n favorited?: boolean;\n /** Label text shown when favorited. @default 'Saved' */\n favoritedLabel?: string;\n /**\n * When true, fires the save-click animation (button pulse + heart pop) and\n * a mini confetti burst from the button center.\n * Reset to false after ~500ms to re-arm.\n */\n isActivating?: boolean;\n /**\n * When true, fires the nudge animation (wiggle + twirl + shimmer + color flash).\n * Reset to false after ~650ms to re-arm.\n */\n isWiggling?: boolean;\n /** Label text shown when not favorited. @default 'Save' */\n label?: string;\n} & Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'children' | 'style'>;\n\ntype AnimationPaletteCSSVar =\n | '--hui-save-color-critical-500'\n | '--hui-save-color-critical-300'\n | '--hui-save-color-critical-200'\n | '--hui-save-color-tertiary-400'\n | '--hui-save-color-tertiary-200';\n\nconst BUTTON_INLINE_STYLES: CSSProperties & Record<AnimationPaletteCSSVar, string> = {\n fontSize: 'var(--font-size-button-200)',\n fontWeight: 'var(--font-weight-button)',\n textTransform: 'var(--text-transform-button)' as CSSProperties['textTransform'],\n // Expose canonical animation palette tokens for downstream orchestration.\n '--hui-save-color-critical-500': 'var(--color-critical-500)',\n '--hui-save-color-critical-300': 'var(--color-critical-300)',\n '--hui-save-color-critical-200': 'var(--color-critical-200)',\n '--hui-save-color-tertiary-400': 'var(--color-tertiary-400)',\n '--hui-save-color-tertiary-200': 'var(--color-tertiary-200)',\n};\n\nexport const LabeledAnimatedFavoriteButton = forwardRef<HTMLButtonElement, Props>(\n (\n {\n 'aria-label': ariaLabel = 'Favorite Toggle',\n className,\n disabled,\n favorited,\n favoritedLabel = 'Saved',\n isActivating,\n isWiggling,\n label = 'Save',\n onClick,\n ...restProps\n },\n ref\n ) => {\n const { handleMouseDown, handleMouseLeave, handleMouseUp, isActive } = useFavoriteButtonState();\n\n const internalButtonRef = useRef<HTMLButtonElement>(null);\n const confettiRef = useRef<SaveConfettiHandle>(null);\n\n // Preserve consumer-facing ref contract while keeping internal button access for confetti\n useImperativeHandle(ref, () => internalButtonRef.current!);\n\n // Fire confetti burst when the save-click animation triggers\n useEffect(() => {\n if (!isActivating || !internalButtonRef.current) {\n return;\n }\n confettiRef.current?.fire(internalButtonRef.current);\n }, [isActivating]);\n\n return (\n <>\n <button\n aria-busy={false}\n aria-label={ariaLabel}\n aria-live=\"polite\"\n aria-pressed={favorited ?? false}\n className={cn(\n // Base — exact match to Button's base class string\n 'hui-focus-visible-outline relative flex max-w-full items-center justify-center whitespace-nowrap rounded-button text-center font-primary tracking-[var(--letter-spacing-button)] outline outline-1 -outline-offset-1 transition-colors disabled:text-text-disabled',\n // Color classes — same conditional used by LabeledFavoriteButton\n favorited ? outlinedCriticalClasses : outlinedNeutralClasses,\n // sm size\n 'gap-[4px] px-sm py-[13px] leading-[8px]',\n // Height override (matches LabeledFavoriteButton)\n 'h-[34px]',\n // Favorited state border\n { 'border-critical-500 text-critical-500': favorited },\n // Hover/active overrides — same className passed by LabeledFavoriteButton to Button\n 'hover:border-critical-700 hover:bg-critical-50 hover:text-critical-700',\n 'active:border-critical-900 active:bg-critical-100 active:text-critical-900',\n // Nudge animation — wiggle on button root + color flash on nested SVG path\n isWiggling && 'animate-saveButtonWiggle',\n isWiggling && !favorited && 'hui-fb-color-flash',\n // Save-click animation — pulse on button root\n isActivating && 'animate-saveButtonPulse',\n className\n )}\n data-hui-id=\"FavoriteButton\"\n disabled={disabled}\n onClick={onClick}\n onMouseDown={handleMouseDown}\n onMouseLeave={handleMouseLeave}\n onMouseUp={handleMouseUp}\n ref={internalButtonRef}\n style={BUTTON_INLINE_STYLES}\n {...restProps}\n >\n {/*\n * Perspective wrapper — 3D twirl animation targets this element.\n * Width/height matches Button's internal iconLeft container (14px for xs icon).\n */}\n <span\n className={cn(\n 'hui-fb-icon-frame relative flex items-center justify-center',\n // Critical color during nudge so fill weight reads red immediately (not surface-500 grey)\n isWiggling && !favorited && 'text-critical-500',\n // Nudge animation — 3D twirl + bloom on icon frame\n isWiggling && 'animate-saveHeartTwirlBloom'\n )}\n style={{ height: '14px', perspective: '200px', width: '14px' }}\n >\n <HeartStraight\n className={cn(\n '[transform-style:preserve-3d]',\n // Save-click animation — heart pop on SVG element\n isActivating && 'animate-saveHeartPop'\n )}\n color=\"inherit\"\n size=\"xs\"\n style={favorited || isActive || isWiggling ? 'fill' : 'bold'}\n />\n </span>\n {/* Shimmer wrapper — .hui-fb-shimmer bundles background-clip + gradient + animation */}\n <span\n className={cn('hui-fb-animated-label', isWiggling && 'hui-fb-shimmer animate-saveLabelShimmer')}\n >\n {favorited ? favoritedLabel : label}\n </span>\n </button>\n <SaveConfetti ref={confettiRef} />\n </>\n );\n }\n);\n\nLabeledAnimatedFavoriteButton.displayName = 'LabeledAnimatedFavoriteButton';\n","import { ComponentProps, forwardRef } from 'react';\n\nimport { CaretRight, HeartStraight } from '../../../Icons';\n\nexport const SmallHeartStraightIcon = forwardRef<SVGSVGElement, ComponentProps<typeof CaretRight>>((props, ref) => {\n return (\n <HeartStraight\n style=\"bold\"\n {...props}\n ref={ref}\n size=\"xs\"\n />\n );\n});\n","import { cn } from '@evolve.ui/theme-system';\nimport { ButtonHTMLAttributes, forwardRef } from 'react';\n\nimport { Button } from '../../../Button/Button';\nimport { useFavoriteButtonState } from '../../hooks/useFavoriteButtonState';\nimport { SmallHeartStraightIcon } from '../SmallHeartStraightIcon/SmallHeartStraightIcon';\n\n/**\n * Labeled variant of the FavoriteButton component\n * Displays a button with text and a heart icon\n */\n\ntype Props = {\n 'aria-label'?: string;\n favorited?: boolean;\n favoritedLabel?: string;\n label?: string;\n} & Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'style' | 'children'>;\n\nexport const LabeledFavoriteButton = forwardRef<HTMLButtonElement, Props>(\n (\n {\n 'aria-label': ariaLabel = 'Favorite Toggle',\n className,\n disabled,\n favorited,\n favoritedLabel = 'Saved',\n label = 'Save',\n onClick,\n ...restProps\n },\n ref\n ) => {\n const { handleMouseDown, handleMouseLeave, handleMouseUp, isActive } = useFavoriteButtonState();\n\n return (\n <Button\n aria-label={ariaLabel}\n aria-pressed={favorited ? true : false}\n className={cn(\n // Base styles\n 'h-[34px] text-surface-500',\n // Selected state\n {\n 'border-critical-500 text-critical-500': favorited,\n },\n // Hover state - same for both favorited and non-favorited\n 'hover:border-critical-700 hover:bg-critical-50 hover:text-critical-700',\n // Active states - different for favorited and non-favorited\n 'active:border-critical-900 active:bg-critical-100 active:text-critical-900',\n className\n )}\n data-hui-id=\"FavoriteButton\"\n disabled={disabled}\n iconLeft={SmallHeartStraightIcon}\n iconStyle={favorited || isActive ? 'fill' : 'bold'}\n onClick={onClick}\n onMouseDown={handleMouseDown}\n onMouseLeave={handleMouseLeave}\n onMouseUp={handleMouseUp}\n ref={ref}\n size=\"sm\"\n style={favorited ? 'critical' : 'neutral'}\n variant=\"outlined\"\n {...restProps}\n >\n {favorited ? favoritedLabel : label}\n </Button>\n );\n }\n);\n","import { forwardRef } from 'react';\n\nimport { Tooltip } from '../Tooltip/Tooltip';\nimport { IconOnlyFavoriteButton } from './components/IconOnlyFavoriteButton/IconOnlyFavoriteButton';\nimport { LabeledAnimatedFavoriteButton } from './components/LabeledAnimatedFavoriteButton/LabeledAnimatedFavoriteButton';\nimport { LabeledFavoriteButton } from './components/LabeledFavoriteButton/LabeledFavoriteButton';\nimport { FavoriteButtonProps } from './types/favoriteButton';\n\n/**\n * A button that allows users to mark an item as a favorite.\n * The button displays a heart icon that changes appearance when favorited.\n *\n * Be aware that if you're using the tooltip option, make sure to use a unique id\n * and set the `anchorSelect` prop on the tooltip to the id of the button.\n *\n * Available in four variants:\n * - `circle`: Shows only the heart icon in a circular button (default)\n * - `square`: Shows only the heart icon in a square button\n * - `labeled`: Shows a button with text and the heart icon\n * - `labeled-animated`: Shows a labeled button with animation-ready wrappers\n */\nexport const FavoriteButton = forwardRef<HTMLButtonElement, FavoriteButtonProps>((props, ref) => {\n const { isActivating, isWiggling, tooltipProps, variant = 'circle', ...restProps } = props;\n const { enabled = false, ...tooltipRestProps } = tooltipProps ?? {};\n\n // Use a mapping object to determine which component to render\n const variantComponents = {\n circle: (\n <IconOnlyFavoriteButton\n ref={ref}\n shape=\"circle\"\n {...restProps}\n />\n ),\n labeled: (\n <LabeledFavoriteButton\n ref={ref}\n {...restProps}\n />\n ),\n 'labeled-animated': (\n <LabeledAnimatedFavoriteButton\n ref={ref}\n isActivating={isActivating}\n isWiggling={isWiggling}\n {...restProps}\n />\n ),\n square: (\n <IconOnlyFavoriteButton\n ref={ref}\n shape=\"square\"\n {...restProps}\n />\n ),\n };\n\n return (\n <>\n {enabled && <Tooltip {...tooltipRestProps} />}\n {variantComponents[variant]}\n </>\n );\n});\n"],"mappings":";;;;;;;;;;;;;AAMA,MAAa,+BAA+B;CACxC,MAAM,CAAC,UAAU,gBAAA,GAAA,MAAA,SAAA,CAAwB,KAAK;CAE9C,MAAM,wBAAwB;EAC1B,YAAY,IAAI;CACpB;CAEA,MAAM,sBAAsB;EACxB,YAAY,KAAK;CACrB;CAEA,MAAM,yBAAyB;EAC3B,IAAI,UACA,YAAY,KAAK;CAEzB;CAEA,OAAO;EACH;EACA;EACA;EACA;CACJ;AACJ;;;;;;;AClBA,MAAa,0BAAA,GAAA,MAAA,WAAA,EAEL,EACI,cAAc,YAAY,mBAC1B,WACA,UACA,WACA,SACA,OACA,MACA,GAAG,aAEP,QACC;CACD,MAAM,EAAE,iBAAiB,kBAAkB,eAAe,aAAa,uBAAuB;CAE9F,OACI,iBAAA,GAAA,kBAAA,IAAA,CAAC,UAAD;EACI,cAAY;EACZ,gBAAc,QAAQ,SAAS;EAC/B,YAAA,GAAA,wBAAA,GAAA,CAEI,+FAEA;GACI,qBAAqB,UAAU;GAC/B,gBAAgB,UAAU;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|
|
|
61
61
|
/**
|
|
62
62
|
* When true, fires the nudge animation (wiggle + twirl + shimmer).
|
|
63
63
|
* Only meaningful for the `labeled-animated` variant.
|
|
64
|
-
* Reset to false after ~
|
|
64
|
+
* Reset to false after ~650ms to re-arm.
|
|
65
65
|
*/
|
|
66
66
|
isWiggling?: boolean;
|
|
67
67
|
/**
|
|
@@ -139,4 +139,4 @@ declare const FavoriteButton: import("react").ForwardRefExoticComponent<BaseFavo
|
|
|
139
139
|
} & import("react").RefAttributes<HTMLButtonElement>>;
|
|
140
140
|
//#endregion
|
|
141
141
|
export { BaseFavoriteButtonProps as a, IconOnlyFavoriteButtonProps as c, useFeatureFlag as i, LabeledFavoriteButtonProps as l, cn$1 as n, FavoriteButtonProps as o, useFeatureFlags as r, FavoriteButtonVariant as s, FavoriteButton as t };
|
|
142
|
-
//# sourceMappingURL=FavoriteButton-
|
|
142
|
+
//# sourceMappingURL=FavoriteButton-hIkGjcKH.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FavoriteButton-
|
|
1
|
+
{"version":3,"file":"FavoriteButton-hIkGjcKH.d.mts","names":[],"sources":["../src/FavoriteButton/types/favoriteButton.ts","../src/FeatureFlags/hooks/useFeatureFlag.tsx","../src/FeatureFlags/hooks/useFeatureFlags.tsx","../src/FavoriteButton/FavoriteButton.tsx"],"mappings":";;;;;;;;;;;;;KAWY,qBAAA;;;;UAKK,uBAAA,SAAgC,IAAA,CAAK,oBAAA,CAAqB,iBAAA;EACvE,SAAA;EACA,IAAA;AAAA;;;;KAMQ,0BAAA,GAA6B,uBAAuB;;;;;EAK5D,cAAA;;;;;EAKA,KAAA;AAAA;;;;KAMQ,2BAAA,GAA8B,uBAAuB;;;;EAI7D,KAAK;AAAA;;;;KAMG,mBAAA,GAAsB,uBAAA;;;;;EAK9B,cAAA;;;;;;EAMA,YAAA;;;;;;EAMA,UAAA;;;;;EAKA,KAAA;EACA,YAAA,GAAe,cAAA,QAAsB,OAAA;IACjC,OAAA;EAAA;;;;;;;;;AA/DR;EA0EI,OAAA,GAAU,qBAAA;AAAA;;;;;;;;;;;;;;;;cCtED,cAAA,GAAkB,GAAW;;;;;;;;;;;;;cCH7B,eAAA,QAEZ,YAAA;;;;;;;;;;;;;;;;cCOY,cAAA,kBAAc,yBAAA,CA0CzB,uBAAA"}
|
|
@@ -8,9 +8,9 @@ import { t as Checkbox } from "./ChoiceListItem-BqZ3bIj9.mjs";
|
|
|
8
8
|
import { formatFileSize } from "./utils/formatFileSize.mjs";
|
|
9
9
|
import { d as builtInErrorCodes, i as UploadValidationProvider, n as useFileValidation, o as resolveContextAwareMessage, s as createMessageContext, t as useImageFilePreviewUrl, u as ACCEPTED_MIME_TYPES } from "./hooks-D4sJ62Xl.mjs";
|
|
10
10
|
import { Tabs } from "./tabs.mjs";
|
|
11
|
-
import { t as Table } from "./Table-
|
|
12
|
-
import { r as MenuItem, t as Menu } from "./Menu-
|
|
13
|
-
import { t as ProgressCircle } from "./ProgressCircle-
|
|
11
|
+
import { t as Table } from "./Table-CQGtDpvH.mjs";
|
|
12
|
+
import { r as MenuItem, t as Menu } from "./Menu-Bn4smlEe.mjs";
|
|
13
|
+
import { t as ProgressCircle } from "./ProgressCircle-zSai1HTT.mjs";
|
|
14
14
|
import { cn } from "@evolve.ui/theme-system";
|
|
15
15
|
import { createContext, useCallback, useContext, useMemo, useRef, useState } from "react";
|
|
16
16
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -934,7 +934,7 @@ const GridFileCard = ({ actions = [], badge, className, "data-testid": dataTestI
|
|
|
934
934
|
})
|
|
935
935
|
}),
|
|
936
936
|
/* @__PURE__ */ jsx("div", {
|
|
937
|
-
className: cn("absolute inset-0", "flex items-end justify-center", "rounded-container bg-background-overlay/20 p-xs", "opacity-0 transition-opacity duration-200", "group-
|
|
937
|
+
className: cn("absolute inset-0", "flex items-end justify-center", "rounded-container bg-background-overlay/20 p-xs", "opacity-0 transition-opacity duration-200", "group-hover/grid-file-card:opacity-100 group-has-[:focus-visible]/grid-file-card:opacity-100", "cursor-pointer", { "cursor-grab": draggable }),
|
|
938
938
|
children: /* @__PURE__ */ jsxs("div", {
|
|
939
939
|
className: "flex items-center gap-xs",
|
|
940
940
|
children: [visibleActions.map((action, index) => /* @__PURE__ */ jsx(IconButton, {
|
|
@@ -1056,7 +1056,7 @@ const ListFileCard = ({ actions, cardStyle, className, "data-testid": dataTestId
|
|
|
1056
1056
|
color: isError ? "critical" : "secondary",
|
|
1057
1057
|
children: fileSize
|
|
1058
1058
|
});
|
|
1059
|
-
const actionBtnClasses = showActionsOnHover ? cn("opacity-0 group-
|
|
1059
|
+
const actionBtnClasses = showActionsOnHover ? cn("opacity-0 group-hover/list-file-card:opacity-100 group-has-[:focus-visible]/list-file-card:opacity-100", "focus-visible:opacity-100", "transition-opacity duration-200") : "";
|
|
1060
1060
|
const isProcessing = isPending || isProgressing;
|
|
1061
1061
|
let progressCircleStatus;
|
|
1062
1062
|
if (isPending) progressCircleStatus = "pending";
|
|
@@ -1703,4 +1703,4 @@ FileUploadCanvas.displayName = "FileUploadCanvas";
|
|
|
1703
1703
|
//#endregion
|
|
1704
1704
|
export { FileCard as a, FileDropzone as c, useFileUploadContext as d, FilePreviewList as i, FileUploadContext as l, FileDropzoneOverlay as n, ListFileCard as o, FileUpload as r, GridFileCard as s, FileUploadCanvas as t, FileUploadProvider as u };
|
|
1705
1705
|
|
|
1706
|
-
//# sourceMappingURL=FileUpload-
|
|
1706
|
+
//# sourceMappingURL=FileUpload-BfZOMsLs.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FileUpload-BfZOMsLs.mjs","names":[],"sources":["../src/FileUpload/providers/FileUploadProvider.tsx","../src/FileUpload/hooks/upload/useHandleDragEnter/useHandleDragEnter.ts","../src/FileUpload/hooks/upload/useHandleDrop/createFileRejectionHelpers.ts","../src/FileUpload/hooks/upload/useHandleDrop/useHandleDrop.ts","../src/FileUpload/hooks/upload/useUploadAvailability/useUploadAvailability.ts","../src/FileUpload/hooks/validation/createDropzoneValidator.ts","../src/FileUpload/utils/getMimeTypes.ts","../src/FileUpload/utils/styles.ts","../src/FileUpload/components/FileDropzone/components/DropzoneContent/DropzoneText.tsx","../src/FileUpload/components/FileDropzone/components/DropzoneContent/DropzoneContent.tsx","../src/FileUpload/components/FileDropzone/components/FileDropzoneDebugger/FileRejectionsDisplay.tsx","../src/FileUpload/components/FileDropzone/components/FileDropzoneDebugger/FileDropzoneDebugger.tsx","../src/FileUpload/components/FileDropzone/FileDropzone.tsx","../src/FileUpload/components/GridFileCard/utils/sortable.ts","../src/FileUpload/components/GridFileCard/GridFileCard.tsx","../src/FileUpload/components/ListFileCard/ListFileCard.tsx","../src/FileUpload/components/FileCard/FileCard.tsx","../src/FileUpload/components/FilePreviewList/virtualizerComponents/FilePreviewVirtualizedList/FilePreviewVirtualizedList.tsx","../src/FileUpload/components/FilePreviewList/FilePreviewList.tsx","../src/FileUpload/components/FileUpload/FileUpload.tsx","../src/FileUpload/components/FileDropzoneOverlay/components/OverlayDropzoneDragText.tsx","../src/FileUpload/components/FileDropzoneOverlay/components/OverlayDropzoneContent.tsx","../src/FileUpload/components/FileDropzoneOverlay/styles.ts","../src/FileUpload/components/FileDropzoneOverlay/FileDropzoneOverlay.tsx","../src/FileUpload/components/FileUploadCanvas/FileUploadCanvas.tsx"],"sourcesContent":["import { createContext, useContext, useState } from 'react';\n\nimport { FileResource } from '../types';\nimport { CommonFileTypes, FileError, FileRejection, FileValidator } from '../types/commonTypes';\nimport { UploadValidationProvider } from './UploadValidationProvider';\n\n/**\n * Context type for the FileUploadProvider\n * Contains both file state management and callback handlers for file operations.\n * This context makes file upload state and operations available to all child components.\n *\n * @property disabled - Whether the file upload functionality is disabled\n * @property files - Array of currently selected/uploaded files\n * @property onDrop - Callback triggered when files are dropped, with both accepted and rejected files\n * @property onDropAccepted - Callback triggered when files pass validation\n * @property onDropRejected - Callback triggered when files fail validation\n * @property onFileDelete - Callback triggered when a file is deleted from the preview\n * @property setFiles - State setter function to update the files array\n */\nexport type FileUploadContextType = {\n disabled: boolean;\n files: FileResource[];\n onDrop?: (acceptedFiles: File[], rejectedFiles: FileRejection[]) => void;\n onDropAccepted?: (files: File[]) => void;\n onDropRejected?: (rejectedFiles: FileRejection[]) => void;\n onFileDelete?: (fileResource: FileResource) => void;\n setFiles: (files: FileResource[] | ((prev: FileResource[]) => FileResource[])) => void;\n};\n\n/**\n * React context for file upload state and operations\n * Used by the useFileUploadContext hook\n */\nexport const FileUploadContext = createContext<FileUploadContextType | undefined>(undefined);\n\n/**\n * Configuration props for the FileUploadProvider\n * These props control both file upload behavior and validation rules.\n * Many of these properties are passed to the underlying ValidationProvider.\n */\nexport type FileUploadProviderConfigProps = {\n /**\n * Allowed file types - either preset categories ('images', 'pdfs', 'documents')\n * or an array of MIME types/extensions (e.g., ['image/jpeg', '.png'])\n */\n accept?: CommonFileTypes | string[];\n\n /**\n * Whether the upload is disabled\n * When true, prevents any interaction with the upload components\n */\n disabled?: boolean;\n\n /**\n * Error object to display custom validation errors\n * Overrides any validation errors with this custom error\n */\n error?: FileError;\n\n /**\n * Initial files to populate the uploader with\n * These files will be present when the component first mounts\n */\n initialFiles?: FileResource[];\n\n /**\n * Maximum number of files allowed\n * Set to 1 for single file upload, undefined for unlimited\n */\n maxFiles?: number;\n\n /**\n * Maximum allowed file size in bytes\n * Example: 5 * 1024 * 1024 for 5MB\n */\n maxSize?: number;\n\n /**\n * Callback when files are dropped (regardless of validation result)\n * Provides both accepted and rejected files for handling\n */\n onDrop?: (acceptedFiles: File[], rejectedFiles: FileRejection[]) => void;\n\n /**\n * Callback when files pass validation and are accepted\n * Useful for immediately processing valid files\n */\n onDropAccepted?: (files: File[]) => void;\n\n /**\n * Callback when files fail validation\n * Provides detailed rejection reasons for each file\n */\n onDropRejected?: (rejectedFiles: FileRejection[]) => void;\n\n /**\n * Callback when user clicks delete button on a file preview\n * Used to remove files from state or external storage\n */\n onFileDelete?: (fileResource: FileResource) => void;\n\n /**\n * When true, if any file fails validation, all files are rejected\n * When false (default), valid files are accepted even if others are rejected\n */\n strictValidation?: boolean;\n\n /**\n * Custom validator function for additional validation rules\n * Allows you to implement validation beyond the built-in type/size checks\n */\n validator?: FileValidator;\n};\n\n/**\n * Props for the FileUploadProvider component\n * Extends the config props with React children\n */\ntype FileUploadProviderProps = FileUploadProviderConfigProps & {\n /** React children */\n children: React.ReactNode;\n};\n\n/**\n * Provider component for file upload functionality\n *\n * This provider manages both file state and validation rules:\n * 1. Maintains file state (selected/uploaded files)\n * 2. Provides context for drag/drop operations and file management\n * 3. Wraps children with validation context for enforcing file rules\n *\n * While FileDropzone and FilePreviewList can function as standalone components,\n * using this provider offers coordinated state management when using multiple\n * file upload components together.\n *\n * @example\n * ```tsx\n * <FileUploadProvider\n * accept=\"images\"\n * maxFiles={5}\n * maxSize={2 * 1024 * 1024}\n * onDropAccepted={(files) => console.log('Accepted:', files)}\n * >\n * <FileDropzone />\n * <FilePreviewList />\n * </FileUploadProvider>\n * ```\n */\nexport const FileUploadProvider = ({\n accept,\n children,\n disabled = false,\n error,\n initialFiles = [],\n maxFiles,\n maxSize,\n onDrop,\n onDropAccepted,\n onDropRejected,\n onFileDelete,\n strictValidation,\n validator,\n}: FileUploadProviderProps) => {\n const [files, setFiles] = useState<FileResource[]>(initialFiles);\n\n const value = {\n accept,\n disabled,\n files,\n onDrop,\n onDropAccepted,\n onDropRejected,\n onFileDelete,\n setFiles,\n };\n\n return (\n <UploadValidationProvider\n accept={accept}\n error={error}\n maxFiles={maxFiles}\n maxSize={maxSize}\n strictValidation={strictValidation}\n validator={validator}\n >\n <FileUploadContext.Provider value={value}>{children}</FileUploadContext.Provider>\n </UploadValidationProvider>\n );\n};\n\nFileUploadProvider.displayName = 'FileUploadProvider';\n\n/**\n * Hook to access the file upload context\n *\n * Provides access to the current files array and operations for\n * managing file uploads within the FileUploadProvider.\n *\n * @throws Error if used outside of a FileUploadProvider\n * @returns The FileUploadContextType object with files array and handlers\n *\n * @example\n * ```tsx\n * const { files, setFiles, onFileDelete } = useFileUploadContext();\n *\n * // Remove a file\n * const handleDelete = (fileToDelete) => {\n * onFileDelete?.(fileToDelete);\n * setFiles(files.filter(file => file.name !== fileToDelete.name));\n * };\n * ```\n */\nexport const useFileUploadContext = () => {\n const context = useContext<FileUploadContextType | undefined>(FileUploadContext);\n if (!context) {\n throw new Error('useFileUploadContext must be used within FileUploadProvider');\n }\n return context;\n};\n","import { useCallback } from 'react';\n\nimport { UploadValidationContextType } from '../../../providers/UploadValidationProvider';\nimport { FileResource, FileValidator } from '../../../types/commonTypes';\nimport { createMessageContext } from '../../../utils/createMessageContext';\nimport { resolveContextAwareMessage } from '../../../utils/messageUtils';\n\n/**\n * Hook that handles file validation during drag events over a drop zone\n * @param props Object containing:\n * - files: Currently selected files in the uploader\n * - mimeTypes: Optional mapping of accepted file types to their MIME type arrays\n * - validation: Validation context (from either UploadValidationProvider\n * or local useFileValidationLogic hook)\n * - validator: Optional custom validation function to perform additional checks\n * @returns Callback function for handling dragenter events with early validation feedback\n * @remarks\n * - Provides immediate validation feedback while files are being dragged over the drop zone\n * - File size validation is not possible during drag events as file data is not yet available\n * - Validates in a specific priority order: custom validator → file count → file type\n * - Clears all validation state when drag starts\n * - Sets appropriate validation error messages for display in the UI\n * - Works with the ValidationContext to maintain validation state\n */\n\ntype UseHandleDragEnterProps = {\n /** Current files in the upload area */\n files: FileResource[];\n /** MIME types to accept */\n mimeTypes?: Record<string, string[]>;\n /** Validation context */\n validation: UploadValidationContextType;\n /** Custom validator function */\n validator?: FileValidator;\n};\n\n// Fires when a user drags files over the upload zone - provides early feedback on file type and max file limit\n// Note: We cannot early-validate file size here since we don't have access to the file content during drag events, only after drop.\nexport const useHandleDragEnter = ({ files, mimeTypes, validation, validator }: UseHandleDragEnterProps) => {\n const {\n accept,\n clearAllValidation,\n formattedMaxSize,\n getValidationMessage,\n maxFiles,\n maxSize,\n setDragValidationError,\n validateCustomRules,\n validateFileCount,\n validateFileType,\n } = validation;\n\n return useCallback(\n (event: React.DragEvent<HTMLElement>) => {\n // Clear all previous validation errors when a new drag event occurs\n clearAllValidation();\n\n const items = event.dataTransfer.items;\n if (items.length === 0) {\n return;\n }\n\n // Validation priority follows a specific order with early returns:\n // 1. Custom validator (highest priority)\n if (validator) {\n // Drag validation for custom validator uses the first dragged item\n const file = items[0];\n const validationResult = validateCustomRules(file);\n if (validationResult) {\n // Use the first error in the array\n const result = validationResult[0];\n\n // Create context with all necessary data for the error message\n const messageContext = createMessageContext({\n accept,\n code: result.code,\n count: items.length,\n dragItems: items,\n formattedMaxSize,\n maxFiles,\n maxSize,\n messageType: 'drag',\n });\n\n // Set the error with a properly formatted message\n setDragValidationError({\n code: result.code,\n message: resolveContextAwareMessage(result.message, messageContext),\n });\n return;\n }\n }\n\n // 2. File count validation (second priority)\n if (!validateFileCount(files.length, items.length)) {\n const overflowCount = files.length + items.length - (maxFiles ?? Infinity);\n\n const errorCode = 'too-many-files';\n const errorMessage = getValidationMessage({\n code: errorCode,\n count: overflowCount,\n messageType: 'drag',\n });\n\n setDragValidationError({\n code: errorCode,\n message: errorMessage,\n });\n return;\n }\n\n // 3. File type validation (lowest priority)\n const invalidTypeFiles = Array.from(items).filter((item) => {\n // Skip directories in validation (no type or kind is 'directory')\n if (!item.type || item.kind === 'directory') {\n return false;\n }\n return !validateFileType(item.type, mimeTypes);\n });\n\n if (invalidTypeFiles.length > 0) {\n const errorCode = 'file-invalid-type';\n const errorMessage = getValidationMessage({\n code: errorCode,\n count: invalidTypeFiles.length,\n messageType: 'drag',\n });\n\n setDragValidationError({\n code: errorCode,\n message: errorMessage,\n });\n return;\n }\n\n // If we reach here, all validation passed - no error is set\n },\n [\n files.length,\n mimeTypes,\n clearAllValidation,\n setDragValidationError,\n getValidationMessage,\n validateFileCount,\n maxFiles,\n validateFileType,\n validateCustomRules,\n validator,\n accept,\n formattedMaxSize,\n maxSize,\n ]\n );\n};\n","import { UploadValidationContextType } from '../../../providers/UploadValidationProvider';\nimport {\n ContextAwareMessage,\n DynamicMessageContext,\n FileError,\n FileRejection,\n FileResource,\n ValidationError,\n} from '../../../types/commonTypes';\nimport { builtInErrorCodes } from '../../../utils/constants';\nimport { createMessageContext } from '../../../utils/createMessageContext';\nimport { resolveContextAwareMessage } from '../../../utils/messageUtils';\n\n// Type for tracking error groups\nexport type ErrorGroup = {\n count: number;\n files: File[];\n message: ContextAwareMessage<DynamicMessageContext>;\n};\n\n/**\n * Creates helper functions for processing file rejections and formatting error messages\n * @param validation Validation context containing message formatters and validation rules\n * @returns Object with helper functions for processing file rejections\n */\nexport const createRejectionHelpers = (validation: UploadValidationContextType) => {\n const { accept, formattedMaxSize, getValidationMessage, maxFiles, maxSize, strictValidation, validateFileCount } =\n validation;\n\n /**\n * Ensures an error group exists for the given code, creating one if necessary\n *\n * @param errorGroups - Record of existing error groups indexed by error code\n * @param code - The error code to get or create a group for\n * @param message - Optional error message to use when creating a new group\n * @returns The existing or newly created error group for the specified code\n * @remarks\n * - Error groups track files that failed with the same error code\n * - Each group maintains a count of files, file references, and a shared message\n * - New groups are initialized with empty arrays and zero counts\n */\n const getOrCreateErrorGroup = (\n errorGroups: Record<string, ErrorGroup>,\n code: string,\n message?: ContextAwareMessage<DynamicMessageContext>\n ): ErrorGroup => {\n if (!(code in errorGroups)) {\n errorGroups[code] = {\n count: 0,\n files: [],\n message: message ?? '',\n };\n }\n return errorGroups[code];\n };\n\n return {\n /**\n * Formats a human-readable error message for display based on error code and grouped files\n *\n * This function handles two types of validation errors:\n *\n * 1. System errors (built-in): For standard error codes like 'file-too-large' or 'too-many-files',\n * it uses the built-in message system with appropriate pluralization and formatting.\n *\n * 2. Custom validator errors: For custom error codes from user-defined validators,\n * it enriches the message with context about the rejected files (count, names, etc.).\n *\n * Used in two key scenarios:\n * - Creating consolidated error messages for the UI (one message per error type)\n * - Formatting individual file rejection messages for callbacks\n *\n * @param code - The error code identifying the validation failure\n * @param error - The error object containing the message (string or function)\n * @param errorGroups - Record of grouped errors with counts and file references\n * @returns A formatted, human-readable error message ready for display\n */\n getFormattedErrorGroupMessage: (\n code: string,\n error: ValidationError,\n errorGroups: Record<string, ErrorGroup>\n ) => {\n const isSystemError = builtInErrorCodes.includes(code);\n const errorGroup = errorGroups[code];\n\n // For system errors, use getValidationMessage directly\n if (isSystemError) {\n return getValidationMessage({\n code,\n count: errorGroup.count,\n messageType: 'drop',\n });\n }\n\n // For custom errors, we need to provide context about the rejected files\n const messageContext = createMessageContext({\n accept,\n code,\n count: errorGroup.count,\n dropFiles: errorGroup.files,\n formattedMaxSize,\n maxFiles,\n maxSize,\n messageType: 'drop',\n });\n\n // Resolve the message function with proper context containing all grouped files\n return resolveContextAwareMessage(error.message, messageContext);\n },\n\n getOrCreateErrorGroup,\n\n /**\n * Handles file count limits and returns updated accepted/rejected files\n *\n * This function enforces the maxFiles constraint by calculating whether adding\n * new files would exceed the configured limit.\n *\n * @param currentFiles - Existing files already uploaded or selected\n * @param droppedAcceptedFiles - New files that passed initial type/size validation\n * @param droppedRejectedFiles - New files that already failed validation for other reasons\n * @returns Object containing the final accepted and rejected files after limit checks\n * @remarks\n * - Considers both existing files and newly dropped files when checking limits\n * - Handles two validation modes:\n * 1. Strict validation (strictValidation: true):\n * If adding any files would exceed the limit, ALL files are rejected\n * 2. Partial upload (strictValidation: false):\n * Accepts files up to the remaining limit, rejecting only overflow files\n * - Calculates remaining slots as (maxFiles - currentFiles.length)\n * - When no maxFiles is defined, accepts all files (Infinity limit)\n * - Adds appropriate error metadata to the rejected files for UI feedback\n */\n handleFileCountLimits: (\n currentFiles: FileResource[],\n droppedAcceptedFiles: File[],\n droppedRejectedFiles: FileRejection[]\n ) => {\n let acceptedResult = droppedAcceptedFiles;\n let rejectionsResult = [...droppedRejectedFiles];\n\n // Check if the total number of files (including both accepted and rejected) would exceed the limit\n // This ensures users see the maxFiles error even if some files are rejected for other reasons\n const totalDroppedFiles = droppedAcceptedFiles.length + droppedRejectedFiles.length;\n const wouldExceedLimit = !validateFileCount(currentFiles.length, totalDroppedFiles);\n const remainingSlots = maxFiles ? maxFiles - currentFiles.length : Infinity;\n\n if (wouldExceedLimit) {\n // Calculate how many files exceed the limit, considering all dropped files\n const overflowCount = currentFiles.length + totalDroppedFiles - (maxFiles ?? Infinity);\n const errorCode = 'too-many-files';\n const errorMessage = getValidationMessage({\n code: errorCode,\n count: overflowCount,\n messageType: 'drop',\n });\n\n const maxFilesError: FileError = {\n code: errorCode,\n message: errorMessage,\n };\n\n // Add the error to all files that exceed the limit\n // Start with files that were already accepted (they passed other validations)\n const fileCountRejections = acceptedResult.slice(remainingSlots).map((file) => ({\n errors: [maxFilesError],\n file,\n }));\n\n // Add these new rejections to the existing ones\n rejectionsResult = [...rejectionsResult, ...fileCountRejections];\n\n if (!strictValidation) {\n // In partial upload mode, only accept files up to the max file limit\n acceptedResult = acceptedResult.slice(0, remainingSlots);\n } else {\n // In strict mode, reject all files if the total count exceeds the limit\n acceptedResult = [];\n }\n }\n\n return { allAcceptedFiles: acceptedResult, allRejections: rejectionsResult };\n },\n\n /**\n * Handles file size validation and returns updated accepted/rejected files\n *\n * This function checks if files exceed the maximum allowed size (maxSize)\n * and updates accept/reject lists accordingly.\n *\n * @param acceptedFiles - Files that have passed previous validation steps\n * @returns Object containing validated files and size-related rejections\n * @remarks\n * - Files exceeding maxSize are identified and grouped with a 'file-too-large' error\n * - Handles two validation modes:\n * 1. Strict validation (strictValidation: true):\n * If ANY file exceeds the size limit, ALL files are rejected\n * 2. Partial upload (strictValidation: false):\n * Only oversized files are rejected, others proceed normally\n * - When maxSize is undefined, all files pass size validation\n * - Adds appropriate error metadata to rejected files for UI feedback\n * - The returned object has separate lists for valid files and size rejections\n */\n handleFileSizeValidation: (acceptedFiles: File[]) => {\n let validFiles = [...acceptedFiles];\n let sizeRejections: FileRejection[] = [];\n\n // Check for oversized files\n const oversizedFiles = acceptedFiles.filter((file) => maxSize && file.size > maxSize);\n\n if (oversizedFiles.length > 0) {\n const errorCode = 'file-too-large';\n const errorMessage = getValidationMessage({\n code: errorCode,\n count: oversizedFiles.length,\n messageType: 'drop',\n });\n\n const fileSizeError: FileError = {\n code: errorCode,\n message: errorMessage,\n };\n\n // Add to rejections\n sizeRejections = oversizedFiles.map((file) => ({\n errors: [fileSizeError],\n file,\n }));\n\n if (!strictValidation) {\n // In partial upload mode, filter out oversized files\n validFiles = acceptedFiles.filter((file) => !maxSize || file.size <= maxSize);\n } else {\n // In strict mode, reject all files if any are oversized\n validFiles = [];\n }\n }\n\n return { sizeRejections, validFiles };\n },\n\n /**\n * Processes file rejections and groups them by error code\n *\n * This function takes an array of file rejections and organizes them into\n * error groups based on the error codes. Each group tracks a count of affected\n * files and the file references.\n *\n * @param rejections - Array of file rejections to process\n * @returns A record of error groups indexed by error code\n * @remarks\n * - Multiple files with the same error code are consolidated into a single group\n * - A file can appear in multiple groups if it has multiple error codes\n * - Each group tracks:\n * - count: Number of files affected by this error\n * - files: References to the affected files\n * - message: The error message (shared across the group)\n * - Used for generating consolidated error messages and UI summaries\n */\n processRejections: (rejections: FileRejection[]): Record<string, ErrorGroup> => {\n const groups: Record<string, ErrorGroup> = {};\n rejections.forEach((rejection) => {\n rejection.errors.forEach((error) => {\n const group = getOrCreateErrorGroup(groups, error.code, error.message);\n group.count++;\n group.files.push(rejection.file);\n });\n });\n\n return groups;\n },\n };\n};\n","import { useCallback } from 'react';\n\nimport { UploadValidationContextType } from '../../../providers/UploadValidationProvider';\nimport { FileRejection, FileResource } from '../../../types/commonTypes';\nimport { createRejectionHelpers } from './createFileRejectionHelpers';\n\n/**\n * Hook that handles file validation and processing when files are dropped\n * @param props Object containing:\n * - files: Currently selected files in the uploader\n * - onDrop: Optional callback triggered for both accepted and rejected files\n * - onDropAccepted: Optional callback triggered only for accepted files\n * - onDropRejected: Optional callback triggered only for rejected files\n * - setFiles: Function to update the files state with newly accepted files\n * - validation: Validation context (from either provider or local validation)\n * @returns Callback function for handling file drop events from react-dropzone\n * @remarks\n * - Performs validation in a specific sequence: file types → file sizes → file count\n * - Groups and formats error messages for consistent UI display\n * - Handles strict vs. partial validation modes differently:\n * - Strict: Rejects all files if any would be invalid\n * - Partial: Accepts valid files while rejecting invalid ones\n * - Updates file state only for valid files\n * - Clears validation state on completely successful drops\n * - Calls appropriate callbacks with processed files\n * - Sets validation errors in the validation context for UI display\n */\n\nexport type UseHandleDropProps = {\n /** Current files in the upload area */\n files: FileResource[];\n /** Callback when files are dropped */\n onDrop?: (acceptedFiles: File[], rejectedFiles: FileRejection[]) => void;\n /** Callback when files are accepted */\n onDropAccepted?: (acceptedFiles: File[]) => void;\n /** Callback when files are rejected */\n onDropRejected?: (rejectedFiles: FileRejection[]) => void;\n /** Function to update the files state */\n setFiles: (files: FileResource[]) => void;\n /** Validation context */\n validation: UploadValidationContextType;\n};\n\nexport const useHandleDrop = ({\n files,\n onDrop,\n onDropAccepted,\n onDropRejected,\n setFiles,\n validation,\n}: UseHandleDropProps) => {\n const { clearAllValidation, setDropValidationErrors, setFileRejections, strictValidation } = validation;\n\n return useCallback(\n (acceptedFiles: File[], rejectedFiles: FileRejection[]) => {\n const {\n getFormattedErrorGroupMessage,\n handleFileCountLimits,\n handleFileSizeValidation,\n processRejections,\n } = createRejectionHelpers(validation);\n\n // Step 1: Validate file sizes\n // Note: acceptedFiles have already passed type validation by react-dropzone\n const { sizeRejections, validFiles } = handleFileSizeValidation(acceptedFiles);\n\n // Filter out only File objects from current files for validation\n // This is needed because FileResource can include RemoteFile objects\n const currentFileObjects = files.filter((file): file is File => file instanceof File);\n\n // Step 2: Handle file count limits with all validated files\n // This combines all rejections from previous validation steps, including custom validator errors\n const { allAcceptedFiles, allRejections } = handleFileCountLimits(currentFileObjects, validFiles, [\n ...rejectedFiles, // Already includes custom validation errors\n ...sizeRejections,\n ]);\n\n // Step 3: Process all rejections and group by error code\n // This creates a dictionary of error groups for better UI presentation\n // Message functions are preserved at this stage for proper grouping\n const errorGroups = processRejections(allRejections);\n\n // Step 4: Extract errors for UI display, now resolving messages with proper context\n // We need one error message per error type for the UI\n const errors = Object.entries(errorGroups).map(([code]) => ({\n code,\n message: getFormattedErrorGroupMessage(code, { code, message: errorGroups[code].message }, errorGroups),\n }));\n\n // Step 5: Format rejections for callbacks - maintain file-to-errors relationship\n // These preserve the connection between each file and its specific rejection reasons\n const processedRejections = allRejections.map((rejection) => ({\n errors: rejection.errors.map((error) => ({\n code: error.code,\n message: getFormattedErrorGroupMessage(error.code, error, errorGroups),\n })),\n file: rejection.file,\n }));\n\n const hasRejections = processedRejections.length > 0;\n\n // Step 6: Handle strict validation - reject all files if there are any rejections\n if (strictValidation && hasRejections) {\n // In strict mode, even valid files are rejected if any file has issues\n const strictRejections = [\n ...processedRejections,\n ...allAcceptedFiles.map((file) => ({\n errors,\n file,\n })),\n ];\n\n setFileRejections(strictRejections);\n setDropValidationErrors(errors);\n onDropRejected?.(strictRejections);\n onDrop?.([], strictRejections);\n return;\n }\n\n // Step 7: Handle partial upload mode (OR no rejections)\n setFileRejections(processedRejections);\n setDropValidationErrors(errors);\n onDropRejected?.(processedRejections);\n\n // Step 8: Handle successful file uploads\n if (allAcceptedFiles.length > 0) {\n if (!hasRejections) {\n // Clear validation only if there are no rejections\n clearAllValidation();\n }\n // Update file state with new files (as FileResource[])\n const newFileResources: FileResource[] = [...files, ...allAcceptedFiles];\n setFiles(newFileResources);\n onDropAccepted?.(allAcceptedFiles);\n }\n\n // Always call onDrop with both sets of files\n onDrop?.(allAcceptedFiles, processedRejections);\n },\n [\n files,\n clearAllValidation,\n setDropValidationErrors,\n setFiles,\n onDrop,\n onDropAccepted,\n onDropRejected,\n setFileRejections,\n strictValidation,\n validation,\n ]\n );\n};\n","import { FileResource } from '../../../types/commonTypes';\n\n/**\n * Hook that determines if file uploads are currently available/disabled\n * @param props Object containing:\n * - disabled: Optional flag to manually disable uploads\n * - files: Currently selected files\n * - maxFiles: Optional maximum number of files allowed\n * @returns Object containing:\n * - hasReachedFileLimit: Whether max file count has been reached\n * - isDisabled: Whether uploads are currently disabled\n * @remarks\n * - Combines both manual disable state and file limit restrictions\n * - Used to prevent uploads when either condition is met\n */\nexport type UploadAvailabilityParams = {\n /** Whether the upload is disabled */\n disabled?: boolean;\n /** Current files in the upload area */\n files: FileResource[];\n /** Maximum number of files allowed */\n maxFiles?: number;\n};\n\ntype UploadAvailability = {\n hasReachedFileLimit: boolean;\n isDisabled: boolean;\n};\n\nexport const useUploadAvailability = ({\n disabled = false,\n files,\n maxFiles,\n}: UploadAvailabilityParams): UploadAvailability => {\n // Calculate if we've reached the file limit\n const hasReachedFileLimit = maxFiles !== undefined && files.length >= maxFiles;\n // Consider both local and provider disabled states\n const isDisabled = disabled || hasReachedFileLimit;\n\n return {\n hasReachedFileLimit,\n isDisabled,\n };\n};\n","import { UploadValidationContextType } from '../../providers/UploadValidationProvider';\n\n/**\n * Creates an optimized validator function for React-Dropzone that preserves\n * function-based validation messages for later resolution\n *\n * @param validationContext - The validation context containing the custom validator\n * @returns A validator function compatible with React-Dropzone\n */\nexport const createDropzoneValidator = (validationContext: UploadValidationContextType) => {\n // Extract the custom validator function\n const { validateCustomRules } = validationContext;\n\n // Return undefined if no custom validator exists\n if (typeof validateCustomRules !== 'function') {\n return undefined;\n }\n\n // Return the actual validator function\n return (file: File) => {\n // Run the custom validator\n const validationResult = validateCustomRules(file);\n\n // If no errors, return null (valid)\n if (!validationResult) {\n return null;\n }\n\n // If no errors in array, return null\n if (validationResult.length === 0) {\n return null;\n }\n\n // Return errors with message functions preserved\n // This allows for proper error grouping before message resolution\n return validationResult.map((error) => ({\n code: error.code,\n message: error.message,\n }));\n };\n};\n","import { CommonFileTypes } from '../types/commonTypes';\nimport { ACCEPTED_MIME_TYPES } from './constants';\n\n/**\n * Utility function that converts file type restrictions into MIME type format for react-dropzone\n * @param accept - Optional file type restrictions, can be either:\n * - A preset category from CommonFileTypes (e.g., 'images', 'pdfs', 'documents')\n * - An array of specific MIME types (e.g., ['image/jpeg', 'image/png'])\n * @returns Object mapping MIME types to empty arrays for react-dropzone's accept prop\n * @remarks\n * - Returns undefined when no restrictions are provided (accepts all file types)\n * - Handles both preset categories and custom MIME type arrays\n * - Formats MIME types to match react-dropzone's expected structure\n */\n\nexport const getMimeTypes = (accept?: CommonFileTypes | string[]) => {\n if (!accept) {\n return undefined; // No restrictions\n }\n\n if (Array.isArray(accept)) {\n return accept.reduce((acc, curr) => ({ ...acc, [curr]: [] }), {}); // Custom MIME types\n }\n\n return ACCEPTED_MIME_TYPES[accept].reduce((acc, curr) => ({ ...acc, [curr]: [] }), {}); // Preset category\n};\n","import { cn } from '@evolve.ui/theme-system';\n\nimport { FileError } from '../types';\n\ntype DropzoneState = {\n disableDragValidation: boolean;\n disabled: boolean;\n isDragActive: boolean;\n validationError?: FileError | null;\n};\n\nexport const getUploadZoneStyles = ({\n disabled,\n disableDragValidation,\n isDragActive,\n validationError,\n}: DropzoneState) => {\n const isInvalid = Boolean(validationError);\n const isErrorState = disableDragValidation ? false : isInvalid;\n const isDefaultState = !isDragActive && !isErrorState;\n const isDraggedOver = isDragActive && (disableDragValidation || !isInvalid);\n const isDefaultAppearance = isDefaultState && !disabled;\n\n return cn(\n // Layout & Container\n [\n 'relative',\n 'flex flex-col',\n 'h-full w-full',\n 'items-center justify-center',\n 'rounded-container',\n 'outline-dashed outline-1 -outline-offset-1',\n 'p-sm',\n 'transition-colors',\n 'hover:bg-background-hover hover:outline-border-hover', // Hover (when not dragging)\n ],\n\n // Focus & Interactive Base\n ['hui-focus-visible-outline'],\n\n // Interactive States\n {\n // Disabled\n 'cursor-not-allowed bg-background-disabled outline-border-disabled hover:bg-background-disabled hover:outline-border-disabled':\n disabled,\n\n // Enabled\n 'cursor-pointer active:bg-background-pressed active:outline active:outline-4 active:outline-focus-primary':\n !disabled,\n\n // Drag Active (only when not disabled)\n 'outline outline-4 outline-offset-0 outline-focus-primary': isDragActive && !disabled,\n },\n\n // Visual States\n {\n // Error (only when not disabled)\n 'bg-background-critical-light outline-dashed outline-1 -outline-offset-1 outline-border-critical':\n isErrorState && !disabled,\n\n // Drag Over\n 'bg-background-hover': isDraggedOver && !isErrorState && !disabled,\n\n // Default\n 'bg-background-primary outline-border-secondary': isDefaultAppearance,\n }\n );\n};\n","import { useMemo } from 'react';\n\nimport { useWindowIsMobile } from '../../../../../providers';\nimport { SubtleLink } from '../../../../../Typography/Links/Links';\nimport { UploadValidationContextType } from '../../../../providers/UploadValidationProvider';\n\ntype DropzoneTextProps = {\n disableDragValidation: boolean;\n filePluralizationText: string;\n hasReachedFileLimit: boolean;\n isDisabled: boolean;\n isDragActive: boolean;\n isDragReject: boolean;\n maxFiles?: number;\n validation: UploadValidationContextType;\n};\n\nexport const DropzoneText = ({\n disableDragValidation,\n filePluralizationText,\n hasReachedFileLimit,\n isDisabled,\n isDragActive,\n isDragReject,\n maxFiles,\n validation,\n}: DropzoneTextProps) => {\n const isMobile = useWindowIsMobile();\n const { dragValidationError } = validation;\n\n const dropzoneText = useMemo(() => {\n // Static states (before any drag)\n if (hasReachedFileLimit) {\n return <>{`${maxFiles} file limit reached. Remove files to upload more.`}</>;\n }\n\n // Show validation messages during drag\n if (isDragActive && dragValidationError?.code) {\n return <>{dragValidationError.message}</>;\n }\n\n // Show \"Drop files here\" during valid drag\n if (isDragActive && (disableDragValidation || !isDragReject)) {\n return <>Drop files here to upload</>;\n }\n\n // Default states (no drag)\n if (isMobile) {\n return <>{`Click to browse and add ${filePluralizationText}`}</>;\n }\n\n // Desktop default\n return (\n <>\n <SubtleLink\n className=\"group-hover:underline\"\n disabled={isDisabled}\n href=\"#\"\n onClick={(e) => e.preventDefault()}\n >\n Browse\n </SubtleLink>{' '}\n or drag {filePluralizationText} here to upload\n </>\n );\n }, [\n filePluralizationText,\n hasReachedFileLimit,\n isDisabled,\n isDragActive,\n isDragReject,\n disableDragValidation,\n maxFiles,\n isMobile,\n dragValidationError,\n ]);\n\n return <>{dropzoneText}</>;\n};\n\nDropzoneText.displayName = 'DropzoneText';\n","import { TextColorAliases } from '@evolve.ui/theme-system';\n\nimport { UploadSimple } from '../../../../../Icons';\nimport { BodyPrimary } from '../../../../../Typography/Text/Text';\nimport { DropzoneText } from './DropzoneText';\n\ntype DropzoneContentProps = {\n dropzoneTextProps: React.ComponentProps<typeof DropzoneText>;\n isDisabled: boolean;\n};\n\nexport const DropzoneContent = ({ dropzoneTextProps, isDisabled }: DropzoneContentProps) => {\n const dropzoneTextColor: TextColorAliases = isDisabled ? 'disabled' : 'primary';\n\n return (\n <div className=\"flex w-full flex-col items-center gap-xs\">\n <UploadSimple color={dropzoneTextColor} />\n <BodyPrimary\n className=\"text-center\"\n color={dropzoneTextColor}\n >\n <DropzoneText {...dropzoneTextProps} />\n </BodyPrimary>\n </div>\n );\n};\n\nDropzoneContent.displayName = 'DropzoneContent';\n","import { Badge } from '../../../../../Badge/Badge';\nimport { ColumnType, Table } from '../../../../../Table';\nimport { BodyPrimary, H4 } from '../../../../../Typography/Text/Text';\nimport { FileErrorCode, FileRejection } from '../../../../types';\nimport { builtInErrorCodes } from '../../../../utils/constants';\n\ntype DisplayMode = 'by-error' | 'by-file';\n\ntype Props = {\n displayMode: DisplayMode;\n fileRejections: FileRejection[];\n};\n\ntype TableData = {\n col1: string;\n col2: string | string[];\n col3: string | string[];\n key: string;\n};\n\nconst BadgeCell = ({ codes }: { codes: string | string[] }) => {\n const codeArray = Array.isArray(codes) ? codes : [codes];\n\n return (\n <div className=\"flex flex-col justify-start gap-[4px]\">\n {codeArray.map((code, index) => (\n <Badge\n className=\"my-[2px]\"\n color=\"critical\"\n data-testid={`badge-${code}`}\n emphasis={builtInErrorCodes.includes(code as FileErrorCode) ? 'subtle' : 'bold'}\n key={`${code}-${index}`}\n size=\"xs\"\n >\n {code}\n </Badge>\n ))}\n </div>\n );\n};\n\nexport const FileRejectionsDisplay = ({ displayMode, fileRejections = [] }: Props) => {\n const totalErrors = fileRejections.reduce((sum, rejection) => sum + rejection.errors.length, 0);\n\n const tableData =\n displayMode === 'by-error'\n ? fileRejections.flatMap((rejection, fileIndex) =>\n rejection.errors.map((error, errorIndex) => ({\n col1: rejection.file.name,\n col2: error.code,\n col3: error.message,\n key: `${rejection.file.name}-${fileIndex}-${errorIndex}`,\n }))\n )\n : fileRejections.map((rejection, index) => ({\n col1: rejection.file.name,\n col2: rejection.errors.map((error) => error.code),\n col3: rejection.errors.map((error) => error.message),\n key: `${rejection.file.name}-${index}`,\n }));\n\n const columns: ColumnType<TableData>[] = [\n {\n align: 'left',\n header: 'File Name',\n key: 'col1',\n },\n {\n header: displayMode === 'by-error' ? 'Error Code' : 'Error Codes',\n key: 'col2',\n renderItem: (data: TableData) => <BadgeCell codes={data.col2} />,\n },\n {\n header: displayMode === 'by-error' ? 'Message' : 'Messages',\n key: 'col3',\n renderItem:\n displayMode === 'by-file'\n ? (data: TableData) => (\n <div className=\"flex flex-col gap-[2px]\">\n {(data.col3 as string[]).map((message, index) => (\n <span key={index}>{message}</span>\n ))}\n </div>\n )\n : undefined,\n },\n ];\n\n return (\n <>\n <div className=\"mb-xs mt-sm flex items-center justify-between px-[2px]\">\n <H4>File Rejections {displayMode === 'by-error' ? '(by Error)' : '(by File)'}</H4>\n <BodyPrimary>\n {fileRejections.length} files ({totalErrors} errors)\n </BodyPrimary>\n </div>\n <Table\n columns={columns}\n data={tableData}\n emptyStateHeaderText=\"No files rejected\"\n emptyStateSupportingText=\"Upload files to monitor rejections\"\n fillHorizontal\n hideBorder\n rowDensity=\"sm\"\n />\n </>\n );\n};\n\nFileRejectionsDisplay.displayName = 'FileRejectionsDisplay';\n","import { Tabs } from '../../../../../Tabs/Tabs';\nimport { FileRejection } from '../../../../types/commonTypes';\nimport { FileRejectionsDisplay } from './FileRejectionsDisplay';\n\ntype Props = {\n fileRejections: FileRejection[];\n};\n\nexport const FileDropzoneDebugger = ({ fileRejections = [] }: Props) => {\n return (\n <div className=\"mt-md rounded-container p-sm outline-dashed outline-1 -outline-offset-1 outline-border-secondary\">\n <Tabs\n tabs={[\n {\n content: (\n <FileRejectionsDisplay\n displayMode=\"by-error\"\n fileRejections={fileRejections}\n />\n ),\n contentId: 'rejections-by-error',\n label: 'Errors',\n },\n {\n content: (\n <FileRejectionsDisplay\n displayMode=\"by-file\"\n fileRejections={fileRejections}\n />\n ),\n contentId: 'rejections-by-file',\n label: 'Files',\n },\n ]}\n />\n </div>\n );\n};\n\nFileDropzoneDebugger.displayName = 'FileDropzoneDebugger';\n","import { cn } from '@evolve.ui/theme-system';\nimport { useContext } from 'react';\nimport { useDropzone } from 'react-dropzone';\n\nimport { Caption, LabelMini } from '../../../Typography/Text/Text';\nimport { formatFileSize } from '../../../utils/formatFileSize';\nimport { useFileValidation } from '../../hooks';\nimport { useHandleDragEnter } from '../../hooks/upload/useHandleDragEnter/useHandleDragEnter';\nimport { useHandleDrop } from '../../hooks/upload/useHandleDrop/useHandleDrop';\nimport { useUploadAvailability } from '../../hooks/upload/useUploadAvailability/useUploadAvailability';\nimport { createDropzoneValidator } from '../../hooks/validation/createDropzoneValidator';\nimport { FileUploadContext, FileUploadContextType } from '../../providers/FileUploadProvider';\nimport { FileDropzoneProps } from '../../types/sharedTypes';\nimport { getMimeTypes } from '../../utils/getMimeTypes';\nimport { getUploadZoneStyles } from '../../utils/styles';\nimport { DropzoneContent } from './components/DropzoneContent/DropzoneContent';\nimport { FileDropzoneDebugger } from './components/FileDropzoneDebugger/FileDropzoneDebugger';\n\n/**\n * FileDropzone component for handling file uploads with drag and drop support.\n * This is a versatile file input component that can work both as a standalone\n * component or as part of the FileUpload system.\n */\n\n/**\n * Handles the dual-mode functionality of the FileDropzone component, supporting both standalone usage\n * and provider-wrapped usage.\n *\n * ## Validation Modes\n * - **Provider Mode**: Uses validation context from FileUploadProvider for coordinated validation across components\n * - **Standalone Mode**: Creates local validation instance for independent operation\n *\n * ## Props & Context Resolution\n * The component follows a specific precedence order for each property:\n * 1. Direct props take highest priority (for granular control)\n * 2. Context values serve as fallbacks (for coordinated state)\n * 3. Default values as final fallbacks (for safety)\n *\n * This enables two key use cases:\n * 1. Standalone Usage: <FileDropzone maxFiles={5} onDrop={handleDrop} />\n * 2. Provider Usage:\n * <FileUploadProvider maxFiles={5}>\n * <FileDropzone /> // Inherits provider config\n * <FileDropzone maxFiles={1} /> // Overrides specific provider values\n * </FileUploadProvider>\n */\nexport const FileDropzone = ({\n accept: acceptProp,\n ariaLabel = 'Browse or drag files here to upload.',\n className,\n 'data-testid': dataTestId = 'file-dropzone',\n disabled: disabledProp = false,\n disableDragValidation = false,\n error,\n files: filesProp,\n helpText,\n helpTextAlignCenter,\n hideErrors = false,\n hideHelpText = false,\n labelText,\n maxFiles: maxFilesProp,\n maxSize: maxSizeProp,\n onDrop: onDropProp,\n onDropAccepted: onDropAcceptedProp,\n onDropRejected: onDropRejectedProp,\n onFilesChange: onFilesChangeProp,\n showDebugger,\n strictValidation,\n validator,\n}: FileDropzoneProps) => {\n const uploadContext = useContext<FileUploadContextType | undefined>(FileUploadContext);\n\n const validationConfig = {\n accept: acceptProp,\n error,\n maxFiles: maxFilesProp,\n maxSize: maxSizeProp,\n strictValidation,\n validator,\n };\n\n /* IMPORTANT: This component supports both standalone usage and provider usage */\n // useFileValidation automatically detects if we're in a provider context\n // If not in provider, create local validation for standalone usage\n const validation = useFileValidation(validationConfig);\n\n // Determine whether to use context or local state for files and setFiles\n const files = filesProp ?? uploadContext?.files ?? [];\n const setFiles = onFilesChangeProp ?? uploadContext?.setFiles ?? (() => {});\n\n // Intentionally check both props and context with precedence order\n const disabled = disabledProp || uploadContext?.disabled;\n const onDrop = onDropProp ?? uploadContext?.onDrop;\n const onDropAccepted = onDropAcceptedProp ?? uploadContext?.onDropAccepted;\n const onDropRejected = onDropRejectedProp ?? uploadContext?.onDropRejected;\n const maxFiles = maxFilesProp ?? validation.maxFiles;\n const maxSize = maxSizeProp ?? validation.maxSize;\n const accept = acceptProp ?? validation.accept;\n /* END IMPORTANT */\n\n // Check if upload is disabled based on current state\n const { hasReachedFileLimit, isDisabled } = useUploadAvailability({\n disabled,\n files,\n maxFiles,\n });\n\n const formattedMaxSize = maxSize ? formatFileSize(maxSize) : undefined;\n\n const defaultHelpText = formattedMaxSize ? `File size must be smaller than ${formattedMaxSize}` : undefined;\n\n // If custom help text is provided, use it. Otherwise, use the default help text, or hide it.\n const helpTextToDisplay = hideHelpText ? undefined : (helpText ?? defaultHelpText);\n\n // Configure text based on multiple vs single file mode\n const allowMultipleFiles = maxFiles === undefined || maxFiles > 1;\n const filePluralizationText = allowMultipleFiles ? 'files' : 'a file';\n const mimeTypes = getMimeTypes(accept);\n\n // Set up drag and drop handlers\n const handleDrop = useHandleDrop({\n files,\n onDrop,\n onDropAccepted,\n onDropRejected,\n setFiles,\n validation,\n });\n\n const handleDragEnter = useHandleDragEnter({\n files,\n mimeTypes,\n validation,\n validator,\n });\n\n // Configure the dropzone\n const { getInputProps, getRootProps, isDragActive, isDragReject } = useDropzone({\n accept: mimeTypes,\n disabled: isDisabled,\n maxSize,\n multiple: allowMultipleFiles,\n onDragEnter: disableDragValidation ? validation.clearAllValidation : handleDragEnter,\n onDragLeave: validation.clearAllValidation,\n onDrop: handleDrop,\n // @ts-expect-error Our validator returns potentially function-based messages, React-Dropzone expects strings.\n // This is intentional and allows us to resolve dynamic messages later with proper file counts.\n validator: createDropzoneValidator(validation),\n });\n\n // Determine Dropzone styles based on interaction state\n const activeCode = isDragActive ? validation.dragValidationError : validation.dropValidationErrors[0];\n const uploadZoneStyles = getUploadZoneStyles({\n disabled: isDisabled,\n disableDragValidation,\n isDragActive,\n validationError: activeCode,\n });\n\n return (\n <div\n aria-label={ariaLabel}\n className={cn('flex h-full w-full flex-col gap-[4px]', className)}\n role=\"region\"\n >\n {labelText && <LabelMini color={isDisabled ? 'disabled' : 'secondary'}>{labelText}</LabelMini>}\n <div\n {...getRootProps({\n 'aria-disabled': isDisabled,\n className: cn('group min-h-[88px] w-full', uploadZoneStyles),\n 'data-testid': `${dataTestId}-container`,\n onClick: validation.clearAllValidation,\n role: 'button',\n })}\n >\n <input\n {...getInputProps({\n 'aria-label': `Upload ${filePluralizationText}`,\n 'data-testid': `${dataTestId}-input`,\n })}\n />\n <DropzoneContent\n dropzoneTextProps={{\n disableDragValidation,\n filePluralizationText,\n hasReachedFileLimit,\n isDisabled,\n isDragActive,\n isDragReject,\n maxFiles,\n validation,\n }}\n isDisabled={isDisabled}\n />\n </div>\n <div\n className={cn('relative flex flex-col gap-[4px]', {\n 'items-center': helpTextAlignCenter,\n })}\n >\n {helpTextToDisplay && (\n <Caption color={isDisabled ? 'disabled' : 'secondary'}>{helpTextToDisplay}</Caption>\n )}\n {!hideErrors &&\n validation.dropValidationErrors.map((error, index) => (\n <Caption\n color=\"critical\"\n key={`${error.code}-${index}`}\n role=\"alert\"\n >\n {error.message}\n </Caption>\n ))}\n </div>\n {/* Display debug information around fileRejections when showDebugger is true */}\n {showDebugger && <FileDropzoneDebugger fileRejections={validation.fileRejections} />}\n </div>\n );\n};\n\nFileDropzone.displayName = 'FileDropzone';\n","import { BaseFileCardProps } from '../../../components/types';\n\n/**\n * Helper function to check if an element or its parents have the data-no-drag attribute\n * Exported for testing, you should probably be using the `dataNoDragSortable` function instead\n * @param element - The element to check\n * @returns Whether the element or any of its parents have the data-no-drag attribute\n */\nexport const hasDataNoDragOrParent = (element: HTMLElement | null): boolean => {\n if (!element) {\n return false;\n }\n if (element.hasAttribute('data-no-drag')) {\n return true;\n }\n if (element.parentElement) {\n return hasDataNoDragOrParent(element.parentElement);\n }\n return false;\n};\n\n/**\n * Modified sortable object that stops propagation if the parent element has the data-no-drag attribute\n * @param sortable - The sortable object to modify\n * @returns The modified sortable object\n */\nexport const dataNoDragSortable = (sortable: BaseFileCardProps['sortable'] | undefined | null) => {\n if (!sortable) {\n return null;\n }\n return {\n ...sortable,\n attributes: {\n ...sortable.attributes,\n },\n listeners: {\n ...sortable.listeners,\n onPointerDown: (e: React.PointerEvent) => {\n if (hasDataNoDragOrParent(e.target as HTMLElement)) {\n e.stopPropagation();\n return;\n }\n // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition\n sortable.listeners?.onPointerDown?.(e);\n },\n },\n };\n};\n","import { cn } from '@evolve.ui/theme-system';\n\nimport { Badge } from '../../../Badge/Badge';\nimport { Checkbox } from '../../../ChoiceListItem';\nimport { IconButton } from '../../../IconButton/IconButton';\nimport { DotsSixVertical, DotsThreeOutlineVertical, Paperclip, Trash } from '../../../Icons';\nimport { Menu, MenuItem } from '../../../Menu';\nimport { ProgressCircle } from '../../../ProgressCircle/ProgressCircle';\nimport { BodyPrimary, BodySecondary } from '../../../Typography/Text/Text';\nimport { formatFileSize } from '../../../utils/formatFileSize';\nimport { dataNoDragSortable } from '../../components/GridFileCard/utils/sortable';\nimport { useImageFilePreviewUrl } from '../../hooks/filePreview/useImageFilePreviewUrl';\nimport { FileResource } from '../../types';\nimport { BaseFileCardProps } from '../types';\n\ntype GridViewProps = BaseFileCardProps & {\n badge?: string;\n 'data-testid'?: string;\n statusText?: string;\n};\n\n/**\n * Actions to render. First 3 actions will be visible buttons,\n * remaining will appear in overflow menu.\n */\nconst MAX_VISIBLE_ACTIONS = 3;\n\nexport const GridFileCard = ({\n actions = [],\n badge,\n className,\n 'data-testid': dataTestId = 'grid-file-card',\n draggable,\n errorMessage,\n fileName,\n hideFileName = false,\n hideFileSize = false,\n hideFileStatus = false,\n imageSource,\n isSelected,\n onDelete,\n onImageError,\n onSelect,\n progress,\n selectable,\n sortable,\n status = 'default',\n statusIcon,\n statusText,\n}: GridViewProps) => {\n const previewUrl = useImageFilePreviewUrl(imageSource);\n\n const isRemoteFile = 'url' in imageSource;\n const fileSize = isRemoteFile ? '' : formatFileSize(imageSource.size);\n\n // Automatically hide file size for URLs, respect the prop for Files\n const shouldHideFileSize = hideFileSize || isRemoteFile;\n\n const defaultFileName = isRemoteFile ? (imageSource.url.split('/').pop() ?? 'image') : imageSource.name;\n const fileDisplayName = fileName ?? defaultFileName;\n\n // Status checks\n const isError = status === 'error';\n const isPending = status === 'pending';\n const isProgressing = status === 'progressing';\n const isComplete = status === 'complete';\n const isDragging = sortable?.isDragging ?? false;\n\n // Determine when to auto-render ProgressCircle\n // Only when statusIcon is not provided AND status is pending/progressing/complete\n const shouldShowProgressCircle = !statusIcon && (isPending || isProgressing || isComplete);\n\n // Determine what to show below the file name (priority: error > progressing > size)\n let fileStatusText = null;\n\n if (isError && errorMessage && !hideFileStatus) {\n fileStatusText = (\n <BodySecondary\n className=\"text-text-critical\"\n data-no-drag\n >\n {errorMessage}\n </BodySecondary>\n );\n } else if ((isProgressing || isPending) && !hideFileStatus) {\n // Use custom statusText if provided, otherwise use default\n const defaultStatusText = isPending ? 'Pending' : 'Uploading';\n const displayStatusText = statusText ?? defaultStatusText;\n fileStatusText = (\n <BodySecondary\n color=\"secondary\"\n data-no-drag\n >\n {displayStatusText}\n </BodySecondary>\n );\n } else if (!shouldHideFileSize) {\n fileStatusText = (\n <BodySecondary\n color={isError ? 'critical' : 'secondary'}\n data-no-drag\n >\n {fileSize}\n </BodySecondary>\n );\n }\n\n const actionsWithDelete = [\n ...actions,\n ...(onDelete\n ? [\n {\n icon: Trash,\n iconStyle: 'regular',\n name: 'Delete',\n onClick: (_: React.MouseEvent<HTMLElement>, fileResource: FileResource) => onDelete(fileResource),\n },\n ]\n : []),\n ];\n\n // Modified sortable object that prevents drag events if the parent element has the data-no-drag attribute\n const modifiedSortable = dataNoDragSortable(sortable);\n\n // Handle visible actions\n const visibleActions = actionsWithDelete.slice(0, MAX_VISIBLE_ACTIONS);\n\n // Handle overflow actions - only used when we have 4+ actions\n const overflowActions = actionsWithDelete.slice(MAX_VISIBLE_ACTIONS);\n\n // Map status to ProgressCircle-compatible status (only needed when shouldShowProgressCircle is true)\n let progressCircleStatus: 'pending' | 'progressing' | 'complete';\n if (isPending) {\n progressCircleStatus = 'pending';\n } else if (isProgressing) {\n progressCircleStatus = 'progressing';\n } else {\n progressCircleStatus = 'complete';\n }\n\n const isProcessing = isPending || isProgressing;\n\n return (\n <div\n aria-busy={isProcessing || undefined}\n className={cn(\n 'group/grid-file-card relative flex w-full min-w-0 cursor-pointer flex-col gap-xs',\n 'rounded-container p-xs',\n 'ring-1',\n 'transition-all duration-200',\n 'hover:z-10',\n 'focus-within:z-10',\n {\n // Error state\n 'bg-background-critical-light ring-border-critical focus-within:bg-background-critical-light focus-within:ring-border-critical hover:bg-background-critical-light hover:ring-border-critical':\n isError && !isDragging,\n // Default state\n 'bg-background-primary ring-transparent focus-within:bg-background-subdued focus-within:ring-border-secondary hover:bg-background-subdued hover:ring-border-secondary':\n !isError && !isDragging,\n // Drag state\n 'z-50 scale-105 border-border-selected bg-background-secondary shadow-01': isDragging,\n },\n className\n )}\n data-testid={dataTestId}\n ref={modifiedSortable?.setNodeRef}\n style={modifiedSortable?.styles}\n {...modifiedSortable?.attributes}\n {...modifiedSortable?.listeners}\n >\n <div className=\"relative aspect-square min-w-0 items-center justify-center rounded-container bg-background-subdued\">\n <div className=\"absolute left-0 top-0 z-10 flex items-center gap-[2px] p-xs\">\n {selectable && (\n <div data-no-drag>\n <Checkbox.Option\n checked={isSelected}\n className=\"![grid-template-columns:24px_0px_1fr]\"\n onChange={(e: React.ChangeEvent<HTMLInputElement>) => {\n e.stopPropagation();\n onSelect?.(imageSource, e.target.checked);\n }}\n />\n </div>\n )}\n {badge && (\n <Badge\n className=\"mt-[3px]\"\n color=\"neutral\"\n emphasis=\"bold\"\n round\n size=\"xs\"\n >\n {badge}\n </Badge>\n )}\n </div>\n {draggable && (\n <div className=\"absolute right-[4.4px] top-[8px] z-10 p-[2px]\">\n <DotsSixVertical\n className=\"flex-shrink-0 cursor-grab\"\n color=\"inverse\"\n size=\"sm\"\n style=\"bold\"\n />\n </div>\n )}\n {previewUrl ? (\n <img\n alt={fileDisplayName}\n className=\"absolute inset-0 h-full w-full rounded-container object-cover\"\n onError={() => onImageError?.(imageSource)}\n src={previewUrl}\n />\n ) : (\n <div className=\"absolute inset-0 flex items-center justify-center\">\n <Paperclip\n color=\"primary\"\n size=\"md\"\n />\n </div>\n )}\n <div\n className={cn(\n // positioning\n 'absolute inset-0',\n // children element positioning\n 'flex items-end justify-center',\n // styling\n 'rounded-container bg-background-overlay/20 p-xs',\n // transitions\n 'opacity-0 transition-opacity duration-200',\n // group focus/hover states\n 'group-hover/grid-file-card:opacity-100 group-has-[:focus-visible]/grid-file-card:opacity-100',\n // mouse pointer\n 'cursor-pointer',\n {\n 'cursor-grab': draggable,\n }\n )}\n >\n <div className=\"flex items-center gap-xs\">\n {/* Visible Actions (max of 4) */}\n {visibleActions.map((action, index) => (\n <IconButton\n aria-label={action.name}\n data-no-drag\n disabled={isProcessing}\n hideTooltip\n icon={action.icon}\n // @ts-expect-error - Look into this\n iconStyle={action.iconStyle}\n key={`${action.name}-${index}`}\n onClick={(e) => {\n e.stopPropagation();\n action.onClick(e, imageSource);\n }}\n shape=\"circle\"\n size=\"xs\"\n style=\"inverse\"\n type=\"button\"\n variant=\"transparent\"\n />\n ))}\n\n {/* Overflow Menu */}\n {overflowActions.length > 0 && (\n <Menu\n data-no-drag\n hasRoundedBorders\n menuPlacement=\"bottom-start\"\n menuSize=\"sm\"\n numberOfColumns={3}\n trigger={\n <IconButton\n data-no-drag\n disabled={isProcessing}\n hideTooltip\n icon={DotsThreeOutlineVertical}\n iconStyle=\"fill\"\n onClick={() => {}}\n shape=\"circle\"\n size=\"xs\"\n style=\"inverse\"\n type=\"button\"\n variant=\"transparent\"\n />\n }\n >\n {overflowActions.map((action, index) => (\n <MenuItem\n color={action.name === 'Delete' ? 'critical' : undefined}\n data-no-drag\n id={`${action.name}-${fileDisplayName}`}\n key={`${action.name}-${index}`}\n leftIcon={action.icon}\n onClick={() => {\n action.onClick({} as React.MouseEvent<HTMLDivElement>, imageSource);\n }}\n primaryLabel={action.name}\n />\n ))}\n </Menu>\n )}\n </div>\n </div>\n </div>\n <div className=\"flex items-center gap-[2px]\">\n <div className=\"flex min-w-0 flex-1 cursor-auto flex-col gap-[2px]\">\n {!hideFileName && (\n <BodyPrimary\n className=\"truncate\"\n color={isError ? 'critical' : 'primary'}\n data-no-drag\n >\n {fileDisplayName}\n </BodyPrimary>\n )}\n {fileStatusText}\n </div>\n {shouldShowProgressCircle ? (\n <div\n className=\"flex items-center\"\n data-testid=\"grid-file-card-progress-circle\"\n >\n <ProgressCircle\n progress={progress}\n size=\"sm\"\n status={progressCircleStatus}\n />\n </div>\n ) : statusIcon ? (\n statusIcon.type === 'progressCircle' ? (\n <div\n className=\"flex items-center\"\n data-testid=\"grid-file-card-progress-circle\"\n >\n <ProgressCircle\n centerIcon={statusIcon.centerIcon}\n color={statusIcon.color}\n indeterminateAnimation={statusIcon.indeterminateAnimation}\n progress={progress}\n size=\"sm\"\n status={progressCircleStatus}\n />\n </div>\n ) : (\n <div\n className=\"flex items-center\"\n data-testid=\"grid-file-card-status-icon\"\n >\n <statusIcon.icon\n color={statusIcon.color}\n size=\"sm\"\n style={statusIcon.style}\n />\n </div>\n )\n ) : null}\n </div>\n </div>\n );\n};\n\nGridFileCard.displayName = 'GridFileCard';\n","import { cn } from '@evolve.ui/theme-system';\nimport { ChangeEvent } from 'react';\n\nimport { Checkbox } from '../../../ChoiceListItem';\nimport { IconButton } from '../../../IconButton/IconButton';\nimport { DotsSixVertical, Paperclip, Trash } from '../../../Icons';\nimport { ProgressCircle } from '../../../ProgressCircle/ProgressCircle';\nimport { BodyPrimary, BodySecondary } from '../../../Typography/Text/Text';\nimport { formatFileSize } from '../../../utils/formatFileSize';\nimport { useImageFilePreviewUrl } from '../../hooks/filePreview/useImageFilePreviewUrl';\nimport { BaseFileCardProps, ListFileCardStyle } from '../types';\n\nexport type ListFileCardProps = BaseFileCardProps & {\n cardStyle?: ListFileCardStyle;\n 'data-testid'?: string;\n showActionsOnHover?: boolean;\n statusText?: string;\n};\n\nexport const ListFileCard = ({\n actions,\n cardStyle,\n className,\n 'data-testid': dataTestId = 'list-file-card',\n draggable,\n errorMessage,\n fileName,\n hideFileName = false,\n hideFileSize = false,\n hideFileStatus = false,\n imageSource,\n isSelected,\n onDelete,\n onImageError,\n onSelect,\n progress,\n selectable,\n showActionsOnHover,\n status = 'default',\n statusIcon,\n statusText,\n}: ListFileCardProps) => {\n const previewUrl = useImageFilePreviewUrl(imageSource);\n\n const isRemoteFile = 'url' in imageSource;\n const fileSize = isRemoteFile ? '' : formatFileSize(imageSource.size);\n\n // Automatically hide file size for URLs, respect the prop for Files\n const shouldHideFileSize = hideFileSize || isRemoteFile;\n\n const defaultFileName = isRemoteFile ? (imageSource.url.split('/').pop() ?? 'image') : imageSource.name;\n const fileDisplayName = fileName ?? defaultFileName;\n\n // Status checks\n const isError = status === 'error';\n const isPending = status === 'pending';\n const isProgressing = status === 'progressing';\n const isComplete = status === 'complete';\n const isDragging = false; // ListFileCard doesn't currently support sortable YET, but adding for consistency with GridFileCard\n\n // Determine when to auto-render ProgressCircle\n // Only when statusIcon is not provided AND status is pending/progressing/complete\n const shouldShowProgressCircle = !statusIcon && (isPending || isProgressing || isComplete);\n\n // Determine what to show below the file name (priority: error > progressing > size)\n let fileStatusText = null;\n\n if (isError && errorMessage && !hideFileStatus) {\n fileStatusText = <BodySecondary className=\"text-text-critical\">{errorMessage}</BodySecondary>;\n } else if ((isProgressing || isPending) && !hideFileStatus) {\n // Use custom statusText if provided, otherwise use default\n const defaultStatusText = isPending ? 'Pending' : 'Uploading';\n const displayStatusText = statusText ?? defaultStatusText;\n fileStatusText = <BodySecondary color=\"secondary\">{displayStatusText}</BodySecondary>;\n } else if (!shouldHideFileSize) {\n fileStatusText = <BodySecondary color={isError ? 'critical' : 'secondary'}>{fileSize}</BodySecondary>;\n }\n\n const actionBtnClasses = showActionsOnHover\n ? cn(\n 'opacity-0 group-hover/list-file-card:opacity-100 group-has-[:focus-visible]/list-file-card:opacity-100',\n 'focus-visible:opacity-100',\n 'transition-opacity duration-200'\n )\n : '';\n\n const isProcessing = isPending || isProgressing;\n\n // Map status to ProgressCircle-compatible status (only needed when shouldShowProgressCircle is true)\n let progressCircleStatus: 'pending' | 'progressing' | 'complete';\n if (isPending) {\n progressCircleStatus = 'pending';\n } else if (isProgressing) {\n progressCircleStatus = 'progressing';\n } else {\n progressCircleStatus = 'complete';\n }\n\n return (\n <div\n aria-busy={isProcessing || undefined}\n className={cn(\n 'group/list-file-card flex w-full min-w-0 cursor-pointer items-center justify-between p-xs',\n 'transition-all duration-200',\n {\n // Error state\n 'bg-background-critical-light': isError && !isDragging,\n // Default state\n 'bg-background-primary': !isError && !isDragging,\n // Drag state\n 'z-50 scale-105 border-border-selected bg-background-secondary shadow-01': isDragging,\n },\n // List View (BorderContained) vs Table View (Single Border)\n cardStyle === 'contained'\n ? cn('rounded-container border', {\n // Error state\n 'border-border-critical hover:border-border-critical hover:bg-background-critical-light':\n isError && !isDragging,\n // Default state\n 'border-border-secondary hover:border-border-secondary hover:bg-background-hover':\n !isError && !isDragging,\n })\n : cn('rounded-b-none border-b', {\n // Error state\n 'border-b-border-critical focus-within:border-b-border-critical hover:bg-background-critical-light':\n isError && !isDragging,\n // Default state\n 'border-b-border-secondary hover:bg-background-hover': !isError && !isDragging,\n }),\n className\n )}\n data-testid={dataTestId}\n >\n <div className=\"flex min-w-0 flex-1 items-center gap-xs\">\n <div className=\"flex items-center gap-[4px]\">\n {/* Show either Checkbox or DragHandle, not both */}\n {selectable ? (\n <Checkbox.Option\n checked={isSelected}\n className=\"![grid-template-columns:24px_0px_1fr]\"\n data-testid=\"list-file-card-select-checkbox\"\n onChange={(e: ChangeEvent<HTMLInputElement>) => {\n e.stopPropagation();\n onSelect?.(imageSource, e.target.checked);\n }}\n />\n ) : draggable ? (\n <DotsSixVertical\n color=\"primary\"\n size=\"sm\"\n style=\"bold\"\n />\n ) : null}\n {previewUrl ? (\n <div className=\"relative h-xl w-xl items-center justify-center overflow-hidden rounded-container bg-background-subdued\">\n <img\n alt={fileDisplayName}\n className=\"absolute inset-0 h-full w-full object-cover\"\n onError={() => {\n onImageError?.(imageSource);\n }}\n src={previewUrl}\n />\n </div>\n ) : (\n <div className=\"flex aspect-square min-w-xl items-center justify-center rounded-container bg-background-subdued\">\n <Paperclip\n color=\"primary\"\n size=\"sm\"\n />\n </div>\n )}\n </div>\n <div className=\"flex min-w-0 flex-1 flex-col gap-[2px]\">\n {!hideFileName && (\n <BodyPrimary\n className=\"truncate\"\n color={isError ? 'critical' : 'primary'}\n >\n {fileDisplayName}\n </BodyPrimary>\n )}\n {fileStatusText}\n </div>\n </div>\n {/* Actions */}\n <div className=\"flex items-center gap-[4px]\">\n {actions?.map((action, index) => (\n <IconButton\n aria-label={action.name}\n className={actionBtnClasses}\n disabled={isProcessing}\n icon={action.icon}\n key={`${action.name}-${index}`}\n onClick={(e) => {\n e.stopPropagation();\n action.onClick(e, imageSource);\n }}\n size=\"sm\"\n type=\"button\"\n />\n ))}\n {onDelete && (\n <IconButton\n aria-label=\"Remove file\"\n className={actionBtnClasses}\n data-testid=\"remove-file-button\"\n disabled={isProcessing}\n icon={Trash}\n onClick={() => onDelete(imageSource)}\n size=\"sm\"\n type=\"button\"\n />\n )}\n {shouldShowProgressCircle ? (\n <div\n className=\"flex items-center\"\n data-testid=\"list-file-card-progress-circle\"\n >\n <ProgressCircle\n progress={progress}\n size=\"sm\"\n status={progressCircleStatus}\n />\n </div>\n ) : statusIcon ? (\n statusIcon.type === 'progressCircle' ? (\n <div\n className=\"flex items-center\"\n data-testid=\"list-file-card-progress-circle\"\n >\n <ProgressCircle\n centerIcon={statusIcon.centerIcon}\n color={statusIcon.color}\n indeterminateAnimation={statusIcon.indeterminateAnimation}\n progress={progress}\n size=\"sm\"\n status={progressCircleStatus}\n />\n </div>\n ) : (\n <div\n className=\"flex items-center\"\n data-testid=\"list-file-card-status-icon\"\n >\n <statusIcon.icon\n color={statusIcon.color}\n size=\"md\"\n style={statusIcon.style}\n />\n </div>\n )\n ) : null}\n </div>\n </div>\n );\n};\n\nListFileCard.displayName = 'ListFileCard';\n","import { GridFileCard } from '../GridFileCard/GridFileCard';\nimport { ListFileCard } from '../ListFileCard/ListFileCard';\nimport { BaseFileCardProps, BaseFileCardStyle } from '../types';\n\nexport type FileCardProps = BaseFileCardProps & {\n badge?: string;\n cardStyle?: BaseFileCardStyle;\n 'data-testid'?: string;\n showActionsOnHover?: boolean;\n statusText?: string;\n};\n\nexport const FileCard = ({\n badge,\n cardStyle = 'contained',\n 'data-testid': dataTestId,\n errorMessage,\n progress,\n showActionsOnHover = false,\n status,\n statusIcon,\n statusText,\n ...props\n}: FileCardProps) =>\n cardStyle === 'card' ? (\n <GridFileCard\n {...props}\n badge={badge}\n data-testid={dataTestId}\n errorMessage={errorMessage}\n progress={progress}\n status={status}\n statusIcon={statusIcon}\n statusText={statusText}\n />\n ) : (\n <ListFileCard\n {...props}\n cardStyle={cardStyle}\n data-testid={dataTestId}\n errorMessage={errorMessage}\n progress={progress}\n showActionsOnHover={showActionsOnHover}\n status={status}\n statusIcon={statusIcon}\n statusText={statusText}\n />\n );\n\nFileCard.displayName = 'FileCard';\n","import { cn } from '@evolve.ui/theme-system';\nimport { useVirtualizer, VirtualItem } from '@tanstack/react-virtual';\nimport { useRef } from 'react';\n\nimport { FileCard, FileCardProps } from '../../../../components/FileCard/FileCard';\nimport { PreviewStyle } from '../../../../components/types';\nimport { FileResource } from '../../../../types';\n\n/**\n * Props for the virtualized list component\n */\ntype VirtualizedListProps = {\n // Common props passed from parent\n bulkSelectionEnabled?: boolean;\n createFileCardProps: (fileResource: FileResource, index: number) => FileCardProps;\n draggable?: boolean;\n files: FileResource[];\n hideDeleteAction?: boolean;\n hideFileNames?: boolean;\n hideFileSizes?: boolean;\n previewStyle: PreviewStyle;\n selectedFiles: string[];\n showActionsOnHover?: boolean;\n};\n\n/**\n * A virtualized list component for efficiently rendering large lists of file previews\n * Only renders items that are currently visible in the viewport\n */\nexport const FilePreviewVirtualizedList = ({ createFileCardProps, files, previewStyle }: VirtualizedListProps) => {\n const scrollRef = useRef<HTMLDivElement>(null);\n\n const listItemHeight = previewStyle === 'list' ? 66 : 65;\n const listItemGap = previewStyle === 'list' ? 8 : 0;\n\n const virtualizer = useVirtualizer({\n count: files.length,\n estimateSize: () => listItemHeight,\n gap: listItemGap,\n getScrollElement: () => scrollRef.current,\n overscan: 5,\n });\n\n const virtualItems = virtualizer.getVirtualItems();\n return (\n <div\n className=\"relative h-full overflow-y-auto\"\n ref={scrollRef}\n >\n <ul\n className={cn('flex flex-col', previewStyle === 'list' && 'gap-xs')}\n data-testid=\"file-preview-virtualized-list-element\"\n style={{\n height: `${virtualizer.getTotalSize()}px`,\n position: 'relative',\n width: '100%',\n }}\n >\n {virtualItems.map((virtualItem: VirtualItem) => {\n const file = files[virtualItem.index];\n\n return (\n <li\n data-index={virtualItem.index}\n data-testid={`file-preview-virtualized-list-item-${virtualItem.index}`}\n key={virtualItem.key}\n style={{\n height: `${virtualItem.size}px`,\n left: 0,\n position: 'absolute',\n top: 0,\n transform: `translateY(${virtualItem.start}px)`,\n width: '100%',\n }}\n >\n <FileCard\n data-testid={`file-preview-virtualized-list-card-${virtualItem.index}`}\n {...createFileCardProps(file, virtualItem.index)}\n />\n </li>\n );\n })}\n </ul>\n </div>\n );\n};\n\nFilePreviewVirtualizedList.displayName = 'FilePreviewVirtualizedList';\n","import { cn } from '@evolve.ui/theme-system';\nimport { breakpoints } from '@evolve.ui/theme-system/themes/common';\nimport { useCallback, useContext, useMemo, useState } from 'react';\n\nimport { useWindowWidth } from '../../../providers';\nimport { FileUploadContext, FileUploadContextType } from '../../providers/FileUploadProvider';\nimport { FileResource } from '../../types/commonTypes';\nimport { FileCard, FileCardProps } from '../FileCard/FileCard';\n/* eslint-disable curly */\nimport { BaseFileCardStyle, FileStatusConfig, PreviewStyle } from '../types';\nimport { FilePreviewVirtualizedList } from './virtualizerComponents/FilePreviewVirtualizedList/FilePreviewVirtualizedList';\n\ntype ColsByBreakpoint = {\n xs: number;\n} & { [key in 'sm' | 'md' | 'lg' | 'xl']?: number };\n\nexport type FilePreviewListProps = {\n /** Whether files in the list can be selected (or checked) */\n bulkSelectionEnabled?: boolean;\n /** Additional CSS classes */\n className?: string;\n /** Number of columns to display at each breakpoint, allowing you to create a custom grid layout. (grid view only) */\n colsByBreakpoint?: ColsByBreakpoint;\n /** Test ID for the component */\n 'data-testid'?: string;\n /** Whether files can be dragged and sorted */\n draggable?: boolean;\n /** Array of Files or RemoteFile Objects (typically with URLs) to display in the preview list */\n files?: FileResource[];\n /** Callback to configure status display (status, progress, error, icon, text) for each file */\n getFileStatusConfig?: (file: FileResource, index: number) => FileStatusConfig | undefined;\n /** Whether to hide the delete action on the file cards */\n hideDeleteAction?: boolean;\n /** Whether to hide the file names on the file cards */\n hideFileNames?: boolean;\n /** Whether to hide the file sizes on the file cards */\n hideFileSizes?: boolean;\n /** Whether to hide status messages on the file cards (error messages, \"Pending\", \"Uploading\", and custom statusText) */\n hideFileStatuses?: boolean;\n /** Called when user clicks delete button on a file preview */\n onDelete?: (fileResource: FileResource) => void;\n /** Called when user selects or deselects a file */\n onSelect?: (fileResource: FileResource, isSelected: boolean) => void;\n /** Determines the view style for the file preview list */\n previewStyle?: PreviewStyle;\n /** Whether to show delete button or other actions on hover (list view only) */\n showActionsOnHover?: boolean;\n /** Whether to use a virtualized list (Only used if previewStyle is list or compactList) */\n virtualized?: boolean;\n};\n\nconst VIEW_TO_CARD_STYLE: Record<PreviewStyle, BaseFileCardStyle> = {\n compactList: 'compact',\n grid: 'card',\n list: 'contained',\n};\n\nexport const FilePreviewList = ({\n bulkSelectionEnabled = false,\n className,\n colsByBreakpoint = { lg: 5, md: 4, sm: 3, xl: 5, xs: 3 },\n 'data-testid': dataTestId = 'file-preview-list',\n draggable = false,\n files: filesProp,\n getFileStatusConfig,\n hideDeleteAction = false,\n hideFileNames = false,\n hideFileSizes = false,\n hideFileStatuses = false,\n onDelete,\n onSelect,\n previewStyle = 'list',\n showActionsOnHover = false,\n virtualized = false,\n}: FilePreviewListProps) => {\n const uploadContext = useContext<FileUploadContextType | undefined>(FileUploadContext);\n // Check if we're in a provider by checking if files exist in context\n\n // Props should take precedence over context values (consistent with FileDropzone)\n // If files are provided as props, use those. Otherwise, fallback to context if available.\n const files = filesProp ?? uploadContext?.files ?? [];\n\n const handleDeleteFile = useCallback(\n (fileToDelete: FileResource) => {\n if (uploadContext && !onDelete) {\n // No onDelete handler, use automatic deletion from context state\n const fileToDeleteId = getItemIdentifier(fileToDelete);\n uploadContext.setFiles((prevFiles) =>\n prevFiles.filter((file) => getItemIdentifier(file) !== fileToDeleteId)\n );\n }\n onDelete?.(fileToDelete);\n },\n [uploadContext, onDelete]\n );\n\n const width = useWindowWidth();\n const [selectedFiles, setSelectedFiles] = useState<string[]>([]);\n\n const { lgMinValue, mdMinValue, smMinValue, xlMinValue } = breakpoints;\n\n const gridColumns = useMemo(() => {\n let columns = colsByBreakpoint.xs;\n // Start with mobile (xs) as default\n // Override with larger breakpoints if they exist and width matches\n if (width >= smMinValue && colsByBreakpoint.sm) columns = colsByBreakpoint.sm;\n if (width >= mdMinValue && colsByBreakpoint.md) columns = colsByBreakpoint.md;\n if (width >= lgMinValue && colsByBreakpoint.lg) columns = colsByBreakpoint.lg;\n if (width >= xlMinValue && colsByBreakpoint.xl) columns = colsByBreakpoint.xl;\n return columns;\n }, [width, colsByBreakpoint, lgMinValue, mdMinValue, smMinValue, xlMinValue]);\n\n const handleSelect = useCallback(\n (file: FileResource, isSelected: boolean) => {\n setSelectedFiles((prev) => {\n const name = file.name; // Both File and RemoteFile have name property\n\n if (isSelected) {\n return [...prev, name];\n }\n return prev.filter((n) => n !== name);\n });\n onSelect?.(file, isSelected);\n },\n [onSelect]\n );\n\n const containerClasses = cn(\n // Grid layout\n previewStyle === 'grid' && ['grid', gridColumns && `grid-cols-${gridColumns}`],\n // List/Table layout - only include gap-xs if viewStyle is list\n previewStyle !== 'grid' && ['flex flex-col', previewStyle === 'list' && 'gap-xs']\n );\n\n const cardStyle = VIEW_TO_CARD_STYLE[previewStyle];\n\n // Determine if we should use the virtualized list based on previewStyle and virtualized prop\n const shouldUseVirtualizedList = virtualized && (previewStyle === 'list' || previewStyle === 'compactList');\n\n // Common props used by both rendering paths\n const commonProps = {\n bulkSelectionEnabled,\n draggable,\n hideDeleteAction,\n hideFileNames,\n hideFileSizes,\n hideFileStatuses,\n showActionsOnHover,\n };\n\n // Helper to get a unique identifier for a file or URL\n const getItemIdentifier = (item: FileResource): string => {\n if ('url' in item) {\n // RemoteFile: id should be unique if provided, otherwise use url as fallback\n return item.id ?? item.url;\n }\n // File: use traditional properties for uniqueness\n return `${item.name}-${item.size}-${item.lastModified}`;\n };\n\n // Create shared FileCard props with common conditional logic\n const createFileCardProps = useCallback(\n (fileResource: FileResource, index: number): FileCardProps => {\n const name = fileResource.name;\n\n const isSelected = selectedFiles.includes(name);\n\n // FileCards hide the delete button when onDelete is not provided,\n // so we pass undefined when hideDeleteAction is true,\n // otherwise we pass the handleDeleteFile function\n const deleteHandler = hideDeleteAction ? undefined : handleDeleteFile;\n\n // Get status configuration from callback if provided\n const statusConfig = getFileStatusConfig?.(fileResource, index);\n\n return {\n cardStyle,\n draggable,\n errorMessage: statusConfig?.errorMessage,\n hideFileName: hideFileNames,\n hideFileSize: hideFileSizes,\n hideFileStatus: hideFileStatuses,\n imageSource: fileResource,\n onDelete: deleteHandler,\n onSelect: bulkSelectionEnabled ? handleSelect : undefined,\n ...(bulkSelectionEnabled ? { isSelected, selectable: true } : { selectable: false }),\n progress: statusConfig?.progress,\n showActionsOnHover,\n status: statusConfig?.status,\n statusIcon: statusConfig?.statusIcon,\n statusText: statusConfig?.statusText,\n };\n },\n [\n bulkSelectionEnabled,\n cardStyle,\n draggable,\n getFileStatusConfig,\n handleDeleteFile,\n handleSelect,\n hideDeleteAction,\n hideFileNames,\n hideFileSizes,\n hideFileStatuses,\n selectedFiles,\n showActionsOnHover,\n ]\n );\n\n return (\n <section\n aria-label=\"File preview list\"\n className={cn(\n 'flex w-full flex-col',\n {\n 'h-full': previewStyle !== 'grid',\n },\n className\n )}\n >\n {shouldUseVirtualizedList ? (\n <FilePreviewVirtualizedList\n {...commonProps}\n createFileCardProps={createFileCardProps}\n files={files}\n previewStyle={previewStyle}\n selectedFiles={selectedFiles}\n />\n ) : (\n <ul\n className={containerClasses}\n data-testid={dataTestId}\n >\n {files.map((fileResource, index) => (\n <li\n data-testid={`${dataTestId}-item-${index}`}\n key={`${getItemIdentifier(fileResource)}-${index}`}\n >\n <FileCard\n data-testid={`${dataTestId}-card-${index}`}\n {...createFileCardProps(fileResource, index)}\n />\n </li>\n ))}\n </ul>\n )}\n </section>\n );\n};\n\nFilePreviewList.displayName = 'FilePreviewList';\n","import { FileUploadProvider, FileUploadProviderConfigProps } from '../../providers/FileUploadProvider';\nimport { FileUploadProps } from '../../types/sharedTypes';\n/* eslint-disable curly */\nimport { FileDropzone } from '../FileDropzone/FileDropzone';\nimport { FilePreviewList } from '../FilePreviewList/FilePreviewList';\n\n/**\n * FileUpload component for handling single or multiple file uploads\n * with built-in validation and preview capabilities.\n *\n * This is the main container component that combines the drag-and-drop area (FileDropzone)\n * and the file preview list (FilePreviewList) into a single, cohesive interface.\n * It handles the file validation, upload state management, and preview display through\n * the FileUploadProvider context.\n *\n */\nexport const FileUpload = ({\n disabled,\n error,\n hideFilePreview = false,\n initialFiles,\n maxFiles,\n maxSize,\n onDrop,\n onDropAccepted,\n onDropRejected,\n onFileDelete,\n previewConfig,\n previewStyle = 'list',\n ...dropzoneProps\n}: FileUploadProps) => {\n const providerProps: FileUploadProviderConfigProps = {\n accept: dropzoneProps.accept,\n disabled,\n error,\n initialFiles,\n maxFiles,\n maxSize,\n onDrop,\n onDropAccepted,\n onDropRejected,\n onFileDelete,\n strictValidation: dropzoneProps.strictValidation,\n validator: dropzoneProps.validator,\n };\n\n return (\n <FileUploadProvider {...providerProps}>\n <div className=\"flex flex-col gap-md\">\n <FileDropzone {...dropzoneProps} />\n {!hideFilePreview && (\n <FilePreviewList\n {...previewConfig}\n onDelete={onFileDelete}\n previewStyle={previewStyle}\n />\n )}\n </div>\n </FileUploadProvider>\n );\n};\n\nFileUpload.displayName = 'FileUpload';\n","import { cn } from '@evolve.ui/theme-system';\nimport { useMemo } from 'react';\n\nimport { UploadValidationContextType } from '../../../providers/UploadValidationProvider';\n\ntype OverlayDropzoneDragTextProps = {\n dragText: string;\n isDragActive: boolean;\n validation: UploadValidationContextType;\n};\n\nexport const OverlayDropzoneDragText = ({ dragText, isDragActive, validation }: OverlayDropzoneDragTextProps) => {\n // Determine overlay text based on drag state and validation\n const overlayText = useMemo(() => {\n if (!isDragActive) {\n return null;\n }\n\n // Show validation error if present\n if (validation.dragValidationError?.message) {\n return validation.dragValidationError.message;\n }\n\n // Show success message for valid drag\n return dragText;\n }, [isDragActive, validation.dragValidationError, dragText]);\n\n if (!overlayText) {\n return null;\n }\n\n return (\n <div\n className={cn(\n 'text-xl font-medium',\n validation.dragValidationError ? 'text-text-critical' : 'text-blue-600'\n )}\n >\n {overlayText}\n </div>\n );\n};\n","import { useMemo } from 'react';\n\nimport { FileArchive, FileCsv, FilePdf, Files, FileText, ImageSquare, ImagesSquare } from '../../../../Icons';\nimport { UploadValidationContextType } from '../../../providers/UploadValidationProvider';\nimport { CommonFileTypes } from '../../../types/commonTypes';\nimport { OverlayDropzoneDragText } from './OverlayDropzoneDragText';\n\ntype OverlayContentProps = {\n accept?: CommonFileTypes | string[];\n customIcon?: React.ReactNode;\n dragText: string;\n isDragActive: boolean;\n maxFiles?: number;\n validation: UploadValidationContextType;\n};\n\nexport const OverlayDropzoneContent = ({\n accept,\n customIcon,\n dragText,\n isDragActive,\n maxFiles,\n validation,\n}: OverlayContentProps) => {\n // Determine icon color based on validation state\n const iconColor = validation.dragValidationError ? 'critical' : 'secondary';\n\n // Determine which icon to show based on accept and maxFiles\n const icon = useMemo(() => {\n // 1. Custom icon takes precedence\n if (customIcon) {\n return customIcon;\n }\n\n const isSingleFile = maxFiles === 1;\n\n // 2. Images\n if (accept === 'images' || (Array.isArray(accept) && accept.some((type) => type.startsWith('image/')))) {\n if (isSingleFile) {\n return (\n <ImageSquare\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n return (\n <ImagesSquare\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n\n // 3. Documents\n if (accept === 'documents') {\n if (isSingleFile) {\n return (\n <FileText\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n return (\n <Files\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n\n // 4. PDFs\n if (accept === 'pdfs' || (Array.isArray(accept) && accept.some((type) => type === 'application/pdf'))) {\n return (\n <FilePdf\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n\n // 5. CSV files\n if (\n Array.isArray(accept) &&\n accept.some((type) => type === 'text/csv' || type === '.csv' || type.includes('csv'))\n ) {\n return (\n <FileCsv\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n\n // 6. Archive files (zip, rar, 7z, tar, gz, etc.)\n if (\n Array.isArray(accept) &&\n accept.some(\n (type) =>\n type.includes('zip') ||\n type.includes('rar') ||\n type.includes('7z') ||\n type.includes('tar') ||\n type.includes('gzip') ||\n type === 'application/x-zip-compressed' ||\n type === 'application/x-rar-compressed' ||\n type === 'application/x-7z-compressed'\n )\n ) {\n return (\n <FileArchive\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }\n\n // 7. Default: general files icon\n return (\n <Files\n color={iconColor}\n size=\"lg\"\n style=\"duotone\"\n />\n );\n }, [customIcon, accept, maxFiles, iconColor]);\n\n return (\n <div className=\"text-center\">\n <div className=\"mb-xs flex justify-center\">{icon}</div>\n <OverlayDropzoneDragText\n dragText={dragText}\n isDragActive={isDragActive}\n validation={validation}\n />\n </div>\n );\n};\n","import { cn } from '@evolve.ui/theme-system';\n\nimport { FileError } from '../../types';\nimport { OverlayStyleOptions } from '../../types/sharedTypes';\n\ntype DropzoneState = {\n disableClickThrough: boolean;\n disableDragValidation: boolean;\n disabled: boolean;\n isDragActive: boolean;\n styleOptions?: OverlayStyleOptions;\n validationError?: FileError | null;\n};\n\nexport const getUploadOverlayStyles = ({\n disableClickThrough,\n disabled,\n disableDragValidation,\n isDragActive,\n styleOptions = {},\n validationError,\n}: DropzoneState) => {\n const { blurOnDrag = false, showDashedBorder = true } = styleOptions;\n\n const isInvalid = Boolean(validationError);\n const isErrorState = disableDragValidation ? false : isInvalid;\n const isDraggedOver = isDragActive && (disableDragValidation || !isInvalid);\n\n return cn(\n // Layout & Container\n [\n 'absolute inset-0',\n 'flex flex-col',\n 'h-full w-full',\n 'items-center justify-center',\n 'rounded-[var(--container-border-radius)]',\n showDashedBorder && 'outline-dashed outline-1 -outline-offset-1',\n 'transition-colors',\n disableClickThrough &&\n 'cursor-pointer group-hover/dropzone:bg-background-hover group-hover/dropzone:outline-border-hover',\n ],\n\n // Pointer Events Strategy:\n // - Only apply pointer-events-none when click-through is not disabled\n // - When disableClickThrough is true, the overlay captures all events\n // - The parent container (with getRootProps) captures drag events\n !disableClickThrough && 'pointer-events-none',\n\n // Z-Index: Always on top to be visible when drag is active\n 'z-10',\n\n // Focus & Interactive Base\n ['hui-focus-visible-outline'],\n\n // Interactive States\n {\n // Drag Active - thick blue outline when dragging\n 'outline outline-4 outline-offset-0 outline-focus-primary': isDragActive,\n },\n\n // Visual States\n {\n // Apply blur when enabled and dragging (success state)\n 'backdrop-blur-[2px]': blurOnDrag && isDraggedOver && !isErrorState && !disabled,\n\n // Apply blur when enabled and dragging (error state)\n 'backdrop-blur-sm': blurOnDrag && isDragActive && isErrorState,\n\n // Error (only when not disabled and dragging)\n 'bg-background-critical-light/50 outline-border-critical': isErrorState && !disabled && isDragActive,\n\n // Drag Over - show background when dragging\n 'bg-background-hover bg-background-secondary/90': isDraggedOver && !isErrorState && !disabled,\n\n // Default - transparent when not dragging\n 'bg-transparent outline-border-secondary': !isDragActive,\n }\n );\n};\n","import { cn } from '@evolve.ui/theme-system';\nimport { useContext } from 'react';\nimport { useDropzone } from 'react-dropzone';\n\nimport { useFileValidation } from '../../hooks';\nimport { useHandleDragEnter } from '../../hooks/upload/useHandleDragEnter/useHandleDragEnter';\nimport { useHandleDrop } from '../../hooks/upload/useHandleDrop/useHandleDrop';\nimport { useUploadAvailability } from '../../hooks/upload/useUploadAvailability/useUploadAvailability';\nimport { createDropzoneValidator } from '../../hooks/validation/createDropzoneValidator';\nimport { FileUploadContext, FileUploadContextType } from '../../providers/FileUploadProvider';\nimport { FileDropzoneOverlayProps } from '../../types/sharedTypes';\nimport { getMimeTypes } from '../../utils/getMimeTypes';\nimport { FileDropzoneDebugger } from '../FileDropzone/components/FileDropzoneDebugger/FileDropzoneDebugger';\nimport { OverlayDropzoneContent } from './components/OverlayDropzoneContent';\nimport { getUploadOverlayStyles } from './styles';\n\nexport const FileDropzoneOverlay = ({\n accept: acceptProp,\n ariaLabel,\n children,\n className,\n 'data-testid': dataTestId = 'file-dropzone-overlay',\n disableClickThrough = false,\n disabled: disabledProp = false,\n disableDragValidation = false,\n dragText = 'Drop files to upload',\n error,\n files: filesProp,\n icon,\n maxFiles: maxFilesProp,\n maxSize: maxSizeProp,\n onDrop: onDropProp,\n onDropAccepted: onDropAcceptedProp,\n onDropRejected: onDropRejectedProp,\n onFilesChange: onFilesChangeProp,\n showDebugger,\n strictValidation,\n styleOptions,\n validator,\n}: FileDropzoneOverlayProps) => {\n const uploadContext = useContext<FileUploadContextType | undefined>(FileUploadContext);\n\n const validationConfig = {\n accept: acceptProp,\n error,\n maxFiles: maxFilesProp,\n maxSize: maxSizeProp,\n strictValidation,\n validator,\n };\n\n /* IMPORTANT: This component supports both standalone usage and provider usage */\n // useFileValidation automatically detects if we're in a provider context\n // If not in provider, create local validation for standalone usage\n const validation = useFileValidation(validationConfig);\n\n // Determine whether to use context or local state for files and setFiles\n const files = filesProp ?? uploadContext?.files ?? [];\n const setFiles = onFilesChangeProp ?? uploadContext?.setFiles ?? (() => {});\n\n // Intentionally check both props and context with precedence order\n const disabled = disabledProp || uploadContext?.disabled;\n const onDrop = onDropProp ?? uploadContext?.onDrop;\n const onDropAccepted = onDropAcceptedProp ?? uploadContext?.onDropAccepted;\n const onDropRejected = onDropRejectedProp ?? uploadContext?.onDropRejected;\n const maxFiles = maxFilesProp ?? validation.maxFiles;\n const maxSize = maxSizeProp ?? validation.maxSize;\n const accept = acceptProp ?? validation.accept;\n /* END IMPORTANT */\n\n // Check if upload is disabled based on current state\n const { isDisabled } = useUploadAvailability({\n disabled,\n files,\n maxFiles,\n });\n\n // Configure text based on multiple vs single file mode\n const allowMultipleFiles = maxFiles === undefined || maxFiles > 1;\n const filePluralizationText = allowMultipleFiles ? 'files' : 'a file';\n const mimeTypes = getMimeTypes(accept);\n\n // Set up drag and drop handlers\n const handleDrop = useHandleDrop({\n files,\n onDrop,\n onDropAccepted,\n onDropRejected,\n setFiles,\n validation,\n });\n\n const handleDragEnter = useHandleDragEnter({\n files,\n mimeTypes,\n validation,\n validator,\n });\n\n // Configure the dropzone\n const { getInputProps, getRootProps, isDragActive } = useDropzone({\n accept: mimeTypes,\n disabled: isDisabled,\n maxSize,\n multiple: allowMultipleFiles,\n noClick: !disableClickThrough, // When clickThrough is not disabled, prevent file picker dialog\n noKeyboard: !disableClickThrough, // When clickThrough is not disabled, prevent keyboard interactions\n onDragEnter: disableDragValidation ? validation.clearAllValidation : handleDragEnter,\n onDragLeave: validation.clearAllValidation,\n onDrop: handleDrop,\n // @ts-expect-error Our validator returns potentially function-based messages, React-Dropzone expects strings.\n // This is intentional and allows us to resolve dynamic messages later with proper file counts.\n validator: createDropzoneValidator(validation),\n });\n\n // Determine Dropzone styles based on interaction state\n const activeCode = isDragActive ? validation.dragValidationError : validation.dropValidationErrors[0];\n const uploadZoneStyles = getUploadOverlayStyles({\n disableClickThrough,\n disabled: isDisabled,\n disableDragValidation,\n isDragActive,\n styleOptions,\n validationError: activeCode,\n });\n\n // Map innerPadding to Tailwind padding classes\n const paddingMap = {\n '2xl': 'p-2xl',\n lg: 'p-lg',\n md: 'p-md',\n sm: 'p-sm',\n xl: 'p-xl',\n xs: 'p-xs',\n } as const;\n const innerPaddingClass = styleOptions?.innerPadding ? paddingMap[styleOptions.innerPadding] : undefined;\n const fillParentClass = styleOptions?.fillParent ? 'h-full' : 'relative';\n\n return (\n <>\n <div\n {...getRootProps({\n 'aria-disabled': isDisabled,\n 'aria-label': ariaLabel ?? (isDragActive ? dragText : undefined),\n className: cn('group/dropzone', fillParentClass, className),\n 'data-testid': `${dataTestId}-root`,\n })}\n >\n <input\n {...getInputProps({\n 'aria-label': `Upload ${filePluralizationText}`,\n 'data-testid': `${dataTestId}-input`,\n })}\n />\n\n {/* Child content - isolation-isolate scopes children's z-indices so the overlay can sit above them */}\n <div className={cn('isolate', fillParentClass, innerPaddingClass)}>{children}</div>\n\n {/* Visual overlay - only appears when dragging */}\n <div\n className={cn('w-full', uploadZoneStyles)}\n data-testid={`${dataTestId}-container`}\n >\n {/* Only show visual feedback when actively dragging */}\n {isDragActive && (\n <OverlayDropzoneContent\n accept={accept}\n customIcon={icon}\n dragText={dragText}\n isDragActive={isDragActive}\n maxFiles={maxFiles}\n validation={validation}\n />\n )}\n </div>\n </div>\n {/* Display debug information around fileRejections when showDebugger is true */}\n {showDebugger && <FileDropzoneDebugger fileRejections={validation.fileRejections} />}\n </>\n );\n};\n\nFileDropzoneOverlay.displayName = 'FileDropzoneOverlay';\n","import { cn } from '@evolve.ui/theme-system';\nimport { useContext } from 'react';\n\nimport { UploadSimple } from '../../../Icons';\n/* eslint-disable curly */\nimport { BodyPrimary } from '../../../Typography/Text/Text';\nimport {\n FileUploadContext,\n FileUploadProvider,\n FileUploadProviderConfigProps,\n} from '../../providers/FileUploadProvider';\nimport { FileUploadCanvasProps } from '../../types/sharedTypes';\nimport { FileDropzoneOverlay } from '../FileDropzoneOverlay/FileDropzoneOverlay';\nimport { FilePreviewList } from '../FilePreviewList/FilePreviewList';\n\n/**\n * Empty state component displayed when no files are present\n */\nconst EmptyState = () => {\n return (\n <div className={cn('flex h-full flex-col items-center justify-center gap-xs', 'bg-gray-50 px-md py-2xl')}>\n <UploadSimple color=\"secondary\" />\n <BodyPrimary\n className=\"text-center\"\n color=\"secondary\"\n >\n Drag files here to upload\n </BodyPrimary>\n </div>\n );\n};\n\n/**\n * Canvas content that shows either FilePreviewList or empty state\n */\nconst CanvasContent = ({\n onFileDelete,\n previewConfig,\n previewStyle,\n}: {\n onFileDelete?: FileUploadCanvasProps['onFileDelete'];\n previewConfig?: FileUploadCanvasProps['previewConfig'];\n previewStyle: FileUploadCanvasProps['previewStyle'];\n}) => {\n const uploadContext = useContext(FileUploadContext);\n const files = uploadContext?.files ?? [];\n\n // Show empty state when no files\n if (files.length === 0) {\n return <EmptyState />;\n }\n\n // Show file preview list when files exist\n return (\n <FilePreviewList\n {...previewConfig}\n onDelete={onFileDelete}\n previewStyle={previewStyle}\n />\n );\n};\n\n/**\n * FileUploadCanvas component - An out-of-the-box solution for drag-and-drop file uploads\n * with overlay-based interaction.\n *\n * This component wraps FilePreviewList with FileDropzoneOverlay, allowing users to drag\n * files over existing content. The overlay appears during drag operations and provides\n * visual feedback. It uses FileUploadProvider for state management.\n *\n * Key differences from FileUpload:\n * - Uses FileDropzoneOverlay (overlay-based) instead of FileDropzone (dedicated area)\n * - Supports disableClickThrough for interactive content underneath\n * - Always shows FilePreviewList (no hideFilePreview option)\n * - Ideal for gallery views and canvas-style interfaces\n */\nexport const FileUploadCanvas = ({\n className,\n disabled,\n error,\n initialFiles,\n maxFiles,\n maxSize,\n onDrop,\n onDropAccepted,\n onDropRejected,\n onFileDelete,\n previewConfig,\n previewStyle = 'list',\n ...dropzoneOverlayProps\n}: FileUploadCanvasProps) => {\n const providerProps: FileUploadProviderConfigProps = {\n accept: dropzoneOverlayProps.accept,\n disabled,\n error,\n initialFiles,\n maxFiles,\n maxSize,\n onDrop,\n onDropAccepted,\n onDropRejected,\n onFileDelete,\n strictValidation: dropzoneOverlayProps.strictValidation,\n validator: dropzoneOverlayProps.validator,\n };\n\n return (\n <FileUploadProvider {...providerProps}>\n <div className={cn('h-full w-full overflow-y-auto', className)}>\n <FileDropzoneOverlay\n {...dropzoneOverlayProps}\n styleOptions={{ ...dropzoneOverlayProps.styleOptions, fillParent: true }}\n >\n <CanvasContent\n onFileDelete={onFileDelete}\n previewConfig={previewConfig}\n previewStyle={previewStyle}\n />\n </FileDropzoneOverlay>\n </div>\n </FileUploadProvider>\n );\n};\n\nFileUploadCanvas.displayName = 'FileUploadCanvas';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAiCA,MAAa,oBAAoB,cAAiD,KAAA,CAAS;;;;;;;;;;;;;;;;;;;;;;;;;;AAmH3F,MAAa,sBAAsB,EAC/B,QACA,UACA,WAAW,OACX,OACA,eAAe,CAAC,GAChB,UACA,SACA,QACA,gBACA,gBACA,cACA,kBACA,gBAC2B;CAC3B,MAAM,CAAC,OAAO,YAAY,SAAyB,YAAY;CAE/D,MAAM,QAAQ;EACV;EACA;EACA;EACA;EACA;EACA;EACA;EACA;CACJ;CAEA,OACI,oBAAC,0BAAD;EACY;EACD;EACG;EACD;EACS;EACP;YAEX,oBAAC,kBAAkB,UAAnB;GAAmC;GAAQ;EAAqC,CAAA;CAC1D,CAAA;AAElC;AAEA,mBAAmB,cAAc;;;;;;;;;;;;;;;;;;;;;AAsBjC,MAAa,6BAA6B;CACtC,MAAM,UAAU,WAA8C,iBAAiB;CAC/E,IAAI,CAAC,SACD,MAAM,IAAI,MAAM,6DAA6D;CAEjF,OAAO;AACX;;;ACpLA,MAAa,sBAAsB,EAAE,OAAO,WAAW,YAAY,gBAAyC;CACxG,MAAM,EACF,QACA,oBACA,kBACA,sBACA,UACA,SACA,wBACA,qBACA,mBACA,qBACA;CAEJ,OAAO,aACF,UAAwC;EAErC,mBAAmB;EAEnB,MAAM,QAAQ,MAAM,aAAa;EACjC,IAAI,MAAM,WAAW,GACjB;EAKJ,IAAI,WAAW;GAEX,MAAM,OAAO,MAAM;GACnB,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