cashdoc-cms-design-system 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/.gitkeep +0 -0
- package/dist/components/Button/Button.d.ts +11 -0
- package/dist/components/Button/index.d.ts +1 -0
- package/dist/components/Checkbox/Checkbox.d.ts +8 -0
- package/dist/components/Checkbox/index.d.ts +2 -0
- package/dist/components/DatePicker/DatePicker.d.ts +16 -0
- package/dist/components/DatePicker/DateRangePicker.d.ts +14 -0
- package/dist/components/DatePicker/index.d.ts +4 -0
- package/dist/components/Dropdown/Combobox.d.ts +8 -0
- package/dist/components/Dropdown/Dropdown.d.ts +25 -0
- package/dist/components/Dropdown/Select.d.ts +9 -0
- package/dist/components/Dropdown/index.d.ts +3 -0
- package/dist/components/LoadingCircle/LoadingCircle.d.ts +6 -0
- package/dist/components/LoadingCircle/index.d.ts +1 -0
- package/dist/components/Modal/ConfirmModal.d.ts +12 -0
- package/dist/components/Modal/DeleteModal.d.ts +14 -0
- package/dist/components/Modal/ErrorModal.d.ts +12 -0
- package/dist/components/Modal/Modal.d.ts +14 -0
- package/dist/components/Modal/SuccessModal.d.ts +12 -0
- package/dist/components/Modal/WarningModal.d.ts +14 -0
- package/dist/components/Modal/index.d.ts +12 -0
- package/dist/components/Popover/Popover.d.ts +5 -0
- package/dist/components/Popover/PopoverMenuItem.d.ts +11 -0
- package/dist/components/Popover/index.d.ts +3 -0
- package/dist/components/RadioButton/RadioButton.d.ts +13 -0
- package/dist/components/RadioButton/index.d.ts +1 -0
- package/dist/components/SideNavigation/SideNavigation.d.ts +21 -0
- package/dist/components/SideNavigation/index.d.ts +1 -0
- package/dist/components/Switch/Switch.d.ts +11 -0
- package/dist/components/Switch/index.d.ts +1 -0
- package/dist/components/TagInput/TagInput.d.ts +22 -0
- package/dist/components/TagInput/index.d.ts +1 -0
- package/dist/components/Text/Text.d.ts +14 -0
- package/dist/components/Text/index.d.ts +2 -0
- package/dist/components/TextInput/TextInput.d.ts +16 -0
- package/dist/components/TextInput/index.d.ts +2 -0
- package/dist/components/Toast/Toaster.d.ts +6 -0
- package/dist/components/Toast/index.d.ts +4 -0
- package/dist/components/icons/ChevronRightIcon.d.ts +3 -0
- package/dist/components/icons/index.d.ts +1 -0
- package/dist/components/index.d.ts +14 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.es.js +12652 -0
- package/dist/index.es.js.map +1 -0
- package/dist/index.umd.js +96 -0
- package/dist/index.umd.js.map +1 -0
- package/dist/style.css +1 -0
- package/dist/utils/cn.d.ts +3 -0
- package/package.json +98 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.umd.js","sources":["../node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs","../node_modules/.pnpm/tailwind-merge@2.6.0/node_modules/tailwind-merge/dist/bundle-mjs.mjs","../src/utils/cn.ts","../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.mjs","../src/components/Button/Button.tsx","../src/components/LoadingCircle/LoadingCircle.tsx","../src/components/Dropdown/Dropdown.tsx","../src/components/Dropdown/Select.tsx","../src/components/Dropdown/Combobox.tsx","../src/components/icons/ChevronRightIcon.tsx","../node_modules/.pnpm/@radix-ui+primitive@1.1.3/node_modules/@radix-ui/primitive/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-compose-refs@1.1.2_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-compose-refs/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-context@1.1.2_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-context/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-slot@1.2.3_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-slot/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-primitive@2.1.3_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18_yolw7mpxxngdeqhbiia4uh4qoe/node_modules/@radix-ui/react-primitive/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-use-callback-ref@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-use-escape-keydown@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-dismissable-layer@1.1.11_@types+react-dom@18.3.7_@types+react@18.3.27__@types_u6tzwtgv5ghthzjquanrhjxpva/node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-focus-guards@1.1.3_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-focus-guards/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-focus-scope@1.1.7_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@_vcdvmbqgklingdkgujb3ivph6i/node_modules/@radix-ui/react-focus-scope/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-use-layout-effect@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-id@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-id/dist/index.mjs","../node_modules/.pnpm/@floating-ui+utils@0.2.10/node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs","../node_modules/.pnpm/@floating-ui+core@1.7.3/node_modules/@floating-ui/core/dist/floating-ui.core.mjs","../node_modules/.pnpm/@floating-ui+utils@0.2.10/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs","../node_modules/.pnpm/@floating-ui+dom@1.7.4/node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs","../node_modules/.pnpm/@floating-ui+react-dom@2.1.6_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs","../node_modules/.pnpm/@radix-ui+react-arrow@1.1.7_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18.3.2_jmx3zqqqg4wfq7l2bjgl4svbuu/node_modules/@radix-ui/react-arrow/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-use-size@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-use-size/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-popper@1.2.8_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18.3._p4txy2d56fahetuxnqliciup5q/node_modules/@radix-ui/react-popper/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-portal@1.1.9_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18.3._7latw2vgc5q47ysk2odet7oazm/node_modules/@radix-ui/react-portal/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-presence@1.1.5_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18._rdlydof7lkhqrva5s2nvtprt3a/node_modules/@radix-ui/react-presence/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-use-controllable-state@1.2.2_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs","../node_modules/.pnpm/aria-hidden@1.2.6/node_modules/aria-hidden/dist/es2015/index.js","../node_modules/.pnpm/tslib@2.8.1/node_modules/tslib/tslib.es6.mjs","../node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll-bar/dist/es2015/constants.js","../node_modules/.pnpm/use-callback-ref@1.3.3_@types+react@18.3.27_react@18.3.1/node_modules/use-callback-ref/dist/es2015/assignRef.js","../node_modules/.pnpm/use-callback-ref@1.3.3_@types+react@18.3.27_react@18.3.1/node_modules/use-callback-ref/dist/es2015/useRef.js","../node_modules/.pnpm/use-callback-ref@1.3.3_@types+react@18.3.27_react@18.3.1/node_modules/use-callback-ref/dist/es2015/useMergeRef.js","../node_modules/.pnpm/use-sidecar@1.1.3_@types+react@18.3.27_react@18.3.1/node_modules/use-sidecar/dist/es2015/medium.js","../node_modules/.pnpm/use-sidecar@1.1.3_@types+react@18.3.27_react@18.3.1/node_modules/use-sidecar/dist/es2015/exports.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/medium.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/UI.js","../node_modules/.pnpm/get-nonce@1.0.1/node_modules/get-nonce/dist/es2015/index.js","../node_modules/.pnpm/react-style-singleton@2.2.3_@types+react@18.3.27_react@18.3.1/node_modules/react-style-singleton/dist/es2015/singleton.js","../node_modules/.pnpm/react-style-singleton@2.2.3_@types+react@18.3.27_react@18.3.1/node_modules/react-style-singleton/dist/es2015/hook.js","../node_modules/.pnpm/react-style-singleton@2.2.3_@types+react@18.3.27_react@18.3.1/node_modules/react-style-singleton/dist/es2015/component.js","../node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll-bar/dist/es2015/utils.js","../node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll-bar/dist/es2015/component.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/handleScroll.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/SideEffect.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/sidecar.js","../node_modules/.pnpm/react-remove-scroll@2.7.1_@types+react@18.3.27_react@18.3.1/node_modules/react-remove-scroll/dist/es2015/Combination.js","../node_modules/.pnpm/@radix-ui+react-popover@1.1.15_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18._m2p473qornmhi7clfx7qtlcnle/node_modules/@radix-ui/react-popover/dist/index.mjs","../src/components/Popover/Popover.tsx","../src/components/Popover/PopoverMenuItem.tsx","../src/components/Text/Text.tsx","../src/components/TextInput/TextInput.tsx","../node_modules/.pnpm/@date-fns+tz@1.4.1/node_modules/@date-fns/tz/tzName/index.js","../node_modules/.pnpm/@date-fns+tz@1.4.1/node_modules/@date-fns/tz/tzOffset/index.js","../node_modules/.pnpm/@date-fns+tz@1.4.1/node_modules/@date-fns/tz/date/mini.js","../node_modules/.pnpm/@date-fns+tz@1.4.1/node_modules/@date-fns/tz/date/index.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/constants.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/constructFrom.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/toDate.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/addDays.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/addMonths.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/defaultOptions.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfISOWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getISOWeekYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/normalizeDates.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfDay.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/differenceInCalendarDays.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfISOWeekYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/addWeeks.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/addYears.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/max.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/min.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isSameDay.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isDate.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isValid.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/differenceInCalendarMonths.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/endOfMonth.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/normalizeInterval.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/eachMonthOfInterval.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfMonth.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/endOfYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/eachYearOfInterval.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/endOfWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/endOfISOWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/en-US/_lib/formatDistance.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/_lib/buildFormatLongFn.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/en-US/_lib/formatLong.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/en-US/_lib/formatRelative.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/_lib/buildLocalizeFn.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/en-US/_lib/localize.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/_lib/buildMatchFn.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/_lib/buildMatchPatternFn.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/en-US/_lib/match.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/en-US.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getDayOfYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getISOWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getWeekYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/startOfWeekYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/addLeadingZeros.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/format/lightFormatters.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/format/formatters.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/format/longFormatters.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/_lib/protectedTokens.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/format.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getDaysInMonth.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getMonth.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/getYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isAfter.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isBefore.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isSameMonth.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/isSameYear.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/setMonth.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/setYear.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getBroadcastWeeksInMonth.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/startOfBroadcastWeek.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/endOfBroadcastWeek.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/ko/_lib/formatDistance.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/ko/_lib/formatLong.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/ko/_lib/formatRelative.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/ko/_lib/localize.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/ko/_lib/match.js","../node_modules/.pnpm/date-fns@4.1.0/node_modules/date-fns/locale/ko.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/locale/en-US.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/classes/DateLib.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/classes/CalendarDay.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/classes/CalendarMonth.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/classes/CalendarWeek.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Button.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/CaptionLabel.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Chevron.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Day.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/DayButton.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/UI.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Dropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/DropdownNav.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Footer.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Month.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/MonthCaption.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/MonthGrid.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Months.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/useDayPicker.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/MonthsDropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Nav.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/NextMonthButton.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Option.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/PreviousMonthButton.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Root.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Select.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Week.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Weekday.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Weekdays.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/WeekNumber.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/WeekNumberHeader.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/Weeks.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/components/YearsDropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/rangeIncludesDate.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/typeguards.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/dateMatchModifiers.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/createGetModifiers.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getClassNamesForModifiers.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getComponents.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getDataAttributes.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getDefaultClassNames.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatCaption.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatDay.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatMonthDropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatWeekdayName.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumber.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatWeekNumberHeader.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/formatters/formatYearDropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getFormatters.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelDayButton.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelGrid.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelGridcell.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelMonthDropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelNav.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelNext.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelPrevious.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelWeekday.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelWeekNumber.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelWeekNumberHeader.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/labels/labelYearDropdown.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getLabels.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getMonthOptions.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getStyleForModifiers.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getWeekdays.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/noonDateLib.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/useAnimation.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getDates.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getDays.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getDisplayMonths.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getInitialMonth.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getMonths.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getNavMonth.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getNextMonth.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getPreviousMonth.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getWeeks.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/useControlledValue.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/useCalendar.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/calculateFocusTarget.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getFocusableDate.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/helpers/getNextFocus.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/useFocus.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/selection/useMulti.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/addToRange.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/rangeContainsDayOfWeek.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/rangeOverlaps.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/rangeContainsModifiers.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/selection/useRange.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/selection/useSingle.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/useSelection.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/toTimeZone.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/utils/convertMatchersToTimeZone.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/DayPicker.js","../node_modules/.pnpm/react-day-picker@9.13.0_react@18.3.1/node_modules/react-day-picker/dist/esm/locale/ko.js","../node_modules/.pnpm/dayjs@1.11.19/node_modules/dayjs/dayjs.min.js","../src/components/DatePicker/DatePicker.tsx","../src/components/DatePicker/DateRangePicker.tsx","../node_modules/.pnpm/@radix-ui+react-use-previous@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-use-previous/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-switch@1.2.6_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18.3._yi5vaf653g4jb4tmc5zqwlzy5q/node_modules/@radix-ui/react-switch/dist/index.mjs","../src/components/Switch/Switch.tsx","../node_modules/.pnpm/@radix-ui+react-collection@1.1.7_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@1_z3knhvmqmfpwh2up5z67ro7hte/node_modules/@radix-ui/react-collection/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-direction@1.1.1_@types+react@18.3.27_react@18.3.1/node_modules/@radix-ui/react-direction/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-roving-focus@1.1.11_@types+react-dom@18.3.7_@types+react@18.3.27__@types+reac_t2y5wootrx6leibhxdnv4c3dmy/node_modules/@radix-ui/react-roving-focus/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-radio-group@1.3.8_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@_zhh3rrdo6k2hvlhh4tv5bq2xa4/node_modules/@radix-ui/react-radio-group/dist/index.mjs","../src/components/RadioButton/RadioButton.tsx","../node_modules/.pnpm/@radix-ui+react-collapsible@1.1.12_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react_i7ze3fssetsn4sk7mavx5frtxa/node_modules/@radix-ui/react-collapsible/dist/index.mjs","../node_modules/.pnpm/@radix-ui+react-accordion@1.2.12_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@1_b74zmvesd5vh24tqhyatrzlpsu/node_modules/@radix-ui/react-accordion/dist/index.mjs","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/shared/src/utils.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/defaultAttributes.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/Icon.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/createLucideIcon.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/check.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/chevron-down.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/circle-check.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/circle-x.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/triangle-alert.js","../node_modules/.pnpm/lucide-react@0.555.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/x.js","../src/components/SideNavigation/SideNavigation.tsx","../node_modules/.pnpm/@radix-ui+react-checkbox@1.3.3_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18._b2scsfwwuo7ermycxnjx5dwvaq/node_modules/@radix-ui/react-checkbox/dist/index.mjs","../src/components/Checkbox/Checkbox.tsx","../node_modules/.pnpm/@radix-ui+react-dialog@1.1.15_@types+react-dom@18.3.7_@types+react@18.3.27__@types+react@18.3_bwdzsrsjkenptt5ry5km67dkui/node_modules/@radix-ui/react-dialog/dist/index.mjs","../src/components/Modal/Modal.tsx","../src/components/Modal/ConfirmModal.tsx","../src/components/Modal/DeleteModal.tsx","../src/components/Modal/ErrorModal.tsx","../src/components/Modal/WarningModal.tsx","../src/components/Modal/SuccessModal.tsx","../node_modules/.pnpm/sonner@2.0.7_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/sonner/dist/index.mjs","../src/components/Toast/Toaster.tsx"],"sourcesContent":["function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","const CLASS_PART_SEPARATOR = '-';\nconst createClassGroupUtils = config => {\n const classMap = createClassMap(config);\n const {\n conflictingClassGroups,\n conflictingClassGroupModifiers\n } = config;\n const getClassGroupId = className => {\n const classParts = className.split(CLASS_PART_SEPARATOR);\n // Classes like `-inset-1` produce an empty string as first classPart. We assume that classes for negative values are used correctly and remove it from classParts.\n if (classParts[0] === '' && classParts.length !== 1) {\n classParts.shift();\n }\n return getGroupRecursive(classParts, classMap) || getGroupIdForArbitraryProperty(className);\n };\n const getConflictingClassGroupIds = (classGroupId, hasPostfixModifier) => {\n const conflicts = conflictingClassGroups[classGroupId] || [];\n if (hasPostfixModifier && conflictingClassGroupModifiers[classGroupId]) {\n return [...conflicts, ...conflictingClassGroupModifiers[classGroupId]];\n }\n return conflicts;\n };\n return {\n getClassGroupId,\n getConflictingClassGroupIds\n };\n};\nconst getGroupRecursive = (classParts, classPartObject) => {\n if (classParts.length === 0) {\n return classPartObject.classGroupId;\n }\n const currentClassPart = classParts[0];\n const nextClassPartObject = classPartObject.nextPart.get(currentClassPart);\n const classGroupFromNextClassPart = nextClassPartObject ? getGroupRecursive(classParts.slice(1), nextClassPartObject) : undefined;\n if (classGroupFromNextClassPart) {\n return classGroupFromNextClassPart;\n }\n if (classPartObject.validators.length === 0) {\n return undefined;\n }\n const classRest = classParts.join(CLASS_PART_SEPARATOR);\n return classPartObject.validators.find(({\n validator\n }) => validator(classRest))?.classGroupId;\n};\nconst arbitraryPropertyRegex = /^\\[(.+)\\]$/;\nconst getGroupIdForArbitraryProperty = className => {\n if (arbitraryPropertyRegex.test(className)) {\n const arbitraryPropertyClassName = arbitraryPropertyRegex.exec(className)[1];\n const property = arbitraryPropertyClassName?.substring(0, arbitraryPropertyClassName.indexOf(':'));\n if (property) {\n // I use two dots here because one dot is used as prefix for class groups in plugins\n return 'arbitrary..' + property;\n }\n }\n};\n/**\n * Exported for testing only\n */\nconst createClassMap = config => {\n const {\n theme,\n prefix\n } = config;\n const classMap = {\n nextPart: new Map(),\n validators: []\n };\n const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(config.classGroups), prefix);\n prefixedClassGroupEntries.forEach(([classGroupId, classGroup]) => {\n processClassesRecursively(classGroup, classMap, classGroupId, theme);\n });\n return classMap;\n};\nconst processClassesRecursively = (classGroup, classPartObject, classGroupId, theme) => {\n classGroup.forEach(classDefinition => {\n if (typeof classDefinition === 'string') {\n const classPartObjectToEdit = classDefinition === '' ? classPartObject : getPart(classPartObject, classDefinition);\n classPartObjectToEdit.classGroupId = classGroupId;\n return;\n }\n if (typeof classDefinition === 'function') {\n if (isThemeGetter(classDefinition)) {\n processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);\n return;\n }\n classPartObject.validators.push({\n validator: classDefinition,\n classGroupId\n });\n return;\n }\n Object.entries(classDefinition).forEach(([key, classGroup]) => {\n processClassesRecursively(classGroup, getPart(classPartObject, key), classGroupId, theme);\n });\n });\n};\nconst getPart = (classPartObject, path) => {\n let currentClassPartObject = classPartObject;\n path.split(CLASS_PART_SEPARATOR).forEach(pathPart => {\n if (!currentClassPartObject.nextPart.has(pathPart)) {\n currentClassPartObject.nextPart.set(pathPart, {\n nextPart: new Map(),\n validators: []\n });\n }\n currentClassPartObject = currentClassPartObject.nextPart.get(pathPart);\n });\n return currentClassPartObject;\n};\nconst isThemeGetter = func => func.isThemeGetter;\nconst getPrefixedClassGroupEntries = (classGroupEntries, prefix) => {\n if (!prefix) {\n return classGroupEntries;\n }\n return classGroupEntries.map(([classGroupId, classGroup]) => {\n const prefixedClassGroup = classGroup.map(classDefinition => {\n if (typeof classDefinition === 'string') {\n return prefix + classDefinition;\n }\n if (typeof classDefinition === 'object') {\n return Object.fromEntries(Object.entries(classDefinition).map(([key, value]) => [prefix + key, value]));\n }\n return classDefinition;\n });\n return [classGroupId, prefixedClassGroup];\n });\n};\n\n// LRU cache inspired from hashlru (https://github.com/dominictarr/hashlru/blob/v1.0.4/index.js) but object replaced with Map to improve performance\nconst createLruCache = maxCacheSize => {\n if (maxCacheSize < 1) {\n return {\n get: () => undefined,\n set: () => {}\n };\n }\n let cacheSize = 0;\n let cache = new Map();\n let previousCache = new Map();\n const update = (key, value) => {\n cache.set(key, value);\n cacheSize++;\n if (cacheSize > maxCacheSize) {\n cacheSize = 0;\n previousCache = cache;\n cache = new Map();\n }\n };\n return {\n get(key) {\n let value = cache.get(key);\n if (value !== undefined) {\n return value;\n }\n if ((value = previousCache.get(key)) !== undefined) {\n update(key, value);\n return value;\n }\n },\n set(key, value) {\n if (cache.has(key)) {\n cache.set(key, value);\n } else {\n update(key, value);\n }\n }\n };\n};\nconst IMPORTANT_MODIFIER = '!';\nconst createParseClassName = config => {\n const {\n separator,\n experimentalParseClassName\n } = config;\n const isSeparatorSingleCharacter = separator.length === 1;\n const firstSeparatorCharacter = separator[0];\n const separatorLength = separator.length;\n // parseClassName inspired by https://github.com/tailwindlabs/tailwindcss/blob/v3.2.2/src/util/splitAtTopLevelOnly.js\n const parseClassName = className => {\n const modifiers = [];\n let bracketDepth = 0;\n let modifierStart = 0;\n let postfixModifierPosition;\n for (let index = 0; index < className.length; index++) {\n let currentCharacter = className[index];\n if (bracketDepth === 0) {\n if (currentCharacter === firstSeparatorCharacter && (isSeparatorSingleCharacter || className.slice(index, index + separatorLength) === separator)) {\n modifiers.push(className.slice(modifierStart, index));\n modifierStart = index + separatorLength;\n continue;\n }\n if (currentCharacter === '/') {\n postfixModifierPosition = index;\n continue;\n }\n }\n if (currentCharacter === '[') {\n bracketDepth++;\n } else if (currentCharacter === ']') {\n bracketDepth--;\n }\n }\n const baseClassNameWithImportantModifier = modifiers.length === 0 ? className : className.substring(modifierStart);\n const hasImportantModifier = baseClassNameWithImportantModifier.startsWith(IMPORTANT_MODIFIER);\n const baseClassName = hasImportantModifier ? baseClassNameWithImportantModifier.substring(1) : baseClassNameWithImportantModifier;\n const maybePostfixModifierPosition = postfixModifierPosition && postfixModifierPosition > modifierStart ? postfixModifierPosition - modifierStart : undefined;\n return {\n modifiers,\n hasImportantModifier,\n baseClassName,\n maybePostfixModifierPosition\n };\n };\n if (experimentalParseClassName) {\n return className => experimentalParseClassName({\n className,\n parseClassName\n });\n }\n return parseClassName;\n};\n/**\n * Sorts modifiers according to following schema:\n * - Predefined modifiers are sorted alphabetically\n * - When an arbitrary variant appears, it must be preserved which modifiers are before and after it\n */\nconst sortModifiers = modifiers => {\n if (modifiers.length <= 1) {\n return modifiers;\n }\n const sortedModifiers = [];\n let unsortedModifiers = [];\n modifiers.forEach(modifier => {\n const isArbitraryVariant = modifier[0] === '[';\n if (isArbitraryVariant) {\n sortedModifiers.push(...unsortedModifiers.sort(), modifier);\n unsortedModifiers = [];\n } else {\n unsortedModifiers.push(modifier);\n }\n });\n sortedModifiers.push(...unsortedModifiers.sort());\n return sortedModifiers;\n};\nconst createConfigUtils = config => ({\n cache: createLruCache(config.cacheSize),\n parseClassName: createParseClassName(config),\n ...createClassGroupUtils(config)\n});\nconst SPLIT_CLASSES_REGEX = /\\s+/;\nconst mergeClassList = (classList, configUtils) => {\n const {\n parseClassName,\n getClassGroupId,\n getConflictingClassGroupIds\n } = configUtils;\n /**\n * Set of classGroupIds in following format:\n * `{importantModifier}{variantModifiers}{classGroupId}`\n * @example 'float'\n * @example 'hover:focus:bg-color'\n * @example 'md:!pr'\n */\n const classGroupsInConflict = [];\n const classNames = classList.trim().split(SPLIT_CLASSES_REGEX);\n let result = '';\n for (let index = classNames.length - 1; index >= 0; index -= 1) {\n const originalClassName = classNames[index];\n const {\n modifiers,\n hasImportantModifier,\n baseClassName,\n maybePostfixModifierPosition\n } = parseClassName(originalClassName);\n let hasPostfixModifier = Boolean(maybePostfixModifierPosition);\n let classGroupId = getClassGroupId(hasPostfixModifier ? baseClassName.substring(0, maybePostfixModifierPosition) : baseClassName);\n if (!classGroupId) {\n if (!hasPostfixModifier) {\n // Not a Tailwind class\n result = originalClassName + (result.length > 0 ? ' ' + result : result);\n continue;\n }\n classGroupId = getClassGroupId(baseClassName);\n if (!classGroupId) {\n // Not a Tailwind class\n result = originalClassName + (result.length > 0 ? ' ' + result : result);\n continue;\n }\n hasPostfixModifier = false;\n }\n const variantModifier = sortModifiers(modifiers).join(':');\n const modifierId = hasImportantModifier ? variantModifier + IMPORTANT_MODIFIER : variantModifier;\n const classId = modifierId + classGroupId;\n if (classGroupsInConflict.includes(classId)) {\n // Tailwind class omitted due to conflict\n continue;\n }\n classGroupsInConflict.push(classId);\n const conflictGroups = getConflictingClassGroupIds(classGroupId, hasPostfixModifier);\n for (let i = 0; i < conflictGroups.length; ++i) {\n const group = conflictGroups[i];\n classGroupsInConflict.push(modifierId + group);\n }\n // Tailwind class not in conflict\n result = originalClassName + (result.length > 0 ? ' ' + result : result);\n }\n return result;\n};\n\n/**\n * The code in this file is copied from https://github.com/lukeed/clsx and modified to suit the needs of tailwind-merge better.\n *\n * Specifically:\n * - Runtime code from https://github.com/lukeed/clsx/blob/v1.2.1/src/index.js\n * - TypeScript types from https://github.com/lukeed/clsx/blob/v1.2.1/clsx.d.ts\n *\n * Original code has MIT license: Copyright (c) Luke Edwards <luke.edwards05@gmail.com> (lukeed.com)\n */\nfunction twJoin() {\n let index = 0;\n let argument;\n let resolvedValue;\n let string = '';\n while (index < arguments.length) {\n if (argument = arguments[index++]) {\n if (resolvedValue = toValue(argument)) {\n string && (string += ' ');\n string += resolvedValue;\n }\n }\n }\n return string;\n}\nconst toValue = mix => {\n if (typeof mix === 'string') {\n return mix;\n }\n let resolvedValue;\n let string = '';\n for (let k = 0; k < mix.length; k++) {\n if (mix[k]) {\n if (resolvedValue = toValue(mix[k])) {\n string && (string += ' ');\n string += resolvedValue;\n }\n }\n }\n return string;\n};\nfunction createTailwindMerge(createConfigFirst, ...createConfigRest) {\n let configUtils;\n let cacheGet;\n let cacheSet;\n let functionToCall = initTailwindMerge;\n function initTailwindMerge(classList) {\n const config = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());\n configUtils = createConfigUtils(config);\n cacheGet = configUtils.cache.get;\n cacheSet = configUtils.cache.set;\n functionToCall = tailwindMerge;\n return tailwindMerge(classList);\n }\n function tailwindMerge(classList) {\n const cachedResult = cacheGet(classList);\n if (cachedResult) {\n return cachedResult;\n }\n const result = mergeClassList(classList, configUtils);\n cacheSet(classList, result);\n return result;\n }\n return function callTailwindMerge() {\n return functionToCall(twJoin.apply(null, arguments));\n };\n}\nconst fromTheme = key => {\n const themeGetter = theme => theme[key] || [];\n themeGetter.isThemeGetter = true;\n return themeGetter;\n};\nconst arbitraryValueRegex = /^\\[(?:([a-z-]+):)?(.+)\\]$/i;\nconst fractionRegex = /^\\d+\\/\\d+$/;\nconst stringLengths = /*#__PURE__*/new Set(['px', 'full', 'screen']);\nconst tshirtUnitRegex = /^(\\d+(\\.\\d+)?)?(xs|sm|md|lg|xl)$/;\nconst lengthUnitRegex = /\\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\\b(calc|min|max|clamp)\\(.+\\)|^0$/;\nconst colorFunctionRegex = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\\(.+\\)$/;\n// Shadow always begins with x and y offset separated by underscore optionally prepended by inset\nconst shadowRegex = /^(inset_)?-?((\\d+)?\\.?(\\d+)[a-z]+|0)_-?((\\d+)?\\.?(\\d+)[a-z]+|0)/;\nconst imageRegex = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\\(.+\\)$/;\nconst isLength = value => isNumber(value) || stringLengths.has(value) || fractionRegex.test(value);\nconst isArbitraryLength = value => getIsArbitraryValue(value, 'length', isLengthOnly);\nconst isNumber = value => Boolean(value) && !Number.isNaN(Number(value));\nconst isArbitraryNumber = value => getIsArbitraryValue(value, 'number', isNumber);\nconst isInteger = value => Boolean(value) && Number.isInteger(Number(value));\nconst isPercent = value => value.endsWith('%') && isNumber(value.slice(0, -1));\nconst isArbitraryValue = value => arbitraryValueRegex.test(value);\nconst isTshirtSize = value => tshirtUnitRegex.test(value);\nconst sizeLabels = /*#__PURE__*/new Set(['length', 'size', 'percentage']);\nconst isArbitrarySize = value => getIsArbitraryValue(value, sizeLabels, isNever);\nconst isArbitraryPosition = value => getIsArbitraryValue(value, 'position', isNever);\nconst imageLabels = /*#__PURE__*/new Set(['image', 'url']);\nconst isArbitraryImage = value => getIsArbitraryValue(value, imageLabels, isImage);\nconst isArbitraryShadow = value => getIsArbitraryValue(value, '', isShadow);\nconst isAny = () => true;\nconst getIsArbitraryValue = (value, label, testValue) => {\n const result = arbitraryValueRegex.exec(value);\n if (result) {\n if (result[1]) {\n return typeof label === 'string' ? result[1] === label : label.has(result[1]);\n }\n return testValue(result[2]);\n }\n return false;\n};\nconst isLengthOnly = value =>\n// `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.\n// For example, `hsl(0 0% 0%)` would be classified as a length without this check.\n// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.\nlengthUnitRegex.test(value) && !colorFunctionRegex.test(value);\nconst isNever = () => false;\nconst isShadow = value => shadowRegex.test(value);\nconst isImage = value => imageRegex.test(value);\nconst validators = /*#__PURE__*/Object.defineProperty({\n __proto__: null,\n isAny,\n isArbitraryImage,\n isArbitraryLength,\n isArbitraryNumber,\n isArbitraryPosition,\n isArbitraryShadow,\n isArbitrarySize,\n isArbitraryValue,\n isInteger,\n isLength,\n isNumber,\n isPercent,\n isTshirtSize\n}, Symbol.toStringTag, {\n value: 'Module'\n});\nconst getDefaultConfig = () => {\n const colors = fromTheme('colors');\n const spacing = fromTheme('spacing');\n const blur = fromTheme('blur');\n const brightness = fromTheme('brightness');\n const borderColor = fromTheme('borderColor');\n const borderRadius = fromTheme('borderRadius');\n const borderSpacing = fromTheme('borderSpacing');\n const borderWidth = fromTheme('borderWidth');\n const contrast = fromTheme('contrast');\n const grayscale = fromTheme('grayscale');\n const hueRotate = fromTheme('hueRotate');\n const invert = fromTheme('invert');\n const gap = fromTheme('gap');\n const gradientColorStops = fromTheme('gradientColorStops');\n const gradientColorStopPositions = fromTheme('gradientColorStopPositions');\n const inset = fromTheme('inset');\n const margin = fromTheme('margin');\n const opacity = fromTheme('opacity');\n const padding = fromTheme('padding');\n const saturate = fromTheme('saturate');\n const scale = fromTheme('scale');\n const sepia = fromTheme('sepia');\n const skew = fromTheme('skew');\n const space = fromTheme('space');\n const translate = fromTheme('translate');\n const getOverscroll = () => ['auto', 'contain', 'none'];\n const getOverflow = () => ['auto', 'hidden', 'clip', 'visible', 'scroll'];\n const getSpacingWithAutoAndArbitrary = () => ['auto', isArbitraryValue, spacing];\n const getSpacingWithArbitrary = () => [isArbitraryValue, spacing];\n const getLengthWithEmptyAndArbitrary = () => ['', isLength, isArbitraryLength];\n const getNumberWithAutoAndArbitrary = () => ['auto', isNumber, isArbitraryValue];\n const getPositions = () => ['bottom', 'center', 'left', 'left-bottom', 'left-top', 'right', 'right-bottom', 'right-top', 'top'];\n const getLineStyles = () => ['solid', 'dashed', 'dotted', 'double', 'none'];\n const getBlendModes = () => ['normal', 'multiply', 'screen', 'overlay', 'darken', 'lighten', 'color-dodge', 'color-burn', 'hard-light', 'soft-light', 'difference', 'exclusion', 'hue', 'saturation', 'color', 'luminosity'];\n const getAlign = () => ['start', 'end', 'center', 'between', 'around', 'evenly', 'stretch'];\n const getZeroAndEmpty = () => ['', '0', isArbitraryValue];\n const getBreaks = () => ['auto', 'avoid', 'all', 'avoid-page', 'page', 'left', 'right', 'column'];\n const getNumberAndArbitrary = () => [isNumber, isArbitraryValue];\n return {\n cacheSize: 500,\n separator: ':',\n theme: {\n colors: [isAny],\n spacing: [isLength, isArbitraryLength],\n blur: ['none', '', isTshirtSize, isArbitraryValue],\n brightness: getNumberAndArbitrary(),\n borderColor: [colors],\n borderRadius: ['none', '', 'full', isTshirtSize, isArbitraryValue],\n borderSpacing: getSpacingWithArbitrary(),\n borderWidth: getLengthWithEmptyAndArbitrary(),\n contrast: getNumberAndArbitrary(),\n grayscale: getZeroAndEmpty(),\n hueRotate: getNumberAndArbitrary(),\n invert: getZeroAndEmpty(),\n gap: getSpacingWithArbitrary(),\n gradientColorStops: [colors],\n gradientColorStopPositions: [isPercent, isArbitraryLength],\n inset: getSpacingWithAutoAndArbitrary(),\n margin: getSpacingWithAutoAndArbitrary(),\n opacity: getNumberAndArbitrary(),\n padding: getSpacingWithArbitrary(),\n saturate: getNumberAndArbitrary(),\n scale: getNumberAndArbitrary(),\n sepia: getZeroAndEmpty(),\n skew: getNumberAndArbitrary(),\n space: getSpacingWithArbitrary(),\n translate: getSpacingWithArbitrary()\n },\n classGroups: {\n // Layout\n /**\n * Aspect Ratio\n * @see https://tailwindcss.com/docs/aspect-ratio\n */\n aspect: [{\n aspect: ['auto', 'square', 'video', isArbitraryValue]\n }],\n /**\n * Container\n * @see https://tailwindcss.com/docs/container\n */\n container: ['container'],\n /**\n * Columns\n * @see https://tailwindcss.com/docs/columns\n */\n columns: [{\n columns: [isTshirtSize]\n }],\n /**\n * Break After\n * @see https://tailwindcss.com/docs/break-after\n */\n 'break-after': [{\n 'break-after': getBreaks()\n }],\n /**\n * Break Before\n * @see https://tailwindcss.com/docs/break-before\n */\n 'break-before': [{\n 'break-before': getBreaks()\n }],\n /**\n * Break Inside\n * @see https://tailwindcss.com/docs/break-inside\n */\n 'break-inside': [{\n 'break-inside': ['auto', 'avoid', 'avoid-page', 'avoid-column']\n }],\n /**\n * Box Decoration Break\n * @see https://tailwindcss.com/docs/box-decoration-break\n */\n 'box-decoration': [{\n 'box-decoration': ['slice', 'clone']\n }],\n /**\n * Box Sizing\n * @see https://tailwindcss.com/docs/box-sizing\n */\n box: [{\n box: ['border', 'content']\n }],\n /**\n * Display\n * @see https://tailwindcss.com/docs/display\n */\n display: ['block', 'inline-block', 'inline', 'flex', 'inline-flex', 'table', 'inline-table', 'table-caption', 'table-cell', 'table-column', 'table-column-group', 'table-footer-group', 'table-header-group', 'table-row-group', 'table-row', 'flow-root', 'grid', 'inline-grid', 'contents', 'list-item', 'hidden'],\n /**\n * Floats\n * @see https://tailwindcss.com/docs/float\n */\n float: [{\n float: ['right', 'left', 'none', 'start', 'end']\n }],\n /**\n * Clear\n * @see https://tailwindcss.com/docs/clear\n */\n clear: [{\n clear: ['left', 'right', 'both', 'none', 'start', 'end']\n }],\n /**\n * Isolation\n * @see https://tailwindcss.com/docs/isolation\n */\n isolation: ['isolate', 'isolation-auto'],\n /**\n * Object Fit\n * @see https://tailwindcss.com/docs/object-fit\n */\n 'object-fit': [{\n object: ['contain', 'cover', 'fill', 'none', 'scale-down']\n }],\n /**\n * Object Position\n * @see https://tailwindcss.com/docs/object-position\n */\n 'object-position': [{\n object: [...getPositions(), isArbitraryValue]\n }],\n /**\n * Overflow\n * @see https://tailwindcss.com/docs/overflow\n */\n overflow: [{\n overflow: getOverflow()\n }],\n /**\n * Overflow X\n * @see https://tailwindcss.com/docs/overflow\n */\n 'overflow-x': [{\n 'overflow-x': getOverflow()\n }],\n /**\n * Overflow Y\n * @see https://tailwindcss.com/docs/overflow\n */\n 'overflow-y': [{\n 'overflow-y': getOverflow()\n }],\n /**\n * Overscroll Behavior\n * @see https://tailwindcss.com/docs/overscroll-behavior\n */\n overscroll: [{\n overscroll: getOverscroll()\n }],\n /**\n * Overscroll Behavior X\n * @see https://tailwindcss.com/docs/overscroll-behavior\n */\n 'overscroll-x': [{\n 'overscroll-x': getOverscroll()\n }],\n /**\n * Overscroll Behavior Y\n * @see https://tailwindcss.com/docs/overscroll-behavior\n */\n 'overscroll-y': [{\n 'overscroll-y': getOverscroll()\n }],\n /**\n * Position\n * @see https://tailwindcss.com/docs/position\n */\n position: ['static', 'fixed', 'absolute', 'relative', 'sticky'],\n /**\n * Top / Right / Bottom / Left\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n inset: [{\n inset: [inset]\n }],\n /**\n * Right / Left\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n 'inset-x': [{\n 'inset-x': [inset]\n }],\n /**\n * Top / Bottom\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n 'inset-y': [{\n 'inset-y': [inset]\n }],\n /**\n * Start\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n start: [{\n start: [inset]\n }],\n /**\n * End\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n end: [{\n end: [inset]\n }],\n /**\n * Top\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n top: [{\n top: [inset]\n }],\n /**\n * Right\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n right: [{\n right: [inset]\n }],\n /**\n * Bottom\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n bottom: [{\n bottom: [inset]\n }],\n /**\n * Left\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n left: [{\n left: [inset]\n }],\n /**\n * Visibility\n * @see https://tailwindcss.com/docs/visibility\n */\n visibility: ['visible', 'invisible', 'collapse'],\n /**\n * Z-Index\n * @see https://tailwindcss.com/docs/z-index\n */\n z: [{\n z: ['auto', isInteger, isArbitraryValue]\n }],\n // Flexbox and Grid\n /**\n * Flex Basis\n * @see https://tailwindcss.com/docs/flex-basis\n */\n basis: [{\n basis: getSpacingWithAutoAndArbitrary()\n }],\n /**\n * Flex Direction\n * @see https://tailwindcss.com/docs/flex-direction\n */\n 'flex-direction': [{\n flex: ['row', 'row-reverse', 'col', 'col-reverse']\n }],\n /**\n * Flex Wrap\n * @see https://tailwindcss.com/docs/flex-wrap\n */\n 'flex-wrap': [{\n flex: ['wrap', 'wrap-reverse', 'nowrap']\n }],\n /**\n * Flex\n * @see https://tailwindcss.com/docs/flex\n */\n flex: [{\n flex: ['1', 'auto', 'initial', 'none', isArbitraryValue]\n }],\n /**\n * Flex Grow\n * @see https://tailwindcss.com/docs/flex-grow\n */\n grow: [{\n grow: getZeroAndEmpty()\n }],\n /**\n * Flex Shrink\n * @see https://tailwindcss.com/docs/flex-shrink\n */\n shrink: [{\n shrink: getZeroAndEmpty()\n }],\n /**\n * Order\n * @see https://tailwindcss.com/docs/order\n */\n order: [{\n order: ['first', 'last', 'none', isInteger, isArbitraryValue]\n }],\n /**\n * Grid Template Columns\n * @see https://tailwindcss.com/docs/grid-template-columns\n */\n 'grid-cols': [{\n 'grid-cols': [isAny]\n }],\n /**\n * Grid Column Start / End\n * @see https://tailwindcss.com/docs/grid-column\n */\n 'col-start-end': [{\n col: ['auto', {\n span: ['full', isInteger, isArbitraryValue]\n }, isArbitraryValue]\n }],\n /**\n * Grid Column Start\n * @see https://tailwindcss.com/docs/grid-column\n */\n 'col-start': [{\n 'col-start': getNumberWithAutoAndArbitrary()\n }],\n /**\n * Grid Column End\n * @see https://tailwindcss.com/docs/grid-column\n */\n 'col-end': [{\n 'col-end': getNumberWithAutoAndArbitrary()\n }],\n /**\n * Grid Template Rows\n * @see https://tailwindcss.com/docs/grid-template-rows\n */\n 'grid-rows': [{\n 'grid-rows': [isAny]\n }],\n /**\n * Grid Row Start / End\n * @see https://tailwindcss.com/docs/grid-row\n */\n 'row-start-end': [{\n row: ['auto', {\n span: [isInteger, isArbitraryValue]\n }, isArbitraryValue]\n }],\n /**\n * Grid Row Start\n * @see https://tailwindcss.com/docs/grid-row\n */\n 'row-start': [{\n 'row-start': getNumberWithAutoAndArbitrary()\n }],\n /**\n * Grid Row End\n * @see https://tailwindcss.com/docs/grid-row\n */\n 'row-end': [{\n 'row-end': getNumberWithAutoAndArbitrary()\n }],\n /**\n * Grid Auto Flow\n * @see https://tailwindcss.com/docs/grid-auto-flow\n */\n 'grid-flow': [{\n 'grid-flow': ['row', 'col', 'dense', 'row-dense', 'col-dense']\n }],\n /**\n * Grid Auto Columns\n * @see https://tailwindcss.com/docs/grid-auto-columns\n */\n 'auto-cols': [{\n 'auto-cols': ['auto', 'min', 'max', 'fr', isArbitraryValue]\n }],\n /**\n * Grid Auto Rows\n * @see https://tailwindcss.com/docs/grid-auto-rows\n */\n 'auto-rows': [{\n 'auto-rows': ['auto', 'min', 'max', 'fr', isArbitraryValue]\n }],\n /**\n * Gap\n * @see https://tailwindcss.com/docs/gap\n */\n gap: [{\n gap: [gap]\n }],\n /**\n * Gap X\n * @see https://tailwindcss.com/docs/gap\n */\n 'gap-x': [{\n 'gap-x': [gap]\n }],\n /**\n * Gap Y\n * @see https://tailwindcss.com/docs/gap\n */\n 'gap-y': [{\n 'gap-y': [gap]\n }],\n /**\n * Justify Content\n * @see https://tailwindcss.com/docs/justify-content\n */\n 'justify-content': [{\n justify: ['normal', ...getAlign()]\n }],\n /**\n * Justify Items\n * @see https://tailwindcss.com/docs/justify-items\n */\n 'justify-items': [{\n 'justify-items': ['start', 'end', 'center', 'stretch']\n }],\n /**\n * Justify Self\n * @see https://tailwindcss.com/docs/justify-self\n */\n 'justify-self': [{\n 'justify-self': ['auto', 'start', 'end', 'center', 'stretch']\n }],\n /**\n * Align Content\n * @see https://tailwindcss.com/docs/align-content\n */\n 'align-content': [{\n content: ['normal', ...getAlign(), 'baseline']\n }],\n /**\n * Align Items\n * @see https://tailwindcss.com/docs/align-items\n */\n 'align-items': [{\n items: ['start', 'end', 'center', 'baseline', 'stretch']\n }],\n /**\n * Align Self\n * @see https://tailwindcss.com/docs/align-self\n */\n 'align-self': [{\n self: ['auto', 'start', 'end', 'center', 'stretch', 'baseline']\n }],\n /**\n * Place Content\n * @see https://tailwindcss.com/docs/place-content\n */\n 'place-content': [{\n 'place-content': [...getAlign(), 'baseline']\n }],\n /**\n * Place Items\n * @see https://tailwindcss.com/docs/place-items\n */\n 'place-items': [{\n 'place-items': ['start', 'end', 'center', 'baseline', 'stretch']\n }],\n /**\n * Place Self\n * @see https://tailwindcss.com/docs/place-self\n */\n 'place-self': [{\n 'place-self': ['auto', 'start', 'end', 'center', 'stretch']\n }],\n // Spacing\n /**\n * Padding\n * @see https://tailwindcss.com/docs/padding\n */\n p: [{\n p: [padding]\n }],\n /**\n * Padding X\n * @see https://tailwindcss.com/docs/padding\n */\n px: [{\n px: [padding]\n }],\n /**\n * Padding Y\n * @see https://tailwindcss.com/docs/padding\n */\n py: [{\n py: [padding]\n }],\n /**\n * Padding Start\n * @see https://tailwindcss.com/docs/padding\n */\n ps: [{\n ps: [padding]\n }],\n /**\n * Padding End\n * @see https://tailwindcss.com/docs/padding\n */\n pe: [{\n pe: [padding]\n }],\n /**\n * Padding Top\n * @see https://tailwindcss.com/docs/padding\n */\n pt: [{\n pt: [padding]\n }],\n /**\n * Padding Right\n * @see https://tailwindcss.com/docs/padding\n */\n pr: [{\n pr: [padding]\n }],\n /**\n * Padding Bottom\n * @see https://tailwindcss.com/docs/padding\n */\n pb: [{\n pb: [padding]\n }],\n /**\n * Padding Left\n * @see https://tailwindcss.com/docs/padding\n */\n pl: [{\n pl: [padding]\n }],\n /**\n * Margin\n * @see https://tailwindcss.com/docs/margin\n */\n m: [{\n m: [margin]\n }],\n /**\n * Margin X\n * @see https://tailwindcss.com/docs/margin\n */\n mx: [{\n mx: [margin]\n }],\n /**\n * Margin Y\n * @see https://tailwindcss.com/docs/margin\n */\n my: [{\n my: [margin]\n }],\n /**\n * Margin Start\n * @see https://tailwindcss.com/docs/margin\n */\n ms: [{\n ms: [margin]\n }],\n /**\n * Margin End\n * @see https://tailwindcss.com/docs/margin\n */\n me: [{\n me: [margin]\n }],\n /**\n * Margin Top\n * @see https://tailwindcss.com/docs/margin\n */\n mt: [{\n mt: [margin]\n }],\n /**\n * Margin Right\n * @see https://tailwindcss.com/docs/margin\n */\n mr: [{\n mr: [margin]\n }],\n /**\n * Margin Bottom\n * @see https://tailwindcss.com/docs/margin\n */\n mb: [{\n mb: [margin]\n }],\n /**\n * Margin Left\n * @see https://tailwindcss.com/docs/margin\n */\n ml: [{\n ml: [margin]\n }],\n /**\n * Space Between X\n * @see https://tailwindcss.com/docs/space\n */\n 'space-x': [{\n 'space-x': [space]\n }],\n /**\n * Space Between X Reverse\n * @see https://tailwindcss.com/docs/space\n */\n 'space-x-reverse': ['space-x-reverse'],\n /**\n * Space Between Y\n * @see https://tailwindcss.com/docs/space\n */\n 'space-y': [{\n 'space-y': [space]\n }],\n /**\n * Space Between Y Reverse\n * @see https://tailwindcss.com/docs/space\n */\n 'space-y-reverse': ['space-y-reverse'],\n // Sizing\n /**\n * Width\n * @see https://tailwindcss.com/docs/width\n */\n w: [{\n w: ['auto', 'min', 'max', 'fit', 'svw', 'lvw', 'dvw', isArbitraryValue, spacing]\n }],\n /**\n * Min-Width\n * @see https://tailwindcss.com/docs/min-width\n */\n 'min-w': [{\n 'min-w': [isArbitraryValue, spacing, 'min', 'max', 'fit']\n }],\n /**\n * Max-Width\n * @see https://tailwindcss.com/docs/max-width\n */\n 'max-w': [{\n 'max-w': [isArbitraryValue, spacing, 'none', 'full', 'min', 'max', 'fit', 'prose', {\n screen: [isTshirtSize]\n }, isTshirtSize]\n }],\n /**\n * Height\n * @see https://tailwindcss.com/docs/height\n */\n h: [{\n h: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']\n }],\n /**\n * Min-Height\n * @see https://tailwindcss.com/docs/min-height\n */\n 'min-h': [{\n 'min-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']\n }],\n /**\n * Max-Height\n * @see https://tailwindcss.com/docs/max-height\n */\n 'max-h': [{\n 'max-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']\n }],\n /**\n * Size\n * @see https://tailwindcss.com/docs/size\n */\n size: [{\n size: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit']\n }],\n // Typography\n /**\n * Font Size\n * @see https://tailwindcss.com/docs/font-size\n */\n 'font-size': [{\n text: ['base', isTshirtSize, isArbitraryLength]\n }],\n /**\n * Font Smoothing\n * @see https://tailwindcss.com/docs/font-smoothing\n */\n 'font-smoothing': ['antialiased', 'subpixel-antialiased'],\n /**\n * Font Style\n * @see https://tailwindcss.com/docs/font-style\n */\n 'font-style': ['italic', 'not-italic'],\n /**\n * Font Weight\n * @see https://tailwindcss.com/docs/font-weight\n */\n 'font-weight': [{\n font: ['thin', 'extralight', 'light', 'normal', 'medium', 'semibold', 'bold', 'extrabold', 'black', isArbitraryNumber]\n }],\n /**\n * Font Family\n * @see https://tailwindcss.com/docs/font-family\n */\n 'font-family': [{\n font: [isAny]\n }],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-normal': ['normal-nums'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-ordinal': ['ordinal'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-slashed-zero': ['slashed-zero'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-figure': ['lining-nums', 'oldstyle-nums'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-spacing': ['proportional-nums', 'tabular-nums'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-fraction': ['diagonal-fractions', 'stacked-fractions'],\n /**\n * Letter Spacing\n * @see https://tailwindcss.com/docs/letter-spacing\n */\n tracking: [{\n tracking: ['tighter', 'tight', 'normal', 'wide', 'wider', 'widest', isArbitraryValue]\n }],\n /**\n * Line Clamp\n * @see https://tailwindcss.com/docs/line-clamp\n */\n 'line-clamp': [{\n 'line-clamp': ['none', isNumber, isArbitraryNumber]\n }],\n /**\n * Line Height\n * @see https://tailwindcss.com/docs/line-height\n */\n leading: [{\n leading: ['none', 'tight', 'snug', 'normal', 'relaxed', 'loose', isLength, isArbitraryValue]\n }],\n /**\n * List Style Image\n * @see https://tailwindcss.com/docs/list-style-image\n */\n 'list-image': [{\n 'list-image': ['none', isArbitraryValue]\n }],\n /**\n * List Style Type\n * @see https://tailwindcss.com/docs/list-style-type\n */\n 'list-style-type': [{\n list: ['none', 'disc', 'decimal', isArbitraryValue]\n }],\n /**\n * List Style Position\n * @see https://tailwindcss.com/docs/list-style-position\n */\n 'list-style-position': [{\n list: ['inside', 'outside']\n }],\n /**\n * Placeholder Color\n * @deprecated since Tailwind CSS v3.0.0\n * @see https://tailwindcss.com/docs/placeholder-color\n */\n 'placeholder-color': [{\n placeholder: [colors]\n }],\n /**\n * Placeholder Opacity\n * @see https://tailwindcss.com/docs/placeholder-opacity\n */\n 'placeholder-opacity': [{\n 'placeholder-opacity': [opacity]\n }],\n /**\n * Text Alignment\n * @see https://tailwindcss.com/docs/text-align\n */\n 'text-alignment': [{\n text: ['left', 'center', 'right', 'justify', 'start', 'end']\n }],\n /**\n * Text Color\n * @see https://tailwindcss.com/docs/text-color\n */\n 'text-color': [{\n text: [colors]\n }],\n /**\n * Text Opacity\n * @see https://tailwindcss.com/docs/text-opacity\n */\n 'text-opacity': [{\n 'text-opacity': [opacity]\n }],\n /**\n * Text Decoration\n * @see https://tailwindcss.com/docs/text-decoration\n */\n 'text-decoration': ['underline', 'overline', 'line-through', 'no-underline'],\n /**\n * Text Decoration Style\n * @see https://tailwindcss.com/docs/text-decoration-style\n */\n 'text-decoration-style': [{\n decoration: [...getLineStyles(), 'wavy']\n }],\n /**\n * Text Decoration Thickness\n * @see https://tailwindcss.com/docs/text-decoration-thickness\n */\n 'text-decoration-thickness': [{\n decoration: ['auto', 'from-font', isLength, isArbitraryLength]\n }],\n /**\n * Text Underline Offset\n * @see https://tailwindcss.com/docs/text-underline-offset\n */\n 'underline-offset': [{\n 'underline-offset': ['auto', isLength, isArbitraryValue]\n }],\n /**\n * Text Decoration Color\n * @see https://tailwindcss.com/docs/text-decoration-color\n */\n 'text-decoration-color': [{\n decoration: [colors]\n }],\n /**\n * Text Transform\n * @see https://tailwindcss.com/docs/text-transform\n */\n 'text-transform': ['uppercase', 'lowercase', 'capitalize', 'normal-case'],\n /**\n * Text Overflow\n * @see https://tailwindcss.com/docs/text-overflow\n */\n 'text-overflow': ['truncate', 'text-ellipsis', 'text-clip'],\n /**\n * Text Wrap\n * @see https://tailwindcss.com/docs/text-wrap\n */\n 'text-wrap': [{\n text: ['wrap', 'nowrap', 'balance', 'pretty']\n }],\n /**\n * Text Indent\n * @see https://tailwindcss.com/docs/text-indent\n */\n indent: [{\n indent: getSpacingWithArbitrary()\n }],\n /**\n * Vertical Alignment\n * @see https://tailwindcss.com/docs/vertical-align\n */\n 'vertical-align': [{\n align: ['baseline', 'top', 'middle', 'bottom', 'text-top', 'text-bottom', 'sub', 'super', isArbitraryValue]\n }],\n /**\n * Whitespace\n * @see https://tailwindcss.com/docs/whitespace\n */\n whitespace: [{\n whitespace: ['normal', 'nowrap', 'pre', 'pre-line', 'pre-wrap', 'break-spaces']\n }],\n /**\n * Word Break\n * @see https://tailwindcss.com/docs/word-break\n */\n break: [{\n break: ['normal', 'words', 'all', 'keep']\n }],\n /**\n * Hyphens\n * @see https://tailwindcss.com/docs/hyphens\n */\n hyphens: [{\n hyphens: ['none', 'manual', 'auto']\n }],\n /**\n * Content\n * @see https://tailwindcss.com/docs/content\n */\n content: [{\n content: ['none', isArbitraryValue]\n }],\n // Backgrounds\n /**\n * Background Attachment\n * @see https://tailwindcss.com/docs/background-attachment\n */\n 'bg-attachment': [{\n bg: ['fixed', 'local', 'scroll']\n }],\n /**\n * Background Clip\n * @see https://tailwindcss.com/docs/background-clip\n */\n 'bg-clip': [{\n 'bg-clip': ['border', 'padding', 'content', 'text']\n }],\n /**\n * Background Opacity\n * @deprecated since Tailwind CSS v3.0.0\n * @see https://tailwindcss.com/docs/background-opacity\n */\n 'bg-opacity': [{\n 'bg-opacity': [opacity]\n }],\n /**\n * Background Origin\n * @see https://tailwindcss.com/docs/background-origin\n */\n 'bg-origin': [{\n 'bg-origin': ['border', 'padding', 'content']\n }],\n /**\n * Background Position\n * @see https://tailwindcss.com/docs/background-position\n */\n 'bg-position': [{\n bg: [...getPositions(), isArbitraryPosition]\n }],\n /**\n * Background Repeat\n * @see https://tailwindcss.com/docs/background-repeat\n */\n 'bg-repeat': [{\n bg: ['no-repeat', {\n repeat: ['', 'x', 'y', 'round', 'space']\n }]\n }],\n /**\n * Background Size\n * @see https://tailwindcss.com/docs/background-size\n */\n 'bg-size': [{\n bg: ['auto', 'cover', 'contain', isArbitrarySize]\n }],\n /**\n * Background Image\n * @see https://tailwindcss.com/docs/background-image\n */\n 'bg-image': [{\n bg: ['none', {\n 'gradient-to': ['t', 'tr', 'r', 'br', 'b', 'bl', 'l', 'tl']\n }, isArbitraryImage]\n }],\n /**\n * Background Color\n * @see https://tailwindcss.com/docs/background-color\n */\n 'bg-color': [{\n bg: [colors]\n }],\n /**\n * Gradient Color Stops From Position\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-from-pos': [{\n from: [gradientColorStopPositions]\n }],\n /**\n * Gradient Color Stops Via Position\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-via-pos': [{\n via: [gradientColorStopPositions]\n }],\n /**\n * Gradient Color Stops To Position\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-to-pos': [{\n to: [gradientColorStopPositions]\n }],\n /**\n * Gradient Color Stops From\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-from': [{\n from: [gradientColorStops]\n }],\n /**\n * Gradient Color Stops Via\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-via': [{\n via: [gradientColorStops]\n }],\n /**\n * Gradient Color Stops To\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-to': [{\n to: [gradientColorStops]\n }],\n // Borders\n /**\n * Border Radius\n * @see https://tailwindcss.com/docs/border-radius\n */\n rounded: [{\n rounded: [borderRadius]\n }],\n /**\n * Border Radius Start\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-s': [{\n 'rounded-s': [borderRadius]\n }],\n /**\n * Border Radius End\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-e': [{\n 'rounded-e': [borderRadius]\n }],\n /**\n * Border Radius Top\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-t': [{\n 'rounded-t': [borderRadius]\n }],\n /**\n * Border Radius Right\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-r': [{\n 'rounded-r': [borderRadius]\n }],\n /**\n * Border Radius Bottom\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-b': [{\n 'rounded-b': [borderRadius]\n }],\n /**\n * Border Radius Left\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-l': [{\n 'rounded-l': [borderRadius]\n }],\n /**\n * Border Radius Start Start\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-ss': [{\n 'rounded-ss': [borderRadius]\n }],\n /**\n * Border Radius Start End\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-se': [{\n 'rounded-se': [borderRadius]\n }],\n /**\n * Border Radius End End\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-ee': [{\n 'rounded-ee': [borderRadius]\n }],\n /**\n * Border Radius End Start\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-es': [{\n 'rounded-es': [borderRadius]\n }],\n /**\n * Border Radius Top Left\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-tl': [{\n 'rounded-tl': [borderRadius]\n }],\n /**\n * Border Radius Top Right\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-tr': [{\n 'rounded-tr': [borderRadius]\n }],\n /**\n * Border Radius Bottom Right\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-br': [{\n 'rounded-br': [borderRadius]\n }],\n /**\n * Border Radius Bottom Left\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-bl': [{\n 'rounded-bl': [borderRadius]\n }],\n /**\n * Border Width\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w': [{\n border: [borderWidth]\n }],\n /**\n * Border Width X\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-x': [{\n 'border-x': [borderWidth]\n }],\n /**\n * Border Width Y\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-y': [{\n 'border-y': [borderWidth]\n }],\n /**\n * Border Width Start\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-s': [{\n 'border-s': [borderWidth]\n }],\n /**\n * Border Width End\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-e': [{\n 'border-e': [borderWidth]\n }],\n /**\n * Border Width Top\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-t': [{\n 'border-t': [borderWidth]\n }],\n /**\n * Border Width Right\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-r': [{\n 'border-r': [borderWidth]\n }],\n /**\n * Border Width Bottom\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-b': [{\n 'border-b': [borderWidth]\n }],\n /**\n * Border Width Left\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-l': [{\n 'border-l': [borderWidth]\n }],\n /**\n * Border Opacity\n * @see https://tailwindcss.com/docs/border-opacity\n */\n 'border-opacity': [{\n 'border-opacity': [opacity]\n }],\n /**\n * Border Style\n * @see https://tailwindcss.com/docs/border-style\n */\n 'border-style': [{\n border: [...getLineStyles(), 'hidden']\n }],\n /**\n * Divide Width X\n * @see https://tailwindcss.com/docs/divide-width\n */\n 'divide-x': [{\n 'divide-x': [borderWidth]\n }],\n /**\n * Divide Width X Reverse\n * @see https://tailwindcss.com/docs/divide-width\n */\n 'divide-x-reverse': ['divide-x-reverse'],\n /**\n * Divide Width Y\n * @see https://tailwindcss.com/docs/divide-width\n */\n 'divide-y': [{\n 'divide-y': [borderWidth]\n }],\n /**\n * Divide Width Y Reverse\n * @see https://tailwindcss.com/docs/divide-width\n */\n 'divide-y-reverse': ['divide-y-reverse'],\n /**\n * Divide Opacity\n * @see https://tailwindcss.com/docs/divide-opacity\n */\n 'divide-opacity': [{\n 'divide-opacity': [opacity]\n }],\n /**\n * Divide Style\n * @see https://tailwindcss.com/docs/divide-style\n */\n 'divide-style': [{\n divide: getLineStyles()\n }],\n /**\n * Border Color\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color': [{\n border: [borderColor]\n }],\n /**\n * Border Color X\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-x': [{\n 'border-x': [borderColor]\n }],\n /**\n * Border Color Y\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-y': [{\n 'border-y': [borderColor]\n }],\n /**\n * Border Color S\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-s': [{\n 'border-s': [borderColor]\n }],\n /**\n * Border Color E\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-e': [{\n 'border-e': [borderColor]\n }],\n /**\n * Border Color Top\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-t': [{\n 'border-t': [borderColor]\n }],\n /**\n * Border Color Right\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-r': [{\n 'border-r': [borderColor]\n }],\n /**\n * Border Color Bottom\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-b': [{\n 'border-b': [borderColor]\n }],\n /**\n * Border Color Left\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-l': [{\n 'border-l': [borderColor]\n }],\n /**\n * Divide Color\n * @see https://tailwindcss.com/docs/divide-color\n */\n 'divide-color': [{\n divide: [borderColor]\n }],\n /**\n * Outline Style\n * @see https://tailwindcss.com/docs/outline-style\n */\n 'outline-style': [{\n outline: ['', ...getLineStyles()]\n }],\n /**\n * Outline Offset\n * @see https://tailwindcss.com/docs/outline-offset\n */\n 'outline-offset': [{\n 'outline-offset': [isLength, isArbitraryValue]\n }],\n /**\n * Outline Width\n * @see https://tailwindcss.com/docs/outline-width\n */\n 'outline-w': [{\n outline: [isLength, isArbitraryLength]\n }],\n /**\n * Outline Color\n * @see https://tailwindcss.com/docs/outline-color\n */\n 'outline-color': [{\n outline: [colors]\n }],\n /**\n * Ring Width\n * @see https://tailwindcss.com/docs/ring-width\n */\n 'ring-w': [{\n ring: getLengthWithEmptyAndArbitrary()\n }],\n /**\n * Ring Width Inset\n * @see https://tailwindcss.com/docs/ring-width\n */\n 'ring-w-inset': ['ring-inset'],\n /**\n * Ring Color\n * @see https://tailwindcss.com/docs/ring-color\n */\n 'ring-color': [{\n ring: [colors]\n }],\n /**\n * Ring Opacity\n * @see https://tailwindcss.com/docs/ring-opacity\n */\n 'ring-opacity': [{\n 'ring-opacity': [opacity]\n }],\n /**\n * Ring Offset Width\n * @see https://tailwindcss.com/docs/ring-offset-width\n */\n 'ring-offset-w': [{\n 'ring-offset': [isLength, isArbitraryLength]\n }],\n /**\n * Ring Offset Color\n * @see https://tailwindcss.com/docs/ring-offset-color\n */\n 'ring-offset-color': [{\n 'ring-offset': [colors]\n }],\n // Effects\n /**\n * Box Shadow\n * @see https://tailwindcss.com/docs/box-shadow\n */\n shadow: [{\n shadow: ['', 'inner', 'none', isTshirtSize, isArbitraryShadow]\n }],\n /**\n * Box Shadow Color\n * @see https://tailwindcss.com/docs/box-shadow-color\n */\n 'shadow-color': [{\n shadow: [isAny]\n }],\n /**\n * Opacity\n * @see https://tailwindcss.com/docs/opacity\n */\n opacity: [{\n opacity: [opacity]\n }],\n /**\n * Mix Blend Mode\n * @see https://tailwindcss.com/docs/mix-blend-mode\n */\n 'mix-blend': [{\n 'mix-blend': [...getBlendModes(), 'plus-lighter', 'plus-darker']\n }],\n /**\n * Background Blend Mode\n * @see https://tailwindcss.com/docs/background-blend-mode\n */\n 'bg-blend': [{\n 'bg-blend': getBlendModes()\n }],\n // Filters\n /**\n * Filter\n * @deprecated since Tailwind CSS v3.0.0\n * @see https://tailwindcss.com/docs/filter\n */\n filter: [{\n filter: ['', 'none']\n }],\n /**\n * Blur\n * @see https://tailwindcss.com/docs/blur\n */\n blur: [{\n blur: [blur]\n }],\n /**\n * Brightness\n * @see https://tailwindcss.com/docs/brightness\n */\n brightness: [{\n brightness: [brightness]\n }],\n /**\n * Contrast\n * @see https://tailwindcss.com/docs/contrast\n */\n contrast: [{\n contrast: [contrast]\n }],\n /**\n * Drop Shadow\n * @see https://tailwindcss.com/docs/drop-shadow\n */\n 'drop-shadow': [{\n 'drop-shadow': ['', 'none', isTshirtSize, isArbitraryValue]\n }],\n /**\n * Grayscale\n * @see https://tailwindcss.com/docs/grayscale\n */\n grayscale: [{\n grayscale: [grayscale]\n }],\n /**\n * Hue Rotate\n * @see https://tailwindcss.com/docs/hue-rotate\n */\n 'hue-rotate': [{\n 'hue-rotate': [hueRotate]\n }],\n /**\n * Invert\n * @see https://tailwindcss.com/docs/invert\n */\n invert: [{\n invert: [invert]\n }],\n /**\n * Saturate\n * @see https://tailwindcss.com/docs/saturate\n */\n saturate: [{\n saturate: [saturate]\n }],\n /**\n * Sepia\n * @see https://tailwindcss.com/docs/sepia\n */\n sepia: [{\n sepia: [sepia]\n }],\n /**\n * Backdrop Filter\n * @deprecated since Tailwind CSS v3.0.0\n * @see https://tailwindcss.com/docs/backdrop-filter\n */\n 'backdrop-filter': [{\n 'backdrop-filter': ['', 'none']\n }],\n /**\n * Backdrop Blur\n * @see https://tailwindcss.com/docs/backdrop-blur\n */\n 'backdrop-blur': [{\n 'backdrop-blur': [blur]\n }],\n /**\n * Backdrop Brightness\n * @see https://tailwindcss.com/docs/backdrop-brightness\n */\n 'backdrop-brightness': [{\n 'backdrop-brightness': [brightness]\n }],\n /**\n * Backdrop Contrast\n * @see https://tailwindcss.com/docs/backdrop-contrast\n */\n 'backdrop-contrast': [{\n 'backdrop-contrast': [contrast]\n }],\n /**\n * Backdrop Grayscale\n * @see https://tailwindcss.com/docs/backdrop-grayscale\n */\n 'backdrop-grayscale': [{\n 'backdrop-grayscale': [grayscale]\n }],\n /**\n * Backdrop Hue Rotate\n * @see https://tailwindcss.com/docs/backdrop-hue-rotate\n */\n 'backdrop-hue-rotate': [{\n 'backdrop-hue-rotate': [hueRotate]\n }],\n /**\n * Backdrop Invert\n * @see https://tailwindcss.com/docs/backdrop-invert\n */\n 'backdrop-invert': [{\n 'backdrop-invert': [invert]\n }],\n /**\n * Backdrop Opacity\n * @see https://tailwindcss.com/docs/backdrop-opacity\n */\n 'backdrop-opacity': [{\n 'backdrop-opacity': [opacity]\n }],\n /**\n * Backdrop Saturate\n * @see https://tailwindcss.com/docs/backdrop-saturate\n */\n 'backdrop-saturate': [{\n 'backdrop-saturate': [saturate]\n }],\n /**\n * Backdrop Sepia\n * @see https://tailwindcss.com/docs/backdrop-sepia\n */\n 'backdrop-sepia': [{\n 'backdrop-sepia': [sepia]\n }],\n // Tables\n /**\n * Border Collapse\n * @see https://tailwindcss.com/docs/border-collapse\n */\n 'border-collapse': [{\n border: ['collapse', 'separate']\n }],\n /**\n * Border Spacing\n * @see https://tailwindcss.com/docs/border-spacing\n */\n 'border-spacing': [{\n 'border-spacing': [borderSpacing]\n }],\n /**\n * Border Spacing X\n * @see https://tailwindcss.com/docs/border-spacing\n */\n 'border-spacing-x': [{\n 'border-spacing-x': [borderSpacing]\n }],\n /**\n * Border Spacing Y\n * @see https://tailwindcss.com/docs/border-spacing\n */\n 'border-spacing-y': [{\n 'border-spacing-y': [borderSpacing]\n }],\n /**\n * Table Layout\n * @see https://tailwindcss.com/docs/table-layout\n */\n 'table-layout': [{\n table: ['auto', 'fixed']\n }],\n /**\n * Caption Side\n * @see https://tailwindcss.com/docs/caption-side\n */\n caption: [{\n caption: ['top', 'bottom']\n }],\n // Transitions and Animation\n /**\n * Tranisition Property\n * @see https://tailwindcss.com/docs/transition-property\n */\n transition: [{\n transition: ['none', 'all', '', 'colors', 'opacity', 'shadow', 'transform', isArbitraryValue]\n }],\n /**\n * Transition Duration\n * @see https://tailwindcss.com/docs/transition-duration\n */\n duration: [{\n duration: getNumberAndArbitrary()\n }],\n /**\n * Transition Timing Function\n * @see https://tailwindcss.com/docs/transition-timing-function\n */\n ease: [{\n ease: ['linear', 'in', 'out', 'in-out', isArbitraryValue]\n }],\n /**\n * Transition Delay\n * @see https://tailwindcss.com/docs/transition-delay\n */\n delay: [{\n delay: getNumberAndArbitrary()\n }],\n /**\n * Animation\n * @see https://tailwindcss.com/docs/animation\n */\n animate: [{\n animate: ['none', 'spin', 'ping', 'pulse', 'bounce', isArbitraryValue]\n }],\n // Transforms\n /**\n * Transform\n * @see https://tailwindcss.com/docs/transform\n */\n transform: [{\n transform: ['', 'gpu', 'none']\n }],\n /**\n * Scale\n * @see https://tailwindcss.com/docs/scale\n */\n scale: [{\n scale: [scale]\n }],\n /**\n * Scale X\n * @see https://tailwindcss.com/docs/scale\n */\n 'scale-x': [{\n 'scale-x': [scale]\n }],\n /**\n * Scale Y\n * @see https://tailwindcss.com/docs/scale\n */\n 'scale-y': [{\n 'scale-y': [scale]\n }],\n /**\n * Rotate\n * @see https://tailwindcss.com/docs/rotate\n */\n rotate: [{\n rotate: [isInteger, isArbitraryValue]\n }],\n /**\n * Translate X\n * @see https://tailwindcss.com/docs/translate\n */\n 'translate-x': [{\n 'translate-x': [translate]\n }],\n /**\n * Translate Y\n * @see https://tailwindcss.com/docs/translate\n */\n 'translate-y': [{\n 'translate-y': [translate]\n }],\n /**\n * Skew X\n * @see https://tailwindcss.com/docs/skew\n */\n 'skew-x': [{\n 'skew-x': [skew]\n }],\n /**\n * Skew Y\n * @see https://tailwindcss.com/docs/skew\n */\n 'skew-y': [{\n 'skew-y': [skew]\n }],\n /**\n * Transform Origin\n * @see https://tailwindcss.com/docs/transform-origin\n */\n 'transform-origin': [{\n origin: ['center', 'top', 'top-right', 'right', 'bottom-right', 'bottom', 'bottom-left', 'left', 'top-left', isArbitraryValue]\n }],\n // Interactivity\n /**\n * Accent Color\n * @see https://tailwindcss.com/docs/accent-color\n */\n accent: [{\n accent: ['auto', colors]\n }],\n /**\n * Appearance\n * @see https://tailwindcss.com/docs/appearance\n */\n appearance: [{\n appearance: ['none', 'auto']\n }],\n /**\n * Cursor\n * @see https://tailwindcss.com/docs/cursor\n */\n cursor: [{\n cursor: ['auto', 'default', 'pointer', 'wait', 'text', 'move', 'help', 'not-allowed', 'none', 'context-menu', 'progress', 'cell', 'crosshair', 'vertical-text', 'alias', 'copy', 'no-drop', 'grab', 'grabbing', 'all-scroll', 'col-resize', 'row-resize', 'n-resize', 'e-resize', 's-resize', 'w-resize', 'ne-resize', 'nw-resize', 'se-resize', 'sw-resize', 'ew-resize', 'ns-resize', 'nesw-resize', 'nwse-resize', 'zoom-in', 'zoom-out', isArbitraryValue]\n }],\n /**\n * Caret Color\n * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities\n */\n 'caret-color': [{\n caret: [colors]\n }],\n /**\n * Pointer Events\n * @see https://tailwindcss.com/docs/pointer-events\n */\n 'pointer-events': [{\n 'pointer-events': ['none', 'auto']\n }],\n /**\n * Resize\n * @see https://tailwindcss.com/docs/resize\n */\n resize: [{\n resize: ['none', 'y', 'x', '']\n }],\n /**\n * Scroll Behavior\n * @see https://tailwindcss.com/docs/scroll-behavior\n */\n 'scroll-behavior': [{\n scroll: ['auto', 'smooth']\n }],\n /**\n * Scroll Margin\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-m': [{\n 'scroll-m': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin X\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mx': [{\n 'scroll-mx': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin Y\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-my': [{\n 'scroll-my': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin Start\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-ms': [{\n 'scroll-ms': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin End\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-me': [{\n 'scroll-me': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin Top\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mt': [{\n 'scroll-mt': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin Right\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mr': [{\n 'scroll-mr': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin Bottom\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mb': [{\n 'scroll-mb': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Margin Left\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-ml': [{\n 'scroll-ml': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-p': [{\n 'scroll-p': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding X\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-px': [{\n 'scroll-px': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding Y\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-py': [{\n 'scroll-py': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding Start\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-ps': [{\n 'scroll-ps': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding End\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pe': [{\n 'scroll-pe': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding Top\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pt': [{\n 'scroll-pt': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding Right\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pr': [{\n 'scroll-pr': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding Bottom\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pb': [{\n 'scroll-pb': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Padding Left\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pl': [{\n 'scroll-pl': getSpacingWithArbitrary()\n }],\n /**\n * Scroll Snap Align\n * @see https://tailwindcss.com/docs/scroll-snap-align\n */\n 'snap-align': [{\n snap: ['start', 'end', 'center', 'align-none']\n }],\n /**\n * Scroll Snap Stop\n * @see https://tailwindcss.com/docs/scroll-snap-stop\n */\n 'snap-stop': [{\n snap: ['normal', 'always']\n }],\n /**\n * Scroll Snap Type\n * @see https://tailwindcss.com/docs/scroll-snap-type\n */\n 'snap-type': [{\n snap: ['none', 'x', 'y', 'both']\n }],\n /**\n * Scroll Snap Type Strictness\n * @see https://tailwindcss.com/docs/scroll-snap-type\n */\n 'snap-strictness': [{\n snap: ['mandatory', 'proximity']\n }],\n /**\n * Touch Action\n * @see https://tailwindcss.com/docs/touch-action\n */\n touch: [{\n touch: ['auto', 'none', 'manipulation']\n }],\n /**\n * Touch Action X\n * @see https://tailwindcss.com/docs/touch-action\n */\n 'touch-x': [{\n 'touch-pan': ['x', 'left', 'right']\n }],\n /**\n * Touch Action Y\n * @see https://tailwindcss.com/docs/touch-action\n */\n 'touch-y': [{\n 'touch-pan': ['y', 'up', 'down']\n }],\n /**\n * Touch Action Pinch Zoom\n * @see https://tailwindcss.com/docs/touch-action\n */\n 'touch-pz': ['touch-pinch-zoom'],\n /**\n * User Select\n * @see https://tailwindcss.com/docs/user-select\n */\n select: [{\n select: ['none', 'text', 'all', 'auto']\n }],\n /**\n * Will Change\n * @see https://tailwindcss.com/docs/will-change\n */\n 'will-change': [{\n 'will-change': ['auto', 'scroll', 'contents', 'transform', isArbitraryValue]\n }],\n // SVG\n /**\n * Fill\n * @see https://tailwindcss.com/docs/fill\n */\n fill: [{\n fill: [colors, 'none']\n }],\n /**\n * Stroke Width\n * @see https://tailwindcss.com/docs/stroke-width\n */\n 'stroke-w': [{\n stroke: [isLength, isArbitraryLength, isArbitraryNumber]\n }],\n /**\n * Stroke\n * @see https://tailwindcss.com/docs/stroke\n */\n stroke: [{\n stroke: [colors, 'none']\n }],\n // Accessibility\n /**\n * Screen Readers\n * @see https://tailwindcss.com/docs/screen-readers\n */\n sr: ['sr-only', 'not-sr-only'],\n /**\n * Forced Color Adjust\n * @see https://tailwindcss.com/docs/forced-color-adjust\n */\n 'forced-color-adjust': [{\n 'forced-color-adjust': ['auto', 'none']\n }]\n },\n conflictingClassGroups: {\n overflow: ['overflow-x', 'overflow-y'],\n overscroll: ['overscroll-x', 'overscroll-y'],\n inset: ['inset-x', 'inset-y', 'start', 'end', 'top', 'right', 'bottom', 'left'],\n 'inset-x': ['right', 'left'],\n 'inset-y': ['top', 'bottom'],\n flex: ['basis', 'grow', 'shrink'],\n gap: ['gap-x', 'gap-y'],\n p: ['px', 'py', 'ps', 'pe', 'pt', 'pr', 'pb', 'pl'],\n px: ['pr', 'pl'],\n py: ['pt', 'pb'],\n m: ['mx', 'my', 'ms', 'me', 'mt', 'mr', 'mb', 'ml'],\n mx: ['mr', 'ml'],\n my: ['mt', 'mb'],\n size: ['w', 'h'],\n 'font-size': ['leading'],\n 'fvn-normal': ['fvn-ordinal', 'fvn-slashed-zero', 'fvn-figure', 'fvn-spacing', 'fvn-fraction'],\n 'fvn-ordinal': ['fvn-normal'],\n 'fvn-slashed-zero': ['fvn-normal'],\n 'fvn-figure': ['fvn-normal'],\n 'fvn-spacing': ['fvn-normal'],\n 'fvn-fraction': ['fvn-normal'],\n 'line-clamp': ['display', 'overflow'],\n rounded: ['rounded-s', 'rounded-e', 'rounded-t', 'rounded-r', 'rounded-b', 'rounded-l', 'rounded-ss', 'rounded-se', 'rounded-ee', 'rounded-es', 'rounded-tl', 'rounded-tr', 'rounded-br', 'rounded-bl'],\n 'rounded-s': ['rounded-ss', 'rounded-es'],\n 'rounded-e': ['rounded-se', 'rounded-ee'],\n 'rounded-t': ['rounded-tl', 'rounded-tr'],\n 'rounded-r': ['rounded-tr', 'rounded-br'],\n 'rounded-b': ['rounded-br', 'rounded-bl'],\n 'rounded-l': ['rounded-tl', 'rounded-bl'],\n 'border-spacing': ['border-spacing-x', 'border-spacing-y'],\n 'border-w': ['border-w-s', 'border-w-e', 'border-w-t', 'border-w-r', 'border-w-b', 'border-w-l'],\n 'border-w-x': ['border-w-r', 'border-w-l'],\n 'border-w-y': ['border-w-t', 'border-w-b'],\n 'border-color': ['border-color-s', 'border-color-e', 'border-color-t', 'border-color-r', 'border-color-b', 'border-color-l'],\n 'border-color-x': ['border-color-r', 'border-color-l'],\n 'border-color-y': ['border-color-t', 'border-color-b'],\n 'scroll-m': ['scroll-mx', 'scroll-my', 'scroll-ms', 'scroll-me', 'scroll-mt', 'scroll-mr', 'scroll-mb', 'scroll-ml'],\n 'scroll-mx': ['scroll-mr', 'scroll-ml'],\n 'scroll-my': ['scroll-mt', 'scroll-mb'],\n 'scroll-p': ['scroll-px', 'scroll-py', 'scroll-ps', 'scroll-pe', 'scroll-pt', 'scroll-pr', 'scroll-pb', 'scroll-pl'],\n 'scroll-px': ['scroll-pr', 'scroll-pl'],\n 'scroll-py': ['scroll-pt', 'scroll-pb'],\n touch: ['touch-x', 'touch-y', 'touch-pz'],\n 'touch-x': ['touch'],\n 'touch-y': ['touch'],\n 'touch-pz': ['touch']\n },\n conflictingClassGroupModifiers: {\n 'font-size': ['leading']\n }\n };\n};\n\n/**\n * @param baseConfig Config where other config will be merged into. This object will be mutated.\n * @param configExtension Partial config to merge into the `baseConfig`.\n */\nconst mergeConfigs = (baseConfig, {\n cacheSize,\n prefix,\n separator,\n experimentalParseClassName,\n extend = {},\n override = {}\n}) => {\n overrideProperty(baseConfig, 'cacheSize', cacheSize);\n overrideProperty(baseConfig, 'prefix', prefix);\n overrideProperty(baseConfig, 'separator', separator);\n overrideProperty(baseConfig, 'experimentalParseClassName', experimentalParseClassName);\n for (const configKey in override) {\n overrideConfigProperties(baseConfig[configKey], override[configKey]);\n }\n for (const key in extend) {\n mergeConfigProperties(baseConfig[key], extend[key]);\n }\n return baseConfig;\n};\nconst overrideProperty = (baseObject, overrideKey, overrideValue) => {\n if (overrideValue !== undefined) {\n baseObject[overrideKey] = overrideValue;\n }\n};\nconst overrideConfigProperties = (baseObject, overrideObject) => {\n if (overrideObject) {\n for (const key in overrideObject) {\n overrideProperty(baseObject, key, overrideObject[key]);\n }\n }\n};\nconst mergeConfigProperties = (baseObject, mergeObject) => {\n if (mergeObject) {\n for (const key in mergeObject) {\n const mergeValue = mergeObject[key];\n if (mergeValue !== undefined) {\n baseObject[key] = (baseObject[key] || []).concat(mergeValue);\n }\n }\n }\n};\nconst extendTailwindMerge = (configExtension, ...createConfig) => typeof configExtension === 'function' ? createTailwindMerge(getDefaultConfig, configExtension, ...createConfig) : createTailwindMerge(() => mergeConfigs(getDefaultConfig(), configExtension), ...createConfig);\nconst twMerge = /*#__PURE__*/createTailwindMerge(getDefaultConfig);\nexport { createTailwindMerge, extendTailwindMerge, fromTheme, getDefaultConfig, mergeConfigs, twJoin, twMerge, validators };\n//# sourceMappingURL=bundle-mjs.mjs.map\n","import { type ClassValue, clsx } from 'clsx';\nimport { twMerge } from 'tailwind-merge';\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs));\n}\n","/**\n * Copyright 2022 Joe Bell. All rights reserved.\n *\n * This file is licensed to you under the Apache License, Version 2.0\n * (the \"License\"); you may not use this file except in compliance with the\n * License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR REPRESENTATIONS OF ANY KIND, either express or implied. See the\n * License for the specific language governing permissions and limitations under\n * the License.\n */ import { clsx } from \"clsx\";\nconst falsyToString = (value)=>typeof value === \"boolean\" ? `${value}` : value === 0 ? \"0\" : value;\nexport const cx = clsx;\nexport const cva = (base, config)=>(props)=>{\n var _config_compoundVariants;\n if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);\n const { variants, defaultVariants } = config;\n const getVariantClassNames = Object.keys(variants).map((variant)=>{\n const variantProp = props === null || props === void 0 ? void 0 : props[variant];\n const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];\n if (variantProp === null) return null;\n const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);\n return variants[variant][variantKey];\n });\n const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param)=>{\n let [key, value] = param;\n if (value === undefined) {\n return acc;\n }\n acc[key] = value;\n return acc;\n }, {});\n const getCompoundVariantClassNames = config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param)=>{\n let { class: cvClass, className: cvClassName, ...compoundVariantOptions } = param;\n return Object.entries(compoundVariantOptions).every((param)=>{\n let [key, value] = param;\n return Array.isArray(value) ? value.includes({\n ...defaultVariants,\n ...propsWithoutUndefined\n }[key]) : ({\n ...defaultVariants,\n ...propsWithoutUndefined\n })[key] === value;\n }) ? [\n ...acc,\n cvClass,\n cvClassName\n ] : acc;\n }, []);\n return cx(base, getVariantClassNames, getCompoundVariantClassNames, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);\n };\n\n","import { cn } from \"@/utils/cn\";\nimport { cva, VariantProps } from \"class-variance-authority\";\nimport { ButtonHTMLAttributes, forwardRef } from \"react\";\n\nexport const buttonVariants = cva(\n cn(\n \"inline-flex items-center justify-center gap-2\",\n \"rounded-md ring-offset-white\",\n \"text-sm font-medium\",\n \"focus-visible:outline-none focus-visible:ring-2\",\n \"focus-visible:ring-slate-950 focus-visible:ring-offset-2\",\n \"disabled:pointer-events-none disabled:opacity-60\",\n \"transition-colors cursor-pointer\"\n ),\n {\n variants: {\n variant: {\n default: \"bg-cms-gray-850 text-cms-white hover:bg-cms-gray-750\",\n secondary: cn(\n \"bg-cms-gray-300 text-cms-black\",\n \"hover:bg-cms-gray-200 hover:text-cms-gray-800\"\n ),\n outline: cn(\n \"border border-cms-gray-400 bg-transparent\",\n \"hover:bg-cms-gray-200 hover:text-cms-gray-900\"\n ),\n\n ghost: \"hover:bg-cms-gray-200 hover:text-cms-gray-800\",\n link: \"text-cms-black underline-offset-4 hover:underline\",\n },\n size: {\n default: \"h-10 px-4 py-2\",\n sm: \"h-8 rounded-sm px-3\",\n lg: \"h-11 rounded-sm px-8\",\n icon: \"h-10 w-10\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n size: \"default\",\n },\n }\n);\n\nexport interface ButtonProps\n extends\n ButtonHTMLAttributes<HTMLButtonElement>,\n VariantProps<typeof buttonVariants> {}\n\nconst Button = forwardRef<HTMLButtonElement, ButtonProps>(\n ({ className, variant, size, ...props }, ref) => {\n return (\n <button\n className={cn(buttonVariants({ variant, size, className }))}\n ref={ref}\n {...props}\n />\n );\n }\n);\nButton.displayName = \"Button\";\n\nexport { Button };\n","import { cn } from \"@/utils/cn\";\n\ninterface LoadingCircleProps {\n size?: \"sm\" | \"md\" | \"lg\";\n className?: string;\n}\n\nconst sizeClasses = {\n sm: \"h-4 w-4\",\n md: \"h-8 w-8\",\n lg: \"h-16 w-16\",\n};\n\nexport function LoadingCircle({ size = \"lg\", className }: LoadingCircleProps) {\n return (\n <div className=\"flex items-center justify-center\">\n <div\n className={cn(\n sizeClasses[size],\n \"animate-spin rounded-full\",\n \"border-2 border-cms-gray-500 border-b-transparent\",\n className,\n )}\n />\n </div>\n );\n}\n","import { cn } from \"@/utils/cn\";\nimport { cva, VariantProps } from \"class-variance-authority\";\nimport { useState, useRef, useEffect, forwardRef, KeyboardEvent } from \"react\";\n\nexport const dropdownTriggerVariants = cva(\n cn(\n \"flex items-center justify-between\",\n \"rounded-lg px-4 py-2.5\",\n \"text-sm font-medium\",\n \"outline-none\",\n \"focus:ring-2 focus:ring-offset-2\",\n \"transition-all\"\n ),\n {\n variants: {\n variant: {\n default: cn(\n \"bg-default text-black border border-cms-outline\",\n \"hover:bg-cms-gray-200\"\n ),\n outline: cn(\n \"border border-cms-outline bg-transparent\",\n \"hover:bg-cms-gray-200\"\n ),\n ghost: \"hover:bg-cms-gray-200 hover:text-black\",\n },\n size: {\n sm: \"px-3 py-2 text-xs\",\n default: \"px-4 py-2.5 text-sm\",\n lg: \"px-6 py-3 text-base\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n size: \"default\",\n },\n }\n);\n\nexport interface DropdownOption {\n value: string;\n label: string;\n disabled?: boolean;\n}\n\nexport interface DropdownProps extends VariantProps<\n typeof dropdownTriggerVariants\n> {\n options: DropdownOption[];\n value?: string;\n placeholder?: string;\n onValueChange?: (value: string) => void;\n disabled?: boolean;\n className?: string;\n dropdownClassName?: string;\n searchable?: boolean;\n clearable?: boolean;\n multiple?: boolean;\n maxHeight?: number;\n}\n\nconst ChevronDownIcon = ({\n className,\n isOpen,\n}: {\n className?: string;\n isOpen: boolean;\n}) => (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"10\"\n height=\"6\"\n viewBox=\"0 0 10 6\"\n fill=\"none\"\n className={cn(\n \"transition-transform duration-200\",\n isOpen && \"rotate-180\",\n className\n )}\n >\n <path\n d=\"M8.75 0.75L4.57609 4.75L0.75 0.75\"\n stroke=\"currentColor\"\n strokeWidth=\"1.5\"\n strokeLinecap=\"round\"\n />\n </svg>\n);\n\nconst ClearIcon = ({ className }: { className?: string }) => (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 12 12\"\n fill=\"none\"\n className={className}\n >\n <path\n d=\"M9 3L3 9M3 3L9 9\"\n stroke=\"currentColor\"\n strokeWidth=\"1.5\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n />\n </svg>\n);\n\nexport const Dropdown = forwardRef<HTMLButtonElement, DropdownProps>(\n (\n {\n options,\n value,\n placeholder = \"선택하세요\",\n onValueChange,\n disabled = false,\n className,\n dropdownClassName,\n variant,\n size,\n searchable = false,\n clearable = false,\n multiple = false,\n maxHeight = 200,\n ...props\n },\n ref\n ) => {\n const [isOpen, setIsOpen] = useState(false);\n const [searchTerm, setSearchTerm] = useState(\"\");\n const [selectedValues, setSelectedValues] = useState<string[]>(\n multiple ? (value ? [value] : []) : []\n );\n\n const dropdownRef = useRef<HTMLDivElement>(null);\n const searchInputRef = useRef<HTMLInputElement>(null);\n\n const selectedOption = options.find((option) => option.value === value);\n const selectedLabel = multiple\n ? selectedValues.length > 0\n ? `${selectedValues.length}개 선택됨`\n : placeholder\n : selectedOption?.label || placeholder;\n\n const filteredOptions = options.filter((option) =>\n option.label.toLowerCase().includes(searchTerm.toLowerCase())\n );\n\n const handleToggle = () => {\n if (!disabled) {\n setIsOpen(!isOpen);\n setSearchTerm(\"\");\n }\n };\n\n const handleOptionClick = (option: DropdownOption) => {\n if (option.disabled) return;\n\n if (multiple) {\n const newSelectedValues = selectedValues.includes(option.value)\n ? selectedValues.filter((v) => v !== option.value)\n : [...selectedValues, option.value];\n\n setSelectedValues(newSelectedValues);\n onValueChange?.(newSelectedValues.join(\",\"));\n } else {\n onValueChange?.(option.value);\n setIsOpen(false);\n }\n };\n\n const handleClear = (e: React.MouseEvent) => {\n e.stopPropagation();\n if (multiple) {\n setSelectedValues([]);\n onValueChange?.(\"\");\n } else {\n onValueChange?.(\"\");\n }\n };\n\n const handleKeyDown = (e: KeyboardEvent) => {\n if (e.key === \"Escape\") {\n setIsOpen(false);\n } else if (e.key === \"Enter\" || e.key === \" \") {\n e.preventDefault();\n handleToggle();\n }\n };\n\n // 외부 클릭 감지\n useEffect(() => {\n const handleClickOutside = (event: MouseEvent) => {\n if (\n dropdownRef.current &&\n !dropdownRef.current.contains(event.target as Node)\n ) {\n setIsOpen(false);\n }\n };\n\n document.addEventListener(\"mousedown\", handleClickOutside);\n return () =>\n document.removeEventListener(\"mousedown\", handleClickOutside);\n }, []);\n\n // 드롭다운이 열릴 때 검색 입력창에 포커스\n useEffect(() => {\n if (isOpen && searchable && searchInputRef.current) {\n searchInputRef.current.focus();\n }\n }, [isOpen, searchable]);\n\n return (\n <div ref={dropdownRef} className=\"relative w-full\">\n <button\n ref={ref}\n type=\"button\"\n className={cn(\n dropdownTriggerVariants({ variant, size }),\n disabled && \"opacity-50 cursor-not-allowed\",\n className\n )}\n onClick={handleToggle}\n onKeyDown={handleKeyDown}\n disabled={disabled}\n aria-expanded={isOpen}\n aria-haspopup=\"listbox\"\n {...props}\n >\n <span\n className={cn(\n \"truncate flex-1 text-left\",\n !selectedOption && !multiple && \"text-cms-gray-400\"\n )}\n >\n {selectedLabel}\n </span>\n\n <div className=\"flex items-center gap-2 ml-3\">\n {clearable && (value || selectedValues.length > 0) && (\n <button\n type=\"button\"\n className={cn(\n \"p-1 rounded text-cms-gray-400 transition-colors\",\n \"hover:text-cms-black\"\n )}\n onClick={handleClear}\n aria-label=\"선택 취소\"\n >\n <ClearIcon className=\"w-3 h-3\" />\n </button>\n )}\n <ChevronDownIcon\n isOpen={isOpen}\n className=\"w-4 h-4 text-cms-gray-400\"\n />\n </div>\n </button>\n\n {isOpen && (\n <div\n className={cn(\n \"absolute z-50 mt-1 py-1 w-full\",\n \"rounded-lg border border-cms-gray-400\",\n \"bg-white shadow-lg\",\n dropdownClassName\n )}\n style={{ maxHeight: `${maxHeight}px` }}\n >\n {searchable && (\n <div className=\"px-3 py-2 border-b border-cms-gray-400\">\n <input\n ref={searchInputRef}\n type=\"text\"\n value={searchTerm}\n onChange={(e) => setSearchTerm(e.target.value)}\n placeholder=\"검색...\"\n className={cn(\n \"w-full px-2 py-1 text-sm\",\n \"rounded outline-none\",\n \"border border-cms-gray-400\",\n \"focus:ring-1 focus:ring-cms-black\"\n )}\n />\n </div>\n )}\n\n <div className=\"max-h-48 overflow-y-auto\">\n {filteredOptions.length === 0 ? (\n <div className=\"px-3 py-2 text-sm text-cms-gray-400 text-center\">\n {searchTerm ? \"검색 결과가 없습니다\" : \"옵션이 없습니다\"}\n </div>\n ) : (\n filteredOptions.map((option) => {\n const isSelected = multiple\n ? selectedValues.includes(option.value)\n : value === option.value;\n\n return (\n <button\n key={option.value}\n type=\"button\"\n className={cn(\n \"flex items-center justify-between gap-2\",\n \"w-full px-3 py-2 \",\n \"text-left text-sm\",\n \"transition-colors\",\n option.disabled\n ? \"text-cms-gray-400 cursor-not-allowed\"\n : \"text-cms-black hover:bg-cms-gray-200 cursor-pointer\",\n isSelected && \"bg-cms-gray-400 font-medium\"\n )}\n onClick={() => handleOptionClick(option)}\n disabled={option.disabled}\n >\n <span className=\"truncate\">{option.label}</span>\n {isSelected && (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n className=\"w-4 h-4 text-black shrink-0\"\n >\n <path\n d=\"M13.5 4.5L6 12L2.5 8.5\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n />\n </svg>\n )}\n </button>\n );\n })\n )}\n </div>\n </div>\n )}\n </div>\n );\n }\n);\n\nDropdown.displayName = \"Dropdown\";\n","import { cn } from \"@/utils/cn\";\nimport { forwardRef } from \"react\";\nimport { Dropdown, DropdownProps } from \"./Dropdown\";\n\nexport interface SelectProps extends Omit<\n DropdownProps,\n \"multiple\" | \"searchable\" | \"clearable\"\n> {\n label?: string;\n helperText?: string;\n error?: string;\n required?: boolean;\n}\n\nexport const Select = forwardRef<HTMLButtonElement, SelectProps>(\n ({ label, helperText, error, required, className, ...props }, ref) => {\n return (\n <div className={cn(\"space-y-1\", className)}>\n {label && (\n <label className=\"block text-sm font-medium text-cms-black\">\n {label}\n {required && <span className=\"text-cms-red-500 ml-1\">*</span>}\n </label>\n )}\n\n <Dropdown\n ref={ref}\n {...props}\n className={cn(error && \"border-cms-red-500 focus:ring-cms-red-500\")}\n />\n\n {(helperText || error) && (\n <p\n className={cn(\n \"text-xs\",\n error ? \"text-cms-red-500\" : \"text-cms-gray-400\",\n )}\n >\n {error || helperText}\n </p>\n )}\n </div>\n );\n },\n);\n\nSelect.displayName = \"Select\";\n","import { cn } from \"@/utils/cn\";\nimport { useState, forwardRef } from \"react\";\nimport { Dropdown, DropdownProps } from \"./Dropdown\";\n\nexport interface ComboboxProps extends Omit<DropdownProps, \"searchable\"> {\n loading?: boolean;\n createable?: boolean;\n onCreateOption?: (value: string) => void;\n}\n\nexport const Combobox = forwardRef<HTMLButtonElement, ComboboxProps>(\n (\n { options, loading = false, createable = false, onCreateOption, ...props },\n ref,\n ) => {\n const [searchTerm] = useState(\"\");\n\n const filteredOptions = options.filter((option) =>\n option.label.toLowerCase().includes(searchTerm.toLowerCase()),\n );\n\n const hasExactMatch = filteredOptions.some(\n (option) => option.label.toLowerCase() === searchTerm.toLowerCase(),\n );\n\n // 검색어가 있고 createable이며 정확히 일치하는 옵션이 없을 때 생성 옵션 추가\n const optionsWithCreate = [\n ...filteredOptions,\n ...(createable && searchTerm && !hasExactMatch\n ? [\n {\n value: `__create__${searchTerm}`,\n label: `\"${searchTerm}\" 생성`,\n disabled: false,\n },\n ]\n : []),\n ];\n\n return (\n <Dropdown\n ref={ref}\n {...props}\n options={optionsWithCreate}\n searchable={true}\n dropdownClassName={cn(loading && \"opacity-75\", props.dropdownClassName)}\n onValueChange={(value) => {\n if (value.startsWith(\"__create__\")) {\n const createValue = value.replace(\"__create__\", \"\");\n onCreateOption?.(createValue);\n } else {\n props.onValueChange?.(value);\n }\n }}\n />\n );\n },\n);\n\nCombobox.displayName = \"Combobox\";\n","import type { SVGProps } from 'react';\n\nexport function ChevronRightIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"20\"\n height=\"20\"\n viewBox=\"0 0 20 20\"\n fill=\"none\"\n {...props}\n >\n <path\n d=\"M7 5L12 10L7 15\"\n stroke=\"black\"\n strokeWidth=\"1.5\"\n strokeLinecap=\"round\"\n />\n </svg>\n );\n}\n","// src/primitive.tsx\nvar canUseDOM = !!(typeof window !== \"undefined\" && window.document && window.document.createElement);\nfunction composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {\n return function handleEvent(event) {\n originalEventHandler?.(event);\n if (checkForDefaultPrevented === false || !event.defaultPrevented) {\n return ourEventHandler?.(event);\n }\n };\n}\nfunction getOwnerWindow(element) {\n if (!canUseDOM) {\n throw new Error(\"Cannot access window outside of the DOM\");\n }\n return element?.ownerDocument?.defaultView ?? window;\n}\nfunction getOwnerDocument(element) {\n if (!canUseDOM) {\n throw new Error(\"Cannot access document outside of the DOM\");\n }\n return element?.ownerDocument ?? document;\n}\nfunction getActiveElement(node, activeDescendant = false) {\n const { activeElement } = getOwnerDocument(node);\n if (!activeElement?.nodeName) {\n return null;\n }\n if (isFrame(activeElement) && activeElement.contentDocument) {\n return getActiveElement(activeElement.contentDocument.body, activeDescendant);\n }\n if (activeDescendant) {\n const id = activeElement.getAttribute(\"aria-activedescendant\");\n if (id) {\n const element = getOwnerDocument(activeElement).getElementById(id);\n if (element) {\n return element;\n }\n }\n }\n return activeElement;\n}\nfunction isFrame(element) {\n return element.tagName === \"IFRAME\";\n}\nexport {\n canUseDOM,\n composeEventHandlers,\n getActiveElement,\n getOwnerDocument,\n getOwnerWindow,\n isFrame\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/compose-refs/src/compose-refs.tsx\nimport * as React from \"react\";\nfunction setRef(ref, value) {\n if (typeof ref === \"function\") {\n return ref(value);\n } else if (ref !== null && ref !== void 0) {\n ref.current = value;\n }\n}\nfunction composeRefs(...refs) {\n return (node) => {\n let hasCleanup = false;\n const cleanups = refs.map((ref) => {\n const cleanup = setRef(ref, node);\n if (!hasCleanup && typeof cleanup == \"function\") {\n hasCleanup = true;\n }\n return cleanup;\n });\n if (hasCleanup) {\n return () => {\n for (let i = 0; i < cleanups.length; i++) {\n const cleanup = cleanups[i];\n if (typeof cleanup == \"function\") {\n cleanup();\n } else {\n setRef(refs[i], null);\n }\n }\n };\n }\n };\n}\nfunction useComposedRefs(...refs) {\n return React.useCallback(composeRefs(...refs), refs);\n}\nexport {\n composeRefs,\n useComposedRefs\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/context/src/create-context.tsx\nimport * as React from \"react\";\nimport { jsx } from \"react/jsx-runtime\";\nfunction createContext2(rootComponentName, defaultContext) {\n const Context = React.createContext(defaultContext);\n const Provider = (props) => {\n const { children, ...context } = props;\n const value = React.useMemo(() => context, Object.values(context));\n return /* @__PURE__ */ jsx(Context.Provider, { value, children });\n };\n Provider.displayName = rootComponentName + \"Provider\";\n function useContext2(consumerName) {\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== void 0) return defaultContext;\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n return [Provider, useContext2];\n}\nfunction createContextScope(scopeName, createContextScopeDeps = []) {\n let defaultContexts = [];\n function createContext3(rootComponentName, defaultContext) {\n const BaseContext = React.createContext(defaultContext);\n const index = defaultContexts.length;\n defaultContexts = [...defaultContexts, defaultContext];\n const Provider = (props) => {\n const { scope, children, ...context } = props;\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n const value = React.useMemo(() => context, Object.values(context));\n return /* @__PURE__ */ jsx(Context.Provider, { value, children });\n };\n Provider.displayName = rootComponentName + \"Provider\";\n function useContext2(consumerName, scope) {\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== void 0) return defaultContext;\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n return [Provider, useContext2];\n }\n const createScope = () => {\n const scopeContexts = defaultContexts.map((defaultContext) => {\n return React.createContext(defaultContext);\n });\n return function useScope(scope) {\n const contexts = scope?.[scopeName] || scopeContexts;\n return React.useMemo(\n () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),\n [scope, contexts]\n );\n };\n };\n createScope.scopeName = scopeName;\n return [createContext3, composeContextScopes(createScope, ...createContextScopeDeps)];\n}\nfunction composeContextScopes(...scopes) {\n const baseScope = scopes[0];\n if (scopes.length === 1) return baseScope;\n const createScope = () => {\n const scopeHooks = scopes.map((createScope2) => ({\n useScope: createScope2(),\n scopeName: createScope2.scopeName\n }));\n return function useComposedScopes(overrideScopes) {\n const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {\n const scopeProps = useScope(overrideScopes);\n const currentScope = scopeProps[`__scope${scopeName}`];\n return { ...nextScopes2, ...currentScope };\n }, {});\n return React.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);\n };\n };\n createScope.scopeName = baseScope.scopeName;\n return createScope;\n}\nexport {\n createContext2 as createContext,\n createContextScope\n};\n//# sourceMappingURL=index.mjs.map\n","// src/slot.tsx\nimport * as React from \"react\";\nimport { composeRefs } from \"@radix-ui/react-compose-refs\";\nimport { Fragment as Fragment2, jsx } from \"react/jsx-runtime\";\n// @__NO_SIDE_EFFECTS__\nfunction createSlot(ownerName) {\n const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);\n const Slot2 = React.forwardRef((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n const childrenArray = React.Children.toArray(children);\n const slottable = childrenArray.find(isSlottable);\n if (slottable) {\n const newElement = slottable.props.children;\n const newChildren = childrenArray.map((child) => {\n if (child === slottable) {\n if (React.Children.count(newElement) > 1) return React.Children.only(null);\n return React.isValidElement(newElement) ? newElement.props.children : null;\n } else {\n return child;\n }\n });\n return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });\n }\n return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });\n });\n Slot2.displayName = `${ownerName}.Slot`;\n return Slot2;\n}\nvar Slot = /* @__PURE__ */ createSlot(\"Slot\");\n// @__NO_SIDE_EFFECTS__\nfunction createSlotClone(ownerName) {\n const SlotClone = React.forwardRef((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n if (React.isValidElement(children)) {\n const childrenRef = getElementRef(children);\n const props2 = mergeProps(slotProps, children.props);\n if (children.type !== React.Fragment) {\n props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;\n }\n return React.cloneElement(children, props2);\n }\n return React.Children.count(children) > 1 ? React.Children.only(null) : null;\n });\n SlotClone.displayName = `${ownerName}.SlotClone`;\n return SlotClone;\n}\nvar SLOTTABLE_IDENTIFIER = Symbol(\"radix.slottable\");\n// @__NO_SIDE_EFFECTS__\nfunction createSlottable(ownerName) {\n const Slottable2 = ({ children }) => {\n return /* @__PURE__ */ jsx(Fragment2, { children });\n };\n Slottable2.displayName = `${ownerName}.Slottable`;\n Slottable2.__radixId = SLOTTABLE_IDENTIFIER;\n return Slottable2;\n}\nvar Slottable = /* @__PURE__ */ createSlottable(\"Slottable\");\nfunction isSlottable(child) {\n return React.isValidElement(child) && typeof child.type === \"function\" && \"__radixId\" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;\n}\nfunction mergeProps(slotProps, childProps) {\n const overrideProps = { ...childProps };\n for (const propName in childProps) {\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n if (slotPropValue && childPropValue) {\n overrideProps[propName] = (...args) => {\n const result = childPropValue(...args);\n slotPropValue(...args);\n return result;\n };\n } else if (slotPropValue) {\n overrideProps[propName] = slotPropValue;\n }\n } else if (propName === \"style\") {\n overrideProps[propName] = { ...slotPropValue, ...childPropValue };\n } else if (propName === \"className\") {\n overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(\" \");\n }\n }\n return { ...slotProps, ...overrideProps };\n}\nfunction getElementRef(element) {\n let getter = Object.getOwnPropertyDescriptor(element.props, \"ref\")?.get;\n let mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.ref;\n }\n getter = Object.getOwnPropertyDescriptor(element, \"ref\")?.get;\n mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.props.ref;\n }\n return element.props.ref || element.ref;\n}\nexport {\n Slot as Root,\n Slot,\n Slottable,\n createSlot,\n createSlottable\n};\n//# sourceMappingURL=index.mjs.map\n","// src/primitive.tsx\nimport * as React from \"react\";\nimport * as ReactDOM from \"react-dom\";\nimport { createSlot } from \"@radix-ui/react-slot\";\nimport { jsx } from \"react/jsx-runtime\";\nvar NODES = [\n \"a\",\n \"button\",\n \"div\",\n \"form\",\n \"h2\",\n \"h3\",\n \"img\",\n \"input\",\n \"label\",\n \"li\",\n \"nav\",\n \"ol\",\n \"p\",\n \"select\",\n \"span\",\n \"svg\",\n \"ul\"\n];\nvar Primitive = NODES.reduce((primitive, node) => {\n const Slot = createSlot(`Primitive.${node}`);\n const Node = React.forwardRef((props, forwardedRef) => {\n const { asChild, ...primitiveProps } = props;\n const Comp = asChild ? Slot : node;\n if (typeof window !== \"undefined\") {\n window[Symbol.for(\"radix-ui\")] = true;\n }\n return /* @__PURE__ */ jsx(Comp, { ...primitiveProps, ref: forwardedRef });\n });\n Node.displayName = `Primitive.${node}`;\n return { ...primitive, [node]: Node };\n}, {});\nfunction dispatchDiscreteCustomEvent(target, event) {\n if (target) ReactDOM.flushSync(() => target.dispatchEvent(event));\n}\nvar Root = Primitive;\nexport {\n Primitive,\n Root,\n dispatchDiscreteCustomEvent\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/use-callback-ref/src/use-callback-ref.tsx\nimport * as React from \"react\";\nfunction useCallbackRef(callback) {\n const callbackRef = React.useRef(callback);\n React.useEffect(() => {\n callbackRef.current = callback;\n });\n return React.useMemo(() => (...args) => callbackRef.current?.(...args), []);\n}\nexport {\n useCallbackRef\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/use-escape-keydown/src/use-escape-keydown.tsx\nimport * as React from \"react\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nfunction useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis?.document) {\n const onEscapeKeyDown = useCallbackRef(onEscapeKeyDownProp);\n React.useEffect(() => {\n const handleKeyDown = (event) => {\n if (event.key === \"Escape\") {\n onEscapeKeyDown(event);\n }\n };\n ownerDocument.addEventListener(\"keydown\", handleKeyDown, { capture: true });\n return () => ownerDocument.removeEventListener(\"keydown\", handleKeyDown, { capture: true });\n }, [onEscapeKeyDown, ownerDocument]);\n}\nexport {\n useEscapeKeydown\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/dismissable-layer.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { Primitive, dispatchDiscreteCustomEvent } from \"@radix-ui/react-primitive\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { useEscapeKeydown } from \"@radix-ui/react-use-escape-keydown\";\nimport { jsx } from \"react/jsx-runtime\";\nvar DISMISSABLE_LAYER_NAME = \"DismissableLayer\";\nvar CONTEXT_UPDATE = \"dismissableLayer.update\";\nvar POINTER_DOWN_OUTSIDE = \"dismissableLayer.pointerDownOutside\";\nvar FOCUS_OUTSIDE = \"dismissableLayer.focusOutside\";\nvar originalBodyPointerEvents;\nvar DismissableLayerContext = React.createContext({\n layers: /* @__PURE__ */ new Set(),\n layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),\n branches: /* @__PURE__ */ new Set()\n});\nvar DismissableLayer = React.forwardRef(\n (props, forwardedRef) => {\n const {\n disableOutsidePointerEvents = false,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n onDismiss,\n ...layerProps\n } = props;\n const context = React.useContext(DismissableLayerContext);\n const [node, setNode] = React.useState(null);\n const ownerDocument = node?.ownerDocument ?? globalThis?.document;\n const [, force] = React.useState({});\n const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));\n const layers = Array.from(context.layers);\n const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);\n const highestLayerWithOutsidePointerEventsDisabledIndex = layers.indexOf(highestLayerWithOutsidePointerEventsDisabled);\n const index = node ? layers.indexOf(node) : -1;\n const isBodyPointerEventsDisabled = context.layersWithOutsidePointerEventsDisabled.size > 0;\n const isPointerEventsEnabled = index >= highestLayerWithOutsidePointerEventsDisabledIndex;\n const pointerDownOutside = usePointerDownOutside((event) => {\n const target = event.target;\n const isPointerDownOnBranch = [...context.branches].some((branch) => branch.contains(target));\n if (!isPointerEventsEnabled || isPointerDownOnBranch) return;\n onPointerDownOutside?.(event);\n onInteractOutside?.(event);\n if (!event.defaultPrevented) onDismiss?.();\n }, ownerDocument);\n const focusOutside = useFocusOutside((event) => {\n const target = event.target;\n const isFocusInBranch = [...context.branches].some((branch) => branch.contains(target));\n if (isFocusInBranch) return;\n onFocusOutside?.(event);\n onInteractOutside?.(event);\n if (!event.defaultPrevented) onDismiss?.();\n }, ownerDocument);\n useEscapeKeydown((event) => {\n const isHighestLayer = index === context.layers.size - 1;\n if (!isHighestLayer) return;\n onEscapeKeyDown?.(event);\n if (!event.defaultPrevented && onDismiss) {\n event.preventDefault();\n onDismiss();\n }\n }, ownerDocument);\n React.useEffect(() => {\n if (!node) return;\n if (disableOutsidePointerEvents) {\n if (context.layersWithOutsidePointerEventsDisabled.size === 0) {\n originalBodyPointerEvents = ownerDocument.body.style.pointerEvents;\n ownerDocument.body.style.pointerEvents = \"none\";\n }\n context.layersWithOutsidePointerEventsDisabled.add(node);\n }\n context.layers.add(node);\n dispatchUpdate();\n return () => {\n if (disableOutsidePointerEvents && context.layersWithOutsidePointerEventsDisabled.size === 1) {\n ownerDocument.body.style.pointerEvents = originalBodyPointerEvents;\n }\n };\n }, [node, ownerDocument, disableOutsidePointerEvents, context]);\n React.useEffect(() => {\n return () => {\n if (!node) return;\n context.layers.delete(node);\n context.layersWithOutsidePointerEventsDisabled.delete(node);\n dispatchUpdate();\n };\n }, [node, context]);\n React.useEffect(() => {\n const handleUpdate = () => force({});\n document.addEventListener(CONTEXT_UPDATE, handleUpdate);\n return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);\n }, []);\n return /* @__PURE__ */ jsx(\n Primitive.div,\n {\n ...layerProps,\n ref: composedRefs,\n style: {\n pointerEvents: isBodyPointerEventsDisabled ? isPointerEventsEnabled ? \"auto\" : \"none\" : void 0,\n ...props.style\n },\n onFocusCapture: composeEventHandlers(props.onFocusCapture, focusOutside.onFocusCapture),\n onBlurCapture: composeEventHandlers(props.onBlurCapture, focusOutside.onBlurCapture),\n onPointerDownCapture: composeEventHandlers(\n props.onPointerDownCapture,\n pointerDownOutside.onPointerDownCapture\n )\n }\n );\n }\n);\nDismissableLayer.displayName = DISMISSABLE_LAYER_NAME;\nvar BRANCH_NAME = \"DismissableLayerBranch\";\nvar DismissableLayerBranch = React.forwardRef((props, forwardedRef) => {\n const context = React.useContext(DismissableLayerContext);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n React.useEffect(() => {\n const node = ref.current;\n if (node) {\n context.branches.add(node);\n return () => {\n context.branches.delete(node);\n };\n }\n }, [context.branches]);\n return /* @__PURE__ */ jsx(Primitive.div, { ...props, ref: composedRefs });\n});\nDismissableLayerBranch.displayName = BRANCH_NAME;\nfunction usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis?.document) {\n const handlePointerDownOutside = useCallbackRef(onPointerDownOutside);\n const isPointerInsideReactTreeRef = React.useRef(false);\n const handleClickRef = React.useRef(() => {\n });\n React.useEffect(() => {\n const handlePointerDown = (event) => {\n if (event.target && !isPointerInsideReactTreeRef.current) {\n let handleAndDispatchPointerDownOutsideEvent2 = function() {\n handleAndDispatchCustomEvent(\n POINTER_DOWN_OUTSIDE,\n handlePointerDownOutside,\n eventDetail,\n { discrete: true }\n );\n };\n var handleAndDispatchPointerDownOutsideEvent = handleAndDispatchPointerDownOutsideEvent2;\n const eventDetail = { originalEvent: event };\n if (event.pointerType === \"touch\") {\n ownerDocument.removeEventListener(\"click\", handleClickRef.current);\n handleClickRef.current = handleAndDispatchPointerDownOutsideEvent2;\n ownerDocument.addEventListener(\"click\", handleClickRef.current, { once: true });\n } else {\n handleAndDispatchPointerDownOutsideEvent2();\n }\n } else {\n ownerDocument.removeEventListener(\"click\", handleClickRef.current);\n }\n isPointerInsideReactTreeRef.current = false;\n };\n const timerId = window.setTimeout(() => {\n ownerDocument.addEventListener(\"pointerdown\", handlePointerDown);\n }, 0);\n return () => {\n window.clearTimeout(timerId);\n ownerDocument.removeEventListener(\"pointerdown\", handlePointerDown);\n ownerDocument.removeEventListener(\"click\", handleClickRef.current);\n };\n }, [ownerDocument, handlePointerDownOutside]);\n return {\n // ensures we check React component tree (not just DOM tree)\n onPointerDownCapture: () => isPointerInsideReactTreeRef.current = true\n };\n}\nfunction useFocusOutside(onFocusOutside, ownerDocument = globalThis?.document) {\n const handleFocusOutside = useCallbackRef(onFocusOutside);\n const isFocusInsideReactTreeRef = React.useRef(false);\n React.useEffect(() => {\n const handleFocus = (event) => {\n if (event.target && !isFocusInsideReactTreeRef.current) {\n const eventDetail = { originalEvent: event };\n handleAndDispatchCustomEvent(FOCUS_OUTSIDE, handleFocusOutside, eventDetail, {\n discrete: false\n });\n }\n };\n ownerDocument.addEventListener(\"focusin\", handleFocus);\n return () => ownerDocument.removeEventListener(\"focusin\", handleFocus);\n }, [ownerDocument, handleFocusOutside]);\n return {\n onFocusCapture: () => isFocusInsideReactTreeRef.current = true,\n onBlurCapture: () => isFocusInsideReactTreeRef.current = false\n };\n}\nfunction dispatchUpdate() {\n const event = new CustomEvent(CONTEXT_UPDATE);\n document.dispatchEvent(event);\n}\nfunction handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {\n const target = detail.originalEvent.target;\n const event = new CustomEvent(name, { bubbles: false, cancelable: true, detail });\n if (handler) target.addEventListener(name, handler, { once: true });\n if (discrete) {\n dispatchDiscreteCustomEvent(target, event);\n } else {\n target.dispatchEvent(event);\n }\n}\nvar Root = DismissableLayer;\nvar Branch = DismissableLayerBranch;\nexport {\n Branch,\n DismissableLayer,\n DismissableLayerBranch,\n Root\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/focus-guards.tsx\nimport * as React from \"react\";\nvar count = 0;\nfunction FocusGuards(props) {\n useFocusGuards();\n return props.children;\n}\nfunction useFocusGuards() {\n React.useEffect(() => {\n const edgeGuards = document.querySelectorAll(\"[data-radix-focus-guard]\");\n document.body.insertAdjacentElement(\"afterbegin\", edgeGuards[0] ?? createFocusGuard());\n document.body.insertAdjacentElement(\"beforeend\", edgeGuards[1] ?? createFocusGuard());\n count++;\n return () => {\n if (count === 1) {\n document.querySelectorAll(\"[data-radix-focus-guard]\").forEach((node) => node.remove());\n }\n count--;\n };\n }, []);\n}\nfunction createFocusGuard() {\n const element = document.createElement(\"span\");\n element.setAttribute(\"data-radix-focus-guard\", \"\");\n element.tabIndex = 0;\n element.style.outline = \"none\";\n element.style.opacity = \"0\";\n element.style.position = \"fixed\";\n element.style.pointerEvents = \"none\";\n return element;\n}\nexport {\n FocusGuards,\n FocusGuards as Root,\n useFocusGuards\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/focus-scope.tsx\nimport * as React from \"react\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { jsx } from \"react/jsx-runtime\";\nvar AUTOFOCUS_ON_MOUNT = \"focusScope.autoFocusOnMount\";\nvar AUTOFOCUS_ON_UNMOUNT = \"focusScope.autoFocusOnUnmount\";\nvar EVENT_OPTIONS = { bubbles: false, cancelable: true };\nvar FOCUS_SCOPE_NAME = \"FocusScope\";\nvar FocusScope = React.forwardRef((props, forwardedRef) => {\n const {\n loop = false,\n trapped = false,\n onMountAutoFocus: onMountAutoFocusProp,\n onUnmountAutoFocus: onUnmountAutoFocusProp,\n ...scopeProps\n } = props;\n const [container, setContainer] = React.useState(null);\n const onMountAutoFocus = useCallbackRef(onMountAutoFocusProp);\n const onUnmountAutoFocus = useCallbackRef(onUnmountAutoFocusProp);\n const lastFocusedElementRef = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, (node) => setContainer(node));\n const focusScope = React.useRef({\n paused: false,\n pause() {\n this.paused = true;\n },\n resume() {\n this.paused = false;\n }\n }).current;\n React.useEffect(() => {\n if (trapped) {\n let handleFocusIn2 = function(event) {\n if (focusScope.paused || !container) return;\n const target = event.target;\n if (container.contains(target)) {\n lastFocusedElementRef.current = target;\n } else {\n focus(lastFocusedElementRef.current, { select: true });\n }\n }, handleFocusOut2 = function(event) {\n if (focusScope.paused || !container) return;\n const relatedTarget = event.relatedTarget;\n if (relatedTarget === null) return;\n if (!container.contains(relatedTarget)) {\n focus(lastFocusedElementRef.current, { select: true });\n }\n }, handleMutations2 = function(mutations) {\n const focusedElement = document.activeElement;\n if (focusedElement !== document.body) return;\n for (const mutation of mutations) {\n if (mutation.removedNodes.length > 0) focus(container);\n }\n };\n var handleFocusIn = handleFocusIn2, handleFocusOut = handleFocusOut2, handleMutations = handleMutations2;\n document.addEventListener(\"focusin\", handleFocusIn2);\n document.addEventListener(\"focusout\", handleFocusOut2);\n const mutationObserver = new MutationObserver(handleMutations2);\n if (container) mutationObserver.observe(container, { childList: true, subtree: true });\n return () => {\n document.removeEventListener(\"focusin\", handleFocusIn2);\n document.removeEventListener(\"focusout\", handleFocusOut2);\n mutationObserver.disconnect();\n };\n }\n }, [trapped, container, focusScope.paused]);\n React.useEffect(() => {\n if (container) {\n focusScopesStack.add(focusScope);\n const previouslyFocusedElement = document.activeElement;\n const hasFocusedCandidate = container.contains(previouslyFocusedElement);\n if (!hasFocusedCandidate) {\n const mountEvent = new CustomEvent(AUTOFOCUS_ON_MOUNT, EVENT_OPTIONS);\n container.addEventListener(AUTOFOCUS_ON_MOUNT, onMountAutoFocus);\n container.dispatchEvent(mountEvent);\n if (!mountEvent.defaultPrevented) {\n focusFirst(removeLinks(getTabbableCandidates(container)), { select: true });\n if (document.activeElement === previouslyFocusedElement) {\n focus(container);\n }\n }\n }\n return () => {\n container.removeEventListener(AUTOFOCUS_ON_MOUNT, onMountAutoFocus);\n setTimeout(() => {\n const unmountEvent = new CustomEvent(AUTOFOCUS_ON_UNMOUNT, EVENT_OPTIONS);\n container.addEventListener(AUTOFOCUS_ON_UNMOUNT, onUnmountAutoFocus);\n container.dispatchEvent(unmountEvent);\n if (!unmountEvent.defaultPrevented) {\n focus(previouslyFocusedElement ?? document.body, { select: true });\n }\n container.removeEventListener(AUTOFOCUS_ON_UNMOUNT, onUnmountAutoFocus);\n focusScopesStack.remove(focusScope);\n }, 0);\n };\n }\n }, [container, onMountAutoFocus, onUnmountAutoFocus, focusScope]);\n const handleKeyDown = React.useCallback(\n (event) => {\n if (!loop && !trapped) return;\n if (focusScope.paused) return;\n const isTabKey = event.key === \"Tab\" && !event.altKey && !event.ctrlKey && !event.metaKey;\n const focusedElement = document.activeElement;\n if (isTabKey && focusedElement) {\n const container2 = event.currentTarget;\n const [first, last] = getTabbableEdges(container2);\n const hasTabbableElementsInside = first && last;\n if (!hasTabbableElementsInside) {\n if (focusedElement === container2) event.preventDefault();\n } else {\n if (!event.shiftKey && focusedElement === last) {\n event.preventDefault();\n if (loop) focus(first, { select: true });\n } else if (event.shiftKey && focusedElement === first) {\n event.preventDefault();\n if (loop) focus(last, { select: true });\n }\n }\n }\n },\n [loop, trapped, focusScope.paused]\n );\n return /* @__PURE__ */ jsx(Primitive.div, { tabIndex: -1, ...scopeProps, ref: composedRefs, onKeyDown: handleKeyDown });\n});\nFocusScope.displayName = FOCUS_SCOPE_NAME;\nfunction focusFirst(candidates, { select = false } = {}) {\n const previouslyFocusedElement = document.activeElement;\n for (const candidate of candidates) {\n focus(candidate, { select });\n if (document.activeElement !== previouslyFocusedElement) return;\n }\n}\nfunction getTabbableEdges(container) {\n const candidates = getTabbableCandidates(container);\n const first = findVisible(candidates, container);\n const last = findVisible(candidates.reverse(), container);\n return [first, last];\n}\nfunction getTabbableCandidates(container) {\n const nodes = [];\n const walker = document.createTreeWalker(container, NodeFilter.SHOW_ELEMENT, {\n acceptNode: (node) => {\n const isHiddenInput = node.tagName === \"INPUT\" && node.type === \"hidden\";\n if (node.disabled || node.hidden || isHiddenInput) return NodeFilter.FILTER_SKIP;\n return node.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;\n }\n });\n while (walker.nextNode()) nodes.push(walker.currentNode);\n return nodes;\n}\nfunction findVisible(elements, container) {\n for (const element of elements) {\n if (!isHidden(element, { upTo: container })) return element;\n }\n}\nfunction isHidden(node, { upTo }) {\n if (getComputedStyle(node).visibility === \"hidden\") return true;\n while (node) {\n if (upTo !== void 0 && node === upTo) return false;\n if (getComputedStyle(node).display === \"none\") return true;\n node = node.parentElement;\n }\n return false;\n}\nfunction isSelectableInput(element) {\n return element instanceof HTMLInputElement && \"select\" in element;\n}\nfunction focus(element, { select = false } = {}) {\n if (element && element.focus) {\n const previouslyFocusedElement = document.activeElement;\n element.focus({ preventScroll: true });\n if (element !== previouslyFocusedElement && isSelectableInput(element) && select)\n element.select();\n }\n}\nvar focusScopesStack = createFocusScopesStack();\nfunction createFocusScopesStack() {\n let stack = [];\n return {\n add(focusScope) {\n const activeFocusScope = stack[0];\n if (focusScope !== activeFocusScope) {\n activeFocusScope?.pause();\n }\n stack = arrayRemove(stack, focusScope);\n stack.unshift(focusScope);\n },\n remove(focusScope) {\n stack = arrayRemove(stack, focusScope);\n stack[0]?.resume();\n }\n };\n}\nfunction arrayRemove(array, item) {\n const updatedArray = [...array];\n const index = updatedArray.indexOf(item);\n if (index !== -1) {\n updatedArray.splice(index, 1);\n }\n return updatedArray;\n}\nfunction removeLinks(items) {\n return items.filter((item) => item.tagName !== \"A\");\n}\nvar Root = FocusScope;\nexport {\n FocusScope,\n Root\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/use-layout-effect/src/use-layout-effect.tsx\nimport * as React from \"react\";\nvar useLayoutEffect2 = globalThis?.document ? React.useLayoutEffect : () => {\n};\nexport {\n useLayoutEffect2 as useLayoutEffect\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/id/src/id.tsx\nimport * as React from \"react\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nvar useReactId = React[\" useId \".trim().toString()] || (() => void 0);\nvar count = 0;\nfunction useId(deterministicId) {\n const [id, setId] = React.useState(useReactId());\n useLayoutEffect(() => {\n if (!deterministicId) setId((reactId) => reactId ?? String(count++));\n }, [deterministicId]);\n return deterministicId || (id ? `radix-${id}` : \"\");\n}\nexport {\n useId\n};\n//# sourceMappingURL=index.mjs.map\n","/**\n * Custom positioning reference element.\n * @see https://floating-ui.com/docs/virtual-elements\n */\n\nconst sides = ['top', 'right', 'bottom', 'left'];\nconst alignments = ['start', 'end'];\nconst placements = /*#__PURE__*/sides.reduce((acc, side) => acc.concat(side, side + \"-\" + alignments[0], side + \"-\" + alignments[1]), []);\nconst min = Math.min;\nconst max = Math.max;\nconst round = Math.round;\nconst floor = Math.floor;\nconst createCoords = v => ({\n x: v,\n y: v\n});\nconst oppositeSideMap = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nconst oppositeAlignmentMap = {\n start: 'end',\n end: 'start'\n};\nfunction clamp(start, value, end) {\n return max(start, min(value, end));\n}\nfunction evaluate(value, param) {\n return typeof value === 'function' ? value(param) : value;\n}\nfunction getSide(placement) {\n return placement.split('-')[0];\n}\nfunction getAlignment(placement) {\n return placement.split('-')[1];\n}\nfunction getOppositeAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}\nfunction getAxisLength(axis) {\n return axis === 'y' ? 'height' : 'width';\n}\nconst yAxisSides = /*#__PURE__*/new Set(['top', 'bottom']);\nfunction getSideAxis(placement) {\n return yAxisSides.has(getSide(placement)) ? 'y' : 'x';\n}\nfunction getAlignmentAxis(placement) {\n return getOppositeAxis(getSideAxis(placement));\n}\nfunction getAlignmentSides(placement, rects, rtl) {\n if (rtl === void 0) {\n rtl = false;\n }\n const alignment = getAlignment(placement);\n const alignmentAxis = getAlignmentAxis(placement);\n const length = getAxisLength(alignmentAxis);\n let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';\n if (rects.reference[length] > rects.floating[length]) {\n mainAlignmentSide = getOppositePlacement(mainAlignmentSide);\n }\n return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];\n}\nfunction getExpandedPlacements(placement) {\n const oppositePlacement = getOppositePlacement(placement);\n return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];\n}\nfunction getOppositeAlignmentPlacement(placement) {\n return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);\n}\nconst lrPlacement = ['left', 'right'];\nconst rlPlacement = ['right', 'left'];\nconst tbPlacement = ['top', 'bottom'];\nconst btPlacement = ['bottom', 'top'];\nfunction getSideList(side, isStart, rtl) {\n switch (side) {\n case 'top':\n case 'bottom':\n if (rtl) return isStart ? rlPlacement : lrPlacement;\n return isStart ? lrPlacement : rlPlacement;\n case 'left':\n case 'right':\n return isStart ? tbPlacement : btPlacement;\n default:\n return [];\n }\n}\nfunction getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {\n const alignment = getAlignment(placement);\n let list = getSideList(getSide(placement), direction === 'start', rtl);\n if (alignment) {\n list = list.map(side => side + \"-\" + alignment);\n if (flipAlignment) {\n list = list.concat(list.map(getOppositeAlignmentPlacement));\n }\n }\n return list;\n}\nfunction getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);\n}\nfunction expandPaddingObject(padding) {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n ...padding\n };\n}\nfunction getPaddingObject(padding) {\n return typeof padding !== 'number' ? expandPaddingObject(padding) : {\n top: padding,\n right: padding,\n bottom: padding,\n left: padding\n };\n}\nfunction rectToClientRect(rect) {\n const {\n x,\n y,\n width,\n height\n } = rect;\n return {\n width,\n height,\n top: y,\n left: x,\n right: x + width,\n bottom: y + height,\n x,\n y\n };\n}\n\nexport { alignments, clamp, createCoords, evaluate, expandPaddingObject, floor, getAlignment, getAlignmentAxis, getAlignmentSides, getAxisLength, getExpandedPlacements, getOppositeAlignmentPlacement, getOppositeAxis, getOppositeAxisPlacements, getOppositePlacement, getPaddingObject, getSide, getSideAxis, max, min, placements, rectToClientRect, round, sides };\n","import { getSideAxis, getAlignmentAxis, getAxisLength, getSide, getAlignment, evaluate, getPaddingObject, rectToClientRect, min, clamp, placements, getAlignmentSides, getOppositeAlignmentPlacement, getOppositePlacement, getExpandedPlacements, getOppositeAxisPlacements, sides, max, getOppositeAxis } from '@floating-ui/utils';\nexport { rectToClientRect } from '@floating-ui/utils';\n\nfunction computeCoordsFromPlacement(_ref, placement, rtl) {\n let {\n reference,\n floating\n } = _ref;\n const sideAxis = getSideAxis(placement);\n const alignmentAxis = getAlignmentAxis(placement);\n const alignLength = getAxisLength(alignmentAxis);\n const side = getSide(placement);\n const isVertical = sideAxis === 'y';\n const commonX = reference.x + reference.width / 2 - floating.width / 2;\n const commonY = reference.y + reference.height / 2 - floating.height / 2;\n const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;\n let coords;\n switch (side) {\n case 'top':\n coords = {\n x: commonX,\n y: reference.y - floating.height\n };\n break;\n case 'bottom':\n coords = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n case 'right':\n coords = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n case 'left':\n coords = {\n x: reference.x - floating.width,\n y: commonY\n };\n break;\n default:\n coords = {\n x: reference.x,\n y: reference.y\n };\n }\n switch (getAlignment(placement)) {\n case 'start':\n coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);\n break;\n case 'end':\n coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);\n break;\n }\n return coords;\n}\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a given reference element.\n *\n * This export does not have any `platform` interface logic. You will need to\n * write one for the platform you are using Floating UI with.\n */\nconst computePosition = async (reference, floating, config) => {\n const {\n placement = 'bottom',\n strategy = 'absolute',\n middleware = [],\n platform\n } = config;\n const validMiddleware = middleware.filter(Boolean);\n const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));\n let rects = await platform.getElementRects({\n reference,\n floating,\n strategy\n });\n let {\n x,\n y\n } = computeCoordsFromPlacement(rects, placement, rtl);\n let statefulPlacement = placement;\n let middlewareData = {};\n let resetCount = 0;\n for (let i = 0; i < validMiddleware.length; i++) {\n const {\n name,\n fn\n } = validMiddleware[i];\n const {\n x: nextX,\n y: nextY,\n data,\n reset\n } = await fn({\n x,\n y,\n initialPlacement: placement,\n placement: statefulPlacement,\n strategy,\n middlewareData,\n rects,\n platform,\n elements: {\n reference,\n floating\n }\n });\n x = nextX != null ? nextX : x;\n y = nextY != null ? nextY : y;\n middlewareData = {\n ...middlewareData,\n [name]: {\n ...middlewareData[name],\n ...data\n }\n };\n if (reset && resetCount <= 50) {\n resetCount++;\n if (typeof reset === 'object') {\n if (reset.placement) {\n statefulPlacement = reset.placement;\n }\n if (reset.rects) {\n rects = reset.rects === true ? await platform.getElementRects({\n reference,\n floating,\n strategy\n }) : reset.rects;\n }\n ({\n x,\n y\n } = computeCoordsFromPlacement(rects, statefulPlacement, rtl));\n }\n i = -1;\n }\n }\n return {\n x,\n y,\n placement: statefulPlacement,\n strategy,\n middlewareData\n };\n};\n\n/**\n * Resolves with an object of overflow side offsets that determine how much the\n * element is overflowing a given clipping boundary on each side.\n * - positive = overflowing the boundary by that number of pixels\n * - negative = how many pixels left before it will overflow\n * - 0 = lies flush with the boundary\n * @see https://floating-ui.com/docs/detectOverflow\n */\nasync function detectOverflow(state, options) {\n var _await$platform$isEle;\n if (options === void 0) {\n options = {};\n }\n const {\n x,\n y,\n platform,\n rects,\n elements,\n strategy\n } = state;\n const {\n boundary = 'clippingAncestors',\n rootBoundary = 'viewport',\n elementContext = 'floating',\n altBoundary = false,\n padding = 0\n } = evaluate(options, state);\n const paddingObject = getPaddingObject(padding);\n const altContext = elementContext === 'floating' ? 'reference' : 'floating';\n const element = elements[altBoundary ? altContext : elementContext];\n const clippingClientRect = rectToClientRect(await platform.getClippingRect({\n element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || (await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating))),\n boundary,\n rootBoundary,\n strategy\n }));\n const rect = elementContext === 'floating' ? {\n x,\n y,\n width: rects.floating.width,\n height: rects.floating.height\n } : rects.reference;\n const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));\n const offsetScale = (await (platform.isElement == null ? void 0 : platform.isElement(offsetParent))) ? (await (platform.getScale == null ? void 0 : platform.getScale(offsetParent))) || {\n x: 1,\n y: 1\n } : {\n x: 1,\n y: 1\n };\n const elementClientRect = rectToClientRect(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({\n elements,\n rect,\n offsetParent,\n strategy\n }) : rect);\n return {\n top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,\n bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,\n left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,\n right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x\n };\n}\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = options => ({\n name: 'arrow',\n options,\n async fn(state) {\n const {\n x,\n y,\n placement,\n rects,\n platform,\n elements,\n middlewareData\n } = state;\n // Since `element` is required, we don't Partial<> the type.\n const {\n element,\n padding = 0\n } = evaluate(options, state) || {};\n if (element == null) {\n return {};\n }\n const paddingObject = getPaddingObject(padding);\n const coords = {\n x,\n y\n };\n const axis = getAlignmentAxis(placement);\n const length = getAxisLength(axis);\n const arrowDimensions = await platform.getDimensions(element);\n const isYAxis = axis === 'y';\n const minProp = isYAxis ? 'top' : 'left';\n const maxProp = isYAxis ? 'bottom' : 'right';\n const clientProp = isYAxis ? 'clientHeight' : 'clientWidth';\n const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];\n const startDiff = coords[axis] - rects.reference[axis];\n const arrowOffsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(element));\n let clientSize = arrowOffsetParent ? arrowOffsetParent[clientProp] : 0;\n\n // DOM platform can return `window` as the `offsetParent`.\n if (!clientSize || !(await (platform.isElement == null ? void 0 : platform.isElement(arrowOffsetParent)))) {\n clientSize = elements.floating[clientProp] || rects.floating[length];\n }\n const centerToReference = endDiff / 2 - startDiff / 2;\n\n // If the padding is large enough that it causes the arrow to no longer be\n // centered, modify the padding so that it is centered.\n const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;\n const minPadding = min(paddingObject[minProp], largestPossiblePadding);\n const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);\n\n // Make sure the arrow doesn't overflow the floating element if the center\n // point is outside the floating element's bounds.\n const min$1 = minPadding;\n const max = clientSize - arrowDimensions[length] - maxPadding;\n const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;\n const offset = clamp(min$1, center, max);\n\n // If the reference is small enough that the arrow's padding causes it to\n // to point to nothing for an aligned placement, adjust the offset of the\n // floating element itself. To ensure `shift()` continues to take action,\n // a single reset is performed when this is true.\n const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset && rects.reference[length] / 2 - (center < min$1 ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;\n const alignmentOffset = shouldAddOffset ? center < min$1 ? center - min$1 : center - max : 0;\n return {\n [axis]: coords[axis] + alignmentOffset,\n data: {\n [axis]: offset,\n centerOffset: center - offset - alignmentOffset,\n ...(shouldAddOffset && {\n alignmentOffset\n })\n },\n reset: shouldAddOffset\n };\n }\n});\n\nfunction getPlacementList(alignment, autoAlignment, allowedPlacements) {\n const allowedPlacementsSortedByAlignment = alignment ? [...allowedPlacements.filter(placement => getAlignment(placement) === alignment), ...allowedPlacements.filter(placement => getAlignment(placement) !== alignment)] : allowedPlacements.filter(placement => getSide(placement) === placement);\n return allowedPlacementsSortedByAlignment.filter(placement => {\n if (alignment) {\n return getAlignment(placement) === alignment || (autoAlignment ? getOppositeAlignmentPlacement(placement) !== placement : false);\n }\n return true;\n });\n}\n/**\n * Optimizes the visibility of the floating element by choosing the placement\n * that has the most space available automatically, without needing to specify a\n * preferred placement. Alternative to `flip`.\n * @see https://floating-ui.com/docs/autoPlacement\n */\nconst autoPlacement = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'autoPlacement',\n options,\n async fn(state) {\n var _middlewareData$autoP, _middlewareData$autoP2, _placementsThatFitOnE;\n const {\n rects,\n middlewareData,\n placement,\n platform,\n elements\n } = state;\n const {\n crossAxis = false,\n alignment,\n allowedPlacements = placements,\n autoAlignment = true,\n ...detectOverflowOptions\n } = evaluate(options, state);\n const placements$1 = alignment !== undefined || allowedPlacements === placements ? getPlacementList(alignment || null, autoAlignment, allowedPlacements) : allowedPlacements;\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const currentIndex = ((_middlewareData$autoP = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP.index) || 0;\n const currentPlacement = placements$1[currentIndex];\n if (currentPlacement == null) {\n return {};\n }\n const alignmentSides = getAlignmentSides(currentPlacement, rects, await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating)));\n\n // Make `computeCoords` start from the right place.\n if (placement !== currentPlacement) {\n return {\n reset: {\n placement: placements$1[0]\n }\n };\n }\n const currentOverflows = [overflow[getSide(currentPlacement)], overflow[alignmentSides[0]], overflow[alignmentSides[1]]];\n const allOverflows = [...(((_middlewareData$autoP2 = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP2.overflows) || []), {\n placement: currentPlacement,\n overflows: currentOverflows\n }];\n const nextPlacement = placements$1[currentIndex + 1];\n\n // There are more placements to check.\n if (nextPlacement) {\n return {\n data: {\n index: currentIndex + 1,\n overflows: allOverflows\n },\n reset: {\n placement: nextPlacement\n }\n };\n }\n const placementsSortedByMostSpace = allOverflows.map(d => {\n const alignment = getAlignment(d.placement);\n return [d.placement, alignment && crossAxis ?\n // Check along the mainAxis and main crossAxis side.\n d.overflows.slice(0, 2).reduce((acc, v) => acc + v, 0) :\n // Check only the mainAxis.\n d.overflows[0], d.overflows];\n }).sort((a, b) => a[1] - b[1]);\n const placementsThatFitOnEachSide = placementsSortedByMostSpace.filter(d => d[2].slice(0,\n // Aligned placements should not check their opposite crossAxis\n // side.\n getAlignment(d[0]) ? 2 : 3).every(v => v <= 0));\n const resetPlacement = ((_placementsThatFitOnE = placementsThatFitOnEachSide[0]) == null ? void 0 : _placementsThatFitOnE[0]) || placementsSortedByMostSpace[0][0];\n if (resetPlacement !== placement) {\n return {\n data: {\n index: currentIndex + 1,\n overflows: allOverflows\n },\n reset: {\n placement: resetPlacement\n }\n };\n }\n return {};\n }\n };\n};\n\n/**\n * Optimizes the visibility of the floating element by flipping the `placement`\n * in order to keep it in view when the preferred placement(s) will overflow the\n * clipping boundary. Alternative to `autoPlacement`.\n * @see https://floating-ui.com/docs/flip\n */\nconst flip = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'flip',\n options,\n async fn(state) {\n var _middlewareData$arrow, _middlewareData$flip;\n const {\n placement,\n middlewareData,\n rects,\n initialPlacement,\n platform,\n elements\n } = state;\n const {\n mainAxis: checkMainAxis = true,\n crossAxis: checkCrossAxis = true,\n fallbackPlacements: specifiedFallbackPlacements,\n fallbackStrategy = 'bestFit',\n fallbackAxisSideDirection = 'none',\n flipAlignment = true,\n ...detectOverflowOptions\n } = evaluate(options, state);\n\n // If a reset by the arrow was caused due to an alignment offset being\n // added, we should skip any logic now since `flip()` has already done its\n // work.\n // https://github.com/floating-ui/floating-ui/issues/2549#issuecomment-1719601643\n if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {\n return {};\n }\n const side = getSide(placement);\n const initialSideAxis = getSideAxis(initialPlacement);\n const isBasePlacement = getSide(initialPlacement) === initialPlacement;\n const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));\n const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));\n const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== 'none';\n if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {\n fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));\n }\n const placements = [initialPlacement, ...fallbackPlacements];\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const overflows = [];\n let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];\n if (checkMainAxis) {\n overflows.push(overflow[side]);\n }\n if (checkCrossAxis) {\n const sides = getAlignmentSides(placement, rects, rtl);\n overflows.push(overflow[sides[0]], overflow[sides[1]]);\n }\n overflowsData = [...overflowsData, {\n placement,\n overflows\n }];\n\n // One or more sides is overflowing.\n if (!overflows.every(side => side <= 0)) {\n var _middlewareData$flip2, _overflowsData$filter;\n const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;\n const nextPlacement = placements[nextIndex];\n if (nextPlacement) {\n const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;\n if (!ignoreCrossAxisOverflow ||\n // We leave the current main axis only if every placement on that axis\n // overflows the main axis.\n overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {\n // Try next placement and re-run the lifecycle.\n return {\n data: {\n index: nextIndex,\n overflows: overflowsData\n },\n reset: {\n placement: nextPlacement\n }\n };\n }\n }\n\n // First, find the candidates that fit on the mainAxis side of overflow,\n // then find the placement that fits the best on the main crossAxis side.\n let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;\n\n // Otherwise fallback.\n if (!resetPlacement) {\n switch (fallbackStrategy) {\n case 'bestFit':\n {\n var _overflowsData$filter2;\n const placement = (_overflowsData$filter2 = overflowsData.filter(d => {\n if (hasFallbackAxisSideDirection) {\n const currentSideAxis = getSideAxis(d.placement);\n return currentSideAxis === initialSideAxis ||\n // Create a bias to the `y` side axis due to horizontal\n // reading directions favoring greater width.\n currentSideAxis === 'y';\n }\n return true;\n }).map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];\n if (placement) {\n resetPlacement = placement;\n }\n break;\n }\n case 'initialPlacement':\n resetPlacement = initialPlacement;\n break;\n }\n }\n if (placement !== resetPlacement) {\n return {\n reset: {\n placement: resetPlacement\n }\n };\n }\n }\n return {};\n }\n };\n};\n\nfunction getSideOffsets(overflow, rect) {\n return {\n top: overflow.top - rect.height,\n right: overflow.right - rect.width,\n bottom: overflow.bottom - rect.height,\n left: overflow.left - rect.width\n };\n}\nfunction isAnySideFullyClipped(overflow) {\n return sides.some(side => overflow[side] >= 0);\n}\n/**\n * Provides data to hide the floating element in applicable situations, such as\n * when it is not in the same clipping context as the reference element.\n * @see https://floating-ui.com/docs/hide\n */\nconst hide = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'hide',\n options,\n async fn(state) {\n const {\n rects\n } = state;\n const {\n strategy = 'referenceHidden',\n ...detectOverflowOptions\n } = evaluate(options, state);\n switch (strategy) {\n case 'referenceHidden':\n {\n const overflow = await detectOverflow(state, {\n ...detectOverflowOptions,\n elementContext: 'reference'\n });\n const offsets = getSideOffsets(overflow, rects.reference);\n return {\n data: {\n referenceHiddenOffsets: offsets,\n referenceHidden: isAnySideFullyClipped(offsets)\n }\n };\n }\n case 'escaped':\n {\n const overflow = await detectOverflow(state, {\n ...detectOverflowOptions,\n altBoundary: true\n });\n const offsets = getSideOffsets(overflow, rects.floating);\n return {\n data: {\n escapedOffsets: offsets,\n escaped: isAnySideFullyClipped(offsets)\n }\n };\n }\n default:\n {\n return {};\n }\n }\n }\n };\n};\n\nfunction getBoundingRect(rects) {\n const minX = min(...rects.map(rect => rect.left));\n const minY = min(...rects.map(rect => rect.top));\n const maxX = max(...rects.map(rect => rect.right));\n const maxY = max(...rects.map(rect => rect.bottom));\n return {\n x: minX,\n y: minY,\n width: maxX - minX,\n height: maxY - minY\n };\n}\nfunction getRectsByLine(rects) {\n const sortedRects = rects.slice().sort((a, b) => a.y - b.y);\n const groups = [];\n let prevRect = null;\n for (let i = 0; i < sortedRects.length; i++) {\n const rect = sortedRects[i];\n if (!prevRect || rect.y - prevRect.y > prevRect.height / 2) {\n groups.push([rect]);\n } else {\n groups[groups.length - 1].push(rect);\n }\n prevRect = rect;\n }\n return groups.map(rect => rectToClientRect(getBoundingRect(rect)));\n}\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'inline',\n options,\n async fn(state) {\n const {\n placement,\n elements,\n rects,\n platform,\n strategy\n } = state;\n // A MouseEvent's client{X,Y} coords can be up to 2 pixels off a\n // ClientRect's bounds, despite the event listener being triggered. A\n // padding of 2 seems to handle this issue.\n const {\n padding = 2,\n x,\n y\n } = evaluate(options, state);\n const nativeClientRects = Array.from((await (platform.getClientRects == null ? void 0 : platform.getClientRects(elements.reference))) || []);\n const clientRects = getRectsByLine(nativeClientRects);\n const fallback = rectToClientRect(getBoundingRect(nativeClientRects));\n const paddingObject = getPaddingObject(padding);\n function getBoundingClientRect() {\n // There are two rects and they are disjoined.\n if (clientRects.length === 2 && clientRects[0].left > clientRects[1].right && x != null && y != null) {\n // Find the first rect in which the point is fully inside.\n return clientRects.find(rect => x > rect.left - paddingObject.left && x < rect.right + paddingObject.right && y > rect.top - paddingObject.top && y < rect.bottom + paddingObject.bottom) || fallback;\n }\n\n // There are 2 or more connected rects.\n if (clientRects.length >= 2) {\n if (getSideAxis(placement) === 'y') {\n const firstRect = clientRects[0];\n const lastRect = clientRects[clientRects.length - 1];\n const isTop = getSide(placement) === 'top';\n const top = firstRect.top;\n const bottom = lastRect.bottom;\n const left = isTop ? firstRect.left : lastRect.left;\n const right = isTop ? firstRect.right : lastRect.right;\n const width = right - left;\n const height = bottom - top;\n return {\n top,\n bottom,\n left,\n right,\n width,\n height,\n x: left,\n y: top\n };\n }\n const isLeftSide = getSide(placement) === 'left';\n const maxRight = max(...clientRects.map(rect => rect.right));\n const minLeft = min(...clientRects.map(rect => rect.left));\n const measureRects = clientRects.filter(rect => isLeftSide ? rect.left === minLeft : rect.right === maxRight);\n const top = measureRects[0].top;\n const bottom = measureRects[measureRects.length - 1].bottom;\n const left = minLeft;\n const right = maxRight;\n const width = right - left;\n const height = bottom - top;\n return {\n top,\n bottom,\n left,\n right,\n width,\n height,\n x: left,\n y: top\n };\n }\n return fallback;\n }\n const resetRects = await platform.getElementRects({\n reference: {\n getBoundingClientRect\n },\n floating: elements.floating,\n strategy\n });\n if (rects.reference.x !== resetRects.reference.x || rects.reference.y !== resetRects.reference.y || rects.reference.width !== resetRects.reference.width || rects.reference.height !== resetRects.reference.height) {\n return {\n reset: {\n rects: resetRects\n }\n };\n }\n return {};\n }\n };\n};\n\nconst originSides = /*#__PURE__*/new Set(['left', 'top']);\n\n// For type backwards-compatibility, the `OffsetOptions` type was also\n// Derivable.\n\nasync function convertValueToCoords(state, options) {\n const {\n placement,\n platform,\n elements\n } = state;\n const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));\n const side = getSide(placement);\n const alignment = getAlignment(placement);\n const isVertical = getSideAxis(placement) === 'y';\n const mainAxisMulti = originSides.has(side) ? -1 : 1;\n const crossAxisMulti = rtl && isVertical ? -1 : 1;\n const rawValue = evaluate(options, state);\n\n // eslint-disable-next-line prefer-const\n let {\n mainAxis,\n crossAxis,\n alignmentAxis\n } = typeof rawValue === 'number' ? {\n mainAxis: rawValue,\n crossAxis: 0,\n alignmentAxis: null\n } : {\n mainAxis: rawValue.mainAxis || 0,\n crossAxis: rawValue.crossAxis || 0,\n alignmentAxis: rawValue.alignmentAxis\n };\n if (alignment && typeof alignmentAxis === 'number') {\n crossAxis = alignment === 'end' ? alignmentAxis * -1 : alignmentAxis;\n }\n return isVertical ? {\n x: crossAxis * crossAxisMulti,\n y: mainAxis * mainAxisMulti\n } : {\n x: mainAxis * mainAxisMulti,\n y: crossAxis * crossAxisMulti\n };\n}\n\n/**\n * Modifies the placement by translating the floating element along the\n * specified axes.\n * A number (shorthand for `mainAxis` or distance), or an axes configuration\n * object may be passed.\n * @see https://floating-ui.com/docs/offset\n */\nconst offset = function (options) {\n if (options === void 0) {\n options = 0;\n }\n return {\n name: 'offset',\n options,\n async fn(state) {\n var _middlewareData$offse, _middlewareData$arrow;\n const {\n x,\n y,\n placement,\n middlewareData\n } = state;\n const diffCoords = await convertValueToCoords(state, options);\n\n // If the placement is the same and the arrow caused an alignment offset\n // then we don't need to change the positioning coordinates.\n if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {\n return {};\n }\n return {\n x: x + diffCoords.x,\n y: y + diffCoords.y,\n data: {\n ...diffCoords,\n placement\n }\n };\n }\n };\n};\n\n/**\n * Optimizes the visibility of the floating element by shifting it in order to\n * keep it in view when it will overflow the clipping boundary.\n * @see https://floating-ui.com/docs/shift\n */\nconst shift = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'shift',\n options,\n async fn(state) {\n const {\n x,\n y,\n placement\n } = state;\n const {\n mainAxis: checkMainAxis = true,\n crossAxis: checkCrossAxis = false,\n limiter = {\n fn: _ref => {\n let {\n x,\n y\n } = _ref;\n return {\n x,\n y\n };\n }\n },\n ...detectOverflowOptions\n } = evaluate(options, state);\n const coords = {\n x,\n y\n };\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const crossAxis = getSideAxis(getSide(placement));\n const mainAxis = getOppositeAxis(crossAxis);\n let mainAxisCoord = coords[mainAxis];\n let crossAxisCoord = coords[crossAxis];\n if (checkMainAxis) {\n const minSide = mainAxis === 'y' ? 'top' : 'left';\n const maxSide = mainAxis === 'y' ? 'bottom' : 'right';\n const min = mainAxisCoord + overflow[minSide];\n const max = mainAxisCoord - overflow[maxSide];\n mainAxisCoord = clamp(min, mainAxisCoord, max);\n }\n if (checkCrossAxis) {\n const minSide = crossAxis === 'y' ? 'top' : 'left';\n const maxSide = crossAxis === 'y' ? 'bottom' : 'right';\n const min = crossAxisCoord + overflow[minSide];\n const max = crossAxisCoord - overflow[maxSide];\n crossAxisCoord = clamp(min, crossAxisCoord, max);\n }\n const limitedCoords = limiter.fn({\n ...state,\n [mainAxis]: mainAxisCoord,\n [crossAxis]: crossAxisCoord\n });\n return {\n ...limitedCoords,\n data: {\n x: limitedCoords.x - x,\n y: limitedCoords.y - y,\n enabled: {\n [mainAxis]: checkMainAxis,\n [crossAxis]: checkCrossAxis\n }\n }\n };\n }\n };\n};\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n options,\n fn(state) {\n const {\n x,\n y,\n placement,\n rects,\n middlewareData\n } = state;\n const {\n offset = 0,\n mainAxis: checkMainAxis = true,\n crossAxis: checkCrossAxis = true\n } = evaluate(options, state);\n const coords = {\n x,\n y\n };\n const crossAxis = getSideAxis(placement);\n const mainAxis = getOppositeAxis(crossAxis);\n let mainAxisCoord = coords[mainAxis];\n let crossAxisCoord = coords[crossAxis];\n const rawOffset = evaluate(offset, state);\n const computedOffset = typeof rawOffset === 'number' ? {\n mainAxis: rawOffset,\n crossAxis: 0\n } : {\n mainAxis: 0,\n crossAxis: 0,\n ...rawOffset\n };\n if (checkMainAxis) {\n const len = mainAxis === 'y' ? 'height' : 'width';\n const limitMin = rects.reference[mainAxis] - rects.floating[len] + computedOffset.mainAxis;\n const limitMax = rects.reference[mainAxis] + rects.reference[len] - computedOffset.mainAxis;\n if (mainAxisCoord < limitMin) {\n mainAxisCoord = limitMin;\n } else if (mainAxisCoord > limitMax) {\n mainAxisCoord = limitMax;\n }\n }\n if (checkCrossAxis) {\n var _middlewareData$offse, _middlewareData$offse2;\n const len = mainAxis === 'y' ? 'width' : 'height';\n const isOriginSide = originSides.has(getSide(placement));\n const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);\n const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);\n if (crossAxisCoord < limitMin) {\n crossAxisCoord = limitMin;\n } else if (crossAxisCoord > limitMax) {\n crossAxisCoord = limitMax;\n }\n }\n return {\n [mainAxis]: mainAxisCoord,\n [crossAxis]: crossAxisCoord\n };\n }\n };\n};\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'size',\n options,\n async fn(state) {\n var _state$middlewareData, _state$middlewareData2;\n const {\n placement,\n rects,\n platform,\n elements\n } = state;\n const {\n apply = () => {},\n ...detectOverflowOptions\n } = evaluate(options, state);\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const side = getSide(placement);\n const alignment = getAlignment(placement);\n const isYAxis = getSideAxis(placement) === 'y';\n const {\n width,\n height\n } = rects.floating;\n let heightSide;\n let widthSide;\n if (side === 'top' || side === 'bottom') {\n heightSide = side;\n widthSide = alignment === ((await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating))) ? 'start' : 'end') ? 'left' : 'right';\n } else {\n widthSide = side;\n heightSide = alignment === 'end' ? 'top' : 'bottom';\n }\n const maximumClippingHeight = height - overflow.top - overflow.bottom;\n const maximumClippingWidth = width - overflow.left - overflow.right;\n const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);\n const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);\n const noShift = !state.middlewareData.shift;\n let availableHeight = overflowAvailableHeight;\n let availableWidth = overflowAvailableWidth;\n if ((_state$middlewareData = state.middlewareData.shift) != null && _state$middlewareData.enabled.x) {\n availableWidth = maximumClippingWidth;\n }\n if ((_state$middlewareData2 = state.middlewareData.shift) != null && _state$middlewareData2.enabled.y) {\n availableHeight = maximumClippingHeight;\n }\n if (noShift && !alignment) {\n const xMin = max(overflow.left, 0);\n const xMax = max(overflow.right, 0);\n const yMin = max(overflow.top, 0);\n const yMax = max(overflow.bottom, 0);\n if (isYAxis) {\n availableWidth = width - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));\n } else {\n availableHeight = height - 2 * (yMin !== 0 || yMax !== 0 ? yMin + yMax : max(overflow.top, overflow.bottom));\n }\n }\n await apply({\n ...state,\n availableWidth,\n availableHeight\n });\n const nextDimensions = await platform.getDimensions(elements.floating);\n if (width !== nextDimensions.width || height !== nextDimensions.height) {\n return {\n reset: {\n rects: true\n }\n };\n }\n return {};\n }\n };\n};\n\nexport { arrow, autoPlacement, computePosition, detectOverflow, flip, hide, inline, limitShift, offset, shift, size };\n","function hasWindow() {\n return typeof window !== 'undefined';\n}\nfunction getNodeName(node) {\n if (isNode(node)) {\n return (node.nodeName || '').toLowerCase();\n }\n // Mocked nodes in testing environments may not be instances of Node. By\n // returning `#document` an infinite loop won't occur.\n // https://github.com/floating-ui/floating-ui/issues/2317\n return '#document';\n}\nfunction getWindow(node) {\n var _node$ownerDocument;\n return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;\n}\nfunction getDocumentElement(node) {\n var _ref;\n return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;\n}\nfunction isNode(value) {\n if (!hasWindow()) {\n return false;\n }\n return value instanceof Node || value instanceof getWindow(value).Node;\n}\nfunction isElement(value) {\n if (!hasWindow()) {\n return false;\n }\n return value instanceof Element || value instanceof getWindow(value).Element;\n}\nfunction isHTMLElement(value) {\n if (!hasWindow()) {\n return false;\n }\n return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;\n}\nfunction isShadowRoot(value) {\n if (!hasWindow() || typeof ShadowRoot === 'undefined') {\n return false;\n }\n return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;\n}\nconst invalidOverflowDisplayValues = /*#__PURE__*/new Set(['inline', 'contents']);\nfunction isOverflowElement(element) {\n const {\n overflow,\n overflowX,\n overflowY,\n display\n } = getComputedStyle(element);\n return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);\n}\nconst tableElements = /*#__PURE__*/new Set(['table', 'td', 'th']);\nfunction isTableElement(element) {\n return tableElements.has(getNodeName(element));\n}\nconst topLayerSelectors = [':popover-open', ':modal'];\nfunction isTopLayer(element) {\n return topLayerSelectors.some(selector => {\n try {\n return element.matches(selector);\n } catch (_e) {\n return false;\n }\n });\n}\nconst transformProperties = ['transform', 'translate', 'scale', 'rotate', 'perspective'];\nconst willChangeValues = ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'];\nconst containValues = ['paint', 'layout', 'strict', 'content'];\nfunction isContainingBlock(elementOrCss) {\n const webkit = isWebKit();\n const css = isElement(elementOrCss) ? getComputedStyle(elementOrCss) : elementOrCss;\n\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n // https://drafts.csswg.org/css-transforms-2/#individual-transforms\n return transformProperties.some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || willChangeValues.some(value => (css.willChange || '').includes(value)) || containValues.some(value => (css.contain || '').includes(value));\n}\nfunction getContainingBlock(element) {\n let currentNode = getParentNode(element);\n while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {\n if (isContainingBlock(currentNode)) {\n return currentNode;\n } else if (isTopLayer(currentNode)) {\n return null;\n }\n currentNode = getParentNode(currentNode);\n }\n return null;\n}\nfunction isWebKit() {\n if (typeof CSS === 'undefined' || !CSS.supports) return false;\n return CSS.supports('-webkit-backdrop-filter', 'none');\n}\nconst lastTraversableNodeNames = /*#__PURE__*/new Set(['html', 'body', '#document']);\nfunction isLastTraversableNode(node) {\n return lastTraversableNodeNames.has(getNodeName(node));\n}\nfunction getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}\nfunction getNodeScroll(element) {\n if (isElement(element)) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n }\n return {\n scrollLeft: element.scrollX,\n scrollTop: element.scrollY\n };\n}\nfunction getParentNode(node) {\n if (getNodeName(node) === 'html') {\n return node;\n }\n const result =\n // Step into the shadow DOM of the parent of a slotted node.\n node.assignedSlot ||\n // DOM Element detected.\n node.parentNode ||\n // ShadowRoot detected.\n isShadowRoot(node) && node.host ||\n // Fallback.\n getDocumentElement(node);\n return isShadowRoot(result) ? result.host : result;\n}\nfunction getNearestOverflowAncestor(node) {\n const parentNode = getParentNode(node);\n if (isLastTraversableNode(parentNode)) {\n return node.ownerDocument ? node.ownerDocument.body : node.body;\n }\n if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {\n return parentNode;\n }\n return getNearestOverflowAncestor(parentNode);\n}\nfunction getOverflowAncestors(node, list, traverseIframes) {\n var _node$ownerDocument2;\n if (list === void 0) {\n list = [];\n }\n if (traverseIframes === void 0) {\n traverseIframes = true;\n }\n const scrollableAncestor = getNearestOverflowAncestor(node);\n const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);\n const win = getWindow(scrollableAncestor);\n if (isBody) {\n const frameElement = getFrameElement(win);\n return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);\n }\n return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));\n}\nfunction getFrameElement(win) {\n return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;\n}\n\nexport { getComputedStyle, getContainingBlock, getDocumentElement, getFrameElement, getNearestOverflowAncestor, getNodeName, getNodeScroll, getOverflowAncestors, getParentNode, getWindow, isContainingBlock, isElement, isHTMLElement, isLastTraversableNode, isNode, isOverflowElement, isShadowRoot, isTableElement, isTopLayer, isWebKit };\n","import { rectToClientRect, arrow as arrow$1, autoPlacement as autoPlacement$1, detectOverflow as detectOverflow$1, flip as flip$1, hide as hide$1, inline as inline$1, limitShift as limitShift$1, offset as offset$1, shift as shift$1, size as size$1, computePosition as computePosition$1 } from '@floating-ui/core';\nimport { round, createCoords, max, min, floor } from '@floating-ui/utils';\nimport { getComputedStyle as getComputedStyle$1, isHTMLElement, isElement, getWindow, isWebKit, getFrameElement, getNodeScroll, getDocumentElement, isTopLayer, getNodeName, isOverflowElement, getOverflowAncestors, getParentNode, isLastTraversableNode, isContainingBlock, isTableElement, getContainingBlock } from '@floating-ui/utils/dom';\nexport { getOverflowAncestors } from '@floating-ui/utils/dom';\n\nfunction getCssDimensions(element) {\n const css = getComputedStyle$1(element);\n // In testing environments, the `width` and `height` properties are empty\n // strings for SVG elements, returning NaN. Fallback to `0` in this case.\n let width = parseFloat(css.width) || 0;\n let height = parseFloat(css.height) || 0;\n const hasOffset = isHTMLElement(element);\n const offsetWidth = hasOffset ? element.offsetWidth : width;\n const offsetHeight = hasOffset ? element.offsetHeight : height;\n const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;\n if (shouldFallback) {\n width = offsetWidth;\n height = offsetHeight;\n }\n return {\n width,\n height,\n $: shouldFallback\n };\n}\n\nfunction unwrapElement(element) {\n return !isElement(element) ? element.contextElement : element;\n}\n\nfunction getScale(element) {\n const domElement = unwrapElement(element);\n if (!isHTMLElement(domElement)) {\n return createCoords(1);\n }\n const rect = domElement.getBoundingClientRect();\n const {\n width,\n height,\n $\n } = getCssDimensions(domElement);\n let x = ($ ? round(rect.width) : rect.width) / width;\n let y = ($ ? round(rect.height) : rect.height) / height;\n\n // 0, NaN, or Infinity should always fallback to 1.\n\n if (!x || !Number.isFinite(x)) {\n x = 1;\n }\n if (!y || !Number.isFinite(y)) {\n y = 1;\n }\n return {\n x,\n y\n };\n}\n\nconst noOffsets = /*#__PURE__*/createCoords(0);\nfunction getVisualOffsets(element) {\n const win = getWindow(element);\n if (!isWebKit() || !win.visualViewport) {\n return noOffsets;\n }\n return {\n x: win.visualViewport.offsetLeft,\n y: win.visualViewport.offsetTop\n };\n}\nfunction shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {\n return false;\n }\n return isFixed;\n}\n\nfunction getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n const clientRect = element.getBoundingClientRect();\n const domElement = unwrapElement(element);\n let scale = createCoords(1);\n if (includeScale) {\n if (offsetParent) {\n if (isElement(offsetParent)) {\n scale = getScale(offsetParent);\n }\n } else {\n scale = getScale(element);\n }\n }\n const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);\n let x = (clientRect.left + visualOffsets.x) / scale.x;\n let y = (clientRect.top + visualOffsets.y) / scale.y;\n let width = clientRect.width / scale.x;\n let height = clientRect.height / scale.y;\n if (domElement) {\n const win = getWindow(domElement);\n const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;\n let currentWin = win;\n let currentIFrame = getFrameElement(currentWin);\n while (currentIFrame && offsetParent && offsetWin !== currentWin) {\n const iframeScale = getScale(currentIFrame);\n const iframeRect = currentIFrame.getBoundingClientRect();\n const css = getComputedStyle$1(currentIFrame);\n const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;\n const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;\n x *= iframeScale.x;\n y *= iframeScale.y;\n width *= iframeScale.x;\n height *= iframeScale.y;\n x += left;\n y += top;\n currentWin = getWindow(currentIFrame);\n currentIFrame = getFrameElement(currentWin);\n }\n }\n return rectToClientRect({\n width,\n height,\n x,\n y\n });\n}\n\n// If <html> has a CSS width greater than the viewport, then this will be\n// incorrect for RTL.\nfunction getWindowScrollBarX(element, rect) {\n const leftScroll = getNodeScroll(element).scrollLeft;\n if (!rect) {\n return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;\n }\n return rect.left + leftScroll;\n}\n\nfunction getHTMLOffset(documentElement, scroll) {\n const htmlRect = documentElement.getBoundingClientRect();\n const x = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);\n const y = htmlRect.top + scroll.scrollTop;\n return {\n x,\n y\n };\n}\n\nfunction convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {\n let {\n elements,\n rect,\n offsetParent,\n strategy\n } = _ref;\n const isFixed = strategy === 'fixed';\n const documentElement = getDocumentElement(offsetParent);\n const topLayer = elements ? isTopLayer(elements.floating) : false;\n if (offsetParent === documentElement || topLayer && isFixed) {\n return rect;\n }\n let scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n let scale = createCoords(1);\n const offsets = createCoords(0);\n const isOffsetParentAnElement = isHTMLElement(offsetParent);\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n if (isHTMLElement(offsetParent)) {\n const offsetRect = getBoundingClientRect(offsetParent);\n scale = getScale(offsetParent);\n offsets.x = offsetRect.x + offsetParent.clientLeft;\n offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n }\n const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);\n return {\n width: rect.width * scale.x,\n height: rect.height * scale.y,\n x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,\n y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y\n };\n}\n\nfunction getClientRects(element) {\n return Array.from(element.getClientRects());\n}\n\n// Gets the entire size of the scrollable document area, even extending outside\n// of the `<html>` and `<body>` rect bounds if horizontally scrollable.\nfunction getDocumentRect(element) {\n const html = getDocumentElement(element);\n const scroll = getNodeScroll(element);\n const body = element.ownerDocument.body;\n const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);\n const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);\n let x = -scroll.scrollLeft + getWindowScrollBarX(element);\n const y = -scroll.scrollTop;\n if (getComputedStyle$1(body).direction === 'rtl') {\n x += max(html.clientWidth, body.clientWidth) - width;\n }\n return {\n width,\n height,\n x,\n y\n };\n}\n\n// Safety check: ensure the scrollbar space is reasonable in case this\n// calculation is affected by unusual styles.\n// Most scrollbars leave 15-18px of space.\nconst SCROLLBAR_MAX = 25;\nfunction getViewportRect(element, strategy) {\n const win = getWindow(element);\n const html = getDocumentElement(element);\n const visualViewport = win.visualViewport;\n let width = html.clientWidth;\n let height = html.clientHeight;\n let x = 0;\n let y = 0;\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n const visualViewportBased = isWebKit();\n if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n const windowScrollbarX = getWindowScrollBarX(html);\n // <html> `overflow: hidden` + `scrollbar-gutter: stable` reduces the\n // visual width of the <html> but this is not considered in the size\n // of `html.clientWidth`.\n if (windowScrollbarX <= 0) {\n const doc = html.ownerDocument;\n const body = doc.body;\n const bodyStyles = getComputedStyle(body);\n const bodyMarginInline = doc.compatMode === 'CSS1Compat' ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;\n const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);\n if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {\n width -= clippingStableScrollbarWidth;\n }\n } else if (windowScrollbarX <= SCROLLBAR_MAX) {\n // If the <body> scrollbar is on the left, the width needs to be extended\n // by the scrollbar amount so there isn't extra space on the right.\n width += windowScrollbarX;\n }\n return {\n width,\n height,\n x,\n y\n };\n}\n\nconst absoluteOrFixed = /*#__PURE__*/new Set(['absolute', 'fixed']);\n// Returns the inner client rect, subtracting scrollbars if present.\nfunction getInnerBoundingClientRect(element, strategy) {\n const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');\n const top = clientRect.top + element.clientTop;\n const left = clientRect.left + element.clientLeft;\n const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);\n const width = element.clientWidth * scale.x;\n const height = element.clientHeight * scale.y;\n const x = left * scale.x;\n const y = top * scale.y;\n return {\n width,\n height,\n x,\n y\n };\n}\nfunction getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {\n let rect;\n if (clippingAncestor === 'viewport') {\n rect = getViewportRect(element, strategy);\n } else if (clippingAncestor === 'document') {\n rect = getDocumentRect(getDocumentElement(element));\n } else if (isElement(clippingAncestor)) {\n rect = getInnerBoundingClientRect(clippingAncestor, strategy);\n } else {\n const visualOffsets = getVisualOffsets(element);\n rect = {\n x: clippingAncestor.x - visualOffsets.x,\n y: clippingAncestor.y - visualOffsets.y,\n width: clippingAncestor.width,\n height: clippingAncestor.height\n };\n }\n return rectToClientRect(rect);\n}\nfunction hasFixedPositionAncestor(element, stopNode) {\n const parentNode = getParentNode(element);\n if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {\n return false;\n }\n return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);\n}\n\n// A \"clipping ancestor\" is an `overflow` element with the characteristic of\n// clipping (or hiding) child elements. This returns all clipping ancestors\n// of the given element up the tree.\nfunction getClippingElementAncestors(element, cache) {\n const cachedResult = cache.get(element);\n if (cachedResult) {\n return cachedResult;\n }\n let result = getOverflowAncestors(element, [], false).filter(el => isElement(el) && getNodeName(el) !== 'body');\n let currentContainingBlockComputedStyle = null;\n const elementIsFixed = getComputedStyle$1(element).position === 'fixed';\n let currentNode = elementIsFixed ? getParentNode(element) : element;\n\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {\n const computedStyle = getComputedStyle$1(currentNode);\n const currentNodeIsContaining = isContainingBlock(currentNode);\n if (!currentNodeIsContaining && computedStyle.position === 'fixed') {\n currentContainingBlockComputedStyle = null;\n }\n const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);\n if (shouldDropCurrentNode) {\n // Drop non-containing blocks.\n result = result.filter(ancestor => ancestor !== currentNode);\n } else {\n // Record last containing block for next iteration.\n currentContainingBlockComputedStyle = computedStyle;\n }\n currentNode = getParentNode(currentNode);\n }\n cache.set(element, result);\n return result;\n}\n\n// Gets the maximum area that the element is visible in due to any number of\n// clipping ancestors.\nfunction getClippingRect(_ref) {\n let {\n element,\n boundary,\n rootBoundary,\n strategy\n } = _ref;\n const elementClippingAncestors = boundary === 'clippingAncestors' ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);\n const clippingAncestors = [...elementClippingAncestors, rootBoundary];\n const firstClippingAncestor = clippingAncestors[0];\n const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {\n const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));\n return {\n width: clippingRect.right - clippingRect.left,\n height: clippingRect.bottom - clippingRect.top,\n x: clippingRect.left,\n y: clippingRect.top\n };\n}\n\nfunction getDimensions(element) {\n const {\n width,\n height\n } = getCssDimensions(element);\n return {\n width,\n height\n };\n}\n\nfunction getRectRelativeToOffsetParent(element, offsetParent, strategy) {\n const isOffsetParentAnElement = isHTMLElement(offsetParent);\n const documentElement = getDocumentElement(offsetParent);\n const isFixed = strategy === 'fixed';\n const rect = getBoundingClientRect(element, true, isFixed, offsetParent);\n let scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n const offsets = createCoords(0);\n\n // If the <body> scrollbar appears on the left (e.g. RTL systems). Use\n // Firefox with layout.scrollbar.side = 3 in about:config to test this.\n function setLeftRTLScrollbarOffset() {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n if (isOffsetParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);\n offsets.x = offsetRect.x + offsetParent.clientLeft;\n offsets.y = offsetRect.y + offsetParent.clientTop;\n } else if (documentElement) {\n setLeftRTLScrollbarOffset();\n }\n }\n if (isFixed && !isOffsetParentAnElement && documentElement) {\n setLeftRTLScrollbarOffset();\n }\n const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);\n const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;\n const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;\n return {\n x,\n y,\n width: rect.width,\n height: rect.height\n };\n}\n\nfunction isStaticPositioned(element) {\n return getComputedStyle$1(element).position === 'static';\n}\n\nfunction getTrueOffsetParent(element, polyfill) {\n if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {\n return null;\n }\n if (polyfill) {\n return polyfill(element);\n }\n let rawOffsetParent = element.offsetParent;\n\n // Firefox returns the <html> element as the offsetParent if it's non-static,\n // while Chrome and Safari return the <body> element. The <body> element must\n // be used to perform the correct calculations even if the <html> element is\n // non-static.\n if (getDocumentElement(element) === rawOffsetParent) {\n rawOffsetParent = rawOffsetParent.ownerDocument.body;\n }\n return rawOffsetParent;\n}\n\n// Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\nfunction getOffsetParent(element, polyfill) {\n const win = getWindow(element);\n if (isTopLayer(element)) {\n return win;\n }\n if (!isHTMLElement(element)) {\n let svgOffsetParent = getParentNode(element);\n while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {\n if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {\n return svgOffsetParent;\n }\n svgOffsetParent = getParentNode(svgOffsetParent);\n }\n return win;\n }\n let offsetParent = getTrueOffsetParent(element, polyfill);\n while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {\n offsetParent = getTrueOffsetParent(offsetParent, polyfill);\n }\n if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {\n return win;\n }\n return offsetParent || getContainingBlock(element) || win;\n}\n\nconst getElementRects = async function (data) {\n const getOffsetParentFn = this.getOffsetParent || getOffsetParent;\n const getDimensionsFn = this.getDimensions;\n const floatingDimensions = await getDimensionsFn(data.floating);\n return {\n reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),\n floating: {\n x: 0,\n y: 0,\n width: floatingDimensions.width,\n height: floatingDimensions.height\n }\n };\n};\n\nfunction isRTL(element) {\n return getComputedStyle$1(element).direction === 'rtl';\n}\n\nconst platform = {\n convertOffsetParentRelativeRectToViewportRelativeRect,\n getDocumentElement,\n getClippingRect,\n getOffsetParent,\n getElementRects,\n getClientRects,\n getDimensions,\n getScale,\n isElement,\n isRTL\n};\n\nfunction rectsAreEqual(a, b) {\n return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;\n}\n\n// https://samthor.au/2021/observing-dom/\nfunction observeMove(element, onMove) {\n let io = null;\n let timeoutId;\n const root = getDocumentElement(element);\n function cleanup() {\n var _io;\n clearTimeout(timeoutId);\n (_io = io) == null || _io.disconnect();\n io = null;\n }\n function refresh(skip, threshold) {\n if (skip === void 0) {\n skip = false;\n }\n if (threshold === void 0) {\n threshold = 1;\n }\n cleanup();\n const elementRectForRootMargin = element.getBoundingClientRect();\n const {\n left,\n top,\n width,\n height\n } = elementRectForRootMargin;\n if (!skip) {\n onMove();\n }\n if (!width || !height) {\n return;\n }\n const insetTop = floor(top);\n const insetRight = floor(root.clientWidth - (left + width));\n const insetBottom = floor(root.clientHeight - (top + height));\n const insetLeft = floor(left);\n const rootMargin = -insetTop + \"px \" + -insetRight + \"px \" + -insetBottom + \"px \" + -insetLeft + \"px\";\n const options = {\n rootMargin,\n threshold: max(0, min(1, threshold)) || 1\n };\n let isFirstUpdate = true;\n function handleObserve(entries) {\n const ratio = entries[0].intersectionRatio;\n if (ratio !== threshold) {\n if (!isFirstUpdate) {\n return refresh();\n }\n if (!ratio) {\n // If the reference is clipped, the ratio is 0. Throttle the refresh\n // to prevent an infinite loop of updates.\n timeoutId = setTimeout(() => {\n refresh(false, 1e-7);\n }, 1000);\n } else {\n refresh(false, ratio);\n }\n }\n if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {\n // It's possible that even though the ratio is reported as 1, the\n // element is not actually fully within the IntersectionObserver's root\n // area anymore. This can happen under performance constraints. This may\n // be a bug in the browser's IntersectionObserver implementation. To\n // work around this, we compare the element's bounding rect now with\n // what it was at the time we created the IntersectionObserver. If they\n // are not equal then the element moved, so we refresh.\n refresh();\n }\n isFirstUpdate = false;\n }\n\n // Older browsers don't support a `document` as the root and will throw an\n // error.\n try {\n io = new IntersectionObserver(handleObserve, {\n ...options,\n // Handle <iframe>s\n root: root.ownerDocument\n });\n } catch (_e) {\n io = new IntersectionObserver(handleObserve, options);\n }\n io.observe(element);\n }\n refresh(true);\n return cleanup;\n}\n\n/**\n * Automatically updates the position of the floating element when necessary.\n * Should only be called when the floating element is mounted on the DOM or\n * visible on the screen.\n * @returns cleanup function that should be invoked when the floating element is\n * removed from the DOM or hidden from the screen.\n * @see https://floating-ui.com/docs/autoUpdate\n */\nfunction autoUpdate(reference, floating, update, options) {\n if (options === void 0) {\n options = {};\n }\n const {\n ancestorScroll = true,\n ancestorResize = true,\n elementResize = typeof ResizeObserver === 'function',\n layoutShift = typeof IntersectionObserver === 'function',\n animationFrame = false\n } = options;\n const referenceEl = unwrapElement(reference);\n const ancestors = ancestorScroll || ancestorResize ? [...(referenceEl ? getOverflowAncestors(referenceEl) : []), ...getOverflowAncestors(floating)] : [];\n ancestors.forEach(ancestor => {\n ancestorScroll && ancestor.addEventListener('scroll', update, {\n passive: true\n });\n ancestorResize && ancestor.addEventListener('resize', update);\n });\n const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update) : null;\n let reobserveFrame = -1;\n let resizeObserver = null;\n if (elementResize) {\n resizeObserver = new ResizeObserver(_ref => {\n let [firstEntry] = _ref;\n if (firstEntry && firstEntry.target === referenceEl && resizeObserver) {\n // Prevent update loops when using the `size` middleware.\n // https://github.com/floating-ui/floating-ui/issues/1740\n resizeObserver.unobserve(floating);\n cancelAnimationFrame(reobserveFrame);\n reobserveFrame = requestAnimationFrame(() => {\n var _resizeObserver;\n (_resizeObserver = resizeObserver) == null || _resizeObserver.observe(floating);\n });\n }\n update();\n });\n if (referenceEl && !animationFrame) {\n resizeObserver.observe(referenceEl);\n }\n resizeObserver.observe(floating);\n }\n let frameId;\n let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;\n if (animationFrame) {\n frameLoop();\n }\n function frameLoop() {\n const nextRefRect = getBoundingClientRect(reference);\n if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) {\n update();\n }\n prevRefRect = nextRefRect;\n frameId = requestAnimationFrame(frameLoop);\n }\n update();\n return () => {\n var _resizeObserver2;\n ancestors.forEach(ancestor => {\n ancestorScroll && ancestor.removeEventListener('scroll', update);\n ancestorResize && ancestor.removeEventListener('resize', update);\n });\n cleanupIo == null || cleanupIo();\n (_resizeObserver2 = resizeObserver) == null || _resizeObserver2.disconnect();\n resizeObserver = null;\n if (animationFrame) {\n cancelAnimationFrame(frameId);\n }\n };\n}\n\n/**\n * Resolves with an object of overflow side offsets that determine how much the\n * element is overflowing a given clipping boundary on each side.\n * - positive = overflowing the boundary by that number of pixels\n * - negative = how many pixels left before it will overflow\n * - 0 = lies flush with the boundary\n * @see https://floating-ui.com/docs/detectOverflow\n */\nconst detectOverflow = detectOverflow$1;\n\n/**\n * Modifies the placement by translating the floating element along the\n * specified axes.\n * A number (shorthand for `mainAxis` or distance), or an axes configuration\n * object may be passed.\n * @see https://floating-ui.com/docs/offset\n */\nconst offset = offset$1;\n\n/**\n * Optimizes the visibility of the floating element by choosing the placement\n * that has the most space available automatically, without needing to specify a\n * preferred placement. Alternative to `flip`.\n * @see https://floating-ui.com/docs/autoPlacement\n */\nconst autoPlacement = autoPlacement$1;\n\n/**\n * Optimizes the visibility of the floating element by shifting it in order to\n * keep it in view when it will overflow the clipping boundary.\n * @see https://floating-ui.com/docs/shift\n */\nconst shift = shift$1;\n\n/**\n * Optimizes the visibility of the floating element by flipping the `placement`\n * in order to keep it in view when the preferred placement(s) will overflow the\n * clipping boundary. Alternative to `autoPlacement`.\n * @see https://floating-ui.com/docs/flip\n */\nconst flip = flip$1;\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = size$1;\n\n/**\n * Provides data to hide the floating element in applicable situations, such as\n * when it is not in the same clipping context as the reference element.\n * @see https://floating-ui.com/docs/hide\n */\nconst hide = hide$1;\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = arrow$1;\n\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = inline$1;\n\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = limitShift$1;\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a given reference element.\n */\nconst computePosition = (reference, floating, options) => {\n // This caches the expensive `getClippingElementAncestors` function so that\n // multiple lifecycle resets re-use the same result. It only lives for a\n // single call. If other functions become expensive, we can add them as well.\n const cache = new Map();\n const mergedOptions = {\n platform,\n ...options\n };\n const platformWithCache = {\n ...mergedOptions.platform,\n _c: cache\n };\n return computePosition$1(reference, floating, {\n ...mergedOptions,\n platform: platformWithCache\n });\n};\n\nexport { arrow, autoPlacement, autoUpdate, computePosition, detectOverflow, flip, hide, inline, limitShift, offset, platform, shift, size };\n","import { computePosition, arrow as arrow$2, autoPlacement as autoPlacement$1, flip as flip$1, hide as hide$1, inline as inline$1, limitShift as limitShift$1, offset as offset$1, shift as shift$1, size as size$1 } from '@floating-ui/dom';\nexport { autoUpdate, computePosition, detectOverflow, getOverflowAncestors, platform } from '@floating-ui/dom';\nimport * as React from 'react';\nimport { useLayoutEffect } from 'react';\nimport * as ReactDOM from 'react-dom';\n\nvar isClient = typeof document !== 'undefined';\n\nvar noop = function noop() {};\nvar index = isClient ? useLayoutEffect : noop;\n\n// Fork of `fast-deep-equal` that only does the comparisons we need and compares\n// functions\nfunction deepEqual(a, b) {\n if (a === b) {\n return true;\n }\n if (typeof a !== typeof b) {\n return false;\n }\n if (typeof a === 'function' && a.toString() === b.toString()) {\n return true;\n }\n let length;\n let i;\n let keys;\n if (a && b && typeof a === 'object') {\n if (Array.isArray(a)) {\n length = a.length;\n if (length !== b.length) return false;\n for (i = length; i-- !== 0;) {\n if (!deepEqual(a[i], b[i])) {\n return false;\n }\n }\n return true;\n }\n keys = Object.keys(a);\n length = keys.length;\n if (length !== Object.keys(b).length) {\n return false;\n }\n for (i = length; i-- !== 0;) {\n if (!{}.hasOwnProperty.call(b, keys[i])) {\n return false;\n }\n }\n for (i = length; i-- !== 0;) {\n const key = keys[i];\n if (key === '_owner' && a.$$typeof) {\n continue;\n }\n if (!deepEqual(a[key], b[key])) {\n return false;\n }\n }\n return true;\n }\n return a !== a && b !== b;\n}\n\nfunction getDPR(element) {\n if (typeof window === 'undefined') {\n return 1;\n }\n const win = element.ownerDocument.defaultView || window;\n return win.devicePixelRatio || 1;\n}\n\nfunction roundByDPR(element, value) {\n const dpr = getDPR(element);\n return Math.round(value * dpr) / dpr;\n}\n\nfunction useLatestRef(value) {\n const ref = React.useRef(value);\n index(() => {\n ref.current = value;\n });\n return ref;\n}\n\n/**\n * Provides data to position a floating element.\n * @see https://floating-ui.com/docs/useFloating\n */\nfunction useFloating(options) {\n if (options === void 0) {\n options = {};\n }\n const {\n placement = 'bottom',\n strategy = 'absolute',\n middleware = [],\n platform,\n elements: {\n reference: externalReference,\n floating: externalFloating\n } = {},\n transform = true,\n whileElementsMounted,\n open\n } = options;\n const [data, setData] = React.useState({\n x: 0,\n y: 0,\n strategy,\n placement,\n middlewareData: {},\n isPositioned: false\n });\n const [latestMiddleware, setLatestMiddleware] = React.useState(middleware);\n if (!deepEqual(latestMiddleware, middleware)) {\n setLatestMiddleware(middleware);\n }\n const [_reference, _setReference] = React.useState(null);\n const [_floating, _setFloating] = React.useState(null);\n const setReference = React.useCallback(node => {\n if (node !== referenceRef.current) {\n referenceRef.current = node;\n _setReference(node);\n }\n }, []);\n const setFloating = React.useCallback(node => {\n if (node !== floatingRef.current) {\n floatingRef.current = node;\n _setFloating(node);\n }\n }, []);\n const referenceEl = externalReference || _reference;\n const floatingEl = externalFloating || _floating;\n const referenceRef = React.useRef(null);\n const floatingRef = React.useRef(null);\n const dataRef = React.useRef(data);\n const hasWhileElementsMounted = whileElementsMounted != null;\n const whileElementsMountedRef = useLatestRef(whileElementsMounted);\n const platformRef = useLatestRef(platform);\n const openRef = useLatestRef(open);\n const update = React.useCallback(() => {\n if (!referenceRef.current || !floatingRef.current) {\n return;\n }\n const config = {\n placement,\n strategy,\n middleware: latestMiddleware\n };\n if (platformRef.current) {\n config.platform = platformRef.current;\n }\n computePosition(referenceRef.current, floatingRef.current, config).then(data => {\n const fullData = {\n ...data,\n // The floating element's position may be recomputed while it's closed\n // but still mounted (such as when transitioning out). To ensure\n // `isPositioned` will be `false` initially on the next open, avoid\n // setting it to `true` when `open === false` (must be specified).\n isPositioned: openRef.current !== false\n };\n if (isMountedRef.current && !deepEqual(dataRef.current, fullData)) {\n dataRef.current = fullData;\n ReactDOM.flushSync(() => {\n setData(fullData);\n });\n }\n });\n }, [latestMiddleware, placement, strategy, platformRef, openRef]);\n index(() => {\n if (open === false && dataRef.current.isPositioned) {\n dataRef.current.isPositioned = false;\n setData(data => ({\n ...data,\n isPositioned: false\n }));\n }\n }, [open]);\n const isMountedRef = React.useRef(false);\n index(() => {\n isMountedRef.current = true;\n return () => {\n isMountedRef.current = false;\n };\n }, []);\n index(() => {\n if (referenceEl) referenceRef.current = referenceEl;\n if (floatingEl) floatingRef.current = floatingEl;\n if (referenceEl && floatingEl) {\n if (whileElementsMountedRef.current) {\n return whileElementsMountedRef.current(referenceEl, floatingEl, update);\n }\n update();\n }\n }, [referenceEl, floatingEl, update, whileElementsMountedRef, hasWhileElementsMounted]);\n const refs = React.useMemo(() => ({\n reference: referenceRef,\n floating: floatingRef,\n setReference,\n setFloating\n }), [setReference, setFloating]);\n const elements = React.useMemo(() => ({\n reference: referenceEl,\n floating: floatingEl\n }), [referenceEl, floatingEl]);\n const floatingStyles = React.useMemo(() => {\n const initialStyles = {\n position: strategy,\n left: 0,\n top: 0\n };\n if (!elements.floating) {\n return initialStyles;\n }\n const x = roundByDPR(elements.floating, data.x);\n const y = roundByDPR(elements.floating, data.y);\n if (transform) {\n return {\n ...initialStyles,\n transform: \"translate(\" + x + \"px, \" + y + \"px)\",\n ...(getDPR(elements.floating) >= 1.5 && {\n willChange: 'transform'\n })\n };\n }\n return {\n position: strategy,\n left: x,\n top: y\n };\n }, [strategy, transform, elements.floating, data.x, data.y]);\n return React.useMemo(() => ({\n ...data,\n update,\n refs,\n elements,\n floatingStyles\n }), [data, update, refs, elements, floatingStyles]);\n}\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * This wraps the core `arrow` middleware to allow React refs as the element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow$1 = options => {\n function isRef(value) {\n return {}.hasOwnProperty.call(value, 'current');\n }\n return {\n name: 'arrow',\n options,\n fn(state) {\n const {\n element,\n padding\n } = typeof options === 'function' ? options(state) : options;\n if (element && isRef(element)) {\n if (element.current != null) {\n return arrow$2({\n element: element.current,\n padding\n }).fn(state);\n }\n return {};\n }\n if (element) {\n return arrow$2({\n element,\n padding\n }).fn(state);\n }\n return {};\n }\n };\n};\n\n/**\n * Modifies the placement by translating the floating element along the\n * specified axes.\n * A number (shorthand for `mainAxis` or distance), or an axes configuration\n * object may be passed.\n * @see https://floating-ui.com/docs/offset\n */\nconst offset = (options, deps) => ({\n ...offset$1(options),\n options: [options, deps]\n});\n\n/**\n * Optimizes the visibility of the floating element by shifting it in order to\n * keep it in view when it will overflow the clipping boundary.\n * @see https://floating-ui.com/docs/shift\n */\nconst shift = (options, deps) => ({\n ...shift$1(options),\n options: [options, deps]\n});\n\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = (options, deps) => ({\n ...limitShift$1(options),\n options: [options, deps]\n});\n\n/**\n * Optimizes the visibility of the floating element by flipping the `placement`\n * in order to keep it in view when the preferred placement(s) will overflow the\n * clipping boundary. Alternative to `autoPlacement`.\n * @see https://floating-ui.com/docs/flip\n */\nconst flip = (options, deps) => ({\n ...flip$1(options),\n options: [options, deps]\n});\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = (options, deps) => ({\n ...size$1(options),\n options: [options, deps]\n});\n\n/**\n * Optimizes the visibility of the floating element by choosing the placement\n * that has the most space available automatically, without needing to specify a\n * preferred placement. Alternative to `flip`.\n * @see https://floating-ui.com/docs/autoPlacement\n */\nconst autoPlacement = (options, deps) => ({\n ...autoPlacement$1(options),\n options: [options, deps]\n});\n\n/**\n * Provides data to hide the floating element in applicable situations, such as\n * when it is not in the same clipping context as the reference element.\n * @see https://floating-ui.com/docs/hide\n */\nconst hide = (options, deps) => ({\n ...hide$1(options),\n options: [options, deps]\n});\n\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = (options, deps) => ({\n ...inline$1(options),\n options: [options, deps]\n});\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * This wraps the core `arrow` middleware to allow React refs as the element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = (options, deps) => ({\n ...arrow$1(options),\n options: [options, deps]\n});\n\nexport { arrow, autoPlacement, flip, hide, inline, limitShift, offset, shift, size, useFloating };\n","// src/arrow.tsx\nimport * as React from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { jsx } from \"react/jsx-runtime\";\nvar NAME = \"Arrow\";\nvar Arrow = React.forwardRef((props, forwardedRef) => {\n const { children, width = 10, height = 5, ...arrowProps } = props;\n return /* @__PURE__ */ jsx(\n Primitive.svg,\n {\n ...arrowProps,\n ref: forwardedRef,\n width,\n height,\n viewBox: \"0 0 30 10\",\n preserveAspectRatio: \"none\",\n children: props.asChild ? children : /* @__PURE__ */ jsx(\"polygon\", { points: \"0,0 30,0 15,10\" })\n }\n );\n});\nArrow.displayName = NAME;\nvar Root = Arrow;\nexport {\n Arrow,\n Root\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/use-size/src/use-size.tsx\nimport * as React from \"react\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nfunction useSize(element) {\n const [size, setSize] = React.useState(void 0);\n useLayoutEffect(() => {\n if (element) {\n setSize({ width: element.offsetWidth, height: element.offsetHeight });\n const resizeObserver = new ResizeObserver((entries) => {\n if (!Array.isArray(entries)) {\n return;\n }\n if (!entries.length) {\n return;\n }\n const entry = entries[0];\n let width;\n let height;\n if (\"borderBoxSize\" in entry) {\n const borderSizeEntry = entry[\"borderBoxSize\"];\n const borderSize = Array.isArray(borderSizeEntry) ? borderSizeEntry[0] : borderSizeEntry;\n width = borderSize[\"inlineSize\"];\n height = borderSize[\"blockSize\"];\n } else {\n width = element.offsetWidth;\n height = element.offsetHeight;\n }\n setSize({ width, height });\n });\n resizeObserver.observe(element, { box: \"border-box\" });\n return () => resizeObserver.unobserve(element);\n } else {\n setSize(void 0);\n }\n }, [element]);\n return size;\n}\nexport {\n useSize\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/popper.tsx\nimport * as React from \"react\";\nimport {\n useFloating,\n autoUpdate,\n offset,\n shift,\n limitShift,\n hide,\n arrow as floatingUIarrow,\n flip,\n size\n} from \"@floating-ui/react-dom\";\nimport * as ArrowPrimitive from \"@radix-ui/react-arrow\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nimport { useSize } from \"@radix-ui/react-use-size\";\nimport { jsx } from \"react/jsx-runtime\";\nvar SIDE_OPTIONS = [\"top\", \"right\", \"bottom\", \"left\"];\nvar ALIGN_OPTIONS = [\"start\", \"center\", \"end\"];\nvar POPPER_NAME = \"Popper\";\nvar [createPopperContext, createPopperScope] = createContextScope(POPPER_NAME);\nvar [PopperProvider, usePopperContext] = createPopperContext(POPPER_NAME);\nvar Popper = (props) => {\n const { __scopePopper, children } = props;\n const [anchor, setAnchor] = React.useState(null);\n return /* @__PURE__ */ jsx(PopperProvider, { scope: __scopePopper, anchor, onAnchorChange: setAnchor, children });\n};\nPopper.displayName = POPPER_NAME;\nvar ANCHOR_NAME = \"PopperAnchor\";\nvar PopperAnchor = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopePopper, virtualRef, ...anchorProps } = props;\n const context = usePopperContext(ANCHOR_NAME, __scopePopper);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const anchorRef = React.useRef(null);\n React.useEffect(() => {\n const previousAnchor = anchorRef.current;\n anchorRef.current = virtualRef?.current || ref.current;\n if (previousAnchor !== anchorRef.current) {\n context.onAnchorChange(anchorRef.current);\n }\n });\n return virtualRef ? null : /* @__PURE__ */ jsx(Primitive.div, { ...anchorProps, ref: composedRefs });\n }\n);\nPopperAnchor.displayName = ANCHOR_NAME;\nvar CONTENT_NAME = \"PopperContent\";\nvar [PopperContentProvider, useContentContext] = createPopperContext(CONTENT_NAME);\nvar PopperContent = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopePopper,\n side = \"bottom\",\n sideOffset = 0,\n align = \"center\",\n alignOffset = 0,\n arrowPadding = 0,\n avoidCollisions = true,\n collisionBoundary = [],\n collisionPadding: collisionPaddingProp = 0,\n sticky = \"partial\",\n hideWhenDetached = false,\n updatePositionStrategy = \"optimized\",\n onPlaced,\n ...contentProps\n } = props;\n const context = usePopperContext(CONTENT_NAME, __scopePopper);\n const [content, setContent] = React.useState(null);\n const composedRefs = useComposedRefs(forwardedRef, (node) => setContent(node));\n const [arrow, setArrow] = React.useState(null);\n const arrowSize = useSize(arrow);\n const arrowWidth = arrowSize?.width ?? 0;\n const arrowHeight = arrowSize?.height ?? 0;\n const desiredPlacement = side + (align !== \"center\" ? \"-\" + align : \"\");\n const collisionPadding = typeof collisionPaddingProp === \"number\" ? collisionPaddingProp : { top: 0, right: 0, bottom: 0, left: 0, ...collisionPaddingProp };\n const boundary = Array.isArray(collisionBoundary) ? collisionBoundary : [collisionBoundary];\n const hasExplicitBoundaries = boundary.length > 0;\n const detectOverflowOptions = {\n padding: collisionPadding,\n boundary: boundary.filter(isNotNull),\n // with `strategy: 'fixed'`, this is the only way to get it to respect boundaries\n altBoundary: hasExplicitBoundaries\n };\n const { refs, floatingStyles, placement, isPositioned, middlewareData } = useFloating({\n // default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues\n strategy: \"fixed\",\n placement: desiredPlacement,\n whileElementsMounted: (...args) => {\n const cleanup = autoUpdate(...args, {\n animationFrame: updatePositionStrategy === \"always\"\n });\n return cleanup;\n },\n elements: {\n reference: context.anchor\n },\n middleware: [\n offset({ mainAxis: sideOffset + arrowHeight, alignmentAxis: alignOffset }),\n avoidCollisions && shift({\n mainAxis: true,\n crossAxis: false,\n limiter: sticky === \"partial\" ? limitShift() : void 0,\n ...detectOverflowOptions\n }),\n avoidCollisions && flip({ ...detectOverflowOptions }),\n size({\n ...detectOverflowOptions,\n apply: ({ elements, rects, availableWidth, availableHeight }) => {\n const { width: anchorWidth, height: anchorHeight } = rects.reference;\n const contentStyle = elements.floating.style;\n contentStyle.setProperty(\"--radix-popper-available-width\", `${availableWidth}px`);\n contentStyle.setProperty(\"--radix-popper-available-height\", `${availableHeight}px`);\n contentStyle.setProperty(\"--radix-popper-anchor-width\", `${anchorWidth}px`);\n contentStyle.setProperty(\"--radix-popper-anchor-height\", `${anchorHeight}px`);\n }\n }),\n arrow && floatingUIarrow({ element: arrow, padding: arrowPadding }),\n transformOrigin({ arrowWidth, arrowHeight }),\n hideWhenDetached && hide({ strategy: \"referenceHidden\", ...detectOverflowOptions })\n ]\n });\n const [placedSide, placedAlign] = getSideAndAlignFromPlacement(placement);\n const handlePlaced = useCallbackRef(onPlaced);\n useLayoutEffect(() => {\n if (isPositioned) {\n handlePlaced?.();\n }\n }, [isPositioned, handlePlaced]);\n const arrowX = middlewareData.arrow?.x;\n const arrowY = middlewareData.arrow?.y;\n const cannotCenterArrow = middlewareData.arrow?.centerOffset !== 0;\n const [contentZIndex, setContentZIndex] = React.useState();\n useLayoutEffect(() => {\n if (content) setContentZIndex(window.getComputedStyle(content).zIndex);\n }, [content]);\n return /* @__PURE__ */ jsx(\n \"div\",\n {\n ref: refs.setFloating,\n \"data-radix-popper-content-wrapper\": \"\",\n style: {\n ...floatingStyles,\n transform: isPositioned ? floatingStyles.transform : \"translate(0, -200%)\",\n // keep off the page when measuring\n minWidth: \"max-content\",\n zIndex: contentZIndex,\n [\"--radix-popper-transform-origin\"]: [\n middlewareData.transformOrigin?.x,\n middlewareData.transformOrigin?.y\n ].join(\" \"),\n // hide the content if using the hide middleware and should be hidden\n // set visibility to hidden and disable pointer events so the UI behaves\n // as if the PopperContent isn't there at all\n ...middlewareData.hide?.referenceHidden && {\n visibility: \"hidden\",\n pointerEvents: \"none\"\n }\n },\n dir: props.dir,\n children: /* @__PURE__ */ jsx(\n PopperContentProvider,\n {\n scope: __scopePopper,\n placedSide,\n onArrowChange: setArrow,\n arrowX,\n arrowY,\n shouldHideArrow: cannotCenterArrow,\n children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n \"data-side\": placedSide,\n \"data-align\": placedAlign,\n ...contentProps,\n ref: composedRefs,\n style: {\n ...contentProps.style,\n // if the PopperContent hasn't been placed yet (not all measurements done)\n // we prevent animations so that users's animation don't kick in too early referring wrong sides\n animation: !isPositioned ? \"none\" : void 0\n }\n }\n )\n }\n )\n }\n );\n }\n);\nPopperContent.displayName = CONTENT_NAME;\nvar ARROW_NAME = \"PopperArrow\";\nvar OPPOSITE_SIDE = {\n top: \"bottom\",\n right: \"left\",\n bottom: \"top\",\n left: \"right\"\n};\nvar PopperArrow = React.forwardRef(function PopperArrow2(props, forwardedRef) {\n const { __scopePopper, ...arrowProps } = props;\n const contentContext = useContentContext(ARROW_NAME, __scopePopper);\n const baseSide = OPPOSITE_SIDE[contentContext.placedSide];\n return (\n // we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)\n // doesn't report size as we'd expect on SVG elements.\n // it reports their bounding box which is effectively the largest path inside the SVG.\n /* @__PURE__ */ jsx(\n \"span\",\n {\n ref: contentContext.onArrowChange,\n style: {\n position: \"absolute\",\n left: contentContext.arrowX,\n top: contentContext.arrowY,\n [baseSide]: 0,\n transformOrigin: {\n top: \"\",\n right: \"0 0\",\n bottom: \"center 0\",\n left: \"100% 0\"\n }[contentContext.placedSide],\n transform: {\n top: \"translateY(100%)\",\n right: \"translateY(50%) rotate(90deg) translateX(-50%)\",\n bottom: `rotate(180deg)`,\n left: \"translateY(50%) rotate(-90deg) translateX(50%)\"\n }[contentContext.placedSide],\n visibility: contentContext.shouldHideArrow ? \"hidden\" : void 0\n },\n children: /* @__PURE__ */ jsx(\n ArrowPrimitive.Root,\n {\n ...arrowProps,\n ref: forwardedRef,\n style: {\n ...arrowProps.style,\n // ensures the element can be measured correctly (mostly for if SVG)\n display: \"block\"\n }\n }\n )\n }\n )\n );\n});\nPopperArrow.displayName = ARROW_NAME;\nfunction isNotNull(value) {\n return value !== null;\n}\nvar transformOrigin = (options) => ({\n name: \"transformOrigin\",\n options,\n fn(data) {\n const { placement, rects, middlewareData } = data;\n const cannotCenterArrow = middlewareData.arrow?.centerOffset !== 0;\n const isArrowHidden = cannotCenterArrow;\n const arrowWidth = isArrowHidden ? 0 : options.arrowWidth;\n const arrowHeight = isArrowHidden ? 0 : options.arrowHeight;\n const [placedSide, placedAlign] = getSideAndAlignFromPlacement(placement);\n const noArrowAlign = { start: \"0%\", center: \"50%\", end: \"100%\" }[placedAlign];\n const arrowXCenter = (middlewareData.arrow?.x ?? 0) + arrowWidth / 2;\n const arrowYCenter = (middlewareData.arrow?.y ?? 0) + arrowHeight / 2;\n let x = \"\";\n let y = \"\";\n if (placedSide === \"bottom\") {\n x = isArrowHidden ? noArrowAlign : `${arrowXCenter}px`;\n y = `${-arrowHeight}px`;\n } else if (placedSide === \"top\") {\n x = isArrowHidden ? noArrowAlign : `${arrowXCenter}px`;\n y = `${rects.floating.height + arrowHeight}px`;\n } else if (placedSide === \"right\") {\n x = `${-arrowHeight}px`;\n y = isArrowHidden ? noArrowAlign : `${arrowYCenter}px`;\n } else if (placedSide === \"left\") {\n x = `${rects.floating.width + arrowHeight}px`;\n y = isArrowHidden ? noArrowAlign : `${arrowYCenter}px`;\n }\n return { data: { x, y } };\n }\n});\nfunction getSideAndAlignFromPlacement(placement) {\n const [side, align = \"center\"] = placement.split(\"-\");\n return [side, align];\n}\nvar Root2 = Popper;\nvar Anchor = PopperAnchor;\nvar Content = PopperContent;\nvar Arrow = PopperArrow;\nexport {\n ALIGN_OPTIONS,\n Anchor,\n Arrow,\n Content,\n Popper,\n PopperAnchor,\n PopperArrow,\n PopperContent,\n Root2 as Root,\n SIDE_OPTIONS,\n createPopperScope\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/portal.tsx\nimport * as React from \"react\";\nimport ReactDOM from \"react-dom\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nimport { jsx } from \"react/jsx-runtime\";\nvar PORTAL_NAME = \"Portal\";\nvar Portal = React.forwardRef((props, forwardedRef) => {\n const { container: containerProp, ...portalProps } = props;\n const [mounted, setMounted] = React.useState(false);\n useLayoutEffect(() => setMounted(true), []);\n const container = containerProp || mounted && globalThis?.document?.body;\n return container ? ReactDOM.createPortal(/* @__PURE__ */ jsx(Primitive.div, { ...portalProps, ref: forwardedRef }), container) : null;\n});\nPortal.displayName = PORTAL_NAME;\nvar Root = Portal;\nexport {\n Portal,\n Root\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/presence.tsx\nimport * as React2 from \"react\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\n\n// src/use-state-machine.tsx\nimport * as React from \"react\";\nfunction useStateMachine(initialState, machine) {\n return React.useReducer((state, event) => {\n const nextState = machine[state][event];\n return nextState ?? state;\n }, initialState);\n}\n\n// src/presence.tsx\nvar Presence = (props) => {\n const { present, children } = props;\n const presence = usePresence(present);\n const child = typeof children === \"function\" ? children({ present: presence.isPresent }) : React2.Children.only(children);\n const ref = useComposedRefs(presence.ref, getElementRef(child));\n const forceMount = typeof children === \"function\";\n return forceMount || presence.isPresent ? React2.cloneElement(child, { ref }) : null;\n};\nPresence.displayName = \"Presence\";\nfunction usePresence(present) {\n const [node, setNode] = React2.useState();\n const stylesRef = React2.useRef(null);\n const prevPresentRef = React2.useRef(present);\n const prevAnimationNameRef = React2.useRef(\"none\");\n const initialState = present ? \"mounted\" : \"unmounted\";\n const [state, send] = useStateMachine(initialState, {\n mounted: {\n UNMOUNT: \"unmounted\",\n ANIMATION_OUT: \"unmountSuspended\"\n },\n unmountSuspended: {\n MOUNT: \"mounted\",\n ANIMATION_END: \"unmounted\"\n },\n unmounted: {\n MOUNT: \"mounted\"\n }\n });\n React2.useEffect(() => {\n const currentAnimationName = getAnimationName(stylesRef.current);\n prevAnimationNameRef.current = state === \"mounted\" ? currentAnimationName : \"none\";\n }, [state]);\n useLayoutEffect(() => {\n const styles = stylesRef.current;\n const wasPresent = prevPresentRef.current;\n const hasPresentChanged = wasPresent !== present;\n if (hasPresentChanged) {\n const prevAnimationName = prevAnimationNameRef.current;\n const currentAnimationName = getAnimationName(styles);\n if (present) {\n send(\"MOUNT\");\n } else if (currentAnimationName === \"none\" || styles?.display === \"none\") {\n send(\"UNMOUNT\");\n } else {\n const isAnimating = prevAnimationName !== currentAnimationName;\n if (wasPresent && isAnimating) {\n send(\"ANIMATION_OUT\");\n } else {\n send(\"UNMOUNT\");\n }\n }\n prevPresentRef.current = present;\n }\n }, [present, send]);\n useLayoutEffect(() => {\n if (node) {\n let timeoutId;\n const ownerWindow = node.ownerDocument.defaultView ?? window;\n const handleAnimationEnd = (event) => {\n const currentAnimationName = getAnimationName(stylesRef.current);\n const isCurrentAnimation = currentAnimationName.includes(CSS.escape(event.animationName));\n if (event.target === node && isCurrentAnimation) {\n send(\"ANIMATION_END\");\n if (!prevPresentRef.current) {\n const currentFillMode = node.style.animationFillMode;\n node.style.animationFillMode = \"forwards\";\n timeoutId = ownerWindow.setTimeout(() => {\n if (node.style.animationFillMode === \"forwards\") {\n node.style.animationFillMode = currentFillMode;\n }\n });\n }\n }\n };\n const handleAnimationStart = (event) => {\n if (event.target === node) {\n prevAnimationNameRef.current = getAnimationName(stylesRef.current);\n }\n };\n node.addEventListener(\"animationstart\", handleAnimationStart);\n node.addEventListener(\"animationcancel\", handleAnimationEnd);\n node.addEventListener(\"animationend\", handleAnimationEnd);\n return () => {\n ownerWindow.clearTimeout(timeoutId);\n node.removeEventListener(\"animationstart\", handleAnimationStart);\n node.removeEventListener(\"animationcancel\", handleAnimationEnd);\n node.removeEventListener(\"animationend\", handleAnimationEnd);\n };\n } else {\n send(\"ANIMATION_END\");\n }\n }, [node, send]);\n return {\n isPresent: [\"mounted\", \"unmountSuspended\"].includes(state),\n ref: React2.useCallback((node2) => {\n stylesRef.current = node2 ? getComputedStyle(node2) : null;\n setNode(node2);\n }, [])\n };\n}\nfunction getAnimationName(styles) {\n return styles?.animationName || \"none\";\n}\nfunction getElementRef(element) {\n let getter = Object.getOwnPropertyDescriptor(element.props, \"ref\")?.get;\n let mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.ref;\n }\n getter = Object.getOwnPropertyDescriptor(element, \"ref\")?.get;\n mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.props.ref;\n }\n return element.props.ref || element.ref;\n}\nvar Root = Presence;\nexport {\n Presence,\n Root\n};\n//# sourceMappingURL=index.mjs.map\n","// src/use-controllable-state.tsx\nimport * as React from \"react\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nvar useInsertionEffect = React[\" useInsertionEffect \".trim().toString()] || useLayoutEffect;\nfunction useControllableState({\n prop,\n defaultProp,\n onChange = () => {\n },\n caller\n}) {\n const [uncontrolledProp, setUncontrolledProp, onChangeRef] = useUncontrolledState({\n defaultProp,\n onChange\n });\n const isControlled = prop !== void 0;\n const value = isControlled ? prop : uncontrolledProp;\n if (true) {\n const isControlledRef = React.useRef(prop !== void 0);\n React.useEffect(() => {\n const wasControlled = isControlledRef.current;\n if (wasControlled !== isControlled) {\n const from = wasControlled ? \"controlled\" : \"uncontrolled\";\n const to = isControlled ? \"controlled\" : \"uncontrolled\";\n console.warn(\n `${caller} is changing from ${from} to ${to}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`\n );\n }\n isControlledRef.current = isControlled;\n }, [isControlled, caller]);\n }\n const setValue = React.useCallback(\n (nextValue) => {\n if (isControlled) {\n const value2 = isFunction(nextValue) ? nextValue(prop) : nextValue;\n if (value2 !== prop) {\n onChangeRef.current?.(value2);\n }\n } else {\n setUncontrolledProp(nextValue);\n }\n },\n [isControlled, prop, setUncontrolledProp, onChangeRef]\n );\n return [value, setValue];\n}\nfunction useUncontrolledState({\n defaultProp,\n onChange\n}) {\n const [value, setValue] = React.useState(defaultProp);\n const prevValueRef = React.useRef(value);\n const onChangeRef = React.useRef(onChange);\n useInsertionEffect(() => {\n onChangeRef.current = onChange;\n }, [onChange]);\n React.useEffect(() => {\n if (prevValueRef.current !== value) {\n onChangeRef.current?.(value);\n prevValueRef.current = value;\n }\n }, [value, prevValueRef]);\n return [value, setValue, onChangeRef];\n}\nfunction isFunction(value) {\n return typeof value === \"function\";\n}\n\n// src/use-controllable-state-reducer.tsx\nimport * as React2 from \"react\";\nimport { useEffectEvent } from \"@radix-ui/react-use-effect-event\";\nvar SYNC_STATE = Symbol(\"RADIX:SYNC_STATE\");\nfunction useControllableStateReducer(reducer, userArgs, initialArg, init) {\n const { prop: controlledState, defaultProp, onChange: onChangeProp, caller } = userArgs;\n const isControlled = controlledState !== void 0;\n const onChange = useEffectEvent(onChangeProp);\n if (true) {\n const isControlledRef = React2.useRef(controlledState !== void 0);\n React2.useEffect(() => {\n const wasControlled = isControlledRef.current;\n if (wasControlled !== isControlled) {\n const from = wasControlled ? \"controlled\" : \"uncontrolled\";\n const to = isControlled ? \"controlled\" : \"uncontrolled\";\n console.warn(\n `${caller} is changing from ${from} to ${to}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`\n );\n }\n isControlledRef.current = isControlled;\n }, [isControlled, caller]);\n }\n const args = [{ ...initialArg, state: defaultProp }];\n if (init) {\n args.push(init);\n }\n const [internalState, dispatch] = React2.useReducer(\n (state2, action) => {\n if (action.type === SYNC_STATE) {\n return { ...state2, state: action.state };\n }\n const next = reducer(state2, action);\n if (isControlled && !Object.is(next.state, state2.state)) {\n onChange(next.state);\n }\n return next;\n },\n ...args\n );\n const uncontrolledState = internalState.state;\n const prevValueRef = React2.useRef(uncontrolledState);\n React2.useEffect(() => {\n if (prevValueRef.current !== uncontrolledState) {\n prevValueRef.current = uncontrolledState;\n if (!isControlled) {\n onChange(uncontrolledState);\n }\n }\n }, [onChange, uncontrolledState, prevValueRef, isControlled]);\n const state = React2.useMemo(() => {\n const isControlled2 = controlledState !== void 0;\n if (isControlled2) {\n return { ...internalState, state: controlledState };\n }\n return internalState;\n }, [internalState, controlledState]);\n React2.useEffect(() => {\n if (isControlled && !Object.is(controlledState, internalState.state)) {\n dispatch({ type: SYNC_STATE, state: controlledState });\n }\n }, [controlledState, internalState.state, isControlled]);\n return [state, dispatch];\n}\nexport {\n useControllableState,\n useControllableStateReducer\n};\n//# sourceMappingURL=index.mjs.map\n","var getDefaultParent = function (originalTarget) {\n if (typeof document === 'undefined') {\n return null;\n }\n var sampleTarget = Array.isArray(originalTarget) ? originalTarget[0] : originalTarget;\n return sampleTarget.ownerDocument.body;\n};\nvar counterMap = new WeakMap();\nvar uncontrolledNodes = new WeakMap();\nvar markerMap = {};\nvar lockCount = 0;\nvar unwrapHost = function (node) {\n return node && (node.host || unwrapHost(node.parentNode));\n};\nvar correctTargets = function (parent, targets) {\n return targets\n .map(function (target) {\n if (parent.contains(target)) {\n return target;\n }\n var correctedTarget = unwrapHost(target);\n if (correctedTarget && parent.contains(correctedTarget)) {\n return correctedTarget;\n }\n console.error('aria-hidden', target, 'in not contained inside', parent, '. Doing nothing');\n return null;\n })\n .filter(function (x) { return Boolean(x); });\n};\n/**\n * Marks everything except given node(or nodes) as aria-hidden\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @param {String} [controlAttribute] - html Attribute to control\n * @return {Undo} undo command\n */\nvar applyAttributeToOthers = function (originalTarget, parentNode, markerName, controlAttribute) {\n var targets = correctTargets(parentNode, Array.isArray(originalTarget) ? originalTarget : [originalTarget]);\n if (!markerMap[markerName]) {\n markerMap[markerName] = new WeakMap();\n }\n var markerCounter = markerMap[markerName];\n var hiddenNodes = [];\n var elementsToKeep = new Set();\n var elementsToStop = new Set(targets);\n var keep = function (el) {\n if (!el || elementsToKeep.has(el)) {\n return;\n }\n elementsToKeep.add(el);\n keep(el.parentNode);\n };\n targets.forEach(keep);\n var deep = function (parent) {\n if (!parent || elementsToStop.has(parent)) {\n return;\n }\n Array.prototype.forEach.call(parent.children, function (node) {\n if (elementsToKeep.has(node)) {\n deep(node);\n }\n else {\n try {\n var attr = node.getAttribute(controlAttribute);\n var alreadyHidden = attr !== null && attr !== 'false';\n var counterValue = (counterMap.get(node) || 0) + 1;\n var markerValue = (markerCounter.get(node) || 0) + 1;\n counterMap.set(node, counterValue);\n markerCounter.set(node, markerValue);\n hiddenNodes.push(node);\n if (counterValue === 1 && alreadyHidden) {\n uncontrolledNodes.set(node, true);\n }\n if (markerValue === 1) {\n node.setAttribute(markerName, 'true');\n }\n if (!alreadyHidden) {\n node.setAttribute(controlAttribute, 'true');\n }\n }\n catch (e) {\n console.error('aria-hidden: cannot operate on ', node, e);\n }\n }\n });\n };\n deep(parentNode);\n elementsToKeep.clear();\n lockCount++;\n return function () {\n hiddenNodes.forEach(function (node) {\n var counterValue = counterMap.get(node) - 1;\n var markerValue = markerCounter.get(node) - 1;\n counterMap.set(node, counterValue);\n markerCounter.set(node, markerValue);\n if (!counterValue) {\n if (!uncontrolledNodes.has(node)) {\n node.removeAttribute(controlAttribute);\n }\n uncontrolledNodes.delete(node);\n }\n if (!markerValue) {\n node.removeAttribute(markerName);\n }\n });\n lockCount--;\n if (!lockCount) {\n // clear\n counterMap = new WeakMap();\n counterMap = new WeakMap();\n uncontrolledNodes = new WeakMap();\n markerMap = {};\n }\n };\n};\n/**\n * Marks everything except given node(or nodes) as aria-hidden\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @return {Undo} undo command\n */\nexport var hideOthers = function (originalTarget, parentNode, markerName) {\n if (markerName === void 0) { markerName = 'data-aria-hidden'; }\n var targets = Array.from(Array.isArray(originalTarget) ? originalTarget : [originalTarget]);\n var activeParentNode = parentNode || getDefaultParent(originalTarget);\n if (!activeParentNode) {\n return function () { return null; };\n }\n // we should not hide aria-live elements - https://github.com/theKashey/aria-hidden/issues/10\n // and script elements, as they have no impact on accessibility.\n targets.push.apply(targets, Array.from(activeParentNode.querySelectorAll('[aria-live], script')));\n return applyAttributeToOthers(targets, activeParentNode, markerName, 'aria-hidden');\n};\n/**\n * Marks everything except given node(or nodes) as inert\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @return {Undo} undo command\n */\nexport var inertOthers = function (originalTarget, parentNode, markerName) {\n if (markerName === void 0) { markerName = 'data-inert-ed'; }\n var activeParentNode = parentNode || getDefaultParent(originalTarget);\n if (!activeParentNode) {\n return function () { return null; };\n }\n return applyAttributeToOthers(originalTarget, activeParentNode, markerName, 'inert');\n};\n/**\n * @returns if current browser supports inert\n */\nexport var supportsInert = function () {\n return typeof HTMLElement !== 'undefined' && HTMLElement.prototype.hasOwnProperty('inert');\n};\n/**\n * Automatic function to \"suppress\" DOM elements - _hide_ or _inert_ in the best possible way\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @return {Undo} undo command\n */\nexport var suppressOthers = function (originalTarget, parentNode, markerName) {\n if (markerName === void 0) { markerName = 'data-suppressed'; }\n return (supportsInert() ? inertOthers : hideOthers)(originalTarget, parentNode, markerName);\n};\n","/******************************************************************************\nCopyright (c) Microsoft Corporation.\n\nPermission to use, copy, modify, and/or distribute this software for any\npurpose with or without fee is hereby granted.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\nPERFORMANCE OF THIS SOFTWARE.\n***************************************************************************** */\n/* global Reflect, Promise, SuppressedError, Symbol, Iterator */\n\nvar extendStatics = function(d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n};\n\nexport function __extends(d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n}\n\nexport var __assign = function() {\n __assign = Object.assign || function __assign(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\n }\n return t;\n }\n return __assign.apply(this, arguments);\n}\n\nexport function __rest(s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\n t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\n t[p[i]] = s[p[i]];\n }\n return t;\n}\n\nexport function __decorate(decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n}\n\nexport function __param(paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n}\n\nexport function __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {\n function accept(f) { if (f !== void 0 && typeof f !== \"function\") throw new TypeError(\"Function expected\"); return f; }\n var kind = contextIn.kind, key = kind === \"getter\" ? \"get\" : kind === \"setter\" ? \"set\" : \"value\";\n var target = !descriptorIn && ctor ? contextIn[\"static\"] ? ctor : ctor.prototype : null;\n var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});\n var _, done = false;\n for (var i = decorators.length - 1; i >= 0; i--) {\n var context = {};\n for (var p in contextIn) context[p] = p === \"access\" ? {} : contextIn[p];\n for (var p in contextIn.access) context.access[p] = contextIn.access[p];\n context.addInitializer = function (f) { if (done) throw new TypeError(\"Cannot add initializers after decoration has completed\"); extraInitializers.push(accept(f || null)); };\n var result = (0, decorators[i])(kind === \"accessor\" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);\n if (kind === \"accessor\") {\n if (result === void 0) continue;\n if (result === null || typeof result !== \"object\") throw new TypeError(\"Object expected\");\n if (_ = accept(result.get)) descriptor.get = _;\n if (_ = accept(result.set)) descriptor.set = _;\n if (_ = accept(result.init)) initializers.unshift(_);\n }\n else if (_ = accept(result)) {\n if (kind === \"field\") initializers.unshift(_);\n else descriptor[key] = _;\n }\n }\n if (target) Object.defineProperty(target, contextIn.name, descriptor);\n done = true;\n};\n\nexport function __runInitializers(thisArg, initializers, value) {\n var useValue = arguments.length > 2;\n for (var i = 0; i < initializers.length; i++) {\n value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);\n }\n return useValue ? value : void 0;\n};\n\nexport function __propKey(x) {\n return typeof x === \"symbol\" ? x : \"\".concat(x);\n};\n\nexport function __setFunctionName(f, name, prefix) {\n if (typeof name === \"symbol\") name = name.description ? \"[\".concat(name.description, \"]\") : \"\";\n return Object.defineProperty(f, \"name\", { configurable: true, value: prefix ? \"\".concat(prefix, \" \", name) : name });\n};\n\nexport function __metadata(metadataKey, metadataValue) {\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\n}\n\nexport function __awaiter(thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n}\n\nexport function __generator(thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === \"function\" ? Iterator : Object).prototype);\n return g.next = verb(0), g[\"throw\"] = verb(1), g[\"return\"] = verb(2), typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (g && (g = 0, op[0] && (_ = 0)), _) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n}\n\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n});\n\nexport function __exportStar(m, o) {\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\n}\n\nexport function __values(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n}\n\nexport function __read(o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n}\n\n/** @deprecated */\nexport function __spread() {\n for (var ar = [], i = 0; i < arguments.length; i++)\n ar = ar.concat(__read(arguments[i]));\n return ar;\n}\n\n/** @deprecated */\nexport function __spreadArrays() {\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\n r[k] = a[j];\n return r;\n}\n\nexport function __spreadArray(to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n}\n\nexport function __await(v) {\n return this instanceof __await ? (this.v = v, this) : new __await(v);\n}\n\nexport function __asyncGenerator(thisArg, _arguments, generator) {\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\n return i = Object.create((typeof AsyncIterator === \"function\" ? AsyncIterator : Object).prototype), verb(\"next\"), verb(\"throw\"), verb(\"return\", awaitReturn), i[Symbol.asyncIterator] = function () { return this; }, i;\n function awaitReturn(f) { return function (v) { return Promise.resolve(v).then(f, reject); }; }\n function verb(n, f) { if (g[n]) { i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; if (f) i[n] = f(i[n]); } }\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\n function fulfill(value) { resume(\"next\", value); }\n function reject(value) { resume(\"throw\", value); }\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\n}\n\nexport function __asyncDelegator(o) {\n var i, p;\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: false } : f ? f(v) : v; } : f; }\n}\n\nexport function __asyncValues(o) {\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var m = o[Symbol.asyncIterator], i;\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\n}\n\nexport function __makeTemplateObject(cooked, raw) {\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\n return cooked;\n};\n\nvar __setModuleDefault = Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n};\n\nvar ownKeys = function(o) {\n ownKeys = Object.getOwnPropertyNames || function (o) {\n var ar = [];\n for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;\n return ar;\n };\n return ownKeys(o);\n};\n\nexport function __importStar(mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== \"default\") __createBinding(result, mod, k[i]);\n __setModuleDefault(result, mod);\n return result;\n}\n\nexport function __importDefault(mod) {\n return (mod && mod.__esModule) ? mod : { default: mod };\n}\n\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\n}\n\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\n}\n\nexport function __classPrivateFieldIn(state, receiver) {\n if (receiver === null || (typeof receiver !== \"object\" && typeof receiver !== \"function\")) throw new TypeError(\"Cannot use 'in' operator on non-object\");\n return typeof state === \"function\" ? receiver === state : state.has(receiver);\n}\n\nexport function __addDisposableResource(env, value, async) {\n if (value !== null && value !== void 0) {\n if (typeof value !== \"object\" && typeof value !== \"function\") throw new TypeError(\"Object expected.\");\n var dispose, inner;\n if (async) {\n if (!Symbol.asyncDispose) throw new TypeError(\"Symbol.asyncDispose is not defined.\");\n dispose = value[Symbol.asyncDispose];\n }\n if (dispose === void 0) {\n if (!Symbol.dispose) throw new TypeError(\"Symbol.dispose is not defined.\");\n dispose = value[Symbol.dispose];\n if (async) inner = dispose;\n }\n if (typeof dispose !== \"function\") throw new TypeError(\"Object not disposable.\");\n if (inner) dispose = function() { try { inner.call(this); } catch (e) { return Promise.reject(e); } };\n env.stack.push({ value: value, dispose: dispose, async: async });\n }\n else if (async) {\n env.stack.push({ async: true });\n }\n return value;\n}\n\nvar _SuppressedError = typeof SuppressedError === \"function\" ? SuppressedError : function (error, suppressed, message) {\n var e = new Error(message);\n return e.name = \"SuppressedError\", e.error = error, e.suppressed = suppressed, e;\n};\n\nexport function __disposeResources(env) {\n function fail(e) {\n env.error = env.hasError ? new _SuppressedError(e, env.error, \"An error was suppressed during disposal.\") : e;\n env.hasError = true;\n }\n var r, s = 0;\n function next() {\n while (r = env.stack.pop()) {\n try {\n if (!r.async && s === 1) return s = 0, env.stack.push(r), Promise.resolve().then(next);\n if (r.dispose) {\n var result = r.dispose.call(r.value);\n if (r.async) return s |= 2, Promise.resolve(result).then(next, function(e) { fail(e); return next(); });\n }\n else s |= 1;\n }\n catch (e) {\n fail(e);\n }\n }\n if (s === 1) return env.hasError ? Promise.reject(env.error) : Promise.resolve();\n if (env.hasError) throw env.error;\n }\n return next();\n}\n\nexport function __rewriteRelativeImportExtension(path, preserveJsx) {\n if (typeof path === \"string\" && /^\\.\\.?\\//.test(path)) {\n return path.replace(/\\.(tsx)$|((?:\\.d)?)((?:\\.[^./]+?)?)\\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {\n return tsx ? preserveJsx ? \".jsx\" : \".js\" : d && (!ext || !cm) ? m : (d + ext + \".\" + cm.toLowerCase() + \"js\");\n });\n }\n return path;\n}\n\nexport default {\n __extends,\n __assign,\n __rest,\n __decorate,\n __param,\n __esDecorate,\n __runInitializers,\n __propKey,\n __setFunctionName,\n __metadata,\n __awaiter,\n __generator,\n __createBinding,\n __exportStar,\n __values,\n __read,\n __spread,\n __spreadArrays,\n __spreadArray,\n __await,\n __asyncGenerator,\n __asyncDelegator,\n __asyncValues,\n __makeTemplateObject,\n __importStar,\n __importDefault,\n __classPrivateFieldGet,\n __classPrivateFieldSet,\n __classPrivateFieldIn,\n __addDisposableResource,\n __disposeResources,\n __rewriteRelativeImportExtension,\n};\n","export var zeroRightClassName = 'right-scroll-bar-position';\nexport var fullWidthClassName = 'width-before-scroll-bar';\nexport var noScrollbarsClassName = 'with-scroll-bars-hidden';\n/**\n * Name of a CSS variable containing the amount of \"hidden\" scrollbar\n * ! might be undefined ! use will fallback!\n */\nexport var removedBarSizeVariable = '--removed-body-scroll-bar-size';\n","/**\n * Assigns a value for a given ref, no matter of the ref format\n * @param {RefObject} ref - a callback function or ref object\n * @param value - a new value\n *\n * @see https://github.com/theKashey/use-callback-ref#assignref\n * @example\n * const refObject = useRef();\n * const refFn = (ref) => {....}\n *\n * assignRef(refObject, \"refValue\");\n * assignRef(refFn, \"refValue\");\n */\nexport function assignRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n }\n else if (ref) {\n ref.current = value;\n }\n return ref;\n}\n","import { useState } from 'react';\n/**\n * creates a MutableRef with ref change callback\n * @param initialValue - initial ref value\n * @param {Function} callback - a callback to run when value changes\n *\n * @example\n * const ref = useCallbackRef(0, (newValue, oldValue) => console.log(oldValue, '->', newValue);\n * ref.current = 1;\n * // prints 0 -> 1\n *\n * @see https://reactjs.org/docs/hooks-reference.html#useref\n * @see https://github.com/theKashey/use-callback-ref#usecallbackref---to-replace-reactuseref\n * @returns {MutableRefObject}\n */\nexport function useCallbackRef(initialValue, callback) {\n var ref = useState(function () { return ({\n // value\n value: initialValue,\n // last callback\n callback: callback,\n // \"memoized\" public interface\n facade: {\n get current() {\n return ref.value;\n },\n set current(value) {\n var last = ref.value;\n if (last !== value) {\n ref.value = value;\n ref.callback(value, last);\n }\n },\n },\n }); })[0];\n // update callback\n ref.callback = callback;\n return ref.facade;\n}\n","import * as React from 'react';\nimport { assignRef } from './assignRef';\nimport { useCallbackRef } from './useRef';\nvar useIsomorphicLayoutEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nvar currentValues = new WeakMap();\n/**\n * Merges two or more refs together providing a single interface to set their value\n * @param {RefObject|Ref} refs\n * @returns {MutableRefObject} - a new ref, which translates all changes to {refs}\n *\n * @see {@link mergeRefs} a version without buit-in memoization\n * @see https://github.com/theKashey/use-callback-ref#usemergerefs\n * @example\n * const Component = React.forwardRef((props, ref) => {\n * const ownRef = useRef();\n * const domRef = useMergeRefs([ref, ownRef]); // 👈 merge together\n * return <div ref={domRef}>...</div>\n * }\n */\nexport function useMergeRefs(refs, defaultValue) {\n var callbackRef = useCallbackRef(defaultValue || null, function (newValue) {\n return refs.forEach(function (ref) { return assignRef(ref, newValue); });\n });\n // handle refs changes - added or removed\n useIsomorphicLayoutEffect(function () {\n var oldValue = currentValues.get(callbackRef);\n if (oldValue) {\n var prevRefs_1 = new Set(oldValue);\n var nextRefs_1 = new Set(refs);\n var current_1 = callbackRef.current;\n prevRefs_1.forEach(function (ref) {\n if (!nextRefs_1.has(ref)) {\n assignRef(ref, null);\n }\n });\n nextRefs_1.forEach(function (ref) {\n if (!prevRefs_1.has(ref)) {\n assignRef(ref, current_1);\n }\n });\n }\n currentValues.set(callbackRef, refs);\n }, [refs]);\n return callbackRef;\n}\n","import { __assign } from \"tslib\";\nfunction ItoI(a) {\n return a;\n}\nfunction innerCreateMedium(defaults, middleware) {\n if (middleware === void 0) { middleware = ItoI; }\n var buffer = [];\n var assigned = false;\n var medium = {\n read: function () {\n if (assigned) {\n throw new Error('Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.');\n }\n if (buffer.length) {\n return buffer[buffer.length - 1];\n }\n return defaults;\n },\n useMedium: function (data) {\n var item = middleware(data, assigned);\n buffer.push(item);\n return function () {\n buffer = buffer.filter(function (x) { return x !== item; });\n };\n },\n assignSyncMedium: function (cb) {\n assigned = true;\n while (buffer.length) {\n var cbs = buffer;\n buffer = [];\n cbs.forEach(cb);\n }\n buffer = {\n push: function (x) { return cb(x); },\n filter: function () { return buffer; },\n };\n },\n assignMedium: function (cb) {\n assigned = true;\n var pendingQueue = [];\n if (buffer.length) {\n var cbs = buffer;\n buffer = [];\n cbs.forEach(cb);\n pendingQueue = buffer;\n }\n var executeQueue = function () {\n var cbs = pendingQueue;\n pendingQueue = [];\n cbs.forEach(cb);\n };\n var cycle = function () { return Promise.resolve().then(executeQueue); };\n cycle();\n buffer = {\n push: function (x) {\n pendingQueue.push(x);\n cycle();\n },\n filter: function (filter) {\n pendingQueue = pendingQueue.filter(filter);\n return buffer;\n },\n };\n },\n };\n return medium;\n}\nexport function createMedium(defaults, middleware) {\n if (middleware === void 0) { middleware = ItoI; }\n return innerCreateMedium(defaults, middleware);\n}\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport function createSidecarMedium(options) {\n if (options === void 0) { options = {}; }\n var medium = innerCreateMedium(null);\n medium.options = __assign({ async: true, ssr: false }, options);\n return medium;\n}\n","import { __assign, __rest } from \"tslib\";\nimport * as React from 'react';\nvar SideCar = function (_a) {\n var sideCar = _a.sideCar, rest = __rest(_a, [\"sideCar\"]);\n if (!sideCar) {\n throw new Error('Sidecar: please provide `sideCar` property to import the right car');\n }\n var Target = sideCar.read();\n if (!Target) {\n throw new Error('Sidecar medium not found');\n }\n return React.createElement(Target, __assign({}, rest));\n};\nSideCar.isSideCarExport = true;\nexport function exportSidecar(medium, exported) {\n medium.useMedium(exported);\n return SideCar;\n}\n","import { createSidecarMedium } from 'use-sidecar';\nexport var effectCar = createSidecarMedium();\n","import { __assign, __rest } from \"tslib\";\nimport * as React from 'react';\nimport { fullWidthClassName, zeroRightClassName } from 'react-remove-scroll-bar/constants';\nimport { useMergeRefs } from 'use-callback-ref';\nimport { effectCar } from './medium';\nvar nothing = function () {\n return;\n};\n/**\n * Removes scrollbar from the page and contain the scroll within the Lock\n */\nvar RemoveScroll = React.forwardRef(function (props, parentRef) {\n var ref = React.useRef(null);\n var _a = React.useState({\n onScrollCapture: nothing,\n onWheelCapture: nothing,\n onTouchMoveCapture: nothing,\n }), callbacks = _a[0], setCallbacks = _a[1];\n var forwardProps = props.forwardProps, children = props.children, className = props.className, removeScrollBar = props.removeScrollBar, enabled = props.enabled, shards = props.shards, sideCar = props.sideCar, noRelative = props.noRelative, noIsolation = props.noIsolation, inert = props.inert, allowPinchZoom = props.allowPinchZoom, _b = props.as, Container = _b === void 0 ? 'div' : _b, gapMode = props.gapMode, rest = __rest(props, [\"forwardProps\", \"children\", \"className\", \"removeScrollBar\", \"enabled\", \"shards\", \"sideCar\", \"noRelative\", \"noIsolation\", \"inert\", \"allowPinchZoom\", \"as\", \"gapMode\"]);\n var SideCar = sideCar;\n var containerRef = useMergeRefs([ref, parentRef]);\n var containerProps = __assign(__assign({}, rest), callbacks);\n return (React.createElement(React.Fragment, null,\n enabled && (React.createElement(SideCar, { sideCar: effectCar, removeScrollBar: removeScrollBar, shards: shards, noRelative: noRelative, noIsolation: noIsolation, inert: inert, setCallbacks: setCallbacks, allowPinchZoom: !!allowPinchZoom, lockRef: ref, gapMode: gapMode })),\n forwardProps ? (React.cloneElement(React.Children.only(children), __assign(__assign({}, containerProps), { ref: containerRef }))) : (React.createElement(Container, __assign({}, containerProps, { className: className, ref: containerRef }), children))));\n});\nRemoveScroll.defaultProps = {\n enabled: true,\n removeScrollBar: true,\n inert: false,\n};\nRemoveScroll.classNames = {\n fullWidth: fullWidthClassName,\n zeroRight: zeroRightClassName,\n};\nexport { RemoveScroll };\n","var currentNonce;\nexport var setNonce = function (nonce) {\n currentNonce = nonce;\n};\nexport var getNonce = function () {\n if (currentNonce) {\n return currentNonce;\n }\n if (typeof __webpack_nonce__ !== 'undefined') {\n return __webpack_nonce__;\n }\n return undefined;\n};\n","import { getNonce } from 'get-nonce';\nfunction makeStyleTag() {\n if (!document)\n return null;\n var tag = document.createElement('style');\n tag.type = 'text/css';\n var nonce = getNonce();\n if (nonce) {\n tag.setAttribute('nonce', nonce);\n }\n return tag;\n}\nfunction injectStyles(tag, css) {\n // @ts-ignore\n if (tag.styleSheet) {\n // @ts-ignore\n tag.styleSheet.cssText = css;\n }\n else {\n tag.appendChild(document.createTextNode(css));\n }\n}\nfunction insertStyleTag(tag) {\n var head = document.head || document.getElementsByTagName('head')[0];\n head.appendChild(tag);\n}\nexport var stylesheetSingleton = function () {\n var counter = 0;\n var stylesheet = null;\n return {\n add: function (style) {\n if (counter == 0) {\n if ((stylesheet = makeStyleTag())) {\n injectStyles(stylesheet, style);\n insertStyleTag(stylesheet);\n }\n }\n counter++;\n },\n remove: function () {\n counter--;\n if (!counter && stylesheet) {\n stylesheet.parentNode && stylesheet.parentNode.removeChild(stylesheet);\n stylesheet = null;\n }\n },\n };\n};\n","import * as React from 'react';\nimport { stylesheetSingleton } from './singleton';\n/**\n * creates a hook to control style singleton\n * @see {@link styleSingleton} for a safer component version\n * @example\n * ```tsx\n * const useStyle = styleHookSingleton();\n * ///\n * useStyle('body { overflow: hidden}');\n */\nexport var styleHookSingleton = function () {\n var sheet = stylesheetSingleton();\n return function (styles, isDynamic) {\n React.useEffect(function () {\n sheet.add(styles);\n return function () {\n sheet.remove();\n };\n }, [styles && isDynamic]);\n };\n};\n","import { styleHookSingleton } from './hook';\n/**\n * create a Component to add styles on demand\n * - styles are added when first instance is mounted\n * - styles are removed when the last instance is unmounted\n * - changing styles in runtime does nothing unless dynamic is set. But with multiple components that can lead to the undefined behavior\n */\nexport var styleSingleton = function () {\n var useStyle = styleHookSingleton();\n var Sheet = function (_a) {\n var styles = _a.styles, dynamic = _a.dynamic;\n useStyle(styles, dynamic);\n return null;\n };\n return Sheet;\n};\n","export var zeroGap = {\n left: 0,\n top: 0,\n right: 0,\n gap: 0,\n};\nvar parse = function (x) { return parseInt(x || '', 10) || 0; };\nvar getOffset = function (gapMode) {\n var cs = window.getComputedStyle(document.body);\n var left = cs[gapMode === 'padding' ? 'paddingLeft' : 'marginLeft'];\n var top = cs[gapMode === 'padding' ? 'paddingTop' : 'marginTop'];\n var right = cs[gapMode === 'padding' ? 'paddingRight' : 'marginRight'];\n return [parse(left), parse(top), parse(right)];\n};\nexport var getGapWidth = function (gapMode) {\n if (gapMode === void 0) { gapMode = 'margin'; }\n if (typeof window === 'undefined') {\n return zeroGap;\n }\n var offsets = getOffset(gapMode);\n var documentWidth = document.documentElement.clientWidth;\n var windowWidth = window.innerWidth;\n return {\n left: offsets[0],\n top: offsets[1],\n right: offsets[2],\n gap: Math.max(0, windowWidth - documentWidth + offsets[2] - offsets[0]),\n };\n};\n","import * as React from 'react';\nimport { styleSingleton } from 'react-style-singleton';\nimport { fullWidthClassName, zeroRightClassName, noScrollbarsClassName, removedBarSizeVariable } from './constants';\nimport { getGapWidth } from './utils';\nvar Style = styleSingleton();\nexport var lockAttribute = 'data-scroll-locked';\n// important tip - once we measure scrollBar width and remove them\n// we could not repeat this operation\n// thus we are using style-singleton - only the first \"yet correct\" style will be applied.\nvar getStyles = function (_a, allowRelative, gapMode, important) {\n var left = _a.left, top = _a.top, right = _a.right, gap = _a.gap;\n if (gapMode === void 0) { gapMode = 'margin'; }\n return \"\\n .\".concat(noScrollbarsClassName, \" {\\n overflow: hidden \").concat(important, \";\\n padding-right: \").concat(gap, \"px \").concat(important, \";\\n }\\n body[\").concat(lockAttribute, \"] {\\n overflow: hidden \").concat(important, \";\\n overscroll-behavior: contain;\\n \").concat([\n allowRelative && \"position: relative \".concat(important, \";\"),\n gapMode === 'margin' &&\n \"\\n padding-left: \".concat(left, \"px;\\n padding-top: \").concat(top, \"px;\\n padding-right: \").concat(right, \"px;\\n margin-left:0;\\n margin-top:0;\\n margin-right: \").concat(gap, \"px \").concat(important, \";\\n \"),\n gapMode === 'padding' && \"padding-right: \".concat(gap, \"px \").concat(important, \";\"),\n ]\n .filter(Boolean)\n .join(''), \"\\n }\\n \\n .\").concat(zeroRightClassName, \" {\\n right: \").concat(gap, \"px \").concat(important, \";\\n }\\n \\n .\").concat(fullWidthClassName, \" {\\n margin-right: \").concat(gap, \"px \").concat(important, \";\\n }\\n \\n .\").concat(zeroRightClassName, \" .\").concat(zeroRightClassName, \" {\\n right: 0 \").concat(important, \";\\n }\\n \\n .\").concat(fullWidthClassName, \" .\").concat(fullWidthClassName, \" {\\n margin-right: 0 \").concat(important, \";\\n }\\n \\n body[\").concat(lockAttribute, \"] {\\n \").concat(removedBarSizeVariable, \": \").concat(gap, \"px;\\n }\\n\");\n};\nvar getCurrentUseCounter = function () {\n var counter = parseInt(document.body.getAttribute(lockAttribute) || '0', 10);\n return isFinite(counter) ? counter : 0;\n};\nexport var useLockAttribute = function () {\n React.useEffect(function () {\n document.body.setAttribute(lockAttribute, (getCurrentUseCounter() + 1).toString());\n return function () {\n var newCounter = getCurrentUseCounter() - 1;\n if (newCounter <= 0) {\n document.body.removeAttribute(lockAttribute);\n }\n else {\n document.body.setAttribute(lockAttribute, newCounter.toString());\n }\n };\n }, []);\n};\n/**\n * Removes page scrollbar and blocks page scroll when mounted\n */\nexport var RemoveScrollBar = function (_a) {\n var noRelative = _a.noRelative, noImportant = _a.noImportant, _b = _a.gapMode, gapMode = _b === void 0 ? 'margin' : _b;\n useLockAttribute();\n /*\n gap will be measured on every component mount\n however it will be used only by the \"first\" invocation\n due to singleton nature of <Style\n */\n var gap = React.useMemo(function () { return getGapWidth(gapMode); }, [gapMode]);\n return React.createElement(Style, { styles: getStyles(gap, !noRelative, gapMode, !noImportant ? '!important' : '') });\n};\n","var passiveSupported = false;\nif (typeof window !== 'undefined') {\n try {\n var options = Object.defineProperty({}, 'passive', {\n get: function () {\n passiveSupported = true;\n return true;\n },\n });\n // @ts-ignore\n window.addEventListener('test', options, options);\n // @ts-ignore\n window.removeEventListener('test', options, options);\n }\n catch (err) {\n passiveSupported = false;\n }\n}\nexport var nonPassive = passiveSupported ? { passive: false } : false;\n","var alwaysContainsScroll = function (node) {\n // textarea will always _contain_ scroll inside self. It only can be hidden\n return node.tagName === 'TEXTAREA';\n};\nvar elementCanBeScrolled = function (node, overflow) {\n if (!(node instanceof Element)) {\n return false;\n }\n var styles = window.getComputedStyle(node);\n return (\n // not-not-scrollable\n styles[overflow] !== 'hidden' &&\n // contains scroll inside self\n !(styles.overflowY === styles.overflowX && !alwaysContainsScroll(node) && styles[overflow] === 'visible'));\n};\nvar elementCouldBeVScrolled = function (node) { return elementCanBeScrolled(node, 'overflowY'); };\nvar elementCouldBeHScrolled = function (node) { return elementCanBeScrolled(node, 'overflowX'); };\nexport var locationCouldBeScrolled = function (axis, node) {\n var ownerDocument = node.ownerDocument;\n var current = node;\n do {\n // Skip over shadow root\n if (typeof ShadowRoot !== 'undefined' && current instanceof ShadowRoot) {\n current = current.host;\n }\n var isScrollable = elementCouldBeScrolled(axis, current);\n if (isScrollable) {\n var _a = getScrollVariables(axis, current), scrollHeight = _a[1], clientHeight = _a[2];\n if (scrollHeight > clientHeight) {\n return true;\n }\n }\n current = current.parentNode;\n } while (current && current !== ownerDocument.body);\n return false;\n};\nvar getVScrollVariables = function (_a) {\n var scrollTop = _a.scrollTop, scrollHeight = _a.scrollHeight, clientHeight = _a.clientHeight;\n return [\n scrollTop,\n scrollHeight,\n clientHeight,\n ];\n};\nvar getHScrollVariables = function (_a) {\n var scrollLeft = _a.scrollLeft, scrollWidth = _a.scrollWidth, clientWidth = _a.clientWidth;\n return [\n scrollLeft,\n scrollWidth,\n clientWidth,\n ];\n};\nvar elementCouldBeScrolled = function (axis, node) {\n return axis === 'v' ? elementCouldBeVScrolled(node) : elementCouldBeHScrolled(node);\n};\nvar getScrollVariables = function (axis, node) {\n return axis === 'v' ? getVScrollVariables(node) : getHScrollVariables(node);\n};\nvar getDirectionFactor = function (axis, direction) {\n /**\n * If the element's direction is rtl (right-to-left), then scrollLeft is 0 when the scrollbar is at its rightmost position,\n * and then increasingly negative as you scroll towards the end of the content.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollLeft\n */\n return axis === 'h' && direction === 'rtl' ? -1 : 1;\n};\nexport var handleScroll = function (axis, endTarget, event, sourceDelta, noOverscroll) {\n var directionFactor = getDirectionFactor(axis, window.getComputedStyle(endTarget).direction);\n var delta = directionFactor * sourceDelta;\n // find scrollable target\n var target = event.target;\n var targetInLock = endTarget.contains(target);\n var shouldCancelScroll = false;\n var isDeltaPositive = delta > 0;\n var availableScroll = 0;\n var availableScrollTop = 0;\n do {\n if (!target) {\n break;\n }\n var _a = getScrollVariables(axis, target), position = _a[0], scroll_1 = _a[1], capacity = _a[2];\n var elementScroll = scroll_1 - capacity - directionFactor * position;\n if (position || elementScroll) {\n if (elementCouldBeScrolled(axis, target)) {\n availableScroll += elementScroll;\n availableScrollTop += position;\n }\n }\n var parent_1 = target.parentNode;\n // we will \"bubble\" from ShadowDom in case we are, or just to the parent in normal case\n // this is the same logic used in focus-lock\n target = (parent_1 && parent_1.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? parent_1.host : parent_1);\n } while (\n // portaled content\n (!targetInLock && target !== document.body) ||\n // self content\n (targetInLock && (endTarget.contains(target) || endTarget === target)));\n // handle epsilon around 0 (non standard zoom levels)\n if (isDeltaPositive &&\n ((noOverscroll && Math.abs(availableScroll) < 1) || (!noOverscroll && delta > availableScroll))) {\n shouldCancelScroll = true;\n }\n else if (!isDeltaPositive &&\n ((noOverscroll && Math.abs(availableScrollTop) < 1) || (!noOverscroll && -delta > availableScrollTop))) {\n shouldCancelScroll = true;\n }\n return shouldCancelScroll;\n};\n","import { __spreadArray } from \"tslib\";\nimport * as React from 'react';\nimport { RemoveScrollBar } from 'react-remove-scroll-bar';\nimport { styleSingleton } from 'react-style-singleton';\nimport { nonPassive } from './aggresiveCapture';\nimport { handleScroll, locationCouldBeScrolled } from './handleScroll';\nexport var getTouchXY = function (event) {\n return 'changedTouches' in event ? [event.changedTouches[0].clientX, event.changedTouches[0].clientY] : [0, 0];\n};\nexport var getDeltaXY = function (event) { return [event.deltaX, event.deltaY]; };\nvar extractRef = function (ref) {\n return ref && 'current' in ref ? ref.current : ref;\n};\nvar deltaCompare = function (x, y) { return x[0] === y[0] && x[1] === y[1]; };\nvar generateStyle = function (id) { return \"\\n .block-interactivity-\".concat(id, \" {pointer-events: none;}\\n .allow-interactivity-\").concat(id, \" {pointer-events: all;}\\n\"); };\nvar idCounter = 0;\nvar lockStack = [];\nexport function RemoveScrollSideCar(props) {\n var shouldPreventQueue = React.useRef([]);\n var touchStartRef = React.useRef([0, 0]);\n var activeAxis = React.useRef();\n var id = React.useState(idCounter++)[0];\n var Style = React.useState(styleSingleton)[0];\n var lastProps = React.useRef(props);\n React.useEffect(function () {\n lastProps.current = props;\n }, [props]);\n React.useEffect(function () {\n if (props.inert) {\n document.body.classList.add(\"block-interactivity-\".concat(id));\n var allow_1 = __spreadArray([props.lockRef.current], (props.shards || []).map(extractRef), true).filter(Boolean);\n allow_1.forEach(function (el) { return el.classList.add(\"allow-interactivity-\".concat(id)); });\n return function () {\n document.body.classList.remove(\"block-interactivity-\".concat(id));\n allow_1.forEach(function (el) { return el.classList.remove(\"allow-interactivity-\".concat(id)); });\n };\n }\n return;\n }, [props.inert, props.lockRef.current, props.shards]);\n var shouldCancelEvent = React.useCallback(function (event, parent) {\n if (('touches' in event && event.touches.length === 2) || (event.type === 'wheel' && event.ctrlKey)) {\n return !lastProps.current.allowPinchZoom;\n }\n var touch = getTouchXY(event);\n var touchStart = touchStartRef.current;\n var deltaX = 'deltaX' in event ? event.deltaX : touchStart[0] - touch[0];\n var deltaY = 'deltaY' in event ? event.deltaY : touchStart[1] - touch[1];\n var currentAxis;\n var target = event.target;\n var moveDirection = Math.abs(deltaX) > Math.abs(deltaY) ? 'h' : 'v';\n // allow horizontal touch move on Range inputs. They will not cause any scroll\n if ('touches' in event && moveDirection === 'h' && target.type === 'range') {\n return false;\n }\n var canBeScrolledInMainDirection = locationCouldBeScrolled(moveDirection, target);\n if (!canBeScrolledInMainDirection) {\n return true;\n }\n if (canBeScrolledInMainDirection) {\n currentAxis = moveDirection;\n }\n else {\n currentAxis = moveDirection === 'v' ? 'h' : 'v';\n canBeScrolledInMainDirection = locationCouldBeScrolled(moveDirection, target);\n // other axis might be not scrollable\n }\n if (!canBeScrolledInMainDirection) {\n return false;\n }\n if (!activeAxis.current && 'changedTouches' in event && (deltaX || deltaY)) {\n activeAxis.current = currentAxis;\n }\n if (!currentAxis) {\n return true;\n }\n var cancelingAxis = activeAxis.current || currentAxis;\n return handleScroll(cancelingAxis, parent, event, cancelingAxis === 'h' ? deltaX : deltaY, true);\n }, []);\n var shouldPrevent = React.useCallback(function (_event) {\n var event = _event;\n if (!lockStack.length || lockStack[lockStack.length - 1] !== Style) {\n // not the last active\n return;\n }\n var delta = 'deltaY' in event ? getDeltaXY(event) : getTouchXY(event);\n var sourceEvent = shouldPreventQueue.current.filter(function (e) { return e.name === event.type && (e.target === event.target || event.target === e.shadowParent) && deltaCompare(e.delta, delta); })[0];\n // self event, and should be canceled\n if (sourceEvent && sourceEvent.should) {\n if (event.cancelable) {\n event.preventDefault();\n }\n return;\n }\n // outside or shard event\n if (!sourceEvent) {\n var shardNodes = (lastProps.current.shards || [])\n .map(extractRef)\n .filter(Boolean)\n .filter(function (node) { return node.contains(event.target); });\n var shouldStop = shardNodes.length > 0 ? shouldCancelEvent(event, shardNodes[0]) : !lastProps.current.noIsolation;\n if (shouldStop) {\n if (event.cancelable) {\n event.preventDefault();\n }\n }\n }\n }, []);\n var shouldCancel = React.useCallback(function (name, delta, target, should) {\n var event = { name: name, delta: delta, target: target, should: should, shadowParent: getOutermostShadowParent(target) };\n shouldPreventQueue.current.push(event);\n setTimeout(function () {\n shouldPreventQueue.current = shouldPreventQueue.current.filter(function (e) { return e !== event; });\n }, 1);\n }, []);\n var scrollTouchStart = React.useCallback(function (event) {\n touchStartRef.current = getTouchXY(event);\n activeAxis.current = undefined;\n }, []);\n var scrollWheel = React.useCallback(function (event) {\n shouldCancel(event.type, getDeltaXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));\n }, []);\n var scrollTouchMove = React.useCallback(function (event) {\n shouldCancel(event.type, getTouchXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));\n }, []);\n React.useEffect(function () {\n lockStack.push(Style);\n props.setCallbacks({\n onScrollCapture: scrollWheel,\n onWheelCapture: scrollWheel,\n onTouchMoveCapture: scrollTouchMove,\n });\n document.addEventListener('wheel', shouldPrevent, nonPassive);\n document.addEventListener('touchmove', shouldPrevent, nonPassive);\n document.addEventListener('touchstart', scrollTouchStart, nonPassive);\n return function () {\n lockStack = lockStack.filter(function (inst) { return inst !== Style; });\n document.removeEventListener('wheel', shouldPrevent, nonPassive);\n document.removeEventListener('touchmove', shouldPrevent, nonPassive);\n document.removeEventListener('touchstart', scrollTouchStart, nonPassive);\n };\n }, []);\n var removeScrollBar = props.removeScrollBar, inert = props.inert;\n return (React.createElement(React.Fragment, null,\n inert ? React.createElement(Style, { styles: generateStyle(id) }) : null,\n removeScrollBar ? React.createElement(RemoveScrollBar, { noRelative: props.noRelative, gapMode: props.gapMode }) : null));\n}\nfunction getOutermostShadowParent(node) {\n var shadowParent = null;\n while (node !== null) {\n if (node instanceof ShadowRoot) {\n shadowParent = node.host;\n node = node.host;\n }\n node = node.parentNode;\n }\n return shadowParent;\n}\n","import { exportSidecar } from 'use-sidecar';\nimport { RemoveScrollSideCar } from './SideEffect';\nimport { effectCar } from './medium';\nexport default exportSidecar(effectCar, RemoveScrollSideCar);\n","import { __assign } from \"tslib\";\nimport * as React from 'react';\nimport { RemoveScroll } from './UI';\nimport SideCar from './sidecar';\nvar ReactRemoveScroll = React.forwardRef(function (props, ref) { return (React.createElement(RemoveScroll, __assign({}, props, { ref: ref, sideCar: SideCar }))); });\nReactRemoveScroll.classNames = RemoveScroll.classNames;\nexport default ReactRemoveScroll;\n","\"use client\";\n\n// src/popover.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { DismissableLayer } from \"@radix-ui/react-dismissable-layer\";\nimport { useFocusGuards } from \"@radix-ui/react-focus-guards\";\nimport { FocusScope } from \"@radix-ui/react-focus-scope\";\nimport { useId } from \"@radix-ui/react-id\";\nimport * as PopperPrimitive from \"@radix-ui/react-popper\";\nimport { createPopperScope } from \"@radix-ui/react-popper\";\nimport { Portal as PortalPrimitive } from \"@radix-ui/react-portal\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { createSlot } from \"@radix-ui/react-slot\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { hideOthers } from \"aria-hidden\";\nimport { RemoveScroll } from \"react-remove-scroll\";\nimport { jsx } from \"react/jsx-runtime\";\nvar POPOVER_NAME = \"Popover\";\nvar [createPopoverContext, createPopoverScope] = createContextScope(POPOVER_NAME, [\n createPopperScope\n]);\nvar usePopperScope = createPopperScope();\nvar [PopoverProvider, usePopoverContext] = createPopoverContext(POPOVER_NAME);\nvar Popover = (props) => {\n const {\n __scopePopover,\n children,\n open: openProp,\n defaultOpen,\n onOpenChange,\n modal = false\n } = props;\n const popperScope = usePopperScope(__scopePopover);\n const triggerRef = React.useRef(null);\n const [hasCustomAnchor, setHasCustomAnchor] = React.useState(false);\n const [open, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen ?? false,\n onChange: onOpenChange,\n caller: POPOVER_NAME\n });\n return /* @__PURE__ */ jsx(PopperPrimitive.Root, { ...popperScope, children: /* @__PURE__ */ jsx(\n PopoverProvider,\n {\n scope: __scopePopover,\n contentId: useId(),\n triggerRef,\n open,\n onOpenChange: setOpen,\n onOpenToggle: React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),\n hasCustomAnchor,\n onCustomAnchorAdd: React.useCallback(() => setHasCustomAnchor(true), []),\n onCustomAnchorRemove: React.useCallback(() => setHasCustomAnchor(false), []),\n modal,\n children\n }\n ) });\n};\nPopover.displayName = POPOVER_NAME;\nvar ANCHOR_NAME = \"PopoverAnchor\";\nvar PopoverAnchor = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopePopover, ...anchorProps } = props;\n const context = usePopoverContext(ANCHOR_NAME, __scopePopover);\n const popperScope = usePopperScope(__scopePopover);\n const { onCustomAnchorAdd, onCustomAnchorRemove } = context;\n React.useEffect(() => {\n onCustomAnchorAdd();\n return () => onCustomAnchorRemove();\n }, [onCustomAnchorAdd, onCustomAnchorRemove]);\n return /* @__PURE__ */ jsx(PopperPrimitive.Anchor, { ...popperScope, ...anchorProps, ref: forwardedRef });\n }\n);\nPopoverAnchor.displayName = ANCHOR_NAME;\nvar TRIGGER_NAME = \"PopoverTrigger\";\nvar PopoverTrigger = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopePopover, ...triggerProps } = props;\n const context = usePopoverContext(TRIGGER_NAME, __scopePopover);\n const popperScope = usePopperScope(__scopePopover);\n const composedTriggerRef = useComposedRefs(forwardedRef, context.triggerRef);\n const trigger = /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n \"aria-haspopup\": \"dialog\",\n \"aria-expanded\": context.open,\n \"aria-controls\": context.contentId,\n \"data-state\": getState(context.open),\n ...triggerProps,\n ref: composedTriggerRef,\n onClick: composeEventHandlers(props.onClick, context.onOpenToggle)\n }\n );\n return context.hasCustomAnchor ? trigger : /* @__PURE__ */ jsx(PopperPrimitive.Anchor, { asChild: true, ...popperScope, children: trigger });\n }\n);\nPopoverTrigger.displayName = TRIGGER_NAME;\nvar PORTAL_NAME = \"PopoverPortal\";\nvar [PortalProvider, usePortalContext] = createPopoverContext(PORTAL_NAME, {\n forceMount: void 0\n});\nvar PopoverPortal = (props) => {\n const { __scopePopover, forceMount, children, container } = props;\n const context = usePopoverContext(PORTAL_NAME, __scopePopover);\n return /* @__PURE__ */ jsx(PortalProvider, { scope: __scopePopover, forceMount, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(PortalPrimitive, { asChild: true, container, children }) }) });\n};\nPopoverPortal.displayName = PORTAL_NAME;\nvar CONTENT_NAME = \"PopoverContent\";\nvar PopoverContent = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(CONTENT_NAME, props.__scopePopover);\n const { forceMount = portalContext.forceMount, ...contentProps } = props;\n const context = usePopoverContext(CONTENT_NAME, props.__scopePopover);\n return /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: context.modal ? /* @__PURE__ */ jsx(PopoverContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ jsx(PopoverContentNonModal, { ...contentProps, ref: forwardedRef }) });\n }\n);\nPopoverContent.displayName = CONTENT_NAME;\nvar Slot = createSlot(\"PopoverContent.RemoveScroll\");\nvar PopoverContentModal = React.forwardRef(\n (props, forwardedRef) => {\n const context = usePopoverContext(CONTENT_NAME, props.__scopePopover);\n const contentRef = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, contentRef);\n const isRightClickOutsideRef = React.useRef(false);\n React.useEffect(() => {\n const content = contentRef.current;\n if (content) return hideOthers(content);\n }, []);\n return /* @__PURE__ */ jsx(RemoveScroll, { as: Slot, allowPinchZoom: true, children: /* @__PURE__ */ jsx(\n PopoverContentImpl,\n {\n ...props,\n ref: composedRefs,\n trapFocus: context.open,\n disableOutsidePointerEvents: true,\n onCloseAutoFocus: composeEventHandlers(props.onCloseAutoFocus, (event) => {\n event.preventDefault();\n if (!isRightClickOutsideRef.current) context.triggerRef.current?.focus();\n }),\n onPointerDownOutside: composeEventHandlers(\n props.onPointerDownOutside,\n (event) => {\n const originalEvent = event.detail.originalEvent;\n const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;\n const isRightClick = originalEvent.button === 2 || ctrlLeftClick;\n isRightClickOutsideRef.current = isRightClick;\n },\n { checkForDefaultPrevented: false }\n ),\n onFocusOutside: composeEventHandlers(\n props.onFocusOutside,\n (event) => event.preventDefault(),\n { checkForDefaultPrevented: false }\n )\n }\n ) });\n }\n);\nvar PopoverContentNonModal = React.forwardRef(\n (props, forwardedRef) => {\n const context = usePopoverContext(CONTENT_NAME, props.__scopePopover);\n const hasInteractedOutsideRef = React.useRef(false);\n const hasPointerDownOutsideRef = React.useRef(false);\n return /* @__PURE__ */ jsx(\n PopoverContentImpl,\n {\n ...props,\n ref: forwardedRef,\n trapFocus: false,\n disableOutsidePointerEvents: false,\n onCloseAutoFocus: (event) => {\n props.onCloseAutoFocus?.(event);\n if (!event.defaultPrevented) {\n if (!hasInteractedOutsideRef.current) context.triggerRef.current?.focus();\n event.preventDefault();\n }\n hasInteractedOutsideRef.current = false;\n hasPointerDownOutsideRef.current = false;\n },\n onInteractOutside: (event) => {\n props.onInteractOutside?.(event);\n if (!event.defaultPrevented) {\n hasInteractedOutsideRef.current = true;\n if (event.detail.originalEvent.type === \"pointerdown\") {\n hasPointerDownOutsideRef.current = true;\n }\n }\n const target = event.target;\n const targetIsTrigger = context.triggerRef.current?.contains(target);\n if (targetIsTrigger) event.preventDefault();\n if (event.detail.originalEvent.type === \"focusin\" && hasPointerDownOutsideRef.current) {\n event.preventDefault();\n }\n }\n }\n );\n }\n);\nvar PopoverContentImpl = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopePopover,\n trapFocus,\n onOpenAutoFocus,\n onCloseAutoFocus,\n disableOutsidePointerEvents,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n ...contentProps\n } = props;\n const context = usePopoverContext(CONTENT_NAME, __scopePopover);\n const popperScope = usePopperScope(__scopePopover);\n useFocusGuards();\n return /* @__PURE__ */ jsx(\n FocusScope,\n {\n asChild: true,\n loop: true,\n trapped: trapFocus,\n onMountAutoFocus: onOpenAutoFocus,\n onUnmountAutoFocus: onCloseAutoFocus,\n children: /* @__PURE__ */ jsx(\n DismissableLayer,\n {\n asChild: true,\n disableOutsidePointerEvents,\n onInteractOutside,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onDismiss: () => context.onOpenChange(false),\n children: /* @__PURE__ */ jsx(\n PopperPrimitive.Content,\n {\n \"data-state\": getState(context.open),\n role: \"dialog\",\n id: context.contentId,\n ...popperScope,\n ...contentProps,\n ref: forwardedRef,\n style: {\n ...contentProps.style,\n // re-namespace exposed content custom properties\n ...{\n \"--radix-popover-content-transform-origin\": \"var(--radix-popper-transform-origin)\",\n \"--radix-popover-content-available-width\": \"var(--radix-popper-available-width)\",\n \"--radix-popover-content-available-height\": \"var(--radix-popper-available-height)\",\n \"--radix-popover-trigger-width\": \"var(--radix-popper-anchor-width)\",\n \"--radix-popover-trigger-height\": \"var(--radix-popper-anchor-height)\"\n }\n }\n }\n )\n }\n )\n }\n );\n }\n);\nvar CLOSE_NAME = \"PopoverClose\";\nvar PopoverClose = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopePopover, ...closeProps } = props;\n const context = usePopoverContext(CLOSE_NAME, __scopePopover);\n return /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n ...closeProps,\n ref: forwardedRef,\n onClick: composeEventHandlers(props.onClick, () => context.onOpenChange(false))\n }\n );\n }\n);\nPopoverClose.displayName = CLOSE_NAME;\nvar ARROW_NAME = \"PopoverArrow\";\nvar PopoverArrow = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopePopover, ...arrowProps } = props;\n const popperScope = usePopperScope(__scopePopover);\n return /* @__PURE__ */ jsx(PopperPrimitive.Arrow, { ...popperScope, ...arrowProps, ref: forwardedRef });\n }\n);\nPopoverArrow.displayName = ARROW_NAME;\nfunction getState(open) {\n return open ? \"open\" : \"closed\";\n}\nvar Root2 = Popover;\nvar Anchor2 = PopoverAnchor;\nvar Trigger = PopoverTrigger;\nvar Portal = PopoverPortal;\nvar Content2 = PopoverContent;\nvar Close = PopoverClose;\nvar Arrow2 = PopoverArrow;\nexport {\n Anchor2 as Anchor,\n Arrow2 as Arrow,\n Close,\n Content2 as Content,\n Popover,\n PopoverAnchor,\n PopoverArrow,\n PopoverClose,\n PopoverContent,\n PopoverPortal,\n PopoverTrigger,\n Portal,\n Root2 as Root,\n Trigger,\n createPopoverScope\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { cn } from \"@/utils/cn\";\nimport { forwardRef } from \"react\";\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>\n>(({ className, align = \"end\", sideOffset = 8, ...props }, ref) => (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n ref={ref}\n align={align}\n sideOffset={sideOffset}\n className={cn(\n \"z-50 min-w-[200px] p-2\",\n \"border rounded-md border-cms-gray-200\",\n \"bg-cms-white shadow-lg\",\n \"animate-in fade-in-0 zoom-in-95\",\n \"data-[state=closed]:animate-out\",\n \"data-[state=closed]:fade-out-0\",\n \"data-[state=closed]:zoom-out-95\",\n \"data-[side=bottom]:slide-in-from-top-2\",\n \"data-[side=left]:slide-in-from-right-2\",\n \"data-[side=right]:slide-in-from-left-2\",\n \"data-[side=top]:slide-in-from-bottom-2\",\n className,\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","\"use client\";\n\nimport { cn } from \"@/utils/cn\";\nimport { cva, VariantProps } from \"class-variance-authority\";\nimport { ButtonHTMLAttributes, forwardRef } from \"react\";\n\nconst popoverMenuItemVariants = cva(\n cn(\n \"flex w-full items-center gap-3 rounded-md px-3 py-2\",\n \"text-sm font-medium transition-colors\",\n \"hover:bg-cms-gray-200 active:bg-cms-gray-300\",\n \"disabled:pointer-events-none disabled:opacity-50\",\n ),\n {\n variants: {\n variant: {\n default: \"text-cms-foreground\",\n destructive: \"text-cms-red-400 hover:text-cms-red-500\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n },\n);\n\nexport interface PopoverMenuItemProps\n extends\n ButtonHTMLAttributes<HTMLButtonElement>,\n VariantProps<typeof popoverMenuItemVariants> {\n icon?: React.ReactNode;\n}\n\nconst PopoverMenuItem = forwardRef<HTMLButtonElement, PopoverMenuItemProps>(\n ({ className, variant, icon, children, ...props }, ref) => {\n return (\n <button\n ref={ref}\n className={cn(popoverMenuItemVariants({ variant }), className)}\n {...props}\n >\n {icon && <span className=\"shrink-0\">{icon}</span>}\n {children}\n </button>\n );\n },\n);\n\nPopoverMenuItem.displayName = \"PopoverMenuItem\";\n\nexport { PopoverMenuItem, popoverMenuItemVariants };\n","import React from \"react\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"@/utils/cn\";\n\nconst textVariants = cva(\"cms-font-pretendard cms-text-black\", {\n variants: {\n variant: {\n h1: \"text-3xl font-bold\",\n h2: \"text-2xl font-semibold\",\n h3: \"text-lg font-semibold\",\n subtitle: \"text-base font-medium\",\n body: \"text-sm font-normal\",\n emphasis: \"text-sm font-semibold\",\n caption: \"text-xs font-normal\",\n price: \"text-xs font-bold\",\n },\n align: {\n left: \"text-left\",\n center: \"text-center\",\n right: \"text-right\",\n },\n decoration: {\n underline: \"underline\",\n lineThrough: \"line-through\",\n none: \"no-underline\",\n },\n },\n defaultVariants: {\n variant: \"body\",\n align: \"left\",\n },\n});\n\nexport interface TextProps\n extends React.HTMLAttributes<HTMLElement>, VariantProps<typeof textVariants> {\n as?: \"p\" | \"span\" | \"div\" | \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\" | \"label\";\n children: React.ReactNode;\n}\n\nexport const Text = React.forwardRef<HTMLElement, TextProps>(\n (\n {\n className,\n variant,\n align,\n decoration,\n as: Component = \"p\",\n children,\n ...props\n },\n ref,\n ) => {\n return (\n <Component\n className={cn(textVariants({ variant, align, decoration }), className)}\n ref={ref as any}\n {...props}\n >\n {children}\n </Component>\n );\n },\n);\n\nText.displayName = \"Text\";\n","import React from \"react\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"@/utils/cn\";\n\nconst textInputVariants = cva(\n cn(\n \"w-full box-border\",\n \"px-3 py-2\",\n \"rounded-cms-sm\",\n \"border border-solid\",\n \"font-normal leading-tight\",\n \"transition-colors duration-200\",\n \"outline-none\",\n \"text-md text-cms-black\",\n \"placeholder:text-cms-gray-500\",\n \"placeholder:text-md\",\n ),\n {\n variants: {\n variant: {\n default: cn(\n \"bg-cms-white \",\n \"border-cms-gray-450\",\n \"focus:border-cms-gray-800\",\n \"disabled:bg-cms-gray-150\",\n \"disabled:text-cms-gray-400\",\n \"disabled:cursor-not-allowed\",\n ),\n error: cn(\n \"bg-cms-white\",\n \"border-cms-red-400\",\n \"focus:border-cms-red-500\",\n ),\n },\n fullWidth: {\n true: \"w-full\",\n false: \"w-auto\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n fullWidth: true,\n },\n },\n);\n\nconst labelVariants = cva(\"block text-sm font-medium text-cms-black\");\n\nconst errorMessageVariants = cva(\n \"block text-sm font-medium text-cms-red-400 mt-1\",\n);\n\nconst helperTextVariants = cva(\n \"block text-sm font-normal text-cms-gray-700 mt-1\",\n);\n\nexport interface TextInputProps\n extends\n Omit<React.InputHTMLAttributes<HTMLInputElement>, \"size\">,\n VariantProps<typeof textInputVariants> {\n label?: string;\n error?: boolean;\n errorMessage?: string;\n helperText?: string;\n showCharCount?: boolean;\n}\n\nexport const TextInput = React.forwardRef<HTMLInputElement, TextInputProps>(\n (\n {\n className,\n variant,\n fullWidth,\n label,\n error,\n errorMessage,\n helperText,\n showCharCount,\n maxLength,\n value,\n defaultValue,\n onChange,\n id,\n ...props\n },\n ref,\n ) => {\n const [internalValue, setInternalValue] = React.useState<string>(\n (value || defaultValue || \"\") as string,\n );\n const inputId = id || `input-${Math.random().toString(36).substr(2, 9)}`;\n const finalVariant = error ? \"error\" : variant;\n\n const currentValue =\n value !== undefined ? (value as string) : internalValue;\n const charCount = currentValue?.length || 0;\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n if (value === undefined) {\n setInternalValue(e.target.value);\n }\n onChange?.(e);\n };\n\n const hasHeader = label || (showCharCount && maxLength);\n\n return (\n <div className={cn(\"w-full\", !fullWidth && \"w-auto\")}>\n {hasHeader && (\n <div className=\"flex justify-between items-center mb-2\">\n {label ? (\n <label htmlFor={inputId} className={labelVariants()}>\n {label}\n </label>\n ) : (\n <div />\n )}\n {showCharCount && maxLength && (\n <span className=\"text-sm text-cms-gray-600\">\n {charCount} / {maxLength}\n </span>\n )}\n </div>\n )}\n <input\n id={inputId}\n ref={ref}\n className={cn(\n textInputVariants({ variant: finalVariant, fullWidth }),\n className,\n )}\n maxLength={maxLength}\n value={value}\n defaultValue={defaultValue}\n onChange={handleChange}\n {...props}\n />\n {error && errorMessage && (\n <span className={errorMessageVariants()}>{errorMessage}</span>\n )}\n {!error && helperText && (\n <span className={helperTextVariants()}>{helperText}</span>\n )}\n </div>\n );\n },\n);\n\nTextInput.displayName = \"TextInput\";\n","/**\n * Time zone name format.\n */\n\n/**\n * The function returns the time zone name for the given date in the specified\n * time zone.\n *\n * It uses the `Intl.DateTimeFormat` API and by default outputs the time zone\n * name in a long format, e.g. \"Pacific Standard Time\" or\n * \"Singapore Standard Time\".\n *\n * It is possible to specify the format as the third argument using one of the following options\n *\n * - \"short\": e.g. \"EDT\" or \"GMT+8\".\n * - \"long\": e.g. \"Eastern Daylight Time\".\n * - \"shortGeneric\": e.g. \"ET\" or \"Singapore Time\".\n * - \"longGeneric\": e.g. \"Eastern Time\" or \"Singapore Standard Time\".\n *\n * These options correspond to TR35 tokens `z..zzz`, `zzzz`, `v`, and `vvvv` respectively: https://www.unicode.org/reports/tr35/tr35-dates.html#dfst-zone\n *\n * @param timeZone - Time zone name (IANA or UTC offset)\n * @param date - Date object to get the time zone name for\n * @param format - Optional format of the time zone name. Defaults to \"long\". Can be \"short\", \"long\", \"shortGeneric\", or \"longGeneric\".\n *\n * @returns Time zone name (e.g. \"Singapore Standard Time\")\n */\nexport function tzName(timeZone, date, format = \"long\") {\n return new Intl.DateTimeFormat(\"en-US\", {\n // Enforces engine to render the time. Without the option JavaScriptCore omits it.\n hour: \"numeric\",\n timeZone: timeZone,\n timeZoneName: format\n }).format(date).split(/\\s/g) // Format.JS uses non-breaking spaces\n .slice(2) // Skip the hour and AM/PM parts\n .join(\" \");\n}","const offsetFormatCache = {};\nconst offsetCache = {};\n\n/**\n * The function extracts UTC offset in minutes from the given date in specified\n * time zone.\n *\n * Unlike `Date.prototype.getTimezoneOffset`, this function returns the value\n * mirrored to the sign of the offset in the time zone. For Asia/Singapore\n * (UTC+8), `tzOffset` returns 480, while `getTimezoneOffset` returns -480.\n *\n * @param timeZone - Time zone name (IANA or UTC offset)\n * @param date - Date to check the offset for\n *\n * @returns UTC offset in minutes\n */\nexport function tzOffset(timeZone, date) {\n try {\n const format = offsetFormatCache[timeZone] ||= new Intl.DateTimeFormat(\"en-US\", {\n timeZone,\n timeZoneName: \"longOffset\"\n }).format;\n const offsetStr = format(date).split(\"GMT\")[1];\n if (offsetStr in offsetCache) return offsetCache[offsetStr];\n return calcOffset(offsetStr, offsetStr.split(\":\"));\n } catch {\n // Fallback to manual parsing if the runtime doesn't support ±HH:MM/±HHMM/±HH\n // See: https://github.com/nodejs/node/issues/53419\n if (timeZone in offsetCache) return offsetCache[timeZone];\n const captures = timeZone?.match(offsetRe);\n if (captures) return calcOffset(timeZone, captures.slice(1));\n return NaN;\n }\n}\nconst offsetRe = /([+-]\\d\\d):?(\\d\\d)?/;\nfunction calcOffset(cacheStr, values) {\n const hours = +(values[0] || 0);\n const minutes = +(values[1] || 0);\n // Convert seconds to minutes by dividing by 60 to keep the function return in minutes.\n const seconds = +(values[2] || 0) / 60;\n return offsetCache[cacheStr] = hours * 60 + minutes > 0 ? hours * 60 + minutes + seconds : hours * 60 - minutes - seconds;\n}","import { tzOffset } from \"../tzOffset/index.js\";\nexport class TZDateMini extends Date {\n //#region static\n\n constructor(...args) {\n super();\n if (args.length > 1 && typeof args[args.length - 1] === \"string\") {\n this.timeZone = args.pop();\n }\n this.internal = new Date();\n if (isNaN(tzOffset(this.timeZone, this))) {\n this.setTime(NaN);\n } else {\n if (!args.length) {\n this.setTime(Date.now());\n } else if (typeof args[0] === \"number\" && (args.length === 1 || args.length === 2 && typeof args[1] !== \"number\")) {\n this.setTime(args[0]);\n } else if (typeof args[0] === \"string\") {\n this.setTime(+new Date(args[0]));\n } else if (args[0] instanceof Date) {\n this.setTime(+args[0]);\n } else {\n this.setTime(+new Date(...args));\n adjustToSystemTZ(this, NaN);\n syncToInternal(this);\n }\n }\n }\n static tz(tz, ...args) {\n return args.length ? new TZDateMini(...args, tz) : new TZDateMini(Date.now(), tz);\n }\n\n //#endregion\n\n //#region time zone\n\n withTimeZone(timeZone) {\n return new TZDateMini(+this, timeZone);\n }\n getTimezoneOffset() {\n const offset = -tzOffset(this.timeZone, this);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n return offset > 0 ? Math.floor(offset) : Math.ceil(offset);\n }\n\n //#endregion\n\n //#region time\n\n setTime(time) {\n Date.prototype.setTime.apply(this, arguments);\n syncToInternal(this);\n return +this;\n }\n\n //#endregion\n\n //#region date-fns integration\n\n [Symbol.for(\"constructDateFrom\")](date) {\n return new TZDateMini(+new Date(date), this.timeZone);\n }\n\n //#endregion\n}\n\n// Assign getters and setters\nconst re = /^(get|set)(?!UTC)/;\nObject.getOwnPropertyNames(Date.prototype).forEach(method => {\n if (!re.test(method)) return;\n const utcMethod = method.replace(re, \"$1UTC\");\n // Filter out methods without UTC counterparts\n if (!TZDateMini.prototype[utcMethod]) return;\n if (method.startsWith(\"get\")) {\n // Delegate to internal date's UTC method\n TZDateMini.prototype[method] = function () {\n return this.internal[utcMethod]();\n };\n } else {\n // Assign regular setter\n TZDateMini.prototype[method] = function () {\n Date.prototype[utcMethod].apply(this.internal, arguments);\n syncFromInternal(this);\n return +this;\n };\n\n // Assign UTC setter\n TZDateMini.prototype[utcMethod] = function () {\n Date.prototype[utcMethod].apply(this, arguments);\n syncToInternal(this);\n return +this;\n };\n }\n});\n\n/**\n * Function syncs time to internal date, applying the time zone offset.\n *\n * @param {Date} date - Date to sync\n */\nfunction syncToInternal(date) {\n date.internal.setTime(+date);\n date.internal.setUTCSeconds(date.internal.getUTCSeconds() - Math.round(-tzOffset(date.timeZone, date) * 60));\n}\n\n/**\n * Function syncs the internal date UTC values to the date. It allows to get\n * accurate timestamp value.\n *\n * @param {Date} date - The date to sync\n */\nfunction syncFromInternal(date) {\n // First we transpose the internal values\n Date.prototype.setFullYear.call(date, date.internal.getUTCFullYear(), date.internal.getUTCMonth(), date.internal.getUTCDate());\n Date.prototype.setHours.call(date, date.internal.getUTCHours(), date.internal.getUTCMinutes(), date.internal.getUTCSeconds(), date.internal.getUTCMilliseconds());\n\n // Now we have to adjust the date to the system time zone\n adjustToSystemTZ(date);\n}\n\n/**\n * Function adjusts the date to the system time zone. It uses the time zone\n * differences to calculate the offset and adjust the date.\n *\n * @param {Date} date - Date to adjust\n */\nfunction adjustToSystemTZ(date) {\n // Save the time zone offset before all the adjustments\n const baseOffset = tzOffset(date.timeZone, date);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n const offset = baseOffset > 0 ? Math.floor(baseOffset) : Math.ceil(baseOffset);\n //#region System DST adjustment\n\n // The biggest problem with using the system time zone is that when we create\n // a date from internal values stored in UTC, the system time zone might end\n // up on the DST hour:\n //\n // $ TZ=America/New_York node\n // > new Date(2020, 2, 8, 1).toString()\n // 'Sun Mar 08 2020 01:00:00 GMT-0500 (Eastern Standard Time)'\n // > new Date(2020, 2, 8, 2).toString()\n // 'Sun Mar 08 2020 03:00:00 GMT-0400 (Eastern Daylight Time)'\n // > new Date(2020, 2, 8, 3).toString()\n // 'Sun Mar 08 2020 03:00:00 GMT-0400 (Eastern Daylight Time)'\n // > new Date(2020, 2, 8, 4).toString()\n // 'Sun Mar 08 2020 04:00:00 GMT-0400 (Eastern Daylight Time)'\n //\n // Here we get the same hour for both 2 and 3, because the system time zone\n // has DST beginning at 8 March 2020, 2 a.m. and jumps to 3 a.m. So we have\n // to adjust the internal date to reflect that.\n //\n // However we want to adjust only if that's the DST hour the change happenes,\n // not the hour where DST moves to.\n\n // We calculate the previous hour to see if the time zone offset has changed\n // and we have landed on the DST hour.\n const prevHour = new Date(+date);\n // We use UTC methods here as we don't want to land on the same hour again\n // in case of DST.\n prevHour.setUTCHours(prevHour.getUTCHours() - 1);\n\n // Calculate if we are on the system DST hour.\n const systemOffset = -new Date(+date).getTimezoneOffset();\n const prevHourSystemOffset = -new Date(+prevHour).getTimezoneOffset();\n const systemDSTChange = systemOffset - prevHourSystemOffset;\n // Detect the DST shift. System DST change will occur both on\n const dstShift = Date.prototype.getHours.apply(date) !== date.internal.getUTCHours();\n\n // Move the internal date when we are on the system DST hour.\n if (systemDSTChange && dstShift) date.internal.setUTCMinutes(date.internal.getUTCMinutes() + systemDSTChange);\n\n //#endregion\n\n //#region System diff adjustment\n\n // Now we need to adjust the date, since we just applied internal values.\n // We need to calculate the difference between the system and date time zones\n // and apply it to the date.\n\n const offsetDiff = systemOffset - offset;\n if (offsetDiff) Date.prototype.setUTCMinutes.call(date, Date.prototype.getUTCMinutes.call(date) + offsetDiff);\n\n //#endregion\n\n //#region Seconds System diff adjustment\n\n const systemDate = new Date(+date);\n // Set the UTC seconds to 0 to isolate the timezone offset in seconds.\n systemDate.setUTCSeconds(0);\n // For negative systemOffset, invert the seconds.\n const systemSecondsOffset = systemOffset > 0 ? systemDate.getSeconds() : (systemDate.getSeconds() - 60) % 60;\n\n // Calculate the seconds offset based on the timezone offset.\n const secondsOffset = Math.round(-(tzOffset(date.timeZone, date) * 60)) % 60;\n if (secondsOffset || systemSecondsOffset) {\n date.internal.setUTCSeconds(date.internal.getUTCSeconds() + secondsOffset);\n Date.prototype.setUTCSeconds.call(date, Date.prototype.getUTCSeconds.call(date) + secondsOffset + systemSecondsOffset);\n }\n\n //#endregion\n\n //#region Post-adjustment DST fix\n\n const postBaseOffset = tzOffset(date.timeZone, date);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n const postOffset = postBaseOffset > 0 ? Math.floor(postBaseOffset) : Math.ceil(postBaseOffset);\n const postSystemOffset = -new Date(+date).getTimezoneOffset();\n const postOffsetDiff = postSystemOffset - postOffset;\n const offsetChanged = postOffset !== offset;\n const postDiff = postOffsetDiff - offsetDiff;\n if (offsetChanged && postDiff) {\n Date.prototype.setUTCMinutes.call(date, Date.prototype.getUTCMinutes.call(date) + postDiff);\n\n // Now we need to check if got offset change during the post-adjustment.\n // If so, we also need both dates to reflect that.\n\n const newBaseOffset = tzOffset(date.timeZone, date);\n // Remove the seconds offset\n // use Math.floor for negative GMT timezones and Math.ceil for positive GMT timezones.\n const newOffset = newBaseOffset > 0 ? Math.floor(newBaseOffset) : Math.ceil(newBaseOffset);\n const offsetChange = postOffset - newOffset;\n if (offsetChange) {\n date.internal.setUTCMinutes(date.internal.getUTCMinutes() + offsetChange);\n Date.prototype.setUTCMinutes.call(date, Date.prototype.getUTCMinutes.call(date) + offsetChange);\n }\n }\n\n //#endregion\n}","import { tzName } from \"../tzName/index.js\";\nimport { TZDateMini } from \"./mini.js\";\nexport class TZDate extends TZDateMini {\n //#region static\n\n static tz(tz, ...args) {\n return args.length ? new TZDate(...args, tz) : new TZDate(Date.now(), tz);\n }\n\n //#endregion\n\n //#region representation\n\n toISOString() {\n const [sign, hours, minutes] = this.tzComponents();\n const tz = `${sign}${hours}:${minutes}`;\n return this.internal.toISOString().slice(0, -1) + tz;\n }\n toString() {\n // \"Tue Aug 13 2024 07:50:19 GMT+0800 (Singapore Standard Time)\";\n return `${this.toDateString()} ${this.toTimeString()}`;\n }\n toDateString() {\n // toUTCString returns RFC 7231 (\"Mon, 12 Aug 2024 23:36:08 GMT\")\n const [day, date, month, year] = this.internal.toUTCString().split(\" \");\n // \"Tue Aug 13 2024\"\n return `${day?.slice(0, -1) /* Remove \",\" */} ${month} ${date} ${year}`;\n }\n toTimeString() {\n // toUTCString returns RFC 7231 (\"Mon, 12 Aug 2024 23:36:08 GMT\")\n const time = this.internal.toUTCString().split(\" \")[4];\n const [sign, hours, minutes] = this.tzComponents();\n // \"07:42:23 GMT+0800 (Singapore Standard Time)\"\n return `${time} GMT${sign}${hours}${minutes} (${tzName(this.timeZone, this)})`;\n }\n toLocaleString(locales, options) {\n return Date.prototype.toLocaleString.call(this, locales, {\n ...options,\n timeZone: options?.timeZone || this.timeZone\n });\n }\n toLocaleDateString(locales, options) {\n return Date.prototype.toLocaleDateString.call(this, locales, {\n ...options,\n timeZone: options?.timeZone || this.timeZone\n });\n }\n toLocaleTimeString(locales, options) {\n return Date.prototype.toLocaleTimeString.call(this, locales, {\n ...options,\n timeZone: options?.timeZone || this.timeZone\n });\n }\n\n //#endregion\n\n //#region private\n\n tzComponents() {\n const offset = this.getTimezoneOffset();\n const sign = offset > 0 ? \"-\" : \"+\";\n const hours = String(Math.floor(Math.abs(offset) / 60)).padStart(2, \"0\");\n const minutes = String(Math.abs(offset) % 60).padStart(2, \"0\");\n return [sign, hours, minutes];\n }\n\n //#endregion\n\n withTimeZone(timeZone) {\n return new TZDate(+this, timeZone);\n }\n\n //#region date-fns integration\n\n [Symbol.for(\"constructDateFrom\")](date) {\n return new TZDate(+new Date(date), this.timeZone);\n }\n\n //#endregion\n}","/**\n * @module constants\n * @summary Useful constants\n * @description\n * Collection of useful date constants.\n *\n * The constants could be imported from `date-fns/constants`:\n *\n * ```ts\n * import { maxTime, minTime } from \"./constants/date-fns/constants\";\n *\n * function isAllowedTime(time) {\n * return time <= maxTime && time >= minTime;\n * }\n * ```\n */\n\n/**\n * @constant\n * @name daysInWeek\n * @summary Days in 1 week.\n */\nexport const daysInWeek = 7;\n\n/**\n * @constant\n * @name daysInYear\n * @summary Days in 1 year.\n *\n * @description\n * How many days in a year.\n *\n * One years equals 365.2425 days according to the formula:\n *\n * > Leap year occurs every 4 years, except for years that are divisible by 100 and not divisible by 400.\n * > 1 mean year = (365+1/4-1/100+1/400) days = 365.2425 days\n */\nexport const daysInYear = 365.2425;\n\n/**\n * @constant\n * @name maxTime\n * @summary Maximum allowed time.\n *\n * @example\n * import { maxTime } from \"./constants/date-fns/constants\";\n *\n * const isValid = 8640000000000001 <= maxTime;\n * //=> false\n *\n * new Date(8640000000000001);\n * //=> Invalid Date\n */\nexport const maxTime = Math.pow(10, 8) * 24 * 60 * 60 * 1000;\n\n/**\n * @constant\n * @name minTime\n * @summary Minimum allowed time.\n *\n * @example\n * import { minTime } from \"./constants/date-fns/constants\";\n *\n * const isValid = -8640000000000001 >= minTime;\n * //=> false\n *\n * new Date(-8640000000000001)\n * //=> Invalid Date\n */\nexport const minTime = -maxTime;\n\n/**\n * @constant\n * @name millisecondsInWeek\n * @summary Milliseconds in 1 week.\n */\nexport const millisecondsInWeek = 604800000;\n\n/**\n * @constant\n * @name millisecondsInDay\n * @summary Milliseconds in 1 day.\n */\nexport const millisecondsInDay = 86400000;\n\n/**\n * @constant\n * @name millisecondsInMinute\n * @summary Milliseconds in 1 minute\n */\nexport const millisecondsInMinute = 60000;\n\n/**\n * @constant\n * @name millisecondsInHour\n * @summary Milliseconds in 1 hour\n */\nexport const millisecondsInHour = 3600000;\n\n/**\n * @constant\n * @name millisecondsInSecond\n * @summary Milliseconds in 1 second\n */\nexport const millisecondsInSecond = 1000;\n\n/**\n * @constant\n * @name minutesInYear\n * @summary Minutes in 1 year.\n */\nexport const minutesInYear = 525600;\n\n/**\n * @constant\n * @name minutesInMonth\n * @summary Minutes in 1 month.\n */\nexport const minutesInMonth = 43200;\n\n/**\n * @constant\n * @name minutesInDay\n * @summary Minutes in 1 day.\n */\nexport const minutesInDay = 1440;\n\n/**\n * @constant\n * @name minutesInHour\n * @summary Minutes in 1 hour.\n */\nexport const minutesInHour = 60;\n\n/**\n * @constant\n * @name monthsInQuarter\n * @summary Months in 1 quarter.\n */\nexport const monthsInQuarter = 3;\n\n/**\n * @constant\n * @name monthsInYear\n * @summary Months in 1 year.\n */\nexport const monthsInYear = 12;\n\n/**\n * @constant\n * @name quartersInYear\n * @summary Quarters in 1 year\n */\nexport const quartersInYear = 4;\n\n/**\n * @constant\n * @name secondsInHour\n * @summary Seconds in 1 hour.\n */\nexport const secondsInHour = 3600;\n\n/**\n * @constant\n * @name secondsInMinute\n * @summary Seconds in 1 minute.\n */\nexport const secondsInMinute = 60;\n\n/**\n * @constant\n * @name secondsInDay\n * @summary Seconds in 1 day.\n */\nexport const secondsInDay = secondsInHour * 24;\n\n/**\n * @constant\n * @name secondsInWeek\n * @summary Seconds in 1 week.\n */\nexport const secondsInWeek = secondsInDay * 7;\n\n/**\n * @constant\n * @name secondsInYear\n * @summary Seconds in 1 year.\n */\nexport const secondsInYear = secondsInDay * daysInYear;\n\n/**\n * @constant\n * @name secondsInMonth\n * @summary Seconds in 1 month\n */\nexport const secondsInMonth = secondsInYear / 12;\n\n/**\n * @constant\n * @name secondsInQuarter\n * @summary Seconds in 1 quarter.\n */\nexport const secondsInQuarter = secondsInMonth * 3;\n\n/**\n * @constant\n * @name constructFromSymbol\n * @summary Symbol enabling Date extensions to inherit properties from the reference date.\n *\n * The symbol is used to enable the `constructFrom` function to construct a date\n * using a reference date and a value. It allows to transfer extra properties\n * from the reference date to the new date. It's useful for extensions like\n * [`TZDate`](https://github.com/date-fns/tz) that accept a time zone as\n * a constructor argument.\n */\nexport const constructFromSymbol = Symbol.for(\"constructDateFrom\");\n","import { constructFromSymbol } from \"./constants.js\";\n\n/**\n * @name constructFrom\n * @category Generic Helpers\n * @summary Constructs a date using the reference date and the value\n *\n * @description\n * The function constructs a new date using the constructor from the reference\n * date and the given value. It helps to build generic functions that accept\n * date extensions.\n *\n * It defaults to `Date` if the passed reference date is a number or a string.\n *\n * Starting from v3.7.0, it allows to construct a date using `[Symbol.for(\"constructDateFrom\")]`\n * enabling to transfer extra properties from the reference date to the new date.\n * It's useful for extensions like [`TZDate`](https://github.com/date-fns/tz)\n * that accept a time zone as a constructor argument.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n *\n * @param date - The reference date to take constructor from\n * @param value - The value to create the date\n *\n * @returns Date initialized using the given date and value\n *\n * @example\n * import { constructFrom } from \"./constructFrom/date-fns\";\n *\n * // A function that clones a date preserving the original type\n * function cloneDate<DateType extends Date>(date: DateType): DateType {\n * return constructFrom(\n * date, // Use constructor from the given date\n * date.getTime() // Use the date value to create a new date\n * );\n * }\n */\nexport function constructFrom(date, value) {\n if (typeof date === \"function\") return date(value);\n\n if (date && typeof date === \"object\" && constructFromSymbol in date)\n return date[constructFromSymbol](value);\n\n if (date instanceof Date) return new date.constructor(value);\n\n return new Date(value);\n}\n\n// Fallback for modularized imports:\nexport default constructFrom;\n","import { constructFrom } from \"./constructFrom.js\";\n\n/**\n * @name toDate\n * @category Common Helpers\n * @summary Convert the given argument to an instance of Date.\n *\n * @description\n * Convert the given argument to an instance of Date.\n *\n * If the argument is an instance of Date, the function returns its clone.\n *\n * If the argument is a number, it is treated as a timestamp.\n *\n * If the argument is none of the above, the function returns Invalid Date.\n *\n * Starting from v3.7.0, it clones a date using `[Symbol.for(\"constructDateFrom\")]`\n * enabling to transfer extra properties from the reference date to the new date.\n * It's useful for extensions like [`TZDate`](https://github.com/date-fns/tz)\n * that accept a time zone as a constructor argument.\n *\n * **Note**: *all* Date arguments passed to any *date-fns* function is processed by `toDate`.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param argument - The value to convert\n *\n * @returns The parsed date in the local time zone\n *\n * @example\n * // Clone the date:\n * const result = toDate(new Date(2014, 1, 11, 11, 30, 30))\n * //=> Tue Feb 11 2014 11:30:30\n *\n * @example\n * // Convert the timestamp to date:\n * const result = toDate(1392098430000)\n * //=> Tue Feb 11 2014 11:30:30\n */\nexport function toDate(argument, context) {\n // [TODO] Get rid of `toDate` or `constructFrom`?\n return constructFrom(context || argument, argument);\n}\n\n// Fallback for modularized imports:\nexport default toDate;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link addDays} function options.\n */\n\n/**\n * @name addDays\n * @category Day Helpers\n * @summary Add the specified number of days to the given date.\n *\n * @description\n * Add the specified number of days to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param amount - The amount of days to be added.\n * @param options - An object with options\n *\n * @returns The new date with the days added\n *\n * @example\n * // Add 10 days to 1 September 2014:\n * const result = addDays(new Date(2014, 8, 1), 10)\n * //=> Thu Sep 11 2014 00:00:00\n */\nexport function addDays(date, amount, options) {\n const _date = toDate(date, options?.in);\n if (isNaN(amount)) return constructFrom(options?.in || date, NaN);\n\n // If 0 days, no-op to avoid changing times in the hour before end of DST\n if (!amount) return _date;\n\n _date.setDate(_date.getDate() + amount);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default addDays;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link addMonths} function options.\n */\n\n/**\n * @name addMonths\n * @category Month Helpers\n * @summary Add the specified number of months to the given date.\n *\n * @description\n * Add the specified number of months to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param amount - The amount of months to be added.\n * @param options - The options object\n *\n * @returns The new date with the months added\n *\n * @example\n * // Add 5 months to 1 September 2014:\n * const result = addMonths(new Date(2014, 8, 1), 5)\n * //=> Sun Feb 01 2015 00:00:00\n *\n * // Add one month to 30 January 2023:\n * const result = addMonths(new Date(2023, 0, 30), 1)\n * //=> Tue Feb 28 2023 00:00:00\n */\nexport function addMonths(date, amount, options) {\n const _date = toDate(date, options?.in);\n if (isNaN(amount)) return constructFrom(options?.in || date, NaN);\n if (!amount) {\n // If 0 months, no-op to avoid changing times in the hour before end of DST\n return _date;\n }\n const dayOfMonth = _date.getDate();\n\n // The JS Date object supports date math by accepting out-of-bounds values for\n // month, day, etc. For example, new Date(2020, 0, 0) returns 31 Dec 2019 and\n // new Date(2020, 13, 1) returns 1 Feb 2021. This is *almost* the behavior we\n // want except that dates will wrap around the end of a month, meaning that\n // new Date(2020, 13, 31) will return 3 Mar 2021 not 28 Feb 2021 as desired. So\n // we'll default to the end of the desired month by adding 1 to the desired\n // month and using a date of 0 to back up one day to the end of the desired\n // month.\n const endOfDesiredMonth = constructFrom(options?.in || date, _date.getTime());\n endOfDesiredMonth.setMonth(_date.getMonth() + amount + 1, 0);\n const daysInMonth = endOfDesiredMonth.getDate();\n if (dayOfMonth >= daysInMonth) {\n // If we're already at the end of the month, then this is the correct date\n // and we're done.\n return endOfDesiredMonth;\n } else {\n // Otherwise, we now know that setting the original day-of-month value won't\n // cause an overflow, so set the desired day-of-month. Note that we can't\n // just set the date of `endOfDesiredMonth` because that object may have had\n // its time changed in the unusual case where where a DST transition was on\n // the last day of the month and its local time was in the hour skipped or\n // repeated next to a DST transition. So we use `date` instead which is\n // guaranteed to still have the original time.\n _date.setFullYear(\n endOfDesiredMonth.getFullYear(),\n endOfDesiredMonth.getMonth(),\n dayOfMonth,\n );\n return _date;\n }\n}\n\n// Fallback for modularized imports:\nexport default addMonths;\n","let defaultOptions = {};\n\nexport function getDefaultOptions() {\n return defaultOptions;\n}\n\nexport function setDefaultOptions(newOptions) {\n defaultOptions = newOptions;\n}\n","import { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link startOfWeek} function options.\n */\n\n/**\n * @name startOfWeek\n * @category Week Helpers\n * @summary Return the start of a week for the given date.\n *\n * @description\n * Return the start of a week for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of a week\n *\n * @example\n * // The start of a week for 2 September 2014 11:55:00:\n * const result = startOfWeek(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Sun Aug 31 2014 00:00:00\n *\n * @example\n * // If the week starts on Monday, the start of the week for 2 September 2014 11:55:00:\n * const result = startOfWeek(new Date(2014, 8, 2, 11, 55, 0), { weekStartsOn: 1 })\n * //=> Mon Sep 01 2014 00:00:00\n */\nexport function startOfWeek(date, options) {\n const defaultOptions = getDefaultOptions();\n const weekStartsOn =\n options?.weekStartsOn ??\n options?.locale?.options?.weekStartsOn ??\n defaultOptions.weekStartsOn ??\n defaultOptions.locale?.options?.weekStartsOn ??\n 0;\n\n const _date = toDate(date, options?.in);\n const day = _date.getDay();\n const diff = (day < weekStartsOn ? 7 : 0) + day - weekStartsOn;\n\n _date.setDate(_date.getDate() - diff);\n _date.setHours(0, 0, 0, 0);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default startOfWeek;\n","import { startOfWeek } from \"./startOfWeek.js\";\n\n/**\n * The {@link startOfISOWeek} function options.\n */\n\n/**\n * @name startOfISOWeek\n * @category ISO Week Helpers\n * @summary Return the start of an ISO week for the given date.\n *\n * @description\n * Return the start of an ISO week for the given date.\n * The result will be in the local timezone.\n *\n * ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of an ISO week\n *\n * @example\n * // The start of an ISO week for 2 September 2014 11:55:00:\n * const result = startOfISOWeek(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Mon Sep 01 2014 00:00:00\n */\nexport function startOfISOWeek(date, options) {\n return startOfWeek(date, { ...options, weekStartsOn: 1 });\n}\n\n// Fallback for modularized imports:\nexport default startOfISOWeek;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { startOfISOWeek } from \"./startOfISOWeek.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getISOWeekYear} function options.\n */\n\n/**\n * @name getISOWeekYear\n * @category ISO Week-Numbering Year Helpers\n * @summary Get the ISO week-numbering year of the given date.\n *\n * @description\n * Get the ISO week-numbering year of the given date,\n * which always starts 3 days before the year's first Thursday.\n *\n * ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date\n *\n * @param date - The given date\n *\n * @returns The ISO week-numbering year\n *\n * @example\n * // Which ISO-week numbering year is 2 January 2005?\n * const result = getISOWeekYear(new Date(2005, 0, 2))\n * //=> 2004\n */\nexport function getISOWeekYear(date, options) {\n const _date = toDate(date, options?.in);\n const year = _date.getFullYear();\n\n const fourthOfJanuaryOfNextYear = constructFrom(_date, 0);\n fourthOfJanuaryOfNextYear.setFullYear(year + 1, 0, 4);\n fourthOfJanuaryOfNextYear.setHours(0, 0, 0, 0);\n const startOfNextYear = startOfISOWeek(fourthOfJanuaryOfNextYear);\n\n const fourthOfJanuaryOfThisYear = constructFrom(_date, 0);\n fourthOfJanuaryOfThisYear.setFullYear(year, 0, 4);\n fourthOfJanuaryOfThisYear.setHours(0, 0, 0, 0);\n const startOfThisYear = startOfISOWeek(fourthOfJanuaryOfThisYear);\n\n if (_date.getTime() >= startOfNextYear.getTime()) {\n return year + 1;\n } else if (_date.getTime() >= startOfThisYear.getTime()) {\n return year;\n } else {\n return year - 1;\n }\n}\n\n// Fallback for modularized imports:\nexport default getISOWeekYear;\n","import { toDate } from \"../toDate.js\";\n\n/**\n * Google Chrome as of 67.0.3396.87 introduced timezones with offset that includes seconds.\n * They usually appear for dates that denote time before the timezones were introduced\n * (e.g. for 'Europe/Prague' timezone the offset is GMT+00:57:44 before 1 October 1891\n * and GMT+01:00:00 after that date)\n *\n * Date#getTimezoneOffset returns the offset in minutes and would return 57 for the example above,\n * which would lead to incorrect calculations.\n *\n * This function returns the timezone offset in milliseconds that takes seconds in account.\n */\nexport function getTimezoneOffsetInMilliseconds(date) {\n const _date = toDate(date);\n const utcDate = new Date(\n Date.UTC(\n _date.getFullYear(),\n _date.getMonth(),\n _date.getDate(),\n _date.getHours(),\n _date.getMinutes(),\n _date.getSeconds(),\n _date.getMilliseconds(),\n ),\n );\n utcDate.setUTCFullYear(_date.getFullYear());\n return +date - +utcDate;\n}\n","import { constructFrom } from \"../constructFrom.js\";\n\nexport function normalizeDates(context, ...dates) {\n const normalize = constructFrom.bind(\n null,\n context || dates.find((date) => typeof date === \"object\"),\n );\n return dates.map(normalize);\n}\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link startOfDay} function options.\n */\n\n/**\n * @name startOfDay\n * @category Day Helpers\n * @summary Return the start of a day for the given date.\n *\n * @description\n * Return the start of a day for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - The options\n *\n * @returns The start of a day\n *\n * @example\n * // The start of a day for 2 September 2014 11:55:00:\n * const result = startOfDay(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Tue Sep 02 2014 00:00:00\n */\nexport function startOfDay(date, options) {\n const _date = toDate(date, options?.in);\n _date.setHours(0, 0, 0, 0);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default startOfDay;\n","import { getTimezoneOffsetInMilliseconds } from \"./_lib/getTimezoneOffsetInMilliseconds.js\";\nimport { normalizeDates } from \"./_lib/normalizeDates.js\";\nimport { millisecondsInDay } from \"./constants.js\";\nimport { startOfDay } from \"./startOfDay.js\";\n\n/**\n * The {@link differenceInCalendarDays} function options.\n */\n\n/**\n * @name differenceInCalendarDays\n * @category Day Helpers\n * @summary Get the number of calendar days between the given dates.\n *\n * @description\n * Get the number of calendar days between the given dates. This means that the times are removed\n * from the dates and then the difference in days is calculated.\n *\n * @param laterDate - The later date\n * @param earlierDate - The earlier date\n * @param options - The options object\n *\n * @returns The number of calendar days\n *\n * @example\n * // How many calendar days are between\n * // 2 July 2011 23:00:00 and 2 July 2012 00:00:00?\n * const result = differenceInCalendarDays(\n * new Date(2012, 6, 2, 0, 0),\n * new Date(2011, 6, 2, 23, 0)\n * )\n * //=> 366\n * // How many calendar days are between\n * // 2 July 2011 23:59:00 and 3 July 2011 00:01:00?\n * const result = differenceInCalendarDays(\n * new Date(2011, 6, 3, 0, 1),\n * new Date(2011, 6, 2, 23, 59)\n * )\n * //=> 1\n */\nexport function differenceInCalendarDays(laterDate, earlierDate, options) {\n const [laterDate_, earlierDate_] = normalizeDates(\n options?.in,\n laterDate,\n earlierDate,\n );\n\n const laterStartOfDay = startOfDay(laterDate_);\n const earlierStartOfDay = startOfDay(earlierDate_);\n\n const laterTimestamp =\n +laterStartOfDay - getTimezoneOffsetInMilliseconds(laterStartOfDay);\n const earlierTimestamp =\n +earlierStartOfDay - getTimezoneOffsetInMilliseconds(earlierStartOfDay);\n\n // Round the number of days to the nearest integer because the number of\n // milliseconds in a day is not constant (e.g. it's different in the week of\n // the daylight saving time clock shift).\n return Math.round((laterTimestamp - earlierTimestamp) / millisecondsInDay);\n}\n\n// Fallback for modularized imports:\nexport default differenceInCalendarDays;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { getISOWeekYear } from \"./getISOWeekYear.js\";\nimport { startOfISOWeek } from \"./startOfISOWeek.js\";\n\n/**\n * The {@link startOfISOWeekYear} function options.\n */\n\n/**\n * @name startOfISOWeekYear\n * @category ISO Week-Numbering Year Helpers\n * @summary Return the start of an ISO week-numbering year for the given date.\n *\n * @description\n * Return the start of an ISO week-numbering year,\n * which always starts 3 days before the year's first Thursday.\n * The result will be in the local timezone.\n *\n * ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of an ISO week-numbering year\n *\n * @example\n * // The start of an ISO week-numbering year for 2 July 2005:\n * const result = startOfISOWeekYear(new Date(2005, 6, 2))\n * //=> Mon Jan 03 2005 00:00:00\n */\nexport function startOfISOWeekYear(date, options) {\n const year = getISOWeekYear(date, options);\n const fourthOfJanuary = constructFrom(options?.in || date, 0);\n fourthOfJanuary.setFullYear(year, 0, 4);\n fourthOfJanuary.setHours(0, 0, 0, 0);\n return startOfISOWeek(fourthOfJanuary);\n}\n\n// Fallback for modularized imports:\nexport default startOfISOWeekYear;\n","import { addDays } from \"./addDays.js\";\n\n/**\n * The {@link addWeeks} function options.\n */\n\n/**\n * @name addWeeks\n * @category Week Helpers\n * @summary Add the specified number of weeks to the given date.\n *\n * @description\n * Add the specified number of weeks to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param amount - The amount of weeks to be added.\n * @param options - An object with options\n *\n * @returns The new date with the weeks added\n *\n * @example\n * // Add 4 weeks to 1 September 2014:\n * const result = addWeeks(new Date(2014, 8, 1), 4)\n * //=> Mon Sep 29 2014 00:00:00\n */\nexport function addWeeks(date, amount, options) {\n return addDays(date, amount * 7, options);\n}\n\n// Fallback for modularized imports:\nexport default addWeeks;\n","import { addMonths } from \"./addMonths.js\";\n\n/**\n * The {@link addYears} function options.\n */\n\n/**\n * @name addYears\n * @category Year Helpers\n * @summary Add the specified number of years to the given date.\n *\n * @description\n * Add the specified number of years to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type.\n *\n * @param date - The date to be changed\n * @param amount - The amount of years to be added.\n * @param options - The options\n *\n * @returns The new date with the years added\n *\n * @example\n * // Add 5 years to 1 September 2014:\n * const result = addYears(new Date(2014, 8, 1), 5)\n * //=> Sun Sep 01 2019 00:00:00\n */\nexport function addYears(date, amount, options) {\n return addMonths(date, amount * 12, options);\n}\n\n// Fallback for modularized imports:\nexport default addYears;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link max} function options.\n */\n\n/**\n * @name max\n * @category Common Helpers\n * @summary Return the latest of the given dates.\n *\n * @description\n * Return the latest of the given dates.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param dates - The dates to compare\n *\n * @returns The latest of the dates\n *\n * @example\n * // Which of these dates is the latest?\n * const result = max([\n * new Date(1989, 6, 10),\n * new Date(1987, 1, 11),\n * new Date(1995, 6, 2),\n * new Date(1990, 0, 1)\n * ])\n * //=> Sun Jul 02 1995 00:00:00\n */\nexport function max(dates, options) {\n let result;\n let context = options?.in;\n\n dates.forEach((date) => {\n // Use the first date object as the context function\n if (!context && typeof date === \"object\")\n context = constructFrom.bind(null, date);\n\n const date_ = toDate(date, context);\n if (!result || result < date_ || isNaN(+date_)) result = date_;\n });\n\n return constructFrom(context, result || NaN);\n}\n\n// Fallback for modularized imports:\nexport default max;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link min} function options.\n */\n\n/**\n * @name min\n * @category Common Helpers\n * @summary Returns the earliest of the given dates.\n *\n * @description\n * Returns the earliest of the given dates.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param dates - The dates to compare\n *\n * @returns The earliest of the dates\n *\n * @example\n * // Which of these dates is the earliest?\n * const result = min([\n * new Date(1989, 6, 10),\n * new Date(1987, 1, 11),\n * new Date(1995, 6, 2),\n * new Date(1990, 0, 1)\n * ])\n * //=> Wed Feb 11 1987 00:00:00\n */\nexport function min(dates, options) {\n let result;\n let context = options?.in;\n\n dates.forEach((date) => {\n // Use the first date object as the context function\n if (!context && typeof date === \"object\")\n context = constructFrom.bind(null, date);\n\n const date_ = toDate(date, context);\n if (!result || result > date_ || isNaN(+date_)) result = date_;\n });\n\n return constructFrom(context, result || NaN);\n}\n\n// Fallback for modularized imports:\nexport default min;\n","import { normalizeDates } from \"./_lib/normalizeDates.js\";\nimport { startOfDay } from \"./startOfDay.js\";\n\n/**\n * The {@link isSameDay} function options.\n */\n\n/**\n * @name isSameDay\n * @category Day Helpers\n * @summary Are the given dates in the same day (and year and month)?\n *\n * @description\n * Are the given dates in the same day (and year and month)?\n *\n * @param laterDate - The first date to check\n * @param earlierDate - The second date to check\n * @param options - An object with options\n *\n * @returns The dates are in the same day (and year and month)\n *\n * @example\n * // Are 4 September 06:00:00 and 4 September 18:00:00 in the same day?\n * const result = isSameDay(new Date(2014, 8, 4, 6, 0), new Date(2014, 8, 4, 18, 0))\n * //=> true\n *\n * @example\n * // Are 4 September and 4 October in the same day?\n * const result = isSameDay(new Date(2014, 8, 4), new Date(2014, 9, 4))\n * //=> false\n *\n * @example\n * // Are 4 September, 2014 and 4 September, 2015 in the same day?\n * const result = isSameDay(new Date(2014, 8, 4), new Date(2015, 8, 4))\n * //=> false\n */\nexport function isSameDay(laterDate, earlierDate, options) {\n const [dateLeft_, dateRight_] = normalizeDates(\n options?.in,\n laterDate,\n earlierDate,\n );\n return +startOfDay(dateLeft_) === +startOfDay(dateRight_);\n}\n\n// Fallback for modularized imports:\nexport default isSameDay;\n","/**\n * @name isDate\n * @category Common Helpers\n * @summary Is the given value a date?\n *\n * @description\n * Returns true if the given value is an instance of Date. The function works for dates transferred across iframes.\n *\n * @param value - The value to check\n *\n * @returns True if the given value is a date\n *\n * @example\n * // For a valid date:\n * const result = isDate(new Date())\n * //=> true\n *\n * @example\n * // For an invalid date:\n * const result = isDate(new Date(NaN))\n * //=> true\n *\n * @example\n * // For some value:\n * const result = isDate('2014-02-31')\n * //=> false\n *\n * @example\n * // For an object:\n * const result = isDate({})\n * //=> false\n */\nexport function isDate(value) {\n return (\n value instanceof Date ||\n (typeof value === \"object\" &&\n Object.prototype.toString.call(value) === \"[object Date]\")\n );\n}\n\n// Fallback for modularized imports:\nexport default isDate;\n","import { isDate } from \"./isDate.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * @name isValid\n * @category Common Helpers\n * @summary Is the given date valid?\n *\n * @description\n * Returns false if argument is Invalid Date and true otherwise.\n * Argument is converted to Date using `toDate`. See [toDate](https://date-fns.org/docs/toDate)\n * Invalid Date is a Date, whose time value is NaN.\n *\n * Time value of Date: http://es5.github.io/#x15.9.1.1\n *\n * @param date - The date to check\n *\n * @returns The date is valid\n *\n * @example\n * // For the valid date:\n * const result = isValid(new Date(2014, 1, 31))\n * //=> true\n *\n * @example\n * // For the value, convertible into a date:\n * const result = isValid(1393804800000)\n * //=> true\n *\n * @example\n * // For the invalid date:\n * const result = isValid(new Date(''))\n * //=> false\n */\nexport function isValid(date) {\n return !((!isDate(date) && typeof date !== \"number\") || isNaN(+toDate(date)));\n}\n\n// Fallback for modularized imports:\nexport default isValid;\n","import { normalizeDates } from \"./_lib/normalizeDates.js\";\n\n/**\n * The {@link differenceInCalendarMonths} function options.\n */\n\n/**\n * @name differenceInCalendarMonths\n * @category Month Helpers\n * @summary Get the number of calendar months between the given dates.\n *\n * @description\n * Get the number of calendar months between the given dates.\n *\n * @param laterDate - The later date\n * @param earlierDate - The earlier date\n * @param options - An object with options\n *\n * @returns The number of calendar months\n *\n * @example\n * // How many calendar months are between 31 January 2014 and 1 September 2014?\n * const result = differenceInCalendarMonths(\n * new Date(2014, 8, 1),\n * new Date(2014, 0, 31)\n * )\n * //=> 8\n */\nexport function differenceInCalendarMonths(laterDate, earlierDate, options) {\n const [laterDate_, earlierDate_] = normalizeDates(\n options?.in,\n laterDate,\n earlierDate,\n );\n\n const yearsDiff = laterDate_.getFullYear() - earlierDate_.getFullYear();\n const monthsDiff = laterDate_.getMonth() - earlierDate_.getMonth();\n\n return yearsDiff * 12 + monthsDiff;\n}\n\n// Fallback for modularized imports:\nexport default differenceInCalendarMonths;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link endOfMonth} function options.\n */\n\n/**\n * @name endOfMonth\n * @category Month Helpers\n * @summary Return the end of a month for the given date.\n *\n * @description\n * Return the end of a month for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The end of a month\n *\n * @example\n * // The end of a month for 2 September 2014 11:55:00:\n * const result = endOfMonth(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Tue Sep 30 2014 23:59:59.999\n */\nexport function endOfMonth(date, options) {\n const _date = toDate(date, options?.in);\n const month = _date.getMonth();\n _date.setFullYear(_date.getFullYear(), month + 1, 0);\n _date.setHours(23, 59, 59, 999);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default endOfMonth;\n","import { normalizeDates } from \"./normalizeDates.js\";\n\nexport function normalizeInterval(context, interval) {\n const [start, end] = normalizeDates(context, interval.start, interval.end);\n return { start, end };\n}\n","import { normalizeInterval } from \"./_lib/normalizeInterval.js\";\nimport { constructFrom } from \"./constructFrom.js\";\n\n/**\n * The {@link eachMonthOfInterval} function options.\n */\n\n/**\n * The {@link eachMonthOfInterval} function result type. It resolves the proper data type.\n */\n\n/**\n * @name eachMonthOfInterval\n * @category Interval Helpers\n * @summary Return the array of months within the specified time interval.\n *\n * @description\n * Return the array of months within the specified time interval.\n *\n * @typeParam IntervalType - Interval type.\n * @typeParam Options - Options type.\n *\n * @param interval - The interval.\n * @param options - An object with options.\n *\n * @returns The array with starts of months from the month of the interval start to the month of the interval end\n *\n * @example\n * // Each month between 6 February 2014 and 10 August 2014:\n * const result = eachMonthOfInterval({\n * start: new Date(2014, 1, 6),\n * end: new Date(2014, 7, 10)\n * })\n * //=> [\n * // Sat Feb 01 2014 00:00:00,\n * // Sat Mar 01 2014 00:00:00,\n * // Tue Apr 01 2014 00:00:00,\n * // Thu May 01 2014 00:00:00,\n * // Sun Jun 01 2014 00:00:00,\n * // Tue Jul 01 2014 00:00:00,\n * // Fri Aug 01 2014 00:00:00\n * // ]\n */\nexport function eachMonthOfInterval(interval, options) {\n const { start, end } = normalizeInterval(options?.in, interval);\n\n let reversed = +start > +end;\n const endTime = reversed ? +start : +end;\n const date = reversed ? end : start;\n date.setHours(0, 0, 0, 0);\n date.setDate(1);\n\n let step = options?.step ?? 1;\n if (!step) return [];\n if (step < 0) {\n step = -step;\n reversed = !reversed;\n }\n\n const dates = [];\n\n while (+date <= endTime) {\n dates.push(constructFrom(start, date));\n date.setMonth(date.getMonth() + step);\n }\n\n return reversed ? dates.reverse() : dates;\n}\n\n// Fallback for modularized imports:\nexport default eachMonthOfInterval;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link startOfMonth} function options.\n */\n\n/**\n * @name startOfMonth\n * @category Month Helpers\n * @summary Return the start of a month for the given date.\n *\n * @description\n * Return the start of a month for the given date. The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments.\n * Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed,\n * or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of a month\n *\n * @example\n * // The start of a month for 2 September 2014 11:55:00:\n * const result = startOfMonth(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Mon Sep 01 2014 00:00:00\n */\nexport function startOfMonth(date, options) {\n const _date = toDate(date, options?.in);\n _date.setDate(1);\n _date.setHours(0, 0, 0, 0);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default startOfMonth;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link endOfYear} function options.\n */\n\n/**\n * @name endOfYear\n * @category Year Helpers\n * @summary Return the end of a year for the given date.\n *\n * @description\n * Return the end of a year for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - The options\n *\n * @returns The end of a year\n *\n * @example\n * // The end of a year for 2 September 2014 11:55:00:\n * const result = endOfYear(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Wed Dec 31 2014 23:59:59.999\n */\nexport function endOfYear(date, options) {\n const _date = toDate(date, options?.in);\n const year = _date.getFullYear();\n _date.setFullYear(year + 1, 0, 0);\n _date.setHours(23, 59, 59, 999);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default endOfYear;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link startOfYear} function options.\n */\n\n/**\n * @name startOfYear\n * @category Year Helpers\n * @summary Return the start of a year for the given date.\n *\n * @description\n * Return the start of a year for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - The options\n *\n * @returns The start of a year\n *\n * @example\n * // The start of a year for 2 September 2014 11:55:00:\n * const result = startOfYear(new Date(2014, 8, 2, 11, 55, 00))\n * //=> Wed Jan 01 2014 00:00:00\n */\nexport function startOfYear(date, options) {\n const date_ = toDate(date, options?.in);\n date_.setFullYear(date_.getFullYear(), 0, 1);\n date_.setHours(0, 0, 0, 0);\n return date_;\n}\n\n// Fallback for modularized imports:\nexport default startOfYear;\n","import { normalizeInterval } from \"./_lib/normalizeInterval.js\";\nimport { constructFrom } from \"./constructFrom.js\";\n\n/**\n * The {@link eachYearOfInterval} function options.\n */\n\n/**\n * The {@link eachYearOfInterval} function result type. It resolves the proper data type.\n * It uses the first argument date object type, starting from the date argument,\n * then the start interval date, and finally the end interval date. If\n * a context function is passed, it uses the context function return type.\n */\n\n/**\n * @name eachYearOfInterval\n * @category Interval Helpers\n * @summary Return the array of yearly timestamps within the specified time interval.\n *\n * @description\n * Return the array of yearly timestamps within the specified time interval.\n *\n * @typeParam IntervalType - Interval type.\n * @typeParam Options - Options type.\n *\n * @param interval - The interval.\n * @param options - An object with options.\n *\n * @returns The array with starts of yearly timestamps from the month of the interval start to the month of the interval end\n *\n * @example\n * // Each year between 6 February 2014 and 10 August 2017:\n * const result = eachYearOfInterval({\n * start: new Date(2014, 1, 6),\n * end: new Date(2017, 7, 10)\n * })\n * //=> [\n * // Wed Jan 01 2014 00:00:00,\n * // Thu Jan 01 2015 00:00:00,\n * // Fri Jan 01 2016 00:00:00,\n * // Sun Jan 01 2017 00:00:00\n * // ]\n */\nexport function eachYearOfInterval(interval, options) {\n const { start, end } = normalizeInterval(options?.in, interval);\n\n let reversed = +start > +end;\n const endTime = reversed ? +start : +end;\n const date = reversed ? end : start;\n date.setHours(0, 0, 0, 0);\n date.setMonth(0, 1);\n\n let step = options?.step ?? 1;\n if (!step) return [];\n if (step < 0) {\n step = -step;\n reversed = !reversed;\n }\n\n const dates = [];\n\n while (+date <= endTime) {\n dates.push(constructFrom(start, date));\n date.setFullYear(date.getFullYear() + step);\n }\n\n return reversed ? dates.reverse() : dates;\n}\n\n// Fallback for modularized imports:\nexport default eachYearOfInterval;\n","import { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link endOfWeek} function options.\n */\n\n/**\n * @name endOfWeek\n * @category Week Helpers\n * @summary Return the end of a week for the given date.\n *\n * @description\n * Return the end of a week for the given date.\n * The result will be in the local timezone.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The end of a week\n *\n * @example\n * // The end of a week for 2 September 2014 11:55:00:\n * const result = endOfWeek(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Sat Sep 06 2014 23:59:59.999\n *\n * @example\n * // If the week starts on Monday, the end of the week for 2 September 2014 11:55:00:\n * const result = endOfWeek(new Date(2014, 8, 2, 11, 55, 0), { weekStartsOn: 1 })\n * //=> Sun Sep 07 2014 23:59:59.999\n */\nexport function endOfWeek(date, options) {\n const defaultOptions = getDefaultOptions();\n const weekStartsOn =\n options?.weekStartsOn ??\n options?.locale?.options?.weekStartsOn ??\n defaultOptions.weekStartsOn ??\n defaultOptions.locale?.options?.weekStartsOn ??\n 0;\n\n const _date = toDate(date, options?.in);\n const day = _date.getDay();\n const diff = (day < weekStartsOn ? -7 : 0) + 6 - (day - weekStartsOn);\n\n _date.setDate(_date.getDate() + diff);\n _date.setHours(23, 59, 59, 999);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default endOfWeek;\n","import { endOfWeek } from \"./endOfWeek.js\";\n\n/**\n * The {@link endOfISOWeek} function options.\n */\n\n/**\n * @name endOfISOWeek\n * @category ISO Week Helpers\n * @summary Return the end of an ISO week for the given date.\n *\n * @description\n * Return the end of an ISO week for the given date.\n * The result will be in the local timezone.\n *\n * ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The end of an ISO week\n *\n * @example\n * // The end of an ISO week for 2 September 2014 11:55:00:\n * const result = endOfISOWeek(new Date(2014, 8, 2, 11, 55, 0))\n * //=> Sun Sep 07 2014 23:59:59.999\n */\nexport function endOfISOWeek(date, options) {\n return endOfWeek(date, { ...options, weekStartsOn: 1 });\n}\n\n// Fallback for modularized imports:\nexport default endOfISOWeek;\n","const formatDistanceLocale = {\n lessThanXSeconds: {\n one: \"less than a second\",\n other: \"less than {{count}} seconds\",\n },\n\n xSeconds: {\n one: \"1 second\",\n other: \"{{count}} seconds\",\n },\n\n halfAMinute: \"half a minute\",\n\n lessThanXMinutes: {\n one: \"less than a minute\",\n other: \"less than {{count}} minutes\",\n },\n\n xMinutes: {\n one: \"1 minute\",\n other: \"{{count}} minutes\",\n },\n\n aboutXHours: {\n one: \"about 1 hour\",\n other: \"about {{count}} hours\",\n },\n\n xHours: {\n one: \"1 hour\",\n other: \"{{count}} hours\",\n },\n\n xDays: {\n one: \"1 day\",\n other: \"{{count}} days\",\n },\n\n aboutXWeeks: {\n one: \"about 1 week\",\n other: \"about {{count}} weeks\",\n },\n\n xWeeks: {\n one: \"1 week\",\n other: \"{{count}} weeks\",\n },\n\n aboutXMonths: {\n one: \"about 1 month\",\n other: \"about {{count}} months\",\n },\n\n xMonths: {\n one: \"1 month\",\n other: \"{{count}} months\",\n },\n\n aboutXYears: {\n one: \"about 1 year\",\n other: \"about {{count}} years\",\n },\n\n xYears: {\n one: \"1 year\",\n other: \"{{count}} years\",\n },\n\n overXYears: {\n one: \"over 1 year\",\n other: \"over {{count}} years\",\n },\n\n almostXYears: {\n one: \"almost 1 year\",\n other: \"almost {{count}} years\",\n },\n};\n\nexport const formatDistance = (token, count, options) => {\n let result;\n\n const tokenValue = formatDistanceLocale[token];\n if (typeof tokenValue === \"string\") {\n result = tokenValue;\n } else if (count === 1) {\n result = tokenValue.one;\n } else {\n result = tokenValue.other.replace(\"{{count}}\", count.toString());\n }\n\n if (options?.addSuffix) {\n if (options.comparison && options.comparison > 0) {\n return \"in \" + result;\n } else {\n return result + \" ago\";\n }\n }\n\n return result;\n};\n","export function buildFormatLongFn(args) {\n return (options = {}) => {\n // TODO: Remove String()\n const width = options.width ? String(options.width) : args.defaultWidth;\n const format = args.formats[width] || args.formats[args.defaultWidth];\n return format;\n };\n}\n","import { buildFormatLongFn } from \"../../_lib/buildFormatLongFn.js\";\n\nconst dateFormats = {\n full: \"EEEE, MMMM do, y\",\n long: \"MMMM do, y\",\n medium: \"MMM d, y\",\n short: \"MM/dd/yyyy\",\n};\n\nconst timeFormats = {\n full: \"h:mm:ss a zzzz\",\n long: \"h:mm:ss a z\",\n medium: \"h:mm:ss a\",\n short: \"h:mm a\",\n};\n\nconst dateTimeFormats = {\n full: \"{{date}} 'at' {{time}}\",\n long: \"{{date}} 'at' {{time}}\",\n medium: \"{{date}}, {{time}}\",\n short: \"{{date}}, {{time}}\",\n};\n\nexport const formatLong = {\n date: buildFormatLongFn({\n formats: dateFormats,\n defaultWidth: \"full\",\n }),\n\n time: buildFormatLongFn({\n formats: timeFormats,\n defaultWidth: \"full\",\n }),\n\n dateTime: buildFormatLongFn({\n formats: dateTimeFormats,\n defaultWidth: \"full\",\n }),\n};\n","const formatRelativeLocale = {\n lastWeek: \"'last' eeee 'at' p\",\n yesterday: \"'yesterday at' p\",\n today: \"'today at' p\",\n tomorrow: \"'tomorrow at' p\",\n nextWeek: \"eeee 'at' p\",\n other: \"P\",\n};\n\nexport const formatRelative = (token, _date, _baseDate, _options) =>\n formatRelativeLocale[token];\n","/**\n * The localize function argument callback which allows to convert raw value to\n * the actual type.\n *\n * @param value - The value to convert\n *\n * @returns The converted value\n */\n\n/**\n * The map of localized values for each width.\n */\n\n/**\n * The index type of the locale unit value. It types conversion of units of\n * values that don't start at 0 (i.e. quarters).\n */\n\n/**\n * Converts the unit value to the tuple of values.\n */\n\n/**\n * The tuple of localized era values. The first element represents BC,\n * the second element represents AD.\n */\n\n/**\n * The tuple of localized quarter values. The first element represents Q1.\n */\n\n/**\n * The tuple of localized day values. The first element represents Sunday.\n */\n\n/**\n * The tuple of localized month values. The first element represents January.\n */\n\nexport function buildLocalizeFn(args) {\n return (value, options) => {\n const context = options?.context ? String(options.context) : \"standalone\";\n\n let valuesArray;\n if (context === \"formatting\" && args.formattingValues) {\n const defaultWidth = args.defaultFormattingWidth || args.defaultWidth;\n const width = options?.width ? String(options.width) : defaultWidth;\n\n valuesArray =\n args.formattingValues[width] || args.formattingValues[defaultWidth];\n } else {\n const defaultWidth = args.defaultWidth;\n const width = options?.width ? String(options.width) : args.defaultWidth;\n\n valuesArray = args.values[width] || args.values[defaultWidth];\n }\n const index = args.argumentCallback ? args.argumentCallback(value) : value;\n\n // @ts-expect-error - For some reason TypeScript just don't want to match it, no matter how hard we try. I challenge you to try to remove it!\n return valuesArray[index];\n };\n}\n","import { buildLocalizeFn } from \"../../_lib/buildLocalizeFn.js\";\n\nconst eraValues = {\n narrow: [\"B\", \"A\"],\n abbreviated: [\"BC\", \"AD\"],\n wide: [\"Before Christ\", \"Anno Domini\"],\n};\n\nconst quarterValues = {\n narrow: [\"1\", \"2\", \"3\", \"4\"],\n abbreviated: [\"Q1\", \"Q2\", \"Q3\", \"Q4\"],\n wide: [\"1st quarter\", \"2nd quarter\", \"3rd quarter\", \"4th quarter\"],\n};\n\n// Note: in English, the names of days of the week and months are capitalized.\n// If you are making a new locale based on this one, check if the same is true for the language you're working on.\n// Generally, formatted dates should look like they are in the middle of a sentence,\n// e.g. in Spanish language the weekdays and months should be in the lowercase.\nconst monthValues = {\n narrow: [\"J\", \"F\", \"M\", \"A\", \"M\", \"J\", \"J\", \"A\", \"S\", \"O\", \"N\", \"D\"],\n abbreviated: [\n \"Jan\",\n \"Feb\",\n \"Mar\",\n \"Apr\",\n \"May\",\n \"Jun\",\n \"Jul\",\n \"Aug\",\n \"Sep\",\n \"Oct\",\n \"Nov\",\n \"Dec\",\n ],\n\n wide: [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n ],\n};\n\nconst dayValues = {\n narrow: [\"S\", \"M\", \"T\", \"W\", \"T\", \"F\", \"S\"],\n short: [\"Su\", \"Mo\", \"Tu\", \"We\", \"Th\", \"Fr\", \"Sa\"],\n abbreviated: [\"Sun\", \"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\"],\n wide: [\n \"Sunday\",\n \"Monday\",\n \"Tuesday\",\n \"Wednesday\",\n \"Thursday\",\n \"Friday\",\n \"Saturday\",\n ],\n};\n\nconst dayPeriodValues = {\n narrow: {\n am: \"a\",\n pm: \"p\",\n midnight: \"mi\",\n noon: \"n\",\n morning: \"morning\",\n afternoon: \"afternoon\",\n evening: \"evening\",\n night: \"night\",\n },\n abbreviated: {\n am: \"AM\",\n pm: \"PM\",\n midnight: \"midnight\",\n noon: \"noon\",\n morning: \"morning\",\n afternoon: \"afternoon\",\n evening: \"evening\",\n night: \"night\",\n },\n wide: {\n am: \"a.m.\",\n pm: \"p.m.\",\n midnight: \"midnight\",\n noon: \"noon\",\n morning: \"morning\",\n afternoon: \"afternoon\",\n evening: \"evening\",\n night: \"night\",\n },\n};\n\nconst formattingDayPeriodValues = {\n narrow: {\n am: \"a\",\n pm: \"p\",\n midnight: \"mi\",\n noon: \"n\",\n morning: \"in the morning\",\n afternoon: \"in the afternoon\",\n evening: \"in the evening\",\n night: \"at night\",\n },\n abbreviated: {\n am: \"AM\",\n pm: \"PM\",\n midnight: \"midnight\",\n noon: \"noon\",\n morning: \"in the morning\",\n afternoon: \"in the afternoon\",\n evening: \"in the evening\",\n night: \"at night\",\n },\n wide: {\n am: \"a.m.\",\n pm: \"p.m.\",\n midnight: \"midnight\",\n noon: \"noon\",\n morning: \"in the morning\",\n afternoon: \"in the afternoon\",\n evening: \"in the evening\",\n night: \"at night\",\n },\n};\n\nconst ordinalNumber = (dirtyNumber, _options) => {\n const number = Number(dirtyNumber);\n\n // If ordinal numbers depend on context, for example,\n // if they are different for different grammatical genders,\n // use `options.unit`.\n //\n // `unit` can be 'year', 'quarter', 'month', 'week', 'date', 'dayOfYear',\n // 'day', 'hour', 'minute', 'second'.\n\n const rem100 = number % 100;\n if (rem100 > 20 || rem100 < 10) {\n switch (rem100 % 10) {\n case 1:\n return number + \"st\";\n case 2:\n return number + \"nd\";\n case 3:\n return number + \"rd\";\n }\n }\n return number + \"th\";\n};\n\nexport const localize = {\n ordinalNumber,\n\n era: buildLocalizeFn({\n values: eraValues,\n defaultWidth: \"wide\",\n }),\n\n quarter: buildLocalizeFn({\n values: quarterValues,\n defaultWidth: \"wide\",\n argumentCallback: (quarter) => quarter - 1,\n }),\n\n month: buildLocalizeFn({\n values: monthValues,\n defaultWidth: \"wide\",\n }),\n\n day: buildLocalizeFn({\n values: dayValues,\n defaultWidth: \"wide\",\n }),\n\n dayPeriod: buildLocalizeFn({\n values: dayPeriodValues,\n defaultWidth: \"wide\",\n formattingValues: formattingDayPeriodValues,\n defaultFormattingWidth: \"wide\",\n }),\n};\n","export function buildMatchFn(args) {\n return (string, options = {}) => {\n const width = options.width;\n\n const matchPattern =\n (width && args.matchPatterns[width]) ||\n args.matchPatterns[args.defaultMatchWidth];\n const matchResult = string.match(matchPattern);\n\n if (!matchResult) {\n return null;\n }\n const matchedString = matchResult[0];\n\n const parsePatterns =\n (width && args.parsePatterns[width]) ||\n args.parsePatterns[args.defaultParseWidth];\n\n const key = Array.isArray(parsePatterns)\n ? findIndex(parsePatterns, (pattern) => pattern.test(matchedString))\n : // [TODO] -- I challenge you to fix the type\n findKey(parsePatterns, (pattern) => pattern.test(matchedString));\n\n let value;\n\n value = args.valueCallback ? args.valueCallback(key) : key;\n value = options.valueCallback\n ? // [TODO] -- I challenge you to fix the type\n options.valueCallback(value)\n : value;\n\n const rest = string.slice(matchedString.length);\n\n return { value, rest };\n };\n}\n\nfunction findKey(object, predicate) {\n for (const key in object) {\n if (\n Object.prototype.hasOwnProperty.call(object, key) &&\n predicate(object[key])\n ) {\n return key;\n }\n }\n return undefined;\n}\n\nfunction findIndex(array, predicate) {\n for (let key = 0; key < array.length; key++) {\n if (predicate(array[key])) {\n return key;\n }\n }\n return undefined;\n}\n","export function buildMatchPatternFn(args) {\n return (string, options = {}) => {\n const matchResult = string.match(args.matchPattern);\n if (!matchResult) return null;\n const matchedString = matchResult[0];\n\n const parseResult = string.match(args.parsePattern);\n if (!parseResult) return null;\n let value = args.valueCallback\n ? args.valueCallback(parseResult[0])\n : parseResult[0];\n\n // [TODO] I challenge you to fix the type\n value = options.valueCallback ? options.valueCallback(value) : value;\n\n const rest = string.slice(matchedString.length);\n\n return { value, rest };\n };\n}\n","import { buildMatchFn } from \"../../_lib/buildMatchFn.js\";\nimport { buildMatchPatternFn } from \"../../_lib/buildMatchPatternFn.js\";\n\nconst matchOrdinalNumberPattern = /^(\\d+)(th|st|nd|rd)?/i;\nconst parseOrdinalNumberPattern = /\\d+/i;\n\nconst matchEraPatterns = {\n narrow: /^(b|a)/i,\n abbreviated: /^(b\\.?\\s?c\\.?|b\\.?\\s?c\\.?\\s?e\\.?|a\\.?\\s?d\\.?|c\\.?\\s?e\\.?)/i,\n wide: /^(before christ|before common era|anno domini|common era)/i,\n};\nconst parseEraPatterns = {\n any: [/^b/i, /^(a|c)/i],\n};\n\nconst matchQuarterPatterns = {\n narrow: /^[1234]/i,\n abbreviated: /^q[1234]/i,\n wide: /^[1234](th|st|nd|rd)? quarter/i,\n};\nconst parseQuarterPatterns = {\n any: [/1/i, /2/i, /3/i, /4/i],\n};\n\nconst matchMonthPatterns = {\n narrow: /^[jfmasond]/i,\n abbreviated: /^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,\n wide: /^(january|february|march|april|may|june|july|august|september|october|november|december)/i,\n};\nconst parseMonthPatterns = {\n narrow: [\n /^j/i,\n /^f/i,\n /^m/i,\n /^a/i,\n /^m/i,\n /^j/i,\n /^j/i,\n /^a/i,\n /^s/i,\n /^o/i,\n /^n/i,\n /^d/i,\n ],\n\n any: [\n /^ja/i,\n /^f/i,\n /^mar/i,\n /^ap/i,\n /^may/i,\n /^jun/i,\n /^jul/i,\n /^au/i,\n /^s/i,\n /^o/i,\n /^n/i,\n /^d/i,\n ],\n};\n\nconst matchDayPatterns = {\n narrow: /^[smtwf]/i,\n short: /^(su|mo|tu|we|th|fr|sa)/i,\n abbreviated: /^(sun|mon|tue|wed|thu|fri|sat)/i,\n wide: /^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i,\n};\nconst parseDayPatterns = {\n narrow: [/^s/i, /^m/i, /^t/i, /^w/i, /^t/i, /^f/i, /^s/i],\n any: [/^su/i, /^m/i, /^tu/i, /^w/i, /^th/i, /^f/i, /^sa/i],\n};\n\nconst matchDayPeriodPatterns = {\n narrow: /^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,\n any: /^([ap]\\.?\\s?m\\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i,\n};\nconst parseDayPeriodPatterns = {\n any: {\n am: /^a/i,\n pm: /^p/i,\n midnight: /^mi/i,\n noon: /^no/i,\n morning: /morning/i,\n afternoon: /afternoon/i,\n evening: /evening/i,\n night: /night/i,\n },\n};\n\nexport const match = {\n ordinalNumber: buildMatchPatternFn({\n matchPattern: matchOrdinalNumberPattern,\n parsePattern: parseOrdinalNumberPattern,\n valueCallback: (value) => parseInt(value, 10),\n }),\n\n era: buildMatchFn({\n matchPatterns: matchEraPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseEraPatterns,\n defaultParseWidth: \"any\",\n }),\n\n quarter: buildMatchFn({\n matchPatterns: matchQuarterPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseQuarterPatterns,\n defaultParseWidth: \"any\",\n valueCallback: (index) => index + 1,\n }),\n\n month: buildMatchFn({\n matchPatterns: matchMonthPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseMonthPatterns,\n defaultParseWidth: \"any\",\n }),\n\n day: buildMatchFn({\n matchPatterns: matchDayPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseDayPatterns,\n defaultParseWidth: \"any\",\n }),\n\n dayPeriod: buildMatchFn({\n matchPatterns: matchDayPeriodPatterns,\n defaultMatchWidth: \"any\",\n parsePatterns: parseDayPeriodPatterns,\n defaultParseWidth: \"any\",\n }),\n};\n","import { formatDistance } from \"./en-US/_lib/formatDistance.js\";\nimport { formatLong } from \"./en-US/_lib/formatLong.js\";\nimport { formatRelative } from \"./en-US/_lib/formatRelative.js\";\nimport { localize } from \"./en-US/_lib/localize.js\";\nimport { match } from \"./en-US/_lib/match.js\";\n\n/**\n * @category Locales\n * @summary English locale (United States).\n * @language English\n * @iso-639-2 eng\n * @author Sasha Koss [@kossnocorp](https://github.com/kossnocorp)\n * @author Lesha Koss [@leshakoss](https://github.com/leshakoss)\n */\nexport const enUS = {\n code: \"en-US\",\n formatDistance: formatDistance,\n formatLong: formatLong,\n formatRelative: formatRelative,\n localize: localize,\n match: match,\n options: {\n weekStartsOn: 0 /* Sunday */,\n firstWeekContainsDate: 1,\n },\n};\n\n// Fallback for modularized imports:\nexport default enUS;\n","import { differenceInCalendarDays } from \"./differenceInCalendarDays.js\";\nimport { startOfYear } from \"./startOfYear.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getDayOfYear} function options.\n */\n\n/**\n * @name getDayOfYear\n * @category Day Helpers\n * @summary Get the day of the year of the given date.\n *\n * @description\n * Get the day of the year of the given date.\n *\n * @param date - The given date\n * @param options - The options\n *\n * @returns The day of year\n *\n * @example\n * // Which day of the year is 2 July 2014?\n * const result = getDayOfYear(new Date(2014, 6, 2))\n * //=> 183\n */\nexport function getDayOfYear(date, options) {\n const _date = toDate(date, options?.in);\n const diff = differenceInCalendarDays(_date, startOfYear(_date));\n const dayOfYear = diff + 1;\n return dayOfYear;\n}\n\n// Fallback for modularized imports:\nexport default getDayOfYear;\n","import { millisecondsInWeek } from \"./constants.js\";\nimport { startOfISOWeek } from \"./startOfISOWeek.js\";\nimport { startOfISOWeekYear } from \"./startOfISOWeekYear.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getISOWeek} function options.\n */\n\n/**\n * @name getISOWeek\n * @category ISO Week Helpers\n * @summary Get the ISO week of the given date.\n *\n * @description\n * Get the ISO week of the given date.\n *\n * ISO week-numbering year: http://en.wikipedia.org/wiki/ISO_week_date\n *\n * @param date - The given date\n * @param options - The options\n *\n * @returns The ISO week\n *\n * @example\n * // Which week of the ISO-week numbering year is 2 January 2005?\n * const result = getISOWeek(new Date(2005, 0, 2))\n * //=> 53\n */\nexport function getISOWeek(date, options) {\n const _date = toDate(date, options?.in);\n const diff = +startOfISOWeek(_date) - +startOfISOWeekYear(_date);\n\n // Round the number of weeks to the nearest integer because the number of\n // milliseconds in a week is not constant (e.g. it's different in the week of\n // the daylight saving time clock shift).\n return Math.round(diff / millisecondsInWeek) + 1;\n}\n\n// Fallback for modularized imports:\nexport default getISOWeek;\n","import { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { constructFrom } from \"./constructFrom.js\";\nimport { startOfWeek } from \"./startOfWeek.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getWeekYear} function options.\n */\n\n/**\n * @name getWeekYear\n * @category Week-Numbering Year Helpers\n * @summary Get the local week-numbering year of the given date.\n *\n * @description\n * Get the local week-numbering year of the given date.\n * The exact calculation depends on the values of\n * `options.weekStartsOn` (which is the index of the first day of the week)\n * and `options.firstWeekContainsDate` (which is the day of January, which is always in\n * the first week of the week-numbering year)\n *\n * Week numbering: https://en.wikipedia.org/wiki/Week#The_ISO_week_date_system\n *\n * @param date - The given date\n * @param options - An object with options.\n *\n * @returns The local week-numbering year\n *\n * @example\n * // Which week numbering year is 26 December 2004 with the default settings?\n * const result = getWeekYear(new Date(2004, 11, 26))\n * //=> 2005\n *\n * @example\n * // Which week numbering year is 26 December 2004 if week starts on Saturday?\n * const result = getWeekYear(new Date(2004, 11, 26), { weekStartsOn: 6 })\n * //=> 2004\n *\n * @example\n * // Which week numbering year is 26 December 2004 if the first week contains 4 January?\n * const result = getWeekYear(new Date(2004, 11, 26), { firstWeekContainsDate: 4 })\n * //=> 2004\n */\nexport function getWeekYear(date, options) {\n const _date = toDate(date, options?.in);\n const year = _date.getFullYear();\n\n const defaultOptions = getDefaultOptions();\n const firstWeekContainsDate =\n options?.firstWeekContainsDate ??\n options?.locale?.options?.firstWeekContainsDate ??\n defaultOptions.firstWeekContainsDate ??\n defaultOptions.locale?.options?.firstWeekContainsDate ??\n 1;\n\n const firstWeekOfNextYear = constructFrom(options?.in || date, 0);\n firstWeekOfNextYear.setFullYear(year + 1, 0, firstWeekContainsDate);\n firstWeekOfNextYear.setHours(0, 0, 0, 0);\n const startOfNextYear = startOfWeek(firstWeekOfNextYear, options);\n\n const firstWeekOfThisYear = constructFrom(options?.in || date, 0);\n firstWeekOfThisYear.setFullYear(year, 0, firstWeekContainsDate);\n firstWeekOfThisYear.setHours(0, 0, 0, 0);\n const startOfThisYear = startOfWeek(firstWeekOfThisYear, options);\n\n if (+_date >= +startOfNextYear) {\n return year + 1;\n } else if (+_date >= +startOfThisYear) {\n return year;\n } else {\n return year - 1;\n }\n}\n\n// Fallback for modularized imports:\nexport default getWeekYear;\n","import { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { constructFrom } from \"./constructFrom.js\";\nimport { getWeekYear } from \"./getWeekYear.js\";\nimport { startOfWeek } from \"./startOfWeek.js\";\n\n/**\n * The {@link startOfWeekYear} function options.\n */\n\n/**\n * @name startOfWeekYear\n * @category Week-Numbering Year Helpers\n * @summary Return the start of a local week-numbering year for the given date.\n *\n * @description\n * Return the start of a local week-numbering year.\n * The exact calculation depends on the values of\n * `options.weekStartsOn` (which is the index of the first day of the week)\n * and `options.firstWeekContainsDate` (which is the day of January, which is always in\n * the first week of the week-numbering year)\n *\n * Week numbering: https://en.wikipedia.org/wiki/Week#The_ISO_week_date_system\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type.\n *\n * @param date - The original date\n * @param options - An object with options\n *\n * @returns The start of a week-numbering year\n *\n * @example\n * // The start of an a week-numbering year for 2 July 2005 with default settings:\n * const result = startOfWeekYear(new Date(2005, 6, 2))\n * //=> Sun Dec 26 2004 00:00:00\n *\n * @example\n * // The start of a week-numbering year for 2 July 2005\n * // if Monday is the first day of week\n * // and 4 January is always in the first week of the year:\n * const result = startOfWeekYear(new Date(2005, 6, 2), {\n * weekStartsOn: 1,\n * firstWeekContainsDate: 4\n * })\n * //=> Mon Jan 03 2005 00:00:00\n */\nexport function startOfWeekYear(date, options) {\n const defaultOptions = getDefaultOptions();\n const firstWeekContainsDate =\n options?.firstWeekContainsDate ??\n options?.locale?.options?.firstWeekContainsDate ??\n defaultOptions.firstWeekContainsDate ??\n defaultOptions.locale?.options?.firstWeekContainsDate ??\n 1;\n\n const year = getWeekYear(date, options);\n const firstWeek = constructFrom(options?.in || date, 0);\n firstWeek.setFullYear(year, 0, firstWeekContainsDate);\n firstWeek.setHours(0, 0, 0, 0);\n const _date = startOfWeek(firstWeek, options);\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default startOfWeekYear;\n","import { millisecondsInWeek } from \"./constants.js\";\nimport { startOfWeek } from \"./startOfWeek.js\";\nimport { startOfWeekYear } from \"./startOfWeekYear.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getWeek} function options.\n */\n\n/**\n * @name getWeek\n * @category Week Helpers\n * @summary Get the local week index of the given date.\n *\n * @description\n * Get the local week index of the given date.\n * The exact calculation depends on the values of\n * `options.weekStartsOn` (which is the index of the first day of the week)\n * and `options.firstWeekContainsDate` (which is the day of January, which is always in\n * the first week of the week-numbering year)\n *\n * Week numbering: https://en.wikipedia.org/wiki/Week#The_ISO_week_date_system\n *\n * @param date - The given date\n * @param options - An object with options\n *\n * @returns The week\n *\n * @example\n * // Which week of the local week numbering year is 2 January 2005 with default options?\n * const result = getWeek(new Date(2005, 0, 2))\n * //=> 2\n *\n * @example\n * // Which week of the local week numbering year is 2 January 2005,\n * // if Monday is the first day of the week,\n * // and the first week of the year always contains 4 January?\n * const result = getWeek(new Date(2005, 0, 2), {\n * weekStartsOn: 1,\n * firstWeekContainsDate: 4\n * })\n * //=> 53\n */\nexport function getWeek(date, options) {\n const _date = toDate(date, options?.in);\n const diff = +startOfWeek(_date, options) - +startOfWeekYear(_date, options);\n\n // Round the number of weeks to the nearest integer because the number of\n // milliseconds in a week is not constant (e.g. it's different in the week of\n // the daylight saving time clock shift).\n return Math.round(diff / millisecondsInWeek) + 1;\n}\n\n// Fallback for modularized imports:\nexport default getWeek;\n","export function addLeadingZeros(number, targetLength) {\n const sign = number < 0 ? \"-\" : \"\";\n const output = Math.abs(number).toString().padStart(targetLength, \"0\");\n return sign + output;\n}\n","import { addLeadingZeros } from \"../addLeadingZeros.js\";\n\n/*\n * | | Unit | | Unit |\n * |-----|--------------------------------|-----|--------------------------------|\n * | a | AM, PM | A* | |\n * | d | Day of month | D | |\n * | h | Hour [1-12] | H | Hour [0-23] |\n * | m | Minute | M | Month |\n * | s | Second | S | Fraction of second |\n * | y | Year (abs) | Y | |\n *\n * Letters marked by * are not implemented but reserved by Unicode standard.\n */\n\nexport const lightFormatters = {\n // Year\n y(date, token) {\n // From http://www.unicode.org/reports/tr35/tr35-31/tr35-dates.html#Date_Format_tokens\n // | Year | y | yy | yyy | yyyy | yyyyy |\n // |----------|-------|----|-------|-------|-------|\n // | AD 1 | 1 | 01 | 001 | 0001 | 00001 |\n // | AD 12 | 12 | 12 | 012 | 0012 | 00012 |\n // | AD 123 | 123 | 23 | 123 | 0123 | 00123 |\n // | AD 1234 | 1234 | 34 | 1234 | 1234 | 01234 |\n // | AD 12345 | 12345 | 45 | 12345 | 12345 | 12345 |\n\n const signedYear = date.getFullYear();\n // Returns 1 for 1 BC (which is year 0 in JavaScript)\n const year = signedYear > 0 ? signedYear : 1 - signedYear;\n return addLeadingZeros(token === \"yy\" ? year % 100 : year, token.length);\n },\n\n // Month\n M(date, token) {\n const month = date.getMonth();\n return token === \"M\" ? String(month + 1) : addLeadingZeros(month + 1, 2);\n },\n\n // Day of the month\n d(date, token) {\n return addLeadingZeros(date.getDate(), token.length);\n },\n\n // AM or PM\n a(date, token) {\n const dayPeriodEnumValue = date.getHours() / 12 >= 1 ? \"pm\" : \"am\";\n\n switch (token) {\n case \"a\":\n case \"aa\":\n return dayPeriodEnumValue.toUpperCase();\n case \"aaa\":\n return dayPeriodEnumValue;\n case \"aaaaa\":\n return dayPeriodEnumValue[0];\n case \"aaaa\":\n default:\n return dayPeriodEnumValue === \"am\" ? \"a.m.\" : \"p.m.\";\n }\n },\n\n // Hour [1-12]\n h(date, token) {\n return addLeadingZeros(date.getHours() % 12 || 12, token.length);\n },\n\n // Hour [0-23]\n H(date, token) {\n return addLeadingZeros(date.getHours(), token.length);\n },\n\n // Minute\n m(date, token) {\n return addLeadingZeros(date.getMinutes(), token.length);\n },\n\n // Second\n s(date, token) {\n return addLeadingZeros(date.getSeconds(), token.length);\n },\n\n // Fraction of second\n S(date, token) {\n const numberOfDigits = token.length;\n const milliseconds = date.getMilliseconds();\n const fractionalSeconds = Math.trunc(\n milliseconds * Math.pow(10, numberOfDigits - 3),\n );\n return addLeadingZeros(fractionalSeconds, token.length);\n },\n};\n","import { getDayOfYear } from \"../../getDayOfYear.js\";\nimport { getISOWeek } from \"../../getISOWeek.js\";\nimport { getISOWeekYear } from \"../../getISOWeekYear.js\";\nimport { getWeek } from \"../../getWeek.js\";\nimport { getWeekYear } from \"../../getWeekYear.js\";\n\nimport { addLeadingZeros } from \"../addLeadingZeros.js\";\nimport { lightFormatters } from \"./lightFormatters.js\";\n\nconst dayPeriodEnum = {\n am: \"am\",\n pm: \"pm\",\n midnight: \"midnight\",\n noon: \"noon\",\n morning: \"morning\",\n afternoon: \"afternoon\",\n evening: \"evening\",\n night: \"night\",\n};\n\n/*\n * | | Unit | | Unit |\n * |-----|--------------------------------|-----|--------------------------------|\n * | a | AM, PM | A* | Milliseconds in day |\n * | b | AM, PM, noon, midnight | B | Flexible day period |\n * | c | Stand-alone local day of week | C* | Localized hour w/ day period |\n * | d | Day of month | D | Day of year |\n * | e | Local day of week | E | Day of week |\n * | f | | F* | Day of week in month |\n * | g* | Modified Julian day | G | Era |\n * | h | Hour [1-12] | H | Hour [0-23] |\n * | i! | ISO day of week | I! | ISO week of year |\n * | j* | Localized hour w/ day period | J* | Localized hour w/o day period |\n * | k | Hour [1-24] | K | Hour [0-11] |\n * | l* | (deprecated) | L | Stand-alone month |\n * | m | Minute | M | Month |\n * | n | | N | |\n * | o! | Ordinal number modifier | O | Timezone (GMT) |\n * | p! | Long localized time | P! | Long localized date |\n * | q | Stand-alone quarter | Q | Quarter |\n * | r* | Related Gregorian year | R! | ISO week-numbering year |\n * | s | Second | S | Fraction of second |\n * | t! | Seconds timestamp | T! | Milliseconds timestamp |\n * | u | Extended year | U* | Cyclic year |\n * | v* | Timezone (generic non-locat.) | V* | Timezone (location) |\n * | w | Local week of year | W* | Week of month |\n * | x | Timezone (ISO-8601 w/o Z) | X | Timezone (ISO-8601) |\n * | y | Year (abs) | Y | Local week-numbering year |\n * | z | Timezone (specific non-locat.) | Z* | Timezone (aliases) |\n *\n * Letters marked by * are not implemented but reserved by Unicode standard.\n *\n * Letters marked by ! are non-standard, but implemented by date-fns:\n * - `o` modifies the previous token to turn it into an ordinal (see `format` docs)\n * - `i` is ISO day of week. For `i` and `ii` is returns numeric ISO week days,\n * i.e. 7 for Sunday, 1 for Monday, etc.\n * - `I` is ISO week of year, as opposed to `w` which is local week of year.\n * - `R` is ISO week-numbering year, as opposed to `Y` which is local week-numbering year.\n * `R` is supposed to be used in conjunction with `I` and `i`\n * for universal ISO week-numbering date, whereas\n * `Y` is supposed to be used in conjunction with `w` and `e`\n * for week-numbering date specific to the locale.\n * - `P` is long localized date format\n * - `p` is long localized time format\n */\n\nexport const formatters = {\n // Era\n G: function (date, token, localize) {\n const era = date.getFullYear() > 0 ? 1 : 0;\n switch (token) {\n // AD, BC\n case \"G\":\n case \"GG\":\n case \"GGG\":\n return localize.era(era, { width: \"abbreviated\" });\n // A, B\n case \"GGGGG\":\n return localize.era(era, { width: \"narrow\" });\n // Anno Domini, Before Christ\n case \"GGGG\":\n default:\n return localize.era(era, { width: \"wide\" });\n }\n },\n\n // Year\n y: function (date, token, localize) {\n // Ordinal number\n if (token === \"yo\") {\n const signedYear = date.getFullYear();\n // Returns 1 for 1 BC (which is year 0 in JavaScript)\n const year = signedYear > 0 ? signedYear : 1 - signedYear;\n return localize.ordinalNumber(year, { unit: \"year\" });\n }\n\n return lightFormatters.y(date, token);\n },\n\n // Local week-numbering year\n Y: function (date, token, localize, options) {\n const signedWeekYear = getWeekYear(date, options);\n // Returns 1 for 1 BC (which is year 0 in JavaScript)\n const weekYear = signedWeekYear > 0 ? signedWeekYear : 1 - signedWeekYear;\n\n // Two digit year\n if (token === \"YY\") {\n const twoDigitYear = weekYear % 100;\n return addLeadingZeros(twoDigitYear, 2);\n }\n\n // Ordinal number\n if (token === \"Yo\") {\n return localize.ordinalNumber(weekYear, { unit: \"year\" });\n }\n\n // Padding\n return addLeadingZeros(weekYear, token.length);\n },\n\n // ISO week-numbering year\n R: function (date, token) {\n const isoWeekYear = getISOWeekYear(date);\n\n // Padding\n return addLeadingZeros(isoWeekYear, token.length);\n },\n\n // Extended year. This is a single number designating the year of this calendar system.\n // The main difference between `y` and `u` localizers are B.C. years:\n // | Year | `y` | `u` |\n // |------|-----|-----|\n // | AC 1 | 1 | 1 |\n // | BC 1 | 1 | 0 |\n // | BC 2 | 2 | -1 |\n // Also `yy` always returns the last two digits of a year,\n // while `uu` pads single digit years to 2 characters and returns other years unchanged.\n u: function (date, token) {\n const year = date.getFullYear();\n return addLeadingZeros(year, token.length);\n },\n\n // Quarter\n Q: function (date, token, localize) {\n const quarter = Math.ceil((date.getMonth() + 1) / 3);\n switch (token) {\n // 1, 2, 3, 4\n case \"Q\":\n return String(quarter);\n // 01, 02, 03, 04\n case \"QQ\":\n return addLeadingZeros(quarter, 2);\n // 1st, 2nd, 3rd, 4th\n case \"Qo\":\n return localize.ordinalNumber(quarter, { unit: \"quarter\" });\n // Q1, Q2, Q3, Q4\n case \"QQQ\":\n return localize.quarter(quarter, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n // 1, 2, 3, 4 (narrow quarter; could be not numerical)\n case \"QQQQQ\":\n return localize.quarter(quarter, {\n width: \"narrow\",\n context: \"formatting\",\n });\n // 1st quarter, 2nd quarter, ...\n case \"QQQQ\":\n default:\n return localize.quarter(quarter, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // Stand-alone quarter\n q: function (date, token, localize) {\n const quarter = Math.ceil((date.getMonth() + 1) / 3);\n switch (token) {\n // 1, 2, 3, 4\n case \"q\":\n return String(quarter);\n // 01, 02, 03, 04\n case \"qq\":\n return addLeadingZeros(quarter, 2);\n // 1st, 2nd, 3rd, 4th\n case \"qo\":\n return localize.ordinalNumber(quarter, { unit: \"quarter\" });\n // Q1, Q2, Q3, Q4\n case \"qqq\":\n return localize.quarter(quarter, {\n width: \"abbreviated\",\n context: \"standalone\",\n });\n // 1, 2, 3, 4 (narrow quarter; could be not numerical)\n case \"qqqqq\":\n return localize.quarter(quarter, {\n width: \"narrow\",\n context: \"standalone\",\n });\n // 1st quarter, 2nd quarter, ...\n case \"qqqq\":\n default:\n return localize.quarter(quarter, {\n width: \"wide\",\n context: \"standalone\",\n });\n }\n },\n\n // Month\n M: function (date, token, localize) {\n const month = date.getMonth();\n switch (token) {\n case \"M\":\n case \"MM\":\n return lightFormatters.M(date, token);\n // 1st, 2nd, ..., 12th\n case \"Mo\":\n return localize.ordinalNumber(month + 1, { unit: \"month\" });\n // Jan, Feb, ..., Dec\n case \"MMM\":\n return localize.month(month, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n // J, F, ..., D\n case \"MMMMM\":\n return localize.month(month, {\n width: \"narrow\",\n context: \"formatting\",\n });\n // January, February, ..., December\n case \"MMMM\":\n default:\n return localize.month(month, { width: \"wide\", context: \"formatting\" });\n }\n },\n\n // Stand-alone month\n L: function (date, token, localize) {\n const month = date.getMonth();\n switch (token) {\n // 1, 2, ..., 12\n case \"L\":\n return String(month + 1);\n // 01, 02, ..., 12\n case \"LL\":\n return addLeadingZeros(month + 1, 2);\n // 1st, 2nd, ..., 12th\n case \"Lo\":\n return localize.ordinalNumber(month + 1, { unit: \"month\" });\n // Jan, Feb, ..., Dec\n case \"LLL\":\n return localize.month(month, {\n width: \"abbreviated\",\n context: \"standalone\",\n });\n // J, F, ..., D\n case \"LLLLL\":\n return localize.month(month, {\n width: \"narrow\",\n context: \"standalone\",\n });\n // January, February, ..., December\n case \"LLLL\":\n default:\n return localize.month(month, { width: \"wide\", context: \"standalone\" });\n }\n },\n\n // Local week of year\n w: function (date, token, localize, options) {\n const week = getWeek(date, options);\n\n if (token === \"wo\") {\n return localize.ordinalNumber(week, { unit: \"week\" });\n }\n\n return addLeadingZeros(week, token.length);\n },\n\n // ISO week of year\n I: function (date, token, localize) {\n const isoWeek = getISOWeek(date);\n\n if (token === \"Io\") {\n return localize.ordinalNumber(isoWeek, { unit: \"week\" });\n }\n\n return addLeadingZeros(isoWeek, token.length);\n },\n\n // Day of the month\n d: function (date, token, localize) {\n if (token === \"do\") {\n return localize.ordinalNumber(date.getDate(), { unit: \"date\" });\n }\n\n return lightFormatters.d(date, token);\n },\n\n // Day of year\n D: function (date, token, localize) {\n const dayOfYear = getDayOfYear(date);\n\n if (token === \"Do\") {\n return localize.ordinalNumber(dayOfYear, { unit: \"dayOfYear\" });\n }\n\n return addLeadingZeros(dayOfYear, token.length);\n },\n\n // Day of week\n E: function (date, token, localize) {\n const dayOfWeek = date.getDay();\n switch (token) {\n // Tue\n case \"E\":\n case \"EE\":\n case \"EEE\":\n return localize.day(dayOfWeek, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n // T\n case \"EEEEE\":\n return localize.day(dayOfWeek, {\n width: \"narrow\",\n context: \"formatting\",\n });\n // Tu\n case \"EEEEEE\":\n return localize.day(dayOfWeek, {\n width: \"short\",\n context: \"formatting\",\n });\n // Tuesday\n case \"EEEE\":\n default:\n return localize.day(dayOfWeek, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // Local day of week\n e: function (date, token, localize, options) {\n const dayOfWeek = date.getDay();\n const localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;\n switch (token) {\n // Numerical value (Nth day of week with current locale or weekStartsOn)\n case \"e\":\n return String(localDayOfWeek);\n // Padded numerical value\n case \"ee\":\n return addLeadingZeros(localDayOfWeek, 2);\n // 1st, 2nd, ..., 7th\n case \"eo\":\n return localize.ordinalNumber(localDayOfWeek, { unit: \"day\" });\n case \"eee\":\n return localize.day(dayOfWeek, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n // T\n case \"eeeee\":\n return localize.day(dayOfWeek, {\n width: \"narrow\",\n context: \"formatting\",\n });\n // Tu\n case \"eeeeee\":\n return localize.day(dayOfWeek, {\n width: \"short\",\n context: \"formatting\",\n });\n // Tuesday\n case \"eeee\":\n default:\n return localize.day(dayOfWeek, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // Stand-alone local day of week\n c: function (date, token, localize, options) {\n const dayOfWeek = date.getDay();\n const localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;\n switch (token) {\n // Numerical value (same as in `e`)\n case \"c\":\n return String(localDayOfWeek);\n // Padded numerical value\n case \"cc\":\n return addLeadingZeros(localDayOfWeek, token.length);\n // 1st, 2nd, ..., 7th\n case \"co\":\n return localize.ordinalNumber(localDayOfWeek, { unit: \"day\" });\n case \"ccc\":\n return localize.day(dayOfWeek, {\n width: \"abbreviated\",\n context: \"standalone\",\n });\n // T\n case \"ccccc\":\n return localize.day(dayOfWeek, {\n width: \"narrow\",\n context: \"standalone\",\n });\n // Tu\n case \"cccccc\":\n return localize.day(dayOfWeek, {\n width: \"short\",\n context: \"standalone\",\n });\n // Tuesday\n case \"cccc\":\n default:\n return localize.day(dayOfWeek, {\n width: \"wide\",\n context: \"standalone\",\n });\n }\n },\n\n // ISO day of week\n i: function (date, token, localize) {\n const dayOfWeek = date.getDay();\n const isoDayOfWeek = dayOfWeek === 0 ? 7 : dayOfWeek;\n switch (token) {\n // 2\n case \"i\":\n return String(isoDayOfWeek);\n // 02\n case \"ii\":\n return addLeadingZeros(isoDayOfWeek, token.length);\n // 2nd\n case \"io\":\n return localize.ordinalNumber(isoDayOfWeek, { unit: \"day\" });\n // Tue\n case \"iii\":\n return localize.day(dayOfWeek, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n // T\n case \"iiiii\":\n return localize.day(dayOfWeek, {\n width: \"narrow\",\n context: \"formatting\",\n });\n // Tu\n case \"iiiiii\":\n return localize.day(dayOfWeek, {\n width: \"short\",\n context: \"formatting\",\n });\n // Tuesday\n case \"iiii\":\n default:\n return localize.day(dayOfWeek, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // AM or PM\n a: function (date, token, localize) {\n const hours = date.getHours();\n const dayPeriodEnumValue = hours / 12 >= 1 ? \"pm\" : \"am\";\n\n switch (token) {\n case \"a\":\n case \"aa\":\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n case \"aaa\":\n return localize\n .dayPeriod(dayPeriodEnumValue, {\n width: \"abbreviated\",\n context: \"formatting\",\n })\n .toLowerCase();\n case \"aaaaa\":\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"narrow\",\n context: \"formatting\",\n });\n case \"aaaa\":\n default:\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // AM, PM, midnight, noon\n b: function (date, token, localize) {\n const hours = date.getHours();\n let dayPeriodEnumValue;\n if (hours === 12) {\n dayPeriodEnumValue = dayPeriodEnum.noon;\n } else if (hours === 0) {\n dayPeriodEnumValue = dayPeriodEnum.midnight;\n } else {\n dayPeriodEnumValue = hours / 12 >= 1 ? \"pm\" : \"am\";\n }\n\n switch (token) {\n case \"b\":\n case \"bb\":\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n case \"bbb\":\n return localize\n .dayPeriod(dayPeriodEnumValue, {\n width: \"abbreviated\",\n context: \"formatting\",\n })\n .toLowerCase();\n case \"bbbbb\":\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"narrow\",\n context: \"formatting\",\n });\n case \"bbbb\":\n default:\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // in the morning, in the afternoon, in the evening, at night\n B: function (date, token, localize) {\n const hours = date.getHours();\n let dayPeriodEnumValue;\n if (hours >= 17) {\n dayPeriodEnumValue = dayPeriodEnum.evening;\n } else if (hours >= 12) {\n dayPeriodEnumValue = dayPeriodEnum.afternoon;\n } else if (hours >= 4) {\n dayPeriodEnumValue = dayPeriodEnum.morning;\n } else {\n dayPeriodEnumValue = dayPeriodEnum.night;\n }\n\n switch (token) {\n case \"B\":\n case \"BB\":\n case \"BBB\":\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"abbreviated\",\n context: \"formatting\",\n });\n case \"BBBBB\":\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"narrow\",\n context: \"formatting\",\n });\n case \"BBBB\":\n default:\n return localize.dayPeriod(dayPeriodEnumValue, {\n width: \"wide\",\n context: \"formatting\",\n });\n }\n },\n\n // Hour [1-12]\n h: function (date, token, localize) {\n if (token === \"ho\") {\n let hours = date.getHours() % 12;\n if (hours === 0) hours = 12;\n return localize.ordinalNumber(hours, { unit: \"hour\" });\n }\n\n return lightFormatters.h(date, token);\n },\n\n // Hour [0-23]\n H: function (date, token, localize) {\n if (token === \"Ho\") {\n return localize.ordinalNumber(date.getHours(), { unit: \"hour\" });\n }\n\n return lightFormatters.H(date, token);\n },\n\n // Hour [0-11]\n K: function (date, token, localize) {\n const hours = date.getHours() % 12;\n\n if (token === \"Ko\") {\n return localize.ordinalNumber(hours, { unit: \"hour\" });\n }\n\n return addLeadingZeros(hours, token.length);\n },\n\n // Hour [1-24]\n k: function (date, token, localize) {\n let hours = date.getHours();\n if (hours === 0) hours = 24;\n\n if (token === \"ko\") {\n return localize.ordinalNumber(hours, { unit: \"hour\" });\n }\n\n return addLeadingZeros(hours, token.length);\n },\n\n // Minute\n m: function (date, token, localize) {\n if (token === \"mo\") {\n return localize.ordinalNumber(date.getMinutes(), { unit: \"minute\" });\n }\n\n return lightFormatters.m(date, token);\n },\n\n // Second\n s: function (date, token, localize) {\n if (token === \"so\") {\n return localize.ordinalNumber(date.getSeconds(), { unit: \"second\" });\n }\n\n return lightFormatters.s(date, token);\n },\n\n // Fraction of second\n S: function (date, token) {\n return lightFormatters.S(date, token);\n },\n\n // Timezone (ISO-8601. If offset is 0, output is always `'Z'`)\n X: function (date, token, _localize) {\n const timezoneOffset = date.getTimezoneOffset();\n\n if (timezoneOffset === 0) {\n return \"Z\";\n }\n\n switch (token) {\n // Hours and optional minutes\n case \"X\":\n return formatTimezoneWithOptionalMinutes(timezoneOffset);\n\n // Hours, minutes and optional seconds without `:` delimiter\n // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets\n // so this token always has the same output as `XX`\n case \"XXXX\":\n case \"XX\": // Hours and minutes without `:` delimiter\n return formatTimezone(timezoneOffset);\n\n // Hours, minutes and optional seconds with `:` delimiter\n // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets\n // so this token always has the same output as `XXX`\n case \"XXXXX\":\n case \"XXX\": // Hours and minutes with `:` delimiter\n default:\n return formatTimezone(timezoneOffset, \":\");\n }\n },\n\n // Timezone (ISO-8601. If offset is 0, output is `'+00:00'` or equivalent)\n x: function (date, token, _localize) {\n const timezoneOffset = date.getTimezoneOffset();\n\n switch (token) {\n // Hours and optional minutes\n case \"x\":\n return formatTimezoneWithOptionalMinutes(timezoneOffset);\n\n // Hours, minutes and optional seconds without `:` delimiter\n // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets\n // so this token always has the same output as `xx`\n case \"xxxx\":\n case \"xx\": // Hours and minutes without `:` delimiter\n return formatTimezone(timezoneOffset);\n\n // Hours, minutes and optional seconds with `:` delimiter\n // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets\n // so this token always has the same output as `xxx`\n case \"xxxxx\":\n case \"xxx\": // Hours and minutes with `:` delimiter\n default:\n return formatTimezone(timezoneOffset, \":\");\n }\n },\n\n // Timezone (GMT)\n O: function (date, token, _localize) {\n const timezoneOffset = date.getTimezoneOffset();\n\n switch (token) {\n // Short\n case \"O\":\n case \"OO\":\n case \"OOO\":\n return \"GMT\" + formatTimezoneShort(timezoneOffset, \":\");\n // Long\n case \"OOOO\":\n default:\n return \"GMT\" + formatTimezone(timezoneOffset, \":\");\n }\n },\n\n // Timezone (specific non-location)\n z: function (date, token, _localize) {\n const timezoneOffset = date.getTimezoneOffset();\n\n switch (token) {\n // Short\n case \"z\":\n case \"zz\":\n case \"zzz\":\n return \"GMT\" + formatTimezoneShort(timezoneOffset, \":\");\n // Long\n case \"zzzz\":\n default:\n return \"GMT\" + formatTimezone(timezoneOffset, \":\");\n }\n },\n\n // Seconds timestamp\n t: function (date, token, _localize) {\n const timestamp = Math.trunc(+date / 1000);\n return addLeadingZeros(timestamp, token.length);\n },\n\n // Milliseconds timestamp\n T: function (date, token, _localize) {\n return addLeadingZeros(+date, token.length);\n },\n};\n\nfunction formatTimezoneShort(offset, delimiter = \"\") {\n const sign = offset > 0 ? \"-\" : \"+\";\n const absOffset = Math.abs(offset);\n const hours = Math.trunc(absOffset / 60);\n const minutes = absOffset % 60;\n if (minutes === 0) {\n return sign + String(hours);\n }\n return sign + String(hours) + delimiter + addLeadingZeros(minutes, 2);\n}\n\nfunction formatTimezoneWithOptionalMinutes(offset, delimiter) {\n if (offset % 60 === 0) {\n const sign = offset > 0 ? \"-\" : \"+\";\n return sign + addLeadingZeros(Math.abs(offset) / 60, 2);\n }\n return formatTimezone(offset, delimiter);\n}\n\nfunction formatTimezone(offset, delimiter = \"\") {\n const sign = offset > 0 ? \"-\" : \"+\";\n const absOffset = Math.abs(offset);\n const hours = addLeadingZeros(Math.trunc(absOffset / 60), 2);\n const minutes = addLeadingZeros(absOffset % 60, 2);\n return sign + hours + delimiter + minutes;\n}\n","const dateLongFormatter = (pattern, formatLong) => {\n switch (pattern) {\n case \"P\":\n return formatLong.date({ width: \"short\" });\n case \"PP\":\n return formatLong.date({ width: \"medium\" });\n case \"PPP\":\n return formatLong.date({ width: \"long\" });\n case \"PPPP\":\n default:\n return formatLong.date({ width: \"full\" });\n }\n};\n\nconst timeLongFormatter = (pattern, formatLong) => {\n switch (pattern) {\n case \"p\":\n return formatLong.time({ width: \"short\" });\n case \"pp\":\n return formatLong.time({ width: \"medium\" });\n case \"ppp\":\n return formatLong.time({ width: \"long\" });\n case \"pppp\":\n default:\n return formatLong.time({ width: \"full\" });\n }\n};\n\nconst dateTimeLongFormatter = (pattern, formatLong) => {\n const matchResult = pattern.match(/(P+)(p+)?/) || [];\n const datePattern = matchResult[1];\n const timePattern = matchResult[2];\n\n if (!timePattern) {\n return dateLongFormatter(pattern, formatLong);\n }\n\n let dateTimeFormat;\n\n switch (datePattern) {\n case \"P\":\n dateTimeFormat = formatLong.dateTime({ width: \"short\" });\n break;\n case \"PP\":\n dateTimeFormat = formatLong.dateTime({ width: \"medium\" });\n break;\n case \"PPP\":\n dateTimeFormat = formatLong.dateTime({ width: \"long\" });\n break;\n case \"PPPP\":\n default:\n dateTimeFormat = formatLong.dateTime({ width: \"full\" });\n break;\n }\n\n return dateTimeFormat\n .replace(\"{{date}}\", dateLongFormatter(datePattern, formatLong))\n .replace(\"{{time}}\", timeLongFormatter(timePattern, formatLong));\n};\n\nexport const longFormatters = {\n p: timeLongFormatter,\n P: dateTimeLongFormatter,\n};\n","const dayOfYearTokenRE = /^D+$/;\nconst weekYearTokenRE = /^Y+$/;\n\nconst throwTokens = [\"D\", \"DD\", \"YY\", \"YYYY\"];\n\nexport function isProtectedDayOfYearToken(token) {\n return dayOfYearTokenRE.test(token);\n}\n\nexport function isProtectedWeekYearToken(token) {\n return weekYearTokenRE.test(token);\n}\n\nexport function warnOrThrowProtectedError(token, format, input) {\n const _message = message(token, format, input);\n console.warn(_message);\n if (throwTokens.includes(token)) throw new RangeError(_message);\n}\n\nfunction message(token, format, input) {\n const subject = token[0] === \"Y\" ? \"years\" : \"days of the month\";\n return `Use \\`${token.toLowerCase()}\\` instead of \\`${token}\\` (in \\`${format}\\`) for formatting ${subject} to the input \\`${input}\\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`;\n}\n","import { defaultLocale } from \"./_lib/defaultLocale.js\";\nimport { getDefaultOptions } from \"./_lib/defaultOptions.js\";\nimport { formatters } from \"./_lib/format/formatters.js\";\nimport { longFormatters } from \"./_lib/format/longFormatters.js\";\nimport {\n isProtectedDayOfYearToken,\n isProtectedWeekYearToken,\n warnOrThrowProtectedError,\n} from \"./_lib/protectedTokens.js\";\nimport { isValid } from \"./isValid.js\";\nimport { toDate } from \"./toDate.js\";\n\n// Rexports of internal for libraries to use.\n// See: https://github.com/date-fns/date-fns/issues/3638#issuecomment-1877082874\nexport { formatters, longFormatters };\n\n// This RegExp consists of three parts separated by `|`:\n// - [yYQqMLwIdDecihHKkms]o matches any available ordinal number token\n// (one of the certain letters followed by `o`)\n// - (\\w)\\1* matches any sequences of the same letter\n// - '' matches two quote characters in a row\n// - '(''|[^'])+('|$) matches anything surrounded by two quote characters ('),\n// except a single quote symbol, which ends the sequence.\n// Two quote characters do not end the sequence.\n// If there is no matching single quote\n// then the sequence will continue until the end of the string.\n// - . matches any single character unmatched by previous parts of the RegExps\nconst formattingTokensRegExp =\n /[yYQqMLwIdDecihHKkms]o|(\\w)\\1*|''|'(''|[^'])+('|$)|./g;\n\n// This RegExp catches symbols escaped by quotes, and also\n// sequences of symbols P, p, and the combinations like `PPPPPPPppppp`\nconst longFormattingTokensRegExp = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g;\n\nconst escapedStringRegExp = /^'([^]*?)'?$/;\nconst doubleQuoteRegExp = /''/g;\nconst unescapedLatinCharacterRegExp = /[a-zA-Z]/;\n\nexport { format as formatDate };\n\n/**\n * The {@link format} function options.\n */\n\n/**\n * @name format\n * @alias formatDate\n * @category Common Helpers\n * @summary Format the date.\n *\n * @description\n * Return the formatted date string in the given format. The result may vary by locale.\n *\n * > ⚠️ Please note that the `format` tokens differ from Moment.js and other libraries.\n * > See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n *\n * The characters wrapped between two single quotes characters (') are escaped.\n * Two single quotes in a row, whether inside or outside a quoted sequence, represent a 'real' single quote.\n * (see the last example)\n *\n * Format of the string is based on Unicode Technical Standard #35:\n * https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table\n * with a few additions (see note 7 below the table).\n *\n * Accepted patterns:\n * | Unit | Pattern | Result examples | Notes |\n * |---------------------------------|---------|-----------------------------------|-------|\n * | Era | G..GGG | AD, BC | |\n * | | GGGG | Anno Domini, Before Christ | 2 |\n * | | GGGGG | A, B | |\n * | Calendar year | y | 44, 1, 1900, 2017 | 5 |\n * | | yo | 44th, 1st, 0th, 17th | 5,7 |\n * | | yy | 44, 01, 00, 17 | 5 |\n * | | yyy | 044, 001, 1900, 2017 | 5 |\n * | | yyyy | 0044, 0001, 1900, 2017 | 5 |\n * | | yyyyy | ... | 3,5 |\n * | Local week-numbering year | Y | 44, 1, 1900, 2017 | 5 |\n * | | Yo | 44th, 1st, 1900th, 2017th | 5,7 |\n * | | YY | 44, 01, 00, 17 | 5,8 |\n * | | YYY | 044, 001, 1900, 2017 | 5 |\n * | | YYYY | 0044, 0001, 1900, 2017 | 5,8 |\n * | | YYYYY | ... | 3,5 |\n * | ISO week-numbering year | R | -43, 0, 1, 1900, 2017 | 5,7 |\n * | | RR | -43, 00, 01, 1900, 2017 | 5,7 |\n * | | RRR | -043, 000, 001, 1900, 2017 | 5,7 |\n * | | RRRR | -0043, 0000, 0001, 1900, 2017 | 5,7 |\n * | | RRRRR | ... | 3,5,7 |\n * | Extended year | u | -43, 0, 1, 1900, 2017 | 5 |\n * | | uu | -43, 01, 1900, 2017 | 5 |\n * | | uuu | -043, 001, 1900, 2017 | 5 |\n * | | uuuu | -0043, 0001, 1900, 2017 | 5 |\n * | | uuuuu | ... | 3,5 |\n * | Quarter (formatting) | Q | 1, 2, 3, 4 | |\n * | | Qo | 1st, 2nd, 3rd, 4th | 7 |\n * | | QQ | 01, 02, 03, 04 | |\n * | | QQQ | Q1, Q2, Q3, Q4 | |\n * | | QQQQ | 1st quarter, 2nd quarter, ... | 2 |\n * | | QQQQQ | 1, 2, 3, 4 | 4 |\n * | Quarter (stand-alone) | q | 1, 2, 3, 4 | |\n * | | qo | 1st, 2nd, 3rd, 4th | 7 |\n * | | qq | 01, 02, 03, 04 | |\n * | | qqq | Q1, Q2, Q3, Q4 | |\n * | | qqqq | 1st quarter, 2nd quarter, ... | 2 |\n * | | qqqqq | 1, 2, 3, 4 | 4 |\n * | Month (formatting) | M | 1, 2, ..., 12 | |\n * | | Mo | 1st, 2nd, ..., 12th | 7 |\n * | | MM | 01, 02, ..., 12 | |\n * | | MMM | Jan, Feb, ..., Dec | |\n * | | MMMM | January, February, ..., December | 2 |\n * | | MMMMM | J, F, ..., D | |\n * | Month (stand-alone) | L | 1, 2, ..., 12 | |\n * | | Lo | 1st, 2nd, ..., 12th | 7 |\n * | | LL | 01, 02, ..., 12 | |\n * | | LLL | Jan, Feb, ..., Dec | |\n * | | LLLL | January, February, ..., December | 2 |\n * | | LLLLL | J, F, ..., D | |\n * | Local week of year | w | 1, 2, ..., 53 | |\n * | | wo | 1st, 2nd, ..., 53th | 7 |\n * | | ww | 01, 02, ..., 53 | |\n * | ISO week of year | I | 1, 2, ..., 53 | 7 |\n * | | Io | 1st, 2nd, ..., 53th | 7 |\n * | | II | 01, 02, ..., 53 | 7 |\n * | Day of month | d | 1, 2, ..., 31 | |\n * | | do | 1st, 2nd, ..., 31st | 7 |\n * | | dd | 01, 02, ..., 31 | |\n * | Day of year | D | 1, 2, ..., 365, 366 | 9 |\n * | | Do | 1st, 2nd, ..., 365th, 366th | 7 |\n * | | DD | 01, 02, ..., 365, 366 | 9 |\n * | | DDD | 001, 002, ..., 365, 366 | |\n * | | DDDD | ... | 3 |\n * | Day of week (formatting) | E..EEE | Mon, Tue, Wed, ..., Sun | |\n * | | EEEE | Monday, Tuesday, ..., Sunday | 2 |\n * | | EEEEE | M, T, W, T, F, S, S | |\n * | | EEEEEE | Mo, Tu, We, Th, Fr, Sa, Su | |\n * | ISO day of week (formatting) | i | 1, 2, 3, ..., 7 | 7 |\n * | | io | 1st, 2nd, ..., 7th | 7 |\n * | | ii | 01, 02, ..., 07 | 7 |\n * | | iii | Mon, Tue, Wed, ..., Sun | 7 |\n * | | iiii | Monday, Tuesday, ..., Sunday | 2,7 |\n * | | iiiii | M, T, W, T, F, S, S | 7 |\n * | | iiiiii | Mo, Tu, We, Th, Fr, Sa, Su | 7 |\n * | Local day of week (formatting) | e | 2, 3, 4, ..., 1 | |\n * | | eo | 2nd, 3rd, ..., 1st | 7 |\n * | | ee | 02, 03, ..., 01 | |\n * | | eee | Mon, Tue, Wed, ..., Sun | |\n * | | eeee | Monday, Tuesday, ..., Sunday | 2 |\n * | | eeeee | M, T, W, T, F, S, S | |\n * | | eeeeee | Mo, Tu, We, Th, Fr, Sa, Su | |\n * | Local day of week (stand-alone) | c | 2, 3, 4, ..., 1 | |\n * | | co | 2nd, 3rd, ..., 1st | 7 |\n * | | cc | 02, 03, ..., 01 | |\n * | | ccc | Mon, Tue, Wed, ..., Sun | |\n * | | cccc | Monday, Tuesday, ..., Sunday | 2 |\n * | | ccccc | M, T, W, T, F, S, S | |\n * | | cccccc | Mo, Tu, We, Th, Fr, Sa, Su | |\n * | AM, PM | a..aa | AM, PM | |\n * | | aaa | am, pm | |\n * | | aaaa | a.m., p.m. | 2 |\n * | | aaaaa | a, p | |\n * | AM, PM, noon, midnight | b..bb | AM, PM, noon, midnight | |\n * | | bbb | am, pm, noon, midnight | |\n * | | bbbb | a.m., p.m., noon, midnight | 2 |\n * | | bbbbb | a, p, n, mi | |\n * | Flexible day period | B..BBB | at night, in the morning, ... | |\n * | | BBBB | at night, in the morning, ... | 2 |\n * | | BBBBB | at night, in the morning, ... | |\n * | Hour [1-12] | h | 1, 2, ..., 11, 12 | |\n * | | ho | 1st, 2nd, ..., 11th, 12th | 7 |\n * | | hh | 01, 02, ..., 11, 12 | |\n * | Hour [0-23] | H | 0, 1, 2, ..., 23 | |\n * | | Ho | 0th, 1st, 2nd, ..., 23rd | 7 |\n * | | HH | 00, 01, 02, ..., 23 | |\n * | Hour [0-11] | K | 1, 2, ..., 11, 0 | |\n * | | Ko | 1st, 2nd, ..., 11th, 0th | 7 |\n * | | KK | 01, 02, ..., 11, 00 | |\n * | Hour [1-24] | k | 24, 1, 2, ..., 23 | |\n * | | ko | 24th, 1st, 2nd, ..., 23rd | 7 |\n * | | kk | 24, 01, 02, ..., 23 | |\n * | Minute | m | 0, 1, ..., 59 | |\n * | | mo | 0th, 1st, ..., 59th | 7 |\n * | | mm | 00, 01, ..., 59 | |\n * | Second | s | 0, 1, ..., 59 | |\n * | | so | 0th, 1st, ..., 59th | 7 |\n * | | ss | 00, 01, ..., 59 | |\n * | Fraction of second | S | 0, 1, ..., 9 | |\n * | | SS | 00, 01, ..., 99 | |\n * | | SSS | 000, 001, ..., 999 | |\n * | | SSSS | ... | 3 |\n * | Timezone (ISO-8601 w/ Z) | X | -08, +0530, Z | |\n * | | XX | -0800, +0530, Z | |\n * | | XXX | -08:00, +05:30, Z | |\n * | | XXXX | -0800, +0530, Z, +123456 | 2 |\n * | | XXXXX | -08:00, +05:30, Z, +12:34:56 | |\n * | Timezone (ISO-8601 w/o Z) | x | -08, +0530, +00 | |\n * | | xx | -0800, +0530, +0000 | |\n * | | xxx | -08:00, +05:30, +00:00 | 2 |\n * | | xxxx | -0800, +0530, +0000, +123456 | |\n * | | xxxxx | -08:00, +05:30, +00:00, +12:34:56 | |\n * | Timezone (GMT) | O...OOO | GMT-8, GMT+5:30, GMT+0 | |\n * | | OOOO | GMT-08:00, GMT+05:30, GMT+00:00 | 2 |\n * | Timezone (specific non-locat.) | z...zzz | GMT-8, GMT+5:30, GMT+0 | 6 |\n * | | zzzz | GMT-08:00, GMT+05:30, GMT+00:00 | 2,6 |\n * | Seconds timestamp | t | 512969520 | 7 |\n * | | tt | ... | 3,7 |\n * | Milliseconds timestamp | T | 512969520900 | 7 |\n * | | TT | ... | 3,7 |\n * | Long localized date | P | 04/29/1453 | 7 |\n * | | PP | Apr 29, 1453 | 7 |\n * | | PPP | April 29th, 1453 | 7 |\n * | | PPPP | Friday, April 29th, 1453 | 2,7 |\n * | Long localized time | p | 12:00 AM | 7 |\n * | | pp | 12:00:00 AM | 7 |\n * | | ppp | 12:00:00 AM GMT+2 | 7 |\n * | | pppp | 12:00:00 AM GMT+02:00 | 2,7 |\n * | Combination of date and time | Pp | 04/29/1453, 12:00 AM | 7 |\n * | | PPpp | Apr 29, 1453, 12:00:00 AM | 7 |\n * | | PPPppp | April 29th, 1453 at ... | 7 |\n * | | PPPPpppp| Friday, April 29th, 1453 at ... | 2,7 |\n * Notes:\n * 1. \"Formatting\" units (e.g. formatting quarter) in the default en-US locale\n * are the same as \"stand-alone\" units, but are different in some languages.\n * \"Formatting\" units are declined according to the rules of the language\n * in the context of a date. \"Stand-alone\" units are always nominative singular:\n *\n * `format(new Date(2017, 10, 6), 'do LLLL', {locale: cs}) //=> '6. listopad'`\n *\n * `format(new Date(2017, 10, 6), 'do MMMM', {locale: cs}) //=> '6. listopadu'`\n *\n * 2. Any sequence of the identical letters is a pattern, unless it is escaped by\n * the single quote characters (see below).\n * If the sequence is longer than listed in table (e.g. `EEEEEEEEEEE`)\n * the output will be the same as default pattern for this unit, usually\n * the longest one (in case of ISO weekdays, `EEEE`). Default patterns for units\n * are marked with \"2\" in the last column of the table.\n *\n * `format(new Date(2017, 10, 6), 'MMM') //=> 'Nov'`\n *\n * `format(new Date(2017, 10, 6), 'MMMM') //=> 'November'`\n *\n * `format(new Date(2017, 10, 6), 'MMMMM') //=> 'N'`\n *\n * `format(new Date(2017, 10, 6), 'MMMMMM') //=> 'November'`\n *\n * `format(new Date(2017, 10, 6), 'MMMMMMM') //=> 'November'`\n *\n * 3. Some patterns could be unlimited length (such as `yyyyyyyy`).\n * The output will be padded with zeros to match the length of the pattern.\n *\n * `format(new Date(2017, 10, 6), 'yyyyyyyy') //=> '00002017'`\n *\n * 4. `QQQQQ` and `qqqqq` could be not strictly numerical in some locales.\n * These tokens represent the shortest form of the quarter.\n *\n * 5. The main difference between `y` and `u` patterns are B.C. years:\n *\n * | Year | `y` | `u` |\n * |------|-----|-----|\n * | AC 1 | 1 | 1 |\n * | BC 1 | 1 | 0 |\n * | BC 2 | 2 | -1 |\n *\n * Also `yy` always returns the last two digits of a year,\n * while `uu` pads single digit years to 2 characters and returns other years unchanged:\n *\n * | Year | `yy` | `uu` |\n * |------|------|------|\n * | 1 | 01 | 01 |\n * | 14 | 14 | 14 |\n * | 376 | 76 | 376 |\n * | 1453 | 53 | 1453 |\n *\n * The same difference is true for local and ISO week-numbering years (`Y` and `R`),\n * except local week-numbering years are dependent on `options.weekStartsOn`\n * and `options.firstWeekContainsDate` (compare [getISOWeekYear](https://date-fns.org/docs/getISOWeekYear)\n * and [getWeekYear](https://date-fns.org/docs/getWeekYear)).\n *\n * 6. Specific non-location timezones are currently unavailable in `date-fns`,\n * so right now these tokens fall back to GMT timezones.\n *\n * 7. These patterns are not in the Unicode Technical Standard #35:\n * - `i`: ISO day of week\n * - `I`: ISO week of year\n * - `R`: ISO week-numbering year\n * - `t`: seconds timestamp\n * - `T`: milliseconds timestamp\n * - `o`: ordinal number modifier\n * - `P`: long localized date\n * - `p`: long localized time\n *\n * 8. `YY` and `YYYY` tokens represent week-numbering years but they are often confused with years.\n * You should enable `options.useAdditionalWeekYearTokens` to use them. See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n *\n * 9. `D` and `DD` tokens represent days of the year but they are often confused with days of the month.\n * You should enable `options.useAdditionalDayOfYearTokens` to use them. See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n *\n * @param date - The original date\n * @param format - The string of tokens\n * @param options - An object with options\n *\n * @returns The formatted date string\n *\n * @throws `date` must not be Invalid Date\n * @throws `options.locale` must contain `localize` property\n * @throws `options.locale` must contain `formatLong` property\n * @throws use `yyyy` instead of `YYYY` for formatting years using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws use `yy` instead of `YY` for formatting years using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws use `d` instead of `D` for formatting days of the month using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws use `dd` instead of `DD` for formatting days of the month using [format provided] to the input [input provided]; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md\n * @throws format string contains an unescaped latin alphabet character\n *\n * @example\n * // Represent 11 February 2014 in middle-endian format:\n * const result = format(new Date(2014, 1, 11), 'MM/dd/yyyy')\n * //=> '02/11/2014'\n *\n * @example\n * // Represent 2 July 2014 in Esperanto:\n * import { eoLocale } from 'date-fns/locale/eo'\n * const result = format(new Date(2014, 6, 2), \"do 'de' MMMM yyyy\", {\n * locale: eoLocale\n * })\n * //=> '2-a de julio 2014'\n *\n * @example\n * // Escape string by single quote characters:\n * const result = format(new Date(2014, 6, 2, 15), \"h 'o''clock'\")\n * //=> \"3 o'clock\"\n */\nexport function format(date, formatStr, options) {\n const defaultOptions = getDefaultOptions();\n const locale = options?.locale ?? defaultOptions.locale ?? defaultLocale;\n\n const firstWeekContainsDate =\n options?.firstWeekContainsDate ??\n options?.locale?.options?.firstWeekContainsDate ??\n defaultOptions.firstWeekContainsDate ??\n defaultOptions.locale?.options?.firstWeekContainsDate ??\n 1;\n\n const weekStartsOn =\n options?.weekStartsOn ??\n options?.locale?.options?.weekStartsOn ??\n defaultOptions.weekStartsOn ??\n defaultOptions.locale?.options?.weekStartsOn ??\n 0;\n\n const originalDate = toDate(date, options?.in);\n\n if (!isValid(originalDate)) {\n throw new RangeError(\"Invalid time value\");\n }\n\n let parts = formatStr\n .match(longFormattingTokensRegExp)\n .map((substring) => {\n const firstCharacter = substring[0];\n if (firstCharacter === \"p\" || firstCharacter === \"P\") {\n const longFormatter = longFormatters[firstCharacter];\n return longFormatter(substring, locale.formatLong);\n }\n return substring;\n })\n .join(\"\")\n .match(formattingTokensRegExp)\n .map((substring) => {\n // Replace two single quote characters with one single quote character\n if (substring === \"''\") {\n return { isToken: false, value: \"'\" };\n }\n\n const firstCharacter = substring[0];\n if (firstCharacter === \"'\") {\n return { isToken: false, value: cleanEscapedString(substring) };\n }\n\n if (formatters[firstCharacter]) {\n return { isToken: true, value: substring };\n }\n\n if (firstCharacter.match(unescapedLatinCharacterRegExp)) {\n throw new RangeError(\n \"Format string contains an unescaped latin alphabet character `\" +\n firstCharacter +\n \"`\",\n );\n }\n\n return { isToken: false, value: substring };\n });\n\n // invoke localize preprocessor (only for french locales at the moment)\n if (locale.localize.preprocessor) {\n parts = locale.localize.preprocessor(originalDate, parts);\n }\n\n const formatterOptions = {\n firstWeekContainsDate,\n weekStartsOn,\n locale,\n };\n\n return parts\n .map((part) => {\n if (!part.isToken) return part.value;\n\n const token = part.value;\n\n if (\n (!options?.useAdditionalWeekYearTokens &&\n isProtectedWeekYearToken(token)) ||\n (!options?.useAdditionalDayOfYearTokens &&\n isProtectedDayOfYearToken(token))\n ) {\n warnOrThrowProtectedError(token, formatStr, String(date));\n }\n\n const formatter = formatters[token[0]];\n return formatter(originalDate, token, locale.localize, formatterOptions);\n })\n .join(\"\");\n}\n\nfunction cleanEscapedString(input) {\n const matched = input.match(escapedStringRegExp);\n\n if (!matched) {\n return input;\n }\n\n return matched[1].replace(doubleQuoteRegExp, \"'\");\n}\n\n// Fallback for modularized imports:\nexport default format;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getDaysInMonth} function options.\n */\n\n/**\n * @name getDaysInMonth\n * @category Month Helpers\n * @summary Get the number of days in a month of the given date.\n *\n * @description\n * Get the number of days in a month of the given date, considering the context if provided.\n *\n * @param date - The given date\n * @param options - An object with options\n *\n * @returns The number of days in a month\n *\n * @example\n * // How many days are in February 2000?\n * const result = getDaysInMonth(new Date(2000, 1))\n * //=> 29\n */\nexport function getDaysInMonth(date, options) {\n const _date = toDate(date, options?.in);\n const year = _date.getFullYear();\n const monthIndex = _date.getMonth();\n const lastDayOfMonth = constructFrom(_date, 0);\n lastDayOfMonth.setFullYear(year, monthIndex + 1, 0);\n lastDayOfMonth.setHours(0, 0, 0, 0);\n return lastDayOfMonth.getDate();\n}\n\n// Fallback for modularized imports:\nexport default getDaysInMonth;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getMonth} function options.\n */\n\n/**\n * @name getMonth\n * @category Month Helpers\n * @summary Get the month of the given date.\n *\n * @description\n * Get the month of the given date.\n *\n * @param date - The given date\n * @param options - An object with options\n *\n * @returns The month index (0-11)\n *\n * @example\n * // Which month is 29 February 2012?\n * const result = getMonth(new Date(2012, 1, 29))\n * //=> 1\n */\nexport function getMonth(date, options) {\n return toDate(date, options?.in).getMonth();\n}\n\n// Fallback for modularized imports:\nexport default getMonth;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * The {@link getYear} function options.\n */\n\n/**\n * @name getYear\n * @category Year Helpers\n * @summary Get the year of the given date.\n *\n * @description\n * Get the year of the given date.\n *\n * @param date - The given date\n * @param options - An object with options\n *\n * @returns The year\n *\n * @example\n * // Which year is 2 July 2014?\n * const result = getYear(new Date(2014, 6, 2))\n * //=> 2014\n */\nexport function getYear(date, options) {\n return toDate(date, options?.in).getFullYear();\n}\n\n// Fallback for modularized imports:\nexport default getYear;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * @name isAfter\n * @category Common Helpers\n * @summary Is the first date after the second one?\n *\n * @description\n * Is the first date after the second one?\n *\n * @param date - The date that should be after the other one to return true\n * @param dateToCompare - The date to compare with\n *\n * @returns The first date is after the second date\n *\n * @example\n * // Is 10 July 1989 after 11 February 1987?\n * const result = isAfter(new Date(1989, 6, 10), new Date(1987, 1, 11))\n * //=> true\n */\nexport function isAfter(date, dateToCompare) {\n return +toDate(date) > +toDate(dateToCompare);\n}\n\n// Fallback for modularized imports:\nexport default isAfter;\n","import { toDate } from \"./toDate.js\";\n\n/**\n * @name isBefore\n * @category Common Helpers\n * @summary Is the first date before the second one?\n *\n * @description\n * Is the first date before the second one?\n *\n * @param date - The date that should be before the other one to return true\n * @param dateToCompare - The date to compare with\n *\n * @returns The first date is before the second date\n *\n * @example\n * // Is 10 July 1989 before 11 February 1987?\n * const result = isBefore(new Date(1989, 6, 10), new Date(1987, 1, 11))\n * //=> false\n */\nexport function isBefore(date, dateToCompare) {\n return +toDate(date) < +toDate(dateToCompare);\n}\n\n// Fallback for modularized imports:\nexport default isBefore;\n","import { normalizeDates } from \"./_lib/normalizeDates.js\";\n\n/**\n * The {@link isSameMonth} function options.\n */\n\n/**\n * @name isSameMonth\n * @category Month Helpers\n * @summary Are the given dates in the same month (and year)?\n *\n * @description\n * Are the given dates in the same month (and year)?\n *\n * @param laterDate - The first date to check\n * @param earlierDate - The second date to check\n * @param options - An object with options\n *\n * @returns The dates are in the same month (and year)\n *\n * @example\n * // Are 2 September 2014 and 25 September 2014 in the same month?\n * const result = isSameMonth(new Date(2014, 8, 2), new Date(2014, 8, 25))\n * //=> true\n *\n * @example\n * // Are 2 September 2014 and 25 September 2015 in the same month?\n * const result = isSameMonth(new Date(2014, 8, 2), new Date(2015, 8, 25))\n * //=> false\n */\nexport function isSameMonth(laterDate, earlierDate, options) {\n const [laterDate_, earlierDate_] = normalizeDates(\n options?.in,\n laterDate,\n earlierDate,\n );\n return (\n laterDate_.getFullYear() === earlierDate_.getFullYear() &&\n laterDate_.getMonth() === earlierDate_.getMonth()\n );\n}\n\n// Fallback for modularized imports:\nexport default isSameMonth;\n","import { normalizeDates } from \"./_lib/normalizeDates.js\";\n\n/**\n * The {@link isSameYear} function options.\n */\n\n/**\n * @name isSameYear\n * @category Year Helpers\n * @summary Are the given dates in the same year?\n *\n * @description\n * Are the given dates in the same year?\n *\n * @param laterDate - The first date to check\n * @param earlierDate - The second date to check\n * @param options - An object with options\n *\n * @returns The dates are in the same year\n *\n * @example\n * // Are 2 September 2014 and 25 September 2014 in the same year?\n * const result = isSameYear(new Date(2014, 8, 2), new Date(2014, 8, 25))\n * //=> true\n */\nexport function isSameYear(laterDate, earlierDate, options) {\n const [laterDate_, earlierDate_] = normalizeDates(\n options?.in,\n laterDate,\n earlierDate,\n );\n return laterDate_.getFullYear() === earlierDate_.getFullYear();\n}\n\n// Fallback for modularized imports:\nexport default isSameYear;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { getDaysInMonth } from \"./getDaysInMonth.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link setMonth} function options.\n */\n\n/**\n * @name setMonth\n * @category Month Helpers\n * @summary Set the month to the given date.\n *\n * @description\n * Set the month to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param month - The month index to set (0-11)\n * @param options - The options\n *\n * @returns The new date with the month set\n *\n * @example\n * // Set February to 1 September 2014:\n * const result = setMonth(new Date(2014, 8, 1), 1)\n * //=> Sat Feb 01 2014 00:00:00\n */\nexport function setMonth(date, month, options) {\n const _date = toDate(date, options?.in);\n const year = _date.getFullYear();\n const day = _date.getDate();\n\n const midMonth = constructFrom(options?.in || date, 0);\n midMonth.setFullYear(year, month, 15);\n midMonth.setHours(0, 0, 0, 0);\n const daysInMonth = getDaysInMonth(midMonth);\n\n // Set the earlier date, allows to wrap Jan 31 to Feb 28\n _date.setMonth(month, Math.min(day, daysInMonth));\n return _date;\n}\n\n// Fallback for modularized imports:\nexport default setMonth;\n","import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link setYear} function options.\n */\n\n/**\n * @name setYear\n * @category Year Helpers\n * @summary Set the year to the given date.\n *\n * @description\n * Set the year to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param year - The year of the new date\n * @param options - An object with options.\n *\n * @returns The new date with the year set\n *\n * @example\n * // Set year 2013 to 1 September 2014:\n * const result = setYear(new Date(2014, 8, 1), 2013)\n * //=> Sun Sep 01 2013 00:00:00\n */\nexport function setYear(date, year, options) {\n const date_ = toDate(date, options?.in);\n\n // Check if date is Invalid Date because Date.prototype.setFullYear ignores the value of Invalid Date\n if (isNaN(+date_)) return constructFrom(options?.in || date, NaN);\n\n date_.setFullYear(year);\n return date_;\n}\n\n// Fallback for modularized imports:\nexport default setYear;\n","const FIVE_WEEKS = 5;\nconst FOUR_WEEKS = 4;\n/**\n * Returns the number of weeks to display in the broadcast calendar for a given\n * month.\n *\n * The broadcast calendar may have either 4 or 5 weeks in a month, depending on\n * the start and end dates of the broadcast weeks.\n *\n * @since 9.4.0\n * @param month The month for which to calculate the number of weeks.\n * @param dateLib The date library to use for date manipulation.\n * @returns The number of weeks in the broadcast calendar (4 or 5).\n */\nexport function getBroadcastWeeksInMonth(month, dateLib) {\n // Get the first day of the month\n const firstDayOfMonth = dateLib.startOfMonth(month);\n // Get the day of the week for the first day of the month (1-7, where 1 is Monday)\n const firstDayOfWeek = firstDayOfMonth.getDay() > 0 ? firstDayOfMonth.getDay() : 7;\n const broadcastStartDate = dateLib.addDays(month, -firstDayOfWeek + 1);\n const lastDateOfLastWeek = dateLib.addDays(broadcastStartDate, FIVE_WEEKS * 7 - 1);\n const numberOfWeeks = dateLib.getMonth(month) === dateLib.getMonth(lastDateOfLastWeek)\n ? FIVE_WEEKS\n : FOUR_WEEKS;\n return numberOfWeeks;\n}\n","/**\n * Returns the start date of the week in the broadcast calendar.\n *\n * The broadcast week starts on Monday. If the first day of the month is not a\n * Monday, this function calculates the previous Monday as the start of the\n * broadcast week.\n *\n * @since 9.4.0\n * @param date The date for which to calculate the start of the broadcast week.\n * @param dateLib The date library to use for date manipulation.\n * @returns The start date of the broadcast week.\n */\nexport function startOfBroadcastWeek(date, dateLib) {\n const firstOfMonth = dateLib.startOfMonth(date);\n const dayOfWeek = firstOfMonth.getDay();\n if (dayOfWeek === 1) {\n return firstOfMonth;\n }\n else if (dayOfWeek === 0) {\n return dateLib.addDays(firstOfMonth, -1 * 6);\n }\n else {\n return dateLib.addDays(firstOfMonth, -1 * (dayOfWeek - 1));\n }\n}\n","import { getBroadcastWeeksInMonth } from \"./getBroadcastWeeksInMonth.js\";\nimport { startOfBroadcastWeek } from \"./startOfBroadcastWeek.js\";\n/**\n * Returns the end date of the week in the broadcast calendar.\n *\n * The broadcast week ends on the last day of the last broadcast week for the\n * given date.\n *\n * @since 9.4.0\n * @param date The date for which to calculate the end of the broadcast week.\n * @param dateLib The date library to use for date manipulation.\n * @returns The end date of the broadcast week.\n */\nexport function endOfBroadcastWeek(date, dateLib) {\n const startDate = startOfBroadcastWeek(date, dateLib);\n const numberOfWeeks = getBroadcastWeeksInMonth(date, dateLib);\n const endDate = dateLib.addDays(startDate, numberOfWeeks * 7 - 1);\n return endDate;\n}\n","const formatDistanceLocale = {\n lessThanXSeconds: {\n one: \"1초 미만\",\n other: \"{{count}}초 미만\",\n },\n\n xSeconds: {\n one: \"1초\",\n other: \"{{count}}초\",\n },\n\n halfAMinute: \"30초\",\n\n lessThanXMinutes: {\n one: \"1분 미만\",\n other: \"{{count}}분 미만\",\n },\n\n xMinutes: {\n one: \"1분\",\n other: \"{{count}}분\",\n },\n\n aboutXHours: {\n one: \"약 1시간\",\n other: \"약 {{count}}시간\",\n },\n\n xHours: {\n one: \"1시간\",\n other: \"{{count}}시간\",\n },\n\n xDays: {\n one: \"1일\",\n other: \"{{count}}일\",\n },\n\n aboutXWeeks: {\n one: \"약 1주\",\n other: \"약 {{count}}주\",\n },\n\n xWeeks: {\n one: \"1주\",\n other: \"{{count}}주\",\n },\n\n aboutXMonths: {\n one: \"약 1개월\",\n other: \"약 {{count}}개월\",\n },\n\n xMonths: {\n one: \"1개월\",\n other: \"{{count}}개월\",\n },\n\n aboutXYears: {\n one: \"약 1년\",\n other: \"약 {{count}}년\",\n },\n\n xYears: {\n one: \"1년\",\n other: \"{{count}}년\",\n },\n\n overXYears: {\n one: \"1년 이상\",\n other: \"{{count}}년 이상\",\n },\n\n almostXYears: {\n one: \"거의 1년\",\n other: \"거의 {{count}}년\",\n },\n};\n\nexport const formatDistance = (token, count, options) => {\n let result;\n\n const tokenValue = formatDistanceLocale[token];\n if (typeof tokenValue === \"string\") {\n result = tokenValue;\n } else if (count === 1) {\n result = tokenValue.one;\n } else {\n result = tokenValue.other.replace(\"{{count}}\", count.toString());\n }\n\n if (options?.addSuffix) {\n if (options.comparison && options.comparison > 0) {\n return result + \" 후\";\n } else {\n return result + \" 전\";\n }\n }\n\n return result;\n};\n","import { buildFormatLongFn } from \"../../_lib/buildFormatLongFn.js\";\n\nconst dateFormats = {\n full: \"y년 M월 d일 EEEE\",\n long: \"y년 M월 d일\",\n medium: \"y.MM.dd\",\n short: \"y.MM.dd\",\n};\n\nconst timeFormats = {\n full: \"a H시 mm분 ss초 zzzz\",\n long: \"a H:mm:ss z\",\n medium: \"HH:mm:ss\",\n short: \"HH:mm\",\n};\n\nconst dateTimeFormats = {\n full: \"{{date}} {{time}}\",\n long: \"{{date}} {{time}}\",\n medium: \"{{date}} {{time}}\",\n short: \"{{date}} {{time}}\",\n};\n\nexport const formatLong = {\n date: buildFormatLongFn({\n formats: dateFormats,\n defaultWidth: \"full\",\n }),\n\n time: buildFormatLongFn({\n formats: timeFormats,\n defaultWidth: \"full\",\n }),\n\n dateTime: buildFormatLongFn({\n formats: dateTimeFormats,\n defaultWidth: \"full\",\n }),\n};\n","const formatRelativeLocale = {\n lastWeek: \"'지난' eeee p\",\n yesterday: \"'어제' p\",\n today: \"'오늘' p\",\n tomorrow: \"'내일' p\",\n nextWeek: \"'다음' eeee p\",\n other: \"P\",\n};\n\nexport const formatRelative = (token, _date, _baseDate, _options) =>\n formatRelativeLocale[token];\n","import { buildLocalizeFn } from \"../../_lib/buildLocalizeFn.js\";\n\nconst eraValues = {\n narrow: [\"BC\", \"AD\"],\n abbreviated: [\"BC\", \"AD\"],\n wide: [\"기원전\", \"서기\"],\n};\n\nconst quarterValues = {\n narrow: [\"1\", \"2\", \"3\", \"4\"],\n abbreviated: [\"Q1\", \"Q2\", \"Q3\", \"Q4\"],\n wide: [\"1분기\", \"2분기\", \"3분기\", \"4분기\"],\n};\n\nconst monthValues = {\n narrow: [\"1\", \"2\", \"3\", \"4\", \"5\", \"6\", \"7\", \"8\", \"9\", \"10\", \"11\", \"12\"],\n\n abbreviated: [\n \"1월\",\n \"2월\",\n \"3월\",\n \"4월\",\n \"5월\",\n \"6월\",\n \"7월\",\n \"8월\",\n \"9월\",\n \"10월\",\n \"11월\",\n \"12월\",\n ],\n\n wide: [\n \"1월\",\n \"2월\",\n \"3월\",\n \"4월\",\n \"5월\",\n \"6월\",\n \"7월\",\n \"8월\",\n \"9월\",\n \"10월\",\n \"11월\",\n \"12월\",\n ],\n};\n\nconst dayValues = {\n narrow: [\"일\", \"월\", \"화\", \"수\", \"목\", \"금\", \"토\"],\n short: [\"일\", \"월\", \"화\", \"수\", \"목\", \"금\", \"토\"],\n abbreviated: [\"일\", \"월\", \"화\", \"수\", \"목\", \"금\", \"토\"],\n wide: [\"일요일\", \"월요일\", \"화요일\", \"수요일\", \"목요일\", \"금요일\", \"토요일\"],\n};\n\nconst dayPeriodValues = {\n narrow: {\n am: \"오전\",\n pm: \"오후\",\n midnight: \"자정\",\n noon: \"정오\",\n morning: \"아침\",\n afternoon: \"오후\",\n evening: \"저녁\",\n night: \"밤\",\n },\n abbreviated: {\n am: \"오전\",\n pm: \"오후\",\n midnight: \"자정\",\n noon: \"정오\",\n morning: \"아침\",\n afternoon: \"오후\",\n evening: \"저녁\",\n night: \"밤\",\n },\n wide: {\n am: \"오전\",\n pm: \"오후\",\n midnight: \"자정\",\n noon: \"정오\",\n morning: \"아침\",\n afternoon: \"오후\",\n evening: \"저녁\",\n night: \"밤\",\n },\n};\n\nconst formattingDayPeriodValues = {\n narrow: {\n am: \"오전\",\n pm: \"오후\",\n midnight: \"자정\",\n noon: \"정오\",\n morning: \"아침\",\n afternoon: \"오후\",\n evening: \"저녁\",\n night: \"밤\",\n },\n abbreviated: {\n am: \"오전\",\n pm: \"오후\",\n midnight: \"자정\",\n noon: \"정오\",\n morning: \"아침\",\n afternoon: \"오후\",\n evening: \"저녁\",\n night: \"밤\",\n },\n wide: {\n am: \"오전\",\n pm: \"오후\",\n midnight: \"자정\",\n noon: \"정오\",\n morning: \"아침\",\n afternoon: \"오후\",\n evening: \"저녁\",\n night: \"밤\",\n },\n};\n\nconst ordinalNumber = (dirtyNumber, options) => {\n const number = Number(dirtyNumber);\n const unit = String(options?.unit);\n\n switch (unit) {\n case \"minute\":\n case \"second\":\n return String(number);\n case \"date\":\n return number + \"일\";\n default:\n return number + \"번째\";\n }\n};\n\nexport const localize = {\n ordinalNumber,\n\n era: buildLocalizeFn({\n values: eraValues,\n defaultWidth: \"wide\",\n }),\n\n quarter: buildLocalizeFn({\n values: quarterValues,\n defaultWidth: \"wide\",\n argumentCallback: (quarter) => quarter - 1,\n }),\n\n month: buildLocalizeFn({\n values: monthValues,\n defaultWidth: \"wide\",\n }),\n\n day: buildLocalizeFn({\n values: dayValues,\n defaultWidth: \"wide\",\n }),\n\n dayPeriod: buildLocalizeFn({\n values: dayPeriodValues,\n defaultWidth: \"wide\",\n formattingValues: formattingDayPeriodValues,\n defaultFormattingWidth: \"wide\",\n }),\n};\n","import { buildMatchFn } from \"../../_lib/buildMatchFn.js\";\nimport { buildMatchPatternFn } from \"../../_lib/buildMatchPatternFn.js\";\n\nconst matchOrdinalNumberPattern = /^(\\d+)(일|번째)?/i;\nconst parseOrdinalNumberPattern = /\\d+/i;\n\nconst matchEraPatterns = {\n narrow: /^(b\\.?\\s?c\\.?|b\\.?\\s?c\\.?\\s?e\\.?|a\\.?\\s?d\\.?|c\\.?\\s?e\\.?)/i,\n abbreviated: /^(b\\.?\\s?c\\.?|b\\.?\\s?c\\.?\\s?e\\.?|a\\.?\\s?d\\.?|c\\.?\\s?e\\.?)/i,\n wide: /^(기원전|서기)/i,\n};\nconst parseEraPatterns = {\n any: [/^(bc|기원전)/i, /^(ad|서기)/i],\n};\n\nconst matchQuarterPatterns = {\n narrow: /^[1234]/i,\n abbreviated: /^q[1234]/i,\n wide: /^[1234]사?분기/i,\n};\nconst parseQuarterPatterns = {\n any: [/1/i, /2/i, /3/i, /4/i],\n};\n\nconst matchMonthPatterns = {\n narrow: /^(1[012]|[123456789])/,\n abbreviated: /^(1[012]|[123456789])월/i,\n wide: /^(1[012]|[123456789])월/i,\n};\nconst parseMonthPatterns = {\n any: [\n /^1월?$/,\n /^2/,\n /^3/,\n /^4/,\n /^5/,\n /^6/,\n /^7/,\n /^8/,\n /^9/,\n /^10/,\n /^11/,\n /^12/,\n ],\n};\n\nconst matchDayPatterns = {\n narrow: /^[일월화수목금토]/,\n short: /^[일월화수목금토]/,\n abbreviated: /^[일월화수목금토]/,\n wide: /^[일월화수목금토]요일/,\n};\nconst parseDayPatterns = {\n any: [/^일/, /^월/, /^화/, /^수/, /^목/, /^금/, /^토/],\n};\n\nconst matchDayPeriodPatterns = {\n any: /^(am|pm|오전|오후|자정|정오|아침|저녁|밤)/i,\n};\nconst parseDayPeriodPatterns = {\n any: {\n am: /^(am|오전)/i,\n pm: /^(pm|오후)/i,\n midnight: /^자정/i,\n noon: /^정오/i,\n morning: /^아침/i,\n afternoon: /^오후/i,\n evening: /^저녁/i,\n night: /^밤/i,\n },\n};\n\nexport const match = {\n ordinalNumber: buildMatchPatternFn({\n matchPattern: matchOrdinalNumberPattern,\n parsePattern: parseOrdinalNumberPattern,\n valueCallback: (value) => parseInt(value, 10),\n }),\n\n era: buildMatchFn({\n matchPatterns: matchEraPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseEraPatterns,\n defaultParseWidth: \"any\",\n }),\n\n quarter: buildMatchFn({\n matchPatterns: matchQuarterPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseQuarterPatterns,\n defaultParseWidth: \"any\",\n valueCallback: (index) => index + 1,\n }),\n\n month: buildMatchFn({\n matchPatterns: matchMonthPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseMonthPatterns,\n defaultParseWidth: \"any\",\n }),\n\n day: buildMatchFn({\n matchPatterns: matchDayPatterns,\n defaultMatchWidth: \"wide\",\n parsePatterns: parseDayPatterns,\n defaultParseWidth: \"any\",\n }),\n\n dayPeriod: buildMatchFn({\n matchPatterns: matchDayPeriodPatterns,\n defaultMatchWidth: \"any\",\n parsePatterns: parseDayPeriodPatterns,\n defaultParseWidth: \"any\",\n }),\n};\n","import { formatDistance } from \"./ko/_lib/formatDistance.js\";\nimport { formatLong } from \"./ko/_lib/formatLong.js\";\nimport { formatRelative } from \"./ko/_lib/formatRelative.js\";\nimport { localize } from \"./ko/_lib/localize.js\";\nimport { match } from \"./ko/_lib/match.js\";\n\n/**\n * @category Locales\n * @summary Korean locale.\n * @language Korean\n * @iso-639-2 kor\n * @author Hong Chulju [@angdev](https://github.com/angdev)\n * @author Lee Seoyoen [@iamssen](https://github.com/iamssen)\n * @author Taiki IKeda [@so99ynoodles](https://github.com/so99ynoodles)\n */\nexport const ko = {\n code: \"ko\",\n formatDistance: formatDistance,\n formatLong: formatLong,\n formatRelative: formatRelative,\n localize: localize,\n match: match,\n options: {\n weekStartsOn: 0 /* Sunday */,\n firstWeekContainsDate: 1,\n },\n};\n\n// Fallback for modularized imports:\nexport default ko;\n","import { format } from \"date-fns\";\nimport { enUS as dateFnsEnUS } from \"date-fns/locale\";\n/** English (United States) locale extended with DayPicker-specific translations. */\nexport const enUS = {\n ...dateFnsEnUS,\n labels: {\n labelDayButton: (date, modifiers, options, dateLib) => {\n let formatDate;\n if (dateLib && typeof dateLib.format === \"function\") {\n formatDate = dateLib.format.bind(dateLib);\n }\n else {\n formatDate = (d, pattern) => format(d, pattern, { locale: dateFnsEnUS, ...options });\n }\n let label = formatDate(date, \"PPPP\");\n if (modifiers.today)\n label = `Today, ${label}`;\n if (modifiers.selected)\n label = `${label}, selected`;\n return label;\n },\n labelMonthDropdown: \"Choose the Month\",\n labelNext: \"Go to the Next Month\",\n labelPrevious: \"Go to the Previous Month\",\n labelWeekNumber: (weekNumber) => `Week ${weekNumber}`,\n labelYearDropdown: \"Choose the Year\",\n labelGrid: (date, options, dateLib) => {\n let formatDate;\n if (dateLib && typeof dateLib.format === \"function\") {\n formatDate = dateLib.format.bind(dateLib);\n }\n else {\n formatDate = (d, pattern) => format(d, pattern, { locale: dateFnsEnUS, ...options });\n }\n return formatDate(date, \"LLLL yyyy\");\n },\n labelGridcell: (date, modifiers, options, dateLib) => {\n let formatDate;\n if (dateLib && typeof dateLib.format === \"function\") {\n formatDate = dateLib.format.bind(dateLib);\n }\n else {\n formatDate = (d, pattern) => format(d, pattern, { locale: dateFnsEnUS, ...options });\n }\n let label = formatDate(date, \"PPPP\");\n if (modifiers?.today) {\n label = `Today, ${label}`;\n }\n return label;\n },\n labelNav: \"Navigation bar\",\n labelWeekNumberHeader: \"Week Number\",\n labelWeekday: (date, options, dateLib) => {\n let formatDate;\n if (dateLib && typeof dateLib.format === \"function\") {\n formatDate = dateLib.format.bind(dateLib);\n }\n else {\n formatDate = (d, pattern) => format(d, pattern, { locale: dateFnsEnUS, ...options });\n }\n return formatDate(date, \"cccc\");\n },\n },\n};\n","import { TZDate } from \"@date-fns/tz\";\nimport { addDays, addMonths, addWeeks, addYears, differenceInCalendarDays, differenceInCalendarMonths, eachMonthOfInterval, eachYearOfInterval, endOfISOWeek, endOfMonth, endOfWeek, endOfYear, format, getISOWeek, getMonth, getWeek, getYear, isAfter, isBefore, isDate, isSameDay, isSameMonth, isSameYear, max, min, setMonth, setYear, startOfDay, startOfISOWeek, startOfMonth, startOfWeek, startOfYear, } from \"date-fns\";\nimport { endOfBroadcastWeek } from \"../helpers/endOfBroadcastWeek.js\";\nimport { startOfBroadcastWeek } from \"../helpers/startOfBroadcastWeek.js\";\nimport { enUS } from \"../locale/en-US.js\";\n/**\n * A wrapper class around [date-fns](http://date-fns.org) that provides utility\n * methods for date manipulation and formatting.\n *\n * @since 9.2.0\n * @example\n * const dateLib = new DateLib({ locale: es });\n * const newDate = dateLib.addDays(new Date(), 5);\n */\nexport class DateLib {\n /**\n * Creates an instance of `DateLib`.\n *\n * @param options Configuration options for the date library.\n * @param overrides Custom overrides for the date library functions.\n */\n constructor(options, overrides) {\n /**\n * Reference to the built-in Date constructor.\n *\n * @deprecated Use `newDate()` or `today()`.\n */\n this.Date = Date;\n /**\n * Creates a new `Date` object representing today's date.\n *\n * @since 9.5.0\n * @returns A `Date` object for today's date.\n */\n this.today = () => {\n if (this.overrides?.today) {\n return this.overrides.today();\n }\n if (this.options.timeZone) {\n return TZDate.tz(this.options.timeZone);\n }\n return new this.Date();\n };\n /**\n * Creates a new `Date` object with the specified year, month, and day.\n *\n * @since 9.5.0\n * @param year The year.\n * @param monthIndex The month (0-11).\n * @param date The day of the month.\n * @returns A new `Date` object.\n */\n this.newDate = (year, monthIndex, date) => {\n if (this.overrides?.newDate) {\n return this.overrides.newDate(year, monthIndex, date);\n }\n if (this.options.timeZone) {\n return new TZDate(year, monthIndex, date, this.options.timeZone);\n }\n return new Date(year, monthIndex, date);\n };\n /**\n * Adds the specified number of days to the given date.\n *\n * @param date The date to add days to.\n * @param amount The number of days to add.\n * @returns The new date with the days added.\n */\n this.addDays = (date, amount) => {\n return this.overrides?.addDays\n ? this.overrides.addDays(date, amount)\n : addDays(date, amount);\n };\n /**\n * Adds the specified number of months to the given date.\n *\n * @param date The date to add months to.\n * @param amount The number of months to add.\n * @returns The new date with the months added.\n */\n this.addMonths = (date, amount) => {\n return this.overrides?.addMonths\n ? this.overrides.addMonths(date, amount)\n : addMonths(date, amount);\n };\n /**\n * Adds the specified number of weeks to the given date.\n *\n * @param date The date to add weeks to.\n * @param amount The number of weeks to add.\n * @returns The new date with the weeks added.\n */\n this.addWeeks = (date, amount) => {\n return this.overrides?.addWeeks\n ? this.overrides.addWeeks(date, amount)\n : addWeeks(date, amount);\n };\n /**\n * Adds the specified number of years to the given date.\n *\n * @param date The date to add years to.\n * @param amount The number of years to add.\n * @returns The new date with the years added.\n */\n this.addYears = (date, amount) => {\n return this.overrides?.addYears\n ? this.overrides.addYears(date, amount)\n : addYears(date, amount);\n };\n /**\n * Returns the number of calendar days between the given dates.\n *\n * @param dateLeft The later date.\n * @param dateRight The earlier date.\n * @returns The number of calendar days between the dates.\n */\n this.differenceInCalendarDays = (dateLeft, dateRight) => {\n return this.overrides?.differenceInCalendarDays\n ? this.overrides.differenceInCalendarDays(dateLeft, dateRight)\n : differenceInCalendarDays(dateLeft, dateRight);\n };\n /**\n * Returns the number of calendar months between the given dates.\n *\n * @param dateLeft The later date.\n * @param dateRight The earlier date.\n * @returns The number of calendar months between the dates.\n */\n this.differenceInCalendarMonths = (dateLeft, dateRight) => {\n return this.overrides?.differenceInCalendarMonths\n ? this.overrides.differenceInCalendarMonths(dateLeft, dateRight)\n : differenceInCalendarMonths(dateLeft, dateRight);\n };\n /**\n * Returns the months between the given dates.\n *\n * @param interval The interval to get the months for.\n */\n this.eachMonthOfInterval = (interval) => {\n return this.overrides?.eachMonthOfInterval\n ? this.overrides.eachMonthOfInterval(interval)\n : eachMonthOfInterval(interval);\n };\n /**\n * Returns the years between the given dates.\n *\n * @since 9.11.1\n * @param interval The interval to get the years for.\n * @returns The array of years in the interval.\n */\n this.eachYearOfInterval = (interval) => {\n const years = this.overrides?.eachYearOfInterval\n ? this.overrides.eachYearOfInterval(interval)\n : eachYearOfInterval(interval);\n // Remove duplicates that may happen across DST transitions (e.g., \"America/Sao_Paulo\")\n // See https://github.com/date-fns/tz/issues/72\n const uniqueYears = new Set(years.map((d) => this.getYear(d)));\n if (uniqueYears.size === years.length) {\n // No duplicates, return as is\n return years;\n }\n // Rebuild the array to ensure one date per year\n const yearsArray = [];\n uniqueYears.forEach((y) => {\n yearsArray.push(new Date(y, 0, 1));\n });\n return yearsArray;\n };\n /**\n * Returns the end of the broadcast week for the given date.\n *\n * @param date The original date.\n * @returns The end of the broadcast week.\n */\n this.endOfBroadcastWeek = (date) => {\n return this.overrides?.endOfBroadcastWeek\n ? this.overrides.endOfBroadcastWeek(date)\n : endOfBroadcastWeek(date, this);\n };\n /**\n * Returns the end of the ISO week for the given date.\n *\n * @param date The original date.\n * @returns The end of the ISO week.\n */\n this.endOfISOWeek = (date) => {\n return this.overrides?.endOfISOWeek\n ? this.overrides.endOfISOWeek(date)\n : endOfISOWeek(date);\n };\n /**\n * Returns the end of the month for the given date.\n *\n * @param date The original date.\n * @returns The end of the month.\n */\n this.endOfMonth = (date) => {\n return this.overrides?.endOfMonth\n ? this.overrides.endOfMonth(date)\n : endOfMonth(date);\n };\n /**\n * Returns the end of the week for the given date.\n *\n * @param date The original date.\n * @returns The end of the week.\n */\n this.endOfWeek = (date, options) => {\n return this.overrides?.endOfWeek\n ? this.overrides.endOfWeek(date, options)\n : endOfWeek(date, this.options);\n };\n /**\n * Returns the end of the year for the given date.\n *\n * @param date The original date.\n * @returns The end of the year.\n */\n this.endOfYear = (date) => {\n return this.overrides?.endOfYear\n ? this.overrides.endOfYear(date)\n : endOfYear(date);\n };\n /**\n * Formats the given date using the specified format string.\n *\n * @param date The date to format.\n * @param formatStr The format string.\n * @returns The formatted date string.\n */\n this.format = (date, formatStr, _options) => {\n const formatted = this.overrides?.format\n ? this.overrides.format(date, formatStr, this.options)\n : format(date, formatStr, this.options);\n if (this.options.numerals && this.options.numerals !== \"latn\") {\n return this.replaceDigits(formatted);\n }\n return formatted;\n };\n /**\n * Returns the ISO week number for the given date.\n *\n * @param date The date to get the ISO week number for.\n * @returns The ISO week number.\n */\n this.getISOWeek = (date) => {\n return this.overrides?.getISOWeek\n ? this.overrides.getISOWeek(date)\n : getISOWeek(date);\n };\n /**\n * Returns the month of the given date.\n *\n * @param date The date to get the month for.\n * @returns The month.\n */\n this.getMonth = (date, _options) => {\n return this.overrides?.getMonth\n ? this.overrides.getMonth(date, this.options)\n : getMonth(date, this.options);\n };\n /**\n * Returns the year of the given date.\n *\n * @param date The date to get the year for.\n * @returns The year.\n */\n this.getYear = (date, _options) => {\n return this.overrides?.getYear\n ? this.overrides.getYear(date, this.options)\n : getYear(date, this.options);\n };\n /**\n * Returns the local week number for the given date.\n *\n * @param date The date to get the week number for.\n * @returns The week number.\n */\n this.getWeek = (date, _options) => {\n return this.overrides?.getWeek\n ? this.overrides.getWeek(date, this.options)\n : getWeek(date, this.options);\n };\n /**\n * Checks if the first date is after the second date.\n *\n * @param date The date to compare.\n * @param dateToCompare The date to compare with.\n * @returns True if the first date is after the second date.\n */\n this.isAfter = (date, dateToCompare) => {\n return this.overrides?.isAfter\n ? this.overrides.isAfter(date, dateToCompare)\n : isAfter(date, dateToCompare);\n };\n /**\n * Checks if the first date is before the second date.\n *\n * @param date The date to compare.\n * @param dateToCompare The date to compare with.\n * @returns True if the first date is before the second date.\n */\n this.isBefore = (date, dateToCompare) => {\n return this.overrides?.isBefore\n ? this.overrides.isBefore(date, dateToCompare)\n : isBefore(date, dateToCompare);\n };\n /**\n * Checks if the given value is a Date object.\n *\n * @param value The value to check.\n * @returns True if the value is a Date object.\n */\n this.isDate = (value) => {\n return this.overrides?.isDate\n ? this.overrides.isDate(value)\n : isDate(value);\n };\n /**\n * Checks if the given dates are on the same day.\n *\n * @param dateLeft The first date to compare.\n * @param dateRight The second date to compare.\n * @returns True if the dates are on the same day.\n */\n this.isSameDay = (dateLeft, dateRight) => {\n return this.overrides?.isSameDay\n ? this.overrides.isSameDay(dateLeft, dateRight)\n : isSameDay(dateLeft, dateRight);\n };\n /**\n * Checks if the given dates are in the same month.\n *\n * @param dateLeft The first date to compare.\n * @param dateRight The second date to compare.\n * @returns True if the dates are in the same month.\n */\n this.isSameMonth = (dateLeft, dateRight) => {\n return this.overrides?.isSameMonth\n ? this.overrides.isSameMonth(dateLeft, dateRight)\n : isSameMonth(dateLeft, dateRight);\n };\n /**\n * Checks if the given dates are in the same year.\n *\n * @param dateLeft The first date to compare.\n * @param dateRight The second date to compare.\n * @returns True if the dates are in the same year.\n */\n this.isSameYear = (dateLeft, dateRight) => {\n return this.overrides?.isSameYear\n ? this.overrides.isSameYear(dateLeft, dateRight)\n : isSameYear(dateLeft, dateRight);\n };\n /**\n * Returns the latest date in the given array of dates.\n *\n * @param dates The array of dates to compare.\n * @returns The latest date.\n */\n this.max = (dates) => {\n return this.overrides?.max ? this.overrides.max(dates) : max(dates);\n };\n /**\n * Returns the earliest date in the given array of dates.\n *\n * @param dates The array of dates to compare.\n * @returns The earliest date.\n */\n this.min = (dates) => {\n return this.overrides?.min ? this.overrides.min(dates) : min(dates);\n };\n /**\n * Sets the month of the given date.\n *\n * @param date The date to set the month on.\n * @param month The month to set (0-11).\n * @returns The new date with the month set.\n */\n this.setMonth = (date, month) => {\n return this.overrides?.setMonth\n ? this.overrides.setMonth(date, month)\n : setMonth(date, month);\n };\n /**\n * Sets the year of the given date.\n *\n * @param date The date to set the year on.\n * @param year The year to set.\n * @returns The new date with the year set.\n */\n this.setYear = (date, year) => {\n return this.overrides?.setYear\n ? this.overrides.setYear(date, year)\n : setYear(date, year);\n };\n /**\n * Returns the start of the broadcast week for the given date.\n *\n * @param date The original date.\n * @returns The start of the broadcast week.\n */\n this.startOfBroadcastWeek = (date, _dateLib) => {\n return this.overrides?.startOfBroadcastWeek\n ? this.overrides.startOfBroadcastWeek(date, this)\n : startOfBroadcastWeek(date, this);\n };\n /**\n * Returns the start of the day for the given date.\n *\n * @param date The original date.\n * @returns The start of the day.\n */\n this.startOfDay = (date) => {\n return this.overrides?.startOfDay\n ? this.overrides.startOfDay(date)\n : startOfDay(date);\n };\n /**\n * Returns the start of the ISO week for the given date.\n *\n * @param date The original date.\n * @returns The start of the ISO week.\n */\n this.startOfISOWeek = (date) => {\n return this.overrides?.startOfISOWeek\n ? this.overrides.startOfISOWeek(date)\n : startOfISOWeek(date);\n };\n /**\n * Returns the start of the month for the given date.\n *\n * @param date The original date.\n * @returns The start of the month.\n */\n this.startOfMonth = (date) => {\n return this.overrides?.startOfMonth\n ? this.overrides.startOfMonth(date)\n : startOfMonth(date);\n };\n /**\n * Returns the start of the week for the given date.\n *\n * @param date The original date.\n * @returns The start of the week.\n */\n this.startOfWeek = (date, _options) => {\n return this.overrides?.startOfWeek\n ? this.overrides.startOfWeek(date, this.options)\n : startOfWeek(date, this.options);\n };\n /**\n * Returns the start of the year for the given date.\n *\n * @param date The original date.\n * @returns The start of the year.\n */\n this.startOfYear = (date) => {\n return this.overrides?.startOfYear\n ? this.overrides.startOfYear(date)\n : startOfYear(date);\n };\n this.options = { locale: enUS, ...options };\n this.overrides = overrides;\n }\n /**\n * Generates a mapping of Arabic digits (0-9) to the target numbering system\n * digits.\n *\n * @since 9.5.0\n * @returns A record mapping Arabic digits to the target numerals.\n */\n getDigitMap() {\n const { numerals = \"latn\" } = this.options;\n // Use Intl.NumberFormat to create a formatter with the specified numbering system\n const formatter = new Intl.NumberFormat(\"en-US\", {\n numberingSystem: numerals,\n });\n // Map Arabic digits (0-9) to the target numerals\n const digitMap = {};\n for (let i = 0; i < 10; i++) {\n digitMap[i.toString()] = formatter.format(i);\n }\n return digitMap;\n }\n /**\n * Replaces Arabic digits in a string with the target numbering system digits.\n *\n * @since 9.5.0\n * @param input The string containing Arabic digits.\n * @returns The string with digits replaced.\n */\n replaceDigits(input) {\n const digitMap = this.getDigitMap();\n return input.replace(/\\d/g, (digit) => digitMap[digit] || digit);\n }\n /**\n * Formats a number using the configured numbering system.\n *\n * @since 9.5.0\n * @param value The number to format.\n * @returns The formatted number as a string.\n */\n formatNumber(value) {\n return this.replaceDigits(value.toString());\n }\n /**\n * Returns the preferred ordering for month and year labels for the current\n * locale.\n */\n getMonthYearOrder() {\n const code = this.options.locale?.code;\n if (!code) {\n return \"month-first\";\n }\n return DateLib.yearFirstLocales.has(code) ? \"year-first\" : \"month-first\";\n }\n /**\n * Formats the month/year pair respecting locale conventions.\n *\n * @since 9.11.0\n */\n formatMonthYear(date) {\n const { locale, timeZone, numerals } = this.options;\n const localeCode = locale?.code;\n if (localeCode && DateLib.yearFirstLocales.has(localeCode)) {\n try {\n const intl = new Intl.DateTimeFormat(localeCode, {\n month: \"long\",\n year: \"numeric\",\n timeZone,\n numberingSystem: numerals,\n });\n const formatted = intl.format(date);\n return formatted;\n }\n catch {\n // Fallback to date-fns formatting below.\n }\n }\n const pattern = this.getMonthYearOrder() === \"year-first\" ? \"y LLLL\" : \"LLLL y\";\n return this.format(date, pattern);\n }\n}\nDateLib.yearFirstLocales = new Set([\n \"eu\",\n \"hu\",\n \"ja\",\n \"ja-Hira\",\n \"ja-JP\",\n \"ko\",\n \"ko-KR\",\n \"lt\",\n \"lt-LT\",\n \"lv\",\n \"lv-LV\",\n \"mn\",\n \"mn-MN\",\n \"zh\",\n \"zh-CN\",\n \"zh-HK\",\n \"zh-TW\",\n]);\n/** The default locale (English). */\nexport { enUS as defaultLocale } from \"../locale/en-US.js\";\n/**\n * The default date library with English locale.\n *\n * @since 9.2.0\n */\nexport const defaultDateLib = new DateLib();\n/**\n * @ignore\n * @deprecated Use `defaultDateLib`.\n */\nexport const dateLib = defaultDateLib;\n","import { defaultDateLib } from \"./DateLib.js\";\n/**\n * Represents a day displayed in the calendar.\n *\n * In DayPicker, a `CalendarDay` is a wrapper around a `Date` object that\n * provides additional information about the day, such as whether it belongs to\n * the displayed month.\n */\nexport class CalendarDay {\n constructor(date, displayMonth, dateLib = defaultDateLib) {\n this.date = date;\n this.displayMonth = displayMonth;\n this.outside = Boolean(displayMonth && !dateLib.isSameMonth(date, displayMonth));\n this.dateLib = dateLib;\n this.isoDate = dateLib.format(date, \"yyyy-MM-dd\");\n this.displayMonthId = dateLib.format(displayMonth, \"yyyy-MM\");\n this.dateMonthId = dateLib.format(date, \"yyyy-MM\");\n }\n /**\n * Checks if this day is equal to another `CalendarDay`, considering both the\n * date and the displayed month.\n *\n * @param day The `CalendarDay` to compare with.\n * @returns `true` if the days are equal, otherwise `false`.\n */\n isEqualTo(day) {\n return (this.dateLib.isSameDay(day.date, this.date) &&\n this.dateLib.isSameMonth(day.displayMonth, this.displayMonth));\n }\n}\n","/**\n * Represents a month in a calendar year.\n *\n * A `CalendarMonth` contains the weeks within the month and the date of the\n * month.\n */\nexport class CalendarMonth {\n constructor(month, weeks) {\n this.date = month;\n this.weeks = weeks;\n }\n}\n","/**\n * Represents a week in a calendar month.\n *\n * A `CalendarWeek` contains the days within the week and the week number.\n */\nexport class CalendarWeek {\n constructor(weekNumber, days) {\n this.days = days;\n this.weekNumber = weekNumber;\n }\n}\n","import React from \"react\";\n/**\n * Render the button elements in the calendar.\n *\n * @private\n * @deprecated Use `PreviousMonthButton` or `@link NextMonthButton` instead.\n */\nexport function Button(props) {\n return React.createElement(\"button\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render the label in the month caption.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function CaptionLabel(props) {\n return React.createElement(\"span\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render the chevron icon used in the navigation buttons and dropdowns.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Chevron(props) {\n const { size = 24, orientation = \"left\", className } = props;\n return (\n // biome-ignore lint/a11y/noSvgWithoutTitle: handled by the parent component\n React.createElement(\"svg\", { className: className, width: size, height: size, viewBox: \"0 0 24 24\" },\n orientation === \"up\" && (React.createElement(\"polygon\", { points: \"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28\" })),\n orientation === \"down\" && (React.createElement(\"polygon\", { points: \"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72\" })),\n orientation === \"left\" && (React.createElement(\"polygon\", { points: \"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20\" })),\n orientation === \"right\" && (React.createElement(\"polygon\", { points: \"8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20\" }))));\n}\n","import React from \"react\";\n/**\n * Render a grid cell for a specific day in the calendar.\n *\n * Handles interaction and focus for the day. If you only need to change the\n * content of the day cell, consider swapping the `DayButton` component\n * instead.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Day(props) {\n const { day, modifiers, ...tdProps } = props;\n return React.createElement(\"td\", { ...tdProps });\n}\n","import React from \"react\";\n/**\n * Render a button for a specific day in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function DayButton(props) {\n const { day, modifiers, ...buttonProps } = props;\n const ref = React.useRef(null);\n React.useEffect(() => {\n if (modifiers.focused)\n ref.current?.focus();\n }, [modifiers.focused]);\n return React.createElement(\"button\", { ref: ref, ...buttonProps });\n}\n","/**\n * Enum representing the UI elements composing DayPicker. These elements are\n * mapped to {@link CustomComponents}, {@link ClassNames}, and {@link Styles}.\n *\n * Some elements are extended by flags and modifiers.\n */\nexport var UI;\n(function (UI) {\n /** The root component displaying the months and the navigation bar. */\n UI[\"Root\"] = \"root\";\n /** The Chevron SVG element used by navigation buttons and dropdowns. */\n UI[\"Chevron\"] = \"chevron\";\n /**\n * The grid cell with the day's date. Extended by {@link DayFlag} and\n * {@link SelectionState}.\n */\n UI[\"Day\"] = \"day\";\n /** The button containing the formatted day's date, inside the grid cell. */\n UI[\"DayButton\"] = \"day_button\";\n /** The caption label of the month (when not showing the dropdown navigation). */\n UI[\"CaptionLabel\"] = \"caption_label\";\n /** The container of the dropdown navigation (when enabled). */\n UI[\"Dropdowns\"] = \"dropdowns\";\n /** The dropdown element to select for years and months. */\n UI[\"Dropdown\"] = \"dropdown\";\n /** The container element of the dropdown. */\n UI[\"DropdownRoot\"] = \"dropdown_root\";\n /** The root element of the footer. */\n UI[\"Footer\"] = \"footer\";\n /** The month grid. */\n UI[\"MonthGrid\"] = \"month_grid\";\n /** Contains the dropdown navigation or the caption label. */\n UI[\"MonthCaption\"] = \"month_caption\";\n /** The dropdown with the months. */\n UI[\"MonthsDropdown\"] = \"months_dropdown\";\n /** Wrapper of the month grid. */\n UI[\"Month\"] = \"month\";\n /** The container of the displayed months. */\n UI[\"Months\"] = \"months\";\n /** The navigation bar with the previous and next buttons. */\n UI[\"Nav\"] = \"nav\";\n /**\n * The next month button in the navigation. *\n *\n * @since 9.1.0\n */\n UI[\"NextMonthButton\"] = \"button_next\";\n /**\n * The previous month button in the navigation.\n *\n * @since 9.1.0\n */\n UI[\"PreviousMonthButton\"] = \"button_previous\";\n /** The row containing the week. */\n UI[\"Week\"] = \"week\";\n /** The group of row weeks in a month (`tbody`). */\n UI[\"Weeks\"] = \"weeks\";\n /** The column header with the weekday. */\n UI[\"Weekday\"] = \"weekday\";\n /** The row grouping the weekdays in the column headers. */\n UI[\"Weekdays\"] = \"weekdays\";\n /** The cell containing the week number. */\n UI[\"WeekNumber\"] = \"week_number\";\n /** The cell header of the week numbers column. */\n UI[\"WeekNumberHeader\"] = \"week_number_header\";\n /** The dropdown with the years. */\n UI[\"YearsDropdown\"] = \"years_dropdown\";\n})(UI || (UI = {}));\n/** Enum representing flags for the {@link UI.Day} element. */\nexport var DayFlag;\n(function (DayFlag) {\n /** The day is disabled. */\n DayFlag[\"disabled\"] = \"disabled\";\n /** The day is hidden. */\n DayFlag[\"hidden\"] = \"hidden\";\n /** The day is outside the current month. */\n DayFlag[\"outside\"] = \"outside\";\n /** The day is focused. */\n DayFlag[\"focused\"] = \"focused\";\n /** The day is today. */\n DayFlag[\"today\"] = \"today\";\n})(DayFlag || (DayFlag = {}));\n/**\n * Enum representing selection states that can be applied to the {@link UI.Day}\n * element in selection mode.\n */\nexport var SelectionState;\n(function (SelectionState) {\n /** The day is at the end of a selected range. */\n SelectionState[\"range_end\"] = \"range_end\";\n /** The day is at the middle of a selected range. */\n SelectionState[\"range_middle\"] = \"range_middle\";\n /** The day is at the start of a selected range. */\n SelectionState[\"range_start\"] = \"range_start\";\n /** The day is selected. */\n SelectionState[\"selected\"] = \"selected\";\n})(SelectionState || (SelectionState = {}));\n/**\n * Enum representing different animation states for transitioning between\n * months.\n */\nexport var Animation;\n(function (Animation) {\n /** The entering weeks when they appear before the exiting month. */\n Animation[\"weeks_before_enter\"] = \"weeks_before_enter\";\n /** The exiting weeks when they disappear before the entering month. */\n Animation[\"weeks_before_exit\"] = \"weeks_before_exit\";\n /** The entering weeks when they appear after the exiting month. */\n Animation[\"weeks_after_enter\"] = \"weeks_after_enter\";\n /** The exiting weeks when they disappear after the entering month. */\n Animation[\"weeks_after_exit\"] = \"weeks_after_exit\";\n /** The entering caption when it appears after the exiting month. */\n Animation[\"caption_after_enter\"] = \"caption_after_enter\";\n /** The exiting caption when it disappears after the entering month. */\n Animation[\"caption_after_exit\"] = \"caption_after_exit\";\n /** The entering caption when it appears before the exiting month. */\n Animation[\"caption_before_enter\"] = \"caption_before_enter\";\n /** The exiting caption when it disappears before the entering month. */\n Animation[\"caption_before_exit\"] = \"caption_before_exit\";\n})(Animation || (Animation = {}));\n","import React from \"react\";\nimport { UI } from \"../UI.js\";\n/**\n * Render a dropdown component for navigation in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Dropdown(props) {\n const { options, className, components, classNames, ...selectProps } = props;\n const cssClassSelect = [classNames[UI.Dropdown], className].join(\" \");\n const selectedOption = options?.find(({ value }) => value === selectProps.value);\n return (React.createElement(\"span\", { \"data-disabled\": selectProps.disabled, className: classNames[UI.DropdownRoot] },\n React.createElement(components.Select, { className: cssClassSelect, ...selectProps }, options?.map(({ value, label, disabled }) => (React.createElement(components.Option, { key: value, value: value, disabled: disabled }, label)))),\n React.createElement(\"span\", { className: classNames[UI.CaptionLabel], \"aria-hidden\": true },\n selectedOption?.label,\n React.createElement(components.Chevron, { orientation: \"down\", size: 18, className: classNames[UI.Chevron] }))));\n}\n","import React from \"react\";\n/**\n * Render the navigation dropdowns for the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function DropdownNav(props) {\n return React.createElement(\"div\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render the footer of the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Footer(props) {\n return React.createElement(\"div\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render the grid with the weekday header row and the weeks for a specific\n * month.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Month(props) {\n const { calendarMonth, displayIndex, ...divProps } = props;\n return React.createElement(\"div\", { ...divProps }, props.children);\n}\n","import React from \"react\";\n/**\n * Render the caption for a month in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function MonthCaption(props) {\n const { calendarMonth, displayIndex, ...divProps } = props;\n return React.createElement(\"div\", { ...divProps });\n}\n","import React from \"react\";\n/**\n * Render the grid of days for a specific month.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function MonthGrid(props) {\n return React.createElement(\"table\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render a container wrapping the month grids.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Months(props) {\n return React.createElement(\"div\", { ...props });\n}\n","import { createContext, useContext } from \"react\";\n/** @ignore */\nexport const dayPickerContext = createContext(undefined);\n/**\n * Provides access to the DayPicker context, which includes properties and\n * methods to interact with the DayPicker component. This hook must be used\n * within a custom component.\n *\n * @template T - Use this type to refine the returned context type with a\n * specific selection mode.\n * @returns The context to work with DayPicker.\n * @throws {Error} If the hook is used outside of a DayPicker provider.\n * @group Hooks\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function useDayPicker() {\n const context = useContext(dayPickerContext);\n if (context === undefined) {\n throw new Error(\"useDayPicker() must be used within a custom component.\");\n }\n return context;\n}\n","import React from \"react\";\nimport { useDayPicker } from \"../useDayPicker.js\";\n/**\n * Render a dropdown to navigate between months in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function MonthsDropdown(props) {\n const { components } = useDayPicker();\n return React.createElement(components.Dropdown, { ...props });\n}\n","import React, { useCallback, } from \"react\";\nimport { UI } from \"../UI.js\";\nimport { useDayPicker } from \"../useDayPicker.js\";\n/**\n * Render the navigation toolbar with buttons to navigate between months.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Nav(props) {\n const { onPreviousClick, onNextClick, previousMonth, nextMonth, ...navProps } = props;\n const { components, classNames, labels: { labelPrevious, labelNext }, } = useDayPicker();\n const handleNextClick = useCallback((e) => {\n if (nextMonth) {\n onNextClick?.(e);\n }\n }, [nextMonth, onNextClick]);\n const handlePreviousClick = useCallback((e) => {\n if (previousMonth) {\n onPreviousClick?.(e);\n }\n }, [previousMonth, onPreviousClick]);\n return (React.createElement(\"nav\", { ...navProps },\n React.createElement(components.PreviousMonthButton, { type: \"button\", className: classNames[UI.PreviousMonthButton], tabIndex: previousMonth ? undefined : -1, \"aria-disabled\": previousMonth ? undefined : true, \"aria-label\": labelPrevious(previousMonth), onClick: handlePreviousClick },\n React.createElement(components.Chevron, { disabled: previousMonth ? undefined : true, className: classNames[UI.Chevron], orientation: \"left\" })),\n React.createElement(components.NextMonthButton, { type: \"button\", className: classNames[UI.NextMonthButton], tabIndex: nextMonth ? undefined : -1, \"aria-disabled\": nextMonth ? undefined : true, \"aria-label\": labelNext(nextMonth), onClick: handleNextClick },\n React.createElement(components.Chevron, { disabled: nextMonth ? undefined : true, orientation: \"right\", className: classNames[UI.Chevron] }))));\n}\n","import React from \"react\";\nimport { useDayPicker } from \"../useDayPicker.js\";\n/**\n * Render the button to navigate to the next month in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function NextMonthButton(props) {\n const { components } = useDayPicker();\n return React.createElement(components.Button, { ...props });\n}\n","import React from \"react\";\n/**\n * Render an `option` element.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Option(props) {\n return React.createElement(\"option\", { ...props });\n}\n","import React from \"react\";\nimport { useDayPicker } from \"../useDayPicker.js\";\n/**\n * Render the button to navigate to the previous month in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function PreviousMonthButton(props) {\n const { components } = useDayPicker();\n return React.createElement(components.Button, { ...props });\n}\n","import React from \"react\";\n/**\n * Render the root element of the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Root(props) {\n const { rootRef, ...rest } = props;\n return React.createElement(\"div\", { ...rest, ref: rootRef });\n}\n","import React from \"react\";\n/**\n * Render a `select` element.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Select(props) {\n return React.createElement(\"select\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render a table row representing a week in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Week(props) {\n const { week, ...trProps } = props;\n return React.createElement(\"tr\", { ...trProps });\n}\n","import React from \"react\";\n/**\n * Render a table header cell with the name of a weekday (e.g., \"Mo\", \"Tu\").\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Weekday(props) {\n return React.createElement(\"th\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render the table row containing the weekday names.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Weekdays(props) {\n return (React.createElement(\"thead\", { \"aria-hidden\": true },\n React.createElement(\"tr\", { ...props })));\n}\n","import React from \"react\";\n/**\n * Render a table cell displaying the number of the week.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function WeekNumber(props) {\n const { week, ...thProps } = props;\n return React.createElement(\"th\", { ...thProps });\n}\n","import React from \"react\";\n/**\n * Render the header cell for the week numbers column.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function WeekNumberHeader(props) {\n return React.createElement(\"th\", { ...props });\n}\n","import React from \"react\";\n/**\n * Render the container for the weeks in the month grid.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function Weeks(props) {\n return React.createElement(\"tbody\", { ...props });\n}\n","import React from \"react\";\nimport { useDayPicker } from \"../useDayPicker.js\";\n/**\n * Render a dropdown to navigate between years in the calendar.\n *\n * @group Components\n * @see https://daypicker.dev/guides/custom-components\n */\nexport function YearsDropdown(props) {\n const { components } = useDayPicker();\n return React.createElement(components.Dropdown, { ...props });\n}\n","import { defaultDateLib } from \"../classes/index.js\";\n/**\n * Checks if a given date is within a specified date range.\n *\n * @since 9.0.0\n * @param range - The date range to check against.\n * @param date - The date to check.\n * @param excludeEnds - If `true`, the range's start and end dates are excluded.\n * @param dateLib - The date utility library instance.\n * @returns `true` if the date is within the range, otherwise `false`.\n * @group Utilities\n */\nexport function rangeIncludesDate(range, date, excludeEnds = false, dateLib = defaultDateLib) {\n let { from, to } = range;\n const { differenceInCalendarDays, isSameDay } = dateLib;\n if (from && to) {\n const isRangeInverted = differenceInCalendarDays(to, from) < 0;\n if (isRangeInverted) {\n [from, to] = [to, from];\n }\n const isInRange = differenceInCalendarDays(date, from) >= (excludeEnds ? 1 : 0) &&\n differenceInCalendarDays(to, date) >= (excludeEnds ? 1 : 0);\n return isInRange;\n }\n if (!excludeEnds && to) {\n return isSameDay(to, date);\n }\n if (!excludeEnds && from) {\n return isSameDay(from, date);\n }\n return false;\n}\n/**\n * @private\n * @deprecated Use {@link rangeIncludesDate} instead.\n */\nexport const isDateInRange = (range, date) => rangeIncludesDate(range, date, false, defaultDateLib);\n","/**\n * Checks if the given value is of type {@link DateInterval}.\n *\n * @param matcher - The value to check.\n * @returns `true` if the value is a {@link DateInterval}, otherwise `false`.\n * @group Utilities\n */\nexport function isDateInterval(matcher) {\n return Boolean(matcher &&\n typeof matcher === \"object\" &&\n \"before\" in matcher &&\n \"after\" in matcher);\n}\n/**\n * Checks if the given value is of type {@link DateRange}.\n *\n * @param value - The value to check.\n * @returns `true` if the value is a {@link DateRange}, otherwise `false`.\n * @group Utilities\n */\nexport function isDateRange(value) {\n return Boolean(value && typeof value === \"object\" && \"from\" in value);\n}\n/**\n * Checks if the given value is of type {@link DateAfter}.\n *\n * @param value - The value to check.\n * @returns `true` if the value is a {@link DateAfter}, otherwise `false`.\n * @group Utilities\n */\nexport function isDateAfterType(value) {\n return Boolean(value && typeof value === \"object\" && \"after\" in value);\n}\n/**\n * Checks if the given value is of type {@link DateBefore}.\n *\n * @param value - The value to check.\n * @returns `true` if the value is a {@link DateBefore}, otherwise `false`.\n * @group Utilities\n */\nexport function isDateBeforeType(value) {\n return Boolean(value && typeof value === \"object\" && \"before\" in value);\n}\n/**\n * Checks if the given value is of type {@link DayOfWeek}.\n *\n * @param value - The value to check.\n * @returns `true` if the value is a {@link DayOfWeek}, otherwise `false`.\n * @group Utilities\n */\nexport function isDayOfWeekType(value) {\n return Boolean(value && typeof value === \"object\" && \"dayOfWeek\" in value);\n}\n/**\n * Checks if the given value is an array of valid dates.\n *\n * @private\n * @param value - The value to check.\n * @param dateLib - The date utility library instance.\n * @returns `true` if the value is an array of valid dates, otherwise `false`.\n */\nexport function isDatesArray(value, dateLib) {\n return Array.isArray(value) && value.every(dateLib.isDate);\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\nimport { rangeIncludesDate } from \"./rangeIncludesDate.js\";\nimport { isDateAfterType, isDateBeforeType, isDateInterval, isDateRange, isDatesArray, isDayOfWeekType, } from \"./typeguards.js\";\n/**\n * Checks if a given date matches at least one of the specified {@link Matcher}.\n *\n * @param date - The date to check.\n * @param matchers - The matchers to check against.\n * @param dateLib - The date utility library instance.\n * @returns `true` if the date matches any of the matchers, otherwise `false`.\n * @group Utilities\n */\nexport function dateMatchModifiers(date, matchers, dateLib = defaultDateLib) {\n const matchersArr = !Array.isArray(matchers) ? [matchers] : matchers;\n const { isSameDay, differenceInCalendarDays, isAfter } = dateLib;\n return matchersArr.some((matcher) => {\n if (typeof matcher === \"boolean\") {\n return matcher;\n }\n if (dateLib.isDate(matcher)) {\n return isSameDay(date, matcher);\n }\n if (isDatesArray(matcher, dateLib)) {\n return matcher.some((matcherDate) => isSameDay(date, matcherDate));\n }\n if (isDateRange(matcher)) {\n return rangeIncludesDate(matcher, date, false, dateLib);\n }\n if (isDayOfWeekType(matcher)) {\n if (!Array.isArray(matcher.dayOfWeek)) {\n return matcher.dayOfWeek === date.getDay();\n }\n return matcher.dayOfWeek.includes(date.getDay());\n }\n if (isDateInterval(matcher)) {\n const diffBefore = differenceInCalendarDays(matcher.before, date);\n const diffAfter = differenceInCalendarDays(matcher.after, date);\n const isDayBefore = diffBefore > 0;\n const isDayAfter = diffAfter < 0;\n const isClosedInterval = isAfter(matcher.before, matcher.after);\n if (isClosedInterval) {\n return isDayAfter && isDayBefore;\n }\n else {\n return isDayBefore || isDayAfter;\n }\n }\n if (isDateAfterType(matcher)) {\n return differenceInCalendarDays(date, matcher.after) > 0;\n }\n if (isDateBeforeType(matcher)) {\n return differenceInCalendarDays(matcher.before, date) > 0;\n }\n if (typeof matcher === \"function\") {\n return matcher(date);\n }\n return false;\n });\n}\n/**\n * @private\n * @deprecated Use {@link dateMatchModifiers} instead.\n */\nexport const isMatch = dateMatchModifiers;\n","import { DayFlag } from \"../UI.js\";\nimport { dateMatchModifiers } from \"../utils/dateMatchModifiers.js\";\n/**\n * Creates a function to retrieve the modifiers for a given day.\n *\n * This function calculates both internal and custom modifiers for each day\n * based on the provided calendar days and DayPicker props.\n *\n * @private\n * @param days The array of `CalendarDay` objects to process.\n * @param props The DayPicker props, including modifiers and configuration\n * options.\n * @param dateLib The date library to use for date manipulation.\n * @returns A function that retrieves the modifiers for a given `CalendarDay`.\n */\nexport function createGetModifiers(days, props, navStart, navEnd, dateLib) {\n const { disabled, hidden, modifiers, showOutsideDays, broadcastCalendar, today = dateLib.today(), } = props;\n const { isSameDay, isSameMonth, startOfMonth, isBefore, endOfMonth, isAfter, } = dateLib;\n const computedNavStart = navStart && startOfMonth(navStart);\n const computedNavEnd = navEnd && endOfMonth(navEnd);\n const internalModifiersMap = {\n [DayFlag.focused]: [],\n [DayFlag.outside]: [],\n [DayFlag.disabled]: [],\n [DayFlag.hidden]: [],\n [DayFlag.today]: [],\n };\n const customModifiersMap = {};\n for (const day of days) {\n const { date, displayMonth } = day;\n const isOutside = Boolean(displayMonth && !isSameMonth(date, displayMonth));\n const isBeforeNavStart = Boolean(computedNavStart && isBefore(date, computedNavStart));\n const isAfterNavEnd = Boolean(computedNavEnd && isAfter(date, computedNavEnd));\n const isDisabled = Boolean(disabled && dateMatchModifiers(date, disabled, dateLib));\n const isHidden = Boolean(hidden && dateMatchModifiers(date, hidden, dateLib)) ||\n isBeforeNavStart ||\n isAfterNavEnd ||\n // Broadcast calendar will show outside days as default\n (!broadcastCalendar && !showOutsideDays && isOutside) ||\n (broadcastCalendar && showOutsideDays === false && isOutside);\n const isToday = isSameDay(date, today);\n if (isOutside)\n internalModifiersMap.outside.push(day);\n if (isDisabled)\n internalModifiersMap.disabled.push(day);\n if (isHidden)\n internalModifiersMap.hidden.push(day);\n if (isToday)\n internalModifiersMap.today.push(day);\n // Add custom modifiers\n if (modifiers) {\n Object.keys(modifiers).forEach((name) => {\n const modifierValue = modifiers?.[name];\n const isMatch = modifierValue\n ? dateMatchModifiers(date, modifierValue, dateLib)\n : false;\n if (!isMatch)\n return;\n if (customModifiersMap[name]) {\n customModifiersMap[name].push(day);\n }\n else {\n customModifiersMap[name] = [day];\n }\n });\n }\n }\n return (day) => {\n // Initialize all the modifiers to false\n const dayFlags = {\n [DayFlag.focused]: false,\n [DayFlag.disabled]: false,\n [DayFlag.hidden]: false,\n [DayFlag.outside]: false,\n [DayFlag.today]: false,\n };\n const customModifiers = {};\n // Find the modifiers for the given day\n for (const name in internalModifiersMap) {\n const days = internalModifiersMap[name];\n dayFlags[name] = days.some((d) => d === day);\n }\n for (const name in customModifiersMap) {\n customModifiers[name] = customModifiersMap[name].some((d) => d === day);\n }\n return {\n ...dayFlags,\n // custom modifiers should override all the previous ones\n ...customModifiers,\n };\n };\n}\n","import { DayFlag, SelectionState, UI } from \"../UI.js\";\n/**\n * Returns the class names for a day based on its modifiers.\n *\n * This function combines the base class name for the day with any class names\n * associated with active modifiers.\n *\n * @param modifiers The modifiers applied to the day.\n * @param classNames The base class names for the calendar elements.\n * @param modifiersClassNames The class names associated with specific\n * modifiers.\n * @returns An array of class names for the day.\n */\nexport function getClassNamesForModifiers(modifiers, classNames, modifiersClassNames = {}) {\n const modifierClassNames = Object.entries(modifiers)\n .filter(([, active]) => active === true)\n .reduce((previousValue, [key]) => {\n if (modifiersClassNames[key]) {\n previousValue.push(modifiersClassNames[key]);\n }\n else if (classNames[DayFlag[key]]) {\n previousValue.push(classNames[DayFlag[key]]);\n }\n else if (classNames[SelectionState[key]]) {\n previousValue.push(classNames[SelectionState[key]]);\n }\n return previousValue;\n }, [classNames[UI.Day]]);\n return modifierClassNames;\n}\n","import * as components from \"../components/custom-components.js\";\n/**\n * Merges custom components from the props with the default components.\n *\n * This function ensures that any custom components provided in the props\n * override the default components.\n *\n * @param customComponents The custom components provided in the DayPicker\n * props.\n * @returns An object containing the merged components.\n */\nexport function getComponents(customComponents) {\n return {\n ...components,\n ...customComponents,\n };\n}\n","/**\n * Extracts `data-` attributes from the DayPicker props.\n *\n * This function collects all `data-` attributes from the props and adds\n * additional attributes based on the DayPicker configuration.\n *\n * @param props The DayPicker props.\n * @returns An object containing the `data-` attributes.\n */\nexport function getDataAttributes(props) {\n const dataAttributes = {\n \"data-mode\": props.mode ?? undefined,\n \"data-required\": \"required\" in props ? props.required : undefined,\n \"data-multiple-months\": (props.numberOfMonths && props.numberOfMonths > 1) || undefined,\n \"data-week-numbers\": props.showWeekNumber || undefined,\n \"data-broadcast-calendar\": props.broadcastCalendar || undefined,\n \"data-nav-layout\": props.navLayout || undefined,\n };\n Object.entries(props).forEach(([key, val]) => {\n if (key.startsWith(\"data-\")) {\n dataAttributes[key] = val;\n }\n });\n return dataAttributes;\n}\n","import { Animation, DayFlag, SelectionState, UI } from \"../UI.js\";\n/**\n * Returns the default class names for the UI elements.\n *\n * This function generates a mapping of default class names for various UI\n * elements, day flags, selection states, and animations.\n *\n * @returns An object containing the default class names.\n * @group Utilities\n */\nexport function getDefaultClassNames() {\n const classNames = {};\n for (const key in UI) {\n classNames[UI[key]] =\n `rdp-${UI[key]}`;\n }\n for (const key in DayFlag) {\n classNames[DayFlag[key]] =\n `rdp-${DayFlag[key]}`;\n }\n for (const key in SelectionState) {\n classNames[SelectionState[key]] =\n `rdp-${SelectionState[key]}`;\n }\n for (const key in Animation) {\n classNames[Animation[key]] =\n `rdp-${Animation[key]}`;\n }\n return classNames;\n}\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Formats the caption of the month.\n *\n * @defaultValue Locale-specific month/year order (e.g., \"November 2022\").\n * @param month The date representing the month.\n * @param options Configuration options for the date library.\n * @param dateLib The date library to use for formatting. If not provided, a new\n * instance is created.\n * @returns The formatted caption as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatCaption(month, options, dateLib) {\n const lib = dateLib ?? new DateLib(options);\n return lib.formatMonthYear(month);\n}\n/**\n * @private\n * @deprecated Use {@link formatCaption} instead.\n * @group Formatters\n */\nexport const formatMonthCaption = formatCaption;\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Formats the day date shown in the day cell.\n *\n * @defaultValue `d` (e.g., \"1\").\n * @param date The date to format.\n * @param options Configuration options for the date library.\n * @param dateLib The date library to use for formatting. If not provided, a new\n * instance is created.\n * @returns The formatted day as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatDay(date, options, dateLib) {\n return (dateLib ?? new DateLib(options)).format(date, \"d\");\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\n/**\n * Formats the month for the dropdown option label.\n *\n * @defaultValue The localized full month name.\n * @param month The date representing the month.\n * @param dateLib The date library to use for formatting. Defaults to\n * `defaultDateLib`.\n * @returns The formatted month name as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatMonthDropdown(month, dateLib = defaultDateLib) {\n return dateLib.format(month, \"LLLL\");\n}\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Formats the name of a weekday to be displayed in the weekdays header.\n *\n * @defaultValue `cccccc` (e.g., \"Mo\" for Monday).\n * @param weekday The date representing the weekday.\n * @param options Configuration options for the date library.\n * @param dateLib The date library to use for formatting. If not provided, a new\n * instance is created.\n * @returns The formatted weekday name as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatWeekdayName(weekday, options, dateLib) {\n return (dateLib ?? new DateLib(options)).format(weekday, \"cccccc\");\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\n/**\n * Formats the week number.\n *\n * @defaultValue The week number as a string, with a leading zero for single-digit numbers.\n * @param weekNumber The week number to format.\n * @param dateLib The date library to use for formatting. Defaults to\n * `defaultDateLib`.\n * @returns The formatted week number as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatWeekNumber(weekNumber, dateLib = defaultDateLib) {\n if (weekNumber < 10) {\n return dateLib.formatNumber(`0${weekNumber.toLocaleString()}`);\n }\n return dateLib.formatNumber(`${weekNumber.toLocaleString()}`);\n}\n","/**\n * Formats the header for the week number column.\n *\n * @defaultValue An empty string `\"\"`.\n * @returns The formatted week number header as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatWeekNumberHeader() {\n return ``;\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\n/**\n * Formats the year for the dropdown option label.\n *\n * @param year The year to format.\n * @param dateLib The date library to use for formatting. Defaults to\n * `defaultDateLib`.\n * @returns The formatted year as a string.\n * @group Formatters\n * @see https://daypicker.dev/docs/translation#custom-formatters\n */\nexport function formatYearDropdown(year, dateLib = defaultDateLib) {\n return dateLib.format(year, \"yyyy\");\n}\n/**\n * @private\n * @deprecated Use `formatYearDropdown` instead.\n * @group Formatters\n */\nexport const formatYearCaption = formatYearDropdown;\n","import * as defaultFormatters from \"../formatters/index.js\";\n/**\n * Merges custom formatters from the props with the default formatters.\n *\n * @param customFormatters The custom formatters provided in the DayPicker\n * props.\n * @returns The merged formatters object.\n */\nexport function getFormatters(customFormatters) {\n if (customFormatters?.formatMonthCaption && !customFormatters.formatCaption) {\n customFormatters.formatCaption = customFormatters.formatMonthCaption;\n }\n if (customFormatters?.formatYearCaption &&\n !customFormatters.formatYearDropdown) {\n customFormatters.formatYearDropdown = customFormatters.formatYearCaption;\n }\n return {\n ...defaultFormatters,\n ...customFormatters,\n };\n}\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Generates the ARIA label for a day button.\n *\n * Use the `modifiers` argument to provide additional context for the label,\n * such as indicating if the day is \"today\" or \"selected.\"\n *\n * @defaultValue The formatted date.\n * @param date - The date to format.\n * @param modifiers - The modifiers providing context for the day.\n * @param options - Optional configuration for the date formatting library.\n * @param dateLib - An optional instance of the date formatting library.\n * @returns The ARIA label for the day button.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelDayButton(date, modifiers, options, dateLib) {\n let label = (dateLib ?? new DateLib(options)).format(date, \"PPPP\");\n if (modifiers.today)\n label = `Today, ${label}`;\n if (modifiers.selected)\n label = `${label}, selected`;\n return label;\n}\n/**\n * @ignore\n * @deprecated Use `labelDayButton` instead.\n */\nexport const labelDay = labelDayButton;\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Generates the ARIA label for the month grid, which is announced when entering\n * the grid.\n *\n * @defaultValue Locale-specific month/year order (e.g., \"November 2022\").\n * @param date - The date representing the month.\n * @param options - Optional configuration for the date formatting library.\n * @param dateLib - An optional instance of the date formatting library.\n * @returns The ARIA label for the month grid.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelGrid(date, options, dateLib) {\n const lib = dateLib ?? new DateLib(options);\n return lib.formatMonthYear(date);\n}\n/**\n * @ignore\n * @deprecated Use {@link labelGrid} instead.\n */\nexport const labelCaption = labelGrid;\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Generates the label for a day grid cell when the calendar is not interactive.\n *\n * @param date - The date to format.\n * @param modifiers - Optional modifiers providing context for the day.\n * @param options - Optional configuration for the date formatting library.\n * @param dateLib - An optional instance of the date formatting library.\n * @returns The label for the day grid cell.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelGridcell(date, modifiers, options, dateLib) {\n let label = (dateLib ?? new DateLib(options)).format(date, \"PPPP\");\n if (modifiers?.today) {\n label = `Today, ${label}`;\n }\n return label;\n}\n","/**\n * Generates the ARIA label for the months dropdown.\n *\n * @defaultValue `\"Choose the Month\"`\n * @param options - Optional configuration for the date formatting library.\n * @returns The ARIA label for the months dropdown.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelMonthDropdown(_options) {\n return \"Choose the Month\";\n}\n","/**\n * Generates the ARIA label for the navigation toolbar.\n *\n * @defaultValue `\"\"`\n * @returns The ARIA label for the navigation toolbar.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelNav() {\n return \"\";\n}\n","const defaultLabel = \"Go to the Next Month\";\n/**\n * Generates the ARIA label for the \"next month\" button.\n *\n * @defaultValue `\"Go to the Next Month\"`\n * @param month - The date representing the next month, or `undefined` if there\n * is no next month.\n * @returns The ARIA label for the \"next month\" button.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelNext(_month, _options) {\n return defaultLabel;\n}\n","/**\n * Generates the ARIA label for the \"previous month\" button.\n *\n * @defaultValue `\"Go to the Previous Month\"`\n * @param month - The date representing the previous month, or `undefined` if\n * there is no previous month.\n * @returns The ARIA label for the \"previous month\" button.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelPrevious(_month) {\n return \"Go to the Previous Month\";\n}\n","import { DateLib } from \"../classes/DateLib.js\";\n/**\n * Generates the ARIA label for a weekday column header.\n *\n * @defaultValue `\"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\", \"Sunday\"`\n * @param date - The date representing the weekday.\n * @param options - Optional configuration for the date formatting library.\n * @param dateLib - An optional instance of the date formatting library.\n * @returns The ARIA label for the weekday column header.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelWeekday(date, options, dateLib) {\n return (dateLib ?? new DateLib(options)).format(date, \"cccc\");\n}\n","/**\n * Generates the ARIA label for the week number cell (the first cell in a row).\n *\n * @defaultValue `Week ${weekNumber}`\n * @param weekNumber - The number of the week.\n * @param options - Optional configuration for the date formatting library.\n * @returns The ARIA label for the week number cell.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelWeekNumber(weekNumber, _options) {\n return `Week ${weekNumber}`;\n}\n","/**\n * Generates the ARIA label for the week number header element.\n *\n * @defaultValue `\"Week Number\"`\n * @param options - Optional configuration for the date formatting library.\n * @returns The ARIA label for the week number header.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelWeekNumberHeader(_options) {\n return \"Week Number\";\n}\n","/**\n * Generates the ARIA label for the years dropdown.\n *\n * @defaultValue `\"Choose the Year\"`\n * @param options - Optional configuration for the date formatting library.\n * @returns The ARIA label for the years dropdown.\n * @group Labels\n * @see https://daypicker.dev/docs/translation#aria-labels\n */\nexport function labelYearDropdown(_options) {\n return \"Choose the Year\";\n}\n","import * as defaultLabels from \"../labels/index.js\";\nconst resolveLabel = (defaultLabel, customLabel, localeLabel) => {\n if (customLabel)\n return customLabel;\n if (localeLabel) {\n return (typeof localeLabel === \"function\"\n ? localeLabel\n : (..._args) => localeLabel);\n }\n return defaultLabel;\n};\n/**\n * Merges custom labels from the props with the default labels.\n *\n * When available, uses the locale-provided translation for `labelNext`.\n *\n * @param customLabels The custom labels provided in the DayPicker props.\n * @param options Options from the date library, used to resolve locale\n * translations.\n * @returns The merged labels object with locale-aware defaults.\n */\nexport function getLabels(customLabels, options) {\n const localeLabels = options.locale?.labels ?? {};\n return {\n ...defaultLabels,\n ...(customLabels ?? {}),\n labelDayButton: resolveLabel(defaultLabels.labelDayButton, customLabels?.labelDayButton, localeLabels.labelDayButton),\n labelMonthDropdown: resolveLabel(defaultLabels.labelMonthDropdown, customLabels?.labelMonthDropdown, localeLabels.labelMonthDropdown),\n labelNext: resolveLabel(defaultLabels.labelNext, customLabels?.labelNext, localeLabels.labelNext),\n labelPrevious: resolveLabel(defaultLabels.labelPrevious, customLabels?.labelPrevious, localeLabels.labelPrevious),\n labelWeekNumber: resolveLabel(defaultLabels.labelWeekNumber, customLabels?.labelWeekNumber, localeLabels.labelWeekNumber),\n labelYearDropdown: resolveLabel(defaultLabels.labelYearDropdown, customLabels?.labelYearDropdown, localeLabels.labelYearDropdown),\n labelGrid: resolveLabel(defaultLabels.labelGrid, customLabels?.labelGrid, localeLabels.labelGrid),\n labelGridcell: resolveLabel(defaultLabels.labelGridcell, customLabels?.labelGridcell, localeLabels.labelGridcell),\n labelNav: resolveLabel(defaultLabels.labelNav, customLabels?.labelNav, localeLabels.labelNav),\n labelWeekNumberHeader: resolveLabel(defaultLabels.labelWeekNumberHeader, customLabels?.labelWeekNumberHeader, localeLabels.labelWeekNumberHeader),\n labelWeekday: resolveLabel(defaultLabels.labelWeekday, customLabels?.labelWeekday, localeLabels.labelWeekday),\n };\n}\n","/**\n * Returns the months to show in the dropdown.\n *\n * This function generates a list of months for the current year, formatted\n * using the provided formatter, and determines whether each month should be\n * disabled based on the navigation range.\n *\n * @param displayMonth The currently displayed month.\n * @param navStart The start date for navigation.\n * @param navEnd The end date for navigation.\n * @param formatters The formatters to use for formatting the month labels.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of dropdown options representing the months, or `undefined`\n * if no months are available.\n */\nexport function getMonthOptions(displayMonth, navStart, navEnd, formatters, dateLib) {\n const { startOfMonth, startOfYear, endOfYear, eachMonthOfInterval, getMonth, } = dateLib;\n const months = eachMonthOfInterval({\n start: startOfYear(displayMonth),\n end: endOfYear(displayMonth),\n });\n const options = months.map((month) => {\n const label = formatters.formatMonthDropdown(month, dateLib);\n const value = getMonth(month);\n const disabled = (navStart && month < startOfMonth(navStart)) ||\n (navEnd && month > startOfMonth(navEnd)) ||\n false;\n return { value, label, disabled };\n });\n return options;\n}\n","import { UI } from \"../UI.js\";\n/**\n * Returns the computed style for a day based on its modifiers.\n *\n * This function merges the base styles for the day with any styles associated\n * with active modifiers.\n *\n * @param dayModifiers The modifiers applied to the day.\n * @param styles The base styles for the calendar elements.\n * @param modifiersStyles The styles associated with specific modifiers.\n * @returns The computed style for the day.\n */\nexport function getStyleForModifiers(dayModifiers, styles = {}, modifiersStyles = {}) {\n let style = { ...styles?.[UI.Day] };\n Object.entries(dayModifiers)\n .filter(([, active]) => active === true)\n .forEach(([modifier]) => {\n style = {\n ...style,\n ...modifiersStyles?.[modifier],\n };\n });\n return style;\n}\n","/**\n * Generates a series of 7 days, starting from the beginning of the week, to use\n * for formatting weekday names (e.g., Monday, Tuesday, etc.).\n *\n * @param dateLib The date library to use for date manipulation.\n * @param ISOWeek Whether to use ISO week numbering (weeks start on Monday).\n * @param broadcastCalendar Whether to use the broadcast calendar (weeks start\n * on Monday, but may include adjustments for broadcast-specific rules).\n * @returns An array of 7 dates representing the weekdays.\n */\nexport function getWeekdays(dateLib, ISOWeek, broadcastCalendar, today) {\n const referenceToday = today ?? dateLib.today();\n const start = broadcastCalendar\n ? dateLib.startOfBroadcastWeek(referenceToday, dateLib)\n : ISOWeek\n ? dateLib.startOfISOWeek(referenceToday)\n : dateLib.startOfWeek(referenceToday);\n const days = [];\n for (let i = 0; i < 7; i++) {\n const day = dateLib.addDays(start, i);\n days.push(day);\n }\n return days;\n}\n","/**\n * Returns the years to display in the dropdown.\n *\n * This function generates a list of years between the navigation start and end\n * dates, formatted using the provided formatter.\n *\n * @param navStart The start date for navigation.\n * @param navEnd The end date for navigation.\n * @param formatters The formatters to use for formatting the year labels.\n * @param dateLib The date library to use for date manipulation.\n * @param reverse If true, reverses the order of the years (descending).\n * @returns An array of dropdown options representing the years, or `undefined`\n * if `navStart` or `navEnd` is not provided.\n */\nexport function getYearOptions(navStart, navEnd, formatters, dateLib, reverse = false) {\n if (!navStart)\n return undefined;\n if (!navEnd)\n return undefined;\n const { startOfYear, endOfYear, eachYearOfInterval, getYear } = dateLib;\n const firstNavYear = startOfYear(navStart);\n const lastNavYear = endOfYear(navEnd);\n const years = eachYearOfInterval({ start: firstNavYear, end: lastNavYear });\n if (reverse)\n years.reverse();\n return years.map((year) => {\n const label = formatters.formatYearDropdown(year, dateLib);\n return {\n value: getYear(year),\n label,\n disabled: false,\n };\n });\n}\n","import { TZDate } from \"@date-fns/tz\";\nimport { differenceInCalendarDays as differenceInCalendarDaysFn, differenceInCalendarMonths as differenceInCalendarMonthsFn, getISOWeek as getISOWeekFn, getWeek as getWeekFn, } from \"date-fns\";\n/**\n * Creates `dateLib` overrides that keep all calendar math at noon in the target\n * time zone. This avoids second-level offset changes (e.g., historical zones\n * with +03:41:12) from pushing dates backward across midnight.\n */\nexport function createNoonOverrides(timeZone, options = {}) {\n const { weekStartsOn, locale } = options;\n const fallbackWeekStartsOn = (weekStartsOn ??\n locale?.options?.weekStartsOn ??\n 0);\n // Keep all internal math anchored at noon in the target zone to avoid\n // historical second-level offsets from crossing midnight.\n const toNoonTZDate = (date) => {\n const normalizedDate = typeof date === \"number\" || typeof date === \"string\"\n ? new Date(date)\n : date;\n return new TZDate(normalizedDate.getFullYear(), normalizedDate.getMonth(), normalizedDate.getDate(), 12, 0, 0, timeZone);\n };\n // Convert a value into a host `Date` that represents the same calendar day\n // as the target-zone noon. This is useful for helpers (e.g., date-fns week\n // utilities) that expect local `Date` instances rather than `TZDate`s.\n const toCalendarDate = (date) => {\n const zoned = toNoonTZDate(date);\n return new Date(zoned.getFullYear(), zoned.getMonth(), zoned.getDate(), 0, 0, 0, 0);\n };\n return {\n today: () => {\n return toNoonTZDate(TZDate.tz(timeZone));\n },\n newDate: (year, monthIndex, date) => {\n return new TZDate(year, monthIndex, date, 12, 0, 0, timeZone);\n },\n startOfDay: (date) => {\n return toNoonTZDate(date);\n },\n startOfWeek: (date, options) => {\n const base = toNoonTZDate(date);\n const weekStartsOnValue = (options?.weekStartsOn ??\n fallbackWeekStartsOn);\n const diff = (base.getDay() - weekStartsOnValue + 7) % 7;\n base.setDate(base.getDate() - diff);\n return base;\n },\n startOfISOWeek: (date) => {\n const base = toNoonTZDate(date);\n const diff = (base.getDay() - 1 + 7) % 7;\n base.setDate(base.getDate() - diff);\n return base;\n },\n startOfMonth: (date) => {\n const base = toNoonTZDate(date);\n base.setDate(1);\n return base;\n },\n startOfYear: (date) => {\n const base = toNoonTZDate(date);\n base.setMonth(0, 1);\n return base;\n },\n endOfWeek: (date, options) => {\n const base = toNoonTZDate(date);\n const weekStartsOnValue = (options?.weekStartsOn ??\n fallbackWeekStartsOn);\n const endDow = (weekStartsOnValue + 6) % 7;\n const diff = (endDow - base.getDay() + 7) % 7;\n base.setDate(base.getDate() + diff);\n return base;\n },\n endOfISOWeek: (date) => {\n const base = toNoonTZDate(date);\n const diff = (7 - base.getDay()) % 7;\n base.setDate(base.getDate() + diff);\n return base;\n },\n endOfMonth: (date) => {\n const base = toNoonTZDate(date);\n base.setMonth(base.getMonth() + 1, 0);\n return base;\n },\n endOfYear: (date) => {\n const base = toNoonTZDate(date);\n base.setMonth(11, 31);\n return base;\n },\n eachMonthOfInterval: (interval) => {\n const start = toNoonTZDate(interval.start);\n const end = toNoonTZDate(interval.end);\n const result = [];\n const cursor = new TZDate(start.getFullYear(), start.getMonth(), 1, 12, 0, 0, timeZone);\n const endKey = end.getFullYear() * 12 + end.getMonth();\n while (cursor.getFullYear() * 12 + cursor.getMonth() <= endKey) {\n result.push(new TZDate(cursor, timeZone));\n cursor.setMonth(cursor.getMonth() + 1, 1);\n }\n return result;\n },\n // Normalize to noon once before arithmetic (avoid DST/midnight edge cases),\n // mutate the same TZDate, and return it.\n addDays: (date, amount) => {\n const base = toNoonTZDate(date);\n base.setDate(base.getDate() + amount);\n return base;\n },\n addWeeks: (date, amount) => {\n const base = toNoonTZDate(date);\n base.setDate(base.getDate() + amount * 7);\n return base;\n },\n addMonths: (date, amount) => {\n const base = toNoonTZDate(date);\n base.setMonth(base.getMonth() + amount);\n return base;\n },\n addYears: (date, amount) => {\n const base = toNoonTZDate(date);\n base.setFullYear(base.getFullYear() + amount);\n return base;\n },\n eachYearOfInterval: (interval) => {\n const start = toNoonTZDate(interval.start);\n const end = toNoonTZDate(interval.end);\n const years = [];\n const cursor = new TZDate(start.getFullYear(), 0, 1, 12, 0, 0, timeZone);\n while (cursor.getFullYear() <= end.getFullYear()) {\n years.push(new TZDate(cursor, timeZone));\n cursor.setFullYear(cursor.getFullYear() + 1, 0, 1);\n }\n return years;\n },\n getWeek: (date, options) => {\n const base = toCalendarDate(date);\n return getWeekFn(base, {\n weekStartsOn: options?.weekStartsOn ?? fallbackWeekStartsOn,\n firstWeekContainsDate: options?.firstWeekContainsDate ??\n locale?.options?.firstWeekContainsDate ??\n 1,\n });\n },\n getISOWeek: (date) => {\n const base = toCalendarDate(date);\n return getISOWeekFn(base);\n },\n differenceInCalendarDays: (dateLeft, dateRight) => {\n const left = toCalendarDate(dateLeft);\n const right = toCalendarDate(dateRight);\n return differenceInCalendarDaysFn(left, right);\n },\n differenceInCalendarMonths: (dateLeft, dateRight) => {\n const left = toCalendarDate(dateLeft);\n const right = toCalendarDate(dateRight);\n return differenceInCalendarMonthsFn(left, right);\n },\n };\n}\n","import { useLayoutEffect, useRef } from \"react\";\nimport { Animation } from \"./UI.js\";\nconst asHtmlElement = (element) => {\n if (element instanceof HTMLElement)\n return element;\n return null;\n};\nconst queryMonthEls = (element) => [\n ...(element.querySelectorAll(\"[data-animated-month]\") ?? []),\n];\nconst queryMonthEl = (element) => asHtmlElement(element.querySelector(\"[data-animated-month]\"));\nconst queryCaptionEl = (element) => asHtmlElement(element.querySelector(\"[data-animated-caption]\"));\nconst queryWeeksEl = (element) => asHtmlElement(element.querySelector(\"[data-animated-weeks]\"));\nconst queryNavEl = (element) => asHtmlElement(element.querySelector(\"[data-animated-nav]\"));\nconst queryWeekdaysEl = (element) => asHtmlElement(element.querySelector(\"[data-animated-weekdays]\"));\n/**\n * Handles animations for transitioning between months in the DayPicker\n * component.\n *\n * @private\n * @param rootElRef - A reference to the root element of the DayPicker\n * component.\n * @param enabled - Whether animations are enabled.\n * @param options - Configuration options for the animation, including class\n * names, months, focused day, and the date utility library.\n */\nexport function useAnimation(rootElRef, enabled, { classNames, months, focused, dateLib, }) {\n const previousRootElSnapshotRef = useRef(null);\n const previousMonthsRef = useRef(months);\n const animatingRef = useRef(false);\n useLayoutEffect(() => {\n // get previous months before updating the previous months ref\n const previousMonths = previousMonthsRef.current;\n // update previous months ref for next effect trigger\n previousMonthsRef.current = months;\n if (!enabled ||\n !rootElRef.current ||\n // safety check because the ref can be set to anything by consumers\n !(rootElRef.current instanceof HTMLElement) ||\n // validation required for the animation to work as expected\n months.length === 0 ||\n previousMonths.length === 0 ||\n months.length !== previousMonths.length) {\n return;\n }\n const isSameMonth = dateLib.isSameMonth(months[0].date, previousMonths[0].date);\n const isAfterPreviousMonth = dateLib.isAfter(months[0].date, previousMonths[0].date);\n const captionAnimationClass = isAfterPreviousMonth\n ? classNames[Animation.caption_after_enter]\n : classNames[Animation.caption_before_enter];\n const weeksAnimationClass = isAfterPreviousMonth\n ? classNames[Animation.weeks_after_enter]\n : classNames[Animation.weeks_before_enter];\n // get previous root element snapshot before updating the snapshot ref\n const previousRootElSnapshot = previousRootElSnapshotRef.current;\n // update snapshot for next effect trigger\n const rootElSnapshot = rootElRef.current.cloneNode(true);\n if (rootElSnapshot instanceof HTMLElement) {\n // if this effect is triggered while animating, we need to clean up the new root snapshot\n // to put it in the same state as when not animating, to correctly animate the next month change\n const currentMonthElsSnapshot = queryMonthEls(rootElSnapshot);\n currentMonthElsSnapshot.forEach((currentMonthElSnapshot) => {\n if (!(currentMonthElSnapshot instanceof HTMLElement))\n return;\n // remove the old month snapshots from the new root snapshot\n const previousMonthElSnapshot = queryMonthEl(currentMonthElSnapshot);\n if (previousMonthElSnapshot &&\n currentMonthElSnapshot.contains(previousMonthElSnapshot)) {\n currentMonthElSnapshot.removeChild(previousMonthElSnapshot);\n }\n // remove animation classes from the new month snapshots\n const captionEl = queryCaptionEl(currentMonthElSnapshot);\n if (captionEl) {\n captionEl.classList.remove(captionAnimationClass);\n }\n const weeksEl = queryWeeksEl(currentMonthElSnapshot);\n if (weeksEl) {\n weeksEl.classList.remove(weeksAnimationClass);\n }\n });\n previousRootElSnapshotRef.current = rootElSnapshot;\n }\n else {\n previousRootElSnapshotRef.current = null;\n }\n if (animatingRef.current ||\n isSameMonth ||\n // skip animation if a day is focused because it can cause issues to the animation and is better for a11y\n focused) {\n return;\n }\n const previousMonthEls = previousRootElSnapshot instanceof HTMLElement\n ? queryMonthEls(previousRootElSnapshot)\n : [];\n const currentMonthEls = queryMonthEls(rootElRef.current);\n if (currentMonthEls?.every((el) => el instanceof HTMLElement) &&\n previousMonthEls &&\n previousMonthEls.every((el) => el instanceof HTMLElement)) {\n animatingRef.current = true;\n const cleanUpFunctions = [];\n // set isolation to isolate to isolate the stacking context during animation\n rootElRef.current.style.isolation = \"isolate\";\n // set z-index to 1 to ensure the nav is clickable over the other elements being animated\n const navEl = queryNavEl(rootElRef.current);\n if (navEl) {\n navEl.style.zIndex = \"1\";\n }\n currentMonthEls.forEach((currentMonthEl, index) => {\n const previousMonthEl = previousMonthEls[index];\n if (!previousMonthEl) {\n return;\n }\n // animate new displayed month\n currentMonthEl.style.position = \"relative\";\n currentMonthEl.style.overflow = \"hidden\";\n const captionEl = queryCaptionEl(currentMonthEl);\n if (captionEl) {\n captionEl.classList.add(captionAnimationClass);\n }\n const weeksEl = queryWeeksEl(currentMonthEl);\n if (weeksEl) {\n weeksEl.classList.add(weeksAnimationClass);\n }\n // animate new displayed month end\n const cleanUp = () => {\n animatingRef.current = false;\n if (rootElRef.current) {\n rootElRef.current.style.isolation = \"\";\n }\n if (navEl) {\n navEl.style.zIndex = \"\";\n }\n if (captionEl) {\n captionEl.classList.remove(captionAnimationClass);\n }\n if (weeksEl) {\n weeksEl.classList.remove(weeksAnimationClass);\n }\n currentMonthEl.style.position = \"\";\n currentMonthEl.style.overflow = \"\";\n if (currentMonthEl.contains(previousMonthEl)) {\n currentMonthEl.removeChild(previousMonthEl);\n }\n };\n cleanUpFunctions.push(cleanUp);\n // animate old displayed month\n previousMonthEl.style.pointerEvents = \"none\";\n previousMonthEl.style.position = \"absolute\";\n previousMonthEl.style.overflow = \"hidden\";\n previousMonthEl.setAttribute(\"aria-hidden\", \"true\");\n // hide the weekdays container of the old month and only the new one\n const previousWeekdaysEl = queryWeekdaysEl(previousMonthEl);\n if (previousWeekdaysEl) {\n previousWeekdaysEl.style.opacity = \"0\";\n }\n const previousCaptionEl = queryCaptionEl(previousMonthEl);\n if (previousCaptionEl) {\n previousCaptionEl.classList.add(isAfterPreviousMonth\n ? classNames[Animation.caption_before_exit]\n : classNames[Animation.caption_after_exit]);\n previousCaptionEl.addEventListener(\"animationend\", cleanUp);\n }\n const previousWeeksEl = queryWeeksEl(previousMonthEl);\n if (previousWeeksEl) {\n previousWeeksEl.classList.add(isAfterPreviousMonth\n ? classNames[Animation.weeks_before_exit]\n : classNames[Animation.weeks_after_exit]);\n }\n currentMonthEl.insertBefore(previousMonthEl, currentMonthEl.firstChild);\n });\n }\n });\n}\n","/**\n * Returns all the dates to display in the calendar.\n *\n * This function calculates the range of dates to display based on the provided\n * display months, constraints, and calendar configuration.\n *\n * @param displayMonths The months to display in the calendar.\n * @param maxDate The maximum date to include in the range.\n * @param props The DayPicker props, including calendar configuration options.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of dates to display in the calendar.\n */\nexport function getDates(displayMonths, maxDate, props, dateLib) {\n const firstMonth = displayMonths[0];\n const lastMonth = displayMonths[displayMonths.length - 1];\n const { ISOWeek, fixedWeeks, broadcastCalendar } = props ?? {};\n const { addDays, differenceInCalendarDays, differenceInCalendarMonths, endOfBroadcastWeek, endOfISOWeek, endOfMonth, endOfWeek, isAfter, startOfBroadcastWeek, startOfISOWeek, startOfWeek, } = dateLib;\n const startWeekFirstDate = broadcastCalendar\n ? startOfBroadcastWeek(firstMonth, dateLib)\n : ISOWeek\n ? startOfISOWeek(firstMonth)\n : startOfWeek(firstMonth);\n const displayMonthsWeekEnd = broadcastCalendar\n ? endOfBroadcastWeek(lastMonth)\n : ISOWeek\n ? endOfISOWeek(endOfMonth(lastMonth))\n : endOfWeek(endOfMonth(lastMonth));\n // If maxDate is set, clamp the grid to the end of that week.\n const constraintWeekEnd = maxDate &&\n (broadcastCalendar\n ? endOfBroadcastWeek(maxDate)\n : ISOWeek\n ? endOfISOWeek(maxDate)\n : endOfWeek(maxDate));\n // Pick the earliest week end between the displayed months and the constraint.\n const gridEndDate = constraintWeekEnd && isAfter(displayMonthsWeekEnd, constraintWeekEnd)\n ? constraintWeekEnd\n : displayMonthsWeekEnd;\n const nOfDays = differenceInCalendarDays(gridEndDate, startWeekFirstDate);\n const nOfMonths = differenceInCalendarMonths(lastMonth, firstMonth) + 1;\n const dates = [];\n for (let i = 0; i <= nOfDays; i++) {\n const date = addDays(startWeekFirstDate, i);\n dates.push(date);\n }\n // If fixed weeks is enabled, add the extra dates to the array\n const nrOfDaysWithFixedWeeks = broadcastCalendar ? 35 : 42;\n const extraDates = nrOfDaysWithFixedWeeks * nOfMonths;\n if (fixedWeeks && dates.length < extraDates) {\n const daysToAdd = extraDates - dates.length;\n for (let i = 0; i < daysToAdd; i++) {\n const date = addDays(dates[dates.length - 1], 1);\n dates.push(date);\n }\n }\n return dates;\n}\n","/**\n * Returns all the days belonging to the calendar by merging the days in the\n * weeks for each month.\n *\n * @param calendarMonths The array of calendar months.\n * @returns An array of `CalendarDay` objects representing all the days in the\n * calendar.\n */\nexport function getDays(calendarMonths) {\n const initialDays = [];\n return calendarMonths.reduce((days, month) => {\n const weekDays = month.weeks.reduce((weekDays, week) => {\n return weekDays.concat(week.days.slice());\n }, initialDays.slice());\n return days.concat(weekDays.slice());\n }, initialDays.slice());\n}\n","/**\n * Returns the months to display in the calendar.\n *\n * @param firstDisplayedMonth The first month currently displayed in the\n * calendar.\n * @param calendarEndMonth The latest month the user can navigate to.\n * @param props The DayPicker props, including `numberOfMonths`.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of dates representing the months to display.\n */\nexport function getDisplayMonths(firstDisplayedMonth, calendarEndMonth, props, dateLib) {\n const { numberOfMonths = 1 } = props;\n const months = [];\n for (let i = 0; i < numberOfMonths; i++) {\n const month = dateLib.addMonths(firstDisplayedMonth, i);\n if (calendarEndMonth && month > calendarEndMonth) {\n break;\n }\n months.push(month);\n }\n return months;\n}\n","/**\n * Determines the initial month to display in the calendar based on the provided\n * props.\n *\n * This function calculates the starting month, considering constraints such as\n * `startMonth`, `endMonth`, and the number of months to display.\n *\n * @param props The DayPicker props, including navigation and date constraints.\n * @param dateLib The date library to use for date manipulation.\n * @returns The initial month to display.\n */\nexport function getInitialMonth(props, navStart, navEnd, dateLib) {\n const { month, defaultMonth, today = dateLib.today(), numberOfMonths = 1, } = props;\n let initialMonth = month || defaultMonth || today;\n const { differenceInCalendarMonths, addMonths, startOfMonth } = dateLib;\n if (navEnd &&\n differenceInCalendarMonths(navEnd, initialMonth) < numberOfMonths - 1) {\n const offset = -1 * (numberOfMonths - 1);\n initialMonth = addMonths(navEnd, offset);\n }\n if (navStart && differenceInCalendarMonths(initialMonth, navStart) < 0) {\n initialMonth = navStart;\n }\n return startOfMonth(initialMonth);\n}\n","import { CalendarDay, CalendarMonth, CalendarWeek } from \"../classes/index.js\";\n/**\n * Returns the months to display in the calendar.\n *\n * This function generates `CalendarMonth` objects for each month to be\n * displayed, including their weeks and days, based on the provided display\n * months and dates.\n *\n * @param displayMonths The months (as dates) to display in the calendar.\n * @param dates The dates to display in the calendar.\n * @param props Options from the DayPicker props context.\n * @param dateLib The date library to use for date manipulation.\n * @returns An array of `CalendarMonth` objects representing the months to\n * display.\n */\nexport function getMonths(displayMonths, dates, props, dateLib) {\n const { addDays, endOfBroadcastWeek, endOfISOWeek, endOfMonth, endOfWeek, getISOWeek, getWeek, startOfBroadcastWeek, startOfISOWeek, startOfWeek, } = dateLib;\n const dayPickerMonths = displayMonths.reduce((months, month) => {\n const firstDateOfFirstWeek = props.broadcastCalendar\n ? startOfBroadcastWeek(month, dateLib)\n : props.ISOWeek\n ? startOfISOWeek(month)\n : startOfWeek(month);\n const lastDateOfLastWeek = props.broadcastCalendar\n ? endOfBroadcastWeek(month)\n : props.ISOWeek\n ? endOfISOWeek(endOfMonth(month))\n : endOfWeek(endOfMonth(month));\n /** The dates to display in the month. */\n const monthDates = dates.filter((date) => {\n return date >= firstDateOfFirstWeek && date <= lastDateOfLastWeek;\n });\n const nrOfDaysWithFixedWeeks = props.broadcastCalendar ? 35 : 42;\n if (props.fixedWeeks && monthDates.length < nrOfDaysWithFixedWeeks) {\n const extraDates = dates.filter((date) => {\n const daysToAdd = nrOfDaysWithFixedWeeks - monthDates.length;\n return (date > lastDateOfLastWeek &&\n date <= addDays(lastDateOfLastWeek, daysToAdd));\n });\n monthDates.push(...extraDates);\n }\n const weeks = monthDates.reduce((weeks, date) => {\n const weekNumber = props.ISOWeek ? getISOWeek(date) : getWeek(date);\n const week = weeks.find((week) => week.weekNumber === weekNumber);\n const day = new CalendarDay(date, month, dateLib);\n if (!week) {\n weeks.push(new CalendarWeek(weekNumber, [day]));\n }\n else {\n week.days.push(day);\n }\n return weeks;\n }, []);\n const dayPickerMonth = new CalendarMonth(month, weeks);\n months.push(dayPickerMonth);\n return months;\n }, []);\n if (!props.reverseMonths) {\n return dayPickerMonths;\n }\n else {\n return dayPickerMonths.reverse();\n }\n}\n","/**\n * Returns the start and end months for calendar navigation.\n *\n * @param props The DayPicker props, including navigation and layout options.\n * @param dateLib The date library to use for date manipulation.\n * @returns A tuple containing the start and end months for navigation.\n */\nexport function getNavMonths(props, dateLib) {\n let { startMonth, endMonth } = props;\n const { startOfYear, startOfDay, startOfMonth, endOfMonth, addYears, endOfYear, newDate, today, } = dateLib;\n // Handle deprecated code\n const { fromYear, toYear, fromMonth, toMonth } = props;\n if (!startMonth && fromMonth) {\n startMonth = fromMonth;\n }\n if (!startMonth && fromYear) {\n startMonth = dateLib.newDate(fromYear, 0, 1);\n }\n if (!endMonth && toMonth) {\n endMonth = toMonth;\n }\n if (!endMonth && toYear) {\n endMonth = newDate(toYear, 11, 31);\n }\n const hasYearDropdown = props.captionLayout === \"dropdown\" ||\n props.captionLayout === \"dropdown-years\";\n if (startMonth) {\n startMonth = startOfMonth(startMonth);\n }\n else if (fromYear) {\n startMonth = newDate(fromYear, 0, 1);\n }\n else if (!startMonth && hasYearDropdown) {\n startMonth = startOfYear(addYears(props.today ?? today(), -100));\n }\n if (endMonth) {\n endMonth = endOfMonth(endMonth);\n }\n else if (toYear) {\n endMonth = newDate(toYear, 11, 31);\n }\n else if (!endMonth && hasYearDropdown) {\n endMonth = endOfYear(props.today ?? today());\n }\n return [\n startMonth ? startOfDay(startMonth) : startMonth,\n endMonth ? startOfDay(endMonth) : endMonth,\n ];\n}\n","/**\n * Returns the next month the user can navigate to, based on the given options.\n *\n * The next month is not always the next calendar month:\n *\n * - If it is after the `calendarEndMonth`, it returns `undefined`.\n * - If paged navigation is enabled, it skips forward by the number of displayed\n * months.\n *\n * @param firstDisplayedMonth The first month currently displayed in the\n * calendar.\n * @param calendarEndMonth The latest month the user can navigate to.\n * @param options Navigation options, including `numberOfMonths` and\n * `pagedNavigation`.\n * @param dateLib The date library to use for date manipulation.\n * @returns The next month, or `undefined` if navigation is not possible.\n */\nexport function getNextMonth(firstDisplayedMonth, calendarEndMonth, options, dateLib) {\n if (options.disableNavigation) {\n return undefined;\n }\n const { pagedNavigation, numberOfMonths = 1 } = options;\n const { startOfMonth, addMonths, differenceInCalendarMonths } = dateLib;\n const offset = pagedNavigation ? numberOfMonths : 1;\n const month = startOfMonth(firstDisplayedMonth);\n if (!calendarEndMonth) {\n return addMonths(month, offset);\n }\n const monthsDiff = differenceInCalendarMonths(calendarEndMonth, firstDisplayedMonth);\n if (monthsDiff < numberOfMonths) {\n return undefined;\n }\n return addMonths(month, offset);\n}\n","/**\n * Returns the previous month the user can navigate to, based on the given\n * options.\n *\n * The previous month is not always the previous calendar month:\n *\n * - If it is before the `calendarStartMonth`, it returns `undefined`.\n * - If paged navigation is enabled, it skips back by the number of displayed\n * months.\n *\n * @param firstDisplayedMonth The first month currently displayed in the\n * calendar.\n * @param calendarStartMonth The earliest month the user can navigate to.\n * @param options Navigation options, including `numberOfMonths` and\n * `pagedNavigation`.\n * @param dateLib The date library to use for date manipulation.\n * @returns The previous month, or `undefined` if navigation is not possible.\n */\nexport function getPreviousMonth(firstDisplayedMonth, calendarStartMonth, options, dateLib) {\n if (options.disableNavigation) {\n return undefined;\n }\n const { pagedNavigation, numberOfMonths } = options;\n const { startOfMonth, addMonths, differenceInCalendarMonths } = dateLib;\n const offset = pagedNavigation ? (numberOfMonths ?? 1) : 1;\n const month = startOfMonth(firstDisplayedMonth);\n if (!calendarStartMonth) {\n return addMonths(month, -offset);\n }\n const monthsDiff = differenceInCalendarMonths(month, calendarStartMonth);\n if (monthsDiff <= 0) {\n return undefined;\n }\n return addMonths(month, -offset);\n}\n","/**\n * Returns an array of calendar weeks from an array of calendar months.\n *\n * @param months The array of calendar months.\n * @returns An array of calendar weeks.\n */\nexport function getWeeks(months) {\n const initialWeeks = [];\n return months.reduce((weeks, month) => {\n return weeks.concat(month.weeks.slice());\n }, initialWeeks.slice());\n}\n","import { useState } from \"react\";\n/**\n * A custom hook for managing both controlled and uncontrolled component states.\n *\n * This hook allows a component to support both controlled and uncontrolled\n * states by determining whether the `controlledValue` is provided. If it is\n * undefined, the hook falls back to using the internal state.\n *\n * @example\n * // Uncontrolled usage\n * const [value, setValue] = useControlledValue(0, undefined);\n *\n * // Controlled usage\n * const [value, setValue] = useControlledValue(0, props.value);\n *\n * @template T - The type of the value.\n * @param defaultValue The initial value for the uncontrolled state.\n * @param controlledValue The value for the controlled state. If undefined, the\n * component will use the uncontrolled state.\n * @returns A tuple where the first element is the current value (either\n * controlled or uncontrolled) and the second element is a setter function to\n * update the value.\n */\nexport function useControlledValue(defaultValue, controlledValue) {\n const [uncontrolledValue, setValue] = useState(defaultValue);\n const value = controlledValue === undefined ? uncontrolledValue : controlledValue;\n return [value, setValue];\n}\n","import { useEffect, useMemo } from \"react\";\nimport { getDates } from \"./helpers/getDates.js\";\nimport { getDays } from \"./helpers/getDays.js\";\nimport { getDisplayMonths } from \"./helpers/getDisplayMonths.js\";\nimport { getInitialMonth } from \"./helpers/getInitialMonth.js\";\nimport { getMonths } from \"./helpers/getMonths.js\";\nimport { getNavMonths } from \"./helpers/getNavMonth.js\";\nimport { getNextMonth } from \"./helpers/getNextMonth.js\";\nimport { getPreviousMonth } from \"./helpers/getPreviousMonth.js\";\nimport { getWeeks } from \"./helpers/getWeeks.js\";\nimport { useControlledValue } from \"./helpers/useControlledValue.js\";\n/**\n * Provides the calendar object to work with the calendar in custom components.\n *\n * @private\n * @param props - The DayPicker props related to calendar configuration.\n * @param dateLib - The date utility library instance.\n * @returns The calendar object containing displayed days, weeks, months, and\n * navigation methods.\n */\nexport function useCalendar(props, dateLib) {\n const [navStart, navEnd] = getNavMonths(props, dateLib);\n const { startOfMonth, endOfMonth } = dateLib;\n const initialMonth = getInitialMonth(props, navStart, navEnd, dateLib);\n const [firstMonth, setFirstMonth] = useControlledValue(initialMonth, \n // initialMonth is always computed from props.month if provided\n props.month ? initialMonth : undefined);\n // biome-ignore lint/correctness/useExhaustiveDependencies: change the initial month when the time zone changes.\n useEffect(() => {\n const newInitialMonth = getInitialMonth(props, navStart, navEnd, dateLib);\n setFirstMonth(newInitialMonth);\n }, [props.timeZone]);\n /** The months displayed in the calendar. */\n // biome-ignore lint/correctness/useExhaustiveDependencies: We want to recompute only when specific props change.\n const { months, weeks, days, previousMonth, nextMonth } = useMemo(() => {\n const displayMonths = getDisplayMonths(firstMonth, navEnd, { numberOfMonths: props.numberOfMonths }, dateLib);\n const dates = getDates(displayMonths, props.endMonth ? endOfMonth(props.endMonth) : undefined, {\n ISOWeek: props.ISOWeek,\n fixedWeeks: props.fixedWeeks,\n broadcastCalendar: props.broadcastCalendar,\n }, dateLib);\n const months = getMonths(displayMonths, dates, {\n broadcastCalendar: props.broadcastCalendar,\n fixedWeeks: props.fixedWeeks,\n ISOWeek: props.ISOWeek,\n reverseMonths: props.reverseMonths,\n }, dateLib);\n const weeks = getWeeks(months);\n const days = getDays(months);\n const previousMonth = getPreviousMonth(firstMonth, navStart, props, dateLib);\n const nextMonth = getNextMonth(firstMonth, navEnd, props, dateLib);\n return {\n months,\n weeks,\n days,\n previousMonth,\n nextMonth,\n };\n }, [\n dateLib,\n firstMonth.getTime(),\n navEnd?.getTime(),\n navStart?.getTime(),\n props.disableNavigation,\n props.broadcastCalendar,\n props.endMonth?.getTime(),\n props.fixedWeeks,\n props.ISOWeek,\n props.numberOfMonths,\n props.pagedNavigation,\n props.reverseMonths,\n ]);\n const { disableNavigation, onMonthChange } = props;\n const isDayInCalendar = (day) => weeks.some((week) => week.days.some((d) => d.isEqualTo(day)));\n const goToMonth = (date) => {\n if (disableNavigation) {\n return;\n }\n let newMonth = startOfMonth(date);\n // if month is before start, use the first month instead\n if (navStart && newMonth < startOfMonth(navStart)) {\n newMonth = startOfMonth(navStart);\n }\n // if month is after endMonth, use the last month instead\n if (navEnd && newMonth > startOfMonth(navEnd)) {\n newMonth = startOfMonth(navEnd);\n }\n setFirstMonth(newMonth);\n onMonthChange?.(newMonth);\n };\n const goToDay = (day) => {\n // is this check necessary?\n if (isDayInCalendar(day)) {\n return;\n }\n goToMonth(day.date);\n };\n const calendar = {\n months,\n weeks,\n days,\n navStart,\n navEnd,\n previousMonth,\n nextMonth,\n goToMonth,\n goToDay,\n };\n return calendar;\n}\n","import { DayFlag } from \"../UI.js\";\nvar FocusTargetPriority;\n(function (FocusTargetPriority) {\n FocusTargetPriority[FocusTargetPriority[\"Today\"] = 0] = \"Today\";\n FocusTargetPriority[FocusTargetPriority[\"Selected\"] = 1] = \"Selected\";\n FocusTargetPriority[FocusTargetPriority[\"LastFocused\"] = 2] = \"LastFocused\";\n FocusTargetPriority[FocusTargetPriority[\"FocusedModifier\"] = 3] = \"FocusedModifier\";\n})(FocusTargetPriority || (FocusTargetPriority = {}));\n/**\n * Determines if a day is focusable based on its modifiers.\n *\n * A day is considered focusable if it is not disabled, hidden, or outside the\n * displayed month.\n *\n * @param modifiers The modifiers applied to the day.\n * @returns `true` if the day is focusable, otherwise `false`.\n */\nfunction isFocusableDay(modifiers) {\n return (!modifiers[DayFlag.disabled] &&\n !modifiers[DayFlag.hidden] &&\n !modifiers[DayFlag.outside]);\n}\n/**\n * Calculates the focus target day based on priority.\n *\n * This function determines the day that should receive focus in the calendar,\n * prioritizing days with specific modifiers (e.g., \"focused\", \"today\") or\n * selection states.\n *\n * @param days The array of `CalendarDay` objects to evaluate.\n * @param getModifiers A function to retrieve the modifiers for a given day.\n * @param isSelected A function to determine if a day is selected.\n * @param lastFocused The last focused day, if any.\n * @returns The `CalendarDay` that should receive focus, or `undefined` if no\n * focusable day is found.\n */\nexport function calculateFocusTarget(days, getModifiers, isSelected, lastFocused) {\n let focusTarget;\n let foundFocusTargetPriority = -1;\n for (const day of days) {\n const modifiers = getModifiers(day);\n if (isFocusableDay(modifiers)) {\n if (modifiers[DayFlag.focused] &&\n foundFocusTargetPriority < FocusTargetPriority.FocusedModifier) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.FocusedModifier;\n }\n else if (lastFocused?.isEqualTo(day) &&\n foundFocusTargetPriority < FocusTargetPriority.LastFocused) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.LastFocused;\n }\n else if (isSelected(day.date) &&\n foundFocusTargetPriority < FocusTargetPriority.Selected) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.Selected;\n }\n else if (modifiers[DayFlag.today] &&\n foundFocusTargetPriority < FocusTargetPriority.Today) {\n focusTarget = day;\n foundFocusTargetPriority = FocusTargetPriority.Today;\n }\n }\n }\n if (!focusTarget) {\n // Return the first day that is focusable\n focusTarget = days.find((day) => isFocusableDay(getModifiers(day)));\n }\n return focusTarget;\n}\n","/**\n * Calculates the next date that should be focused in the calendar.\n *\n * This function determines the next focusable date based on the movement\n * direction, constraints, and calendar configuration.\n *\n * @param moveBy The unit of movement (e.g., \"day\", \"week\").\n * @param moveDir The direction of movement (\"before\" or \"after\").\n * @param refDate The reference date from which to calculate the next focusable\n * date.\n * @param navStart The earliest date the user can navigate to.\n * @param navEnd The latest date the user can navigate to.\n * @param props The DayPicker props, including calendar configuration options.\n * @param dateLib The date library to use for date manipulation.\n * @returns The next focusable date.\n */\nexport function getFocusableDate(moveBy, moveDir, refDate, navStart, navEnd, props, dateLib) {\n const { ISOWeek, broadcastCalendar } = props;\n const { addDays, addMonths, addWeeks, addYears, endOfBroadcastWeek, endOfISOWeek, endOfWeek, max, min, startOfBroadcastWeek, startOfISOWeek, startOfWeek, } = dateLib;\n const moveFns = {\n day: addDays,\n week: addWeeks,\n month: addMonths,\n year: addYears,\n startOfWeek: (date) => broadcastCalendar\n ? startOfBroadcastWeek(date, dateLib)\n : ISOWeek\n ? startOfISOWeek(date)\n : startOfWeek(date),\n endOfWeek: (date) => broadcastCalendar\n ? endOfBroadcastWeek(date)\n : ISOWeek\n ? endOfISOWeek(date)\n : endOfWeek(date),\n };\n let focusableDate = moveFns[moveBy](refDate, moveDir === \"after\" ? 1 : -1);\n if (moveDir === \"before\" && navStart) {\n focusableDate = max([navStart, focusableDate]);\n }\n else if (moveDir === \"after\" && navEnd) {\n focusableDate = min([navEnd, focusableDate]);\n }\n return focusableDate;\n}\n","import { CalendarDay } from \"../classes/index.js\";\nimport { dateMatchModifiers } from \"../utils/dateMatchModifiers.js\";\nimport { getFocusableDate } from \"./getFocusableDate.js\";\n/**\n * Determines the next focusable day in the calendar.\n *\n * This function recursively calculates the next focusable day based on the\n * movement direction and modifiers applied to the days.\n *\n * @param moveBy The unit of movement (e.g., \"day\", \"week\").\n * @param moveDir The direction of movement (\"before\" or \"after\").\n * @param refDay The currently focused day.\n * @param calendarStartMonth The earliest month the user can navigate to.\n * @param calendarEndMonth The latest month the user can navigate to.\n * @param props The DayPicker props, including modifiers and configuration\n * options.\n * @param dateLib The date library to use for date manipulation.\n * @param attempt The current recursion attempt (used to limit recursion depth).\n * @returns The next focusable day, or `undefined` if no focusable day is found.\n */\nexport function getNextFocus(moveBy, moveDir, refDay, calendarStartMonth, calendarEndMonth, props, dateLib, attempt = 0) {\n if (attempt > 365) {\n // Limit the recursion to 365 attempts\n return undefined;\n }\n const focusableDate = getFocusableDate(moveBy, moveDir, refDay.date, calendarStartMonth, calendarEndMonth, props, dateLib);\n const isDisabled = Boolean(props.disabled &&\n dateMatchModifiers(focusableDate, props.disabled, dateLib));\n const isHidden = Boolean(props.hidden && dateMatchModifiers(focusableDate, props.hidden, dateLib));\n const targetMonth = focusableDate;\n const focusDay = new CalendarDay(focusableDate, targetMonth, dateLib);\n if (!isDisabled && !isHidden) {\n return focusDay;\n }\n // Recursively attempt to find the next focusable date\n return getNextFocus(moveBy, moveDir, focusDay, calendarStartMonth, calendarEndMonth, props, dateLib, attempt + 1);\n}\n","import { useState } from \"react\";\nimport { calculateFocusTarget } from \"./helpers/calculateFocusTarget.js\";\nimport { getNextFocus } from \"./helpers/getNextFocus.js\";\n/**\n * Manages focus behavior for the DayPicker component, including setting,\n * moving, and blurring focus on calendar days.\n *\n * @template T - The type of DayPicker props.\n * @param props - The DayPicker props.\n * @param calendar - The calendar object containing the displayed days and\n * months.\n * @param getModifiers - A function to retrieve modifiers for a given day.\n * @param isSelected - A function to check if a date is selected.\n * @param dateLib - The date utility library instance.\n * @returns An object containing focus-related methods and the currently focused\n * day.\n */\nexport function useFocus(props, calendar, getModifiers, isSelected, dateLib) {\n const { autoFocus } = props;\n const [lastFocused, setLastFocused] = useState();\n const focusTarget = calculateFocusTarget(calendar.days, getModifiers, isSelected || (() => false), lastFocused);\n const [focusedDay, setFocused] = useState(autoFocus ? focusTarget : undefined);\n const blur = () => {\n setLastFocused(focusedDay);\n setFocused(undefined);\n };\n const moveFocus = (moveBy, moveDir) => {\n if (!focusedDay)\n return;\n const nextFocus = getNextFocus(moveBy, moveDir, focusedDay, calendar.navStart, calendar.navEnd, props, dateLib);\n if (!nextFocus)\n return;\n if (props.disableNavigation) {\n const isNextInCalendar = calendar.days.some((day) => day.isEqualTo(nextFocus));\n if (!isNextInCalendar) {\n return;\n }\n }\n calendar.goToDay(nextFocus);\n setFocused(nextFocus);\n };\n const isFocusTarget = (day) => {\n return Boolean(focusTarget?.isEqualTo(day));\n };\n const useFocus = {\n isFocusTarget,\n setFocused,\n focused: focusedDay,\n blur,\n moveFocus,\n };\n return useFocus;\n}\n","import { useControlledValue } from \"../helpers/useControlledValue.js\";\n/**\n * Hook to manage multiple-date selection in the DayPicker component.\n *\n * @template T - The type of DayPicker props.\n * @param props - The DayPicker props.\n * @param dateLib - The date utility library instance.\n * @returns An object containing the selected dates, a function to select dates,\n * and a function to check if a date is selected.\n */\nexport function useMulti(props, dateLib) {\n const { selected: initiallySelected, required, onSelect, } = props;\n const [internallySelected, setSelected] = useControlledValue(initiallySelected, onSelect ? initiallySelected : undefined);\n const selected = !onSelect ? internallySelected : initiallySelected;\n const { isSameDay } = dateLib;\n const isSelected = (date) => {\n return selected?.some((d) => isSameDay(d, date)) ?? false;\n };\n const { min, max } = props;\n const select = (triggerDate, modifiers, e) => {\n let newDates = [...(selected ?? [])];\n if (isSelected(triggerDate)) {\n if (selected?.length === min) {\n // Min value reached, do nothing\n return;\n }\n if (required && selected?.length === 1) {\n // Required value already selected do nothing\n return;\n }\n newDates = selected?.filter((d) => !isSameDay(d, triggerDate));\n }\n else {\n if (selected?.length === max) {\n // Max value reached, reset the selection to date\n newDates = [triggerDate];\n }\n else {\n // Add the date to the selection\n newDates = [...newDates, triggerDate];\n }\n }\n if (!onSelect) {\n setSelected(newDates);\n }\n onSelect?.(newDates, triggerDate, modifiers, e);\n return newDates;\n };\n return {\n selected,\n select,\n isSelected,\n };\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\n/**\n * Adds a date to an existing range, considering constraints like minimum and\n * maximum range size.\n *\n * @param date - The date to add to the range.\n * @param initialRange - The initial range to which the date will be added.\n * @param min - The minimum number of days in the range.\n * @param max - The maximum number of days in the range.\n * @param required - Whether the range must always include at least one date.\n * @param dateLib - The date utility library instance.\n * @returns The updated date range, or `undefined` if the range is cleared.\n * @group Utilities\n */\nexport function addToRange(date, initialRange, min = 0, max = 0, required = false, dateLib = defaultDateLib) {\n const { from, to } = initialRange || {};\n const { isSameDay, isAfter, isBefore } = dateLib;\n let range;\n if (!from && !to) {\n // the range is empty, add the date\n range = { from: date, to: min > 0 ? undefined : date };\n }\n else if (from && !to) {\n // adding date to an incomplete range\n if (isSameDay(from, date)) {\n // adding a date equal to the start of the range\n if (min === 0) {\n range = { from, to: date };\n }\n else if (required) {\n range = { from, to: undefined };\n }\n else {\n range = undefined;\n }\n }\n else if (isBefore(date, from)) {\n // adding a date before the start of the range\n range = { from: date, to: from };\n }\n else {\n // adding a date after the start of the range\n range = { from, to: date };\n }\n }\n else if (from && to) {\n // adding date to a complete range\n if (isSameDay(from, date) && isSameDay(to, date)) {\n // adding a date that is equal to both start and end of the range\n if (required) {\n range = { from, to };\n }\n else {\n range = undefined;\n }\n }\n else if (isSameDay(from, date)) {\n // adding a date equal to the the start of the range\n range = { from, to: min > 0 ? undefined : date };\n }\n else if (isSameDay(to, date)) {\n // adding a dare equal to the end of the range\n range = { from: date, to: min > 0 ? undefined : date };\n }\n else if (isBefore(date, from)) {\n // adding a date before the start of the range\n range = { from: date, to: to };\n }\n else if (isAfter(date, from)) {\n // adding a date after the start of the range\n range = { from, to: date };\n }\n else if (isAfter(date, to)) {\n // adding a date after the end of the range\n range = { from, to: date };\n }\n else {\n throw new Error(\"Invalid range\");\n }\n }\n // check for min / max\n if (range?.from && range?.to) {\n const diff = dateLib.differenceInCalendarDays(range.to, range.from);\n if (max > 0 && diff > max) {\n range = { from: date, to: undefined };\n }\n else if (min > 1 && diff < min) {\n range = { from: date, to: undefined };\n }\n }\n return range;\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\n/**\n * Checks if a date range contains one or more specified days of the week.\n *\n * @since 9.2.2\n * @param range - The date range to check.\n * @param dayOfWeek - The day(s) of the week to check for (`0-6`, where `0` is\n * Sunday).\n * @param dateLib - The date utility library instance.\n * @returns `true` if the range contains the specified day(s) of the week,\n * otherwise `false`.\n * @group Utilities\n */\nexport function rangeContainsDayOfWeek(range, dayOfWeek, dateLib = defaultDateLib) {\n const dayOfWeekArr = !Array.isArray(dayOfWeek) ? [dayOfWeek] : dayOfWeek;\n let date = range.from;\n const totalDays = dateLib.differenceInCalendarDays(range.to, range.from);\n // iterate at maximum one week or the total days if the range is shorter than one week\n const totalDaysLimit = Math.min(totalDays, 6);\n for (let i = 0; i <= totalDaysLimit; i++) {\n if (dayOfWeekArr.includes(date.getDay())) {\n return true;\n }\n date = dateLib.addDays(date, 1);\n }\n return false;\n}\n","import { defaultDateLib } from \"../classes/index.js\";\nimport { rangeIncludesDate } from \"./rangeIncludesDate.js\";\n/**\n * Determines if two date ranges overlap.\n *\n * @since 9.2.2\n * @param rangeLeft - The first date range.\n * @param rangeRight - The second date range.\n * @param dateLib - The date utility library instance.\n * @returns `true` if the ranges overlap, otherwise `false`.\n * @group Utilities\n */\nexport function rangeOverlaps(rangeLeft, rangeRight, dateLib = defaultDateLib) {\n return (rangeIncludesDate(rangeLeft, rangeRight.from, false, dateLib) ||\n rangeIncludesDate(rangeLeft, rangeRight.to, false, dateLib) ||\n rangeIncludesDate(rangeRight, rangeLeft.from, false, dateLib) ||\n rangeIncludesDate(rangeRight, rangeLeft.to, false, dateLib));\n}\n","import { defaultDateLib } from \"../classes/DateLib.js\";\nimport { dateMatchModifiers } from \"./dateMatchModifiers.js\";\nimport { rangeContainsDayOfWeek } from \"./rangeContainsDayOfWeek.js\";\nimport { rangeIncludesDate } from \"./rangeIncludesDate.js\";\nimport { rangeOverlaps } from \"./rangeOverlaps.js\";\nimport { isDateAfterType, isDateBeforeType, isDateInterval, isDateRange, isDatesArray, isDayOfWeekType, } from \"./typeguards.js\";\n/**\n * Checks if a date range contains dates that match the given modifiers.\n *\n * @since 9.2.2\n * @param range - The date range to check.\n * @param modifiers - The modifiers to match against.\n * @param dateLib - The date utility library instance.\n * @returns `true` if the range contains matching dates, otherwise `false`.\n * @group Utilities\n */\nexport function rangeContainsModifiers(range, modifiers, dateLib = defaultDateLib) {\n const matchers = Array.isArray(modifiers) ? modifiers : [modifiers];\n // Defer function matchers evaluation as they are the least performant.\n const nonFunctionMatchers = matchers.filter((matcher) => typeof matcher !== \"function\");\n const nonFunctionMatchersResult = nonFunctionMatchers.some((matcher) => {\n if (typeof matcher === \"boolean\")\n return matcher;\n if (dateLib.isDate(matcher)) {\n return rangeIncludesDate(range, matcher, false, dateLib);\n }\n if (isDatesArray(matcher, dateLib)) {\n return matcher.some((date) => rangeIncludesDate(range, date, false, dateLib));\n }\n if (isDateRange(matcher)) {\n if (matcher.from && matcher.to) {\n return rangeOverlaps(range, { from: matcher.from, to: matcher.to }, dateLib);\n }\n return false;\n }\n if (isDayOfWeekType(matcher)) {\n return rangeContainsDayOfWeek(range, matcher.dayOfWeek, dateLib);\n }\n if (isDateInterval(matcher)) {\n const isClosedInterval = dateLib.isAfter(matcher.before, matcher.after);\n if (isClosedInterval) {\n return rangeOverlaps(range, {\n from: dateLib.addDays(matcher.after, 1),\n to: dateLib.addDays(matcher.before, -1),\n }, dateLib);\n }\n return (dateMatchModifiers(range.from, matcher, dateLib) ||\n dateMatchModifiers(range.to, matcher, dateLib));\n }\n if (isDateAfterType(matcher) || isDateBeforeType(matcher)) {\n return (dateMatchModifiers(range.from, matcher, dateLib) ||\n dateMatchModifiers(range.to, matcher, dateLib));\n }\n return false;\n });\n if (nonFunctionMatchersResult) {\n return true;\n }\n const functionMatchers = matchers.filter((matcher) => typeof matcher === \"function\");\n if (functionMatchers.length) {\n let date = range.from;\n const totalDays = dateLib.differenceInCalendarDays(range.to, range.from);\n for (let i = 0; i <= totalDays; i++) {\n if (functionMatchers.some((matcher) => matcher(date))) {\n return true;\n }\n date = dateLib.addDays(date, 1);\n }\n }\n return false;\n}\n","import { useControlledValue } from \"../helpers/useControlledValue.js\";\nimport { addToRange, rangeContainsModifiers } from \"../utils/index.js\";\nimport { rangeIncludesDate } from \"../utils/rangeIncludesDate.js\";\n/**\n * Hook to manage range selection in the DayPicker component.\n *\n * @template T - The type of DayPicker props.\n * @param props - The DayPicker props.\n * @param dateLib - The date utility library instance.\n * @returns An object containing the selected range, a function to select a\n * range, and a function to check if a date is within the range.\n */\nexport function useRange(props, dateLib) {\n const { disabled, excludeDisabled, selected: initiallySelected, required, onSelect, } = props;\n const [internallySelected, setSelected] = useControlledValue(initiallySelected, onSelect ? initiallySelected : undefined);\n const selected = !onSelect ? internallySelected : initiallySelected;\n const isSelected = (date) => selected && rangeIncludesDate(selected, date, false, dateLib);\n const select = (triggerDate, modifiers, e) => {\n const { min, max } = props;\n const newRange = triggerDate\n ? addToRange(triggerDate, selected, min, max, required, dateLib)\n : undefined;\n if (excludeDisabled && disabled && newRange?.from && newRange.to) {\n if (rangeContainsModifiers({ from: newRange.from, to: newRange.to }, disabled, dateLib)) {\n // if a disabled days is found, the range is reset\n newRange.from = triggerDate;\n newRange.to = undefined;\n }\n }\n if (!onSelect) {\n setSelected(newRange);\n }\n onSelect?.(newRange, triggerDate, modifiers, e);\n return newRange;\n };\n return {\n selected,\n select,\n isSelected,\n };\n}\n","import { useControlledValue } from \"../helpers/useControlledValue.js\";\n/**\n * Hook to manage single-date selection in the DayPicker component.\n *\n * @template T - The type of DayPicker props.\n * @param props - The DayPicker props.\n * @param dateLib - The date utility library instance.\n * @returns An object containing the selected date, a function to select a date,\n * and a function to check if a date is selected.\n */\nexport function useSingle(props, dateLib) {\n const { selected: initiallySelected, required, onSelect, } = props;\n const [internallySelected, setSelected] = useControlledValue(initiallySelected, onSelect ? initiallySelected : undefined);\n const selected = !onSelect ? internallySelected : initiallySelected;\n const { isSameDay } = dateLib;\n const isSelected = (compareDate) => {\n return selected ? isSameDay(selected, compareDate) : false;\n };\n const select = (triggerDate, modifiers, e) => {\n let newDate = triggerDate;\n if (!required && selected && selected && isSameDay(triggerDate, selected)) {\n // If the date is the same, clear the selection.\n newDate = undefined;\n }\n if (!onSelect) {\n setSelected(newDate);\n }\n if (required) {\n onSelect?.(newDate, triggerDate, modifiers, e);\n }\n else {\n onSelect?.(newDate, triggerDate, modifiers, e);\n }\n return newDate;\n };\n return {\n selected,\n select,\n isSelected,\n };\n}\n","import { useMulti } from \"./selection/useMulti.js\";\nimport { useRange } from \"./selection/useRange.js\";\nimport { useSingle } from \"./selection/useSingle.js\";\n/**\n * Determines the appropriate selection hook to use based on the selection mode\n * and returns the corresponding selection object.\n *\n * @template T - The type of DayPicker props.\n * @param props - The DayPicker props.\n * @param dateLib - The date utility library instance.\n * @returns The selection object for the specified mode, or `undefined` if no\n * mode is set.\n */\nexport function useSelection(props, dateLib) {\n const single = useSingle(props, dateLib);\n const multi = useMulti(props, dateLib);\n const range = useRange(props, dateLib);\n switch (props.mode) {\n case \"single\":\n return single;\n case \"multiple\":\n return multi;\n case \"range\":\n return range;\n default:\n return undefined;\n }\n}\n","import { TZDate } from \"@date-fns/tz\";\n/**\n * Convert a {@link Date} or {@link TZDate} instance to the given time zone.\n * Reuses the same instance when it is already a {@link TZDate} using the target\n * time zone to avoid extra allocations.\n */\nexport function toTimeZone(date, timeZone) {\n if (date instanceof TZDate && date.timeZone === timeZone) {\n return date;\n }\n return new TZDate(date, timeZone);\n}\n","import { TZDate } from \"@date-fns/tz\";\nimport { toTimeZone } from \"./toTimeZone.js\";\nimport { isDateAfterType, isDateBeforeType, isDateInterval, isDateRange, } from \"./typeguards.js\";\nfunction toZoneNoon(date, timeZone, noonSafe) {\n if (!noonSafe)\n return toTimeZone(date, timeZone);\n const zoned = toTimeZone(date, timeZone);\n const noonZoned = new TZDate(zoned.getFullYear(), zoned.getMonth(), zoned.getDate(), 12, 0, 0, timeZone);\n return new Date(noonZoned.getTime());\n}\nfunction convertMatcher(matcher, timeZone, noonSafe) {\n if (typeof matcher === \"boolean\" || typeof matcher === \"function\") {\n return matcher;\n }\n if (matcher instanceof Date) {\n return toZoneNoon(matcher, timeZone, noonSafe);\n }\n if (Array.isArray(matcher)) {\n return matcher.map((value) => value instanceof Date ? toZoneNoon(value, timeZone, noonSafe) : value);\n }\n if (isDateRange(matcher)) {\n return {\n ...matcher,\n from: matcher.from ? toTimeZone(matcher.from, timeZone) : matcher.from,\n to: matcher.to ? toTimeZone(matcher.to, timeZone) : matcher.to,\n };\n }\n if (isDateInterval(matcher)) {\n return {\n before: toZoneNoon(matcher.before, timeZone, noonSafe),\n after: toZoneNoon(matcher.after, timeZone, noonSafe),\n };\n }\n if (isDateAfterType(matcher)) {\n return {\n after: toZoneNoon(matcher.after, timeZone, noonSafe),\n };\n }\n if (isDateBeforeType(matcher)) {\n return {\n before: toZoneNoon(matcher.before, timeZone, noonSafe),\n };\n }\n return matcher;\n}\n/**\n * Convert any {@link Matcher} or array of matchers to the specified time zone.\n *\n * @param matchers - The matcher or matchers to convert.\n * @param timeZone - The target IANA time zone.\n * @returns The converted matcher(s).\n * @group Utilities\n */\nexport function convertMatchersToTimeZone(matchers, timeZone, noonSafe) {\n if (!matchers) {\n return matchers;\n }\n if (Array.isArray(matchers)) {\n return matchers.map((matcher) => convertMatcher(matcher, timeZone, noonSafe));\n }\n return convertMatcher(matchers, timeZone, noonSafe);\n}\n","import React, { useCallback, useMemo, useRef } from \"react\";\nimport { DateLib, defaultLocale } from \"./classes/DateLib.js\";\nimport { createGetModifiers } from \"./helpers/createGetModifiers.js\";\nimport { getClassNamesForModifiers } from \"./helpers/getClassNamesForModifiers.js\";\nimport { getComponents } from \"./helpers/getComponents.js\";\nimport { getDataAttributes } from \"./helpers/getDataAttributes.js\";\nimport { getDefaultClassNames } from \"./helpers/getDefaultClassNames.js\";\nimport { getFormatters } from \"./helpers/getFormatters.js\";\nimport { getLabels } from \"./helpers/getLabels.js\";\nimport { getMonthOptions } from \"./helpers/getMonthOptions.js\";\nimport { getStyleForModifiers } from \"./helpers/getStyleForModifiers.js\";\nimport { getWeekdays } from \"./helpers/getWeekdays.js\";\nimport { getYearOptions } from \"./helpers/getYearOptions.js\";\nimport { createNoonOverrides } from \"./noonDateLib.js\";\nimport { DayFlag, SelectionState, UI } from \"./UI.js\";\nimport { useAnimation } from \"./useAnimation.js\";\nimport { useCalendar } from \"./useCalendar.js\";\nimport { dayPickerContext } from \"./useDayPicker.js\";\nimport { useFocus } from \"./useFocus.js\";\nimport { useSelection } from \"./useSelection.js\";\nimport { convertMatchersToTimeZone } from \"./utils/convertMatchersToTimeZone.js\";\nimport { rangeIncludesDate } from \"./utils/rangeIncludesDate.js\";\nimport { toTimeZone } from \"./utils/toTimeZone.js\";\nimport { isDateRange } from \"./utils/typeguards.js\";\n/**\n * Renders the DayPicker calendar component.\n *\n * @param initialProps - The props for the DayPicker component.\n * @returns The rendered DayPicker component.\n * @group DayPicker\n * @see https://daypicker.dev\n */\nexport function DayPicker(initialProps) {\n let props = initialProps;\n const timeZone = props.timeZone;\n if (timeZone) {\n props = {\n ...initialProps,\n timeZone,\n };\n if (props.today) {\n props.today = toTimeZone(props.today, timeZone);\n }\n if (props.month) {\n props.month = toTimeZone(props.month, timeZone);\n }\n if (props.defaultMonth) {\n props.defaultMonth = toTimeZone(props.defaultMonth, timeZone);\n }\n if (props.startMonth) {\n props.startMonth = toTimeZone(props.startMonth, timeZone);\n }\n if (props.endMonth) {\n props.endMonth = toTimeZone(props.endMonth, timeZone);\n }\n if (props.mode === \"single\" && props.selected) {\n props.selected = toTimeZone(props.selected, timeZone);\n }\n else if (props.mode === \"multiple\" && props.selected) {\n props.selected = props.selected?.map((date) => toTimeZone(date, timeZone));\n }\n else if (props.mode === \"range\" && props.selected) {\n props.selected = {\n from: props.selected.from\n ? toTimeZone(props.selected.from, timeZone)\n : props.selected.from,\n to: props.selected.to\n ? toTimeZone(props.selected.to, timeZone)\n : props.selected.to,\n };\n }\n if (props.disabled !== undefined) {\n props.disabled = convertMatchersToTimeZone(props.disabled, timeZone);\n }\n if (props.hidden !== undefined) {\n props.hidden = convertMatchersToTimeZone(props.hidden, timeZone);\n }\n if (props.modifiers) {\n const nextModifiers = {};\n Object.keys(props.modifiers).forEach((key) => {\n nextModifiers[key] = convertMatchersToTimeZone(props.modifiers?.[key], timeZone);\n });\n props.modifiers = nextModifiers;\n }\n }\n const { components, formatters, labels, dateLib, locale, classNames } = useMemo(() => {\n const locale = { ...defaultLocale, ...props.locale };\n const weekStartsOn = props.broadcastCalendar ? 1 : props.weekStartsOn;\n const noonOverrides = props.noonSafe && props.timeZone\n ? createNoonOverrides(props.timeZone, {\n weekStartsOn,\n locale,\n })\n : undefined;\n const overrides = props.dateLib && noonOverrides\n ? { ...noonOverrides, ...props.dateLib }\n : (props.dateLib ?? noonOverrides);\n const dateLib = new DateLib({\n locale,\n weekStartsOn,\n firstWeekContainsDate: props.firstWeekContainsDate,\n useAdditionalWeekYearTokens: props.useAdditionalWeekYearTokens,\n useAdditionalDayOfYearTokens: props.useAdditionalDayOfYearTokens,\n timeZone: props.timeZone,\n numerals: props.numerals,\n }, overrides);\n return {\n dateLib,\n components: getComponents(props.components),\n formatters: getFormatters(props.formatters),\n labels: getLabels(props.labels, dateLib.options),\n locale,\n classNames: { ...getDefaultClassNames(), ...props.classNames },\n };\n }, [\n props.locale,\n props.broadcastCalendar,\n props.weekStartsOn,\n props.firstWeekContainsDate,\n props.useAdditionalWeekYearTokens,\n props.useAdditionalDayOfYearTokens,\n props.timeZone,\n props.numerals,\n props.dateLib,\n props.noonSafe,\n props.components,\n props.formatters,\n props.labels,\n props.classNames,\n ]);\n if (!props.today) {\n props = { ...props, today: dateLib.today() };\n }\n const { captionLayout, mode, navLayout, numberOfMonths = 1, onDayBlur, onDayClick, onDayFocus, onDayKeyDown, onDayMouseEnter, onDayMouseLeave, onNextClick, onPrevClick, showWeekNumber, styles, } = props;\n const { formatCaption, formatDay, formatMonthDropdown, formatWeekNumber, formatWeekNumberHeader, formatWeekdayName, formatYearDropdown, } = formatters;\n const calendar = useCalendar(props, dateLib);\n const { days, months, navStart, navEnd, previousMonth, nextMonth, goToMonth, } = calendar;\n const getModifiers = createGetModifiers(days, props, navStart, navEnd, dateLib);\n const { isSelected, select, selected: selectedValue, } = useSelection(props, dateLib) ?? {};\n const { blur, focused, isFocusTarget, moveFocus, setFocused } = useFocus(props, calendar, getModifiers, isSelected ?? (() => false), dateLib);\n const { labelDayButton, labelGridcell, labelGrid, labelMonthDropdown, labelNav, labelPrevious, labelNext, labelWeekday, labelWeekNumber, labelWeekNumberHeader, labelYearDropdown, } = labels;\n const weekdays = useMemo(() => getWeekdays(dateLib, props.ISOWeek, props.broadcastCalendar, props.today), [dateLib, props.ISOWeek, props.broadcastCalendar, props.today]);\n const isInteractive = mode !== undefined || onDayClick !== undefined;\n const handlePreviousClick = useCallback(() => {\n if (!previousMonth)\n return;\n goToMonth(previousMonth);\n onPrevClick?.(previousMonth);\n }, [previousMonth, goToMonth, onPrevClick]);\n const handleNextClick = useCallback(() => {\n if (!nextMonth)\n return;\n goToMonth(nextMonth);\n onNextClick?.(nextMonth);\n }, [goToMonth, nextMonth, onNextClick]);\n const handleDayClick = useCallback((day, m) => (e) => {\n e.preventDefault();\n e.stopPropagation();\n setFocused(day);\n if (m.disabled) {\n return;\n }\n select?.(day.date, m, e);\n onDayClick?.(day.date, m, e);\n }, [select, onDayClick, setFocused]);\n const handleDayFocus = useCallback((day, m) => (e) => {\n setFocused(day);\n onDayFocus?.(day.date, m, e);\n }, [onDayFocus, setFocused]);\n const handleDayBlur = useCallback((day, m) => (e) => {\n blur();\n onDayBlur?.(day.date, m, e);\n }, [blur, onDayBlur]);\n const handleDayKeyDown = useCallback((day, modifiers) => (e) => {\n const keyMap = {\n ArrowLeft: [\n e.shiftKey ? \"month\" : \"day\",\n props.dir === \"rtl\" ? \"after\" : \"before\",\n ],\n ArrowRight: [\n e.shiftKey ? \"month\" : \"day\",\n props.dir === \"rtl\" ? \"before\" : \"after\",\n ],\n ArrowDown: [e.shiftKey ? \"year\" : \"week\", \"after\"],\n ArrowUp: [e.shiftKey ? \"year\" : \"week\", \"before\"],\n PageUp: [e.shiftKey ? \"year\" : \"month\", \"before\"],\n PageDown: [e.shiftKey ? \"year\" : \"month\", \"after\"],\n Home: [\"startOfWeek\", \"before\"],\n End: [\"endOfWeek\", \"after\"],\n };\n if (keyMap[e.key]) {\n e.preventDefault();\n e.stopPropagation();\n const [moveBy, moveDir] = keyMap[e.key];\n moveFocus(moveBy, moveDir);\n }\n onDayKeyDown?.(day.date, modifiers, e);\n }, [moveFocus, onDayKeyDown, props.dir]);\n const handleDayMouseEnter = useCallback((day, modifiers) => (e) => {\n onDayMouseEnter?.(day.date, modifiers, e);\n }, [onDayMouseEnter]);\n const handleDayMouseLeave = useCallback((day, modifiers) => (e) => {\n onDayMouseLeave?.(day.date, modifiers, e);\n }, [onDayMouseLeave]);\n const handleMonthChange = useCallback((date) => (e) => {\n const selectedMonth = Number(e.target.value);\n const month = dateLib.setMonth(dateLib.startOfMonth(date), selectedMonth);\n goToMonth(month);\n }, [dateLib, goToMonth]);\n const handleYearChange = useCallback((date) => (e) => {\n const selectedYear = Number(e.target.value);\n const month = dateLib.setYear(dateLib.startOfMonth(date), selectedYear);\n goToMonth(month);\n }, [dateLib, goToMonth]);\n const { className, style } = useMemo(() => ({\n className: [classNames[UI.Root], props.className]\n .filter(Boolean)\n .join(\" \"),\n style: { ...styles?.[UI.Root], ...props.style },\n }), [classNames, props.className, props.style, styles]);\n const dataAttributes = getDataAttributes(props);\n const rootElRef = useRef(null);\n useAnimation(rootElRef, Boolean(props.animate), {\n classNames,\n months,\n focused,\n dateLib,\n });\n const contextValue = {\n dayPickerProps: props,\n selected: selectedValue,\n select: select,\n isSelected,\n months,\n nextMonth,\n previousMonth,\n goToMonth,\n getModifiers,\n components,\n classNames,\n styles,\n labels,\n formatters,\n };\n return (React.createElement(dayPickerContext.Provider, { value: contextValue },\n React.createElement(components.Root, { rootRef: props.animate ? rootElRef : undefined, className: className, style: style, dir: props.dir, id: props.id, lang: props.lang, nonce: props.nonce, title: props.title, role: props.role, \"aria-label\": props[\"aria-label\"], \"aria-labelledby\": props[\"aria-labelledby\"], ...dataAttributes },\n React.createElement(components.Months, { className: classNames[UI.Months], style: styles?.[UI.Months] },\n !props.hideNavigation && !navLayout && (React.createElement(components.Nav, { \"data-animated-nav\": props.animate ? \"true\" : undefined, className: classNames[UI.Nav], style: styles?.[UI.Nav], \"aria-label\": labelNav(), onPreviousClick: handlePreviousClick, onNextClick: handleNextClick, previousMonth: previousMonth, nextMonth: nextMonth })),\n months.map((calendarMonth, displayIndex) => {\n return (React.createElement(components.Month, { \"data-animated-month\": props.animate ? \"true\" : undefined, className: classNames[UI.Month], style: styles?.[UI.Month], \n // biome-ignore lint/suspicious/noArrayIndexKey: breaks animation\n key: displayIndex, displayIndex: displayIndex, calendarMonth: calendarMonth },\n navLayout === \"around\" &&\n !props.hideNavigation &&\n displayIndex === 0 && (React.createElement(components.PreviousMonthButton, { type: \"button\", className: classNames[UI.PreviousMonthButton], tabIndex: previousMonth ? undefined : -1, \"aria-disabled\": previousMonth ? undefined : true, \"aria-label\": labelPrevious(previousMonth), onClick: handlePreviousClick, \"data-animated-button\": props.animate ? \"true\" : undefined },\n React.createElement(components.Chevron, { disabled: previousMonth ? undefined : true, className: classNames[UI.Chevron], orientation: props.dir === \"rtl\" ? \"right\" : \"left\" }))),\n React.createElement(components.MonthCaption, { \"data-animated-caption\": props.animate ? \"true\" : undefined, className: classNames[UI.MonthCaption], style: styles?.[UI.MonthCaption], calendarMonth: calendarMonth, displayIndex: displayIndex }, captionLayout?.startsWith(\"dropdown\") ? (React.createElement(components.DropdownNav, { className: classNames[UI.Dropdowns], style: styles?.[UI.Dropdowns] },\n (() => {\n const monthControl = captionLayout === \"dropdown\" ||\n captionLayout === \"dropdown-months\" ? (React.createElement(components.MonthsDropdown, { key: \"month\", className: classNames[UI.MonthsDropdown], \"aria-label\": labelMonthDropdown(), classNames: classNames, components: components, disabled: Boolean(props.disableNavigation), onChange: handleMonthChange(calendarMonth.date), options: getMonthOptions(calendarMonth.date, navStart, navEnd, formatters, dateLib), style: styles?.[UI.Dropdown], value: dateLib.getMonth(calendarMonth.date) })) : (React.createElement(\"span\", { key: \"month\" }, formatMonthDropdown(calendarMonth.date, dateLib)));\n const yearControl = captionLayout === \"dropdown\" ||\n captionLayout === \"dropdown-years\" ? (React.createElement(components.YearsDropdown, { key: \"year\", className: classNames[UI.YearsDropdown], \"aria-label\": labelYearDropdown(dateLib.options), classNames: classNames, components: components, disabled: Boolean(props.disableNavigation), onChange: handleYearChange(calendarMonth.date), options: getYearOptions(navStart, navEnd, formatters, dateLib, Boolean(props.reverseYears)), style: styles?.[UI.Dropdown], value: dateLib.getYear(calendarMonth.date) })) : (React.createElement(\"span\", { key: \"year\" }, formatYearDropdown(calendarMonth.date, dateLib)));\n const controls = dateLib.getMonthYearOrder() === \"year-first\"\n ? [yearControl, monthControl]\n : [monthControl, yearControl];\n return controls;\n })(),\n React.createElement(\"span\", { role: \"status\", \"aria-live\": \"polite\", style: {\n border: 0,\n clip: \"rect(0 0 0 0)\",\n height: \"1px\",\n margin: \"-1px\",\n overflow: \"hidden\",\n padding: 0,\n position: \"absolute\",\n width: \"1px\",\n whiteSpace: \"nowrap\",\n wordWrap: \"normal\",\n } }, formatCaption(calendarMonth.date, dateLib.options, dateLib)))) : (React.createElement(components.CaptionLabel, { className: classNames[UI.CaptionLabel], role: \"status\", \"aria-live\": \"polite\" }, formatCaption(calendarMonth.date, dateLib.options, dateLib)))),\n navLayout === \"around\" &&\n !props.hideNavigation &&\n displayIndex === numberOfMonths - 1 && (React.createElement(components.NextMonthButton, { type: \"button\", className: classNames[UI.NextMonthButton], tabIndex: nextMonth ? undefined : -1, \"aria-disabled\": nextMonth ? undefined : true, \"aria-label\": labelNext(nextMonth), onClick: handleNextClick, \"data-animated-button\": props.animate ? \"true\" : undefined },\n React.createElement(components.Chevron, { disabled: nextMonth ? undefined : true, className: classNames[UI.Chevron], orientation: props.dir === \"rtl\" ? \"left\" : \"right\" }))),\n displayIndex === numberOfMonths - 1 &&\n navLayout === \"after\" &&\n !props.hideNavigation && (React.createElement(components.Nav, { \"data-animated-nav\": props.animate ? \"true\" : undefined, className: classNames[UI.Nav], style: styles?.[UI.Nav], \"aria-label\": labelNav(), onPreviousClick: handlePreviousClick, onNextClick: handleNextClick, previousMonth: previousMonth, nextMonth: nextMonth })),\n React.createElement(components.MonthGrid, { role: \"grid\", \"aria-multiselectable\": mode === \"multiple\" || mode === \"range\", \"aria-label\": labelGrid(calendarMonth.date, dateLib.options, dateLib) ||\n undefined, className: classNames[UI.MonthGrid], style: styles?.[UI.MonthGrid] },\n !props.hideWeekdays && (React.createElement(components.Weekdays, { \"data-animated-weekdays\": props.animate ? \"true\" : undefined, className: classNames[UI.Weekdays], style: styles?.[UI.Weekdays] },\n showWeekNumber && (React.createElement(components.WeekNumberHeader, { \"aria-label\": labelWeekNumberHeader(dateLib.options), className: classNames[UI.WeekNumberHeader], style: styles?.[UI.WeekNumberHeader], scope: \"col\" }, formatWeekNumberHeader())),\n weekdays.map((weekday) => (React.createElement(components.Weekday, { \"aria-label\": labelWeekday(weekday, dateLib.options, dateLib), className: classNames[UI.Weekday], key: String(weekday), style: styles?.[UI.Weekday], scope: \"col\" }, formatWeekdayName(weekday, dateLib.options, dateLib)))))),\n React.createElement(components.Weeks, { \"data-animated-weeks\": props.animate ? \"true\" : undefined, className: classNames[UI.Weeks], style: styles?.[UI.Weeks] }, calendarMonth.weeks.map((week) => {\n return (React.createElement(components.Week, { className: classNames[UI.Week], key: week.weekNumber, style: styles?.[UI.Week], week: week },\n showWeekNumber && (React.createElement(components.WeekNumber, { week: week, style: styles?.[UI.WeekNumber], \"aria-label\": labelWeekNumber(week.weekNumber, {\n locale,\n }), className: classNames[UI.WeekNumber], scope: \"row\", role: \"rowheader\" }, formatWeekNumber(week.weekNumber, dateLib))),\n week.days.map((day) => {\n const { date } = day;\n const modifiers = getModifiers(day);\n modifiers[DayFlag.focused] =\n !modifiers.hidden &&\n Boolean(focused?.isEqualTo(day));\n modifiers[SelectionState.selected] =\n isSelected?.(date) || modifiers.selected;\n if (isDateRange(selectedValue)) {\n // add range modifiers\n const { from, to } = selectedValue;\n modifiers[SelectionState.range_start] = Boolean(from && to && dateLib.isSameDay(date, from));\n modifiers[SelectionState.range_end] = Boolean(from && to && dateLib.isSameDay(date, to));\n modifiers[SelectionState.range_middle] =\n rangeIncludesDate(selectedValue, date, true, dateLib);\n }\n const style = getStyleForModifiers(modifiers, styles, props.modifiersStyles);\n const className = getClassNamesForModifiers(modifiers, classNames, props.modifiersClassNames);\n const ariaLabel = !isInteractive && !modifiers.hidden\n ? labelGridcell(date, modifiers, dateLib.options, dateLib)\n : undefined;\n return (React.createElement(components.Day, { key: `${day.isoDate}_${day.displayMonthId}`, day: day, modifiers: modifiers, className: className.join(\" \"), style: style, role: \"gridcell\", \"aria-selected\": modifiers.selected || undefined, \"aria-label\": ariaLabel, \"data-day\": day.isoDate, \"data-month\": day.outside ? day.dateMonthId : undefined, \"data-selected\": modifiers.selected || undefined, \"data-disabled\": modifiers.disabled || undefined, \"data-hidden\": modifiers.hidden || undefined, \"data-outside\": day.outside || undefined, \"data-focused\": modifiers.focused || undefined, \"data-today\": modifiers.today || undefined }, !modifiers.hidden && isInteractive ? (React.createElement(components.DayButton, { className: classNames[UI.DayButton], style: styles?.[UI.DayButton], type: \"button\", day: day, modifiers: modifiers, disabled: (!modifiers.focused &&\n modifiers.disabled) ||\n undefined, \"aria-disabled\": (modifiers.focused &&\n modifiers.disabled) ||\n undefined, tabIndex: isFocusTarget(day) ? 0 : -1, \"aria-label\": labelDayButton(date, modifiers, dateLib.options, dateLib), onClick: handleDayClick(day, modifiers), onBlur: handleDayBlur(day, modifiers), onFocus: handleDayFocus(day, modifiers), onKeyDown: handleDayKeyDown(day, modifiers), onMouseEnter: handleDayMouseEnter(day, modifiers), onMouseLeave: handleDayMouseLeave(day, modifiers) }, formatDay(date, dateLib.options, dateLib))) : (!modifiers.hidden &&\n formatDay(day.date, dateLib.options, dateLib))));\n })));\n })))));\n })),\n props.footer && (React.createElement(components.Footer, { className: classNames[UI.Footer], style: styles?.[UI.Footer], role: \"status\", \"aria-live\": \"polite\" }, props.footer)))));\n}\n","import { ko as dateFnsKo } from \"date-fns/locale\";\nimport { DateLib } from \"../classes/DateLib.js\";\n/** Korean locale extended with DayPicker-specific translations. */\nexport const ko = {\n ...dateFnsKo,\n labels: {\n labelDayButton: (date, modifiers, options, dateLib) => {\n const lib = dateLib ?? new DateLib(options);\n let label = lib.format(date, \"PPPP\");\n if (modifiers.today)\n label = `오늘, ${label}`;\n if (modifiers.selected)\n label = `${label}, 선택됨`;\n return label;\n },\n labelMonthDropdown: \"월 선택\",\n labelNext: \"다음 달로 이동\",\n labelPrevious: \"이전 달로 이동\",\n labelWeekNumber: (weekNumber) => `주 ${weekNumber}`,\n labelYearDropdown: \"연도 선택\",\n labelGrid: (date, options, dateLib) => (dateLib ?? new DateLib(options)).formatMonthYear(date),\n labelGridcell: (date, modifiers, options, dateLib) => {\n const lib = dateLib ?? new DateLib(options);\n let label = lib.format(date, \"PPPP\");\n if (modifiers?.today) {\n label = `오늘, ${label}`;\n }\n return label;\n },\n labelNav: \"탐색 모음\",\n labelWeekNumberHeader: \"주 번호\",\n labelWeekday: (date, options, dateLib) => (dateLib ?? new DateLib(options)).format(date, \"cccc\"),\n },\n};\n","!function(t,e){\"object\"==typeof exports&&\"undefined\"!=typeof module?module.exports=e():\"function\"==typeof define&&define.amd?define(e):(t=\"undefined\"!=typeof globalThis?globalThis:t||self).dayjs=e()}(this,(function(){\"use strict\";var t=1e3,e=6e4,n=36e5,r=\"millisecond\",i=\"second\",s=\"minute\",u=\"hour\",a=\"day\",o=\"week\",c=\"month\",f=\"quarter\",h=\"year\",d=\"date\",l=\"Invalid Date\",$=/^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/,y=/\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:\"en\",weekdays:\"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday\".split(\"_\"),months:\"January_February_March_April_May_June_July_August_September_October_November_December\".split(\"_\"),ordinal:function(t){var e=[\"th\",\"st\",\"nd\",\"rd\"],n=t%100;return\"[\"+t+(e[(n-20)%10]||e[n]||e[0])+\"]\"}},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:\"\"+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?\"+\":\"-\")+m(r,2,\"0\")+\":\"+m(i,2,\"0\")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,c),s=n-i<0,u=e.clone().add(r+(s?-1:1),c);return+(-(r+(n-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:c,y:h,w:o,d:a,D:d,h:u,m:s,s:i,ms:r,Q:f}[t]||String(t||\"\").toLowerCase().replace(/s$/,\"\")},u:function(t){return void 0===t}},g=\"en\",D={};D[g]=M;var p=\"$isDayjsObject\",S=function(t){return t instanceof _||!(!t||!t[p])},w=function t(e,n,r){var i;if(!e)return g;if(\"string\"==typeof e){var s=e.toLowerCase();D[s]&&(i=s),n&&(D[s]=n,i=s);var u=e.split(\"-\");if(!i&&u.length>1)return t(u[0])}else{var a=e.name;D[a]=e,i=a}return!r&&i&&(g=i),i||!r&&g},O=function(t,e){if(S(t))return t.clone();var n=\"object\"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},b=v;b.l=w,b.i=S,b.w=function(t,e){return O(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function M(t){this.$L=w(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[p]=!0}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(b.u(e))return new Date;if(e instanceof Date)return new Date(e);if(\"string\"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||\"0\").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return b},m.isValid=function(){return!(this.$d.toString()===l)},m.isSame=function(t,e){var n=O(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return O(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<O(t)},m.$g=function(t,e,n){return b.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!b.u(e)||e,f=b.p(t),l=function(t,e){var i=b.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(a)},$=function(t,e){return b.w(n.toDate()[t].apply(n.toDate(\"s\"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},y=this.$W,M=this.$M,m=this.$D,v=\"set\"+(this.$u?\"UTC\":\"\");switch(f){case h:return r?l(1,0):l(31,11);case c:return r?l(1,M):l(0,M+1);case o:var g=this.$locale().weekStart||0,D=(y<g?y+7:y)-g;return l(r?m-D:m+(6-D),M);case a:case d:return $(v+\"Hours\",0);case u:return $(v+\"Minutes\",1);case s:return $(v+\"Seconds\",2);case i:return $(v+\"Milliseconds\",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var n,o=b.p(t),f=\"set\"+(this.$u?\"UTC\":\"\"),l=(n={},n[a]=f+\"Date\",n[d]=f+\"Date\",n[c]=f+\"Month\",n[h]=f+\"FullYear\",n[u]=f+\"Hours\",n[s]=f+\"Minutes\",n[i]=f+\"Seconds\",n[r]=f+\"Milliseconds\",n)[o],$=o===a?this.$D+(e-this.$W):e;if(o===c||o===h){var y=this.clone().set(d,1);y.$d[l]($),y.init(),this.$d=y.set(d,Math.min(this.$D,y.daysInMonth())).$d}else l&&this.$d[l]($);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[b.p(t)]()},m.add=function(r,f){var d,l=this;r=Number(r);var $=b.p(f),y=function(t){var e=O(l);return b.w(e.date(e.date()+Math.round(t*r)),l)};if($===c)return this.set(c,this.$M+r);if($===h)return this.set(h,this.$y+r);if($===a)return y(1);if($===o)return y(7);var M=(d={},d[s]=e,d[u]=n,d[i]=t,d)[$]||1,m=this.$d.getTime()+r*M;return b.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||l;var r=t||\"YYYY-MM-DDTHH:mm:ssZ\",i=b.z(this),s=this.$H,u=this.$m,a=this.$M,o=n.weekdays,c=n.months,f=n.meridiem,h=function(t,n,i,s){return t&&(t[n]||t(e,r))||i[n].slice(0,s)},d=function(t){return b.s(s%12||12,t,\"0\")},$=f||function(t,e,n){var r=t<12?\"AM\":\"PM\";return n?r.toLowerCase():r};return r.replace(y,(function(t,r){return r||function(t){switch(t){case\"YY\":return String(e.$y).slice(-2);case\"YYYY\":return b.s(e.$y,4,\"0\");case\"M\":return a+1;case\"MM\":return b.s(a+1,2,\"0\");case\"MMM\":return h(n.monthsShort,a,c,3);case\"MMMM\":return h(c,a);case\"D\":return e.$D;case\"DD\":return b.s(e.$D,2,\"0\");case\"d\":return String(e.$W);case\"dd\":return h(n.weekdaysMin,e.$W,o,2);case\"ddd\":return h(n.weekdaysShort,e.$W,o,3);case\"dddd\":return o[e.$W];case\"H\":return String(s);case\"HH\":return b.s(s,2,\"0\");case\"h\":return d(1);case\"hh\":return d(2);case\"a\":return $(s,u,!0);case\"A\":return $(s,u,!1);case\"m\":return String(u);case\"mm\":return b.s(u,2,\"0\");case\"s\":return String(e.$s);case\"ss\":return b.s(e.$s,2,\"0\");case\"SSS\":return b.s(e.$ms,3,\"0\");case\"Z\":return i}return null}(t)||i.replace(\":\",\"\")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,d,l){var $,y=this,M=b.p(d),m=O(r),v=(m.utcOffset()-this.utcOffset())*e,g=this-m,D=function(){return b.m(y,m)};switch(M){case h:$=D()/12;break;case c:$=D();break;case f:$=D()/3;break;case o:$=(g-v)/6048e5;break;case a:$=(g-v)/864e5;break;case u:$=g/n;break;case s:$=g/e;break;case i:$=g/t;break;default:$=g}return l?$:b.a($)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return D[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=w(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return b.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},M}(),k=_.prototype;return O.prototype=k,[[\"$ms\",r],[\"$s\",i],[\"$m\",s],[\"$H\",u],[\"$W\",a],[\"$M\",c],[\"$y\",h],[\"$D\",d]].forEach((function(t){k[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),O.extend=function(t,e){return t.$i||(t(e,_,O),t.$i=!0),O},O.locale=w,O.isDayjs=S,O.unix=function(t){return O(1e3*t)},O.en=D[g],O.Ls=D,O.p={},O}));","import React, { useState, useEffect, useMemo } from \"react\";\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { DayPicker } from \"react-day-picker\";\nimport { ko } from \"react-day-picker/locale\";\nimport dayjs, { Dayjs } from \"dayjs\";\nimport { cn } from \"@/utils/cn\";\nimport \"react-day-picker/style.css\";\n\nexport interface DatePickerProps {\n value?: string;\n onChange?: (date: string) => void;\n label?: string;\n placeholder?: string;\n min?: string;\n max?: string;\n disabled?: boolean;\n error?: boolean;\n errorMessage?: string;\n helperText?: string;\n className?: string;\n}\n\nexport const DatePicker = React.forwardRef<HTMLDivElement, DatePickerProps>(\n (\n {\n value,\n onChange,\n label,\n placeholder = \"YYYY-MM-DD\",\n min,\n max,\n disabled = false,\n error = false,\n errorMessage,\n helperText,\n className,\n },\n ref,\n ) => {\n const [isOpen, setIsOpen] = useState(false);\n const [internalDate, setInternalDate] = useState<Dayjs | undefined>(\n value ? dayjs(value) : undefined,\n );\n\n useEffect(() => {\n if (value) {\n setInternalDate(dayjs(value));\n } else {\n setInternalDate(undefined);\n }\n }, [value]);\n\n const selected = useMemo(() => {\n return internalDate?.toDate();\n }, [internalDate]);\n\n const handleDayClick = (date: Date | undefined) => {\n if (!date) {\n setInternalDate(undefined);\n return;\n }\n\n const selectedDate = dayjs(date);\n setInternalDate(selectedDate);\n };\n\n const handleApply = () => {\n if (internalDate) {\n onChange?.(internalDate.format(\"YYYY-MM-DD\"));\n setIsOpen(false);\n }\n };\n\n const handleCancel = () => {\n setInternalDate(value ? dayjs(value) : undefined);\n setIsOpen(false);\n };\n\n const displayValue = useMemo(() => {\n if (!value) return \"\";\n return dayjs(value).format(\"YYYY-MM-DD\");\n }, [value]);\n\n const disabledDays = useMemo(() => {\n const disabled: any[] = [];\n if (min) {\n disabled.push({ before: dayjs(min).toDate() });\n }\n if (max) {\n disabled.push({ after: dayjs(max).toDate() });\n }\n return disabled.length > 0 ? disabled : undefined;\n }, [min, max]);\n\n return (\n <div ref={ref} className={cn(\"flex flex-col gap-1\", className)}>\n {label && (\n <label className=\"text-sm font-medium text-gray-700\">{label}</label>\n )}\n <PopoverPrimitive.Root\n open={isOpen && !disabled}\n onOpenChange={setIsOpen}\n >\n <PopoverPrimitive.Trigger asChild>\n <div className=\"relative\">\n <input\n type=\"text\"\n readOnly\n value={displayValue}\n placeholder={placeholder}\n disabled={disabled}\n className={cn(\n \"w-full h-10 px-3 border rounded bg-white text-sm\",\n \"hover:bg-gray-50 hover:border-gray-400\",\n \"focus:outline-none\",\n \"transition-all duration-150\",\n \"cursor-pointer\",\n error ? \"border-red-500\" : \"border-gray-300\",\n disabled &&\n cn(\n \"bg-gray-100 cursor-not-allowed\",\n \"hover:bg-gray-100 hover:border-gray-300\",\n ),\n )}\n />\n </div>\n </PopoverPrimitive.Trigger>\n\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n align=\"start\"\n sideOffset={5}\n className={cn(\n \"z-50 bg-white rounded-lg shadow-xl p-2\",\n \"border border-gray-200\",\n \"data-[state=open]:animate-in\",\n \"data-[state=closed]:animate-out\",\n \"data-[state=closed]:fade-out-0\",\n \"data-[state=open]:fade-in-0\",\n \"data-[state=closed]:zoom-out-95\",\n \"data-[state=open]:zoom-in-95\",\n \"data-[side=bottom]:slide-in-from-top-2\",\n \"data-[side=top]:slide-in-from-bottom-2\",\n )}\n >\n <div className=\"date-picker-calendar\">\n <DayPicker\n mode=\"single\"\n selected={selected}\n onSelect={handleDayClick}\n locale={ko}\n disabled={disabledDays}\n formatters={{\n formatCaption: (date) => {\n return `${date.getFullYear()}년 ${date.getMonth() + 1}월`;\n },\n }}\n />\n </div>\n\n {/* Footer */}\n <div\n className={cn(\n \"flex items-end justify-between mt-2 pt-2\",\n \"border-t border-gray-200\",\n )}\n >\n <div className=\"flex flex-col min-h-8\">\n {internalDate ? (\n <span className=\"text-xs text-gray-700\">\n {internalDate.format(\"YYYY-MM-DD\")}\n </span>\n ) : (\n <span className=\"text-xs text-red-500\">\n 날짜를 선택해 주세요.\n </span>\n )}\n </div>\n\n <div className=\"flex gap-2\">\n <button\n onClick={handleCancel}\n className={cn(\n \"w-15 h-8 rounded\",\n \"text-xs font-medium text-gray-700\",\n \"border border-gray-300\",\n \"transition-all duration-150\",\n \"active:scale-95\",\n \"hover:bg-gray-50\",\n )}\n >\n 취소\n </button>\n <button\n onClick={handleApply}\n disabled={!internalDate}\n className={cn(\n \"w-15 h-8 bg-blue-600 rounded\",\n \"text-xs text-white\",\n \"hover:bg-blue-700\",\n \"active:scale-95\",\n \"disabled:bg-gray-300 \",\n \"disabled:cursor-not-allowed\",\n \"disabled:active:scale-100\",\n \"transition-all duration-150\",\n )}\n >\n 적용\n </button>\n </div>\n </div>\n </PopoverPrimitive.Content>\n </PopoverPrimitive.Portal>\n </PopoverPrimitive.Root>\n\n {/* Helper/Error Text */}\n {(helperText || errorMessage) && (\n <div>\n {error && errorMessage ? (\n <p className=\"text-xs text-red-500\">{errorMessage}</p>\n ) : (\n helperText && (\n <p className=\"text-xs text-gray-500\">{helperText}</p>\n )\n )}\n </div>\n )}\n </div>\n );\n },\n);\n\nDatePicker.displayName = \"DatePicker\";\n","import React, { useState, useEffect, useMemo } from \"react\";\nimport * as PopoverPrimitive from \"@radix-ui/react-popover\";\nimport { DayPicker, DateRange as DayPickerDateRange } from \"react-day-picker\";\nimport { ko } from \"react-day-picker/locale\";\nimport dayjs, { Dayjs } from \"dayjs\";\nimport { cn } from \"@/utils/cn\";\nimport \"react-day-picker/style.css\";\n\nexport interface DateRange {\n start: string;\n end: string;\n}\n\nexport interface DateRangePickerProps {\n value?: DateRange;\n onChange?: (range: DateRange) => void;\n startLabel?: string;\n endLabel?: string;\n className?: string;\n}\n\ntype QuickSelectOption = {\n label: string;\n getValue: () => [Dayjs, Dayjs];\n};\n\nconst getQuickSelectOptions = (): QuickSelectOption[] => {\n const now = dayjs();\n\n return [\n {\n label: \"전체\",\n getValue: () => [dayjs(\"1970-01-01\"), dayjs(\"2099-12-31\")],\n },\n {\n label: \"오늘\",\n getValue: () => [now, now],\n },\n {\n label: \"내일\",\n getValue: () => [now.add(1, \"day\"), now.add(1, \"day\")],\n },\n {\n label: \"이번주\",\n getValue: () => [now.startOf(\"week\"), now.endOf(\"week\")],\n },\n {\n label: \"이번달\",\n getValue: () => [now.startOf(\"month\"), now.endOf(\"month\")],\n },\n {\n label: \"7일\",\n getValue: () => [now, now.add(6, \"day\")],\n },\n {\n label: \"30일\",\n getValue: () => [now, now.add(29, \"day\")],\n },\n {\n label: \"다음주\",\n getValue: () => [\n now.add(1, \"week\").startOf(\"week\"),\n now.add(1, \"week\").endOf(\"week\"),\n ],\n },\n {\n label: \"다음달\",\n getValue: () => [\n now.add(1, \"month\").startOf(\"month\"),\n now.add(1, \"month\").endOf(\"month\"),\n ],\n },\n ];\n};\n\nexport const DateRangePicker = React.forwardRef<\n HTMLDivElement,\n DateRangePickerProps\n>(\n (\n {\n value,\n onChange,\n startLabel = \"시작일자\",\n endLabel = \"종료일자\",\n className,\n },\n ref,\n ) => {\n const [isOpen, setIsOpen] = useState(false);\n const [internalRange, setInternalRange] = useState<\n [Dayjs | undefined, Dayjs | undefined]\n >([\n value?.start ? dayjs(value.start) : undefined,\n value?.end ? dayjs(value.end) : undefined,\n ]);\n\n useEffect(() => {\n if (value) {\n setInternalRange([\n value.start ? dayjs(value.start) : undefined,\n value.end ? dayjs(value.end) : undefined,\n ]);\n }\n }, [value]);\n\n const [fromDay, toDay] = internalRange;\n\n const selected: DayPickerDateRange | undefined = useMemo(() => {\n if (!fromDay) return undefined;\n return {\n from: fromDay.toDate(),\n to: toDay?.toDate(),\n };\n }, [fromDay, toDay]);\n\n const handleQuickSelect = (option: QuickSelectOption) => {\n const [start, end] = option.getValue();\n setInternalRange([start, end]);\n };\n\n const handleDayClick = (range: DayPickerDateRange | undefined) => {\n if (!range) {\n setInternalRange([undefined, undefined]);\n return;\n }\n\n const from = range.from ? dayjs(range.from) : undefined;\n const to = range.to ? dayjs(range.to) : undefined;\n\n setInternalRange([from, to]);\n };\n\n const handleApply = () => {\n if (fromDay && toDay) {\n onChange?.({\n start: fromDay.format(\"YYYY-MM-DD\"),\n end: toDay.format(\"YYYY-MM-DD\"),\n });\n setIsOpen(false);\n }\n };\n\n const handleCancel = () => {\n setInternalRange([\n value?.start ? dayjs(value.start) : undefined,\n value?.end ? dayjs(value.end) : undefined,\n ]);\n setIsOpen(false);\n };\n\n const numberOfDays = useMemo(() => {\n if (!fromDay || !toDay) return undefined;\n return toDay.diff(fromDay, \"day\") + 1;\n }, [fromDay, toDay]);\n\n const displayValue = useMemo(() => {\n if (!value?.start || !value?.end) {\n return { start: \"\", end: \"\" };\n }\n return {\n start: dayjs(value.start).format(\"YYYY-MM-DD\"),\n end: dayjs(value.end).format(\"YYYY-MM-DD\"),\n };\n }, [value]);\n\n return (\n <PopoverPrimitive.Root open={isOpen} onOpenChange={setIsOpen}>\n <PopoverPrimitive.Trigger asChild>\n <div ref={ref} className={cn(\"flex items-center gap-0\", className)}>\n <div className=\"relative flex-1\">\n <label\n className={cn(\n \"absolute left-3 top-1/2 -translate-y-1/2\",\n \"text-xs text-gray-500\",\n \"pointer-events-none\",\n )}\n >\n {startLabel}\n </label>\n <input\n type=\"text\"\n readOnly\n value={displayValue.start}\n placeholder=\"YYYY-MM-DD\"\n className={cn(\n \"w-full h-10 pl-[59px] pr-3 bg-white text-sm\",\n \"focus:outline-none\",\n \"border border-gray-300 border-r-0 rounded-l\",\n \"hover:bg-gray-50 hover:border-gray-400\",\n \"transition-all duration-150\",\n \"cursor-pointer\",\n )}\n />\n </div>\n <div className=\"relative flex-1\">\n <label\n className={cn(\n \"absolute left-3 top-1/2 -translate-y-1/2\",\n \"text-xs text-gray-500\",\n \"pointer-events-none\",\n )}\n >\n {endLabel}\n </label>\n <input\n type=\"text\"\n readOnly\n value={displayValue.end}\n placeholder=\"YYYY-MM-DD\"\n className={cn(\n \"w-full h-10 pl-[59px] pr-3 bg-white\",\n \"text-sm\",\n \"border border-gray-300 rounded-r\",\n \"hover:bg-gray-50 hover:border-gray-400\",\n \"focus:outline-none\",\n \"transition-all duration-150\",\n \"cursor-pointer\",\n )}\n />\n </div>\n </div>\n </PopoverPrimitive.Trigger>\n\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n align=\"start\"\n sideOffset={5}\n className={cn(\n \"z-50 p-2 bg-white rounded-lg\",\n \"border border-gray-200\",\n \"shadow-xl\",\n \"data-[state=open]:animate-in\",\n \"data-[state=closed]:animate-out\",\n \"data-[state=closed]:fade-out-0\",\n \"data-[state=open]:fade-in-0\",\n \"data-[state=closed]:zoom-out-95\",\n \"data-[state=open]:zoom-in-95\",\n \"data-[side=bottom]:slide-in-from-top-2\",\n \"data-[side=top]:slide-in-from-bottom-2\",\n )}\n >\n <div className=\"flex gap-2\">\n {/* Quick Select Buttons */}\n <div className=\"flex flex-col border-r border-gray-200 pr-2\">\n {getQuickSelectOptions().map((option) => (\n <button\n key={option.label}\n onClick={() => handleQuickSelect(option)}\n className={cn(\n \"w-[70px] h-[26px] px-2\",\n \"text-left text-xs text-gray-700\",\n \"border-b border-gray-200 rounded-sm\",\n \"last:border-b-0\",\n \"transition-all duration-150\",\n \"hover:bg-blue-50\",\n \"hover:font-medium\",\n \"hover:text-blue-600\",\n )}\n >\n {option.label}\n </button>\n ))}\n </div>\n {/* Calendar */}\n <div className=\"date-range-picker-calendar\">\n <DayPicker\n mode=\"range\"\n selected={selected}\n onSelect={handleDayClick}\n numberOfMonths={2}\n locale={ko}\n formatters={{\n formatCaption: (date) => {\n return `${date.getFullYear()}년 ${date.getMonth() + 1}월`;\n },\n }}\n />\n </div>\n </div>\n\n {/* Footer */}\n <div\n className={cn(\n \"flex items-end justify-between mt-2 pt-2\",\n \"border-t border-gray-200\",\n )}\n >\n <div className=\"flex flex-col min-h-8\">\n {!fromDay || !toDay ? (\n <span className=\"text-xs text-red-500\">\n 종료일자를 선택해 주세요.\n </span>\n ) : (\n <>\n <span className=\"text-xs text-gray-700\">\n {fromDay.format(\"YYYY-MM-DD\")} ~{\" \"}\n {toDay.format(\"YYYY-MM-DD\")}\n </span>\n <span className=\"text-xs text-gray-500\">\n ({numberOfDays}일간)\n </span>\n </>\n )}\n </div>\n\n <div className=\"flex gap-2\">\n <button\n onClick={handleCancel}\n className={cn(\n \"w-15 h-8\",\n \"border border-gray-300 rounded\",\n \"text-xs font-medium text-gray-700\",\n \"transition-all duration-150\",\n \"hover:bg-gray-50 active:scale-95\",\n )}\n >\n 취소\n </button>\n <button\n onClick={handleApply}\n disabled={!fromDay || !toDay}\n className={cn(\n \"w-15 h-8\",\n \"bg-blue-600 rounded\",\n \"text-xs font-medium text-cms-white\",\n \"hover:bg-blue-700 active:scale-95\",\n \"disabled:bg-gray-300\",\n \"disabled:active:scale-100\",\n \"disabled:cursor-not-allowed\",\n \"transition-all duration-150\",\n )}\n >\n 적용\n </button>\n </div>\n </div>\n </PopoverPrimitive.Content>\n </PopoverPrimitive.Portal>\n </PopoverPrimitive.Root>\n );\n },\n);\n\nDateRangePicker.displayName = \"DateRangePicker\";\n","// packages/react/use-previous/src/use-previous.tsx\nimport * as React from \"react\";\nfunction usePrevious(value) {\n const ref = React.useRef({ value, previous: value });\n return React.useMemo(() => {\n if (ref.current.value !== value) {\n ref.current.previous = ref.current.value;\n ref.current.value = value;\n }\n return ref.current.previous;\n }, [value]);\n}\nexport {\n usePrevious\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/switch.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { usePrevious } from \"@radix-ui/react-use-previous\";\nimport { useSize } from \"@radix-ui/react-use-size\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { jsx, jsxs } from \"react/jsx-runtime\";\nvar SWITCH_NAME = \"Switch\";\nvar [createSwitchContext, createSwitchScope] = createContextScope(SWITCH_NAME);\nvar [SwitchProvider, useSwitchContext] = createSwitchContext(SWITCH_NAME);\nvar Switch = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeSwitch,\n name,\n checked: checkedProp,\n defaultChecked,\n required,\n disabled,\n value = \"on\",\n onCheckedChange,\n form,\n ...switchProps\n } = props;\n const [button, setButton] = React.useState(null);\n const composedRefs = useComposedRefs(forwardedRef, (node) => setButton(node));\n const hasConsumerStoppedPropagationRef = React.useRef(false);\n const isFormControl = button ? form || !!button.closest(\"form\") : true;\n const [checked, setChecked] = useControllableState({\n prop: checkedProp,\n defaultProp: defaultChecked ?? false,\n onChange: onCheckedChange,\n caller: SWITCH_NAME\n });\n return /* @__PURE__ */ jsxs(SwitchProvider, { scope: __scopeSwitch, checked, disabled, children: [\n /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n role: \"switch\",\n \"aria-checked\": checked,\n \"aria-required\": required,\n \"data-state\": getState(checked),\n \"data-disabled\": disabled ? \"\" : void 0,\n disabled,\n value,\n ...switchProps,\n ref: composedRefs,\n onClick: composeEventHandlers(props.onClick, (event) => {\n setChecked((prevChecked) => !prevChecked);\n if (isFormControl) {\n hasConsumerStoppedPropagationRef.current = event.isPropagationStopped();\n if (!hasConsumerStoppedPropagationRef.current) event.stopPropagation();\n }\n })\n }\n ),\n isFormControl && /* @__PURE__ */ jsx(\n SwitchBubbleInput,\n {\n control: button,\n bubbles: !hasConsumerStoppedPropagationRef.current,\n name,\n value,\n checked,\n required,\n disabled,\n form,\n style: { transform: \"translateX(-100%)\" }\n }\n )\n ] });\n }\n);\nSwitch.displayName = SWITCH_NAME;\nvar THUMB_NAME = \"SwitchThumb\";\nvar SwitchThumb = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeSwitch, ...thumbProps } = props;\n const context = useSwitchContext(THUMB_NAME, __scopeSwitch);\n return /* @__PURE__ */ jsx(\n Primitive.span,\n {\n \"data-state\": getState(context.checked),\n \"data-disabled\": context.disabled ? \"\" : void 0,\n ...thumbProps,\n ref: forwardedRef\n }\n );\n }\n);\nSwitchThumb.displayName = THUMB_NAME;\nvar BUBBLE_INPUT_NAME = \"SwitchBubbleInput\";\nvar SwitchBubbleInput = React.forwardRef(\n ({\n __scopeSwitch,\n control,\n checked,\n bubbles = true,\n ...props\n }, forwardedRef) => {\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(ref, forwardedRef);\n const prevChecked = usePrevious(checked);\n const controlSize = useSize(control);\n React.useEffect(() => {\n const input = ref.current;\n if (!input) return;\n const inputProto = window.HTMLInputElement.prototype;\n const descriptor = Object.getOwnPropertyDescriptor(\n inputProto,\n \"checked\"\n );\n const setChecked = descriptor.set;\n if (prevChecked !== checked && setChecked) {\n const event = new Event(\"click\", { bubbles });\n setChecked.call(input, checked);\n input.dispatchEvent(event);\n }\n }, [prevChecked, checked, bubbles]);\n return /* @__PURE__ */ jsx(\n \"input\",\n {\n type: \"checkbox\",\n \"aria-hidden\": true,\n defaultChecked: checked,\n ...props,\n tabIndex: -1,\n ref: composedRefs,\n style: {\n ...props.style,\n ...controlSize,\n position: \"absolute\",\n pointerEvents: \"none\",\n opacity: 0,\n margin: 0\n }\n }\n );\n }\n);\nSwitchBubbleInput.displayName = BUBBLE_INPUT_NAME;\nfunction getState(checked) {\n return checked ? \"checked\" : \"unchecked\";\n}\nvar Root = Switch;\nvar Thumb = SwitchThumb;\nexport {\n Root,\n Switch,\n SwitchThumb,\n Thumb,\n createSwitchScope\n};\n//# sourceMappingURL=index.mjs.map\n","import React from \"react\";\nimport * as SwitchPrimitives from \"@radix-ui/react-switch\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"@/utils/cn\";\n\nconst switchVariants = cva(\n cn(\n \"peer inline-flex items-center transition-colors \",\n \"rounded-full border-2 border-transparent box-border\",\n \"h-6 w-10 shrink-0\",\n \"cursor-pointer\",\n \"focus-visible:outline-none\",\n \"disabled:cursor-not-allowed disabled:opacity-50\",\n \"data-[state=unchecked]:bg-cms-gray-300\",\n ),\n\n {\n variants: {\n variant: {\n default: \"data-[state=checked]:bg-cms-primary-200\",\n green: \"data-[state=checked]:bg-cms-green-500\",\n black: \"data-[state=checked]:bg-cms-black\",\n blue: \"data-[state=checked]:bg-cms-blue-700\",\n red: \"data-[state=checked]:bg-cms-red-400\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n },\n);\n\nexport interface SwitchProps\n extends\n React.ComponentPropsWithoutRef<typeof SwitchPrimitives.Root>,\n VariantProps<typeof switchVariants> {}\n\nconst Switch = React.forwardRef<\n React.ElementRef<typeof SwitchPrimitives.Root>,\n SwitchProps\n>(({ className, variant, ...props }, ref) => (\n <SwitchPrimitives.Root\n className={cn(switchVariants({ variant }), className)}\n {...props}\n ref={ref}\n >\n <SwitchPrimitives.Thumb\n className={cn(\n \"pointer-events-none block rounded-full ring-0\",\n \"bg-cms-white shadow-lg\",\n \"h-5 w-5\",\n \"data-[state=unchecked]:translate-x-0\",\n \"data-[state=checked]:translate-x-4\",\n \"transition-transform\",\n )}\n />\n </SwitchPrimitives.Root>\n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","\"use client\";\n\n// src/collection-legacy.tsx\nimport React from \"react\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createSlot } from \"@radix-ui/react-slot\";\nimport { jsx } from \"react/jsx-runtime\";\nfunction createCollection(name) {\n const PROVIDER_NAME = name + \"CollectionProvider\";\n const [createCollectionContext, createCollectionScope] = createContextScope(PROVIDER_NAME);\n const [CollectionProviderImpl, useCollectionContext] = createCollectionContext(\n PROVIDER_NAME,\n { collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }\n );\n const CollectionProvider = (props) => {\n const { scope, children } = props;\n const ref = React.useRef(null);\n const itemMap = React.useRef(/* @__PURE__ */ new Map()).current;\n return /* @__PURE__ */ jsx(CollectionProviderImpl, { scope, itemMap, collectionRef: ref, children });\n };\n CollectionProvider.displayName = PROVIDER_NAME;\n const COLLECTION_SLOT_NAME = name + \"CollectionSlot\";\n const CollectionSlotImpl = createSlot(COLLECTION_SLOT_NAME);\n const CollectionSlot = React.forwardRef(\n (props, forwardedRef) => {\n const { scope, children } = props;\n const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);\n const composedRefs = useComposedRefs(forwardedRef, context.collectionRef);\n return /* @__PURE__ */ jsx(CollectionSlotImpl, { ref: composedRefs, children });\n }\n );\n CollectionSlot.displayName = COLLECTION_SLOT_NAME;\n const ITEM_SLOT_NAME = name + \"CollectionItemSlot\";\n const ITEM_DATA_ATTR = \"data-radix-collection-item\";\n const CollectionItemSlotImpl = createSlot(ITEM_SLOT_NAME);\n const CollectionItemSlot = React.forwardRef(\n (props, forwardedRef) => {\n const { scope, children, ...itemData } = props;\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const context = useCollectionContext(ITEM_SLOT_NAME, scope);\n React.useEffect(() => {\n context.itemMap.set(ref, { ref, ...itemData });\n return () => void context.itemMap.delete(ref);\n });\n return /* @__PURE__ */ jsx(CollectionItemSlotImpl, { ...{ [ITEM_DATA_ATTR]: \"\" }, ref: composedRefs, children });\n }\n );\n CollectionItemSlot.displayName = ITEM_SLOT_NAME;\n function useCollection(scope) {\n const context = useCollectionContext(name + \"CollectionConsumer\", scope);\n const getItems = React.useCallback(() => {\n const collectionNode = context.collectionRef.current;\n if (!collectionNode) return [];\n const orderedNodes = Array.from(collectionNode.querySelectorAll(`[${ITEM_DATA_ATTR}]`));\n const items = Array.from(context.itemMap.values());\n const orderedItems = items.sort(\n (a, b) => orderedNodes.indexOf(a.ref.current) - orderedNodes.indexOf(b.ref.current)\n );\n return orderedItems;\n }, [context.collectionRef, context.itemMap]);\n return getItems;\n }\n return [\n { Provider: CollectionProvider, Slot: CollectionSlot, ItemSlot: CollectionItemSlot },\n useCollection,\n createCollectionScope\n ];\n}\n\n// src/collection.tsx\nimport React2 from \"react\";\nimport { createContextScope as createContextScope2 } from \"@radix-ui/react-context\";\nimport { useComposedRefs as useComposedRefs2 } from \"@radix-ui/react-compose-refs\";\nimport { createSlot as createSlot2 } from \"@radix-ui/react-slot\";\n\n// src/ordered-dictionary.ts\nvar __instanciated = /* @__PURE__ */ new WeakMap();\nvar OrderedDict = class _OrderedDict extends Map {\n #keys;\n constructor(entries) {\n super(entries);\n this.#keys = [...super.keys()];\n __instanciated.set(this, true);\n }\n set(key, value) {\n if (__instanciated.get(this)) {\n if (this.has(key)) {\n this.#keys[this.#keys.indexOf(key)] = key;\n } else {\n this.#keys.push(key);\n }\n }\n super.set(key, value);\n return this;\n }\n insert(index, key, value) {\n const has = this.has(key);\n const length = this.#keys.length;\n const relativeIndex = toSafeInteger(index);\n let actualIndex = relativeIndex >= 0 ? relativeIndex : length + relativeIndex;\n const safeIndex = actualIndex < 0 || actualIndex >= length ? -1 : actualIndex;\n if (safeIndex === this.size || has && safeIndex === this.size - 1 || safeIndex === -1) {\n this.set(key, value);\n return this;\n }\n const size = this.size + (has ? 0 : 1);\n if (relativeIndex < 0) {\n actualIndex++;\n }\n const keys = [...this.#keys];\n let nextValue;\n let shouldSkip = false;\n for (let i = actualIndex; i < size; i++) {\n if (actualIndex === i) {\n let nextKey = keys[i];\n if (keys[i] === key) {\n nextKey = keys[i + 1];\n }\n if (has) {\n this.delete(key);\n }\n nextValue = this.get(nextKey);\n this.set(key, value);\n } else {\n if (!shouldSkip && keys[i - 1] === key) {\n shouldSkip = true;\n }\n const currentKey = keys[shouldSkip ? i : i - 1];\n const currentValue = nextValue;\n nextValue = this.get(currentKey);\n this.delete(currentKey);\n this.set(currentKey, currentValue);\n }\n }\n return this;\n }\n with(index, key, value) {\n const copy = new _OrderedDict(this);\n copy.insert(index, key, value);\n return copy;\n }\n before(key) {\n const index = this.#keys.indexOf(key) - 1;\n if (index < 0) {\n return void 0;\n }\n return this.entryAt(index);\n }\n /**\n * Sets a new key-value pair at the position before the given key.\n */\n setBefore(key, newKey, value) {\n const index = this.#keys.indexOf(key);\n if (index === -1) {\n return this;\n }\n return this.insert(index, newKey, value);\n }\n after(key) {\n let index = this.#keys.indexOf(key);\n index = index === -1 || index === this.size - 1 ? -1 : index + 1;\n if (index === -1) {\n return void 0;\n }\n return this.entryAt(index);\n }\n /**\n * Sets a new key-value pair at the position after the given key.\n */\n setAfter(key, newKey, value) {\n const index = this.#keys.indexOf(key);\n if (index === -1) {\n return this;\n }\n return this.insert(index + 1, newKey, value);\n }\n first() {\n return this.entryAt(0);\n }\n last() {\n return this.entryAt(-1);\n }\n clear() {\n this.#keys = [];\n return super.clear();\n }\n delete(key) {\n const deleted = super.delete(key);\n if (deleted) {\n this.#keys.splice(this.#keys.indexOf(key), 1);\n }\n return deleted;\n }\n deleteAt(index) {\n const key = this.keyAt(index);\n if (key !== void 0) {\n return this.delete(key);\n }\n return false;\n }\n at(index) {\n const key = at(this.#keys, index);\n if (key !== void 0) {\n return this.get(key);\n }\n }\n entryAt(index) {\n const key = at(this.#keys, index);\n if (key !== void 0) {\n return [key, this.get(key)];\n }\n }\n indexOf(key) {\n return this.#keys.indexOf(key);\n }\n keyAt(index) {\n return at(this.#keys, index);\n }\n from(key, offset) {\n const index = this.indexOf(key);\n if (index === -1) {\n return void 0;\n }\n let dest = index + offset;\n if (dest < 0) dest = 0;\n if (dest >= this.size) dest = this.size - 1;\n return this.at(dest);\n }\n keyFrom(key, offset) {\n const index = this.indexOf(key);\n if (index === -1) {\n return void 0;\n }\n let dest = index + offset;\n if (dest < 0) dest = 0;\n if (dest >= this.size) dest = this.size - 1;\n return this.keyAt(dest);\n }\n find(predicate, thisArg) {\n let index = 0;\n for (const entry of this) {\n if (Reflect.apply(predicate, thisArg, [entry, index, this])) {\n return entry;\n }\n index++;\n }\n return void 0;\n }\n findIndex(predicate, thisArg) {\n let index = 0;\n for (const entry of this) {\n if (Reflect.apply(predicate, thisArg, [entry, index, this])) {\n return index;\n }\n index++;\n }\n return -1;\n }\n filter(predicate, thisArg) {\n const entries = [];\n let index = 0;\n for (const entry of this) {\n if (Reflect.apply(predicate, thisArg, [entry, index, this])) {\n entries.push(entry);\n }\n index++;\n }\n return new _OrderedDict(entries);\n }\n map(callbackfn, thisArg) {\n const entries = [];\n let index = 0;\n for (const entry of this) {\n entries.push([entry[0], Reflect.apply(callbackfn, thisArg, [entry, index, this])]);\n index++;\n }\n return new _OrderedDict(entries);\n }\n reduce(...args) {\n const [callbackfn, initialValue] = args;\n let index = 0;\n let accumulator = initialValue ?? this.at(0);\n for (const entry of this) {\n if (index === 0 && args.length === 1) {\n accumulator = entry;\n } else {\n accumulator = Reflect.apply(callbackfn, this, [accumulator, entry, index, this]);\n }\n index++;\n }\n return accumulator;\n }\n reduceRight(...args) {\n const [callbackfn, initialValue] = args;\n let accumulator = initialValue ?? this.at(-1);\n for (let index = this.size - 1; index >= 0; index--) {\n const entry = this.at(index);\n if (index === this.size - 1 && args.length === 1) {\n accumulator = entry;\n } else {\n accumulator = Reflect.apply(callbackfn, this, [accumulator, entry, index, this]);\n }\n }\n return accumulator;\n }\n toSorted(compareFn) {\n const entries = [...this.entries()].sort(compareFn);\n return new _OrderedDict(entries);\n }\n toReversed() {\n const reversed = new _OrderedDict();\n for (let index = this.size - 1; index >= 0; index--) {\n const key = this.keyAt(index);\n const element = this.get(key);\n reversed.set(key, element);\n }\n return reversed;\n }\n toSpliced(...args) {\n const entries = [...this.entries()];\n entries.splice(...args);\n return new _OrderedDict(entries);\n }\n slice(start, end) {\n const result = new _OrderedDict();\n let stop = this.size - 1;\n if (start === void 0) {\n return result;\n }\n if (start < 0) {\n start = start + this.size;\n }\n if (end !== void 0 && end > 0) {\n stop = end - 1;\n }\n for (let index = start; index <= stop; index++) {\n const key = this.keyAt(index);\n const element = this.get(key);\n result.set(key, element);\n }\n return result;\n }\n every(predicate, thisArg) {\n let index = 0;\n for (const entry of this) {\n if (!Reflect.apply(predicate, thisArg, [entry, index, this])) {\n return false;\n }\n index++;\n }\n return true;\n }\n some(predicate, thisArg) {\n let index = 0;\n for (const entry of this) {\n if (Reflect.apply(predicate, thisArg, [entry, index, this])) {\n return true;\n }\n index++;\n }\n return false;\n }\n};\nfunction at(array, index) {\n if (\"at\" in Array.prototype) {\n return Array.prototype.at.call(array, index);\n }\n const actualIndex = toSafeIndex(array, index);\n return actualIndex === -1 ? void 0 : array[actualIndex];\n}\nfunction toSafeIndex(array, index) {\n const length = array.length;\n const relativeIndex = toSafeInteger(index);\n const actualIndex = relativeIndex >= 0 ? relativeIndex : length + relativeIndex;\n return actualIndex < 0 || actualIndex >= length ? -1 : actualIndex;\n}\nfunction toSafeInteger(number) {\n return number !== number || number === 0 ? 0 : Math.trunc(number);\n}\n\n// src/collection.tsx\nimport { jsx as jsx2 } from \"react/jsx-runtime\";\nfunction createCollection2(name) {\n const PROVIDER_NAME = name + \"CollectionProvider\";\n const [createCollectionContext, createCollectionScope] = createContextScope2(PROVIDER_NAME);\n const [CollectionContextProvider, useCollectionContext] = createCollectionContext(\n PROVIDER_NAME,\n {\n collectionElement: null,\n collectionRef: { current: null },\n collectionRefObject: { current: null },\n itemMap: new OrderedDict(),\n setItemMap: () => void 0\n }\n );\n const CollectionProvider = ({ state, ...props }) => {\n return state ? /* @__PURE__ */ jsx2(CollectionProviderImpl, { ...props, state }) : /* @__PURE__ */ jsx2(CollectionInit, { ...props });\n };\n CollectionProvider.displayName = PROVIDER_NAME;\n const CollectionInit = (props) => {\n const state = useInitCollection();\n return /* @__PURE__ */ jsx2(CollectionProviderImpl, { ...props, state });\n };\n CollectionInit.displayName = PROVIDER_NAME + \"Init\";\n const CollectionProviderImpl = (props) => {\n const { scope, children, state } = props;\n const ref = React2.useRef(null);\n const [collectionElement, setCollectionElement] = React2.useState(\n null\n );\n const composeRefs = useComposedRefs2(ref, setCollectionElement);\n const [itemMap, setItemMap] = state;\n React2.useEffect(() => {\n if (!collectionElement) return;\n const observer = getChildListObserver(() => {\n });\n observer.observe(collectionElement, {\n childList: true,\n subtree: true\n });\n return () => {\n observer.disconnect();\n };\n }, [collectionElement]);\n return /* @__PURE__ */ jsx2(\n CollectionContextProvider,\n {\n scope,\n itemMap,\n setItemMap,\n collectionRef: composeRefs,\n collectionRefObject: ref,\n collectionElement,\n children\n }\n );\n };\n CollectionProviderImpl.displayName = PROVIDER_NAME + \"Impl\";\n const COLLECTION_SLOT_NAME = name + \"CollectionSlot\";\n const CollectionSlotImpl = createSlot2(COLLECTION_SLOT_NAME);\n const CollectionSlot = React2.forwardRef(\n (props, forwardedRef) => {\n const { scope, children } = props;\n const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);\n const composedRefs = useComposedRefs2(forwardedRef, context.collectionRef);\n return /* @__PURE__ */ jsx2(CollectionSlotImpl, { ref: composedRefs, children });\n }\n );\n CollectionSlot.displayName = COLLECTION_SLOT_NAME;\n const ITEM_SLOT_NAME = name + \"CollectionItemSlot\";\n const ITEM_DATA_ATTR = \"data-radix-collection-item\";\n const CollectionItemSlotImpl = createSlot2(ITEM_SLOT_NAME);\n const CollectionItemSlot = React2.forwardRef(\n (props, forwardedRef) => {\n const { scope, children, ...itemData } = props;\n const ref = React2.useRef(null);\n const [element, setElement] = React2.useState(null);\n const composedRefs = useComposedRefs2(forwardedRef, ref, setElement);\n const context = useCollectionContext(ITEM_SLOT_NAME, scope);\n const { setItemMap } = context;\n const itemDataRef = React2.useRef(itemData);\n if (!shallowEqual(itemDataRef.current, itemData)) {\n itemDataRef.current = itemData;\n }\n const memoizedItemData = itemDataRef.current;\n React2.useEffect(() => {\n const itemData2 = memoizedItemData;\n setItemMap((map) => {\n if (!element) {\n return map;\n }\n if (!map.has(element)) {\n map.set(element, { ...itemData2, element });\n return map.toSorted(sortByDocumentPosition);\n }\n return map.set(element, { ...itemData2, element }).toSorted(sortByDocumentPosition);\n });\n return () => {\n setItemMap((map) => {\n if (!element || !map.has(element)) {\n return map;\n }\n map.delete(element);\n return new OrderedDict(map);\n });\n };\n }, [element, memoizedItemData, setItemMap]);\n return /* @__PURE__ */ jsx2(CollectionItemSlotImpl, { ...{ [ITEM_DATA_ATTR]: \"\" }, ref: composedRefs, children });\n }\n );\n CollectionItemSlot.displayName = ITEM_SLOT_NAME;\n function useInitCollection() {\n return React2.useState(new OrderedDict());\n }\n function useCollection(scope) {\n const { itemMap } = useCollectionContext(name + \"CollectionConsumer\", scope);\n return itemMap;\n }\n const functions = {\n createCollectionScope,\n useCollection,\n useInitCollection\n };\n return [\n { Provider: CollectionProvider, Slot: CollectionSlot, ItemSlot: CollectionItemSlot },\n functions\n ];\n}\nfunction shallowEqual(a, b) {\n if (a === b) return true;\n if (typeof a !== \"object\" || typeof b !== \"object\") return false;\n if (a == null || b == null) return false;\n const keysA = Object.keys(a);\n const keysB = Object.keys(b);\n if (keysA.length !== keysB.length) return false;\n for (const key of keysA) {\n if (!Object.prototype.hasOwnProperty.call(b, key)) return false;\n if (a[key] !== b[key]) return false;\n }\n return true;\n}\nfunction isElementPreceding(a, b) {\n return !!(b.compareDocumentPosition(a) & Node.DOCUMENT_POSITION_PRECEDING);\n}\nfunction sortByDocumentPosition(a, b) {\n return !a[1].element || !b[1].element ? 0 : isElementPreceding(a[1].element, b[1].element) ? -1 : 1;\n}\nfunction getChildListObserver(callback) {\n const observer = new MutationObserver((mutationsList) => {\n for (const mutation of mutationsList) {\n if (mutation.type === \"childList\") {\n callback();\n return;\n }\n }\n });\n return observer;\n}\nexport {\n createCollection,\n createCollection2 as unstable_createCollection\n};\n//# sourceMappingURL=index.mjs.map\n","// packages/react/direction/src/direction.tsx\nimport * as React from \"react\";\nimport { jsx } from \"react/jsx-runtime\";\nvar DirectionContext = React.createContext(void 0);\nvar DirectionProvider = (props) => {\n const { dir, children } = props;\n return /* @__PURE__ */ jsx(DirectionContext.Provider, { value: dir, children });\n};\nfunction useDirection(localDir) {\n const globalDir = React.useContext(DirectionContext);\n return localDir || globalDir || \"ltr\";\n}\nvar Provider = DirectionProvider;\nexport {\n DirectionProvider,\n Provider,\n useDirection\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/roving-focus-group.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { createCollection } from \"@radix-ui/react-collection\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useId } from \"@radix-ui/react-id\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { useDirection } from \"@radix-ui/react-direction\";\nimport { jsx } from \"react/jsx-runtime\";\nvar ENTRY_FOCUS = \"rovingFocusGroup.onEntryFocus\";\nvar EVENT_OPTIONS = { bubbles: false, cancelable: true };\nvar GROUP_NAME = \"RovingFocusGroup\";\nvar [Collection, useCollection, createCollectionScope] = createCollection(GROUP_NAME);\nvar [createRovingFocusGroupContext, createRovingFocusGroupScope] = createContextScope(\n GROUP_NAME,\n [createCollectionScope]\n);\nvar [RovingFocusProvider, useRovingFocusContext] = createRovingFocusGroupContext(GROUP_NAME);\nvar RovingFocusGroup = React.forwardRef(\n (props, forwardedRef) => {\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsx(RovingFocusGroupImpl, { ...props, ref: forwardedRef }) }) });\n }\n);\nRovingFocusGroup.displayName = GROUP_NAME;\nvar RovingFocusGroupImpl = React.forwardRef((props, forwardedRef) => {\n const {\n __scopeRovingFocusGroup,\n orientation,\n loop = false,\n dir,\n currentTabStopId: currentTabStopIdProp,\n defaultCurrentTabStopId,\n onCurrentTabStopIdChange,\n onEntryFocus,\n preventScrollOnEntryFocus = false,\n ...groupProps\n } = props;\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const direction = useDirection(dir);\n const [currentTabStopId, setCurrentTabStopId] = useControllableState({\n prop: currentTabStopIdProp,\n defaultProp: defaultCurrentTabStopId ?? null,\n onChange: onCurrentTabStopIdChange,\n caller: GROUP_NAME\n });\n const [isTabbingBackOut, setIsTabbingBackOut] = React.useState(false);\n const handleEntryFocus = useCallbackRef(onEntryFocus);\n const getItems = useCollection(__scopeRovingFocusGroup);\n const isClickFocusRef = React.useRef(false);\n const [focusableItemsCount, setFocusableItemsCount] = React.useState(0);\n React.useEffect(() => {\n const node = ref.current;\n if (node) {\n node.addEventListener(ENTRY_FOCUS, handleEntryFocus);\n return () => node.removeEventListener(ENTRY_FOCUS, handleEntryFocus);\n }\n }, [handleEntryFocus]);\n return /* @__PURE__ */ jsx(\n RovingFocusProvider,\n {\n scope: __scopeRovingFocusGroup,\n orientation,\n dir: direction,\n loop,\n currentTabStopId,\n onItemFocus: React.useCallback(\n (tabStopId) => setCurrentTabStopId(tabStopId),\n [setCurrentTabStopId]\n ),\n onItemShiftTab: React.useCallback(() => setIsTabbingBackOut(true), []),\n onFocusableItemAdd: React.useCallback(\n () => setFocusableItemsCount((prevCount) => prevCount + 1),\n []\n ),\n onFocusableItemRemove: React.useCallback(\n () => setFocusableItemsCount((prevCount) => prevCount - 1),\n []\n ),\n children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n tabIndex: isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0,\n \"data-orientation\": orientation,\n ...groupProps,\n ref: composedRefs,\n style: { outline: \"none\", ...props.style },\n onMouseDown: composeEventHandlers(props.onMouseDown, () => {\n isClickFocusRef.current = true;\n }),\n onFocus: composeEventHandlers(props.onFocus, (event) => {\n const isKeyboardFocus = !isClickFocusRef.current;\n if (event.target === event.currentTarget && isKeyboardFocus && !isTabbingBackOut) {\n const entryFocusEvent = new CustomEvent(ENTRY_FOCUS, EVENT_OPTIONS);\n event.currentTarget.dispatchEvent(entryFocusEvent);\n if (!entryFocusEvent.defaultPrevented) {\n const items = getItems().filter((item) => item.focusable);\n const activeItem = items.find((item) => item.active);\n const currentItem = items.find((item) => item.id === currentTabStopId);\n const candidateItems = [activeItem, currentItem, ...items].filter(\n Boolean\n );\n const candidateNodes = candidateItems.map((item) => item.ref.current);\n focusFirst(candidateNodes, preventScrollOnEntryFocus);\n }\n }\n isClickFocusRef.current = false;\n }),\n onBlur: composeEventHandlers(props.onBlur, () => setIsTabbingBackOut(false))\n }\n )\n }\n );\n});\nvar ITEM_NAME = \"RovingFocusGroupItem\";\nvar RovingFocusGroupItem = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeRovingFocusGroup,\n focusable = true,\n active = false,\n tabStopId,\n children,\n ...itemProps\n } = props;\n const autoId = useId();\n const id = tabStopId || autoId;\n const context = useRovingFocusContext(ITEM_NAME, __scopeRovingFocusGroup);\n const isCurrentTabStop = context.currentTabStopId === id;\n const getItems = useCollection(__scopeRovingFocusGroup);\n const { onFocusableItemAdd, onFocusableItemRemove, currentTabStopId } = context;\n React.useEffect(() => {\n if (focusable) {\n onFocusableItemAdd();\n return () => onFocusableItemRemove();\n }\n }, [focusable, onFocusableItemAdd, onFocusableItemRemove]);\n return /* @__PURE__ */ jsx(\n Collection.ItemSlot,\n {\n scope: __scopeRovingFocusGroup,\n id,\n focusable,\n active,\n children: /* @__PURE__ */ jsx(\n Primitive.span,\n {\n tabIndex: isCurrentTabStop ? 0 : -1,\n \"data-orientation\": context.orientation,\n ...itemProps,\n ref: forwardedRef,\n onMouseDown: composeEventHandlers(props.onMouseDown, (event) => {\n if (!focusable) event.preventDefault();\n else context.onItemFocus(id);\n }),\n onFocus: composeEventHandlers(props.onFocus, () => context.onItemFocus(id)),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n if (event.key === \"Tab\" && event.shiftKey) {\n context.onItemShiftTab();\n return;\n }\n if (event.target !== event.currentTarget) return;\n const focusIntent = getFocusIntent(event, context.orientation, context.dir);\n if (focusIntent !== void 0) {\n if (event.metaKey || event.ctrlKey || event.altKey || event.shiftKey) return;\n event.preventDefault();\n const items = getItems().filter((item) => item.focusable);\n let candidateNodes = items.map((item) => item.ref.current);\n if (focusIntent === \"last\") candidateNodes.reverse();\n else if (focusIntent === \"prev\" || focusIntent === \"next\") {\n if (focusIntent === \"prev\") candidateNodes.reverse();\n const currentIndex = candidateNodes.indexOf(event.currentTarget);\n candidateNodes = context.loop ? wrapArray(candidateNodes, currentIndex + 1) : candidateNodes.slice(currentIndex + 1);\n }\n setTimeout(() => focusFirst(candidateNodes));\n }\n }),\n children: typeof children === \"function\" ? children({ isCurrentTabStop, hasTabStop: currentTabStopId != null }) : children\n }\n )\n }\n );\n }\n);\nRovingFocusGroupItem.displayName = ITEM_NAME;\nvar MAP_KEY_TO_FOCUS_INTENT = {\n ArrowLeft: \"prev\",\n ArrowUp: \"prev\",\n ArrowRight: \"next\",\n ArrowDown: \"next\",\n PageUp: \"first\",\n Home: \"first\",\n PageDown: \"last\",\n End: \"last\"\n};\nfunction getDirectionAwareKey(key, dir) {\n if (dir !== \"rtl\") return key;\n return key === \"ArrowLeft\" ? \"ArrowRight\" : key === \"ArrowRight\" ? \"ArrowLeft\" : key;\n}\nfunction getFocusIntent(event, orientation, dir) {\n const key = getDirectionAwareKey(event.key, dir);\n if (orientation === \"vertical\" && [\"ArrowLeft\", \"ArrowRight\"].includes(key)) return void 0;\n if (orientation === \"horizontal\" && [\"ArrowUp\", \"ArrowDown\"].includes(key)) return void 0;\n return MAP_KEY_TO_FOCUS_INTENT[key];\n}\nfunction focusFirst(candidates, preventScroll = false) {\n const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;\n for (const candidate of candidates) {\n if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;\n candidate.focus({ preventScroll });\n if (document.activeElement !== PREVIOUSLY_FOCUSED_ELEMENT) return;\n }\n}\nfunction wrapArray(array, startIndex) {\n return array.map((_, index) => array[(startIndex + index) % array.length]);\n}\nvar Root = RovingFocusGroup;\nvar Item = RovingFocusGroupItem;\nexport {\n Item,\n Root,\n RovingFocusGroup,\n RovingFocusGroupItem,\n createRovingFocusGroupScope\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/radio-group.tsx\nimport * as React2 from \"react\";\nimport { composeEventHandlers as composeEventHandlers2 } from \"@radix-ui/primitive\";\nimport { useComposedRefs as useComposedRefs2 } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope as createContextScope2 } from \"@radix-ui/react-context\";\nimport { Primitive as Primitive2 } from \"@radix-ui/react-primitive\";\nimport * as RovingFocusGroup from \"@radix-ui/react-roving-focus\";\nimport { createRovingFocusGroupScope } from \"@radix-ui/react-roving-focus\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { useDirection } from \"@radix-ui/react-direction\";\n\n// src/radio.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useSize } from \"@radix-ui/react-use-size\";\nimport { usePrevious } from \"@radix-ui/react-use-previous\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { jsx, jsxs } from \"react/jsx-runtime\";\nvar RADIO_NAME = \"Radio\";\nvar [createRadioContext, createRadioScope] = createContextScope(RADIO_NAME);\nvar [RadioProvider, useRadioContext] = createRadioContext(RADIO_NAME);\nvar Radio = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeRadio,\n name,\n checked = false,\n required,\n disabled,\n value = \"on\",\n onCheck,\n form,\n ...radioProps\n } = props;\n const [button, setButton] = React.useState(null);\n const composedRefs = useComposedRefs(forwardedRef, (node) => setButton(node));\n const hasConsumerStoppedPropagationRef = React.useRef(false);\n const isFormControl = button ? form || !!button.closest(\"form\") : true;\n return /* @__PURE__ */ jsxs(RadioProvider, { scope: __scopeRadio, checked, disabled, children: [\n /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n role: \"radio\",\n \"aria-checked\": checked,\n \"data-state\": getState(checked),\n \"data-disabled\": disabled ? \"\" : void 0,\n disabled,\n value,\n ...radioProps,\n ref: composedRefs,\n onClick: composeEventHandlers(props.onClick, (event) => {\n if (!checked) onCheck?.();\n if (isFormControl) {\n hasConsumerStoppedPropagationRef.current = event.isPropagationStopped();\n if (!hasConsumerStoppedPropagationRef.current) event.stopPropagation();\n }\n })\n }\n ),\n isFormControl && /* @__PURE__ */ jsx(\n RadioBubbleInput,\n {\n control: button,\n bubbles: !hasConsumerStoppedPropagationRef.current,\n name,\n value,\n checked,\n required,\n disabled,\n form,\n style: { transform: \"translateX(-100%)\" }\n }\n )\n ] });\n }\n);\nRadio.displayName = RADIO_NAME;\nvar INDICATOR_NAME = \"RadioIndicator\";\nvar RadioIndicator = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeRadio, forceMount, ...indicatorProps } = props;\n const context = useRadioContext(INDICATOR_NAME, __scopeRadio);\n return /* @__PURE__ */ jsx(Presence, { present: forceMount || context.checked, children: /* @__PURE__ */ jsx(\n Primitive.span,\n {\n \"data-state\": getState(context.checked),\n \"data-disabled\": context.disabled ? \"\" : void 0,\n ...indicatorProps,\n ref: forwardedRef\n }\n ) });\n }\n);\nRadioIndicator.displayName = INDICATOR_NAME;\nvar BUBBLE_INPUT_NAME = \"RadioBubbleInput\";\nvar RadioBubbleInput = React.forwardRef(\n ({\n __scopeRadio,\n control,\n checked,\n bubbles = true,\n ...props\n }, forwardedRef) => {\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(ref, forwardedRef);\n const prevChecked = usePrevious(checked);\n const controlSize = useSize(control);\n React.useEffect(() => {\n const input = ref.current;\n if (!input) return;\n const inputProto = window.HTMLInputElement.prototype;\n const descriptor = Object.getOwnPropertyDescriptor(\n inputProto,\n \"checked\"\n );\n const setChecked = descriptor.set;\n if (prevChecked !== checked && setChecked) {\n const event = new Event(\"click\", { bubbles });\n setChecked.call(input, checked);\n input.dispatchEvent(event);\n }\n }, [prevChecked, checked, bubbles]);\n return /* @__PURE__ */ jsx(\n Primitive.input,\n {\n type: \"radio\",\n \"aria-hidden\": true,\n defaultChecked: checked,\n ...props,\n tabIndex: -1,\n ref: composedRefs,\n style: {\n ...props.style,\n ...controlSize,\n position: \"absolute\",\n pointerEvents: \"none\",\n opacity: 0,\n margin: 0\n }\n }\n );\n }\n);\nRadioBubbleInput.displayName = BUBBLE_INPUT_NAME;\nfunction getState(checked) {\n return checked ? \"checked\" : \"unchecked\";\n}\n\n// src/radio-group.tsx\nimport { jsx as jsx2 } from \"react/jsx-runtime\";\nvar ARROW_KEYS = [\"ArrowUp\", \"ArrowDown\", \"ArrowLeft\", \"ArrowRight\"];\nvar RADIO_GROUP_NAME = \"RadioGroup\";\nvar [createRadioGroupContext, createRadioGroupScope] = createContextScope2(RADIO_GROUP_NAME, [\n createRovingFocusGroupScope,\n createRadioScope\n]);\nvar useRovingFocusGroupScope = createRovingFocusGroupScope();\nvar useRadioScope = createRadioScope();\nvar [RadioGroupProvider, useRadioGroupContext] = createRadioGroupContext(RADIO_GROUP_NAME);\nvar RadioGroup = React2.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeRadioGroup,\n name,\n defaultValue,\n value: valueProp,\n required = false,\n disabled = false,\n orientation,\n dir,\n loop = true,\n onValueChange,\n ...groupProps\n } = props;\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeRadioGroup);\n const direction = useDirection(dir);\n const [value, setValue] = useControllableState({\n prop: valueProp,\n defaultProp: defaultValue ?? null,\n onChange: onValueChange,\n caller: RADIO_GROUP_NAME\n });\n return /* @__PURE__ */ jsx2(\n RadioGroupProvider,\n {\n scope: __scopeRadioGroup,\n name,\n required,\n disabled,\n value,\n onValueChange: setValue,\n children: /* @__PURE__ */ jsx2(\n RovingFocusGroup.Root,\n {\n asChild: true,\n ...rovingFocusGroupScope,\n orientation,\n dir: direction,\n loop,\n children: /* @__PURE__ */ jsx2(\n Primitive2.div,\n {\n role: \"radiogroup\",\n \"aria-required\": required,\n \"aria-orientation\": orientation,\n \"data-disabled\": disabled ? \"\" : void 0,\n dir: direction,\n ...groupProps,\n ref: forwardedRef\n }\n )\n }\n )\n }\n );\n }\n);\nRadioGroup.displayName = RADIO_GROUP_NAME;\nvar ITEM_NAME = \"RadioGroupItem\";\nvar RadioGroupItem = React2.forwardRef(\n (props, forwardedRef) => {\n const { __scopeRadioGroup, disabled, ...itemProps } = props;\n const context = useRadioGroupContext(ITEM_NAME, __scopeRadioGroup);\n const isDisabled = context.disabled || disabled;\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeRadioGroup);\n const radioScope = useRadioScope(__scopeRadioGroup);\n const ref = React2.useRef(null);\n const composedRefs = useComposedRefs2(forwardedRef, ref);\n const checked = context.value === itemProps.value;\n const isArrowKeyPressedRef = React2.useRef(false);\n React2.useEffect(() => {\n const handleKeyDown = (event) => {\n if (ARROW_KEYS.includes(event.key)) {\n isArrowKeyPressedRef.current = true;\n }\n };\n const handleKeyUp = () => isArrowKeyPressedRef.current = false;\n document.addEventListener(\"keydown\", handleKeyDown);\n document.addEventListener(\"keyup\", handleKeyUp);\n return () => {\n document.removeEventListener(\"keydown\", handleKeyDown);\n document.removeEventListener(\"keyup\", handleKeyUp);\n };\n }, []);\n return /* @__PURE__ */ jsx2(\n RovingFocusGroup.Item,\n {\n asChild: true,\n ...rovingFocusGroupScope,\n focusable: !isDisabled,\n active: checked,\n children: /* @__PURE__ */ jsx2(\n Radio,\n {\n disabled: isDisabled,\n required: context.required,\n checked,\n ...radioScope,\n ...itemProps,\n name: context.name,\n ref: composedRefs,\n onCheck: () => context.onValueChange(itemProps.value),\n onKeyDown: composeEventHandlers2((event) => {\n if (event.key === \"Enter\") event.preventDefault();\n }),\n onFocus: composeEventHandlers2(itemProps.onFocus, () => {\n if (isArrowKeyPressedRef.current) ref.current?.click();\n })\n }\n )\n }\n );\n }\n);\nRadioGroupItem.displayName = ITEM_NAME;\nvar INDICATOR_NAME2 = \"RadioGroupIndicator\";\nvar RadioGroupIndicator = React2.forwardRef(\n (props, forwardedRef) => {\n const { __scopeRadioGroup, ...indicatorProps } = props;\n const radioScope = useRadioScope(__scopeRadioGroup);\n return /* @__PURE__ */ jsx2(RadioIndicator, { ...radioScope, ...indicatorProps, ref: forwardedRef });\n }\n);\nRadioGroupIndicator.displayName = INDICATOR_NAME2;\nvar Root2 = RadioGroup;\nvar Item2 = RadioGroupItem;\nvar Indicator = RadioGroupIndicator;\nexport {\n Indicator,\n Item2 as Item,\n RadioGroup,\n RadioGroupIndicator,\n RadioGroupItem,\n Root2 as Root,\n createRadioGroupScope\n};\n//# sourceMappingURL=index.mjs.map\n","import React from \"react\";\nimport * as RadioGroupPrimitives from \"@radix-ui/react-radio-group\";\nimport { cn } from \"@/utils/cn\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitives.Root>,\n React.ComponentPropsWithoutRef<typeof RadioGroupPrimitives.Root>\n>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitives.Root className={className} {...props} ref={ref} />\n );\n});\nRadioGroup.displayName = RadioGroupPrimitives.Root.displayName;\n\nconst radioGroupItemVariants = cva(\n cn(\n \"flex items-center justify-center\",\n \"aspect-square rounded-full border-2 transition-colors\",\n \"focus:outline-none\",\n \"focus-visible:ring-offset-2\",\n \"disabled:cursor-not-allowed disabled:opacity-50\",\n \"cursor-pointer\",\n ),\n {\n variants: {\n variant: {\n black: cn(\n \"border-cms-gray-300 text-cms-black\",\n \"data-[state=checked]:border-cms-black\",\n ),\n default: cn(\n \"border-cms-gray-300 text-cms-primary-300\",\n \"data-[state=checked]:border-cms-primary-300\",\n ),\n green: cn(\n \"border-cms-gray-300 text-cms-green-500\",\n \"data-[state=checked]:border-cms-green-500\",\n ),\n blue: cn(\n \"border-cms-gray-300 text-cms-blue-700\",\n \"data-[state=checked]:border-cms-blue-700\",\n ),\n red: cn(\n \"border-cms-gray-300 text-cms-red-400\",\n \"data-[state=checked]:border-cms-red-400\",\n ),\n },\n size: {\n sm: \"size-4\",\n md: \"size-5\",\n lg: \"size-6\",\n },\n },\n defaultVariants: {\n variant: \"black\",\n size: \"md\",\n },\n },\n);\n\nconst radioGroupIndicatorVariants = cva(\n \"flex items-center justify-center rounded-full bg-current aspect-square\",\n {\n variants: {\n variant: {\n // bg-current를 쓰면 부모 text color를 따라가므로 색상 정의 줄일 수 있음\n black: \"text-cms-black\",\n default: \"text-cms-primary-300\",\n green: \"text-cms-green-500\",\n blue: \"text-cms-blue-700\",\n red: \"text-cms-red-400\",\n },\n size: {\n sm: \"size-2\",\n md: \"size-2.5\",\n lg: \"size-3\",\n },\n },\n defaultVariants: {\n variant: \"black\",\n size: \"md\",\n },\n },\n);\n\nexport interface RadioGroupItemProps\n extends\n React.ComponentPropsWithoutRef<typeof RadioGroupPrimitives.Item>,\n VariantProps<typeof radioGroupItemVariants> {}\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitives.Item>,\n RadioGroupItemProps\n>(({ className, variant, size, ...props }, ref) => {\n return (\n <RadioGroupPrimitives.Item\n ref={ref}\n className={cn(radioGroupItemVariants({ variant, size }), className)}\n {...props}\n >\n <RadioGroupPrimitives.Indicator\n className={cn(radioGroupIndicatorVariants({ variant, size }))}\n />\n </RadioGroupPrimitives.Item>\n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitives.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","\"use client\";\n\n// src/collapsible.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { useId } from \"@radix-ui/react-id\";\nimport { jsx } from \"react/jsx-runtime\";\nvar COLLAPSIBLE_NAME = \"Collapsible\";\nvar [createCollapsibleContext, createCollapsibleScope] = createContextScope(COLLAPSIBLE_NAME);\nvar [CollapsibleProvider, useCollapsibleContext] = createCollapsibleContext(COLLAPSIBLE_NAME);\nvar Collapsible = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeCollapsible,\n open: openProp,\n defaultOpen,\n disabled,\n onOpenChange,\n ...collapsibleProps\n } = props;\n const [open, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen ?? false,\n onChange: onOpenChange,\n caller: COLLAPSIBLE_NAME\n });\n return /* @__PURE__ */ jsx(\n CollapsibleProvider,\n {\n scope: __scopeCollapsible,\n disabled,\n contentId: useId(),\n open,\n onOpenToggle: React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),\n children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n \"data-state\": getState(open),\n \"data-disabled\": disabled ? \"\" : void 0,\n ...collapsibleProps,\n ref: forwardedRef\n }\n )\n }\n );\n }\n);\nCollapsible.displayName = COLLAPSIBLE_NAME;\nvar TRIGGER_NAME = \"CollapsibleTrigger\";\nvar CollapsibleTrigger = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeCollapsible, ...triggerProps } = props;\n const context = useCollapsibleContext(TRIGGER_NAME, __scopeCollapsible);\n return /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n \"aria-controls\": context.contentId,\n \"aria-expanded\": context.open || false,\n \"data-state\": getState(context.open),\n \"data-disabled\": context.disabled ? \"\" : void 0,\n disabled: context.disabled,\n ...triggerProps,\n ref: forwardedRef,\n onClick: composeEventHandlers(props.onClick, context.onOpenToggle)\n }\n );\n }\n);\nCollapsibleTrigger.displayName = TRIGGER_NAME;\nvar CONTENT_NAME = \"CollapsibleContent\";\nvar CollapsibleContent = React.forwardRef(\n (props, forwardedRef) => {\n const { forceMount, ...contentProps } = props;\n const context = useCollapsibleContext(CONTENT_NAME, props.__scopeCollapsible);\n return /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: ({ present }) => /* @__PURE__ */ jsx(CollapsibleContentImpl, { ...contentProps, ref: forwardedRef, present }) });\n }\n);\nCollapsibleContent.displayName = CONTENT_NAME;\nvar CollapsibleContentImpl = React.forwardRef((props, forwardedRef) => {\n const { __scopeCollapsible, present, children, ...contentProps } = props;\n const context = useCollapsibleContext(CONTENT_NAME, __scopeCollapsible);\n const [isPresent, setIsPresent] = React.useState(present);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const heightRef = React.useRef(0);\n const height = heightRef.current;\n const widthRef = React.useRef(0);\n const width = widthRef.current;\n const isOpen = context.open || isPresent;\n const isMountAnimationPreventedRef = React.useRef(isOpen);\n const originalStylesRef = React.useRef(void 0);\n React.useEffect(() => {\n const rAF = requestAnimationFrame(() => isMountAnimationPreventedRef.current = false);\n return () => cancelAnimationFrame(rAF);\n }, []);\n useLayoutEffect(() => {\n const node = ref.current;\n if (node) {\n originalStylesRef.current = originalStylesRef.current || {\n transitionDuration: node.style.transitionDuration,\n animationName: node.style.animationName\n };\n node.style.transitionDuration = \"0s\";\n node.style.animationName = \"none\";\n const rect = node.getBoundingClientRect();\n heightRef.current = rect.height;\n widthRef.current = rect.width;\n if (!isMountAnimationPreventedRef.current) {\n node.style.transitionDuration = originalStylesRef.current.transitionDuration;\n node.style.animationName = originalStylesRef.current.animationName;\n }\n setIsPresent(present);\n }\n }, [context.open, present]);\n return /* @__PURE__ */ jsx(\n Primitive.div,\n {\n \"data-state\": getState(context.open),\n \"data-disabled\": context.disabled ? \"\" : void 0,\n id: context.contentId,\n hidden: !isOpen,\n ...contentProps,\n ref: composedRefs,\n style: {\n [`--radix-collapsible-content-height`]: height ? `${height}px` : void 0,\n [`--radix-collapsible-content-width`]: width ? `${width}px` : void 0,\n ...props.style\n },\n children: isOpen && children\n }\n );\n});\nfunction getState(open) {\n return open ? \"open\" : \"closed\";\n}\nvar Root = Collapsible;\nvar Trigger = CollapsibleTrigger;\nvar Content = CollapsibleContent;\nexport {\n Collapsible,\n CollapsibleContent,\n CollapsibleTrigger,\n Content,\n Root,\n Trigger,\n createCollapsibleScope\n};\n//# sourceMappingURL=index.mjs.map\n","\"use client\";\n\n// src/accordion.tsx\nimport React from \"react\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { createCollection } from \"@radix-ui/react-collection\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport * as CollapsiblePrimitive from \"@radix-ui/react-collapsible\";\nimport { createCollapsibleScope } from \"@radix-ui/react-collapsible\";\nimport { useId } from \"@radix-ui/react-id\";\nimport { useDirection } from \"@radix-ui/react-direction\";\nimport { jsx } from \"react/jsx-runtime\";\nvar ACCORDION_NAME = \"Accordion\";\nvar ACCORDION_KEYS = [\"Home\", \"End\", \"ArrowDown\", \"ArrowUp\", \"ArrowLeft\", \"ArrowRight\"];\nvar [Collection, useCollection, createCollectionScope] = createCollection(ACCORDION_NAME);\nvar [createAccordionContext, createAccordionScope] = createContextScope(ACCORDION_NAME, [\n createCollectionScope,\n createCollapsibleScope\n]);\nvar useCollapsibleScope = createCollapsibleScope();\nvar Accordion = React.forwardRef(\n (props, forwardedRef) => {\n const { type, ...accordionProps } = props;\n const singleProps = accordionProps;\n const multipleProps = accordionProps;\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeAccordion, children: type === \"multiple\" ? /* @__PURE__ */ jsx(AccordionImplMultiple, { ...multipleProps, ref: forwardedRef }) : /* @__PURE__ */ jsx(AccordionImplSingle, { ...singleProps, ref: forwardedRef }) });\n }\n);\nAccordion.displayName = ACCORDION_NAME;\nvar [AccordionValueProvider, useAccordionValueContext] = createAccordionContext(ACCORDION_NAME);\nvar [AccordionCollapsibleProvider, useAccordionCollapsibleContext] = createAccordionContext(\n ACCORDION_NAME,\n { collapsible: false }\n);\nvar AccordionImplSingle = React.forwardRef(\n (props, forwardedRef) => {\n const {\n value: valueProp,\n defaultValue,\n onValueChange = () => {\n },\n collapsible = false,\n ...accordionSingleProps\n } = props;\n const [value, setValue] = useControllableState({\n prop: valueProp,\n defaultProp: defaultValue ?? \"\",\n onChange: onValueChange,\n caller: ACCORDION_NAME\n });\n return /* @__PURE__ */ jsx(\n AccordionValueProvider,\n {\n scope: props.__scopeAccordion,\n value: React.useMemo(() => value ? [value] : [], [value]),\n onItemOpen: setValue,\n onItemClose: React.useCallback(() => collapsible && setValue(\"\"), [collapsible, setValue]),\n children: /* @__PURE__ */ jsx(AccordionCollapsibleProvider, { scope: props.__scopeAccordion, collapsible, children: /* @__PURE__ */ jsx(AccordionImpl, { ...accordionSingleProps, ref: forwardedRef }) })\n }\n );\n }\n);\nvar AccordionImplMultiple = React.forwardRef((props, forwardedRef) => {\n const {\n value: valueProp,\n defaultValue,\n onValueChange = () => {\n },\n ...accordionMultipleProps\n } = props;\n const [value, setValue] = useControllableState({\n prop: valueProp,\n defaultProp: defaultValue ?? [],\n onChange: onValueChange,\n caller: ACCORDION_NAME\n });\n const handleItemOpen = React.useCallback(\n (itemValue) => setValue((prevValue = []) => [...prevValue, itemValue]),\n [setValue]\n );\n const handleItemClose = React.useCallback(\n (itemValue) => setValue((prevValue = []) => prevValue.filter((value2) => value2 !== itemValue)),\n [setValue]\n );\n return /* @__PURE__ */ jsx(\n AccordionValueProvider,\n {\n scope: props.__scopeAccordion,\n value,\n onItemOpen: handleItemOpen,\n onItemClose: handleItemClose,\n children: /* @__PURE__ */ jsx(AccordionCollapsibleProvider, { scope: props.__scopeAccordion, collapsible: true, children: /* @__PURE__ */ jsx(AccordionImpl, { ...accordionMultipleProps, ref: forwardedRef }) })\n }\n );\n});\nvar [AccordionImplProvider, useAccordionContext] = createAccordionContext(ACCORDION_NAME);\nvar AccordionImpl = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeAccordion, disabled, dir, orientation = \"vertical\", ...accordionProps } = props;\n const accordionRef = React.useRef(null);\n const composedRefs = useComposedRefs(accordionRef, forwardedRef);\n const getItems = useCollection(__scopeAccordion);\n const direction = useDirection(dir);\n const isDirectionLTR = direction === \"ltr\";\n const handleKeyDown = composeEventHandlers(props.onKeyDown, (event) => {\n if (!ACCORDION_KEYS.includes(event.key)) return;\n const target = event.target;\n const triggerCollection = getItems().filter((item) => !item.ref.current?.disabled);\n const triggerIndex = triggerCollection.findIndex((item) => item.ref.current === target);\n const triggerCount = triggerCollection.length;\n if (triggerIndex === -1) return;\n event.preventDefault();\n let nextIndex = triggerIndex;\n const homeIndex = 0;\n const endIndex = triggerCount - 1;\n const moveNext = () => {\n nextIndex = triggerIndex + 1;\n if (nextIndex > endIndex) {\n nextIndex = homeIndex;\n }\n };\n const movePrev = () => {\n nextIndex = triggerIndex - 1;\n if (nextIndex < homeIndex) {\n nextIndex = endIndex;\n }\n };\n switch (event.key) {\n case \"Home\":\n nextIndex = homeIndex;\n break;\n case \"End\":\n nextIndex = endIndex;\n break;\n case \"ArrowRight\":\n if (orientation === \"horizontal\") {\n if (isDirectionLTR) {\n moveNext();\n } else {\n movePrev();\n }\n }\n break;\n case \"ArrowDown\":\n if (orientation === \"vertical\") {\n moveNext();\n }\n break;\n case \"ArrowLeft\":\n if (orientation === \"horizontal\") {\n if (isDirectionLTR) {\n movePrev();\n } else {\n moveNext();\n }\n }\n break;\n case \"ArrowUp\":\n if (orientation === \"vertical\") {\n movePrev();\n }\n break;\n }\n const clampedIndex = nextIndex % triggerCount;\n triggerCollection[clampedIndex].ref.current?.focus();\n });\n return /* @__PURE__ */ jsx(\n AccordionImplProvider,\n {\n scope: __scopeAccordion,\n disabled,\n direction: dir,\n orientation,\n children: /* @__PURE__ */ jsx(Collection.Slot, { scope: __scopeAccordion, children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n ...accordionProps,\n \"data-orientation\": orientation,\n ref: composedRefs,\n onKeyDown: disabled ? void 0 : handleKeyDown\n }\n ) })\n }\n );\n }\n);\nvar ITEM_NAME = \"AccordionItem\";\nvar [AccordionItemProvider, useAccordionItemContext] = createAccordionContext(ITEM_NAME);\nvar AccordionItem = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeAccordion, value, ...accordionItemProps } = props;\n const accordionContext = useAccordionContext(ITEM_NAME, __scopeAccordion);\n const valueContext = useAccordionValueContext(ITEM_NAME, __scopeAccordion);\n const collapsibleScope = useCollapsibleScope(__scopeAccordion);\n const triggerId = useId();\n const open = value && valueContext.value.includes(value) || false;\n const disabled = accordionContext.disabled || props.disabled;\n return /* @__PURE__ */ jsx(\n AccordionItemProvider,\n {\n scope: __scopeAccordion,\n open,\n disabled,\n triggerId,\n children: /* @__PURE__ */ jsx(\n CollapsiblePrimitive.Root,\n {\n \"data-orientation\": accordionContext.orientation,\n \"data-state\": getState(open),\n ...collapsibleScope,\n ...accordionItemProps,\n ref: forwardedRef,\n disabled,\n open,\n onOpenChange: (open2) => {\n if (open2) {\n valueContext.onItemOpen(value);\n } else {\n valueContext.onItemClose(value);\n }\n }\n }\n )\n }\n );\n }\n);\nAccordionItem.displayName = ITEM_NAME;\nvar HEADER_NAME = \"AccordionHeader\";\nvar AccordionHeader = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeAccordion, ...headerProps } = props;\n const accordionContext = useAccordionContext(ACCORDION_NAME, __scopeAccordion);\n const itemContext = useAccordionItemContext(HEADER_NAME, __scopeAccordion);\n return /* @__PURE__ */ jsx(\n Primitive.h3,\n {\n \"data-orientation\": accordionContext.orientation,\n \"data-state\": getState(itemContext.open),\n \"data-disabled\": itemContext.disabled ? \"\" : void 0,\n ...headerProps,\n ref: forwardedRef\n }\n );\n }\n);\nAccordionHeader.displayName = HEADER_NAME;\nvar TRIGGER_NAME = \"AccordionTrigger\";\nvar AccordionTrigger = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeAccordion, ...triggerProps } = props;\n const accordionContext = useAccordionContext(ACCORDION_NAME, __scopeAccordion);\n const itemContext = useAccordionItemContext(TRIGGER_NAME, __scopeAccordion);\n const collapsibleContext = useAccordionCollapsibleContext(TRIGGER_NAME, __scopeAccordion);\n const collapsibleScope = useCollapsibleScope(__scopeAccordion);\n return /* @__PURE__ */ jsx(Collection.ItemSlot, { scope: __scopeAccordion, children: /* @__PURE__ */ jsx(\n CollapsiblePrimitive.Trigger,\n {\n \"aria-disabled\": itemContext.open && !collapsibleContext.collapsible || void 0,\n \"data-orientation\": accordionContext.orientation,\n id: itemContext.triggerId,\n ...collapsibleScope,\n ...triggerProps,\n ref: forwardedRef\n }\n ) });\n }\n);\nAccordionTrigger.displayName = TRIGGER_NAME;\nvar CONTENT_NAME = \"AccordionContent\";\nvar AccordionContent = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeAccordion, ...contentProps } = props;\n const accordionContext = useAccordionContext(ACCORDION_NAME, __scopeAccordion);\n const itemContext = useAccordionItemContext(CONTENT_NAME, __scopeAccordion);\n const collapsibleScope = useCollapsibleScope(__scopeAccordion);\n return /* @__PURE__ */ jsx(\n CollapsiblePrimitive.Content,\n {\n role: \"region\",\n \"aria-labelledby\": itemContext.triggerId,\n \"data-orientation\": accordionContext.orientation,\n ...collapsibleScope,\n ...contentProps,\n ref: forwardedRef,\n style: {\n [\"--radix-accordion-content-height\"]: \"var(--radix-collapsible-content-height)\",\n [\"--radix-accordion-content-width\"]: \"var(--radix-collapsible-content-width)\",\n ...props.style\n }\n }\n );\n }\n);\nAccordionContent.displayName = CONTENT_NAME;\nfunction getState(open) {\n return open ? \"open\" : \"closed\";\n}\nvar Root2 = Accordion;\nvar Item = AccordionItem;\nvar Header = AccordionHeader;\nvar Trigger2 = AccordionTrigger;\nvar Content2 = AccordionContent;\nexport {\n Accordion,\n AccordionContent,\n AccordionHeader,\n AccordionItem,\n AccordionTrigger,\n Content2 as Content,\n Header,\n Item,\n Root2 as Root,\n Trigger2 as Trigger,\n createAccordionScope\n};\n//# sourceMappingURL=index.mjs.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nconst toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, \"$1-$2\").toLowerCase();\nconst toCamelCase = (string) => string.replace(\n /^([A-Z])|[\\s-_]+(\\w)/g,\n (match, p1, p2) => p2 ? p2.toUpperCase() : p1.toLowerCase()\n);\nconst toPascalCase = (string) => {\n const camelCase = toCamelCase(string);\n return camelCase.charAt(0).toUpperCase() + camelCase.slice(1);\n};\nconst mergeClasses = (...classes) => classes.filter((className, index, array) => {\n return Boolean(className) && className.trim() !== \"\" && array.indexOf(className) === index;\n}).join(\" \").trim();\nconst hasA11yProp = (props) => {\n for (const prop in props) {\n if (prop.startsWith(\"aria-\") || prop === \"role\" || prop === \"title\") {\n return true;\n }\n }\n};\n\nexport { hasA11yProp, mergeClasses, toCamelCase, toKebabCase, toPascalCase };\n//# sourceMappingURL=utils.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nvar defaultAttributes = {\n xmlns: \"http://www.w3.org/2000/svg\",\n width: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n stroke: \"currentColor\",\n strokeWidth: 2,\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\"\n};\n\nexport { defaultAttributes as default };\n//# sourceMappingURL=defaultAttributes.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport defaultAttributes from './defaultAttributes.js';\nimport { mergeClasses, hasA11yProp } from './shared/src/utils.js';\n\nconst Icon = forwardRef(\n ({\n color = \"currentColor\",\n size = 24,\n strokeWidth = 2,\n absoluteStrokeWidth,\n className = \"\",\n children,\n iconNode,\n ...rest\n }, ref) => createElement(\n \"svg\",\n {\n ref,\n ...defaultAttributes,\n width: size,\n height: size,\n stroke: color,\n strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,\n className: mergeClasses(\"lucide\", className),\n ...!children && !hasA11yProp(rest) && { \"aria-hidden\": \"true\" },\n ...rest\n },\n [\n ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n ...Array.isArray(children) ? children : [children]\n ]\n )\n);\n\nexport { Icon as default };\n//# sourceMappingURL=Icon.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport { mergeClasses, toKebabCase, toPascalCase } from './shared/src/utils.js';\nimport Icon from './Icon.js';\n\nconst createLucideIcon = (iconName, iconNode) => {\n const Component = forwardRef(\n ({ className, ...props }, ref) => createElement(Icon, {\n ref,\n iconNode,\n className: mergeClasses(\n `lucide-${toKebabCase(toPascalCase(iconName))}`,\n `lucide-${iconName}`,\n className\n ),\n ...props\n })\n );\n Component.displayName = toPascalCase(iconName);\n return Component;\n};\n\nexport { createLucideIcon as default };\n//# sourceMappingURL=createLucideIcon.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"M20 6 9 17l-5-5\", key: \"1gmf2c\" }]];\nconst Check = createLucideIcon(\"check\", __iconNode);\n\nexport { __iconNode, Check as default };\n//# sourceMappingURL=check.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"m6 9 6 6 6-6\", key: \"qrunsl\" }]];\nconst ChevronDown = createLucideIcon(\"chevron-down\", __iconNode);\n\nexport { __iconNode, ChevronDown as default };\n//# sourceMappingURL=chevron-down.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n [\"path\", { d: \"m9 12 2 2 4-4\", key: \"dzmm74\" }]\n];\nconst CircleCheck = createLucideIcon(\"circle-check\", __iconNode);\n\nexport { __iconNode, CircleCheck as default };\n//# sourceMappingURL=circle-check.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n [\"path\", { d: \"m15 9-6 6\", key: \"1uzhvr\" }],\n [\"path\", { d: \"m9 9 6 6\", key: \"z0biqf\" }]\n];\nconst CircleX = createLucideIcon(\"circle-x\", __iconNode);\n\nexport { __iconNode, CircleX as default };\n//# sourceMappingURL=circle-x.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3\",\n key: \"wmoenq\"\n }\n ],\n [\"path\", { d: \"M12 9v4\", key: \"juzpu7\" }],\n [\"path\", { d: \"M12 17h.01\", key: \"p32p05\" }]\n];\nconst TriangleAlert = createLucideIcon(\"triangle-alert\", __iconNode);\n\nexport { __iconNode, TriangleAlert as default };\n//# sourceMappingURL=triangle-alert.js.map\n","/**\n * @license lucide-react v0.555.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"path\", { d: \"M18 6 6 18\", key: \"1bl5f8\" }],\n [\"path\", { d: \"m6 6 12 12\", key: \"d8bk6v\" }]\n];\nconst X = createLucideIcon(\"x\", __iconNode);\n\nexport { __iconNode, X as default };\n//# sourceMappingURL=x.js.map\n","import React, { useState } from \"react\";\nimport * as Accordion from \"@radix-ui/react-accordion\";\nimport { cn } from \"@/utils/cn\";\nimport { ChevronDown } from \"lucide-react\";\n\nexport interface SubMenuItem {\n url: string;\n title: string;\n}\n\nexport interface MenuItem {\n url: string;\n title: string;\n icon?: React.ReactNode;\n subMenu?: SubMenuItem[];\n}\n\nexport interface SideNavigationProps {\n title?: string;\n menus: MenuItem[];\n selectedUrl: string;\n onMenuClick: (url: string) => void;\n headerSlot?: React.ReactNode;\n className?: string;\n}\n\ninterface NavigationMenuItemProps {\n menu: MenuItem;\n isOpen: boolean;\n isSelected: boolean;\n selectedUrl: string;\n onMenuClick: (url: string) => void;\n}\n\nconst NavigationMenuItem = ({\n menu,\n isOpen,\n isSelected,\n selectedUrl,\n onMenuClick,\n}: NavigationMenuItemProps) => {\n const isSubMenuSelected = menu.subMenu?.some(\n (sub) => sub.url === selectedUrl,\n );\n\n return (\n <Accordion.Item value={menu.url} className=\"border-none\">\n <Accordion.Header className=\"m-0\">\n <Accordion.Trigger\n onClick={(e) => {\n if (!menu.subMenu) {\n e.preventDefault();\n onMenuClick(menu.url);\n }\n }}\n className={cn(\n \"group flex items-center px-5\",\n \"text-white font-bold text-lg\",\n \"w-full h-15\",\n \"transition-colors\",\n \"cursor-pointer\",\n !isSubMenuSelected && \"data-[state=open]:bg-transparent\",\n !menu.subMenu && isSelected && \"bg-cms-primary-400 text-cms-black\",\n isSubMenuSelected && \"bg-cms-primary-200 text-cms-black\",\n )}\n >\n {menu.icon && (\n <div\n className={cn(\n \"mr-3 flex items-center\",\n \"[&>svg]:w-6 [&>svg]:h-6\",\n (!menu.subMenu && isSelected) || isSubMenuSelected\n ? \"text-cms-black\"\n : \"text-white\",\n )}\n >\n {menu.icon}\n </div>\n )}\n <span\n className={cn(\n (!menu.subMenu && isSelected) || isSubMenuSelected\n ? \"text-cms-black\"\n : \"text-white\",\n )}\n >\n {menu.title}\n </span>\n {menu.subMenu && (\n <ChevronDown\n className={cn(\n \"ml-auto transition-transform\",\n (!menu.subMenu && isSelected) || isSubMenuSelected\n ? \"text-cms-black\"\n : \"text-white\",\n isOpen && \"rotate-180\",\n )}\n size={20}\n />\n )}\n </Accordion.Trigger>\n </Accordion.Header>\n {menu.subMenu && (\n <Accordion.Content\n className={cn(\n \"overflow-hidden\",\n \"bg-[#232427]\",\n \"data-[state=open]:animate-accordion-down\",\n \"data-[state=closed]:animate-accordion-up\",\n )}\n >\n {menu.subMenu.map((subItem) => {\n const subSelected = subItem.url === selectedUrl;\n return (\n <div\n key={subItem.url}\n onClick={() => onMenuClick(subItem.url)}\n className={cn(\n \"flex items-center\",\n \"h-13 px-5 pl-14\",\n \"cursor-pointer\",\n \"transition-colors\",\n \"hover:bg-[#2e2f32]\",\n )}\n >\n <span\n className={cn(\n \"text-base font-bold\",\n \"transition-colors\",\n subSelected\n ? \"text-cms-primary-400 font-bold\"\n : \"text-cms-white\",\n )}\n >\n {subItem.title}\n </span>\n </div>\n );\n })}\n </Accordion.Content>\n )}\n </Accordion.Item>\n );\n};\n\nexport const SideNavigation = React.forwardRef<\n HTMLDivElement,\n SideNavigationProps\n>(\n (\n { title, menus, selectedUrl, onMenuClick, headerSlot, className, ...props },\n ref,\n ) => {\n const [openedMenus, setOpenedMenus] = useState<string[]>([]);\n\n return (\n <div\n ref={ref}\n className={cn(\n \"flex flex-col\",\n \"w-70 min-w-70 max-w-70 h-full\",\n \"bg-[#2c2d30] text-white\",\n className,\n )}\n {...props}\n >\n {/* Header Slot */}\n {headerSlot}\n\n {/* Title */}\n {title && !headerSlot && (\n <div className=\"px-5 py-4 border-b border-[#3a3b3e]\">\n <h2 className=\"text-lg font-semibold text-white\">{title}</h2>\n </div>\n )}\n\n {/* Menu Body */}\n <div\n className={cn(\n \"flex-1 overflow-y-auto\",\n \"scrollbar-thin\",\n \"scrollbar-thumb-[#3a3b3e]\",\n \"scrollbar-track-transparent\",\n )}\n >\n <Accordion.Root\n type=\"multiple\"\n value={openedMenus}\n onValueChange={setOpenedMenus}\n >\n {menus.map((menu) => (\n <NavigationMenuItem\n key={menu.url}\n menu={menu}\n isOpen={openedMenus.includes(menu.url)}\n isSelected={selectedUrl === menu.url}\n selectedUrl={selectedUrl}\n onMenuClick={onMenuClick}\n />\n ))}\n </Accordion.Root>\n </div>\n </div>\n );\n },\n);\n\nSideNavigation.displayName = \"SideNavigation\";\n","\"use client\";\n\n// src/checkbox.tsx\nimport * as React from \"react\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { usePrevious } from \"@radix-ui/react-use-previous\";\nimport { useSize } from \"@radix-ui/react-use-size\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { Fragment, jsx, jsxs } from \"react/jsx-runtime\";\nvar CHECKBOX_NAME = \"Checkbox\";\nvar [createCheckboxContext, createCheckboxScope] = createContextScope(CHECKBOX_NAME);\nvar [CheckboxProviderImpl, useCheckboxContext] = createCheckboxContext(CHECKBOX_NAME);\nfunction CheckboxProvider(props) {\n const {\n __scopeCheckbox,\n checked: checkedProp,\n children,\n defaultChecked,\n disabled,\n form,\n name,\n onCheckedChange,\n required,\n value = \"on\",\n // @ts-expect-error\n internal_do_not_use_render\n } = props;\n const [checked, setChecked] = useControllableState({\n prop: checkedProp,\n defaultProp: defaultChecked ?? false,\n onChange: onCheckedChange,\n caller: CHECKBOX_NAME\n });\n const [control, setControl] = React.useState(null);\n const [bubbleInput, setBubbleInput] = React.useState(null);\n const hasConsumerStoppedPropagationRef = React.useRef(false);\n const isFormControl = control ? !!form || !!control.closest(\"form\") : (\n // We set this to true by default so that events bubble to forms without JS (SSR)\n true\n );\n const context = {\n checked,\n disabled,\n setChecked,\n control,\n setControl,\n name,\n form,\n value,\n hasConsumerStoppedPropagationRef,\n required,\n defaultChecked: isIndeterminate(defaultChecked) ? false : defaultChecked,\n isFormControl,\n bubbleInput,\n setBubbleInput\n };\n return /* @__PURE__ */ jsx(\n CheckboxProviderImpl,\n {\n scope: __scopeCheckbox,\n ...context,\n children: isFunction(internal_do_not_use_render) ? internal_do_not_use_render(context) : children\n }\n );\n}\nvar TRIGGER_NAME = \"CheckboxTrigger\";\nvar CheckboxTrigger = React.forwardRef(\n ({ __scopeCheckbox, onKeyDown, onClick, ...checkboxProps }, forwardedRef) => {\n const {\n control,\n value,\n disabled,\n checked,\n required,\n setControl,\n setChecked,\n hasConsumerStoppedPropagationRef,\n isFormControl,\n bubbleInput\n } = useCheckboxContext(TRIGGER_NAME, __scopeCheckbox);\n const composedRefs = useComposedRefs(forwardedRef, setControl);\n const initialCheckedStateRef = React.useRef(checked);\n React.useEffect(() => {\n const form = control?.form;\n if (form) {\n const reset = () => setChecked(initialCheckedStateRef.current);\n form.addEventListener(\"reset\", reset);\n return () => form.removeEventListener(\"reset\", reset);\n }\n }, [control, setChecked]);\n return /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n role: \"checkbox\",\n \"aria-checked\": isIndeterminate(checked) ? \"mixed\" : checked,\n \"aria-required\": required,\n \"data-state\": getState(checked),\n \"data-disabled\": disabled ? \"\" : void 0,\n disabled,\n value,\n ...checkboxProps,\n ref: composedRefs,\n onKeyDown: composeEventHandlers(onKeyDown, (event) => {\n if (event.key === \"Enter\") event.preventDefault();\n }),\n onClick: composeEventHandlers(onClick, (event) => {\n setChecked((prevChecked) => isIndeterminate(prevChecked) ? true : !prevChecked);\n if (bubbleInput && isFormControl) {\n hasConsumerStoppedPropagationRef.current = event.isPropagationStopped();\n if (!hasConsumerStoppedPropagationRef.current) event.stopPropagation();\n }\n })\n }\n );\n }\n);\nCheckboxTrigger.displayName = TRIGGER_NAME;\nvar Checkbox = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeCheckbox,\n name,\n checked,\n defaultChecked,\n required,\n disabled,\n value,\n onCheckedChange,\n form,\n ...checkboxProps\n } = props;\n return /* @__PURE__ */ jsx(\n CheckboxProvider,\n {\n __scopeCheckbox,\n checked,\n defaultChecked,\n disabled,\n required,\n onCheckedChange,\n name,\n form,\n value,\n internal_do_not_use_render: ({ isFormControl }) => /* @__PURE__ */ jsxs(Fragment, { children: [\n /* @__PURE__ */ jsx(\n CheckboxTrigger,\n {\n ...checkboxProps,\n ref: forwardedRef,\n __scopeCheckbox\n }\n ),\n isFormControl && /* @__PURE__ */ jsx(\n CheckboxBubbleInput,\n {\n __scopeCheckbox\n }\n )\n ] })\n }\n );\n }\n);\nCheckbox.displayName = CHECKBOX_NAME;\nvar INDICATOR_NAME = \"CheckboxIndicator\";\nvar CheckboxIndicator = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeCheckbox, forceMount, ...indicatorProps } = props;\n const context = useCheckboxContext(INDICATOR_NAME, __scopeCheckbox);\n return /* @__PURE__ */ jsx(\n Presence,\n {\n present: forceMount || isIndeterminate(context.checked) || context.checked === true,\n children: /* @__PURE__ */ jsx(\n Primitive.span,\n {\n \"data-state\": getState(context.checked),\n \"data-disabled\": context.disabled ? \"\" : void 0,\n ...indicatorProps,\n ref: forwardedRef,\n style: { pointerEvents: \"none\", ...props.style }\n }\n )\n }\n );\n }\n);\nCheckboxIndicator.displayName = INDICATOR_NAME;\nvar BUBBLE_INPUT_NAME = \"CheckboxBubbleInput\";\nvar CheckboxBubbleInput = React.forwardRef(\n ({ __scopeCheckbox, ...props }, forwardedRef) => {\n const {\n control,\n hasConsumerStoppedPropagationRef,\n checked,\n defaultChecked,\n required,\n disabled,\n name,\n value,\n form,\n bubbleInput,\n setBubbleInput\n } = useCheckboxContext(BUBBLE_INPUT_NAME, __scopeCheckbox);\n const composedRefs = useComposedRefs(forwardedRef, setBubbleInput);\n const prevChecked = usePrevious(checked);\n const controlSize = useSize(control);\n React.useEffect(() => {\n const input = bubbleInput;\n if (!input) return;\n const inputProto = window.HTMLInputElement.prototype;\n const descriptor = Object.getOwnPropertyDescriptor(\n inputProto,\n \"checked\"\n );\n const setChecked = descriptor.set;\n const bubbles = !hasConsumerStoppedPropagationRef.current;\n if (prevChecked !== checked && setChecked) {\n const event = new Event(\"click\", { bubbles });\n input.indeterminate = isIndeterminate(checked);\n setChecked.call(input, isIndeterminate(checked) ? false : checked);\n input.dispatchEvent(event);\n }\n }, [bubbleInput, prevChecked, checked, hasConsumerStoppedPropagationRef]);\n const defaultCheckedRef = React.useRef(isIndeterminate(checked) ? false : checked);\n return /* @__PURE__ */ jsx(\n Primitive.input,\n {\n type: \"checkbox\",\n \"aria-hidden\": true,\n defaultChecked: defaultChecked ?? defaultCheckedRef.current,\n required,\n disabled,\n name,\n value,\n form,\n ...props,\n tabIndex: -1,\n ref: composedRefs,\n style: {\n ...props.style,\n ...controlSize,\n position: \"absolute\",\n pointerEvents: \"none\",\n opacity: 0,\n margin: 0,\n // We transform because the input is absolutely positioned but we have\n // rendered it **after** the button. This pulls it back to sit on top\n // of the button.\n transform: \"translateX(-100%)\"\n }\n }\n );\n }\n);\nCheckboxBubbleInput.displayName = BUBBLE_INPUT_NAME;\nfunction isFunction(value) {\n return typeof value === \"function\";\n}\nfunction isIndeterminate(checked) {\n return checked === \"indeterminate\";\n}\nfunction getState(checked) {\n return isIndeterminate(checked) ? \"indeterminate\" : checked ? \"checked\" : \"unchecked\";\n}\nexport {\n Checkbox,\n CheckboxIndicator,\n CheckboxIndicator as Indicator,\n Checkbox as Root,\n createCheckboxScope,\n CheckboxBubbleInput as unstable_BubbleInput,\n CheckboxBubbleInput as unstable_CheckboxBubbleInput,\n CheckboxProvider as unstable_CheckboxProvider,\n CheckboxTrigger as unstable_CheckboxTrigger,\n CheckboxProvider as unstable_Provider,\n CheckboxTrigger as unstable_Trigger\n};\n//# sourceMappingURL=index.mjs.map\n","import React from \"react\";\nimport * as CheckboxPrimitive from \"@radix-ui/react-checkbox\";\nimport { Check } from \"lucide-react\";\nimport { cn } from \"@/utils/cn\";\n\nexport interface CheckboxProps extends React.ComponentPropsWithoutRef<\n typeof CheckboxPrimitive.Root\n> {\n label?: string;\n id?: string;\n}\n\nexport const Checkbox = React.forwardRef<\n React.ElementRef<typeof CheckboxPrimitive.Root>,\n CheckboxProps\n>(({ className, label, id, disabled, ...props }, ref) => {\n const checkboxId =\n id || `checkbox-${Math.random().toString(36).substr(2, 9)}`;\n\n return (\n <div className=\"flex items-center\">\n <CheckboxPrimitive.Root\n ref={ref}\n id={checkboxId}\n disabled={disabled}\n className={cn(\n \"peer h-[17px] w-[17px] shrink-0 rounded\",\n \"border border-gray-400 bg-white\",\n \"focus-visible:outline-none\",\n \"focus-visible:ring-2\",\n \"focus-visible:ring-offset-2\",\n \"disabled:cursor-not-allowed disabled:opacity-50\",\n \"data-[state=checked]:bg-black data-[state=checked]:border-black\",\n \"transition-colors\",\n className\n )}\n {...props}\n >\n <CheckboxPrimitive.Indicator\n className={cn(\"flex items-center justify-center\", \"text-white\")}\n >\n <Check className=\"h-3 w-3\" strokeWidth={3} />\n </CheckboxPrimitive.Indicator>\n </CheckboxPrimitive.Root>\n {label && (\n <label\n htmlFor={checkboxId}\n className={cn(\n \"ml-2 text-base font-normal text-gray-500\",\n \"hover:text-black transition-colors\",\n disabled && \"cursor-not-allowed opacity-50\",\n \"cursor-pointer select-none\"\n )}\n >\n {label}\n </label>\n )}\n </div>\n );\n});\n\nCheckbox.displayName = \"Checkbox\";\n","\"use client\";\n\n// src/dialog.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContext, createContextScope } from \"@radix-ui/react-context\";\nimport { useId } from \"@radix-ui/react-id\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { DismissableLayer } from \"@radix-ui/react-dismissable-layer\";\nimport { FocusScope } from \"@radix-ui/react-focus-scope\";\nimport { Portal as PortalPrimitive } from \"@radix-ui/react-portal\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useFocusGuards } from \"@radix-ui/react-focus-guards\";\nimport { RemoveScroll } from \"react-remove-scroll\";\nimport { hideOthers } from \"aria-hidden\";\nimport { createSlot } from \"@radix-ui/react-slot\";\nimport { Fragment, jsx, jsxs } from \"react/jsx-runtime\";\nvar DIALOG_NAME = \"Dialog\";\nvar [createDialogContext, createDialogScope] = createContextScope(DIALOG_NAME);\nvar [DialogProvider, useDialogContext] = createDialogContext(DIALOG_NAME);\nvar Dialog = (props) => {\n const {\n __scopeDialog,\n children,\n open: openProp,\n defaultOpen,\n onOpenChange,\n modal = true\n } = props;\n const triggerRef = React.useRef(null);\n const contentRef = React.useRef(null);\n const [open, setOpen] = useControllableState({\n prop: openProp,\n defaultProp: defaultOpen ?? false,\n onChange: onOpenChange,\n caller: DIALOG_NAME\n });\n return /* @__PURE__ */ jsx(\n DialogProvider,\n {\n scope: __scopeDialog,\n triggerRef,\n contentRef,\n contentId: useId(),\n titleId: useId(),\n descriptionId: useId(),\n open,\n onOpenChange: setOpen,\n onOpenToggle: React.useCallback(() => setOpen((prevOpen) => !prevOpen), [setOpen]),\n modal,\n children\n }\n );\n};\nDialog.displayName = DIALOG_NAME;\nvar TRIGGER_NAME = \"DialogTrigger\";\nvar DialogTrigger = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeDialog, ...triggerProps } = props;\n const context = useDialogContext(TRIGGER_NAME, __scopeDialog);\n const composedTriggerRef = useComposedRefs(forwardedRef, context.triggerRef);\n return /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n \"aria-haspopup\": \"dialog\",\n \"aria-expanded\": context.open,\n \"aria-controls\": context.contentId,\n \"data-state\": getState(context.open),\n ...triggerProps,\n ref: composedTriggerRef,\n onClick: composeEventHandlers(props.onClick, context.onOpenToggle)\n }\n );\n }\n);\nDialogTrigger.displayName = TRIGGER_NAME;\nvar PORTAL_NAME = \"DialogPortal\";\nvar [PortalProvider, usePortalContext] = createDialogContext(PORTAL_NAME, {\n forceMount: void 0\n});\nvar DialogPortal = (props) => {\n const { __scopeDialog, forceMount, children, container } = props;\n const context = useDialogContext(PORTAL_NAME, __scopeDialog);\n return /* @__PURE__ */ jsx(PortalProvider, { scope: __scopeDialog, forceMount, children: React.Children.map(children, (child) => /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(PortalPrimitive, { asChild: true, container, children: child }) })) });\n};\nDialogPortal.displayName = PORTAL_NAME;\nvar OVERLAY_NAME = \"DialogOverlay\";\nvar DialogOverlay = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(OVERLAY_NAME, props.__scopeDialog);\n const { forceMount = portalContext.forceMount, ...overlayProps } = props;\n const context = useDialogContext(OVERLAY_NAME, props.__scopeDialog);\n return context.modal ? /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(DialogOverlayImpl, { ...overlayProps, ref: forwardedRef }) }) : null;\n }\n);\nDialogOverlay.displayName = OVERLAY_NAME;\nvar Slot = createSlot(\"DialogOverlay.RemoveScroll\");\nvar DialogOverlayImpl = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeDialog, ...overlayProps } = props;\n const context = useDialogContext(OVERLAY_NAME, __scopeDialog);\n return (\n // Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`\n // ie. when `Overlay` and `Content` are siblings\n /* @__PURE__ */ jsx(RemoveScroll, { as: Slot, allowPinchZoom: true, shards: [context.contentRef], children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n \"data-state\": getState(context.open),\n ...overlayProps,\n ref: forwardedRef,\n style: { pointerEvents: \"auto\", ...overlayProps.style }\n }\n ) })\n );\n }\n);\nvar CONTENT_NAME = \"DialogContent\";\nvar DialogContent = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(CONTENT_NAME, props.__scopeDialog);\n const { forceMount = portalContext.forceMount, ...contentProps } = props;\n const context = useDialogContext(CONTENT_NAME, props.__scopeDialog);\n return /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: context.modal ? /* @__PURE__ */ jsx(DialogContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ jsx(DialogContentNonModal, { ...contentProps, ref: forwardedRef }) });\n }\n);\nDialogContent.displayName = CONTENT_NAME;\nvar DialogContentModal = React.forwardRef(\n (props, forwardedRef) => {\n const context = useDialogContext(CONTENT_NAME, props.__scopeDialog);\n const contentRef = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, context.contentRef, contentRef);\n React.useEffect(() => {\n const content = contentRef.current;\n if (content) return hideOthers(content);\n }, []);\n return /* @__PURE__ */ jsx(\n DialogContentImpl,\n {\n ...props,\n ref: composedRefs,\n trapFocus: context.open,\n disableOutsidePointerEvents: true,\n onCloseAutoFocus: composeEventHandlers(props.onCloseAutoFocus, (event) => {\n event.preventDefault();\n context.triggerRef.current?.focus();\n }),\n onPointerDownOutside: composeEventHandlers(props.onPointerDownOutside, (event) => {\n const originalEvent = event.detail.originalEvent;\n const ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === true;\n const isRightClick = originalEvent.button === 2 || ctrlLeftClick;\n if (isRightClick) event.preventDefault();\n }),\n onFocusOutside: composeEventHandlers(\n props.onFocusOutside,\n (event) => event.preventDefault()\n )\n }\n );\n }\n);\nvar DialogContentNonModal = React.forwardRef(\n (props, forwardedRef) => {\n const context = useDialogContext(CONTENT_NAME, props.__scopeDialog);\n const hasInteractedOutsideRef = React.useRef(false);\n const hasPointerDownOutsideRef = React.useRef(false);\n return /* @__PURE__ */ jsx(\n DialogContentImpl,\n {\n ...props,\n ref: forwardedRef,\n trapFocus: false,\n disableOutsidePointerEvents: false,\n onCloseAutoFocus: (event) => {\n props.onCloseAutoFocus?.(event);\n if (!event.defaultPrevented) {\n if (!hasInteractedOutsideRef.current) context.triggerRef.current?.focus();\n event.preventDefault();\n }\n hasInteractedOutsideRef.current = false;\n hasPointerDownOutsideRef.current = false;\n },\n onInteractOutside: (event) => {\n props.onInteractOutside?.(event);\n if (!event.defaultPrevented) {\n hasInteractedOutsideRef.current = true;\n if (event.detail.originalEvent.type === \"pointerdown\") {\n hasPointerDownOutsideRef.current = true;\n }\n }\n const target = event.target;\n const targetIsTrigger = context.triggerRef.current?.contains(target);\n if (targetIsTrigger) event.preventDefault();\n if (event.detail.originalEvent.type === \"focusin\" && hasPointerDownOutsideRef.current) {\n event.preventDefault();\n }\n }\n }\n );\n }\n);\nvar DialogContentImpl = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeDialog, trapFocus, onOpenAutoFocus, onCloseAutoFocus, ...contentProps } = props;\n const context = useDialogContext(CONTENT_NAME, __scopeDialog);\n const contentRef = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, contentRef);\n useFocusGuards();\n return /* @__PURE__ */ jsxs(Fragment, { children: [\n /* @__PURE__ */ jsx(\n FocusScope,\n {\n asChild: true,\n loop: true,\n trapped: trapFocus,\n onMountAutoFocus: onOpenAutoFocus,\n onUnmountAutoFocus: onCloseAutoFocus,\n children: /* @__PURE__ */ jsx(\n DismissableLayer,\n {\n role: \"dialog\",\n id: context.contentId,\n \"aria-describedby\": context.descriptionId,\n \"aria-labelledby\": context.titleId,\n \"data-state\": getState(context.open),\n ...contentProps,\n ref: composedRefs,\n onDismiss: () => context.onOpenChange(false)\n }\n )\n }\n ),\n /* @__PURE__ */ jsxs(Fragment, { children: [\n /* @__PURE__ */ jsx(TitleWarning, { titleId: context.titleId }),\n /* @__PURE__ */ jsx(DescriptionWarning, { contentRef, descriptionId: context.descriptionId })\n ] })\n ] });\n }\n);\nvar TITLE_NAME = \"DialogTitle\";\nvar DialogTitle = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeDialog, ...titleProps } = props;\n const context = useDialogContext(TITLE_NAME, __scopeDialog);\n return /* @__PURE__ */ jsx(Primitive.h2, { id: context.titleId, ...titleProps, ref: forwardedRef });\n }\n);\nDialogTitle.displayName = TITLE_NAME;\nvar DESCRIPTION_NAME = \"DialogDescription\";\nvar DialogDescription = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeDialog, ...descriptionProps } = props;\n const context = useDialogContext(DESCRIPTION_NAME, __scopeDialog);\n return /* @__PURE__ */ jsx(Primitive.p, { id: context.descriptionId, ...descriptionProps, ref: forwardedRef });\n }\n);\nDialogDescription.displayName = DESCRIPTION_NAME;\nvar CLOSE_NAME = \"DialogClose\";\nvar DialogClose = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeDialog, ...closeProps } = props;\n const context = useDialogContext(CLOSE_NAME, __scopeDialog);\n return /* @__PURE__ */ jsx(\n Primitive.button,\n {\n type: \"button\",\n ...closeProps,\n ref: forwardedRef,\n onClick: composeEventHandlers(props.onClick, () => context.onOpenChange(false))\n }\n );\n }\n);\nDialogClose.displayName = CLOSE_NAME;\nfunction getState(open) {\n return open ? \"open\" : \"closed\";\n}\nvar TITLE_WARNING_NAME = \"DialogTitleWarning\";\nvar [WarningProvider, useWarningContext] = createContext(TITLE_WARNING_NAME, {\n contentName: CONTENT_NAME,\n titleName: TITLE_NAME,\n docsSlug: \"dialog\"\n});\nvar TitleWarning = ({ titleId }) => {\n const titleWarningContext = useWarningContext(TITLE_WARNING_NAME);\n const MESSAGE = `\\`${titleWarningContext.contentName}\\` requires a \\`${titleWarningContext.titleName}\\` for the component to be accessible for screen reader users.\n\nIf you want to hide the \\`${titleWarningContext.titleName}\\`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/${titleWarningContext.docsSlug}`;\n React.useEffect(() => {\n if (titleId) {\n const hasTitle = document.getElementById(titleId);\n if (!hasTitle) console.error(MESSAGE);\n }\n }, [MESSAGE, titleId]);\n return null;\n};\nvar DESCRIPTION_WARNING_NAME = \"DialogDescriptionWarning\";\nvar DescriptionWarning = ({ contentRef, descriptionId }) => {\n const descriptionWarningContext = useWarningContext(DESCRIPTION_WARNING_NAME);\n const MESSAGE = `Warning: Missing \\`Description\\` or \\`aria-describedby={undefined}\\` for {${descriptionWarningContext.contentName}}.`;\n React.useEffect(() => {\n const describedById = contentRef.current?.getAttribute(\"aria-describedby\");\n if (descriptionId && describedById) {\n const hasDescription = document.getElementById(descriptionId);\n if (!hasDescription) console.warn(MESSAGE);\n }\n }, [MESSAGE, contentRef, descriptionId]);\n return null;\n};\nvar Root = Dialog;\nvar Trigger = DialogTrigger;\nvar Portal = DialogPortal;\nvar Overlay = DialogOverlay;\nvar Content = DialogContent;\nvar Title = DialogTitle;\nvar Description = DialogDescription;\nvar Close = DialogClose;\nexport {\n Close,\n Content,\n Description,\n Dialog,\n DialogClose,\n DialogContent,\n DialogDescription,\n DialogOverlay,\n DialogPortal,\n DialogTitle,\n DialogTrigger,\n Overlay,\n Portal,\n Root,\n Title,\n Trigger,\n WarningProvider,\n createDialogScope\n};\n//# sourceMappingURL=index.mjs.map\n","import React from \"react\";\nimport * as DialogPrimitive from \"@radix-ui/react-dialog\";\nimport { X } from \"lucide-react\";\nimport { cn } from \"@/utils/cn\";\n\nexport interface ModalProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n icon?: React.ReactNode;\n title?: React.ReactNode;\n children: React.ReactNode;\n footer?: React.ReactNode;\n className?: string;\n showCloseButton?: boolean;\n size?: \"sm\" | \"md\" | \"lg\";\n}\n\nconst sizeClasses = {\n sm: \"max-w-sm\",\n md: \"max-w-md\",\n lg: \"max-w-lg\",\n};\n\nexport const Modal = React.forwardRef<HTMLDivElement, ModalProps>(\n (\n {\n open,\n onOpenChange,\n icon,\n title,\n children,\n footer,\n className,\n showCloseButton = true,\n size = \"md\",\n },\n ref,\n ) => {\n return (\n <DialogPrimitive.Root open={open} onOpenChange={onOpenChange}>\n <DialogPrimitive.Portal>\n <DialogPrimitive.Overlay\n className={cn(\n \"fixed inset-0 z-50 bg-black/50\",\n \"data-[state=open]:animate-in data-[state=closed]:animate-out\",\n \"data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0\",\n )}\n />\n <DialogPrimitive.Content\n ref={ref}\n className={cn(\n \"fixed left-[50%] top-[50%] z-50\",\n \"translate-x-[-50%] translate-y-[-50%]\",\n \"w-full\",\n sizeClasses[size],\n \"bg-white rounded-lg shadow-lg\",\n \"p-6\",\n \"data-[state=open]:animate-in data-[state=closed]:animate-out\",\n \"data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0\",\n \"data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95\",\n className,\n )}\n >\n {showCloseButton && (\n <DialogPrimitive.Close\n className={cn(\n \"absolute right-4 top-4 rounded-sm opacity-70\",\n \"transition-opacity hover:opacity-100\",\n \"focus:outline-none focus:ring-2 focus:ring-cms-gray-400\",\n \"disabled:pointer-events-none\",\n )}\n >\n <X className=\"h-4 w-4\" />\n <span className=\"sr-only\">Close</span>\n </DialogPrimitive.Close>\n )}\n\n {icon && <div className=\"flex justify-center mb-4\">{icon}</div>}\n\n {title && (\n <DialogPrimitive.Title\n className={cn(\n \"text-lg font-bold text-cms-gray-900 mb-2\",\n \"flex items-center justify-center\",\n )}\n >\n {title}\n </DialogPrimitive.Title>\n )}\n\n <DialogPrimitive.Description className=\"text-sm text-cms-gray-700 text-center\">\n {children}\n </DialogPrimitive.Description>\n\n {footer && <div className=\"mt-6\">{footer}</div>}\n </DialogPrimitive.Content>\n </DialogPrimitive.Portal>\n </DialogPrimitive.Root>\n );\n },\n);\n\nModal.displayName = \"Modal\";\n","import React from \"react\";\nimport { CheckCircle2 } from \"lucide-react\";\nimport { Modal } from \"./Modal\";\nimport { Button } from \"../Button/Button\";\n\nexport interface ConfirmModalProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n title?: string;\n message: React.ReactNode;\n confirmText?: string;\n onConfirm?: () => void;\n className?: string;\n}\n\nexport const ConfirmModal = React.forwardRef<HTMLDivElement, ConfirmModalProps>(\n (\n {\n open,\n onOpenChange,\n title = \"확인\",\n message,\n confirmText = \"확인\",\n onConfirm,\n className,\n },\n ref,\n ) => {\n const handleConfirm = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n return (\n <Modal\n ref={ref}\n open={open}\n onOpenChange={onOpenChange}\n title={title}\n footer={\n <Button\n onClick={handleConfirm}\n className=\"w-full h-12 bg-cms-gray-850 hover:bg-cms-gray-800\"\n >\n {confirmText}\n </Button>\n }\n className={className}\n size=\"sm\"\n showCloseButton={false}\n icon={<CheckCircle2 className=\"w-15 h-15 text-cms-black\" />}\n >\n <div className=\"text-sm text-cms-gray-700\">{message}</div>\n </Modal>\n );\n },\n);\n\nConfirmModal.displayName = \"ConfirmModal\";\n","import React from \"react\";\nimport { AlertTriangle } from \"lucide-react\";\nimport { Modal } from \"./Modal\";\nimport { Button } from \"../Button/Button\";\nimport { cn } from \"@/utils/cn\";\n\nexport interface DeleteModalProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n title?: string;\n message?: React.ReactNode;\n confirmText?: string;\n cancelText?: string;\n onConfirm: () => void;\n onCancel?: () => void;\n className?: string;\n}\n\nexport const DeleteModal = React.forwardRef<HTMLDivElement, DeleteModalProps>(\n (\n {\n open,\n onOpenChange,\n title = \"삭제\",\n message = \"정말로 삭제하시겠습니까?\",\n confirmText = \"삭제\",\n cancelText = \"취소\",\n onConfirm,\n onCancel,\n className,\n },\n ref,\n ) => {\n const handleConfirm = () => {\n onConfirm();\n onOpenChange(false);\n };\n\n const handleCancel = () => {\n onCancel?.();\n onOpenChange(false);\n };\n\n return (\n <Modal\n ref={ref}\n open={open}\n onOpenChange={onOpenChange}\n icon={<AlertTriangle className=\"w-15 h-15 text-cms-red-400\" />}\n title={title}\n footer={\n <div className=\"flex gap-2 w-full\">\n <Button\n onClick={handleCancel}\n variant=\"outline\"\n className=\"flex-1 h-12\"\n >\n {cancelText}\n </Button>\n <Button\n onClick={handleConfirm}\n className={cn(\n \"flex-1 h-12\",\n \"bg-cms-red-400 hover:bg-cms-red-500\",\n )}\n >\n {confirmText}\n </Button>\n </div>\n }\n className={className}\n size=\"sm\"\n showCloseButton={false}\n >\n <div className=\"text-sm text-cms-gray-700\">{message}</div>\n </Modal>\n );\n },\n);\n\nDeleteModal.displayName = \"DeleteModal\";\n","import React from \"react\";\nimport { XCircle } from \"lucide-react\";\nimport { Modal } from \"./Modal\";\nimport { Button } from \"../Button/Button\";\n\nexport interface ErrorModalProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n title?: string;\n message: React.ReactNode;\n confirmText?: string;\n onConfirm?: () => void;\n className?: string;\n}\n\nexport const ErrorModal = React.forwardRef<HTMLDivElement, ErrorModalProps>(\n (\n {\n open,\n onOpenChange,\n title = \"오류\",\n message,\n confirmText = \"확인\",\n onConfirm,\n className,\n },\n ref,\n ) => {\n const handleConfirm = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n return (\n <Modal\n ref={ref}\n open={open}\n onOpenChange={onOpenChange}\n icon={<XCircle className=\"w-15 h-15 text-cms-red-400\" />}\n title={title}\n footer={\n <Button\n onClick={handleConfirm}\n className=\"w-full h-12 bg-cms-gray-850 hover:bg-cms-gray-800\"\n >\n {confirmText}\n </Button>\n }\n className={className}\n size=\"sm\"\n showCloseButton={false}\n >\n <div className=\"text-sm text-cms-gray-700\">{message}</div>\n </Modal>\n );\n },\n);\n\nErrorModal.displayName = \"ErrorModal\";\n","import React from \"react\";\nimport { AlertTriangle } from \"lucide-react\";\nimport { Modal } from \"./Modal\";\nimport { Button } from \"../Button/Button\";\n\nexport interface WarningModalProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n title?: string;\n message: React.ReactNode;\n confirmText?: string;\n onConfirm?: () => void;\n // 추가된 Props\n cancelText?: string;\n onCancel?: () => void;\n className?: string;\n}\n\nexport const WarningModal = React.forwardRef<HTMLDivElement, WarningModalProps>(\n (\n {\n open,\n onOpenChange,\n title = \"경고\",\n message,\n confirmText = \"확인\",\n onConfirm,\n // 기본값 설정\n cancelText = \"취소\",\n onCancel,\n className,\n },\n ref,\n ) => {\n const handleConfirm = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n // 취소 핸들러 추가\n const handleCancel = () => {\n onCancel?.();\n onOpenChange(false);\n };\n\n return (\n <Modal\n ref={ref}\n open={open}\n onOpenChange={onOpenChange}\n icon={<AlertTriangle className=\"w-15 h-15 text-cms-orange-500\" />}\n title={title}\n footer={\n // 버튼 두 개를 가로로 배치하기 위해 flex 컨테이너 사용\n <div className=\"flex w-full gap-2\">\n <Button\n onClick={handleCancel}\n className=\"flex-1 h-12 bg-white border border-cms-gray-200 text-cms-gray-700 hover:bg-cms-gray-50\"\n >\n {cancelText}\n </Button>\n <Button\n onClick={handleConfirm}\n className=\"flex-1 h-12 bg-cms-gray-850 hover:bg-cms-gray-800\"\n >\n {confirmText}\n </Button>\n </div>\n }\n className={className}\n size=\"sm\"\n showCloseButton={false}\n >\n <div className=\"text-sm text-cms-gray-700\">{message}</div>\n </Modal>\n );\n },\n);\n\nWarningModal.displayName = \"WarningModal\";\n","import React from \"react\";\nimport { CheckCircle2 } from \"lucide-react\";\nimport { Modal } from \"./Modal\";\nimport { Button } from \"../Button/Button\";\n\nexport interface SuccessModalProps {\n open: boolean;\n onOpenChange: (open: boolean) => void;\n title?: string;\n message: React.ReactNode;\n confirmText?: string;\n onConfirm?: () => void;\n className?: string;\n}\n\nexport const SuccessModal = React.forwardRef<HTMLDivElement, SuccessModalProps>(\n (\n {\n open,\n onOpenChange,\n title = \"성공\",\n message,\n confirmText = \"확인\",\n onConfirm,\n className,\n },\n ref,\n ) => {\n const handleConfirm = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n return (\n <Modal\n ref={ref}\n open={open}\n onOpenChange={onOpenChange}\n icon={\n <CheckCircle2 className=\"w-15 h-15 text-cms-green-500 border-cms-green-500\" />\n }\n title={title}\n footer={\n <Button\n onClick={handleConfirm}\n className=\"w-full h-12 bg-cms-gray-850 hover:bg-cms-gray-800\"\n >\n {confirmText}\n </Button>\n }\n className={className}\n size=\"sm\"\n showCloseButton={false}\n >\n <div className=\"text-sm text-cms-gray-700\">{message}</div>\n </Modal>\n );\n },\n);\n\nSuccessModal.displayName = \"SuccessModal\";\n","'use client';\nfunction __insertCSS(code) {\n if (!code || typeof document == 'undefined') return\n let head = document.head || document.getElementsByTagName('head')[0]\n let style = document.createElement('style')\n style.type = 'text/css'\n head.appendChild(style)\n ;style.styleSheet ? (style.styleSheet.cssText = code) : style.appendChild(document.createTextNode(code))\n}\n\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\nconst getAsset = (type)=>{\n switch(type){\n case 'success':\n return SuccessIcon;\n case 'info':\n return InfoIcon;\n case 'warning':\n return WarningIcon;\n case 'error':\n return ErrorIcon;\n default:\n return null;\n }\n};\nconst bars = Array(12).fill(0);\nconst Loader = ({ visible, className })=>{\n return /*#__PURE__*/ React.createElement(\"div\", {\n className: [\n 'sonner-loading-wrapper',\n className\n ].filter(Boolean).join(' '),\n \"data-visible\": visible\n }, /*#__PURE__*/ React.createElement(\"div\", {\n className: \"sonner-spinner\"\n }, bars.map((_, i)=>/*#__PURE__*/ React.createElement(\"div\", {\n className: \"sonner-loading-bar\",\n key: `spinner-bar-${i}`\n }))));\n};\nconst SuccessIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 20 20\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z\",\n clipRule: \"evenodd\"\n}));\nconst WarningIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 24 24\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z\",\n clipRule: \"evenodd\"\n}));\nconst InfoIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 20 20\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z\",\n clipRule: \"evenodd\"\n}));\nconst ErrorIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 20 20\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z\",\n clipRule: \"evenodd\"\n}));\nconst CloseIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n width: \"12\",\n height: \"12\",\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n stroke: \"currentColor\",\n strokeWidth: \"1.5\",\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\"\n}, /*#__PURE__*/ React.createElement(\"line\", {\n x1: \"18\",\n y1: \"6\",\n x2: \"6\",\n y2: \"18\"\n}), /*#__PURE__*/ React.createElement(\"line\", {\n x1: \"6\",\n y1: \"6\",\n x2: \"18\",\n y2: \"18\"\n}));\n\nconst useIsDocumentHidden = ()=>{\n const [isDocumentHidden, setIsDocumentHidden] = React.useState(document.hidden);\n React.useEffect(()=>{\n const callback = ()=>{\n setIsDocumentHidden(document.hidden);\n };\n document.addEventListener('visibilitychange', callback);\n return ()=>window.removeEventListener('visibilitychange', callback);\n }, []);\n return isDocumentHidden;\n};\n\nlet toastsCounter = 1;\nclass Observer {\n constructor(){\n // We use arrow functions to maintain the correct `this` reference\n this.subscribe = (subscriber)=>{\n this.subscribers.push(subscriber);\n return ()=>{\n const index = this.subscribers.indexOf(subscriber);\n this.subscribers.splice(index, 1);\n };\n };\n this.publish = (data)=>{\n this.subscribers.forEach((subscriber)=>subscriber(data));\n };\n this.addToast = (data)=>{\n this.publish(data);\n this.toasts = [\n ...this.toasts,\n data\n ];\n };\n this.create = (data)=>{\n var _data_id;\n const { message, ...rest } = data;\n const id = typeof (data == null ? void 0 : data.id) === 'number' || ((_data_id = data.id) == null ? void 0 : _data_id.length) > 0 ? data.id : toastsCounter++;\n const alreadyExists = this.toasts.find((toast)=>{\n return toast.id === id;\n });\n const dismissible = data.dismissible === undefined ? true : data.dismissible;\n if (this.dismissedToasts.has(id)) {\n this.dismissedToasts.delete(id);\n }\n if (alreadyExists) {\n this.toasts = this.toasts.map((toast)=>{\n if (toast.id === id) {\n this.publish({\n ...toast,\n ...data,\n id,\n title: message\n });\n return {\n ...toast,\n ...data,\n id,\n dismissible,\n title: message\n };\n }\n return toast;\n });\n } else {\n this.addToast({\n title: message,\n ...rest,\n dismissible,\n id\n });\n }\n return id;\n };\n this.dismiss = (id)=>{\n if (id) {\n this.dismissedToasts.add(id);\n requestAnimationFrame(()=>this.subscribers.forEach((subscriber)=>subscriber({\n id,\n dismiss: true\n })));\n } else {\n this.toasts.forEach((toast)=>{\n this.subscribers.forEach((subscriber)=>subscriber({\n id: toast.id,\n dismiss: true\n }));\n });\n }\n return id;\n };\n this.message = (message, data)=>{\n return this.create({\n ...data,\n message\n });\n };\n this.error = (message, data)=>{\n return this.create({\n ...data,\n message,\n type: 'error'\n });\n };\n this.success = (message, data)=>{\n return this.create({\n ...data,\n type: 'success',\n message\n });\n };\n this.info = (message, data)=>{\n return this.create({\n ...data,\n type: 'info',\n message\n });\n };\n this.warning = (message, data)=>{\n return this.create({\n ...data,\n type: 'warning',\n message\n });\n };\n this.loading = (message, data)=>{\n return this.create({\n ...data,\n type: 'loading',\n message\n });\n };\n this.promise = (promise, data)=>{\n if (!data) {\n // Nothing to show\n return;\n }\n let id = undefined;\n if (data.loading !== undefined) {\n id = this.create({\n ...data,\n promise,\n type: 'loading',\n message: data.loading,\n description: typeof data.description !== 'function' ? data.description : undefined\n });\n }\n const p = Promise.resolve(promise instanceof Function ? promise() : promise);\n let shouldDismiss = id !== undefined;\n let result;\n const originalPromise = p.then(async (response)=>{\n result = [\n 'resolve',\n response\n ];\n const isReactElementResponse = React.isValidElement(response);\n if (isReactElementResponse) {\n shouldDismiss = false;\n this.create({\n id,\n type: 'default',\n message: response\n });\n } else if (isHttpResponse(response) && !response.ok) {\n shouldDismiss = false;\n const promiseData = typeof data.error === 'function' ? await data.error(`HTTP error! status: ${response.status}`) : data.error;\n const description = typeof data.description === 'function' ? await data.description(`HTTP error! status: ${response.status}`) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'error',\n description,\n ...toastSettings\n });\n } else if (response instanceof Error) {\n shouldDismiss = false;\n const promiseData = typeof data.error === 'function' ? await data.error(response) : data.error;\n const description = typeof data.description === 'function' ? await data.description(response) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'error',\n description,\n ...toastSettings\n });\n } else if (data.success !== undefined) {\n shouldDismiss = false;\n const promiseData = typeof data.success === 'function' ? await data.success(response) : data.success;\n const description = typeof data.description === 'function' ? await data.description(response) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'success',\n description,\n ...toastSettings\n });\n }\n }).catch(async (error)=>{\n result = [\n 'reject',\n error\n ];\n if (data.error !== undefined) {\n shouldDismiss = false;\n const promiseData = typeof data.error === 'function' ? await data.error(error) : data.error;\n const description = typeof data.description === 'function' ? await data.description(error) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'error',\n description,\n ...toastSettings\n });\n }\n }).finally(()=>{\n if (shouldDismiss) {\n // Toast is still in load state (and will be indefinitely — dismiss it)\n this.dismiss(id);\n id = undefined;\n }\n data.finally == null ? void 0 : data.finally.call(data);\n });\n const unwrap = ()=>new Promise((resolve, reject)=>originalPromise.then(()=>result[0] === 'reject' ? reject(result[1]) : resolve(result[1])).catch(reject));\n if (typeof id !== 'string' && typeof id !== 'number') {\n // cannot Object.assign on undefined\n return {\n unwrap\n };\n } else {\n return Object.assign(id, {\n unwrap\n });\n }\n };\n this.custom = (jsx, data)=>{\n const id = (data == null ? void 0 : data.id) || toastsCounter++;\n this.create({\n jsx: jsx(id),\n id,\n ...data\n });\n return id;\n };\n this.getActiveToasts = ()=>{\n return this.toasts.filter((toast)=>!this.dismissedToasts.has(toast.id));\n };\n this.subscribers = [];\n this.toasts = [];\n this.dismissedToasts = new Set();\n }\n}\nconst ToastState = new Observer();\n// bind this to the toast function\nconst toastFunction = (message, data)=>{\n const id = (data == null ? void 0 : data.id) || toastsCounter++;\n ToastState.addToast({\n title: message,\n ...data,\n id\n });\n return id;\n};\nconst isHttpResponse = (data)=>{\n return data && typeof data === 'object' && 'ok' in data && typeof data.ok === 'boolean' && 'status' in data && typeof data.status === 'number';\n};\nconst basicToast = toastFunction;\nconst getHistory = ()=>ToastState.toasts;\nconst getToasts = ()=>ToastState.getActiveToasts();\n// We use `Object.assign` to maintain the correct types as we would lose them otherwise\nconst toast = Object.assign(basicToast, {\n success: ToastState.success,\n info: ToastState.info,\n warning: ToastState.warning,\n error: ToastState.error,\n custom: ToastState.custom,\n message: ToastState.message,\n promise: ToastState.promise,\n dismiss: ToastState.dismiss,\n loading: ToastState.loading\n}, {\n getHistory,\n getToasts\n});\n\n__insertCSS(\"[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}\");\n\nfunction isAction(action) {\n return action.label !== undefined;\n}\n\n// Visible toasts amount\nconst VISIBLE_TOASTS_AMOUNT = 3;\n// Viewport padding\nconst VIEWPORT_OFFSET = '24px';\n// Mobile viewport padding\nconst MOBILE_VIEWPORT_OFFSET = '16px';\n// Default lifetime of a toasts (in ms)\nconst TOAST_LIFETIME = 4000;\n// Default toast width\nconst TOAST_WIDTH = 356;\n// Default gap between toasts\nconst GAP = 14;\n// Threshold to dismiss a toast\nconst SWIPE_THRESHOLD = 45;\n// Equal to exit animation duration\nconst TIME_BEFORE_UNMOUNT = 200;\nfunction cn(...classes) {\n return classes.filter(Boolean).join(' ');\n}\nfunction getDefaultSwipeDirections(position) {\n const [y, x] = position.split('-');\n const directions = [];\n if (y) {\n directions.push(y);\n }\n if (x) {\n directions.push(x);\n }\n return directions;\n}\nconst Toast = (props)=>{\n var _toast_classNames, _toast_classNames1, _toast_classNames2, _toast_classNames3, _toast_classNames4, _toast_classNames5, _toast_classNames6, _toast_classNames7, _toast_classNames8;\n const { invert: ToasterInvert, toast, unstyled, interacting, setHeights, visibleToasts, heights, index, toasts, expanded, removeToast, defaultRichColors, closeButton: closeButtonFromToaster, style, cancelButtonStyle, actionButtonStyle, className = '', descriptionClassName = '', duration: durationFromToaster, position, gap, expandByDefault, classNames, icons, closeButtonAriaLabel = 'Close toast' } = props;\n const [swipeDirection, setSwipeDirection] = React.useState(null);\n const [swipeOutDirection, setSwipeOutDirection] = React.useState(null);\n const [mounted, setMounted] = React.useState(false);\n const [removed, setRemoved] = React.useState(false);\n const [swiping, setSwiping] = React.useState(false);\n const [swipeOut, setSwipeOut] = React.useState(false);\n const [isSwiped, setIsSwiped] = React.useState(false);\n const [offsetBeforeRemove, setOffsetBeforeRemove] = React.useState(0);\n const [initialHeight, setInitialHeight] = React.useState(0);\n const remainingTime = React.useRef(toast.duration || durationFromToaster || TOAST_LIFETIME);\n const dragStartTime = React.useRef(null);\n const toastRef = React.useRef(null);\n const isFront = index === 0;\n const isVisible = index + 1 <= visibleToasts;\n const toastType = toast.type;\n const dismissible = toast.dismissible !== false;\n const toastClassname = toast.className || '';\n const toastDescriptionClassname = toast.descriptionClassName || '';\n // Height index is used to calculate the offset as it gets updated before the toast array, which means we can calculate the new layout faster.\n const heightIndex = React.useMemo(()=>heights.findIndex((height)=>height.toastId === toast.id) || 0, [\n heights,\n toast.id\n ]);\n const closeButton = React.useMemo(()=>{\n var _toast_closeButton;\n return (_toast_closeButton = toast.closeButton) != null ? _toast_closeButton : closeButtonFromToaster;\n }, [\n toast.closeButton,\n closeButtonFromToaster\n ]);\n const duration = React.useMemo(()=>toast.duration || durationFromToaster || TOAST_LIFETIME, [\n toast.duration,\n durationFromToaster\n ]);\n const closeTimerStartTimeRef = React.useRef(0);\n const offset = React.useRef(0);\n const lastCloseTimerStartTimeRef = React.useRef(0);\n const pointerStartRef = React.useRef(null);\n const [y, x] = position.split('-');\n const toastsHeightBefore = React.useMemo(()=>{\n return heights.reduce((prev, curr, reducerIndex)=>{\n // Calculate offset up until current toast\n if (reducerIndex >= heightIndex) {\n return prev;\n }\n return prev + curr.height;\n }, 0);\n }, [\n heights,\n heightIndex\n ]);\n const isDocumentHidden = useIsDocumentHidden();\n const invert = toast.invert || ToasterInvert;\n const disabled = toastType === 'loading';\n offset.current = React.useMemo(()=>heightIndex * gap + toastsHeightBefore, [\n heightIndex,\n toastsHeightBefore\n ]);\n React.useEffect(()=>{\n remainingTime.current = duration;\n }, [\n duration\n ]);\n React.useEffect(()=>{\n // Trigger enter animation without using CSS animation\n setMounted(true);\n }, []);\n React.useEffect(()=>{\n const toastNode = toastRef.current;\n if (toastNode) {\n const height = toastNode.getBoundingClientRect().height;\n // Add toast height to heights array after the toast is mounted\n setInitialHeight(height);\n setHeights((h)=>[\n {\n toastId: toast.id,\n height,\n position: toast.position\n },\n ...h\n ]);\n return ()=>setHeights((h)=>h.filter((height)=>height.toastId !== toast.id));\n }\n }, [\n setHeights,\n toast.id\n ]);\n React.useLayoutEffect(()=>{\n // Keep height up to date with the content in case it updates\n if (!mounted) return;\n const toastNode = toastRef.current;\n const originalHeight = toastNode.style.height;\n toastNode.style.height = 'auto';\n const newHeight = toastNode.getBoundingClientRect().height;\n toastNode.style.height = originalHeight;\n setInitialHeight(newHeight);\n setHeights((heights)=>{\n const alreadyExists = heights.find((height)=>height.toastId === toast.id);\n if (!alreadyExists) {\n return [\n {\n toastId: toast.id,\n height: newHeight,\n position: toast.position\n },\n ...heights\n ];\n } else {\n return heights.map((height)=>height.toastId === toast.id ? {\n ...height,\n height: newHeight\n } : height);\n }\n });\n }, [\n mounted,\n toast.title,\n toast.description,\n setHeights,\n toast.id,\n toast.jsx,\n toast.action,\n toast.cancel\n ]);\n const deleteToast = React.useCallback(()=>{\n // Save the offset for the exit swipe animation\n setRemoved(true);\n setOffsetBeforeRemove(offset.current);\n setHeights((h)=>h.filter((height)=>height.toastId !== toast.id));\n setTimeout(()=>{\n removeToast(toast);\n }, TIME_BEFORE_UNMOUNT);\n }, [\n toast,\n removeToast,\n setHeights,\n offset\n ]);\n React.useEffect(()=>{\n if (toast.promise && toastType === 'loading' || toast.duration === Infinity || toast.type === 'loading') return;\n let timeoutId;\n // Pause the timer on each hover\n const pauseTimer = ()=>{\n if (lastCloseTimerStartTimeRef.current < closeTimerStartTimeRef.current) {\n // Get the elapsed time since the timer started\n const elapsedTime = new Date().getTime() - closeTimerStartTimeRef.current;\n remainingTime.current = remainingTime.current - elapsedTime;\n }\n lastCloseTimerStartTimeRef.current = new Date().getTime();\n };\n const startTimer = ()=>{\n // setTimeout(, Infinity) behaves as if the delay is 0.\n // As a result, the toast would be closed immediately, giving the appearance that it was never rendered.\n // See: https://github.com/denysdovhan/wtfjs?tab=readme-ov-file#an-infinite-timeout\n if (remainingTime.current === Infinity) return;\n closeTimerStartTimeRef.current = new Date().getTime();\n // Let the toast know it has started\n timeoutId = setTimeout(()=>{\n toast.onAutoClose == null ? void 0 : toast.onAutoClose.call(toast, toast);\n deleteToast();\n }, remainingTime.current);\n };\n if (expanded || interacting || isDocumentHidden) {\n pauseTimer();\n } else {\n startTimer();\n }\n return ()=>clearTimeout(timeoutId);\n }, [\n expanded,\n interacting,\n toast,\n toastType,\n isDocumentHidden,\n deleteToast\n ]);\n React.useEffect(()=>{\n if (toast.delete) {\n deleteToast();\n toast.onDismiss == null ? void 0 : toast.onDismiss.call(toast, toast);\n }\n }, [\n deleteToast,\n toast.delete\n ]);\n function getLoadingIcon() {\n var _toast_classNames;\n if (icons == null ? void 0 : icons.loading) {\n var _toast_classNames1;\n return /*#__PURE__*/ React.createElement(\"div\", {\n className: cn(classNames == null ? void 0 : classNames.loader, toast == null ? void 0 : (_toast_classNames1 = toast.classNames) == null ? void 0 : _toast_classNames1.loader, 'sonner-loader'),\n \"data-visible\": toastType === 'loading'\n }, icons.loading);\n }\n return /*#__PURE__*/ React.createElement(Loader, {\n className: cn(classNames == null ? void 0 : classNames.loader, toast == null ? void 0 : (_toast_classNames = toast.classNames) == null ? void 0 : _toast_classNames.loader),\n visible: toastType === 'loading'\n });\n }\n const icon = toast.icon || (icons == null ? void 0 : icons[toastType]) || getAsset(toastType);\n var _toast_richColors, _icons_close;\n return /*#__PURE__*/ React.createElement(\"li\", {\n tabIndex: 0,\n ref: toastRef,\n className: cn(className, toastClassname, classNames == null ? void 0 : classNames.toast, toast == null ? void 0 : (_toast_classNames = toast.classNames) == null ? void 0 : _toast_classNames.toast, classNames == null ? void 0 : classNames.default, classNames == null ? void 0 : classNames[toastType], toast == null ? void 0 : (_toast_classNames1 = toast.classNames) == null ? void 0 : _toast_classNames1[toastType]),\n \"data-sonner-toast\": \"\",\n \"data-rich-colors\": (_toast_richColors = toast.richColors) != null ? _toast_richColors : defaultRichColors,\n \"data-styled\": !Boolean(toast.jsx || toast.unstyled || unstyled),\n \"data-mounted\": mounted,\n \"data-promise\": Boolean(toast.promise),\n \"data-swiped\": isSwiped,\n \"data-removed\": removed,\n \"data-visible\": isVisible,\n \"data-y-position\": y,\n \"data-x-position\": x,\n \"data-index\": index,\n \"data-front\": isFront,\n \"data-swiping\": swiping,\n \"data-dismissible\": dismissible,\n \"data-type\": toastType,\n \"data-invert\": invert,\n \"data-swipe-out\": swipeOut,\n \"data-swipe-direction\": swipeOutDirection,\n \"data-expanded\": Boolean(expanded || expandByDefault && mounted),\n \"data-testid\": toast.testId,\n style: {\n '--index': index,\n '--toasts-before': index,\n '--z-index': toasts.length - index,\n '--offset': `${removed ? offsetBeforeRemove : offset.current}px`,\n '--initial-height': expandByDefault ? 'auto' : `${initialHeight}px`,\n ...style,\n ...toast.style\n },\n onDragEnd: ()=>{\n setSwiping(false);\n setSwipeDirection(null);\n pointerStartRef.current = null;\n },\n onPointerDown: (event)=>{\n if (event.button === 2) return; // Return early on right click\n if (disabled || !dismissible) return;\n dragStartTime.current = new Date();\n setOffsetBeforeRemove(offset.current);\n // Ensure we maintain correct pointer capture even when going outside of the toast (e.g. when swiping)\n event.target.setPointerCapture(event.pointerId);\n if (event.target.tagName === 'BUTTON') return;\n setSwiping(true);\n pointerStartRef.current = {\n x: event.clientX,\n y: event.clientY\n };\n },\n onPointerUp: ()=>{\n var _toastRef_current, _toastRef_current1, _dragStartTime_current;\n if (swipeOut || !dismissible) return;\n pointerStartRef.current = null;\n const swipeAmountX = Number(((_toastRef_current = toastRef.current) == null ? void 0 : _toastRef_current.style.getPropertyValue('--swipe-amount-x').replace('px', '')) || 0);\n const swipeAmountY = Number(((_toastRef_current1 = toastRef.current) == null ? void 0 : _toastRef_current1.style.getPropertyValue('--swipe-amount-y').replace('px', '')) || 0);\n const timeTaken = new Date().getTime() - ((_dragStartTime_current = dragStartTime.current) == null ? void 0 : _dragStartTime_current.getTime());\n const swipeAmount = swipeDirection === 'x' ? swipeAmountX : swipeAmountY;\n const velocity = Math.abs(swipeAmount) / timeTaken;\n if (Math.abs(swipeAmount) >= SWIPE_THRESHOLD || velocity > 0.11) {\n setOffsetBeforeRemove(offset.current);\n toast.onDismiss == null ? void 0 : toast.onDismiss.call(toast, toast);\n if (swipeDirection === 'x') {\n setSwipeOutDirection(swipeAmountX > 0 ? 'right' : 'left');\n } else {\n setSwipeOutDirection(swipeAmountY > 0 ? 'down' : 'up');\n }\n deleteToast();\n setSwipeOut(true);\n return;\n } else {\n var _toastRef_current2, _toastRef_current3;\n (_toastRef_current2 = toastRef.current) == null ? void 0 : _toastRef_current2.style.setProperty('--swipe-amount-x', `0px`);\n (_toastRef_current3 = toastRef.current) == null ? void 0 : _toastRef_current3.style.setProperty('--swipe-amount-y', `0px`);\n }\n setIsSwiped(false);\n setSwiping(false);\n setSwipeDirection(null);\n },\n onPointerMove: (event)=>{\n var _window_getSelection, // Apply transform using both x and y values\n _toastRef_current, _toastRef_current1;\n if (!pointerStartRef.current || !dismissible) return;\n const isHighlighted = ((_window_getSelection = window.getSelection()) == null ? void 0 : _window_getSelection.toString().length) > 0;\n if (isHighlighted) return;\n const yDelta = event.clientY - pointerStartRef.current.y;\n const xDelta = event.clientX - pointerStartRef.current.x;\n var _props_swipeDirections;\n const swipeDirections = (_props_swipeDirections = props.swipeDirections) != null ? _props_swipeDirections : getDefaultSwipeDirections(position);\n // Determine swipe direction if not already locked\n if (!swipeDirection && (Math.abs(xDelta) > 1 || Math.abs(yDelta) > 1)) {\n setSwipeDirection(Math.abs(xDelta) > Math.abs(yDelta) ? 'x' : 'y');\n }\n let swipeAmount = {\n x: 0,\n y: 0\n };\n const getDampening = (delta)=>{\n const factor = Math.abs(delta) / 20;\n return 1 / (1.5 + factor);\n };\n // Only apply swipe in the locked direction\n if (swipeDirection === 'y') {\n // Handle vertical swipes\n if (swipeDirections.includes('top') || swipeDirections.includes('bottom')) {\n if (swipeDirections.includes('top') && yDelta < 0 || swipeDirections.includes('bottom') && yDelta > 0) {\n swipeAmount.y = yDelta;\n } else {\n // Smoothly transition to dampened movement\n const dampenedDelta = yDelta * getDampening(yDelta);\n // Ensure we don't jump when transitioning to dampened movement\n swipeAmount.y = Math.abs(dampenedDelta) < Math.abs(yDelta) ? dampenedDelta : yDelta;\n }\n }\n } else if (swipeDirection === 'x') {\n // Handle horizontal swipes\n if (swipeDirections.includes('left') || swipeDirections.includes('right')) {\n if (swipeDirections.includes('left') && xDelta < 0 || swipeDirections.includes('right') && xDelta > 0) {\n swipeAmount.x = xDelta;\n } else {\n // Smoothly transition to dampened movement\n const dampenedDelta = xDelta * getDampening(xDelta);\n // Ensure we don't jump when transitioning to dampened movement\n swipeAmount.x = Math.abs(dampenedDelta) < Math.abs(xDelta) ? dampenedDelta : xDelta;\n }\n }\n }\n if (Math.abs(swipeAmount.x) > 0 || Math.abs(swipeAmount.y) > 0) {\n setIsSwiped(true);\n }\n (_toastRef_current = toastRef.current) == null ? void 0 : _toastRef_current.style.setProperty('--swipe-amount-x', `${swipeAmount.x}px`);\n (_toastRef_current1 = toastRef.current) == null ? void 0 : _toastRef_current1.style.setProperty('--swipe-amount-y', `${swipeAmount.y}px`);\n }\n }, closeButton && !toast.jsx && toastType !== 'loading' ? /*#__PURE__*/ React.createElement(\"button\", {\n \"aria-label\": closeButtonAriaLabel,\n \"data-disabled\": disabled,\n \"data-close-button\": true,\n onClick: disabled || !dismissible ? ()=>{} : ()=>{\n deleteToast();\n toast.onDismiss == null ? void 0 : toast.onDismiss.call(toast, toast);\n },\n className: cn(classNames == null ? void 0 : classNames.closeButton, toast == null ? void 0 : (_toast_classNames2 = toast.classNames) == null ? void 0 : _toast_classNames2.closeButton)\n }, (_icons_close = icons == null ? void 0 : icons.close) != null ? _icons_close : CloseIcon) : null, (toastType || toast.icon || toast.promise) && toast.icon !== null && ((icons == null ? void 0 : icons[toastType]) !== null || toast.icon) ? /*#__PURE__*/ React.createElement(\"div\", {\n \"data-icon\": \"\",\n className: cn(classNames == null ? void 0 : classNames.icon, toast == null ? void 0 : (_toast_classNames3 = toast.classNames) == null ? void 0 : _toast_classNames3.icon)\n }, toast.promise || toast.type === 'loading' && !toast.icon ? toast.icon || getLoadingIcon() : null, toast.type !== 'loading' ? icon : null) : null, /*#__PURE__*/ React.createElement(\"div\", {\n \"data-content\": \"\",\n className: cn(classNames == null ? void 0 : classNames.content, toast == null ? void 0 : (_toast_classNames4 = toast.classNames) == null ? void 0 : _toast_classNames4.content)\n }, /*#__PURE__*/ React.createElement(\"div\", {\n \"data-title\": \"\",\n className: cn(classNames == null ? void 0 : classNames.title, toast == null ? void 0 : (_toast_classNames5 = toast.classNames) == null ? void 0 : _toast_classNames5.title)\n }, toast.jsx ? toast.jsx : typeof toast.title === 'function' ? toast.title() : toast.title), toast.description ? /*#__PURE__*/ React.createElement(\"div\", {\n \"data-description\": \"\",\n className: cn(descriptionClassName, toastDescriptionClassname, classNames == null ? void 0 : classNames.description, toast == null ? void 0 : (_toast_classNames6 = toast.classNames) == null ? void 0 : _toast_classNames6.description)\n }, typeof toast.description === 'function' ? toast.description() : toast.description) : null), /*#__PURE__*/ React.isValidElement(toast.cancel) ? toast.cancel : toast.cancel && isAction(toast.cancel) ? /*#__PURE__*/ React.createElement(\"button\", {\n \"data-button\": true,\n \"data-cancel\": true,\n style: toast.cancelButtonStyle || cancelButtonStyle,\n onClick: (event)=>{\n // We need to check twice because typescript\n if (!isAction(toast.cancel)) return;\n if (!dismissible) return;\n toast.cancel.onClick == null ? void 0 : toast.cancel.onClick.call(toast.cancel, event);\n deleteToast();\n },\n className: cn(classNames == null ? void 0 : classNames.cancelButton, toast == null ? void 0 : (_toast_classNames7 = toast.classNames) == null ? void 0 : _toast_classNames7.cancelButton)\n }, toast.cancel.label) : null, /*#__PURE__*/ React.isValidElement(toast.action) ? toast.action : toast.action && isAction(toast.action) ? /*#__PURE__*/ React.createElement(\"button\", {\n \"data-button\": true,\n \"data-action\": true,\n style: toast.actionButtonStyle || actionButtonStyle,\n onClick: (event)=>{\n // We need to check twice because typescript\n if (!isAction(toast.action)) return;\n toast.action.onClick == null ? void 0 : toast.action.onClick.call(toast.action, event);\n if (event.defaultPrevented) return;\n deleteToast();\n },\n className: cn(classNames == null ? void 0 : classNames.actionButton, toast == null ? void 0 : (_toast_classNames8 = toast.classNames) == null ? void 0 : _toast_classNames8.actionButton)\n }, toast.action.label) : null);\n};\nfunction getDocumentDirection() {\n if (typeof window === 'undefined') return 'ltr';\n if (typeof document === 'undefined') return 'ltr'; // For Fresh purpose\n const dirAttribute = document.documentElement.getAttribute('dir');\n if (dirAttribute === 'auto' || !dirAttribute) {\n return window.getComputedStyle(document.documentElement).direction;\n }\n return dirAttribute;\n}\nfunction assignOffset(defaultOffset, mobileOffset) {\n const styles = {};\n [\n defaultOffset,\n mobileOffset\n ].forEach((offset, index)=>{\n const isMobile = index === 1;\n const prefix = isMobile ? '--mobile-offset' : '--offset';\n const defaultValue = isMobile ? MOBILE_VIEWPORT_OFFSET : VIEWPORT_OFFSET;\n function assignAll(offset) {\n [\n 'top',\n 'right',\n 'bottom',\n 'left'\n ].forEach((key)=>{\n styles[`${prefix}-${key}`] = typeof offset === 'number' ? `${offset}px` : offset;\n });\n }\n if (typeof offset === 'number' || typeof offset === 'string') {\n assignAll(offset);\n } else if (typeof offset === 'object') {\n [\n 'top',\n 'right',\n 'bottom',\n 'left'\n ].forEach((key)=>{\n if (offset[key] === undefined) {\n styles[`${prefix}-${key}`] = defaultValue;\n } else {\n styles[`${prefix}-${key}`] = typeof offset[key] === 'number' ? `${offset[key]}px` : offset[key];\n }\n });\n } else {\n assignAll(defaultValue);\n }\n });\n return styles;\n}\nfunction useSonner() {\n const [activeToasts, setActiveToasts] = React.useState([]);\n React.useEffect(()=>{\n return ToastState.subscribe((toast)=>{\n if (toast.dismiss) {\n setTimeout(()=>{\n ReactDOM.flushSync(()=>{\n setActiveToasts((toasts)=>toasts.filter((t)=>t.id !== toast.id));\n });\n });\n return;\n }\n // Prevent batching, temp solution.\n setTimeout(()=>{\n ReactDOM.flushSync(()=>{\n setActiveToasts((toasts)=>{\n const indexOfExistingToast = toasts.findIndex((t)=>t.id === toast.id);\n // Update the toast if it already exists\n if (indexOfExistingToast !== -1) {\n return [\n ...toasts.slice(0, indexOfExistingToast),\n {\n ...toasts[indexOfExistingToast],\n ...toast\n },\n ...toasts.slice(indexOfExistingToast + 1)\n ];\n }\n return [\n toast,\n ...toasts\n ];\n });\n });\n });\n });\n }, []);\n return {\n toasts: activeToasts\n };\n}\nconst Toaster = /*#__PURE__*/ React.forwardRef(function Toaster(props, ref) {\n const { id, invert, position = 'bottom-right', hotkey = [\n 'altKey',\n 'KeyT'\n ], expand, closeButton, className, offset, mobileOffset, theme = 'light', richColors, duration, style, visibleToasts = VISIBLE_TOASTS_AMOUNT, toastOptions, dir = getDocumentDirection(), gap = GAP, icons, containerAriaLabel = 'Notifications' } = props;\n const [toasts, setToasts] = React.useState([]);\n const filteredToasts = React.useMemo(()=>{\n if (id) {\n return toasts.filter((toast)=>toast.toasterId === id);\n }\n return toasts.filter((toast)=>!toast.toasterId);\n }, [\n toasts,\n id\n ]);\n const possiblePositions = React.useMemo(()=>{\n return Array.from(new Set([\n position\n ].concat(filteredToasts.filter((toast)=>toast.position).map((toast)=>toast.position))));\n }, [\n filteredToasts,\n position\n ]);\n const [heights, setHeights] = React.useState([]);\n const [expanded, setExpanded] = React.useState(false);\n const [interacting, setInteracting] = React.useState(false);\n const [actualTheme, setActualTheme] = React.useState(theme !== 'system' ? theme : typeof window !== 'undefined' ? window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light' : 'light');\n const listRef = React.useRef(null);\n const hotkeyLabel = hotkey.join('+').replace(/Key/g, '').replace(/Digit/g, '');\n const lastFocusedElementRef = React.useRef(null);\n const isFocusWithinRef = React.useRef(false);\n const removeToast = React.useCallback((toastToRemove)=>{\n setToasts((toasts)=>{\n var _toasts_find;\n if (!((_toasts_find = toasts.find((toast)=>toast.id === toastToRemove.id)) == null ? void 0 : _toasts_find.delete)) {\n ToastState.dismiss(toastToRemove.id);\n }\n return toasts.filter(({ id })=>id !== toastToRemove.id);\n });\n }, []);\n React.useEffect(()=>{\n return ToastState.subscribe((toast)=>{\n if (toast.dismiss) {\n // Prevent batching of other state updates\n requestAnimationFrame(()=>{\n setToasts((toasts)=>toasts.map((t)=>t.id === toast.id ? {\n ...t,\n delete: true\n } : t));\n });\n return;\n }\n // Prevent batching, temp solution.\n setTimeout(()=>{\n ReactDOM.flushSync(()=>{\n setToasts((toasts)=>{\n const indexOfExistingToast = toasts.findIndex((t)=>t.id === toast.id);\n // Update the toast if it already exists\n if (indexOfExistingToast !== -1) {\n return [\n ...toasts.slice(0, indexOfExistingToast),\n {\n ...toasts[indexOfExistingToast],\n ...toast\n },\n ...toasts.slice(indexOfExistingToast + 1)\n ];\n }\n return [\n toast,\n ...toasts\n ];\n });\n });\n });\n });\n }, [\n toasts\n ]);\n React.useEffect(()=>{\n if (theme !== 'system') {\n setActualTheme(theme);\n return;\n }\n if (theme === 'system') {\n // check if current preference is dark\n if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {\n // it's currently dark\n setActualTheme('dark');\n } else {\n // it's not dark\n setActualTheme('light');\n }\n }\n if (typeof window === 'undefined') return;\n const darkMediaQuery = window.matchMedia('(prefers-color-scheme: dark)');\n try {\n // Chrome & Firefox\n darkMediaQuery.addEventListener('change', ({ matches })=>{\n if (matches) {\n setActualTheme('dark');\n } else {\n setActualTheme('light');\n }\n });\n } catch (error) {\n // Safari < 14\n darkMediaQuery.addListener(({ matches })=>{\n try {\n if (matches) {\n setActualTheme('dark');\n } else {\n setActualTheme('light');\n }\n } catch (e) {\n console.error(e);\n }\n });\n }\n }, [\n theme\n ]);\n React.useEffect(()=>{\n // Ensure expanded is always false when no toasts are present / only one left\n if (toasts.length <= 1) {\n setExpanded(false);\n }\n }, [\n toasts\n ]);\n React.useEffect(()=>{\n const handleKeyDown = (event)=>{\n var _listRef_current;\n const isHotkeyPressed = hotkey.every((key)=>event[key] || event.code === key);\n if (isHotkeyPressed) {\n var _listRef_current1;\n setExpanded(true);\n (_listRef_current1 = listRef.current) == null ? void 0 : _listRef_current1.focus();\n }\n if (event.code === 'Escape' && (document.activeElement === listRef.current || ((_listRef_current = listRef.current) == null ? void 0 : _listRef_current.contains(document.activeElement)))) {\n setExpanded(false);\n }\n };\n document.addEventListener('keydown', handleKeyDown);\n return ()=>document.removeEventListener('keydown', handleKeyDown);\n }, [\n hotkey\n ]);\n React.useEffect(()=>{\n if (listRef.current) {\n return ()=>{\n if (lastFocusedElementRef.current) {\n lastFocusedElementRef.current.focus({\n preventScroll: true\n });\n lastFocusedElementRef.current = null;\n isFocusWithinRef.current = false;\n }\n };\n }\n }, [\n listRef.current\n ]);\n return(// Remove item from normal navigation flow, only available via hotkey\n /*#__PURE__*/ React.createElement(\"section\", {\n ref: ref,\n \"aria-label\": `${containerAriaLabel} ${hotkeyLabel}`,\n tabIndex: -1,\n \"aria-live\": \"polite\",\n \"aria-relevant\": \"additions text\",\n \"aria-atomic\": \"false\",\n suppressHydrationWarning: true\n }, possiblePositions.map((position, index)=>{\n var _heights_;\n const [y, x] = position.split('-');\n if (!filteredToasts.length) return null;\n return /*#__PURE__*/ React.createElement(\"ol\", {\n key: position,\n dir: dir === 'auto' ? getDocumentDirection() : dir,\n tabIndex: -1,\n ref: listRef,\n className: className,\n \"data-sonner-toaster\": true,\n \"data-sonner-theme\": actualTheme,\n \"data-y-position\": y,\n \"data-x-position\": x,\n style: {\n '--front-toast-height': `${((_heights_ = heights[0]) == null ? void 0 : _heights_.height) || 0}px`,\n '--width': `${TOAST_WIDTH}px`,\n '--gap': `${gap}px`,\n ...style,\n ...assignOffset(offset, mobileOffset)\n },\n onBlur: (event)=>{\n if (isFocusWithinRef.current && !event.currentTarget.contains(event.relatedTarget)) {\n isFocusWithinRef.current = false;\n if (lastFocusedElementRef.current) {\n lastFocusedElementRef.current.focus({\n preventScroll: true\n });\n lastFocusedElementRef.current = null;\n }\n }\n },\n onFocus: (event)=>{\n const isNotDismissible = event.target instanceof HTMLElement && event.target.dataset.dismissible === 'false';\n if (isNotDismissible) return;\n if (!isFocusWithinRef.current) {\n isFocusWithinRef.current = true;\n lastFocusedElementRef.current = event.relatedTarget;\n }\n },\n onMouseEnter: ()=>setExpanded(true),\n onMouseMove: ()=>setExpanded(true),\n onMouseLeave: ()=>{\n // Avoid setting expanded to false when interacting with a toast, e.g. swiping\n if (!interacting) {\n setExpanded(false);\n }\n },\n onDragEnd: ()=>setExpanded(false),\n onPointerDown: (event)=>{\n const isNotDismissible = event.target instanceof HTMLElement && event.target.dataset.dismissible === 'false';\n if (isNotDismissible) return;\n setInteracting(true);\n },\n onPointerUp: ()=>setInteracting(false)\n }, filteredToasts.filter((toast)=>!toast.position && index === 0 || toast.position === position).map((toast, index)=>{\n var _toastOptions_duration, _toastOptions_closeButton;\n return /*#__PURE__*/ React.createElement(Toast, {\n key: toast.id,\n icons: icons,\n index: index,\n toast: toast,\n defaultRichColors: richColors,\n duration: (_toastOptions_duration = toastOptions == null ? void 0 : toastOptions.duration) != null ? _toastOptions_duration : duration,\n className: toastOptions == null ? void 0 : toastOptions.className,\n descriptionClassName: toastOptions == null ? void 0 : toastOptions.descriptionClassName,\n invert: invert,\n visibleToasts: visibleToasts,\n closeButton: (_toastOptions_closeButton = toastOptions == null ? void 0 : toastOptions.closeButton) != null ? _toastOptions_closeButton : closeButton,\n interacting: interacting,\n position: position,\n style: toastOptions == null ? void 0 : toastOptions.style,\n unstyled: toastOptions == null ? void 0 : toastOptions.unstyled,\n classNames: toastOptions == null ? void 0 : toastOptions.classNames,\n cancelButtonStyle: toastOptions == null ? void 0 : toastOptions.cancelButtonStyle,\n actionButtonStyle: toastOptions == null ? void 0 : toastOptions.actionButtonStyle,\n closeButtonAriaLabel: toastOptions == null ? void 0 : toastOptions.closeButtonAriaLabel,\n removeToast: removeToast,\n toasts: filteredToasts.filter((t)=>t.position == toast.position),\n heights: heights.filter((h)=>h.position == toast.position),\n setHeights: setHeights,\n expandByDefault: expand,\n gap: gap,\n expanded: expanded,\n swipeDirections: props.swipeDirections\n });\n }));\n })));\n});\n\nexport { Toaster, toast, useSonner };\n","import { Toaster as Sonner } from \"sonner\";\nimport { type ComponentProps } from \"react\";\n\ntype ToasterProps = ComponentProps<typeof Sonner>;\n\nconst Toaster = ({ position = \"bottom-center\", ...props }: ToasterProps) => {\n return (\n <Sonner\n position={position}\n className=\"toaster group\"\n toastOptions={{\n classNames: {\n toast:\n \"group toast w-full flex items-center gap-3 p-4 rounded-cms-lg shadow-lg bg-cms-white text-cms-gray-900 !border !border-cms-blue-600 [&_[data-content]]:!flex-row [&_[data-content]]:!items-baseline\",\n title:\n \"group-[.toast]:text-cms-gray-900 group-[.toast]:font-bold group-[.toast]:text-sm group-[.toast]:mr-2 group-[.toast]:!font-bold\",\n description:\n \"group-[.toast]:text-cms-gray-500 group-[.toast]:text-xs group-[.toast]:font-medium\",\n actionButton:\n \"group-[.toast]:bg-cms-gray-900 group-[.toast]:text-cms-white\",\n cancelButton:\n \"group-[.toast]:bg-cms-gray-100 group-[.toast]:text-cms-gray-500\",\n },\n }}\n {...props}\n />\n );\n};\n\nexport { Toaster };\n"],"names":["r","f","n","clsx","CLASS_PART_SEPARATOR","createClassGroupUtils","config","classMap","createClassMap","conflictingClassGroups","conflictingClassGroupModifiers","className","classParts","getGroupRecursive","getGroupIdForArbitraryProperty","classGroupId","hasPostfixModifier","conflicts","classPartObject","currentClassPart","nextClassPartObject","classGroupFromNextClassPart","classRest","_a","validator","arbitraryPropertyRegex","arbitraryPropertyClassName","property","theme","prefix","getPrefixedClassGroupEntries","classGroup","processClassesRecursively","classDefinition","classPartObjectToEdit","getPart","isThemeGetter","key","path","currentClassPartObject","pathPart","func","classGroupEntries","prefixedClassGroup","value","createLruCache","maxCacheSize","cacheSize","cache","previousCache","update","IMPORTANT_MODIFIER","createParseClassName","separator","experimentalParseClassName","isSeparatorSingleCharacter","firstSeparatorCharacter","separatorLength","parseClassName","modifiers","bracketDepth","modifierStart","postfixModifierPosition","index","currentCharacter","baseClassNameWithImportantModifier","hasImportantModifier","baseClassName","maybePostfixModifierPosition","sortModifiers","sortedModifiers","unsortedModifiers","modifier","createConfigUtils","SPLIT_CLASSES_REGEX","mergeClassList","classList","configUtils","getClassGroupId","getConflictingClassGroupIds","classGroupsInConflict","classNames","result","originalClassName","variantModifier","modifierId","classId","conflictGroups","i","group","twJoin","argument","resolvedValue","string","toValue","mix","k","createTailwindMerge","createConfigFirst","createConfigRest","cacheGet","cacheSet","functionToCall","initTailwindMerge","previousConfig","createConfigCurrent","tailwindMerge","cachedResult","fromTheme","themeGetter","arbitraryValueRegex","fractionRegex","stringLengths","tshirtUnitRegex","lengthUnitRegex","colorFunctionRegex","shadowRegex","imageRegex","isLength","isNumber","isArbitraryLength","getIsArbitraryValue","isLengthOnly","isArbitraryNumber","isInteger","isPercent","isArbitraryValue","isTshirtSize","sizeLabels","isArbitrarySize","isNever","isArbitraryPosition","imageLabels","isArbitraryImage","isImage","isArbitraryShadow","isShadow","isAny","label","testValue","twMerge","colors","spacing","blur","brightness","borderColor","borderRadius","borderSpacing","borderWidth","contrast","grayscale","hueRotate","invert","gap","gradientColorStops","gradientColorStopPositions","inset","margin","opacity","padding","saturate","scale","sepia","skew","space","translate","getOverscroll","getOverflow","getSpacingWithAutoAndArbitrary","getSpacingWithArbitrary","getLengthWithEmptyAndArbitrary","getNumberWithAutoAndArbitrary","getPositions","getLineStyles","getBlendModes","getAlign","getZeroAndEmpty","getBreaks","getNumberAndArbitrary","cn","inputs","falsyToString","cx","cva","base","props","_config_compoundVariants","variants","defaultVariants","getVariantClassNames","variant","variantProp","defaultVariantProp","variantKey","propsWithoutUndefined","acc","param","getCompoundVariantClassNames","cvClass","cvClassName","compoundVariantOptions","buttonVariants","Button","forwardRef","size","ref","jsx","sizeClasses","LoadingCircle","dropdownTriggerVariants","ChevronDownIcon","isOpen","ClearIcon","Dropdown","options","placeholder","onValueChange","disabled","dropdownClassName","searchable","clearable","multiple","maxHeight","setIsOpen","useState","searchTerm","setSearchTerm","selectedValues","setSelectedValues","dropdownRef","useRef","searchInputRef","selectedOption","option","selectedLabel","filteredOptions","handleToggle","handleOptionClick","newSelectedValues","v","handleClear","e","handleKeyDown","useEffect","handleClickOutside","event","jsxs","isSelected","Select","helperText","error","required","Combobox","loading","createable","onCreateOption","hasExactMatch","optionsWithCreate","createValue","ChevronRightIcon","composeEventHandlers","originalEventHandler","ourEventHandler","checkForDefaultPrevented","setRef","composeRefs","refs","node","hasCleanup","cleanups","cleanup","useComposedRefs","React","createContext2","rootComponentName","defaultContext","Context","Provider","children","context","useContext2","consumerName","createContextScope","scopeName","createContextScopeDeps","defaultContexts","createContext3","BaseContext","scope","createScope","scopeContexts","contexts","composeContextScopes","scopes","baseScope","scopeHooks","createScope2","overrideScopes","nextScopes","nextScopes2","useScope","currentScope","createSlot","ownerName","SlotClone","createSlotClone","Slot2","forwardedRef","slotProps","childrenArray","slottable","isSlottable","newElement","newChildren","child","childrenRef","getElementRef","props2","mergeProps","SLOTTABLE_IDENTIFIER","childProps","overrideProps","propName","slotPropValue","childPropValue","args","element","getter","mayWarn","_b","NODES","Primitive","primitive","Slot","Node","asChild","primitiveProps","Comp","dispatchDiscreteCustomEvent","target","ReactDOM","useCallbackRef","callback","callbackRef","useEscapeKeydown","onEscapeKeyDownProp","ownerDocument","onEscapeKeyDown","DISMISSABLE_LAYER_NAME","CONTEXT_UPDATE","POINTER_DOWN_OUTSIDE","FOCUS_OUTSIDE","originalBodyPointerEvents","DismissableLayerContext","DismissableLayer","disableOutsidePointerEvents","onPointerDownOutside","onFocusOutside","onInteractOutside","onDismiss","layerProps","setNode","force","composedRefs","node2","layers","highestLayerWithOutsidePointerEventsDisabled","highestLayerWithOutsidePointerEventsDisabledIndex","isBodyPointerEventsDisabled","isPointerEventsEnabled","pointerDownOutside","usePointerDownOutside","isPointerDownOnBranch","branch","focusOutside","useFocusOutside","dispatchUpdate","handleUpdate","BRANCH_NAME","DismissableLayerBranch","handlePointerDownOutside","isPointerInsideReactTreeRef","handleClickRef","handlePointerDown","handleAndDispatchPointerDownOutsideEvent2","handleAndDispatchCustomEvent","eventDetail","timerId","handleFocusOutside","isFocusInsideReactTreeRef","handleFocus","name","handler","detail","discrete","count","useFocusGuards","edgeGuards","createFocusGuard","AUTOFOCUS_ON_MOUNT","AUTOFOCUS_ON_UNMOUNT","EVENT_OPTIONS","FOCUS_SCOPE_NAME","FocusScope","loop","trapped","onMountAutoFocusProp","onUnmountAutoFocusProp","scopeProps","container","setContainer","onMountAutoFocus","onUnmountAutoFocus","lastFocusedElementRef","focusScope","handleFocusIn2","focus","handleFocusOut2","relatedTarget","handleMutations2","mutations","mutation","mutationObserver","focusScopesStack","previouslyFocusedElement","mountEvent","focusFirst","removeLinks","getTabbableCandidates","unmountEvent","isTabKey","focusedElement","container2","first","last","getTabbableEdges","candidates","select","candidate","findVisible","nodes","walker","isHiddenInput","elements","isHidden","upTo","isSelectableInput","createFocusScopesStack","stack","activeFocusScope","arrayRemove","array","item","updatedArray","items","useLayoutEffect2","useReactId","useId","deterministicId","id","setId","useLayoutEffect","reactId","sides","min","max","round","floor","createCoords","oppositeSideMap","oppositeAlignmentMap","clamp","start","end","evaluate","getSide","placement","getAlignment","getOppositeAxis","axis","getAxisLength","yAxisSides","getSideAxis","getAlignmentAxis","getAlignmentSides","rects","rtl","alignment","alignmentAxis","length","mainAlignmentSide","getOppositePlacement","getExpandedPlacements","oppositePlacement","getOppositeAlignmentPlacement","lrPlacement","rlPlacement","tbPlacement","btPlacement","getSideList","side","isStart","getOppositeAxisPlacements","flipAlignment","direction","list","expandPaddingObject","getPaddingObject","rectToClientRect","rect","x","y","width","height","computeCoordsFromPlacement","_ref","reference","floating","sideAxis","alignLength","isVertical","commonX","commonY","commonAlign","coords","computePosition","strategy","middleware","platform","validMiddleware","statefulPlacement","middlewareData","resetCount","fn","nextX","nextY","data","reset","detectOverflow","state","_await$platform$isEle","boundary","rootBoundary","elementContext","altBoundary","paddingObject","clippingClientRect","offsetParent","offsetScale","elementClientRect","arrow","arrowDimensions","isYAxis","minProp","maxProp","clientProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","largestPossiblePadding","minPadding","maxPadding","min$1","center","offset","shouldAddOffset","alignmentOffset","flip","_middlewareData$arrow","_middlewareData$flip","initialPlacement","checkMainAxis","checkCrossAxis","specifiedFallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","detectOverflowOptions","initialSideAxis","isBasePlacement","fallbackPlacements","hasFallbackAxisSideDirection","placements","overflow","overflows","overflowsData","_middlewareData$flip2","_overflowsData$filter","nextIndex","nextPlacement","d","resetPlacement","a","b","_overflowsData$filter2","currentSideAxis","getSideOffsets","isAnySideFullyClipped","hide","offsets","originSides","convertValueToCoords","mainAxisMulti","crossAxisMulti","rawValue","mainAxis","crossAxis","_middlewareData$offse","diffCoords","shift","limiter","mainAxisCoord","crossAxisCoord","minSide","maxSide","limitedCoords","limitShift","rawOffset","computedOffset","len","limitMin","limitMax","_middlewareData$offse2","isOriginSide","_state$middlewareData","_state$middlewareData2","apply","heightSide","widthSide","maximumClippingHeight","maximumClippingWidth","overflowAvailableHeight","overflowAvailableWidth","noShift","availableHeight","availableWidth","xMin","xMax","yMin","yMax","nextDimensions","hasWindow","getNodeName","isNode","getWindow","_node$ownerDocument","getDocumentElement","isElement","isHTMLElement","isShadowRoot","invalidOverflowDisplayValues","isOverflowElement","overflowX","overflowY","display","getComputedStyle","tableElements","isTableElement","topLayerSelectors","isTopLayer","selector","transformProperties","willChangeValues","containValues","isContainingBlock","elementOrCss","webkit","isWebKit","css","getContainingBlock","currentNode","getParentNode","isLastTraversableNode","lastTraversableNodeNames","getNodeScroll","getNearestOverflowAncestor","parentNode","getOverflowAncestors","traverseIframes","_node$ownerDocument2","scrollableAncestor","isBody","win","frameElement","getFrameElement","getCssDimensions","getComputedStyle$1","hasOffset","offsetWidth","offsetHeight","shouldFallback","unwrapElement","getScale","domElement","$","noOffsets","getVisualOffsets","shouldAddVisualOffsets","isFixed","floatingOffsetParent","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","visualOffsets","offsetWin","currentWin","currentIFrame","iframeScale","iframeRect","left","top","getWindowScrollBarX","leftScroll","getHTMLOffset","documentElement","scroll","htmlRect","convertOffsetParentRelativeRectToViewportRelativeRect","topLayer","isOffsetParentAnElement","offsetRect","htmlOffset","getClientRects","getDocumentRect","html","body","SCROLLBAR_MAX","getViewportRect","visualViewport","visualViewportBased","windowScrollbarX","doc","bodyStyles","bodyMarginInline","clippingStableScrollbarWidth","absoluteOrFixed","getInnerBoundingClientRect","getClientRectFromClippingAncestor","clippingAncestor","hasFixedPositionAncestor","stopNode","getClippingElementAncestors","el","currentContainingBlockComputedStyle","elementIsFixed","computedStyle","currentNodeIsContaining","ancestor","getClippingRect","clippingAncestors","firstClippingAncestor","clippingRect","accRect","getDimensions","getRectRelativeToOffsetParent","setLeftRTLScrollbarOffset","isStaticPositioned","getTrueOffsetParent","polyfill","rawOffsetParent","getOffsetParent","svgOffsetParent","getElementRects","getOffsetParentFn","getDimensionsFn","floatingDimensions","isRTL","rectsAreEqual","observeMove","onMove","io","timeoutId","root","_io","refresh","skip","threshold","elementRectForRootMargin","insetTop","insetRight","insetBottom","insetLeft","isFirstUpdate","handleObserve","entries","ratio","autoUpdate","ancestorScroll","ancestorResize","elementResize","layoutShift","animationFrame","referenceEl","ancestors","cleanupIo","reobserveFrame","resizeObserver","firstEntry","_resizeObserver","frameId","prevRefRect","frameLoop","nextRefRect","_resizeObserver2","offset$1","shift$1","flip$1","size$1","hide$1","arrow$1","limitShift$1","mergedOptions","platformWithCache","computePosition$1","isClient","noop","deepEqual","keys","getDPR","roundByDPR","dpr","useLatestRef","useFloating","externalReference","externalFloating","transform","whileElementsMounted","open","setData","latestMiddleware","setLatestMiddleware","_reference","_setReference","_floating","_setFloating","setReference","referenceRef","setFloating","floatingRef","floatingEl","dataRef","hasWhileElementsMounted","whileElementsMountedRef","platformRef","openRef","fullData","isMountedRef","floatingStyles","initialStyles","isRef","arrow$2","deps","NAME","Arrow","arrowProps","Root","useSize","setSize","entry","borderSizeEntry","borderSize","POPPER_NAME","createPopperContext","createPopperScope","PopperProvider","usePopperContext","Popper","__scopePopper","anchor","setAnchor","ANCHOR_NAME","PopperAnchor","virtualRef","anchorProps","anchorRef","previousAnchor","CONTENT_NAME","PopperContentProvider","useContentContext","PopperContent","sideOffset","align","alignOffset","arrowPadding","avoidCollisions","collisionBoundary","collisionPaddingProp","sticky","hideWhenDetached","updatePositionStrategy","onPlaced","contentProps","content","setContent","setArrow","arrowSize","arrowWidth","arrowHeight","desiredPlacement","collisionPadding","hasExplicitBoundaries","isNotNull","isPositioned","anchorWidth","anchorHeight","contentStyle","floatingUIarrow","transformOrigin","placedSide","placedAlign","getSideAndAlignFromPlacement","handlePlaced","arrowX","arrowY","cannotCenterArrow","_c","contentZIndex","setContentZIndex","_d","_e","_f","ARROW_NAME","OPPOSITE_SIDE","PopperArrow","contentContext","baseSide","ArrowPrimitive.Root","isArrowHidden","noArrowAlign","arrowXCenter","arrowYCenter","Root2","Anchor","Content","PORTAL_NAME","Portal","containerProp","portalProps","mounted","setMounted","useStateMachine","initialState","machine","Presence","present","presence","usePresence","React2","stylesRef","prevPresentRef","prevAnimationNameRef","send","currentAnimationName","getAnimationName","styles","wasPresent","prevAnimationName","ownerWindow","handleAnimationEnd","isCurrentAnimation","currentFillMode","handleAnimationStart","useInsertionEffect","useControllableState","prop","defaultProp","onChange","caller","uncontrolledProp","setUncontrolledProp","onChangeRef","useUncontrolledState","isControlled","isControlledRef","wasControlled","setValue","nextValue","value2","isFunction","prevValueRef","getDefaultParent","originalTarget","sampleTarget","counterMap","uncontrolledNodes","markerMap","lockCount","unwrapHost","correctTargets","parent","targets","correctedTarget","applyAttributeToOthers","markerName","controlAttribute","markerCounter","hiddenNodes","elementsToKeep","elementsToStop","keep","deep","attr","alreadyHidden","counterValue","markerValue","hideOthers","activeParentNode","__assign","s","p","__rest","t","__spreadArray","to","from","pack","l","ar","zeroRightClassName","fullWidthClassName","noScrollbarsClassName","removedBarSizeVariable","assignRef","initialValue","useIsomorphicLayoutEffect","currentValues","useMergeRefs","defaultValue","newValue","oldValue","prevRefs_1","nextRefs_1","current_1","ItoI","innerCreateMedium","defaults","buffer","assigned","medium","cb","cbs","pendingQueue","executeQueue","cycle","filter","createSidecarMedium","SideCar","sideCar","rest","Target","exportSidecar","exported","effectCar","nothing","RemoveScroll","parentRef","callbacks","setCallbacks","forwardProps","removeScrollBar","enabled","shards","noRelative","noIsolation","inert","allowPinchZoom","Container","gapMode","containerRef","containerProps","getNonce","makeStyleTag","tag","nonce","injectStyles","insertStyleTag","head","stylesheetSingleton","counter","stylesheet","style","styleHookSingleton","sheet","isDynamic","styleSingleton","useStyle","Sheet","dynamic","zeroGap","parse","getOffset","cs","right","getGapWidth","documentWidth","windowWidth","Style","lockAttribute","getStyles","allowRelative","important","getCurrentUseCounter","useLockAttribute","newCounter","RemoveScrollBar","noImportant","passiveSupported","nonPassive","alwaysContainsScroll","elementCanBeScrolled","elementCouldBeVScrolled","elementCouldBeHScrolled","locationCouldBeScrolled","current","isScrollable","elementCouldBeScrolled","getScrollVariables","scrollHeight","clientHeight","getVScrollVariables","scrollTop","getHScrollVariables","scrollLeft","scrollWidth","clientWidth","getDirectionFactor","handleScroll","endTarget","sourceDelta","noOverscroll","directionFactor","delta","targetInLock","shouldCancelScroll","isDeltaPositive","availableScroll","availableScrollTop","position","scroll_1","capacity","elementScroll","parent_1","getTouchXY","getDeltaXY","extractRef","deltaCompare","generateStyle","idCounter","lockStack","RemoveScrollSideCar","shouldPreventQueue","touchStartRef","activeAxis","lastProps","allow_1","shouldCancelEvent","touch","touchStart","deltaX","deltaY","currentAxis","moveDirection","canBeScrolledInMainDirection","cancelingAxis","shouldPrevent","_event","sourceEvent","shardNodes","shouldStop","shouldCancel","should","getOutermostShadowParent","scrollTouchStart","scrollWheel","scrollTouchMove","inst","shadowParent","ReactRemoveScroll","POPOVER_NAME","createPopoverContext","usePopperScope","PopoverProvider","usePopoverContext","Popover","__scopePopover","openProp","defaultOpen","onOpenChange","modal","popperScope","triggerRef","hasCustomAnchor","setHasCustomAnchor","setOpen","PopperPrimitive.Root","prevOpen","PopoverAnchor","onCustomAnchorAdd","onCustomAnchorRemove","PopperPrimitive.Anchor","TRIGGER_NAME","PopoverTrigger","triggerProps","composedTriggerRef","trigger","getState","PortalProvider","usePortalContext","PopoverPortal","forceMount","PortalPrimitive","PopoverContent","portalContext","PopoverContentModal","PopoverContentNonModal","contentRef","isRightClickOutsideRef","PopoverContentImpl","originalEvent","ctrlLeftClick","isRightClick","hasInteractedOutsideRef","hasPointerDownOutsideRef","trapFocus","onOpenAutoFocus","onCloseAutoFocus","PopperPrimitive.Content","CLOSE_NAME","PopoverClose","closeProps","PopoverArrow","PopperPrimitive.Arrow","Trigger","Content2","PopoverPrimitive.Root","PopoverPrimitive.Trigger","PopoverPrimitive.Portal","PopoverPrimitive.Content","popoverMenuItemVariants","PopoverMenuItem","icon","textVariants","Text","decoration","Component","textInputVariants","labelVariants","errorMessageVariants","helperTextVariants","TextInput","fullWidth","errorMessage","showCharCount","maxLength","internalValue","setInternalValue","inputId","finalVariant","currentValue","charCount","handleChange","hasHeader","tzName","timeZone","date","format","offsetFormatCache","offsetCache","tzOffset","offsetStr","calcOffset","captures","offsetRe","cacheStr","values","hours","minutes","seconds","TZDateMini","adjustToSystemTZ","syncToInternal","tz","time","re","method","utcMethod","syncFromInternal","baseOffset","prevHour","systemOffset","prevHourSystemOffset","systemDSTChange","dstShift","offsetDiff","systemDate","systemSecondsOffset","secondsOffset","postBaseOffset","postOffset","postOffsetDiff","offsetChanged","postDiff","newBaseOffset","newOffset","offsetChange","TZDate","sign","day","month","year","locales","millisecondsInWeek","millisecondsInDay","constructFromSymbol","constructFrom","toDate","addDays","amount","_date","addMonths","dayOfMonth","endOfDesiredMonth","daysInMonth","defaultOptions","getDefaultOptions","startOfWeek","weekStartsOn","diff","startOfISOWeek","getISOWeekYear","fourthOfJanuaryOfNextYear","startOfNextYear","fourthOfJanuaryOfThisYear","startOfThisYear","getTimezoneOffsetInMilliseconds","utcDate","normalizeDates","dates","normalize","startOfDay","differenceInCalendarDays","laterDate","earlierDate","laterDate_","earlierDate_","laterStartOfDay","earlierStartOfDay","laterTimestamp","earlierTimestamp","startOfISOWeekYear","fourthOfJanuary","addWeeks","addYears","date_","isSameDay","dateLeft_","dateRight_","isDate","isValid","differenceInCalendarMonths","yearsDiff","monthsDiff","endOfMonth","normalizeInterval","interval","eachMonthOfInterval","reversed","endTime","step","startOfMonth","endOfYear","startOfYear","eachYearOfInterval","endOfWeek","endOfISOWeek","formatDistanceLocale","formatDistance","token","tokenValue","buildFormatLongFn","dateFormats","timeFormats","dateTimeFormats","formatLong","formatRelativeLocale","formatRelative","_baseDate","_options","buildLocalizeFn","valuesArray","defaultWidth","eraValues","quarterValues","monthValues","dayValues","dayPeriodValues","formattingDayPeriodValues","localize","dirtyNumber","number","rem100","quarter","buildMatchFn","matchPattern","matchResult","matchedString","parsePatterns","findIndex","pattern","findKey","object","predicate","buildMatchPatternFn","parseResult","matchOrdinalNumberPattern","parseOrdinalNumberPattern","matchEraPatterns","parseEraPatterns","matchQuarterPatterns","parseQuarterPatterns","matchMonthPatterns","parseMonthPatterns","matchDayPatterns","parseDayPatterns","matchDayPeriodPatterns","parseDayPeriodPatterns","match","enUS","getDayOfYear","getISOWeek","getWeekYear","firstWeekContainsDate","firstWeekOfNextYear","firstWeekOfThisYear","startOfWeekYear","firstWeek","getWeek","addLeadingZeros","targetLength","output","lightFormatters","signedYear","dayPeriodEnumValue","numberOfDigits","milliseconds","fractionalSeconds","dayPeriodEnum","formatters","era","signedWeekYear","weekYear","twoDigitYear","isoWeekYear","week","isoWeek","dayOfYear","dayOfWeek","localDayOfWeek","isoDayOfWeek","_localize","timezoneOffset","formatTimezoneWithOptionalMinutes","formatTimezone","formatTimezoneShort","timestamp","delimiter","absOffset","dateLongFormatter","timeLongFormatter","longFormatters","datePattern","timePattern","dateTimeFormat","dayOfYearTokenRE","weekYearTokenRE","throwTokens","isProtectedDayOfYearToken","isProtectedWeekYearToken","warnOrThrowProtectedError","input","_message","message","subject","formattingTokensRegExp","longFormattingTokensRegExp","escapedStringRegExp","doubleQuoteRegExp","unescapedLatinCharacterRegExp","formatStr","locale","defaultLocale","_h","_g","originalDate","parts","substring","firstCharacter","longFormatter","cleanEscapedString","formatterOptions","part","formatter","matched","getDaysInMonth","monthIndex","lastDayOfMonth","getMonth","getYear","isAfter","dateToCompare","isBefore","isSameMonth","isSameYear","setMonth","midMonth","setYear","FIVE_WEEKS","FOUR_WEEKS","getBroadcastWeeksInMonth","dateLib","firstDayOfMonth","firstDayOfWeek","broadcastStartDate","lastDateOfLastWeek","startOfBroadcastWeek","firstOfMonth","endOfBroadcastWeek","startDate","numberOfWeeks","ko","dateFnsEnUS","formatDate","weekNumber","DateLib","overrides","dateLeft","dateRight","years","uniqueYears","yearsArray","formatted","_dateLib","numerals","digitMap","digit","code","localeCode","defaultDateLib","CalendarDay","displayMonth","CalendarMonth","weeks","CalendarWeek","days","CaptionLabel","Chevron","orientation","Day","tdProps","DayButton","buttonProps","UI","DayFlag","SelectionState","Animation","components","selectProps","cssClassSelect","DropdownNav","Footer","Month","calendarMonth","displayIndex","divProps","MonthCaption","MonthGrid","Months","dayPickerContext","createContext","useDayPicker","useContext","MonthsDropdown","Nav","onPreviousClick","onNextClick","previousMonth","nextMonth","navProps","labelPrevious","labelNext","handleNextClick","useCallback","handlePreviousClick","NextMonthButton","Option","PreviousMonthButton","rootRef","Week","trProps","Weekday","Weekdays","WeekNumber","thProps","WeekNumberHeader","Weeks","YearsDropdown","rangeIncludesDate","range","excludeEnds","isDateInterval","matcher","isDateRange","isDateAfterType","isDateBeforeType","isDayOfWeekType","isDatesArray","dateMatchModifiers","matchers","matchersArr","matcherDate","diffBefore","diffAfter","isDayBefore","isDayAfter","createGetModifiers","navStart","navEnd","hidden","showOutsideDays","broadcastCalendar","today","computedNavStart","computedNavEnd","internalModifiersMap","customModifiersMap","isOutside","isBeforeNavStart","isAfterNavEnd","isDisabled","isToday","modifierValue","dayFlags","customModifiers","getClassNamesForModifiers","modifiersClassNames","active","previousValue","getComponents","customComponents","getDataAttributes","dataAttributes","val","getDefaultClassNames","formatCaption","formatMonthCaption","formatDay","formatMonthDropdown","formatWeekdayName","weekday","formatWeekNumber","formatWeekNumberHeader","formatYearDropdown","getFormatters","customFormatters","defaultFormatters","labelDayButton","labelDay","labelGrid","labelCaption","labelGridcell","labelMonthDropdown","labelNav","defaultLabel","_month","labelWeekday","labelWeekNumber","labelWeekNumberHeader","labelYearDropdown","resolveLabel","customLabel","localeLabel","_args","getLabels","customLabels","localeLabels","defaultLabels","defaultLabels.labelDayButton","defaultLabels.labelMonthDropdown","defaultLabels.labelNext","defaultLabels.labelPrevious","defaultLabels.labelWeekNumber","defaultLabels.labelYearDropdown","defaultLabels.labelGrid","defaultLabels.labelGridcell","defaultLabels.labelNav","defaultLabels.labelWeekNumberHeader","defaultLabels.labelWeekday","getMonthOptions","getStyleForModifiers","dayModifiers","modifiersStyles","getWeekdays","ISOWeek","referenceToday","getYearOptions","reverse","firstNavYear","lastNavYear","createNoonOverrides","fallbackWeekStartsOn","toNoonTZDate","normalizedDate","toCalendarDate","zoned","weekStartsOnValue","cursor","endKey","getWeekFn","getISOWeekFn","differenceInCalendarDaysFn","differenceInCalendarMonthsFn","asHtmlElement","queryMonthEls","queryMonthEl","queryCaptionEl","queryWeeksEl","queryNavEl","queryWeekdaysEl","useAnimation","rootElRef","months","focused","previousRootElSnapshotRef","previousMonthsRef","animatingRef","previousMonths","isAfterPreviousMonth","captionAnimationClass","weeksAnimationClass","previousRootElSnapshot","rootElSnapshot","currentMonthElSnapshot","previousMonthElSnapshot","captionEl","weeksEl","previousMonthEls","currentMonthEls","navEl","currentMonthEl","previousMonthEl","cleanUp","previousWeekdaysEl","previousCaptionEl","previousWeeksEl","getDates","displayMonths","maxDate","firstMonth","lastMonth","fixedWeeks","startWeekFirstDate","displayMonthsWeekEnd","constraintWeekEnd","gridEndDate","nOfDays","nOfMonths","extraDates","daysToAdd","getDays","calendarMonths","initialDays","weekDays","getDisplayMonths","firstDisplayedMonth","calendarEndMonth","numberOfMonths","getInitialMonth","defaultMonth","initialMonth","getMonths","dayPickerMonths","firstDateOfFirstWeek","monthDates","nrOfDaysWithFixedWeeks","dayPickerMonth","getNavMonths","startMonth","endMonth","newDate","fromYear","toYear","fromMonth","toMonth","hasYearDropdown","getNextMonth","pagedNavigation","getPreviousMonth","calendarStartMonth","getWeeks","initialWeeks","useControlledValue","controlledValue","uncontrolledValue","useCalendar","setFirstMonth","newInitialMonth","useMemo","disableNavigation","onMonthChange","isDayInCalendar","goToMonth","newMonth","FocusTargetPriority","isFocusableDay","calculateFocusTarget","getModifiers","lastFocused","focusTarget","foundFocusTargetPriority","getFocusableDate","moveBy","moveDir","refDate","focusableDate","getNextFocus","refDay","attempt","targetMonth","focusDay","useFocus","calendar","autoFocus","setLastFocused","focusedDay","setFocused","nextFocus","useMulti","initiallySelected","onSelect","internallySelected","setSelected","selected","triggerDate","newDates","addToRange","initialRange","rangeContainsDayOfWeek","dayOfWeekArr","totalDays","totalDaysLimit","rangeOverlaps","rangeLeft","rangeRight","rangeContainsModifiers","functionMatchers","useRange","excludeDisabled","newRange","useSingle","compareDate","useSelection","single","multi","toTimeZone","toZoneNoon","noonSafe","convertMatcher","convertMatchersToTimeZone","DayPicker","initialProps","nextModifiers","labels","noonOverrides","captionLayout","mode","navLayout","onDayBlur","onDayClick","onDayFocus","onDayKeyDown","onDayMouseEnter","onDayMouseLeave","onPrevClick","showWeekNumber","selectedValue","isFocusTarget","moveFocus","weekdays","isInteractive","handleDayClick","m","handleDayFocus","handleDayBlur","handleDayKeyDown","keyMap","handleDayMouseEnter","handleDayMouseLeave","handleMonthChange","selectedMonth","handleYearChange","selectedYear","contextValue","monthControl","yearControl","ariaLabel","dateFnsKo","module","this","u","o","h","M","g","D","S","_","w","O","c","DatePicker","internalDate","setInternalDate","dayjs","selectedDate","handleApply","handleCancel","displayValue","disabledDays","getQuickSelectOptions","now","DateRangePicker","startLabel","endLabel","internalRange","setInternalRange","fromDay","toDay","handleQuickSelect","numberOfDays","Fragment","usePrevious","SWITCH_NAME","createSwitchContext","SwitchProvider","useSwitchContext","Switch","__scopeSwitch","checkedProp","defaultChecked","onCheckedChange","form","switchProps","button","setButton","hasConsumerStoppedPropagationRef","isFormControl","checked","setChecked","prevChecked","SwitchBubbleInput","THUMB_NAME","SwitchThumb","thumbProps","BUBBLE_INPUT_NAME","control","bubbles","controlSize","inputProto","Thumb","switchVariants","SwitchPrimitives.Root","SwitchPrimitives.Thumb","createCollection","PROVIDER_NAME","createCollectionContext","createCollectionScope","CollectionProviderImpl","useCollectionContext","CollectionProvider","itemMap","COLLECTION_SLOT_NAME","CollectionSlotImpl","CollectionSlot","ITEM_SLOT_NAME","ITEM_DATA_ATTR","CollectionItemSlotImpl","CollectionItemSlot","itemData","useCollection","collectionNode","orderedNodes","DirectionContext","useDirection","localDir","globalDir","ENTRY_FOCUS","GROUP_NAME","Collection","createRovingFocusGroupContext","createRovingFocusGroupScope","RovingFocusProvider","useRovingFocusContext","RovingFocusGroup","RovingFocusGroupImpl","__scopeRovingFocusGroup","dir","currentTabStopIdProp","defaultCurrentTabStopId","onCurrentTabStopIdChange","onEntryFocus","preventScrollOnEntryFocus","groupProps","currentTabStopId","setCurrentTabStopId","isTabbingBackOut","setIsTabbingBackOut","handleEntryFocus","getItems","isClickFocusRef","focusableItemsCount","setFocusableItemsCount","tabStopId","prevCount","isKeyboardFocus","entryFocusEvent","activeItem","currentItem","candidateNodes","ITEM_NAME","RovingFocusGroupItem","focusable","itemProps","autoId","isCurrentTabStop","onFocusableItemAdd","onFocusableItemRemove","focusIntent","getFocusIntent","currentIndex","wrapArray","MAP_KEY_TO_FOCUS_INTENT","getDirectionAwareKey","preventScroll","PREVIOUSLY_FOCUSED_ELEMENT","startIndex","Item","RADIO_NAME","createRadioContext","createRadioScope","RadioProvider","useRadioContext","Radio","__scopeRadio","onCheck","radioProps","RadioBubbleInput","INDICATOR_NAME","RadioIndicator","indicatorProps","ARROW_KEYS","RADIO_GROUP_NAME","createRadioGroupContext","createContextScope2","useRovingFocusGroupScope","useRadioScope","RadioGroupProvider","useRadioGroupContext","RadioGroup","__scopeRadioGroup","valueProp","rovingFocusGroupScope","jsx2","RovingFocusGroup.Root","Primitive2","RadioGroupItem","radioScope","useComposedRefs2","isArrowKeyPressedRef","handleKeyUp","RovingFocusGroup.Item","composeEventHandlers2","INDICATOR_NAME2","RadioGroupIndicator","Item2","Indicator","RadioGroupPrimitives.Root","radioGroupItemVariants","radioGroupIndicatorVariants","RadioGroupPrimitives.Item","RadioGroupPrimitives.Indicator","COLLAPSIBLE_NAME","createCollapsibleContext","createCollapsibleScope","CollapsibleProvider","useCollapsibleContext","Collapsible","__scopeCollapsible","collapsibleProps","CollapsibleTrigger","CollapsibleContent","CollapsibleContentImpl","isPresent","setIsPresent","heightRef","widthRef","isMountAnimationPreventedRef","originalStylesRef","rAF","ACCORDION_NAME","ACCORDION_KEYS","createAccordionContext","useCollapsibleScope","Accordion","type","accordionProps","singleProps","multipleProps","AccordionImplMultiple","AccordionImplSingle","AccordionValueProvider","useAccordionValueContext","AccordionCollapsibleProvider","useAccordionCollapsibleContext","collapsible","accordionSingleProps","AccordionImpl","accordionMultipleProps","handleItemOpen","itemValue","prevValue","handleItemClose","AccordionImplProvider","useAccordionContext","__scopeAccordion","accordionRef","isDirectionLTR","triggerCollection","triggerIndex","triggerCount","homeIndex","endIndex","moveNext","movePrev","clampedIndex","AccordionItemProvider","useAccordionItemContext","AccordionItem","accordionItemProps","accordionContext","valueContext","collapsibleScope","triggerId","CollapsiblePrimitive.Root","open2","HEADER_NAME","AccordionHeader","headerProps","itemContext","AccordionTrigger","collapsibleContext","CollapsiblePrimitive.Trigger","AccordionContent","CollapsiblePrimitive.Content","Header","Trigger2","toKebabCase","toCamelCase","p1","p2","toPascalCase","camelCase","mergeClasses","classes","hasA11yProp","defaultAttributes","Icon","color","strokeWidth","absoluteStrokeWidth","iconNode","createElement","attrs","createLucideIcon","iconName","Check","ChevronDown","CircleCheck","CircleX","TriangleAlert","X","NavigationMenuItem","menu","selectedUrl","onMenuClick","isSubMenuSelected","sub","Accordion.Item","Accordion.Header","Accordion.Trigger","Accordion.Content","subItem","subSelected","SideNavigation","title","menus","headerSlot","openedMenus","setOpenedMenus","Accordion.Root","CHECKBOX_NAME","createCheckboxContext","CheckboxProviderImpl","useCheckboxContext","CheckboxProvider","__scopeCheckbox","internal_do_not_use_render","setControl","bubbleInput","setBubbleInput","isIndeterminate","CheckboxTrigger","onKeyDown","onClick","checkboxProps","initialCheckedStateRef","Checkbox","CheckboxBubbleInput","CheckboxIndicator","defaultCheckedRef","checkboxId","CheckboxPrimitive.Root","CheckboxPrimitive.Indicator","DIALOG_NAME","createDialogContext","DialogProvider","useDialogContext","Dialog","__scopeDialog","DialogTrigger","DialogPortal","OVERLAY_NAME","DialogOverlay","overlayProps","DialogOverlayImpl","DialogContent","DialogContentModal","DialogContentNonModal","DialogContentImpl","TitleWarning","DescriptionWarning","TITLE_NAME","DialogTitle","titleProps","DESCRIPTION_NAME","DialogDescription","descriptionProps","DialogClose","TITLE_WARNING_NAME","WarningProvider","useWarningContext","titleId","titleWarningContext","MESSAGE","DESCRIPTION_WARNING_NAME","descriptionId","describedById","Overlay","Title","Description","Close","Modal","footer","showCloseButton","DialogPrimitive.Root","DialogPrimitive.Portal","DialogPrimitive.Overlay","DialogPrimitive.Content","DialogPrimitive.Close","DialogPrimitive.Title","DialogPrimitive.Description","ConfirmModal","confirmText","onConfirm","handleConfirm","CheckCircle2","DeleteModal","cancelText","onCancel","AlertTriangle","ErrorModal","XCircle","WarningModal","SuccessModal","__insertCSS","getAsset","SuccessIcon","InfoIcon","WarningIcon","ErrorIcon","bars","Loader","visible","CloseIcon","useIsDocumentHidden","isDocumentHidden","setIsDocumentHidden","toastsCounter","Observer","subscriber","_data_id","alreadyExists","toast","dismissible","promise","shouldDismiss","originalPromise","response","isHttpResponse","promiseData","description","toastSettings","unwrap","resolve","reject","ToastState","toastFunction","basicToast","getHistory","getToasts","isAction","action","VISIBLE_TOASTS_AMOUNT","VIEWPORT_OFFSET","MOBILE_VIEWPORT_OFFSET","TOAST_LIFETIME","TOAST_WIDTH","GAP","SWIPE_THRESHOLD","TIME_BEFORE_UNMOUNT","getDefaultSwipeDirections","directions","Toast","_toast_classNames","_toast_classNames1","_toast_classNames2","_toast_classNames3","_toast_classNames4","_toast_classNames5","_toast_classNames6","_toast_classNames7","_toast_classNames8","ToasterInvert","unstyled","interacting","setHeights","visibleToasts","heights","toasts","expanded","removeToast","defaultRichColors","closeButtonFromToaster","cancelButtonStyle","actionButtonStyle","descriptionClassName","durationFromToaster","expandByDefault","icons","closeButtonAriaLabel","swipeDirection","setSwipeDirection","swipeOutDirection","setSwipeOutDirection","removed","setRemoved","swiping","setSwiping","swipeOut","setSwipeOut","isSwiped","setIsSwiped","offsetBeforeRemove","setOffsetBeforeRemove","initialHeight","setInitialHeight","remainingTime","dragStartTime","toastRef","isFront","isVisible","toastType","toastClassname","toastDescriptionClassname","heightIndex","closeButton","_toast_closeButton","duration","closeTimerStartTimeRef","lastCloseTimerStartTimeRef","pointerStartRef","toastsHeightBefore","prev","curr","reducerIndex","toastNode","originalHeight","newHeight","deleteToast","elapsedTime","getLoadingIcon","_toast_richColors","_icons_close","_toastRef_current","_toastRef_current1","_dragStartTime_current","swipeAmountX","swipeAmountY","timeTaken","swipeAmount","velocity","_toastRef_current2","_toastRef_current3","_window_getSelection","yDelta","xDelta","_props_swipeDirections","swipeDirections","getDampening","dampenedDelta","getDocumentDirection","dirAttribute","assignOffset","defaultOffset","mobileOffset","isMobile","assignAll","Toaster","hotkey","expand","richColors","toastOptions","containerAriaLabel","setToasts","filteredToasts","possiblePositions","setExpanded","setInteracting","actualTheme","setActualTheme","listRef","hotkeyLabel","isFocusWithinRef","toastToRemove","_toasts_find","indexOfExistingToast","darkMediaQuery","matches","_listRef_current","_listRef_current1","_heights_","_toastOptions_duration","_toastOptions_closeButton","Sonner"],"mappings":"sqBAAA,SAASA,GAAE,EAAE,CAAC,IAAI,EAAEC,EAAEC,EAAE,GAAG,GAAa,OAAO,GAAjB,UAA8B,OAAO,GAAjB,SAAmBA,GAAG,UAAoB,OAAO,GAAjB,SAAmB,GAAG,MAAM,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,EAAE,OAAO,IAAI,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE,CAAC,IAAID,EAAED,GAAE,EAAE,CAAC,CAAC,KAAKE,IAAIA,GAAG,KAAKA,GAAGD,EAAE,KAAM,KAAIA,KAAK,EAAE,EAAEA,CAAC,IAAIC,IAAIA,GAAG,KAAKA,GAAGD,GAAG,OAAOC,CAAC,CAAQ,SA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48,49,50,51,52,53,54,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,230,231,233,234,235,236,238,239,240,241,242,243,244,245,246,247,248,249,251,253,260]}
|