@handijitcom/ui 0.0.0-stage → 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/LICENSE +21 -0
- package/README.md +1023 -2
- package/build/base.css +1 -0
- package/build/calendar.cjs +2 -0
- package/build/calendar.cjs.map +1 -0
- package/build/calendar.css +1 -0
- package/build/calendar.js +741 -0
- package/build/calendar.js.map +1 -0
- package/build/charts.cjs +2 -0
- package/build/charts.cjs.map +1 -0
- package/build/charts.css +1 -0
- package/build/charts.js +1866 -0
- package/build/charts.js.map +1 -0
- package/build/chat.cjs +4 -0
- package/build/chat.cjs.map +1 -0
- package/build/chat.css +1 -0
- package/build/chat.js +1126 -0
- package/build/chat.js.map +1 -0
- package/build/components/Accordion/index.cjs +2 -0
- package/build/components/Accordion/index.cjs.map +1 -0
- package/build/components/Accordion/index.d.cts +29 -0
- package/build/components/Accordion/index.d.ts +29 -0
- package/build/components/Accordion/index.js +42 -0
- package/build/components/Accordion/index.js.map +1 -0
- package/build/components/Accordion/style.css +1 -0
- package/build/components/Alert/index.cjs +2 -0
- package/build/components/Alert/index.cjs.map +1 -0
- package/build/components/Alert/index.d.cts +15 -0
- package/build/components/Alert/index.d.ts +15 -0
- package/build/components/Alert/index.js +32 -0
- package/build/components/Alert/index.js.map +1 -0
- package/build/components/Alert/style.css +1 -0
- package/build/components/Avatar/index.cjs +2 -0
- package/build/components/Avatar/index.cjs.map +1 -0
- package/build/components/Avatar/index.d.cts +26 -0
- package/build/components/Avatar/index.d.ts +26 -0
- package/build/components/Avatar/index.js +57 -0
- package/build/components/Avatar/index.js.map +1 -0
- package/build/components/Avatar/style.css +1 -0
- package/build/components/Badge/index.cjs +2 -0
- package/build/components/Badge/index.cjs.map +1 -0
- package/build/components/Badge/index.d.cts +21 -0
- package/build/components/Badge/index.d.ts +21 -0
- package/build/components/Badge/index.js +26 -0
- package/build/components/Badge/index.js.map +1 -0
- package/build/components/Badge/style.css +1 -0
- package/build/components/BottomSheet/index.cjs +2 -0
- package/build/components/BottomSheet/index.cjs.map +1 -0
- package/build/components/BottomSheet/index.d.cts +21 -0
- package/build/components/BottomSheet/index.d.ts +21 -0
- package/build/components/BottomSheet/index.js +85 -0
- package/build/components/BottomSheet/index.js.map +1 -0
- package/build/components/BottomSheet/style.css +1 -0
- package/build/components/Breadcrumb/index.cjs +2 -0
- package/build/components/Breadcrumb/index.cjs.map +1 -0
- package/build/components/Breadcrumb/index.d.cts +20 -0
- package/build/components/Breadcrumb/index.d.ts +20 -0
- package/build/components/Breadcrumb/index.js +31 -0
- package/build/components/Breadcrumb/index.js.map +1 -0
- package/build/components/Breadcrumb/style.css +1 -0
- package/build/components/Button/index.cjs +2 -0
- package/build/components/Button/index.cjs.map +1 -0
- package/build/components/Button/index.d.cts +32 -0
- package/build/components/Button/index.d.ts +32 -0
- package/build/components/Button/index.js +88 -0
- package/build/components/Button/index.js.map +1 -0
- package/build/components/Button/style.css +1 -0
- package/build/components/Card/index.cjs +2 -0
- package/build/components/Card/index.cjs.map +1 -0
- package/build/components/Card/index.d.cts +51 -0
- package/build/components/Card/index.d.ts +51 -0
- package/build/components/Card/index.js +58 -0
- package/build/components/Card/index.js.map +1 -0
- package/build/components/Card/style.css +1 -0
- package/build/components/Carousel/index.cjs +2 -0
- package/build/components/Carousel/index.cjs.map +1 -0
- package/build/components/Carousel/index.d.cts +24 -0
- package/build/components/Carousel/index.d.ts +24 -0
- package/build/components/Carousel/index.js +111 -0
- package/build/components/Carousel/index.js.map +1 -0
- package/build/components/Carousel/style.css +1 -0
- package/build/components/Checkbox/index.cjs +2 -0
- package/build/components/Checkbox/index.cjs.map +1 -0
- package/build/components/Checkbox/index.d.cts +15 -0
- package/build/components/Checkbox/index.d.ts +15 -0
- package/build/components/Checkbox/index.js +50 -0
- package/build/components/Checkbox/index.js.map +1 -0
- package/build/components/Checkbox/style.css +1 -0
- package/build/components/Chip/index.cjs +2 -0
- package/build/components/Chip/index.cjs.map +1 -0
- package/build/components/Chip/index.d.cts +27 -0
- package/build/components/Chip/index.d.ts +27 -0
- package/build/components/Chip/index.js +67 -0
- package/build/components/Chip/index.js.map +1 -0
- package/build/components/Chip/style.css +1 -0
- package/build/components/ChipGroup/index.cjs +2 -0
- package/build/components/ChipGroup/index.cjs.map +1 -0
- package/build/components/ChipGroup/index.d.cts +53 -0
- package/build/components/ChipGroup/index.d.ts +53 -0
- package/build/components/ChipGroup/index.js +81 -0
- package/build/components/ChipGroup/index.js.map +1 -0
- package/build/components/ChipGroup/style.css +1 -0
- package/build/components/CodeBadge/index.cjs +2 -0
- package/build/components/CodeBadge/index.cjs.map +1 -0
- package/build/components/CodeBadge/index.d.cts +36 -0
- package/build/components/CodeBadge/index.d.ts +36 -0
- package/build/components/CodeBadge/index.js +62 -0
- package/build/components/CodeBadge/index.js.map +1 -0
- package/build/components/CodeBadge/style.css +1 -0
- package/build/components/Combobox/index.cjs +2 -0
- package/build/components/Combobox/index.cjs.map +1 -0
- package/build/components/Combobox/index.d.cts +8 -0
- package/build/components/Combobox/index.d.ts +8 -0
- package/build/components/Combobox/index.js +332 -0
- package/build/components/Combobox/index.js.map +1 -0
- package/build/components/Combobox/style.css +1 -0
- package/build/components/CommandPalette/index.cjs +2 -0
- package/build/components/CommandPalette/index.cjs.map +1 -0
- package/build/components/CommandPalette/index.d.cts +37 -0
- package/build/components/CommandPalette/index.d.ts +37 -0
- package/build/components/CommandPalette/index.js +181 -0
- package/build/components/CommandPalette/index.js.map +1 -0
- package/build/components/CommandPalette/style.css +1 -0
- package/build/components/ConfirmDialog/index.cjs +2 -0
- package/build/components/ConfirmDialog/index.cjs.map +1 -0
- package/build/components/ConfirmDialog/index.d.cts +34 -0
- package/build/components/ConfirmDialog/index.d.ts +34 -0
- package/build/components/ConfirmDialog/index.js +85 -0
- package/build/components/ConfirmDialog/index.js.map +1 -0
- package/build/components/CopyField/index.cjs +2 -0
- package/build/components/CopyField/index.cjs.map +1 -0
- package/build/components/CopyField/index.d.cts +20 -0
- package/build/components/CopyField/index.d.ts +20 -0
- package/build/components/CopyField/index.js +44 -0
- package/build/components/CopyField/index.js.map +1 -0
- package/build/components/CopyField/style.css +1 -0
- package/build/components/DataTable/index.cjs +2 -0
- package/build/components/DataTable/index.cjs.map +1 -0
- package/build/components/DataTable/index.d.cts +60 -0
- package/build/components/DataTable/index.d.ts +60 -0
- package/build/components/DataTable/index.js +109 -0
- package/build/components/DataTable/index.js.map +1 -0
- package/build/components/DataTable/style.css +1 -0
- package/build/components/DateField/index.cjs +2 -0
- package/build/components/DateField/index.cjs.map +1 -0
- package/build/components/DateField/index.d.cts +57 -0
- package/build/components/DateField/index.d.ts +57 -0
- package/build/components/DateField/index.js +90 -0
- package/build/components/DateField/index.js.map +1 -0
- package/build/components/DateField/style.css +1 -0
- package/build/components/Directory/index.cjs +2 -0
- package/build/components/Directory/index.cjs.map +1 -0
- package/build/components/Directory/index.d.cts +51 -0
- package/build/components/Directory/index.d.ts +51 -0
- package/build/components/Directory/index.js +46 -0
- package/build/components/Directory/index.js.map +1 -0
- package/build/components/Directory/style.css +1 -0
- package/build/components/Disclosure/index.cjs +2 -0
- package/build/components/Disclosure/index.cjs.map +1 -0
- package/build/components/Disclosure/index.d.cts +34 -0
- package/build/components/Disclosure/index.d.ts +34 -0
- package/build/components/Disclosure/index.js +64 -0
- package/build/components/Disclosure/index.js.map +1 -0
- package/build/components/Disclosure/style.css +1 -0
- package/build/components/Divider/index.cjs +2 -0
- package/build/components/Divider/index.cjs.map +1 -0
- package/build/components/Divider/index.d.cts +10 -0
- package/build/components/Divider/index.d.ts +10 -0
- package/build/components/Divider/index.js +24 -0
- package/build/components/Divider/index.js.map +1 -0
- package/build/components/Divider/style.css +1 -0
- package/build/components/Drawer/index.cjs +2 -0
- package/build/components/Drawer/index.cjs.map +1 -0
- package/build/components/Drawer/index.d.cts +29 -0
- package/build/components/Drawer/index.d.ts +29 -0
- package/build/components/Drawer/index.js +91 -0
- package/build/components/Drawer/index.js.map +1 -0
- package/build/components/Drawer/style.css +1 -0
- package/build/components/EmptyState/index.cjs +2 -0
- package/build/components/EmptyState/index.cjs.map +1 -0
- package/build/components/EmptyState/index.d.cts +19 -0
- package/build/components/EmptyState/index.d.ts +19 -0
- package/build/components/EmptyState/index.js +35 -0
- package/build/components/EmptyState/index.js.map +1 -0
- package/build/components/EmptyState/style.css +1 -0
- package/build/components/Field/index.cjs +2 -0
- package/build/components/Field/index.cjs.map +1 -0
- package/build/components/Field/index.d.cts +37 -0
- package/build/components/Field/index.d.ts +37 -0
- package/build/components/Field/index.js +54 -0
- package/build/components/Field/index.js.map +1 -0
- package/build/components/Field/style.css +1 -0
- package/build/components/FileUpload/index.cjs +2 -0
- package/build/components/FileUpload/index.cjs.map +1 -0
- package/build/components/FileUpload/index.d.cts +42 -0
- package/build/components/FileUpload/index.d.ts +42 -0
- package/build/components/FileUpload/index.js +145 -0
- package/build/components/FileUpload/index.js.map +1 -0
- package/build/components/FileUpload/style.css +1 -0
- package/build/components/FilterBar/index.cjs +2 -0
- package/build/components/FilterBar/index.cjs.map +1 -0
- package/build/components/FilterBar/index.d.cts +28 -0
- package/build/components/FilterBar/index.d.ts +28 -0
- package/build/components/FilterBar/index.js +35 -0
- package/build/components/FilterBar/index.js.map +1 -0
- package/build/components/FilterBar/style.css +1 -0
- package/build/components/IconButton/index.cjs +2 -0
- package/build/components/IconButton/index.cjs.map +1 -0
- package/build/components/IconButton/index.d.cts +26 -0
- package/build/components/IconButton/index.d.ts +26 -0
- package/build/components/IconButton/index.js +61 -0
- package/build/components/IconButton/index.js.map +1 -0
- package/build/components/IconButton/style.css +1 -0
- package/build/components/Input/index.cjs +2 -0
- package/build/components/Input/index.cjs.map +1 -0
- package/build/components/Input/index.d.cts +15 -0
- package/build/components/Input/index.d.ts +15 -0
- package/build/components/Input/index.js +52 -0
- package/build/components/Input/index.js.map +1 -0
- package/build/components/Input/style.css +1 -0
- package/build/components/Kbd/index.cjs +2 -0
- package/build/components/Kbd/index.cjs.map +1 -0
- package/build/components/Kbd/index.d.cts +12 -0
- package/build/components/Kbd/index.d.ts +12 -0
- package/build/components/Kbd/index.js +13 -0
- package/build/components/Kbd/index.js.map +1 -0
- package/build/components/Kbd/style.css +1 -0
- package/build/components/Link/index.cjs +2 -0
- package/build/components/Link/index.cjs.map +1 -0
- package/build/components/Link/index.d.cts +5 -0
- package/build/components/Link/index.d.ts +5 -0
- package/build/components/Link/index.js +11 -0
- package/build/components/Link/index.js.map +1 -0
- package/build/components/Menu/index.cjs +2 -0
- package/build/components/Menu/index.cjs.map +1 -0
- package/build/components/Menu/index.d.cts +46 -0
- package/build/components/Menu/index.d.ts +46 -0
- package/build/components/Menu/index.js +241 -0
- package/build/components/Menu/index.js.map +1 -0
- package/build/components/Menu/style.css +1 -0
- package/build/components/Modal/index.cjs +2 -0
- package/build/components/Modal/index.cjs.map +1 -0
- package/build/components/Modal/index.d.cts +35 -0
- package/build/components/Modal/index.d.ts +35 -0
- package/build/components/Modal/index.js +95 -0
- package/build/components/Modal/index.js.map +1 -0
- package/build/components/Modal/style.css +1 -0
- package/build/components/MoneyInput/index.cjs +2 -0
- package/build/components/MoneyInput/index.cjs.map +1 -0
- package/build/components/MoneyInput/index.d.cts +17 -0
- package/build/components/MoneyInput/index.d.ts +17 -0
- package/build/components/MoneyInput/index.js +22 -0
- package/build/components/MoneyInput/index.js.map +1 -0
- package/build/components/PageHeader/index.cjs +2 -0
- package/build/components/PageHeader/index.cjs.map +1 -0
- package/build/components/PageHeader/index.d.cts +24 -0
- package/build/components/PageHeader/index.d.ts +24 -0
- package/build/components/PageHeader/index.js +34 -0
- package/build/components/PageHeader/index.js.map +1 -0
- package/build/components/PageHeader/style.css +1 -0
- package/build/components/Pagination/index.cjs +2 -0
- package/build/components/Pagination/index.cjs.map +1 -0
- package/build/components/Pagination/index.d.cts +39 -0
- package/build/components/Pagination/index.d.ts +39 -0
- package/build/components/Pagination/index.js +128 -0
- package/build/components/Pagination/index.js.map +1 -0
- package/build/components/Pagination/style.css +1 -0
- package/build/components/Panel/index.cjs +2 -0
- package/build/components/Panel/index.cjs.map +1 -0
- package/build/components/Panel/index.d.cts +43 -0
- package/build/components/Panel/index.d.ts +43 -0
- package/build/components/Panel/index.js +55 -0
- package/build/components/Panel/index.js.map +1 -0
- package/build/components/Panel/style.css +1 -0
- package/build/components/PasswordInput/index.cjs +2 -0
- package/build/components/PasswordInput/index.cjs.map +1 -0
- package/build/components/PasswordInput/index.d.cts +14 -0
- package/build/components/PasswordInput/index.d.ts +14 -0
- package/build/components/PasswordInput/index.js +40 -0
- package/build/components/PasswordInput/index.js.map +1 -0
- package/build/components/PasswordInput/style.css +1 -0
- package/build/components/PercentInput/index.cjs +2 -0
- package/build/components/PercentInput/index.cjs.map +1 -0
- package/build/components/PercentInput/index.d.cts +10 -0
- package/build/components/PercentInput/index.d.ts +10 -0
- package/build/components/PercentInput/index.js +14 -0
- package/build/components/PercentInput/index.js.map +1 -0
- package/build/components/Popover/index.cjs +2 -0
- package/build/components/Popover/index.cjs.map +1 -0
- package/build/components/Popover/index.d.cts +26 -0
- package/build/components/Popover/index.d.ts +26 -0
- package/build/components/Popover/index.js +106 -0
- package/build/components/Popover/index.js.map +1 -0
- package/build/components/Popover/style.css +1 -0
- package/build/components/Price/index.cjs +2 -0
- package/build/components/Price/index.cjs.map +1 -0
- package/build/components/Price/index.d.cts +22 -0
- package/build/components/Price/index.d.ts +22 -0
- package/build/components/Price/index.js +46 -0
- package/build/components/Price/index.js.map +1 -0
- package/build/components/Price/style.css +1 -0
- package/build/components/Progress/index.cjs +2 -0
- package/build/components/Progress/index.cjs.map +1 -0
- package/build/components/Progress/index.d.cts +59 -0
- package/build/components/Progress/index.d.ts +59 -0
- package/build/components/Progress/index.js +124 -0
- package/build/components/Progress/index.js.map +1 -0
- package/build/components/Progress/style.css +1 -0
- package/build/components/PromptDialog/index.cjs +2 -0
- package/build/components/PromptDialog/index.cjs.map +1 -0
- package/build/components/PromptDialog/index.d.cts +36 -0
- package/build/components/PromptDialog/index.d.ts +36 -0
- package/build/components/PromptDialog/index.js +119 -0
- package/build/components/PromptDialog/index.js.map +1 -0
- package/build/components/PromptDialog/style.css +1 -0
- package/build/components/QuantityInput/index.cjs +2 -0
- package/build/components/QuantityInput/index.cjs.map +1 -0
- package/build/components/QuantityInput/index.d.cts +17 -0
- package/build/components/QuantityInput/index.d.ts +17 -0
- package/build/components/QuantityInput/index.js +23 -0
- package/build/components/QuantityInput/index.js.map +1 -0
- package/build/components/QuantityStepper/index.cjs +2 -0
- package/build/components/QuantityStepper/index.cjs.map +1 -0
- package/build/components/QuantityStepper/index.d.cts +37 -0
- package/build/components/QuantityStepper/index.d.ts +37 -0
- package/build/components/QuantityStepper/index.js +118 -0
- package/build/components/QuantityStepper/index.js.map +1 -0
- package/build/components/QuantityStepper/style.css +1 -0
- package/build/components/Radio/index.cjs +2 -0
- package/build/components/Radio/index.cjs.map +1 -0
- package/build/components/Radio/index.d.cts +18 -0
- package/build/components/Radio/index.d.ts +18 -0
- package/build/components/Radio/index.js +53 -0
- package/build/components/Radio/index.js.map +1 -0
- package/build/components/Radio/style.css +1 -0
- package/build/components/RadioCard/index.cjs +2 -0
- package/build/components/RadioCard/index.cjs.map +1 -0
- package/build/components/RadioCard/index.d.cts +16 -0
- package/build/components/RadioCard/index.d.ts +16 -0
- package/build/components/RadioCard/index.js +48 -0
- package/build/components/RadioCard/index.js.map +1 -0
- package/build/components/RadioCard/style.css +1 -0
- package/build/components/RangeSlider/index.cjs +2 -0
- package/build/components/RangeSlider/index.cjs.map +1 -0
- package/build/components/RangeSlider/index.d.cts +45 -0
- package/build/components/RangeSlider/index.d.ts +45 -0
- package/build/components/RangeSlider/index.js +121 -0
- package/build/components/RangeSlider/index.js.map +1 -0
- package/build/components/RangeSlider/style.css +1 -0
- package/build/components/RateInput/index.cjs +2 -0
- package/build/components/RateInput/index.cjs.map +1 -0
- package/build/components/RateInput/index.d.cts +9 -0
- package/build/components/RateInput/index.d.ts +9 -0
- package/build/components/RateInput/index.js +18 -0
- package/build/components/RateInput/index.js.map +1 -0
- package/build/components/Rating/index.cjs +2 -0
- package/build/components/Rating/index.cjs.map +1 -0
- package/build/components/Rating/index.d.cts +16 -0
- package/build/components/Rating/index.d.ts +16 -0
- package/build/components/Rating/index.js +29 -0
- package/build/components/Rating/index.js.map +1 -0
- package/build/components/Rating/style.css +1 -0
- package/build/components/RatingInput/index.cjs +2 -0
- package/build/components/RatingInput/index.cjs.map +1 -0
- package/build/components/RatingInput/index.d.cts +34 -0
- package/build/components/RatingInput/index.d.ts +34 -0
- package/build/components/RatingInput/index.js +89 -0
- package/build/components/RatingInput/index.js.map +1 -0
- package/build/components/RatingInput/style.css +1 -0
- package/build/components/ScaledInput/index.cjs +2 -0
- package/build/components/ScaledInput/index.cjs.map +1 -0
- package/build/components/ScaledInput/index.d.cts +77 -0
- package/build/components/ScaledInput/index.d.ts +77 -0
- package/build/components/ScaledInput/index.js +77 -0
- package/build/components/ScaledInput/index.js.map +1 -0
- package/build/components/ScaledInput/style.css +1 -0
- package/build/components/ScrollArea/index.cjs +2 -0
- package/build/components/ScrollArea/index.cjs.map +1 -0
- package/build/components/ScrollArea/index.d.cts +23 -0
- package/build/components/ScrollArea/index.d.ts +23 -0
- package/build/components/ScrollArea/index.js +65 -0
- package/build/components/ScrollArea/index.js.map +1 -0
- package/build/components/ScrollArea/style.css +1 -0
- package/build/components/SectionHeader/index.cjs +2 -0
- package/build/components/SectionHeader/index.cjs.map +1 -0
- package/build/components/SectionHeader/index.d.cts +17 -0
- package/build/components/SectionHeader/index.d.ts +17 -0
- package/build/components/SectionHeader/index.js +25 -0
- package/build/components/SectionHeader/index.js.map +1 -0
- package/build/components/SectionHeader/style.css +1 -0
- package/build/components/SegmentedControl/index.cjs +2 -0
- package/build/components/SegmentedControl/index.cjs.map +1 -0
- package/build/components/SegmentedControl/index.d.cts +39 -0
- package/build/components/SegmentedControl/index.d.ts +39 -0
- package/build/components/SegmentedControl/index.js +84 -0
- package/build/components/SegmentedControl/index.js.map +1 -0
- package/build/components/SegmentedControl/style.css +1 -0
- package/build/components/Select/index.cjs +2 -0
- package/build/components/Select/index.cjs.map +1 -0
- package/build/components/Select/index.d.cts +52 -0
- package/build/components/Select/index.d.ts +52 -0
- package/build/components/Select/index.js +206 -0
- package/build/components/Select/index.js.map +1 -0
- package/build/components/Select/style.css +1 -0
- package/build/components/Skeleton/index.cjs +2 -0
- package/build/components/Skeleton/index.cjs.map +1 -0
- package/build/components/Skeleton/index.d.cts +25 -0
- package/build/components/Skeleton/index.d.ts +25 -0
- package/build/components/Skeleton/index.js +50 -0
- package/build/components/Skeleton/index.js.map +1 -0
- package/build/components/Skeleton/style.css +1 -0
- package/build/components/Spinner/index.cjs +2 -0
- package/build/components/Spinner/index.cjs.map +1 -0
- package/build/components/Spinner/index.d.cts +16 -0
- package/build/components/Spinner/index.d.ts +16 -0
- package/build/components/Spinner/index.js +15 -0
- package/build/components/Spinner/index.js.map +1 -0
- package/build/components/Spinner/style.css +1 -0
- package/build/components/Stat/index.cjs +2 -0
- package/build/components/Stat/index.cjs.map +1 -0
- package/build/components/Stat/index.d.cts +34 -0
- package/build/components/Stat/index.d.ts +34 -0
- package/build/components/Stat/index.js +72 -0
- package/build/components/Stat/index.js.map +1 -0
- package/build/components/Stat/style.css +1 -0
- package/build/components/StatusDot/index.cjs +2 -0
- package/build/components/StatusDot/index.cjs.map +1 -0
- package/build/components/StatusDot/index.d.cts +23 -0
- package/build/components/StatusDot/index.d.ts +23 -0
- package/build/components/StatusDot/index.js +23 -0
- package/build/components/StatusDot/index.js.map +1 -0
- package/build/components/StatusDot/style.css +1 -0
- package/build/components/Steps/index.cjs +2 -0
- package/build/components/Steps/index.cjs.map +1 -0
- package/build/components/Steps/index.d.cts +23 -0
- package/build/components/Steps/index.d.ts +23 -0
- package/build/components/Steps/index.js +69 -0
- package/build/components/Steps/index.js.map +1 -0
- package/build/components/Steps/style.css +1 -0
- package/build/components/SummaryCard/index.cjs +2 -0
- package/build/components/SummaryCard/index.cjs.map +1 -0
- package/build/components/SummaryCard/index.d.cts +24 -0
- package/build/components/SummaryCard/index.d.ts +24 -0
- package/build/components/SummaryCard/index.js +33 -0
- package/build/components/SummaryCard/index.js.map +1 -0
- package/build/components/SummaryCard/style.css +1 -0
- package/build/components/Switch/index.cjs +2 -0
- package/build/components/Switch/index.cjs.map +1 -0
- package/build/components/Switch/index.d.cts +21 -0
- package/build/components/Switch/index.d.ts +21 -0
- package/build/components/Switch/index.js +60 -0
- package/build/components/Switch/index.js.map +1 -0
- package/build/components/Switch/style.css +1 -0
- package/build/components/Table/index.cjs +2 -0
- package/build/components/Table/index.cjs.map +1 -0
- package/build/components/Table/index.d.cts +28 -0
- package/build/components/Table/index.d.ts +28 -0
- package/build/components/Table/index.js +58 -0
- package/build/components/Table/index.js.map +1 -0
- package/build/components/Table/style.css +1 -0
- package/build/components/TableCheckbox/index.cjs +2 -0
- package/build/components/TableCheckbox/index.cjs.map +1 -0
- package/build/components/TableCheckbox/index.d.cts +15 -0
- package/build/components/TableCheckbox/index.d.ts +15 -0
- package/build/components/TableCheckbox/index.js +31 -0
- package/build/components/TableCheckbox/index.js.map +1 -0
- package/build/components/TableCheckbox/style.css +1 -0
- package/build/components/Tabs/index.cjs +2 -0
- package/build/components/Tabs/index.cjs.map +1 -0
- package/build/components/Tabs/index.d.cts +27 -0
- package/build/components/Tabs/index.d.ts +27 -0
- package/build/components/Tabs/index.js +102 -0
- package/build/components/Tabs/index.js.map +1 -0
- package/build/components/Tabs/style.css +1 -0
- package/build/components/TagInput/index.cjs +2 -0
- package/build/components/TagInput/index.cjs.map +1 -0
- package/build/components/TagInput/index.d.cts +43 -0
- package/build/components/TagInput/index.d.ts +43 -0
- package/build/components/TagInput/index.js +134 -0
- package/build/components/TagInput/index.js.map +1 -0
- package/build/components/TagInput/style.css +1 -0
- package/build/components/TextLink/index.cjs +2 -0
- package/build/components/TextLink/index.cjs.map +1 -0
- package/build/components/TextLink/index.d.cts +16 -0
- package/build/components/TextLink/index.d.ts +16 -0
- package/build/components/TextLink/index.js +32 -0
- package/build/components/TextLink/index.js.map +1 -0
- package/build/components/TextLink/style.css +1 -0
- package/build/components/Textarea/index.cjs +2 -0
- package/build/components/Textarea/index.cjs.map +1 -0
- package/build/components/Textarea/index.d.cts +20 -0
- package/build/components/Textarea/index.d.ts +20 -0
- package/build/components/Textarea/index.js +68 -0
- package/build/components/Textarea/index.js.map +1 -0
- package/build/components/Textarea/style.css +1 -0
- package/build/components/Tile/index.cjs +2 -0
- package/build/components/Tile/index.cjs.map +1 -0
- package/build/components/Tile/index.d.cts +19 -0
- package/build/components/Tile/index.d.ts +19 -0
- package/build/components/Tile/index.js +24 -0
- package/build/components/Tile/index.js.map +1 -0
- package/build/components/Tile/style.css +1 -0
- package/build/components/Timeline/index.cjs +2 -0
- package/build/components/Timeline/index.cjs.map +1 -0
- package/build/components/Timeline/index.d.cts +24 -0
- package/build/components/Timeline/index.d.ts +24 -0
- package/build/components/Timeline/index.js +56 -0
- package/build/components/Timeline/index.js.map +1 -0
- package/build/components/Timeline/style.css +1 -0
- package/build/components/Toast/index.cjs +2 -0
- package/build/components/Toast/index.cjs.map +1 -0
- package/build/components/Toast/index.d.cts +63 -0
- package/build/components/Toast/index.d.ts +63 -0
- package/build/components/Toast/index.js +159 -0
- package/build/components/Toast/index.js.map +1 -0
- package/build/components/Toast/style.css +1 -0
- package/build/components/ToastPortal/index.cjs +2 -0
- package/build/components/ToastPortal/index.cjs.map +1 -0
- package/build/components/ToastPortal/index.d.cts +10 -0
- package/build/components/ToastPortal/index.d.ts +10 -0
- package/build/components/ToastPortal/index.js +15 -0
- package/build/components/ToastPortal/index.js.map +1 -0
- package/build/components/Tooltip/index.cjs +2 -0
- package/build/components/Tooltip/index.cjs.map +1 -0
- package/build/components/Tooltip/index.d.cts +23 -0
- package/build/components/Tooltip/index.d.ts +23 -0
- package/build/components/Tooltip/index.js +116 -0
- package/build/components/Tooltip/index.js.map +1 -0
- package/build/components/Tooltip/style.css +1 -0
- package/build/constants/breakpoint.constants.cjs +2 -0
- package/build/constants/breakpoint.constants.cjs.map +1 -0
- package/build/constants/breakpoint.constants.d.cts +15 -0
- package/build/constants/breakpoint.constants.d.ts +15 -0
- package/build/constants/breakpoint.constants.js +12 -0
- package/build/constants/breakpoint.constants.js.map +1 -0
- package/build/constants/combobox.constants.cjs +2 -0
- package/build/constants/combobox.constants.cjs.map +1 -0
- package/build/constants/combobox.constants.d.cts +11 -0
- package/build/constants/combobox.constants.d.ts +11 -0
- package/build/constants/combobox.constants.js +7 -0
- package/build/constants/combobox.constants.js.map +1 -0
- package/build/constants/scale.constants.cjs +2 -0
- package/build/constants/scale.constants.cjs.map +1 -0
- package/build/constants/scale.constants.d.cts +11 -0
- package/build/constants/scale.constants.d.ts +11 -0
- package/build/constants/scale.constants.js +8 -0
- package/build/constants/scale.constants.js.map +1 -0
- package/build/constants/scroll.constants.cjs +2 -0
- package/build/constants/scroll.constants.cjs.map +1 -0
- package/build/constants/scroll.constants.d.cts +7 -0
- package/build/constants/scroll.constants.d.ts +7 -0
- package/build/constants/scroll.constants.js +5 -0
- package/build/constants/scroll.constants.js.map +1 -0
- package/build/enums/ui-size.enum.cjs +2 -0
- package/build/enums/ui-size.enum.cjs.map +1 -0
- package/build/enums/ui-size.enum.d.cts +12 -0
- package/build/enums/ui-size.enum.d.ts +12 -0
- package/build/enums/ui-size.enum.js +5 -0
- package/build/enums/ui-size.enum.js.map +1 -0
- package/build/enums/ui-variant.enum.cjs +2 -0
- package/build/enums/ui-variant.enum.cjs.map +1 -0
- package/build/enums/ui-variant.enum.d.cts +20 -0
- package/build/enums/ui-variant.enum.d.ts +20 -0
- package/build/enums/ui-variant.enum.js +5 -0
- package/build/enums/ui-variant.enum.js.map +1 -0
- package/build/helpers/aria.helper.cjs +2 -0
- package/build/helpers/aria.helper.cjs.map +1 -0
- package/build/helpers/aria.helper.d.cts +7 -0
- package/build/helpers/aria.helper.d.ts +7 -0
- package/build/helpers/aria.helper.js +5 -0
- package/build/helpers/aria.helper.js.map +1 -0
- package/build/helpers/class-name.helper.cjs +2 -0
- package/build/helpers/class-name.helper.cjs.map +1 -0
- package/build/helpers/class-name.helper.d.cts +3 -0
- package/build/helpers/class-name.helper.d.ts +3 -0
- package/build/helpers/class-name.helper.js +10 -0
- package/build/helpers/class-name.helper.js.map +1 -0
- package/build/helpers/component.helper.cjs +2 -0
- package/build/helpers/component.helper.cjs.map +1 -0
- package/build/helpers/component.helper.d.cts +13 -0
- package/build/helpers/component.helper.d.ts +13 -0
- package/build/helpers/component.helper.js +5 -0
- package/build/helpers/component.helper.js.map +1 -0
- package/build/helpers/focus.helper.cjs +2 -0
- package/build/helpers/focus.helper.cjs.map +1 -0
- package/build/helpers/focus.helper.d.cts +90 -0
- package/build/helpers/focus.helper.d.ts +90 -0
- package/build/helpers/focus.helper.js +83 -0
- package/build/helpers/focus.helper.js.map +1 -0
- package/build/helpers/label.helper.cjs +2 -0
- package/build/helpers/label.helper.cjs.map +1 -0
- package/build/helpers/label.helper.d.cts +11 -0
- package/build/helpers/label.helper.d.ts +11 -0
- package/build/helpers/label.helper.js +11 -0
- package/build/helpers/label.helper.js.map +1 -0
- package/build/helpers/portal.helper.cjs +2 -0
- package/build/helpers/portal.helper.cjs.map +1 -0
- package/build/helpers/portal.helper.d.cts +28 -0
- package/build/helpers/portal.helper.d.ts +28 -0
- package/build/helpers/portal.helper.js +36 -0
- package/build/helpers/portal.helper.js.map +1 -0
- package/build/helpers/ref.helper.cjs +2 -0
- package/build/helpers/ref.helper.cjs.map +1 -0
- package/build/helpers/ref.helper.d.cts +3 -0
- package/build/helpers/ref.helper.d.ts +3 -0
- package/build/helpers/ref.helper.js +7 -0
- package/build/helpers/ref.helper.js.map +1 -0
- package/build/helpers/scaled-number.helper.cjs +2 -0
- package/build/helpers/scaled-number.helper.cjs.map +1 -0
- package/build/helpers/scaled-number.helper.d.cts +55 -0
- package/build/helpers/scaled-number.helper.d.ts +55 -0
- package/build/helpers/scaled-number.helper.js +34 -0
- package/build/helpers/scaled-number.helper.js.map +1 -0
- package/build/helpers/scroll.helper.cjs +2 -0
- package/build/helpers/scroll.helper.cjs.map +1 -0
- package/build/helpers/scroll.helper.d.cts +8 -0
- package/build/helpers/scroll.helper.d.ts +8 -0
- package/build/helpers/scroll.helper.js +11 -0
- package/build/helpers/scroll.helper.js.map +1 -0
- package/build/helpers/text.helper.cjs +2 -0
- package/build/helpers/text.helper.cjs.map +1 -0
- package/build/helpers/text.helper.d.cts +5 -0
- package/build/helpers/text.helper.d.ts +5 -0
- package/build/helpers/text.helper.js +6 -0
- package/build/helpers/text.helper.js.map +1 -0
- package/build/helpers/theme.helper.cjs +2 -0
- package/build/helpers/theme.helper.cjs.map +1 -0
- package/build/helpers/theme.helper.d.cts +18 -0
- package/build/helpers/theme.helper.d.ts +18 -0
- package/build/helpers/theme.helper.js +37 -0
- package/build/helpers/theme.helper.js.map +1 -0
- package/build/hooks/useAnnounce.cjs +2 -0
- package/build/hooks/useAnnounce.cjs.map +1 -0
- package/build/hooks/useAnnounce.d.cts +4 -0
- package/build/hooks/useAnnounce.d.ts +4 -0
- package/build/hooks/useAnnounce.js +23 -0
- package/build/hooks/useAnnounce.js.map +1 -0
- package/build/hooks/useAsyncSearch.cjs +2 -0
- package/build/hooks/useAsyncSearch.cjs.map +1 -0
- package/build/hooks/useAsyncSearch.d.cts +11 -0
- package/build/hooks/useAsyncSearch.d.ts +11 -0
- package/build/hooks/useAsyncSearch.js +17 -0
- package/build/hooks/useAsyncSearch.js.map +1 -0
- package/build/hooks/useCopyFeedback.cjs +2 -0
- package/build/hooks/useCopyFeedback.cjs.map +1 -0
- package/build/hooks/useCopyFeedback.d.cts +10 -0
- package/build/hooks/useCopyFeedback.d.ts +10 -0
- package/build/hooks/useCopyFeedback.js +25 -0
- package/build/hooks/useCopyFeedback.js.map +1 -0
- package/build/hooks/useDismissOnEscape.cjs +2 -0
- package/build/hooks/useDismissOnEscape.cjs.map +1 -0
- package/build/hooks/useDismissOnEscape.d.cts +16 -0
- package/build/hooks/useDismissOnEscape.d.ts +16 -0
- package/build/hooks/useDismissOnEscape.js +18 -0
- package/build/hooks/useDismissOnEscape.js.map +1 -0
- package/build/hooks/useListboxNavigation.cjs +2 -0
- package/build/hooks/useListboxNavigation.cjs.map +1 -0
- package/build/hooks/useListboxNavigation.d.cts +7 -0
- package/build/hooks/useListboxNavigation.d.ts +7 -0
- package/build/hooks/useListboxNavigation.js +53 -0
- package/build/hooks/useListboxNavigation.js.map +1 -0
- package/build/hooks/usePortalSurface.cjs +2 -0
- package/build/hooks/usePortalSurface.cjs.map +1 -0
- package/build/hooks/usePortalSurface.d.cts +25 -0
- package/build/hooks/usePortalSurface.d.ts +25 -0
- package/build/hooks/usePortalSurface.js +19 -0
- package/build/hooks/usePortalSurface.js.map +1 -0
- package/build/hooks/usePositioning.cjs +2 -0
- package/build/hooks/usePositioning.cjs.map +1 -0
- package/build/hooks/usePositioning.d.cts +13 -0
- package/build/hooks/usePositioning.d.ts +13 -0
- package/build/hooks/usePositioning.js +74 -0
- package/build/hooks/usePositioning.js.map +1 -0
- package/build/hooks/useScrollLock.cjs +2 -0
- package/build/hooks/useScrollLock.cjs.map +1 -0
- package/build/hooks/useScrollLock.d.cts +2 -0
- package/build/hooks/useScrollLock.d.ts +2 -0
- package/build/hooks/useScrollLock.js +34 -0
- package/build/hooks/useScrollLock.js.map +1 -0
- package/build/hooks/useSheetViewport.cjs +2 -0
- package/build/hooks/useSheetViewport.cjs.map +1 -0
- package/build/hooks/useSheetViewport.d.cts +6 -0
- package/build/hooks/useSheetViewport.d.ts +6 -0
- package/build/hooks/useSheetViewport.js +29 -0
- package/build/hooks/useSheetViewport.js.map +1 -0
- package/build/hooks/useStickToBottom.cjs +2 -0
- package/build/hooks/useStickToBottom.cjs.map +1 -0
- package/build/hooks/useStickToBottom.d.cts +12 -0
- package/build/hooks/useStickToBottom.d.ts +12 -0
- package/build/hooks/useStickToBottom.js +39 -0
- package/build/hooks/useStickToBottom.js.map +1 -0
- package/build/hooks/useUiTheme.cjs +2 -0
- package/build/hooks/useUiTheme.cjs.map +1 -0
- package/build/hooks/useUiTheme.d.cts +10 -0
- package/build/hooks/useUiTheme.d.ts +10 -0
- package/build/hooks/useUiTheme.js +42 -0
- package/build/hooks/useUiTheme.js.map +1 -0
- package/build/hooks/useUiTokens.cjs +2 -0
- package/build/hooks/useUiTokens.cjs.map +1 -0
- package/build/hooks/useUiTokens.d.cts +11 -0
- package/build/hooks/useUiTokens.d.ts +11 -0
- package/build/hooks/useUiTokens.js +36 -0
- package/build/hooks/useUiTokens.js.map +1 -0
- package/build/hooks/useVirtualList.cjs +2 -0
- package/build/hooks/useVirtualList.cjs.map +1 -0
- package/build/hooks/useVirtualList.d.cts +13 -0
- package/build/hooks/useVirtualList.d.ts +13 -0
- package/build/hooks/useVirtualList.js +41 -0
- package/build/hooks/useVirtualList.js.map +1 -0
- package/build/index.cjs +2 -0
- package/build/index.cjs.map +1 -0
- package/build/index.d.cts +98 -0
- package/build/index.d.ts +98 -0
- package/build/index.js +209 -0
- package/build/index.js.map +1 -0
- package/build/scss/_index.scss +7 -0
- package/build/scss/_mixins.scss +861 -0
- package/build/scss/_variables.scss +245 -0
- package/build/styles/base.d.cts +0 -0
- package/build/styles/base.d.ts +0 -0
- package/build/styles.css +135 -0
- package/build/theme/UiProvider.cjs +2 -0
- package/build/theme/UiProvider.cjs.map +1 -0
- package/build/theme/UiProvider.d.cts +23 -0
- package/build/theme/UiProvider.d.ts +23 -0
- package/build/theme/UiProvider.js +12 -0
- package/build/theme/UiProvider.js.map +1 -0
- package/build/theme/UiThemeScript.cjs +2 -0
- package/build/theme/UiThemeScript.cjs.map +1 -0
- package/build/theme/UiThemeScript.d.cts +22 -0
- package/build/theme/UiThemeScript.d.ts +22 -0
- package/build/theme/UiThemeScript.js +8 -0
- package/build/theme/UiThemeScript.js.map +1 -0
- package/build/theme/context.cjs +2 -0
- package/build/theme/context.cjs.map +1 -0
- package/build/theme/context.d.cts +5 -0
- package/build/theme/context.d.ts +5 -0
- package/build/theme/context.js +8 -0
- package/build/theme/context.js.map +1 -0
- package/build/types/calendar/Calendar/EventBlock.d.cts +29 -0
- package/build/types/calendar/Calendar/EventBlock.d.ts +29 -0
- package/build/types/calendar/Calendar/MonthGrid.d.cts +28 -0
- package/build/types/calendar/Calendar/MonthGrid.d.ts +28 -0
- package/build/types/calendar/Calendar/TimeGrid.d.cts +37 -0
- package/build/types/calendar/Calendar/TimeGrid.d.ts +37 -0
- package/build/types/calendar/Calendar/index.d.cts +72 -0
- package/build/types/calendar/Calendar/index.d.ts +72 -0
- package/build/types/calendar/core/layout.d.cts +43 -0
- package/build/types/calendar/core/layout.d.ts +43 -0
- package/build/types/calendar/core/moves.d.cts +37 -0
- package/build/types/calendar/core/moves.d.ts +37 -0
- package/build/types/calendar/core/time.d.cts +19 -0
- package/build/types/calendar/core/time.d.ts +19 -0
- package/build/types/calendar/core/types.d.cts +75 -0
- package/build/types/calendar/core/types.d.ts +75 -0
- package/build/types/calendar/core/useCalendarDrag.d.cts +32 -0
- package/build/types/calendar/core/useCalendarDrag.d.ts +32 -0
- package/build/types/calendar/index.d.cts +13 -0
- package/build/types/calendar/index.d.ts +13 -0
- package/build/types/charts/AreaChart/index.d.cts +14 -0
- package/build/types/charts/AreaChart/index.d.ts +14 -0
- package/build/types/charts/BarChart/index.d.cts +16 -0
- package/build/types/charts/BarChart/index.d.ts +16 -0
- package/build/types/charts/BoxPlot/index.d.cts +43 -0
- package/build/types/charts/BoxPlot/index.d.ts +43 -0
- package/build/types/charts/ComposedChart/index.d.cts +16 -0
- package/build/types/charts/ComposedChart/index.d.ts +16 -0
- package/build/types/charts/Heatmap/index.d.cts +30 -0
- package/build/types/charts/Heatmap/index.d.ts +30 -0
- package/build/types/charts/Histogram/index.d.cts +29 -0
- package/build/types/charts/Histogram/index.d.ts +29 -0
- package/build/types/charts/LineChart/index.d.cts +14 -0
- package/build/types/charts/LineChart/index.d.ts +14 -0
- package/build/types/charts/PieChart/index.d.cts +36 -0
- package/build/types/charts/PieChart/index.d.ts +36 -0
- package/build/types/charts/RadarChart/index.d.cts +40 -0
- package/build/types/charts/RadarChart/index.d.ts +40 -0
- package/build/types/charts/ScatterPlot/index.d.cts +41 -0
- package/build/types/charts/ScatterPlot/index.d.ts +41 -0
- package/build/types/charts/core/CartesianChart.d.cts +43 -0
- package/build/types/charts/core/CartesianChart.d.ts +43 -0
- package/build/types/charts/core/ChartFrame.d.cts +55 -0
- package/build/types/charts/core/ChartFrame.d.ts +55 -0
- package/build/types/charts/core/axes.d.cts +37 -0
- package/build/types/charts/core/axes.d.ts +37 -0
- package/build/types/charts/core/cartesian.d.cts +80 -0
- package/build/types/charts/core/cartesian.d.ts +80 -0
- package/build/types/charts/core/format.d.cts +19 -0
- package/build/types/charts/core/format.d.ts +19 -0
- package/build/types/charts/core/margins.d.cts +9 -0
- package/build/types/charts/core/margins.d.ts +9 -0
- package/build/types/charts/core/palette.d.cts +11 -0
- package/build/types/charts/core/palette.d.ts +11 -0
- package/build/types/charts/core/path.d.cts +24 -0
- package/build/types/charts/core/path.d.ts +24 -0
- package/build/types/charts/core/scale.d.cts +40 -0
- package/build/types/charts/core/scale.d.ts +40 -0
- package/build/types/charts/core/series.d.cts +11 -0
- package/build/types/charts/core/series.d.ts +11 -0
- package/build/types/charts/core/spatial.d.cts +12 -0
- package/build/types/charts/core/spatial.d.ts +12 -0
- package/build/types/charts/core/stats.d.cts +34 -0
- package/build/types/charts/core/stats.d.ts +34 -0
- package/build/types/charts/core/types.d.cts +31 -0
- package/build/types/charts/core/types.d.ts +31 -0
- package/build/types/charts/core/useChartWidth.d.cts +7 -0
- package/build/types/charts/core/useChartWidth.d.ts +7 -0
- package/build/types/charts/index.d.cts +21 -0
- package/build/types/charts/index.d.ts +21 -0
- package/build/types/chat/ActionList/index.d.cts +46 -0
- package/build/types/chat/ActionList/index.d.ts +46 -0
- package/build/types/chat/AppBar/index.d.cts +21 -0
- package/build/types/chat/AppBar/index.d.ts +21 -0
- package/build/types/chat/ChatMessage/index.d.cts +24 -0
- package/build/types/chat/ChatMessage/index.d.ts +24 -0
- package/build/types/chat/ChatThread/index.d.cts +24 -0
- package/build/types/chat/ChatThread/index.d.ts +24 -0
- package/build/types/chat/Citation/index.d.cts +15 -0
- package/build/types/chat/Citation/index.d.ts +15 -0
- package/build/types/chat/CodeBlock/format.d.cts +7 -0
- package/build/types/chat/CodeBlock/format.d.ts +7 -0
- package/build/types/chat/CodeBlock/grammars.d.cts +44 -0
- package/build/types/chat/CodeBlock/grammars.d.ts +44 -0
- package/build/types/chat/CodeBlock/highlight.d.cts +22 -0
- package/build/types/chat/CodeBlock/highlight.d.ts +22 -0
- package/build/types/chat/CodeBlock/index.d.cts +33 -0
- package/build/types/chat/CodeBlock/index.d.ts +33 -0
- package/build/types/chat/DescriptionList/index.d.cts +16 -0
- package/build/types/chat/DescriptionList/index.d.ts +16 -0
- package/build/types/chat/Legend/index.d.cts +21 -0
- package/build/types/chat/Legend/index.d.ts +21 -0
- package/build/types/chat/MessageActions/index.d.cts +21 -0
- package/build/types/chat/MessageActions/index.d.ts +21 -0
- package/build/types/chat/PromptInput/index.d.cts +47 -0
- package/build/types/chat/PromptInput/index.d.ts +47 -0
- package/build/types/chat/PromptSuggestions/index.d.cts +25 -0
- package/build/types/chat/PromptSuggestions/index.d.ts +25 -0
- package/build/types/chat/Prose/index.d.cts +15 -0
- package/build/types/chat/Prose/index.d.ts +15 -0
- package/build/types/chat/ReasoningBlock/index.d.cts +24 -0
- package/build/types/chat/ReasoningBlock/index.d.ts +24 -0
- package/build/types/chat/ReasoningText/index.d.cts +14 -0
- package/build/types/chat/ReasoningText/index.d.ts +14 -0
- package/build/types/chat/SegmentBar/index.d.cts +46 -0
- package/build/types/chat/SegmentBar/index.d.ts +46 -0
- package/build/types/chat/SourceList/index.d.cts +25 -0
- package/build/types/chat/SourceList/index.d.ts +25 -0
- package/build/types/chat/TerminalOutput/index.d.cts +25 -0
- package/build/types/chat/TerminalOutput/index.d.ts +25 -0
- package/build/types/chat/ToolCall/index.d.cts +41 -0
- package/build/types/chat/ToolCall/index.d.ts +41 -0
- package/build/types/chat/index.d.cts +26 -0
- package/build/types/chat/index.d.ts +26 -0
- package/build/types/combobox.type.d.cts +65 -0
- package/build/types/combobox.type.d.ts +65 -0
- package/build/types/common-element-props.type.d.cts +8 -0
- package/build/types/common-element-props.type.d.ts +8 -0
- package/build/types/helpers/class-name.helper.d.cts +3 -0
- package/build/types/helpers/class-name.helper.d.ts +3 -0
- package/build/types/helpers/component.helper.d.cts +13 -0
- package/build/types/helpers/component.helper.d.ts +13 -0
- package/build/types/helpers/label.helper.d.cts +12 -0
- package/build/types/helpers/label.helper.d.ts +12 -0
- package/build/types/hook.type.d.cts +36 -0
- package/build/types/hook.type.d.ts +36 -0
- package/build/types/link.type.d.cts +14 -0
- package/build/types/link.type.d.ts +14 -0
- package/build/types/positioning.type.d.cts +38 -0
- package/build/types/positioning.type.d.ts +38 -0
- package/build/types/theme.type.d.cts +197 -0
- package/build/types/theme.type.d.ts +197 -0
- package/build/types/types/common-element-props.type.d.cts +8 -0
- package/build/types/types/common-element-props.type.d.ts +8 -0
- package/build/types/types/link.type.d.cts +14 -0
- package/build/types/types/link.type.d.ts +14 -0
- package/build/types/types/theme.type.d.cts +197 -0
- package/build/types/types/theme.type.d.ts +197 -0
- package/package.json +905 -4
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar.js","sources":["../src/helpers/class-name.helper.ts","../src/helpers/component.helper.ts","../src/helpers/label.helper.ts","../src/calendar/core/time.ts","../src/calendar/core/layout.ts","../src/calendar/core/moves.ts","../src/calendar/core/useCalendarDrag.ts","../src/calendar/Calendar/EventBlock.tsx","../src/calendar/Calendar/MonthGrid.tsx","../src/calendar/Calendar/TimeGrid.tsx","../src/calendar/Calendar/index.tsx"],"sourcesContent":["import { ClassValue } from '@/types/common-element-props.type';\n\n/** Sınıf adı birleştirici. */\nexport const cx = (...values: ClassValue[]): string => {\n let result = '';\n\n for (const value of values) {\n if (!value) continue;\n result = result === '' ? value : `${result} ${value}`;\n }\n\n return result;\n};\n","/**\n * DevTools adı — modül düzeyinde YAN ETKİ bırakmadan.\n *\n * ⚠ `X.displayName = 'X'` KULLANILMAZ: modül düzeyindeki özellik ataması\n * bundler için yan etkidir ve hedefinin tüm bağımlılık zincirini ayakta tutar.\n * Ölçüldü: yalnızca `Badge` import eden uygulama 20,7 kB indiriyordu (paketin\n * tamamı 21,8 kB). Atama çağrıya dönüşünce `#__PURE__` işaretlenebiliyor →\n * `Badge` 2,71 kB. Nöbetçi `.size-limit.json`.\n *\n * @example\n * export default memo(named(Button, 'Button')) as typeof Button;\n */\nexport const named = <TComponent extends object>(\n component: TComponent,\n displayName: string,\n): TComponent => Object.assign(component, { displayName });\n","/** Metin çözümlemesi: prop → sağlayıcı config'i → geliştirme uyarısı. */\n\nimport type { Formatter } from '@/types/theme.type';\n\n/* Uyari ANAHTAR BASINA bir kez verilir. */\nconst warned = new Set<string>();\n\n/** Uyarı durumu testler arasında sızmamalı; her test kendi durumundan başlar. */\nexport const resetLabelWarnings = (): void => warned.clear();\n\n/**\n * Verilen metni çözer.\n * @param key Uyarıda gösterilecek yol (`Modal.closeLabel`).\n * @param values Öncelik sırasına göre adaylar: prop önce, config sonra.\n */\nexport const resolveLabel = (key: string, ...values: (string | undefined)[]): string => {\n for (const value of values) if (value !== undefined) return value;\n\n if (process.env.NODE_ENV !== 'production' && !warned.has(key)) {\n warned.add(key);\n console.error(\n `[@handijitcom/ui] Eksik metin: ${key}. Prop olarak geçin ya da ` +\n '<UiProvider labels={…}> içinde bir kez tanımlayın. ' +\n 'Metinsiz bırakılan öğe ekran okuyucuda adsız kalır.',\n );\n }\n\n return '';\n};\n\n/** Biçimlendirici çözümü — değere bağlı metinler için. */\nexport const resolveFormatter = <TArgs extends unknown[]>(\n key: string,\n formatter: Formatter<TArgs> | undefined,\n ...args: TArgs\n): string => {\n if (formatter) return formatter(...args);\n\n return resolveLabel(key);\n};\n","/**\n * Minutes of a day and the wall-clock text around them — string work only. Day arithmetic (adding\n * a day, the weekday of a date) is NOT here: it belongs to `@handijit/tr` and the caller passes\n * the days already computed.\n */\n\nexport const MINUTES_PER_DAY = 1440;\n\n/** \"09:30\" → 570. */\nexport const toMinutes = (time: string): number => {\n const [hours, minutes] = time.split(':') as [string, string?];\n\n return Number(hours) * 60 + Number(minutes ?? 0);\n};\n\n/** 570 → \"09:30\". */\nexport const toTime = (minutes: number): string =>\n `${String(Math.floor(minutes / 60)).padStart(2, '0')}:${String(minutes % 60).padStart(2, '0')}`;\n\n/** \"2026-11-12T09:30\" → \"2026-11-12\". */\nexport const dateOf = (wall: string): string => wall.slice(0, 10);\n\n/** \"2026-11-12T09:30\" → 570. */\nexport const minutesOf = (wall: string): number => toMinutes(wall.slice(11, 16));\n\n/** (\"2026-11-12\", 570) → \"2026-11-12T09:30\". */\nexport const toWall = (date: string, minutes: number): string => `${date}T${toTime(minutes)}`;\n\n/** The time range an event or a segment covers, as it is read: \"09:30–11:00\". */\nexport const timeRange = (start: number, end: number): string => `${toTime(start)}–${toTime(end)}`;\n\nexport const clamp = (value: number, low: number, high: number): number =>\n Math.min(Math.max(value, low), high);\n","import { dateOf, MINUTES_PER_DAY, minutesOf, toMinutes } from './time';\nimport type { CalendarBand, CalendarDay, CalendarEvent, CalendarResource } from './types';\n\n/** One column of the time grid: a day, or a day of one resource. */\nexport type CalendarColumn = {\n index: number;\n day: CalendarDay;\n resource?: CalendarResource;\n /** What a screen reader hears for the column: \"Salı 12 Kasım, Derslik 2\". */\n label: string;\n};\n\n/** An event as drawn in one column (time grid) or one day cell (month). */\nexport type PlacedEvent = {\n /** `<id>@<column>`: a multi-day event is drawn once per day it covers. */\n key: string;\n event: CalendarEvent;\n column: number;\n /** The drawn stretch, clipped to the visible hours (time grid). */\n startMin: number;\n endMin: number;\n /** Side-by-side position among overlapping events: lane `lane` of `lanes`. */\n lane: number;\n lanes: number;\n /** Starts and ends on the same day inside the drawn hours, not locked: it can be moved. */\n isMovable: boolean;\n};\n\nconst columnKey = (date: string, resourceId?: string) => `${date}|${resourceId ?? ''}`;\n\n/** The columns, day by day; with resources, every resource of a day under that day. */\nexport const buildColumns = (\n days: readonly CalendarDay[],\n resources: readonly CalendarResource[] | undefined,\n): CalendarColumn[] =>\n resources && resources.length > 0\n ? days.flatMap((day, dayIndex) =>\n resources.map((resource, resourceIndex) => ({\n index: dayIndex * resources.length + resourceIndex,\n day,\n resource,\n label: `${day.label}, ${resource.label}`,\n })),\n )\n : days.map((day, index) => ({ index, day, label: day.label }));\n\n/** Does the event cover the day? Days compare as text: `YYYY-MM-DD` sorts in time. */\nconst covers = (event: CalendarEvent, date: string): boolean => {\n const startDate = dateOf(event.start);\n const endDate = dateOf(event.end);\n\n return startDate <= date && (date < endDate || (date === endDate && minutesOf(event.end) > 0));\n};\n\nconst isSameDay = (event: CalendarEvent) => dateOf(event.start) === dateOf(event.end);\n\n/**\n * Lanes: overlapping events share a column side by side. A cluster is a run of events that\n * overlap one another directly or through a neighbour; every member is as wide as the cluster has\n * lanes, and each takes the first lane that is free at its start.\n */\nconst assignLanes = (items: PlacedEvent[]): void => {\n items.sort((a, b) => a.startMin - b.startMin || b.endMin - a.endMin);\n\n let cluster: PlacedEvent[] = [];\n let laneEnds: number[] = [];\n let clusterEnd = -1;\n\n const close = () => {\n for (const item of cluster) item.lanes = laneEnds.length;\n cluster = [];\n laneEnds = [];\n };\n\n for (const item of items) {\n if (item.startMin >= clusterEnd) close();\n\n const free = laneEnds.findIndex(end => end <= item.startMin);\n item.lane = free === -1 ? laneEnds.length : free;\n /* A zero-length event still holds its lane for a minute: two at 09:00 sit side by side. */\n const laneEnd = Math.max(item.endMin, item.startMin + 1);\n laneEnds[item.lane] = laneEnd;\n clusterEnd = Math.max(clusterEnd, laneEnd);\n cluster.push(item);\n }\n\n close();\n};\n\n/**\n * Places the events in the time grid, column by column, clipped to `[rangeStart, rangeEnd)`.\n * With resources an event goes to its resource's column; one without a known resource is not\n * drawn (it belongs to the caller's pool of unassigned work).\n */\nexport const placeTimeEvents = (\n events: readonly CalendarEvent[],\n columns: readonly CalendarColumn[],\n rangeStart: number,\n rangeEnd: number,\n isEditable: boolean,\n): PlacedEvent[][] => {\n const byKey = new Map(\n columns.map(column => [columnKey(column.day.date, column.resource?.id), column]),\n );\n const hasResources = columns.some(column => column.resource);\n const placed = columns.map((): PlacedEvent[] => []);\n\n const place = (event: CalendarEvent, column: CalendarColumn) => {\n const date = column.day.date;\n const start = dateOf(event.start) === date ? minutesOf(event.start) : 0;\n const end = dateOf(event.end) === date ? minutesOf(event.end) : MINUTES_PER_DAY;\n if (end <= rangeStart || start >= rangeEnd) return;\n\n placed[column.index].push({\n key: `${event.id}@${column.index}`,\n event,\n column: column.index,\n startMin: Math.max(start, rangeStart),\n endMin: Math.min(end, rangeEnd),\n lane: 0,\n lanes: 1,\n isMovable:\n isEditable && !event.isLocked && isSameDay(event) && start >= rangeStart && end <= rangeEnd,\n });\n };\n\n for (const event of events) {\n const resourceId = hasResources ? event.resourceId : undefined;\n if (hasResources && resourceId === undefined) continue;\n\n if (isSameDay(event)) {\n const column = byKey.get(columnKey(dateOf(event.start), resourceId));\n if (column) place(event, column);\n continue;\n }\n\n for (const column of columns)\n if (column.resource?.id === resourceId && covers(event, column.day.date))\n place(event, column);\n }\n\n for (const column of placed) assignLanes(column);\n\n return placed;\n};\n\n/** The events of every day cell of the month, in time order. */\nexport const placeMonthEvents = (\n events: readonly CalendarEvent[],\n days: readonly CalendarDay[],\n isEditable: boolean,\n): PlacedEvent[][] => {\n const byDate = new Map(days.map((day, index) => [day.date, index]));\n const placed = days.map((): PlacedEvent[] => []);\n\n const place = (event: CalendarEvent, index: number) =>\n placed[index].push({\n key: `${event.id}@${index}`,\n event,\n column: index,\n startMin: minutesOf(event.start),\n endMin: minutesOf(event.end),\n lane: 0,\n lanes: 1,\n isMovable: isEditable && !event.isLocked && isSameDay(event),\n });\n\n for (const event of events) {\n if (isSameDay(event)) {\n const index = byDate.get(dateOf(event.start));\n if (index !== undefined) place(event, index);\n continue;\n }\n\n days.forEach((day, index) => {\n if (covers(event, day.date)) place(event, index);\n });\n }\n\n for (const cell of placed)\n cell.sort((a, b) =>\n a.event.start < b.event.start ? -1 : a.event.start > b.event.start ? 1 : 0,\n );\n\n return placed;\n};\n\n/** A band as drawn: its stretch in minutes, clipped to the drawn hours. */\nexport type PlacedBand = {\n key: string;\n label: string;\n startMin: number;\n endMin: number;\n};\n\n/** The bands inside the drawn hours, clipped to them; one that falls outside them is left out. */\nexport const placeBands = (\n bands: readonly CalendarBand[] | undefined,\n rangeStart: number,\n rangeEnd: number,\n): PlacedBand[] =>\n (bands ?? []).flatMap((band, index) => {\n const startMin = Math.max(toMinutes(band.start), rangeStart);\n const endMin = Math.min(toMinutes(band.end), rangeEnd);\n\n return endMin > startMin ? [{ key: `${index}`, label: band.label, startMin, endMin }] : [];\n });\n","import type { CalendarColumn, PlacedEvent } from './layout';\nimport { clamp, toWall } from './time';\nimport type { CalendarDay, CalendarEventChange } from './types';\n\nexport type CalendarView = 'time' | 'month';\n\n/** Where a moved or resized event lands: a column (or day cell) and its minutes. */\nexport type CalendarTarget = { column: number; startMin: number; endMin: number };\n\nexport type MoveBounds = {\n view: CalendarView;\n columnCount: number;\n rangeStart: number;\n rangeEnd: number;\n slotMinutes: number;\n};\n\n/**\n * The target of moving (`resize: false`) or stretching an event by `deltaMinutes` into `column`.\n * The time grid keeps the event inside the drawn hours and at least one slot long; the month\n * keeps the time of day and refuses a day off the drawn grid (`undefined`).\n */\nexport const targetOf = (\n item: PlacedEvent,\n isResize: boolean,\n deltaMinutes: number,\n column: number,\n bounds: MoveBounds,\n): CalendarTarget | undefined => {\n if (bounds.view === 'month')\n return column < 0 || column >= bounds.columnCount\n ? undefined\n : { column, startMin: item.startMin, endMin: item.endMin };\n\n if (isResize) {\n const shortest = Math.min(item.startMin + bounds.slotMinutes, bounds.rangeEnd);\n return {\n column: item.column,\n startMin: item.startMin,\n endMin: clamp(item.endMin + deltaMinutes, shortest, bounds.rangeEnd),\n };\n }\n\n const duration = item.endMin - item.startMin;\n const startMin = clamp(\n item.startMin + deltaMinutes,\n bounds.rangeStart,\n bounds.rangeEnd - duration,\n );\n\n return {\n column: clamp(column, 0, bounds.columnCount - 1),\n startMin,\n endMin: startMin + duration,\n };\n};\n\n/** The change a target means for the caller, or `undefined` when nothing moved. */\nexport const changeOf = (\n item: PlacedEvent,\n target: CalendarTarget,\n view: CalendarView,\n columns: readonly CalendarColumn[],\n days: readonly CalendarDay[],\n): CalendarEventChange | undefined => {\n const isSame =\n target.column === item.column &&\n target.startMin === item.startMin &&\n target.endMin === item.endMin;\n if (isSame) return undefined;\n\n const column = view === 'time' ? columns[target.column] : undefined;\n const date = column ? column.day.date : days[target.column].date;\n\n return {\n id: item.event.id,\n start: toWall(date, target.startMin),\n end: toWall(date, target.endMin),\n resourceId: column?.resource?.id ?? item.event.resourceId,\n };\n};\n\nexport type ArrowKey = 'ArrowUp' | 'ArrowDown' | 'ArrowLeft' | 'ArrowRight';\n\nexport const isArrowKey = (key: string): key is ArrowKey =>\n key === 'ArrowUp' || key === 'ArrowDown' || key === 'ArrowLeft' || key === 'ArrowRight';\n\n/**\n * The event an arrow key moves the focus to: ↑ ↓ the previous and next in the same column (or\n * day), ← → the nearest in time in the closest column that has one.\n */\nexport const neighbourOf = (\n lists: readonly (readonly PlacedEvent[])[],\n from: PlacedEvent,\n key: ArrowKey,\n): PlacedEvent | undefined => {\n if (key === 'ArrowUp' || key === 'ArrowDown') {\n const list = lists[from.column];\n const index = list.findIndex(item => item.key === from.key);\n\n return list[index + (key === 'ArrowDown' ? 1 : -1)];\n }\n\n const step = key === 'ArrowRight' ? 1 : -1;\n for (let column = from.column + step; column >= 0 && column < lists.length; column += step) {\n const list = lists[column];\n if (list.length === 0) continue;\n\n return list.reduce((best, item) =>\n Math.abs(item.startMin - from.startMin) < Math.abs(best.startMin - from.startMin)\n ? item\n : best,\n );\n }\n\n return undefined;\n};\n\n/**\n * The keyboard move of a focused event — ⌘/Ctrl with an arrow: ↑ ↓ one slot earlier or later\n * (month: a week), ← → the previous or next column (month: a day). ⌘/Ctrl ⇧ ↑ ↓ shortens or\n * lengthens it by one slot (time grid only).\n */\nexport const keyboardTarget = (\n item: PlacedEvent,\n key: ArrowKey,\n isResize: boolean,\n bounds: MoveBounds,\n): CalendarTarget | undefined => {\n const isVertical = key === 'ArrowUp' || key === 'ArrowDown';\n const direction = key === 'ArrowDown' || key === 'ArrowRight' ? 1 : -1;\n\n if (bounds.view === 'month') {\n if (isResize) return undefined;\n return targetOf(item, false, 0, item.column + direction * (isVertical ? 7 : 1), bounds);\n }\n\n if (isResize && !isVertical) return undefined;\n\n return isVertical\n ? targetOf(item, isResize, direction * bounds.slotMinutes, item.column, bounds)\n : targetOf(item, false, 0, item.column + direction, bounds);\n};\n","'use client';\n\nimport { type RefObject, useCallback, useEffect, useRef, useState } from 'react';\n\nimport type { PlacedEvent } from './layout';\nimport { type CalendarTarget, type MoveBounds, targetOf } from './moves';\n\n/** A press that travels less than this is a click, not a drag (px). */\nconst DRAG_THRESHOLD = 4;\n\nconst WEEK = 7;\n\ntype Origin = { item: PlacedEvent; isResize: boolean; x: number; y: number; isStarted: boolean };\n\nexport type DragPreview = { key: string; isResize: boolean; target: CalendarTarget };\n\n/**\n * POINTER DRAG of an event: move it (the body) or stretch it (the bottom handle), snapped to the\n * slot, with a preview while the pointer travels and `Escape` to give up.\n *\n * The listeners go on `window` for the length of one drag, not on the event's element: the\n * preview is drawn in the target column while the source stays where it is, and a pointer\n * released outside the calendar still ends the drag. The click a drag ends with is swallowed\n * (`isClickSwallowed`) so that dropping an event does not also open it.\n */\nconst useCalendarDrag = ({\n bodyRef,\n bounds,\n onDrop,\n}: {\n /** The element whose box is the grid of columns (time) or of day cells (month). */\n bodyRef: RefObject<HTMLElement | null>;\n bounds: MoveBounds;\n onDrop: (item: PlacedEvent, target: CalendarTarget) => void;\n}) => {\n const [preview, setPreview] = useState<DragPreview | null>(null);\n const cleanupRef = useRef<(() => void) | null>(null);\n const isSwallowingRef = useRef(false);\n const latest = useRef({ bounds, onDrop });\n latest.current = { bounds, onDrop };\n\n const targetAt = (event: PointerEvent, origin: Origin): CalendarTarget | undefined => {\n const box = bodyRef.current?.getBoundingClientRect();\n const { bounds: current } = latest.current;\n if (!box || box.width === 0 || box.height === 0) return undefined;\n\n if (current.view === 'time') {\n const minutesPerPixel = (current.rangeEnd - current.rangeStart) / box.height;\n const minutes = (event.clientY - origin.y) * minutesPerPixel;\n const delta = Math.round(minutes / current.slotMinutes) * current.slotMinutes;\n const column = Math.floor(((event.clientX - box.left) / box.width) * current.columnCount);\n\n return targetOf(origin.item, origin.isResize, delta, column, current);\n }\n\n const rows = Math.ceil(current.columnCount / WEEK);\n const column = Math.floor(((event.clientX - box.left) / box.width) * WEEK);\n const row = Math.floor(((event.clientY - box.top) / box.height) * rows);\n if (column < 0 || column >= WEEK || row < 0 || row >= rows) return undefined;\n\n return targetOf(origin.item, false, 0, row * WEEK + column, current);\n };\n\n const begin = useCallback(\n (\n item: PlacedEvent,\n event: { button: number; clientX: number; clientY: number },\n isResize: boolean,\n ) => {\n isSwallowingRef.current = false;\n if (event.button !== 0 || !item.isMovable) return;\n\n cleanupRef.current?.();\n const origin: Origin = {\n item,\n isResize,\n x: event.clientX,\n y: event.clientY,\n isStarted: false,\n };\n\n const stop = () => {\n window.removeEventListener('pointermove', move);\n window.removeEventListener('pointerup', end);\n window.removeEventListener('pointercancel', cancel);\n window.removeEventListener('keydown', escape, true);\n cleanupRef.current = null;\n setPreview(null);\n };\n\n /* The click that follows the release in the same task is the drag's, not an \"open\". */\n const swallowNextClick = () => {\n isSwallowingRef.current = true;\n window.setTimeout(() => {\n isSwallowingRef.current = false;\n }, 0);\n };\n\n const move = (moveEvent: PointerEvent) => {\n const travelled = Math.hypot(moveEvent.clientX - origin.x, moveEvent.clientY - origin.y);\n if (!origin.isStarted && travelled < DRAG_THRESHOLD) return;\n origin.isStarted = true;\n\n const target = targetAt(moveEvent, origin);\n setPreview(target ? { key: origin.item.key, isResize: origin.isResize, target } : null);\n };\n\n const end = (upEvent: PointerEvent) => {\n stop();\n if (!origin.isStarted) return;\n\n swallowNextClick();\n const target = targetAt(upEvent, origin);\n if (target) latest.current.onDrop(origin.item, target);\n };\n\n const cancel = () => stop();\n\n /* Captured: the `Escape` that gives up a drag must not also close the dialog around it. */\n const escape = (keyEvent: KeyboardEvent) => {\n if (keyEvent.key !== 'Escape' || !origin.isStarted) return;\n keyEvent.preventDefault();\n keyEvent.stopPropagation();\n swallowNextClick();\n stop();\n };\n\n window.addEventListener('pointermove', move);\n window.addEventListener('pointerup', end);\n window.addEventListener('pointercancel', cancel);\n window.addEventListener('keydown', escape, true);\n cleanupRef.current = stop;\n },\n // `targetAt` reads the box and the bounds through refs at the moment of the event.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [],\n );\n\n /* A calendar unmounted mid-drag leaves no listener behind. */\n useEffect(() => () => cleanupRef.current?.(), []);\n\n const isClickSwallowed = useCallback(() => isSwallowingRef.current, []);\n\n return { preview, begin, isClickSwallowed };\n};\n\nexport default useCalendarDrag;\n","'use client';\n\nimport {\n type CSSProperties,\n type KeyboardEvent,\n memo,\n type MouseEvent,\n type PointerEvent,\n type ReactNode,\n} from 'react';\n\nimport { cx } from '../../helpers/class-name.helper';\nimport type { PlacedEvent } from '../core/layout';\nimport { minutesOf, timeRange, toTime } from '../core/time';\nimport type { CalendarEvent } from '../core/types';\n\nimport styles from './index.module.scss';\n\nexport type EventHandlers = {\n onPointerDown: (item: PlacedEvent, event: PointerEvent, isResize: boolean) => void;\n onClick: (item: PlacedEvent, event: MouseEvent) => void;\n onKeyDown: (item: PlacedEvent, event: KeyboardEvent) => void;\n onFocus: (item: PlacedEvent) => void;\n};\n\ntype Props = {\n item: PlacedEvent;\n view: 'time' | 'month';\n /** The one event of the calendar in the tab order (roving `tabindex`). */\n isActive: boolean;\n /** Being dragged: the source keeps its place, marked, while the preview travels. */\n isDragSource: boolean;\n /** Can be resized with the pointer (time grid, movable, a change handler given). */\n isResizable: boolean;\n /** Time grid: the drawn hours, for the position in the column. */\n rangeStart: number;\n rangeLength: number;\n /** The day (and resource) of the column, read after the event. */\n columnLabel: string;\n cancelledLabel: string;\n renderEvent?: (event: CalendarEvent) => ReactNode;\n handlers: EventHandlers;\n};\n\n/** Percentages of the column for the time grid; the month cell lists its events instead. */\nconst placement = (item: PlacedEvent, rangeStart: number, rangeLength: number): CSSProperties =>\n ({\n '--ui-calendar-top': `${((item.startMin - rangeStart) / rangeLength) * 100}%`,\n '--ui-calendar-height': `${((item.endMin - item.startMin) / rangeLength) * 100}%`,\n '--ui-calendar-lane': item.lane,\n '--ui-calendar-lanes': item.lanes,\n }) as CSSProperties;\n\n/**\n * One event: a button (Enter opens it), its time and its body, the day of its column read after\n * it. A struck-through title is not the only sign of a cancelled event: the \"cancelled\" text is\n * read first.\n */\nconst EventBlock = ({\n item,\n view,\n isActive,\n isDragSource,\n isResizable,\n rangeStart,\n rangeLength,\n columnLabel,\n cancelledLabel,\n renderEvent,\n handlers,\n}: Props) => {\n const { event } = item;\n const time =\n view === 'time'\n ? timeRange(minutesOf(event.start), minutesOf(event.end))\n : toTime(minutesOf(event.start));\n\n return (\n <button\n type=\"button\"\n className={cx(\n styles.event,\n styles[`event--${view}`],\n styles[`event--${event.tone ?? 'primary'}`],\n event.isCancelled && styles['event--cancelled'],\n item.isMovable && styles['event--movable'],\n isDragSource && styles['event--dragging'],\n )}\n style={view === 'time' ? placement(item, rangeStart, rangeLength) : undefined}\n tabIndex={isActive ? 0 : -1}\n data-key={item.key}\n onPointerDown={pointerEvent => handlers.onPointerDown(item, pointerEvent, false)}\n onClick={mouseEvent => handlers.onClick(item, mouseEvent)}\n onKeyDown={keyEvent => handlers.onKeyDown(item, keyEvent)}\n onFocus={() => handlers.onFocus(item)}\n >\n {event.isCancelled && <span className={styles.srOnly}>{`${cancelledLabel}: `}</span>}\n <span className={styles.event__time}>{time}</span>\n <span className={styles.event__body}>{renderEvent ? renderEvent(event) : event.title}</span>\n <span className={styles.srOnly}>{`, ${columnLabel}`}</span>\n {isResizable && (\n <span\n className={styles.event__handle}\n aria-hidden\n onPointerDown={pointerEvent => {\n pointerEvent.stopPropagation();\n handlers.onPointerDown(item, pointerEvent, true);\n }}\n />\n )}\n </button>\n );\n};\n\nexport default /*#__PURE__*/ memo(EventBlock);\n","'use client';\n\nimport { type CSSProperties, type ReactNode, type RefObject } from 'react';\n\nimport { cx } from '../../helpers/class-name.helper';\nimport type { PlacedEvent } from '../core/layout';\nimport type { CalendarDay, CalendarEvent } from '../core/types';\nimport type { DragPreview } from '../core/useCalendarDrag';\n\nimport EventBlock, { type EventHandlers } from './EventBlock';\nimport styles from './index.module.scss';\n\ntype Props = {\n days: readonly CalendarDay[];\n /** The events of each day, already cut to the ones the cell shows. */\n shown: readonly (readonly PlacedEvent[])[];\n /** How many more events each day has than it shows. */\n hiddenCounts: readonly number[];\n weekdays?: readonly string[];\n selectedDate?: string;\n bodyRef: RefObject<HTMLDivElement | null>;\n activeKey: string | undefined;\n preview: DragPreview | null;\n cancelledLabel: string;\n formatMore: (count: number) => string;\n renderEvent?: (event: CalendarEvent) => ReactNode;\n handlers: EventHandlers;\n onDaySelect?: (date: string) => void;\n};\n\nconst WEEK = 7;\n\n/**\n * The month — a cell per day, seven to a row, each listing its first events in time order and a\n * \"+N\" for the rest. The day number opens the day (`onDaySelect`), so does the \"+N\".\n */\nconst MonthGrid = ({\n days,\n shown,\n hiddenCounts,\n weekdays,\n selectedDate,\n bodyRef,\n activeKey,\n preview,\n cancelledLabel,\n formatMore,\n renderEvent,\n handlers,\n onDaySelect,\n}: Props) => (\n <div\n className={styles.month}\n style={{ '--ui-calendar-rows': Math.ceil(days.length / WEEK) } as CSSProperties}\n >\n {weekdays && (\n /* Each cell is named by its full day; the row of weekday names is for the eye. */\n <div className={styles.weekdays} aria-hidden>\n {weekdays.map(weekday => (\n <span key={weekday}>{weekday}</span>\n ))}\n </div>\n )}\n <div ref={bodyRef} className={styles.cells}>\n {days.map((day, index) => {\n const hidden = hiddenCounts[index];\n const dayText = day.shortLabel ?? day.label;\n\n return (\n <div\n key={day.date}\n role=\"group\"\n aria-label={day.label}\n className={cx(\n styles.cell,\n day.isOff && styles['cell--off'],\n day.isOutside && styles['cell--outside'],\n preview?.target.column === index && styles['cell--target'],\n )}\n >\n {onDaySelect ? (\n <button\n type=\"button\"\n className={cx(styles.cell__day, day.isToday && styles['cell__day--today'])}\n aria-label={day.label}\n aria-current={day.isToday ? 'date' : undefined}\n aria-pressed={selectedDate === undefined ? undefined : day.date === selectedDate}\n onClick={() => onDaySelect(day.date)}\n >\n {dayText}\n </button>\n ) : (\n <span\n className={cx(styles.cell__day, day.isToday && styles['cell__day--today'])}\n aria-hidden\n >\n {dayText}\n </span>\n )}\n {shown[index].map(item => (\n <EventBlock\n key={item.key}\n item={item}\n view=\"month\"\n isActive={item.key === activeKey}\n isDragSource={item.key === preview?.key}\n isResizable={false}\n rangeStart={0}\n rangeLength={1}\n columnLabel={day.label}\n cancelledLabel={cancelledLabel}\n renderEvent={renderEvent}\n handlers={handlers}\n />\n ))}\n {hidden > 0 &&\n (onDaySelect ? (\n <button\n type=\"button\"\n className={styles.cell__more}\n onClick={() => onDaySelect(day.date)}\n >\n {formatMore(hidden)}\n </button>\n ) : (\n <span className={styles.cell__more}>{formatMore(hidden)}</span>\n ))}\n </div>\n );\n })}\n </div>\n </div>\n);\n\nexport default MonthGrid;\n","'use client';\n\nimport {\n type CSSProperties,\n type DragEvent,\n type MouseEvent,\n type ReactNode,\n type RefObject,\n} from 'react';\n\nimport { cx } from '../../helpers/class-name.helper';\nimport type { CalendarColumn, PlacedBand, PlacedEvent } from '../core/layout';\nimport { clamp, timeRange, toTime, toWall } from '../core/time';\nimport type { CalendarDay, CalendarEvent, CalendarResource, CalendarSlot } from '../core/types';\nimport type { DragPreview } from '../core/useCalendarDrag';\n\nimport EventBlock, { type EventHandlers } from './EventBlock';\nimport styles from './index.module.scss';\n\ntype Props = {\n label: string;\n days: readonly CalendarDay[];\n resources?: readonly CalendarResource[];\n columns: readonly CalendarColumn[];\n bands: readonly PlacedBand[];\n placed: readonly (readonly PlacedEvent[])[];\n rangeStart: number;\n rangeEnd: number;\n slotMinutes: number;\n bodyRef: RefObject<HTMLDivElement | null>;\n activeKey: string | undefined;\n preview: DragPreview | null;\n isEditable: boolean;\n cancelledLabel: string;\n renderEvent?: (event: CalendarEvent) => ReactNode;\n renderResource?: (resource: CalendarResource) => ReactNode;\n handlers: EventHandlers;\n /** True for the click that ends a drag: released on an empty slot, it is not a new event. */\n isClickSwallowed: () => boolean;\n onSlotSelect?: (slot: CalendarSlot) => void;\n onExternalDrop?: (drop: CalendarSlot & { data: string }) => void;\n};\n\n/** The header of a day: the short text shown, the full name read. */\nconst DayHeader = ({ day, span }: { day: CalendarDay; span: number }) => (\n <div\n className={cx(styles.header, day.isToday && styles['header--today'])}\n style={{ gridColumn: `span ${span}` }}\n aria-current={day.isToday ? 'date' : undefined}\n >\n {day.shortLabel ? (\n <>\n <span aria-hidden>{day.shortLabel}</span>\n <span className={styles.srOnly}>{day.label}</span>\n </>\n ) : (\n day.label\n )}\n </div>\n);\n\n/** The header of a resource column: its label and detail, tinted by its tone. */\nconst ResourceHeader = ({\n resource,\n renderResource,\n}: {\n resource: CalendarResource;\n renderResource?: (resource: CalendarResource) => ReactNode;\n}) => (\n <div\n className={cx(styles.resource, resource.tone && styles[`resource--${resource.tone}`])}\n data-tone={resource.tone}\n >\n {renderResource ? (\n renderResource(resource)\n ) : (\n <>\n {resource.label}\n {resource.detail && <span className={styles.resource__detail}>{resource.detail}</span>}\n </>\n )}\n </div>\n);\n\n/**\n * The time grid — days (and their resources) as columns, the drawn hours as rows. Events sit at\n * their time; overlapping ones share the column side by side. One scroll box: the headers stay\n * on top and the hours on the left while it scrolls both ways.\n */\nconst TimeGrid = ({\n label,\n days,\n resources,\n columns,\n bands,\n placed,\n rangeStart,\n rangeEnd,\n slotMinutes,\n bodyRef,\n activeKey,\n preview,\n isEditable,\n cancelledLabel,\n renderEvent,\n renderResource,\n handlers,\n isClickSwallowed,\n onSlotSelect,\n onExternalDrop,\n}: Props) => {\n const rangeLength = rangeEnd - rangeStart;\n const resourceCount = resources?.length ?? 0;\n const hasResources = resourceCount > 0;\n const hours = Array.from(\n { length: Math.floor((rangeEnd - 1) / 60) - Math.ceil(rangeStart / 60) + 1 },\n (_, index) => (Math.ceil(rangeStart / 60) + index) * 60,\n );\n /** A length of minutes as a share of the drawn hours; `percent(t)` is where time `t` sits. */\n const share = (minutes: number) => `${(minutes / rangeLength) * 100}%`;\n const percent = (minutes: number) => share(minutes - rangeStart);\n const previewItem = preview ? placed.flat().find(item => item.key === preview.key) : undefined;\n\n /** The slot under a pointer in a column, snapped down to the slot. */\n const slotAt = (column: CalendarColumn, element: HTMLElement, clientY: number): CalendarSlot => {\n const box = element.getBoundingClientRect();\n const ratio = box.height > 0 ? clamp((clientY - box.top) / box.height, 0, 1) : 0;\n const minutes = Math.floor((ratio * rangeLength) / slotMinutes) * slotMinutes;\n const start = clamp(rangeStart + minutes, rangeStart, rangeEnd - slotMinutes);\n\n return {\n start: toWall(column.day.date, start),\n end: toWall(column.day.date, start + slotMinutes),\n resourceId: column.resource?.id,\n };\n };\n\n const style = {\n '--ui-calendar-columns': columns.length,\n '--ui-calendar-hours': rangeLength / 60,\n '--ui-calendar-slot-ratio': slotMinutes / 60,\n } as CSSProperties;\n\n return (\n /*\n * With no event to focus, the scroll box itself takes the focus (2.1.1): the hours past the\n * fold are reached with the arrow keys of the box.\n */\n <div\n className={styles.scroller}\n {...(placed.some(list => list.length > 0)\n ? {}\n : { tabIndex: 0, role: 'region', 'aria-label': label })}\n >\n <div className={cx(styles.time, bands.length > 0 && styles['time--bands'])} style={style}>\n <div className={styles.corner} />\n <div className={styles.headers}>\n {days.map(day => (\n <DayHeader key={day.date} day={day} span={hasResources ? resourceCount : 1} />\n ))}\n {hasResources &&\n columns.map(column => (\n <ResourceHeader\n key={column.index}\n resource={column.resource as CalendarResource}\n renderResource={renderResource}\n />\n ))}\n </div>\n\n <div className={styles.gutter} aria-hidden>\n {hours.map(minutes => (\n <span key={minutes} className={styles.gutter__hour} style={{ top: percent(minutes) }}>\n {toTime(minutes)}\n </span>\n ))}\n {bands.map(band => (\n <span\n key={band.key}\n className={styles.gutter__band}\n style={{ top: percent(band.startMin), height: share(band.endMin - band.startMin) }}\n >\n {band.label}\n </span>\n ))}\n </div>\n\n <div ref={bodyRef} className={styles.columns}>\n {columns.map(column => (\n <div\n key={column.index}\n role=\"group\"\n aria-label={column.label}\n className={cx(styles.column, column.day.isOff && styles['column--off'])}\n onClick={\n onSlotSelect\n ? (event: MouseEvent<HTMLDivElement>) => {\n if (event.target !== event.currentTarget || isClickSwallowed()) return;\n onSlotSelect(slotAt(column, event.currentTarget, event.clientY));\n }\n : undefined\n }\n onDragOver={\n onExternalDrop\n ? (event: DragEvent<HTMLDivElement>) => {\n event.preventDefault();\n event.dataTransfer.dropEffect = 'move';\n }\n : undefined\n }\n onDrop={\n onExternalDrop\n ? (event: DragEvent<HTMLDivElement>) => {\n event.preventDefault();\n onExternalDrop({\n ...slotAt(column, event.currentTarget, event.clientY),\n data: event.dataTransfer.getData('text/plain'),\n });\n }\n : undefined\n }\n >\n {bands.map((band, index) => (\n <div\n key={band.key}\n className={cx(styles.band, index % 2 === 1 && styles['band--alternate'])}\n style={{\n top: percent(band.startMin),\n height: share(band.endMin - band.startMin),\n }}\n aria-hidden\n />\n ))}\n {placed[column.index].map(item => (\n <EventBlock\n key={item.key}\n item={item}\n view=\"time\"\n isActive={item.key === activeKey}\n isDragSource={item.key === preview?.key}\n isResizable={isEditable && item.isMovable}\n rangeStart={rangeStart}\n rangeLength={rangeLength}\n columnLabel={column.label}\n cancelledLabel={cancelledLabel}\n renderEvent={renderEvent}\n handlers={handlers}\n />\n ))}\n {preview && previewItem && preview.target.column === column.index && (\n <div\n className={styles.preview}\n style={\n {\n '--ui-calendar-top': percent(preview.target.startMin),\n '--ui-calendar-height': `${((preview.target.endMin - preview.target.startMin) / rangeLength) * 100}%`,\n } as CSSProperties\n }\n aria-hidden\n >\n {timeRange(preview.target.startMin, preview.target.endMin)}\n <span className={styles.preview__title}>{previewItem.event.title}</span>\n </div>\n )}\n </div>\n ))}\n </div>\n </div>\n </div>\n );\n};\n\nexport default TimeGrid;\n","'use client';\n\nimport {\n type KeyboardEvent,\n memo,\n type MouseEvent,\n type PointerEvent,\n type ReactNode,\n useCallback,\n useEffect,\n useId,\n useMemo,\n useRef,\n useState,\n} from 'react';\n\nimport { useAnnounce, useUi } from '@handijitcom/ui';\n\nimport { cx } from '../../helpers/class-name.helper';\nimport { named } from '../../helpers/component.helper';\nimport { resolveFormatter, resolveLabel } from '../../helpers/label.helper';\nimport {\n buildColumns,\n placeBands,\n type PlacedEvent,\n placeMonthEvents,\n placeTimeEvents,\n} from '../core/layout';\nimport {\n type CalendarTarget,\n type CalendarView,\n changeOf,\n isArrowKey,\n keyboardTarget,\n type MoveBounds,\n neighbourOf,\n} from '../core/moves';\nimport { timeRange, toMinutes } from '../core/time';\nimport type {\n CalendarBand,\n CalendarDay,\n CalendarEvent,\n CalendarEventChange,\n CalendarResource,\n CalendarSlot,\n} from '../core/types';\nimport useCalendarDrag from '../core/useCalendarDrag';\n\nimport type { EventHandlers } from './EventBlock';\nimport styles from './index.module.scss';\nimport MonthGrid from './MonthGrid';\nimport TimeGrid from './TimeGrid';\n\ntype Props = {\n /** The calendar's accessible name (\"Ders planı\"). */\n label: string;\n /** The days to draw, in order — computed by the caller (`@handijit/tr` owns day arithmetic). */\n days: readonly CalendarDay[];\n events: readonly CalendarEvent[];\n /** `time` (default): days as columns, hours as rows — day and week. `month`: day cells. */\n view?: CalendarView;\n /**\n * Time grid: a column per resource under every day (teacher, room, technician). A resource's\n * `detail` is a second header line and its `tone` tints the header (a full day: `warning`).\n */\n resources?: readonly CalendarResource[];\n /** Time grid (2.5): the header of a resource column; its label and detail by default. */\n renderResource?: (resource: CalendarResource) => ReactNode;\n /**\n * Time grid (2.5): named stretches of the day (\"Sabah\", \"Öğle\", \"Akşam\") drawn beside the hours\n * and shaded across the columns, under the events and the hour blocks.\n */\n bands?: readonly CalendarBand[];\n /** Time grid: the first drawn hour, `HH:MM`. */\n startTime?: string;\n /** Time grid: the end of the drawn hours, `HH:MM` (at most \"24:00\"). */\n endTime?: string;\n /** Time grid: the snap of a move, a resize and a keyboard step, and the grid lines (minutes). */\n slotMinutes?: number;\n /** Month: the weekday names over the columns (\"Pzt\" … \"Paz\"). */\n weekdays?: readonly string[];\n /** Month: how many events a day cell lists before its \"+N\". */\n maxEventsPerDay?: number;\n /** Month: the day whose list the caller shows beside the calendar (`aria-pressed`). */\n selectedDate?: string;\n /**\n * An event dropped, stretched or moved with the keyboard. Without it the calendar only shows\n * and opens. The calendar is controlled: the move stands once `events` carries it, and a\n * refused move (a conflict) is simply not applied — say why in a toast.\n */\n onEventChange?: (change: CalendarEventChange) => void;\n /** Enter or a click on an event. */\n onEventOpen?: (id: string) => void;\n /** Time grid: a click on an empty slot (a new lesson there). */\n onSlotSelect?: (slot: CalendarSlot) => void;\n /** Month: the day number or the \"+N\" of a cell. */\n onDaySelect?: (date: string) => void;\n /**\n * Time grid: something dragged in from outside (an unassigned job of a pool) and dropped on a\n * slot; `data` is its `text/plain` drag data.\n */\n onExternalDrop?: (drop: CalendarSlot & { data: string }) => void;\n /** The body of an event under its time; its title by default. */\n renderEvent?: (event: CalendarEvent) => ReactNode;\n className?: string;\n testId?: string;\n};\n\nconst DEFAULT_MAX_PER_DAY = 3;\n\ntype Pending = { key: string; before: CalendarEvent };\n\n/**\n * Calendar (2.4) — the base of app-kit's `takvim` pattern: a time grid of days or of days and\n * resources, or a month; events moved and stretched with the pointer and with the keyboard.\n *\n * Keyboard: Tab reaches ONE event (roving `tabindex`; 500 lessons are not 500 tab stops);\n * ← ↑ → ↓ go to the neighbouring event; Enter opens it; ⌘/Ctrl + an arrow moves it one slot or\n * one column (month: a day or a week); ⌘/Ctrl ⇧ ↑ ↓ shortens or lengthens it. The move is\n * announced once `events` carries it. A short event can be smaller than the 44px touch target:\n * its size is its duration, and every pointer action has the keyboard way above.\n */\nconst Calendar = ({\n label,\n days,\n events,\n view = 'time',\n resources,\n renderResource,\n bands,\n startTime = '08:00',\n endTime = '20:00',\n slotMinutes = 30,\n weekdays,\n maxEventsPerDay = DEFAULT_MAX_PER_DAY,\n selectedDate,\n onEventChange,\n onEventOpen,\n onSlotSelect,\n onDaySelect,\n onExternalDrop,\n renderEvent,\n className,\n testId,\n}: Props) => {\n const { labels } = useUi();\n const announce = useAnnounce();\n const instructionsId = useId();\n const rootRef = useRef<HTMLDivElement>(null);\n const bodyRef = useRef<HTMLDivElement>(null);\n const [activeKey, setActiveKey] = useState<string>();\n const pendingRef = useRef<Pending | null>(null);\n\n const isEditable = Boolean(onEventChange);\n const rangeStart = toMinutes(startTime);\n const rangeEnd = toMinutes(endTime);\n\n const columns = useMemo(() => buildColumns(days, resources), [days, resources]);\n const placedBands = useMemo(\n () => placeBands(bands, rangeStart, rangeEnd),\n [bands, rangeStart, rangeEnd],\n );\n const placed = useMemo(\n () =>\n view === 'time'\n ? placeTimeEvents(events, columns, rangeStart, rangeEnd, isEditable)\n : placeMonthEvents(events, days, isEditable),\n [view, events, columns, days, rangeStart, rangeEnd, isEditable],\n );\n /* The month shows the first events of a day; the rest are behind \"+N\" and out of the tab order. */\n const focusable = useMemo(\n () => (view === 'month' ? placed.map(list => list.slice(0, maxEventsPerDay)) : placed),\n [view, placed, maxEventsPerDay],\n );\n\n const bounds: MoveBounds = {\n view,\n columnCount: view === 'time' ? columns.length : days.length,\n rangeStart,\n rangeEnd,\n slotMinutes,\n };\n\n const items = focusable.flat();\n const tabbableKey = items.some(item => item.key === activeKey) ? activeKey : items[0]?.key;\n\n const columnLabel = (item: PlacedEvent) =>\n view === 'time' ? columns[item.column].label : days[item.column].label;\n\n /* The latest props for the stable handlers the memoised events hold. */\n const latest = useRef({ view, columns, days, onEventChange, onEventOpen, focusable, bounds });\n latest.current = { view, columns, days, onEventChange, onEventOpen, focusable, bounds };\n\n const apply = useCallback((item: PlacedEvent, target: CalendarTarget) => {\n const current = latest.current;\n const change = changeOf(item, target, current.view, current.columns, current.days);\n if (!change || !current.onEventChange) return undefined;\n current.onEventChange(change);\n\n return change;\n }, []);\n\n const drag = useCalendarDrag({ bodyRef, bounds, onDrop: apply });\n\n const focusKey = (key: string) => {\n /* Only called from the calendar's own handlers and effect: the root is there. */\n const root = rootRef.current as HTMLDivElement;\n const element = [...root.querySelectorAll<HTMLElement>('[data-key]')].find(\n candidate => candidate.dataset.key === key,\n );\n element?.focus();\n };\n\n const handlers = useMemo<EventHandlers>(\n () => ({\n onPointerDown: (item: PlacedEvent, event: PointerEvent, isResize: boolean) => {\n pendingRef.current = null;\n if (latest.current.onEventChange) drag.begin(item, event, isResize);\n },\n onClick: (item: PlacedEvent, _event: MouseEvent) => {\n if (drag.isClickSwallowed()) return;\n latest.current.onEventOpen?.(item.event.id);\n },\n onFocus: (item: PlacedEvent) => setActiveKey(item.key),\n onKeyDown: (item: PlacedEvent, event: KeyboardEvent) => {\n pendingRef.current = null;\n if (!isArrowKey(event.key)) return;\n const current = latest.current;\n\n if (event.metaKey || event.ctrlKey) {\n event.preventDefault();\n if (!item.isMovable) return;\n const target = keyboardTarget(item, event.key, event.shiftKey, current.bounds);\n if (!target) return;\n pendingRef.current = {\n key: `${item.event.id}@${target.column}`,\n before: item.event,\n };\n if (!apply(item, target)) pendingRef.current = null;\n return;\n }\n\n const next = neighbourOf(current.focusable, item, event.key);\n if (!next) return;\n event.preventDefault();\n setActiveKey(next.key);\n focusKey(next.key);\n },\n }),\n // `drag.begin` and `drag.isClickSwallowed` are stable; the rest is read through `latest`.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [apply],\n );\n\n /*\n * A keyboard move stands once `events` carries it: the focus follows the event into its new\n * column (its button there is a new element) and the new place is announced.\n */\n useEffect(() => {\n const pending = pendingRef.current;\n if (!pending) return;\n const item = placed.flat().find(candidate => candidate.key === pending.key);\n const { before } = pending;\n const isMoved =\n item !== undefined &&\n (item.event.start !== before.start ||\n item.event.end !== before.end ||\n item.event.resourceId !== before.resourceId);\n if (!isMoved) return;\n\n pendingRef.current = null;\n setActiveKey(item.key);\n focusKey(item.key);\n announce(\n resolveFormatter(\n 'Calendar.moved',\n labels?.calendar?.moved,\n item.event.title,\n `${columnLabel(item)}, ${timeRange(item.startMin, item.endMin)}`,\n ),\n );\n // Runs when the events change: that is when a move stands.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [events]);\n\n const cancelledLabel = resolveLabel('Calendar.cancelled', labels?.calendar?.cancelled);\n const instructions = resolveLabel('Calendar.instructions', labels?.calendar?.instructions);\n\n return (\n <div\n ref={rootRef}\n className={cx(styles.calendar, className)}\n role=\"group\"\n aria-label={label}\n aria-describedby={instructionsId}\n data-testid={testId}\n >\n <span id={instructionsId} className={styles.srOnly}>\n {instructions}\n </span>\n {view === 'time' ? (\n <TimeGrid\n label={label}\n days={days}\n resources={resources}\n columns={columns}\n bands={placedBands}\n placed={placed}\n rangeStart={rangeStart}\n rangeEnd={rangeEnd}\n slotMinutes={slotMinutes}\n bodyRef={bodyRef}\n activeKey={tabbableKey}\n preview={drag.preview}\n isEditable={isEditable}\n cancelledLabel={cancelledLabel}\n renderEvent={renderEvent}\n renderResource={renderResource}\n handlers={handlers}\n isClickSwallowed={drag.isClickSwallowed}\n onSlotSelect={onSlotSelect}\n onExternalDrop={onExternalDrop}\n />\n ) : (\n <MonthGrid\n days={days}\n shown={focusable}\n hiddenCounts={placed.map((list, index) => list.length - focusable[index].length)}\n weekdays={weekdays}\n selectedDate={selectedDate}\n bodyRef={bodyRef}\n activeKey={tabbableKey}\n preview={drag.preview}\n cancelledLabel={cancelledLabel}\n formatMore={count => resolveFormatter('Calendar.more', labels?.calendar?.more, count)}\n renderEvent={renderEvent}\n handlers={handlers}\n onDaySelect={onDaySelect}\n />\n )}\n </div>\n );\n};\n\nexport default /*#__PURE__*/ memo(/*#__PURE__*/ named(Calendar, 'Calendar')) as typeof Calendar;\n"],"names":["cx","values","result","value","named","component","displayName","warned","resolveLabel","key","resolveFormatter","formatter","args","MINUTES_PER_DAY","toMinutes","time","hours","minutes","toTime","dateOf","wall","minutesOf","toWall","date","timeRange","start","end","clamp","low","high","columnKey","resourceId","buildColumns","days","resources","day","dayIndex","resource","resourceIndex","index","covers","event","startDate","endDate","isSameDay","assignLanes","items","b","cluster","laneEnds","clusterEnd","close","item","free","laneEnd","placeTimeEvents","events","columns","rangeStart","rangeEnd","isEditable","byKey","column","_a","hasResources","placed","place","placeMonthEvents","byDate","cell","a","placeBands","bands","band","startMin","endMin","targetOf","isResize","deltaMinutes","bounds","shortest","duration","changeOf","target","view","isArrowKey","neighbourOf","lists","from","list","step","best","keyboardTarget","isVertical","direction","DRAG_THRESHOLD","WEEK","useCalendarDrag","bodyRef","onDrop","preview","setPreview","useState","cleanupRef","useRef","isSwallowingRef","latest","targetAt","origin","box","current","minutesPerPixel","delta","rows","row","begin","useCallback","stop","move","cancel","escape","swallowNextClick","moveEvent","travelled","upEvent","keyEvent","useEffect","isClickSwallowed","placement","rangeLength","EventBlock","isActive","isDragSource","isResizable","columnLabel","cancelledLabel","renderEvent","handlers","jsxs","styles","pointerEvent","mouseEvent","jsx","EventBlock$1","MonthGrid","shown","hiddenCounts","weekdays","selectedDate","activeKey","formatMore","onDaySelect","weekday","hidden","dayText","DayHeader","span","Fragment","ResourceHeader","renderResource","TimeGrid","label","slotMinutes","onSlotSelect","onExternalDrop","resourceCount","_","share","percent","previewItem","slotAt","element","clientY","ratio","style","DEFAULT_MAX_PER_DAY","Calendar","startTime","endTime","maxEventsPerDay","onEventChange","onEventOpen","className","testId","labels","useUi","announce","useAnnounce","instructionsId","useId","rootRef","setActiveKey","pendingRef","useMemo","placedBands","focusable","tabbableKey","apply","change","drag","focusKey","candidate","_event","_b","next","pending","before","instructions","_c","count","memo"],"mappings":";;;;AAGO,MAAMA,IAAK,IAAIC,MAAiC;AACrD,MAAIC,IAAS;AAEb,aAAWC,KAASF;AAClB,IAAKE,MACLD,IAASA,MAAW,KAAKC,IAAQ,GAAGD,CAAM,IAAIC,CAAK;AAGrD,SAAOD;AACT,GCAaE,KAAQ,CACnBC,GACAC,MACe,OAAO,OAAOD,GAAW,EAAE,aAAAC,GAAa,GCVnDC,yBAAa,IAAA,GAUNC,KAAe,CAACC,MAAgBR,MAA2C;AACtF,aAAWE,KAASF,EAAQ,KAAIE,MAAU,OAAW,QAAOA;AAE5D,SAAI,QAAQ,IAAI,aAAa,gBAAgB,CAACI,GAAO,IAAIE,CAAG,MAC1DF,GAAO,IAAIE,CAAG,GACd,QAAQ;AAAA,IACN,kCAAkCA,CAAG;AAAA,EAAA,IAMlC;AACT,GAGaC,KAAmB,CAC9BD,GACAE,MACGC,MAECD,IAAkBA,EAAU,GAAGC,CAAI,IAEhCJ,GAAaC,CAAG,GChCZI,KAAkB,MAGlBC,IAAY,CAACC,MAAyB;AACjD,QAAM,CAACC,GAAOC,CAAO,IAAIF,EAAK,MAAM,GAAG;AAEvC,SAAO,OAAOC,CAAK,IAAI,KAAK,OAAOC,KAAW,CAAC;AACjD,GAGaC,KAAS,CAACD,MACrB,GAAG,OAAO,KAAK,MAAMA,IAAU,EAAE,CAAC,EAAE,SAAS,GAAG,GAAG,CAAC,IAAI,OAAOA,IAAU,EAAE,EAAE,SAAS,GAAG,GAAG,CAAC,IAGlFE,IAAS,CAACC,MAAyBA,EAAK,MAAM,GAAG,EAAE,GAGnDC,IAAY,CAACD,MAAyBN,EAAUM,EAAK,MAAM,IAAI,EAAE,CAAC,GAGlEE,KAAS,CAACC,GAAcN,MAA4B,GAAGM,CAAI,IAAIL,GAAOD,CAAO,CAAC,IAG9EO,KAAY,CA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AAS,SACR,gBAAA0D;AAAA,UAACkB;AAAA,UAAA;AAAA,YACC,OAAAC;AAAA,YACA,MAAAhI;AAAA,YACA,WAAAC;AAAA,YACA,SAAAuB;AAAA,YACA,OAAOyI;AAAA,YACP,QAAAjI;AAAA,YACA,YAAAP;AAAA,YACA,UAAAC;AAAA,YACA,aAAAuG;AAAA,YACA,SAAAhE;AAAA,YACA,WAAWkG;AAAA,YACX,SAASG,EAAK;AAAA,YACd,YAAA3I;AAAA,YACA,gBAAA2E;AAAA,YACA,aAAAC;AAAA,YACA,gBAAAuB;AAAA,YACA,UAAAtB;AAAA,YACA,kBAAkB8D,EAAK;AAAA,YACvB,cAAApC;AAAA,YACA,gBAAAC;AAAA,UAAA;AAAA,QAAA,IAGF,gBAAAtB;AAAA,UAACE;AAAA,UAAA;AAAA,YACC,MAAA/G;AAAA,YACA,OAAOkK;AAAA,YACP,cAAclI,EAAO,IAAI,CAACwB,GAAMlD,MAAUkD,EAAK,SAAS0G,EAAU5J,CAAK,EAAE,MAAM;AAAA,YAC/E,UAAA4G;AAAA,YACA,cAAAC;AAAA,YACA,SAAAlD;AAAA,YACA,WAAWkG;AAAA,YACX,SAASG,EAAK;AAAA,YACd,gBAAAhE;AAAA,YACA,YAAY,CAAA0E,MAAA;;AAAS,qBAAAvM,GAAiB,kBAAiBqD,IAAAyH,KAAA,gBAAAA,EAAQ,aAAR,gBAAAzH,EAAkB,MAAMkJ,CAAK;AAAA;AAAA,YACpF,aAAAzE;AAAA,YACA,UAAAC;AAAA,YACA,aAAAc;AAAA,UAAA;AAAA,QAAA;AAAA,MACF;AAAA,IAAA;AAAA,EAAA;AAIR,GAEAhH,KAA6B,gBAAA2K,GAAmB,gBAAA9M,GAAM4K,IAAU,UAAU,CAAC;"}
|
package/build/charts.cjs
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),f=require("react"),dt=require("@handijitcom/ui"),Gt=require("@handijit/design"),at=(t,s)=>Object.assign(t,{displayName:s}),xe="ui-axis-AqLAe",fe="ui-axis__label-dHxpo",pe="ui-axis__grid-RVxXW",ye="ui-axis__baseline-jhG2z",st={axis:xe,axis__label:fe,axis__grid:pe,axis__baseline:ye},wt=(t,s,e)=>{const n=e(t);return t.map((c,i)=>({position:s(c),label:n[i]}))},ie=6.4,ht=t=>t.length*ie,he=(t,s=8)=>{if(t.length<2)return[...t];const e=Math.max(...t.map(i=>ht(i.label))),n=Math.abs(t[1].position-t[0].position),c=n<=0?1:Math.max(1,Math.ceil((e+s)/n));return t.filter((i,m)=>m%c===0)},St=(t,s)=>{const e=Math.max(1,Math.floor(s/ie));return t.length<=e?t:`${t.slice(0,Math.max(1,e-1))}…`},ut=({area:t,ticks:s,side:e,hasGrid:n=!1})=>l.jsx("g",{className:st.axis,"aria-hidden":!0,children:s.map(c=>e==="bottom"?l.jsxs("g",{children:[n&&l.jsx("line",{className:st.axis__grid,x1:c.position,x2:c.position,y1:t.top,y2:t.bottom}),l.jsx("text",{className:st.axis__label,x:c.position,y:t.bottom+16,textAnchor:"middle",children:c.label})]},`${c.position}-${c.label}`):l.jsxs("g",{children:[n&&l.jsx("line",{className:st.axis__grid,x1:t.left,x2:t.right,y1:c.position,y2:c.position}),l.jsx("text",{className:st.axis__label,x:e==="left"?t.left-8:t.right+8,y:c.position,dy:"0.32em",textAnchor:e==="left"?"end":"start",children:c.label})]},`${c.position}-${c.label}`))}),Ot=({area:t,ticks:s,side:e})=>l.jsx("g",{className:st.axis,"aria-hidden":!0,children:e==="bottom"?l.jsxs(l.Fragment,{children:[l.jsx("line",{className:st.axis__baseline,x1:t.left,x2:t.right,y1:t.bottom,y2:t.bottom}),he(s).map(n=>l.jsx("text",{className:st.axis__label,x:n.position,y:t.bottom+16,textAnchor:"middle",children:n.label},`${n.position}-${n.label}`))]}):l.jsxs(l.Fragment,{children:[l.jsx("line",{className:st.axis__baseline,x1:t.left,x2:t.left,y1:t.top,y2:t.bottom}),s.map(n=>l.jsx("text",{className:st.axis__label,x:t.left-8,y:n.position,dy:"0.32em",textAnchor:"end",children:St(n.label,t.left-12)},`${n.position}-${n.label}`))]})}),V=t=>Math.round(t*100)/100,ge=t=>{const s=[];let e=[];for(const n of t)n===null||!Number.isFinite(n.x)||!Number.isFinite(n.y)?(e.length>0&&s.push(e),e=[]):e.push(n);return e.length>0&&s.push(e),s},Lt=t=>t.map((s,e)=>`${e===0?"M":"L"}${V(s.x)},${V(s.y)}`).join(""),ue=t=>{const s=t.length;if(s<3)return Lt(t);const e=[],n=[];for(let i=0;i<s-1;i+=1){const m=t[i+1].x-t[i].x;n.push(m===0?0:(t[i+1].y-t[i].y)/m)}e.push(n[0]);for(let i=1;i<s-1;i+=1)e.push(n[i-1]*n[i]<=0?0:(n[i-1]+n[i])/2);e.push(n[s-2]);for(let i=0;i<s-1;i+=1){if(n[i]===0){e[i]=0,e[i+1]=0;continue}const m=e[i]/n[i],d=e[i+1]/n[i],k=m*m+d*d;if(k>9){const A=3/Math.sqrt(k);e[i]=A*m*n[i],e[i+1]=A*d*n[i]}}let c=`M${V(t[0].x)},${V(t[0].y)}`;for(let i=0;i<s-1;i+=1){const m=t[i],d=t[i+1],k=(d.x-m.x)/3;c+=`C${V(m.x+k)},${V(m.y+e[i]*k)} ${V(d.x-k)},${V(d.y-e[i+1]*k)} ${V(d.x)},${V(d.y)}`}return c},be=(t,s="linear")=>ge(t).map(e=>s==="monotone"?ue(e):Lt(e)).join(""),Me=(t,s,e="linear")=>{const n=[];let c=[],i=[];const m=()=>{if(c.length>0){const d=e==="monotone"?ue:Lt,k=d([...i].reverse()).replace(/^M/,"L");n.push(`${d(c)}${k}Z`)}c=[],i=[]};return t.forEach((d,k)=>{const A=s[k];d===null||A===null||A===void 0?m():(c.push(d),i.push(A))}),m(),n.join("")},tt=(t,s,e,n)=>({x:t+e*Math.sin(n),y:s-e*Math.cos(n)}),Yt=(t,s,e,n,c,i)=>{const m=i-c;if(m<=0||e<=0)return"";if(m>=Math.PI*2-1e-6){const b=(R,E)=>`M${V(t)},${V(s-R)}A${R},${R} 0 1 ${E} ${V(t)},${V(s+R)}A${R},${R} 0 1 ${E} ${V(t)},${V(s-R)}Z`;return b(e,1)+(n>0?b(n,0):"")}const d=m>Math.PI?1:0,k=tt(t,s,e,c),A=tt(t,s,e,i);if(n<=0)return`M${V(t)},${V(s)}L${V(k.x)},${V(k.y)}A${e},${e} 0 ${d} 1 ${V(A.x)},${V(A.y)}Z`;const T=tt(t,s,n,i),C=tt(t,s,n,c);return`M${V(k.x)},${V(k.y)}A${e},${e} 0 ${d} 1 ${V(A.x)},${V(A.y)}L${V(T.x)},${V(T.y)}A${n},${n} 0 ${d} 0 ${V(C.x)},${V(C.y)}Z`},Zt=t=>t.length===0?"":`${Lt(t)}Z`,mt=(t,s)=>{const[e,n]=t,[c,i]=s,m=n-e,d=k=>m===0?(c+i)/2:c+(k-e)/m*(i-c);return d.domain=t,d.range=s,d.invert=k=>i===c?e:e+(k-c)/(i-c)*m,d},Rt=(t,s,{paddingInner:e=.2,paddingOuter:n=.1}={})=>{const[c,i]=s,m=t.length,d=m===0?0:(i-c)/Math.max(1,m-e+n*2),k=d*(1-e),A=c+d*n,T=new Map(t.map((b,R)=>[b,R])),C=b=>{const R=T.get(b);return R===void 0?Number.NaN:A+R*d};return C.domain=t,C.range=s,C.bandwidth=k,C.step=d,C.indexAt=b=>m===0?-1:Math.min(m-1,Math.max(0,Math.floor((b-c-d*n+(d-k)/2)/d))),C},Vt=(t,s,e)=>{const n=Math.abs(s-t);if(n===0||!Number.isFinite(n)||e<=0)return 1;const c=n/e,i=10**Math.floor(Math.log10(c)),m=c/i;return(m>=7.5?10:m>=3.5?5:m>=1.5?2:1)*i},Bt=(t,s)=>{const e=Math.max(0,-Math.floor(Math.log10(s))+1);return Number(t.toFixed(Math.min(e,12)))},jt=(t,s,e=5)=>{if(!Number.isFinite(t)||!Number.isFinite(s))return[0,1];let n=Math.min(t,s),c=Math.max(t,s);if(n===c){if(n===0)return[0,1];const m=Math.abs(n)*.5;n=n>0?0:n-m,c=c<0?0:c+m}const i=Vt(n,c,e);return[Bt(Math.floor(n/i)*i,i),Bt(Math.ceil(c/i)*i,i)]},ot=(t,s,e=5)=>{if(!Number.isFinite(t)||!Number.isFinite(s))return[];if(t===s)return[t];const n=Vt(t,s,e),c=Math.ceil(t/n-1e-9),i=Math.floor(s/n+1e-9),m=[];for(let d=c;d<=i&&m.length<1e3;d+=1)m.push(Bt(d*n,n));return m},_e=(t,s)=>{if(t.length===0)return-1;let e=0,n=t.length-1;for(;e<n;){const c=e+n>>1;t[c]<s?e=c+1:n=c}return e>0&&Math.abs(t[e-1]-s)<=Math.abs(t[e]-s)?e-1:e},Ht=t=>t.filter(s=>typeof s=="number"&&Number.isFinite(s)),xt=t=>{if(t.length===0)return[0,0];let s=t[0],e=t[0];for(const n of t)n<s&&(s=n),n>e&&(e=n);return[s,e]},Pt=(t,s)=>{if(t.length===0)return Number.NaN;if(t.length===1)return t[0];const e=(t.length-1)*Math.min(1,Math.max(0,s)),n=Math.floor(e),c=e-n;return n+1<t.length?t[n]+(t[n+1]-t[n])*c:t[n]},$e=t=>{const s=Ht(t).sort((m,d)=>m-d);if(s.length===0)return null;const e=Pt(s,.25),n=Pt(s,.75),c=(n-e)*1.5,i=s.filter(m=>m>=e-c&&m<=n+c);return{count:s.length,min:s[0],q1:e,median:Pt(s,.5),q3:n,max:s[s.length-1],whiskerLow:i[0]??e,whiskerHigh:i[i.length-1]??n,outliers:s.filter(m=>m<e-c||m>n+c)}},we=(t,s)=>{const e=Ht(t);if(e.length===0)return[];const[n,c]=xt(e);if(n===c)return[{from:n,to:n+1,count:e.length}];const i=s??Math.ceil(Math.log2(e.length))+1,m=Vt(n,c,Math.max(1,i)),d=Math.floor(n/m)*m,k=Math.max(1,Math.ceil((c-d)/m-1e-9)),A=Array.from({length:k},(T,C)=>({from:d+C*m,to:d+(C+1)*m,count:0}));for(const T of e){const C=Math.min(A.length-1,Math.floor((T-d)/m));A[C].count+=1}return A},$t=t=>typeof t=="number"&&Number.isFinite(t)?t:null,ct={top:12,right:16,bottom:28,minLeft:32},je=(t,s)=>{const e=t.map(()=>0),n=t.map(()=>0),c={};for(const i of s)c[i]=t.map((m,d)=>{const k=$t(m[i])??0;if(k>=0){const T=e[d];return e[d]+=k,{base:T,top:e[d]}}const A=n[d];return n[d]+=k,{base:A,top:n[d]}});return c},ke=t=>{const{rows:s,xKey:e,series:n,width:c,height:i,isStacked:m,curve:d,formatX:k}=t,A=n.some(v=>v.type==="bar"),C=(A&&n.every(v=>v.type==="bar")?t.orientation:"vertical")==="horizontal",b=s.map(v=>v[e]),R=!A&&!C&&b.length>1&&b.every(v=>$t(v)!==null),E={};if(m)for(const v of["left","right"])for(const O of["bar","area"]){const B=n.filter(Z=>(Z.axis??"left")===v&&Z.type===O).map(Z=>Z.key);Object.assign(E,je(s,B))}const S=(v,O)=>{if(E[v])return E[v][O];const B=$t(s[O][v]);return B===null?null:{base:0,top:B}},D=v=>{const O=n.filter(lt=>(lt.axis??"left")===v);if(O.length===0)return null;let B=Number.POSITIVE_INFINITY,Z=Number.NEGATIVE_INFINITY;for(const lt of O)for(let gt=0;gt<s.length;gt+=1){const it=S(lt.key,gt);it&&(B=Math.min(B,it.top,it.base),Z=Math.max(Z,it.top,it.base))}if(O.some(lt=>lt.type!=="line")&&(B=Math.min(B,0),Z=Math.max(Z,0)),!Number.isFinite(B)||!Number.isFinite(Z))return[0,1];const[et,J]=v==="left"?t.domain??[void 0,void 0]:[void 0,void 0],K=jt(et??B,J??Z);return[et??K[0],J??K[1]]},z=D("left")??[0,1],N=D("right"),I=N!==null&&!C,P=t.formatLeft(ot(z[0],z[1],5)),$=N?t.formatRight(ot(N[0],N[1],5)):[],j=s.map(v=>k(v[e])),u=C?Math.min(c*.4,Math.max(ct.minLeft,...j.map(ht))+12):Math.max(ct.minLeft,...P.map(ht))+10,p=I?Math.max(ct.minLeft,...$.map(ht))+10:ct.right,a={left:u,top:ct.top,right:Math.max(u+1,c-p),bottom:Math.max(ct.top+1,i-ct.bottom),width:Math.max(1,c-p-u),height:Math.max(1,i-ct.bottom-ct.top)},h=C?[a.top,a.bottom]:[a.left,a.right],r=C?[a.left,a.right]:[a.bottom,a.top],o=mt(z,r),x=N?mt(N,r):o,M=v=>(v.axis??"left")==="right"&&N?x:o;let w,y=0,_=null;if(R){const v=b.map(O=>$t(O));_=mt(xt(v),h),w=v.map(_)}else{const v=Rt(s.map((O,B)=>String(B)),h,A?{paddingInner:.24,paddingOuter:.12}:{paddingInner:0,paddingOuter:0});y=v.bandwidth,w=s.map((O,B)=>v(String(B))+v.bandwidth/2)}const q=(v,O)=>C?{x:O,y:v}:{x:v,y:O},L=[],W=n.filter(v=>v.type==="bar"),U=m?1:Math.max(1,W.length),G=U>1?Math.min(2,y*.04):0,g=Math.max(1,(y-G*(U-1))/U);W.forEach((v,O)=>{const B=M(v),Z=m?0:O;s.forEach((et,J)=>{const K=S(v.key,J);if(!K||K.top===K.base)return;const lt=w[J]-y/2+Z*(g+G),gt=B(K.base),it=B(K.top),Ut=Math.min(gt,it),Xt=Math.max(1,Math.abs(it-gt));L.push(C?{key:v.key,index:J,tone:v.tone,x:Ut,y:lt,width:Xt,height:g}:{key:v.key,index:J,tone:v.tone,x:lt,y:Ut,width:g,height:Xt})})});const F={},H=[],X=[];for(const v of n){if(v.type==="bar")continue;const O=M(v),B=s.map((Z,et)=>{const J=S(v.key,et);return J?q(w[et],O(J.top)):null});if(F[v.key]=B,v.type==="area"){const Z=s.map((et,J)=>{const K=S(v.key,J);return K?q(w[J],O(K.base)):null});X.push({key:v.key,tone:v.tone,d:Me(B,Z,d)})}H.push({key:v.key,tone:v.tone,d:be(B,d)})}const rt=s.map((v,O)=>{let B=null;for(const et of n){const J=S(et.key,O);if(!J)continue;const K=M(et)(J.top);B=B===null?K:C?Math.max(B,K):Math.min(B,K)}const Z=C?a.left:a.bottom;return q(w[O],B??Z)}),kt=(v,O,B)=>wt(ot(O[0],O[1],C?Math.max(2,Math.floor(a.width/90)):Math.max(2,Math.floor(a.height/48))),v,B),de=_?ot(_.domain[0],_.domain[1],Math.max(2,Math.floor(a.width/90))).map(v=>({position:_(v),label:k(v)})):s.map((v,O)=>({position:w[O],label:C?St(j[O],u-12):j[O]}));return{zero:z[0]<0&&z[1]>0?o(0):null,area:a,centers:w,bandwidth:y,isContinuous:R,categoryTicks:de,leftTicks:kt(o,z,t.formatLeft),rightTicks:I&&N?kt(x,N,t.formatRight):[],hasRightAxis:I,lines:H,areas:X,bars:L,points:F,anchors:rt}},Qt=(...t)=>{let s="";for(const e of t)e&&(s=s===""?e:`${s} ${e}`);return s},Jt=["chart-1","chart-2","chart-3","chart-4","chart-5","chart-6"],Tt=(t,s)=>s??Jt[t%Jt.length],Y=t=>Gt.cssVar(t==="muted"?"text-3":t),Ne="ui-chart-iR-5u",ve="ui-chart__canvas-4wf8o",Te="ui-chart__svg-yC5iw",Ae="ui-chart__overlay-kbXEv",Ce="ui-chart__tooltip-wbhLY",Ie="ui-chart__tooltipTitle-j-1Nw",Fe="ui-chart__tooltipRow-phors",Re="ui-chart__tooltipLabel-72x80",Se="ui-chart__tooltipValue-caeby",Le="ui-chart__swatch--mk77",He="ui-chart__legend-EhXcQ",Ee="ui-chart__legendItem--AaGe",Pe="ui-chart__srOnly-Oyem2",Q={chart:Ne,chart__canvas:ve,chart__svg:Te,chart__overlay:Ae,chart__tooltip:Ce,chart__tooltipTitle:Ie,chart__tooltipRow:Fe,chart__tooltipLabel:Re,chart__tooltipValue:Se,chart__swatch:Le,chart__legend:He,chart__legendItem:Ee,"chart__legendItem--hidden":"ui-chart__legendItem--hidden-D3li8",chart__srOnly:Pe},Kt=12,ft=({label:t,description:s,containerRef:e,width:n,height:c,plot:i,overlay:m,underlay:d,itemCount:k,columns:A,pick:T,tooltip:C,anchor:b,tooltipSide:R="inward",announce:E,table:S,legend:D,className:z,testId:N})=>{const I=f.useId(),P=dt.useAnnounce(),[$,j]=f.useState(null),u=f.useRef(null),p=f.useRef(null),a=f.useRef(null);f.useEffect(()=>{$!==null&&$>=k&&j(k>0?k-1:null)},[$,k]),f.useEffect(()=>()=>{u.current!==null&&cancelAnimationFrame(u.current)},[]);const h=f.useCallback(y=>{const _=y.currentTarget.getBoundingClientRect();a.current={x:y.clientX-_.left,y:y.clientY-_.top},u.current===null&&(u.current=requestAnimationFrame(()=>{u.current=null;const q=a.current;q&&j(T(q.x,q.y))}))},[T]),r=y=>{const _=Math.min(k-1,Math.max(0,y));j(_),P(E(_))},o=y=>{if(k===0)return;const _=$??-1,q=A??1,L=y.key==="ArrowRight"?_+1:y.key==="ArrowLeft"?Math.max(0,_-1):y.key==="ArrowDown"?_<0?0:_+q:y.key==="ArrowUp"?Math.max(0,_-q):y.key==="Home"?0:y.key==="End"?k-1:null;if(y.key==="Escape"&&$!==null){y.preventDefault(),j(null);return}L!==null&&(y.preventDefault(),r(L))},x=$===null?null:C($),M=$===null?null:b($),w=M==null?void 0:M.x;return f.useLayoutEffect(()=>{const y=p.current;if(!y||w===void 0)return;const _=y.offsetWidth,q=w>n/2,L=R==="outward"?!q:q,W=w-Kt-_,U=w+Kt,G=W>=0,g=U+_<=n,F=R==="outward"?L?W:U:L?G||!g?W:U:g||!G?U:W;y.style.left=`${Math.min(Math.max(0,F),Math.max(0,n-_))}px`},[$,w,n,R]),l.jsxs("figure",{className:Qt(Q.chart,z),"data-testid":N,children:[l.jsxs("div",{ref:e,className:Q.chart__canvas,style:{blockSize:c},children:[l.jsxs("svg",{className:Q.chart__svg,width:n,height:c,viewBox:`0 0 ${n} ${c}`,role:"img","aria-label":t,"aria-describedby":s?I:void 0,tabIndex:k>0?0:void 0,onPointerMove:h,onPointerDown:h,onPointerLeave:()=>j(null),onKeyDown:o,onBlur:()=>j(null),children:[$!==null&&d&&l.jsx("g",{className:Q.chart__overlay,children:d($)}),i,$!==null&&l.jsx("g",{className:Q.chart__overlay,children:m($)})]}),x&&M&&l.jsxs("div",{ref:p,"aria-hidden":!0,className:Q.chart__tooltip,style:{insetBlockStart:Math.max(24,Math.min(M.y,c-24))},children:[x.title&&l.jsx("span",{className:Q.chart__tooltipTitle,children:x.title}),x.rows.map(y=>l.jsxs("span",{className:Q.chart__tooltipRow,children:[y.tone&&l.jsx("span",{className:Q.chart__swatch,style:{backgroundColor:Y(y.tone)}}),l.jsx("span",{className:Q.chart__tooltipLabel,children:y.label}),l.jsx("span",{className:Q.chart__tooltipValue,children:y.value})]},y.id))]})]}),D&&D.entries.length>1&&l.jsx("ul",{className:Q.chart__legend,children:D.entries.map(y=>{const _=D.hidden.has(y.id);return l.jsx("li",{children:l.jsxs("button",{type:"button",className:Qt(Q.chart__legendItem,_&&Q["chart__legendItem--hidden"]),"aria-pressed":!_,onClick:()=>D.onToggle(y.id),children:[l.jsx(ze,{tone:y.tone,isHidden:_}),y.label]})},y.id)})}),s&&l.jsx("p",{id:I,className:Q.chart__srOnly,children:s}),l.jsx("div",{className:Q.chart__srOnly,children:l.jsxs("table",{children:[l.jsx("caption",{children:t}),l.jsx("thead",{children:l.jsx("tr",{children:S.columns.map((y,_)=>l.jsx("th",{scope:"col",children:y},_))})}),l.jsx("tbody",{children:S.rows.map((y,_)=>l.jsx("tr",{children:y.map((q,L)=>L===0?l.jsx("th",{scope:"row",children:q},L):l.jsx("td",{children:q},L))},_))})]})})]})},ze=({tone:t,isHidden:s})=>l.jsx("span",{"aria-hidden":!0,className:Q.chart__swatch,style:s?{backgroundColor:"transparent",boxShadow:`inset 0 0 0 2px ${Y(t)}`}:{backgroundColor:Y(t)}}),te=new Map,me=(t,s)=>{const e=`${t??""}|${JSON.stringify(s)}`;let n=te.get(e);return n||(n=new Intl.NumberFormat(t,s),te.set(e,n)),n},ee=t=>{if(t===0||!Number.isFinite(t))return null;const[s,e]=Math.abs(t).toExponential(9).split("e"),n=Number(e);return{first:n,last:n-(s.replace(".","").replace(/0+$/,"").length-1)}},At=t=>s=>{const e=s.reduce((n,c)=>{var i;return Math.min(n,((i=ee(c))==null?void 0:i.last)??n)},Number.POSITIVE_INFINITY);return s.map(n=>{var c;return me(t,{notation:"compact",maximumSignificantDigits:Math.min(21,Math.max(1,(((c=ee(n))==null?void 0:c.first)??0)-e+1))}).format(n)})},pt=t=>s=>me(t,{maximumFractionDigits:2}).format(s),qe=640,De=typeof window>"u"?()=>{}:f.useLayoutEffect,yt=t=>{const s=f.useRef(null),[e,n]=f.useState(t??qe);return De(()=>{if(t!==void 0){n(t);return}const c=s.current;if(!c)return;const i=d=>{const k=Math.floor(d);k>0&&n(A=>A===k?A:k)};if(i(c.clientWidth),typeof ResizeObserver>"u")return;const m=new ResizeObserver(([d])=>i(d.contentRect.width));return m.observe(c),()=>m.disconnect()},[t]),[s,e]},Ge="ui-line-CLpqU",Oe="ui-area-LkWXB",Be="ui-bar-260Bd",Ve="ui-point-Vc-kX",We="ui-marker-G-xZb",Ue="ui-crosshair-nV-xX",Xe="ui-band-jnG7s",Ye="ui-zero-GpHvw",nt={line:Ge,area:Oe,bar:Be,point:Ve,marker:We,crosshair:Ue,band:Xe,zero:Ye},Ze=280,ne="—",Qe=({label:t,description:s,data:e,xKey:n,xLabel:c,series:i,height:m=Ze,width:d,isStacked:k=!1,orientation:A="vertical",curve:T="monotone",hasPoints:C=!1,formatX:b=String,formatValue:R,domain:E,className:S,testId:D})=>{const{labels:z}=dt.useUi(),N=z==null?void 0:z.locale,[I,P]=yt(d),[$,j]=f.useState(()=>new Set),u=f.useMemo(()=>R??pt(N),[R,N]),p=f.useMemo(()=>At(N),[N]),a=f.useCallback(g=>g==null?"":b(g),[b]),h=f.useMemo(()=>i.map((g,F)=>({...g,tone:Tt(F,g.tone)})),[i]),r=f.useMemo(()=>h.filter(g=>!$.has(g.key)),[h,$]),o=f.useMemo(()=>ke({rows:e,xKey:n,series:r,width:P,height:m,isStacked:k,orientation:A,curve:T,formatX:a,formatLeft:p,formatRight:p,domain:E}),[e,n,r,P,m,k,A,T,a,p,E]),x=A==="horizontal"&&r.length>0&&r.every(g=>g.type==="bar"),M=r.some(g=>g.type==="bar"),w=f.useMemo(()=>{const g=o.centers.map((F,H)=>({center:F,index:H})).sort((F,H)=>F.center-H.center);return{centers:g.map(F=>F.center),indices:g.map(F=>F.index)}},[o.centers]),y=f.useCallback((g,F)=>{const{area:H}=o;if(g<H.left-4||g>H.right+4||F<H.top-4||F>H.bottom+4)return null;const X=_e(w.centers,x?F:g);return X<0?null:w.indices[X]},[o,w,x]),_=f.useCallback(g=>{var F;return{title:a((F=e[g])==null?void 0:F[n]),rows:r.map(H=>{var rt;const X=$t((rt=e[g])==null?void 0:rt[H.key]);return{id:H.key,label:H.label,tone:H.tone,value:X===null?ne:(H.format??u)(X)}})}},[e,n,r,u,a]),q=f.useCallback(g=>{const F=_(g);return`${F.title}: ${F.rows.map(H=>`${H.label} ${H.value}`).join(", ")}`},[_]),L=f.useMemo(()=>({columns:[c??n,...h.map(g=>g.label)],rows:e.map(g=>[a(g[n]),...h.map(F=>{const H=$t(g[F.key]);return H===null?ne:(F.format??u)(H)})])}),[e,n,c,h,u,a]),W=f.useMemo(()=>l.jsxs("g",{children:[x?l.jsxs(l.Fragment,{children:[l.jsx(ut,{area:o.area,ticks:o.leftTicks,side:"bottom",hasGrid:!0}),l.jsx(Ot,{area:o.area,ticks:o.categoryTicks,side:"left"})]}):l.jsxs(l.Fragment,{children:[l.jsx(ut,{area:o.area,ticks:o.leftTicks,side:"left",hasGrid:!0}),o.hasRightAxis&&l.jsx(ut,{area:o.area,ticks:o.rightTicks,side:"right"}),l.jsx(Ot,{area:o.area,ticks:o.categoryTicks,side:"bottom"})]}),o.zero!==null&&(x?l.jsx("line",{className:nt.zero,x1:o.zero,x2:o.zero,y1:o.area.top,y2:o.area.bottom}):l.jsx("line",{className:nt.zero,x1:o.area.left,x2:o.area.right,y1:o.zero,y2:o.zero})),o.areas.map(g=>l.jsx("path",{d:g.d,className:nt.area,style:{fill:`color-mix(in srgb, ${Y(g.tone)} 18%, transparent)`}},`area-${g.key}`)),o.bars.map(g=>l.jsx("rect",{className:nt.bar,x:g.x,y:g.y,width:g.width,height:g.height,rx:Math.min(3,g.width/4,g.height/4),style:{fill:Y(g.tone)}},`bar-${g.key}-${g.index}`)),o.lines.map(g=>l.jsx("path",{d:g.d,className:nt.line,style:{stroke:Y(g.tone)}},`line-${g.key}`)),r.filter(g=>g.type!=="bar").flatMap(g=>(o.points[g.key]??[]).map((F,H,X)=>F&&(C||!X[H-1]&&!X[H+1])?l.jsx("circle",{className:nt.point,cx:F.x,cy:F.y,r:3,style:{fill:Y(g.tone)}},`point-${g.key}-${H}`):null))]}),[o,C,x,r]),U=f.useCallback(g=>{if(!M||o.bandwidth<=0)return null;const{area:F}=o,H=o.centers[g],X=o.bandwidth*.12;return x?l.jsx("rect",{className:nt.band,x:F.left,width:F.width,y:H-o.bandwidth/2-X,height:o.bandwidth+X*2}):l.jsx("rect",{className:nt.band,y:F.top,height:F.height,x:H-o.bandwidth/2-X,width:o.bandwidth+X*2})},[o,x,M]),G=f.useCallback(g=>{const{area:F}=o,H=o.centers[g];return l.jsxs(l.Fragment,{children:[!M&&l.jsx("line",{className:nt.crosshair,x1:H,x2:H,y1:F.top,y2:F.bottom}),r.filter(X=>X.type!=="bar").map(X=>{var kt;const rt=(kt=o.points[X.key])==null?void 0:kt[g];return rt?l.jsx("circle",{className:nt.marker,cx:rt.x,cy:rt.y,r:4.5,style:{fill:Y(X.tone)}},X.key):null})]})},[o,r,M]);return l.jsx(ft,{label:t,description:s,containerRef:I,width:P,height:m,plot:W,overlay:G,underlay:U,itemCount:e.length,pick:y,tooltip:_,anchor:g=>o.anchors[g]??{x:0,y:0},announce:q,table:L,legend:{entries:h.map(g=>({id:g.key,label:g.label,tone:g.tone})),hidden:$,onToggle:g=>j(F=>{const H=new Set(F);return H.has(g)?H.delete(g):h.length-F.size>1&&H.add(g),H})},className:S,testId:D})},Et=f.memo(Qe),Je=({series:t,...s})=>{const e=f.useMemo(()=>t.map(n=>({...n,type:"line"})),[t]);return l.jsx(Et,{...s,series:e})},Ke=f.memo(at(Je,"LineChart")),tn=({series:t,...s})=>{const e=f.useMemo(()=>t.map(n=>({...n,type:"area"})),[t]);return l.jsx(Et,{...s,series:e})},en=f.memo(at(tn,"AreaChart")),nn=({series:t,...s})=>{const e=f.useMemo(()=>t.map(n=>({...n,type:"bar"})),[t]);return l.jsx(Et,{...s,series:e})},sn=f.memo(at(nn,"BarChart")),on=t=>l.jsx(Et,{...t}),an=f.memo(at(on,"ComposedChart")),cn="ui-slice-dFWuh",rn="ui-center__value-GnqKe",ln="ui-center__label-DsgTV",Nt={slice:cn,center__value:rn,center__label:ln},Ct=6,se=1.5,hn=({label:t,description:s,data:e,variant:n="donut",centerValue:c,centerLabel:i,valueLabel:m,height:d=260,width:k,formatValue:A,className:T,testId:C})=>{const{labels:b}=dt.useUi(),[R,E]=yt(k),[S,D]=f.useState(()=>new Set),z=f.useMemo(()=>pt(b==null?void 0:b.locale),[b==null?void 0:b.locale]),N=A??z,I=f.useMemo(()=>e.map((a,h)=>({...a,tone:Tt(h,a.tone)})),[e]),P=f.useMemo(()=>{const a=I.filter(_=>!S.has(_.id)&&Number.isFinite(_.value)&&_.value>0),h=a.reduce((_,q)=>_+q.value,0),r=E/2,o=d/2,x=Math.max(8,Math.min(E,d)/2-Ct-4),M=n==="donut"?x*.62:0;let w=0;const y=a.map(_=>{const q=h>0?_.value/h*Math.PI*2:0,L=w;return w+=q,{..._,start:L,end:w,share:h>0?_.value/h:0}});return{cx:r,cy:o,outer:x,inner:M,total:h,slices:y}},[I,S,E,d,n]),$=f.useMemo(()=>{const a=new Intl.NumberFormat(b==null?void 0:b.locale,{style:"percent",maximumFractionDigits:1});return h=>a.format(h)},[b==null?void 0:b.locale]),j=f.useMemo(()=>{const{cx:a,cy:h,outer:r,inner:o,slices:x,total:M}=P;return l.jsxs("g",{children:[x.map(w=>l.jsx("path",{className:Nt.slice,d:Yt(a,h,r,o,w.start,w.end),style:{fill:Y(w.tone),strokeWidth:x.length>1?se:0}},w.id)),n==="donut"&&l.jsxs("g",{"aria-hidden":!0,className:Nt.center,children:[l.jsx("text",{className:Nt.center__value,x:a,y:i?h-4:h,dy:"0.32em",textAnchor:"middle",children:c??N(M)}),i&&l.jsx("text",{className:Nt.center__label,x:a,y:h+16,dy:"0.32em",textAnchor:"middle",children:i})]})]})},[P,n,c,i,N]),u=f.useCallback((a,h)=>{const{cx:r,cy:o,outer:x,inner:M,slices:w}=P,y=Math.hypot(a-r,h-o);if(y>x+Ct||y<M)return null;let _=Math.atan2(a-r,-(h-o));_<0&&(_+=Math.PI*2);const q=w.findIndex(L=>_>=L.start&&_<L.end);return q<0?null:q},[P]),p=a=>{const h=P.slices[a];return`${N(h.value)} (${$(h.share)})`};return l.jsx(ft,{label:t,description:s,containerRef:R,width:E,height:d,plot:j,overlay:a=>{const{cx:h,cy:r,outer:o,inner:x,slices:M}=P,w=M[a],y=(w.start+w.end)/2,_=tt(0,0,Ct,y);return l.jsx("path",{className:Nt.slice,d:Yt(h+_.x,r+_.y,o,x,w.start,w.end),style:{fill:Y(w.tone),strokeWidth:se}})},itemCount:P.slices.length,pick:u,tooltip:a=>{const h=P.slices[a];return{rows:[{id:h.id,label:h.label,value:p(a),tone:h.tone}]}},anchor:a=>{const{cx:h,cy:r,outer:o,slices:x}=P,M=x[a];return tt(h,r,o+Ct,(M.start+M.end)/2)},tooltipSide:"outward",announce:a=>`${P.slices[a].label}: ${p(a)}`,table:{columns:[t,m],rows:I.map(a=>[a.label,Number.isFinite(a.value)?N(a.value):"—"])},legend:{entries:I.map(a=>({id:a.id,label:a.label,tone:a.tone})),hidden:S,onToggle:a=>D(h=>{const r=new Set(h);return r.has(a)?r.delete(a):I.length-h.size>1&&r.add(a),r})},className:T,testId:C})},un=f.memo(at(hn,"PieChart")),Wt=(t,s,e,{top:n=12,right:c=16,bottom:i=28}={})=>{const m=Math.max(32,...e.map(ht))+10;return{left:m,top:n,right:Math.max(m+1,t-c),bottom:Math.max(n+1,s-i),width:Math.max(1,t-c-m),height:Math.max(1,s-n-i)}},vt=(t,s)=>Math.max(2,Math.floor(t/(s?90:48))),mn=(t,s=24)=>{const e=new Map,n=(c,i)=>`${c}:${i}`;return t.forEach((c,i)=>{if(!Number.isFinite(c.x)||!Number.isFinite(c.y))return;const m=n(Math.floor(c.x/s),Math.floor(c.y/s)),d=e.get(m);d?d.push(i):e.set(m,[i])}),{nearest:(c,i,m)=>{const d=Math.ceil(m/s),k=Math.floor(c/s),A=Math.floor(i/s);let T=null,C=m*m;for(let b=-d;b<=d;b+=1)for(let R=-d;R<=d;R+=1)for(const E of e.get(n(k+b,A+R))??[]){const S=(t[E].x-c)**2+(t[E].y-i)**2;S<=C&&(C=S,T=E)}return T}}},dn="ui-point-YKyMm",xn="ui-marker-ToO1T",oe={point:dn,marker:xn},bt={plain:4,min:3,max:16},fn=22,pn=({label:t,description:s,series:e,xLabel:n,yLabel:c,sizeLabel:i,height:m=300,width:d,formatX:k,formatY:A,className:T,testId:C})=>{const{labels:b}=dt.useUi(),[R,E]=yt(d),[S,D]=f.useState(()=>new Set),z=f.useMemo(()=>pt(b==null?void 0:b.locale),[b==null?void 0:b.locale]),N=f.useMemo(()=>At(b==null?void 0:b.locale),[b==null?void 0:b.locale]),I=k??z,P=A??z,$=f.useMemo(()=>e.map((r,o)=>({...r,tone:Tt(o,r.tone)})),[e]),j=f.useMemo(()=>$.filter(r=>!S.has(r.id)).flatMap(r=>r.data.filter(o=>Number.isFinite(o.x)&&Number.isFinite(o.y)).map(o=>({...o,series:r}))).sort((r,o)=>r.x-o.x||r.y-o.y),[$,S]),u=f.useMemo(()=>{const r=jt(...xt(j.map(G=>G.x))),o=jt(...xt(j.map(G=>G.y))),x=ot(o[0],o[1],vt(m,!1)),M=Wt(E,m,N(x),{right:20}),w=mt(r,[M.left,M.right]),y=mt(o,[M.bottom,M.top]),_=Ht(j.map(G=>G.size)),[q,L]=xt(_),W=G=>G===void 0||!Number.isFinite(G)||_.length===0?bt.plain:L===q?(bt.min+bt.max)/2:Math.sqrt(bt.min**2+(G-q)/(L-q)*(bt.max**2-bt.min**2)),U=j.map(G=>({...G,cx:w(G.x),cy:y(G.y),r:W(G.size)}));return{area:M,placed:U,index:mn(U.map(G=>({x:G.cx,y:G.cy}))),xTicks:wt(ot(r[0],r[1],vt(M.width,!0)),w,N),yTicks:wt(x,y,N)}},[j,E,m,N]),p=f.useMemo(()=>l.jsxs("g",{children:[l.jsx(ut,{area:u.area,ticks:u.yTicks,side:"left",hasGrid:!0}),l.jsx(ut,{area:u.area,ticks:u.xTicks,side:"bottom",hasGrid:!0}),u.placed.map((r,o)=>l.jsx("circle",{className:oe.point,cx:r.cx,cy:r.cy,r:r.r,style:{fill:`color-mix(in srgb, ${Y(r.series.tone)} 72%, transparent)`,stroke:Y(r.series.tone)}},o))]}),[u]),a=f.useCallback((r,o)=>u.index.nearest(r,o,fn),[u]),h=r=>{const o=u.placed[r];return{title:o.label??o.series.label,rows:[{id:"series",label:o.series.label,value:"",tone:o.series.tone},{id:"x",label:n,value:I(o.x)},{id:"y",label:c,value:P(o.y)},...o.size!==void 0&&i?[{id:"size",label:i,value:z(o.size)}]:[]]}};return l.jsx(ft,{label:t,description:s,containerRef:R,width:E,height:m,plot:p,overlay:r=>{const o=u.placed[r];return l.jsx("circle",{className:oe.marker,cx:o.cx,cy:o.cy,r:o.r+3,style:{stroke:Y(o.series.tone)}})},itemCount:u.placed.length,pick:a,tooltip:h,anchor:r=>({x:u.placed[r].cx,y:u.placed[r].cy}),announce:r=>{const o=u.placed[r];return`${o.label?`${o.label}, `:""}${o.series.label}: ${n} ${I(o.x)}, ${c} ${P(o.y)}`},table:{columns:[t,n,c],rows:j.map(r=>[r.label??r.series.label,I(r.x),P(r.y)])},legend:{entries:$.map(r=>({id:r.id,label:r.label,tone:r.tone})),hidden:S,onToggle:r=>D(o=>{const x=new Set(o);return x.has(r)?x.delete(r):$.length-o.size>1&&x.add(r),x})},className:T,testId:C})},yn=f.memo(at(pn,"ScatterPlot")),gn="ui-labels-MJWYF",bn="ui-empty-AW7c9",Mn="ui-focus-hLQdB",It={labels:gn,empty:bn,focus:Mn},zt=8,_n=28,qt=140,ae=(t,s,e)=>{var c;const n=(c=t[s])==null?void 0:c[e];return typeof n=="number"&&Number.isFinite(n)?n:null},ce=t=>t.map((s,e)=>String(e)),$n=({label:t,description:s,columns:e,rows:n,values:c,valueLabel:i,tone:m="chart-1",height:d=280,width:k,formatValue:A,className:T,testId:C})=>{const{labels:b}=dt.useUi(),[R,E]=yt(k),S=f.useMemo(()=>pt(b==null?void 0:b.locale),[b==null?void 0:b.locale]),D=A??S,z=`ui-heat-${f.useId().replace(/:/g,"")}`,N=f.useMemo(()=>{const p={left:Math.min(E*.3,Math.max(32,...n.map(ht))+12),top:8,right:E-8,bottom:d-28-_n},a=Rt(ce(e),[p.left,p.right],{paddingInner:.06,paddingOuter:0}),h=Rt(ce(n),[p.top,p.bottom],{paddingInner:.06,paddingOuter:0}),[r,o]=xt(Ht(c.flat())),x=w=>w===null?null:o===r?60:zt+(w-r)/(o-r)*(100-zt),M=n.flatMap((w,y)=>e.map((_,q)=>{const L=ae(c,y,q);return{row:w,column:_,key:`${y}:${q}`,value:L,x:a(String(q)),y:h(String(y)),width:a.bandwidth,height:h.bandwidth,mix:x(L)}}));return{area:p,x:a,y:h,cells:M,min:r,max:o}},[e,n,c,E,d]),I=Y(m),P=f.useMemo(()=>{const{area:u,x:p,y:a,cells:h}=N,r=D(N.max),o=u.right-ht(r)-8,x=he(e.map((M,w)=>({position:p(String(w))+p.bandwidth/2,label:M})));return l.jsxs("g",{children:[h.map(M=>l.jsx("rect",{className:M.mix===null?It.empty:void 0,x:M.x,y:M.y,width:M.width,height:M.height,rx:2,style:M.mix===null?void 0:{fill:`color-mix(in srgb, ${I} ${M.mix}%, ${Gt.cssVar("bg-surface")})`}},M.key)),l.jsxs("g",{"aria-hidden":!0,className:It.labels,children:[n.map((M,w)=>l.jsx("text",{x:u.left-8,y:a(String(w))+a.bandwidth/2,dy:"0.32em",textAnchor:"end",children:St(M,u.left-12)},w)),x.map(M=>l.jsx("text",{x:M.position,y:u.bottom+16,textAnchor:"middle",children:M.label},M.position))]}),l.jsx("defs",{children:l.jsxs("linearGradient",{id:z,children:[l.jsx("stop",{offset:"0%",style:{stopColor:`color-mix(in srgb, ${I} ${zt}%, ${Gt.cssVar("bg-surface")})`}}),l.jsx("stop",{offset:"100%",style:{stopColor:I}})]})}),l.jsxs("g",{"aria-hidden":!0,className:It.labels,children:[l.jsx("rect",{x:o-qt,y:d-18,width:qt,height:8,rx:4,style:{fill:`url(#${z})`}}),l.jsx("text",{x:o-qt-8,y:d-14,dy:"0.32em",textAnchor:"end",children:D(N.min)}),l.jsx("text",{x:u.right,y:d-14,dy:"0.32em",textAnchor:"end",children:r})]})]})},[N,e,n,I,z,d,D]),$=f.useCallback((u,p)=>{const{area:a,x:h,y:r}=N;if(u<a.left||u>a.right||p<a.top||p>a.bottom)return null;const o=h.indexAt(u),x=r.indexAt(p);return o<0||x<0?null:x*e.length+o},[N,e.length]),j=u=>{const p=N.cells[u];return{cell:p,value:p.value===null?"—":D(p.value)}};return l.jsx(ft,{label:t,description:s,containerRef:R,width:E,height:d,plot:P,overlay:u=>{const p=N.cells[u];return l.jsx("rect",{className:It.focus,x:p.x-1,y:p.y-1,width:p.width+2,height:p.height+2,rx:3})},itemCount:N.cells.length,columns:e.length,pick:$,tooltip:u=>{const{cell:p,value:a}=j(u);return{title:`${p.row} · ${p.column}`,rows:[{id:"value",label:i,value:a,tone:m}]}},anchor:u=>{const p=N.cells[u];return{x:p.x+p.width/2,y:p.y+p.height/2}},announce:u=>{const{cell:p,value:a}=j(u);return`${p.row}, ${p.column}: ${i} ${a}`},table:{columns:[t,...e],rows:n.map((u,p)=>[u,...e.map((a,h)=>{const r=ae(c,p,h);return r===null?"—":D(r)})])},className:T,testId:C})},wn=f.memo(at($n,"Heatmap")),jn="ui-box-7zEQ-",kn="ui-median-J5g6o",Nn="ui-outlier-M0VN-",vn="ui-band-kK09D",Ft={box:jn,median:kn,outlier:Nn,band:vn},Tn=({label:t,description:s,groups:e,groupLabel:n,labels:c,height:i=280,width:m,formatValue:d,className:k,testId:A})=>{const{labels:T}=dt.useUi(),[C,b]=yt(m),R=f.useMemo(()=>pt(T==null?void 0:T.locale),[T==null?void 0:T.locale]),E=f.useMemo(()=>At(T==null?void 0:T.locale),[T==null?void 0:T.locale]),S=d??R,D=f.useMemo(()=>e.map(($,j)=>({group:$,tone:Tt(j,$.tone),stats:$e($.values)})),[e]),z=f.useMemo(()=>{const $=D.flatMap(x=>x.stats?[x.stats.min,x.stats.max]:[]),[j,u]=$.length?xt($):[0,1],p=jt(j,u),a=ot(p[0],p[1],vt(i,!1)),h=Wt(b,i,E(a)),r=Rt(e.map(x=>x.id),[h.left,h.right],{paddingInner:.4,paddingOuter:.2}),o=mt(p,[h.bottom,h.top]);return{area:h,band:r,y:o,yTicks:wt(a,o,E),groupTicks:e.map(x=>({position:r(x.id)+r.bandwidth/2,label:x.label}))}},[D,e,b,i,E]),N=$=>[{id:"max",label:c.max,value:S($.whiskerHigh)},{id:"q3",label:c.q3,value:S($.q3)},{id:"median",label:c.median,value:S($.median)},{id:"q1",label:c.q1,value:S($.q1)},{id:"min",label:c.min,value:S($.whiskerLow)},...$.outliers.length>0?[{id:"outliers",label:c.outliers,value:R($.outliers.length)}]:[],{id:"count",label:c.count,value:R($.count)}],I=f.useMemo(()=>{const{area:$,band:j,y:u}=z;return l.jsxs("g",{children:[l.jsx(ut,{area:$,ticks:z.yTicks,side:"left",hasGrid:!0}),l.jsx(Ot,{area:$,ticks:z.groupTicks,side:"bottom"}),D.map(({group:p,tone:a,stats:h})=>{if(!h)return null;const r=j(p.id),o=r+j.bandwidth/2,x=j.bandwidth*.3,M=Y(a);return l.jsxs("g",{style:{stroke:M},className:Ft.box,children:[l.jsx("line",{x1:o,x2:o,y1:u(h.whiskerHigh),y2:u(h.q3)}),l.jsx("line",{x1:o,x2:o,y1:u(h.q1),y2:u(h.whiskerLow)}),l.jsx("line",{x1:o-x,x2:o+x,y1:u(h.whiskerHigh),y2:u(h.whiskerHigh)}),l.jsx("line",{x1:o-x,x2:o+x,y1:u(h.whiskerLow),y2:u(h.whiskerLow)}),l.jsx("rect",{x:r,width:j.bandwidth,y:u(h.q3),height:Math.max(1,u(h.q1)-u(h.q3)),rx:2,style:{fill:`color-mix(in srgb, ${M} 22%, transparent)`}}),l.jsx("line",{className:Ft.median,x1:r,x2:r+j.bandwidth,y1:u(h.median),y2:u(h.median)}),h.outliers.map((w,y)=>l.jsx("circle",{className:Ft.outlier,cx:o,cy:u(w),r:3},y))]},p.id)})]})},[z,D]),P=f.useCallback(($,j)=>{const{area:u,band:p}=z;if($<u.left||$>u.right||j<u.top-4||j>u.bottom+4)return null;const a=p.indexAt($);return a<0?null:a},[z]);return l.jsx(ft,{label:t,description:s,containerRef:C,width:b,height:i,plot:I,underlay:$=>{const{area:j,band:u}=z,p=u.step*.2;return l.jsx("rect",{className:Ft.band,x:u(e[$].id)-p,width:u.bandwidth+p*2,y:j.top,height:j.height})},overlay:()=>null,itemCount:e.length,pick:P,tooltip:$=>{const j=D[$];return{title:j.group.label,rows:j.stats?N(j.stats).map(u=>({...u,tone:u.id==="median"?j.tone:void 0})):[]}},anchor:$=>{const j=D[$],{band:u,y:p}=z;return{x:u(j.group.id)+u.bandwidth/2,y:j.stats?p(j.stats.q3):z.area.bottom}},announce:$=>{const j=D[$];return j.stats?`${j.group.label}: ${N(j.stats).map(u=>`${u.label} ${u.value}`).join(", ")}`:j.group.label},table:{columns:[n,c.min,c.q1,c.median,c.q3,c.max,c.count],rows:D.map(({group:$,stats:j})=>j?[$.label,S(j.whiskerLow),S(j.q1),S(j.median),S(j.q3),S(j.whiskerHigh),R(j.count)]:[$.label,"—","—","—","—","—","0"])},className:k,testId:A})},An=f.memo(at(Tn,"BoxPlot")),Cn="ui-baseline-wWs7h",In="ui-band-xvYtL",re={baseline:Cn,band:In},Mt=1,Fn=({label:t,description:s,values:e,bins:n,valueLabel:c,countLabel:i,tone:m="chart-1",height:d=260,width:k,formatValue:A,className:T,testId:C})=>{const{labels:b}=dt.useUi(),[R,E]=yt(k),S=f.useMemo(()=>pt(b==null?void 0:b.locale),[b==null?void 0:b.locale]),D=f.useMemo(()=>At(b==null?void 0:b.locale),[b==null?void 0:b.locale]),z=A??S,N=f.useMemo(()=>we(e,n),[e,n]),I=f.useMemo(()=>{var w,y;const u=Math.max(1,...N.map(_=>_.count)),p=jt(0,u),a=ot(0,p[1],vt(d,!1)).filter(Number.isInteger),h=Wt(E,d,D(a)),r=((w=N[0])==null?void 0:w.from)??0,o=((y=N[N.length-1])==null?void 0:y.to)??1,x=mt([r,o],[h.left,h.right]),M=mt(p,[h.bottom,h.top]);return{area:h,columns:N.map(_=>({x:x(_.from)+Mt/2,width:Math.max(1,x(_.to)-x(_.from)-Mt),y:M(_.count),height:Math.max(0,h.bottom-M(_.count)),center:(x(_.from)+x(_.to))/2})),xTicks:wt(ot(r,o,vt(h.width,!0)),x,D),yTicks:wt(a,M,D)}},[N,E,d,D]),P=u=>`${z(N[u].from)} – ${z(N[u].to)}`,$=f.useMemo(()=>l.jsxs("g",{children:[l.jsx(ut,{area:I.area,ticks:I.yTicks,side:"left",hasGrid:!0}),l.jsx(ut,{area:I.area,ticks:I.xTicks,side:"bottom"}),l.jsx("line",{className:re.baseline,x1:I.area.left,x2:I.area.right,y1:I.area.bottom,y2:I.area.bottom}),I.columns.map((u,p)=>u.height>0?l.jsx("rect",{x:u.x,y:u.y,width:u.width,height:u.height,style:{fill:Y(m)}},p):null)]}),[I,m]),j=f.useCallback((u,p)=>{const{area:a,columns:h}=I;if(u<a.left||u>a.right||p<a.top-4||p>a.bottom+4)return null;const r=h.findIndex(o=>u>=o.x-Mt&&u<=o.x+o.width+Mt);return r<0?null:r},[I]);return l.jsx(ft,{label:t,description:s,containerRef:R,width:E,height:d,plot:$,underlay:u=>{const p=I.columns[u];return l.jsx("rect",{className:re.band,x:p.x-Mt/2,width:p.width+Mt,y:I.area.top,height:I.area.height})},overlay:()=>null,itemCount:N.length,pick:j,tooltip:u=>({title:P(u),rows:[{id:"count",label:i,value:S(N[u].count),tone:m}]}),anchor:u=>({x:I.columns[u].center,y:I.columns[u].y}),announce:u=>`${c} ${P(u)}: ${i} ${S(N[u].count)}`,table:{columns:[c,i],rows:N.map((u,p)=>[P(p),S(u.count)])},className:T,testId:C})},Rn=f.memo(at(Fn,"Histogram")),Sn="ui-grid-fHioN",Ln="ui-shape-Vbb9D",Hn="ui-labels-nRfEk",En="ui-axisLabel-UOZQ7",Pn="ui-spoke-P-6cp",zn="ui-marker-xzn9h",_t={grid:Sn,shape:Ln,labels:Hn,axisLabel:En,spoke:Pn,marker:zn},le=10,qn=16,Dn=28,Dt=(t,s)=>{const e=t.values[s];return typeof e=="number"&&Number.isFinite(e)?e:null},Gn=({label:t,description:s,axes:e,series:n,max:c,height:i=320,width:m,formatValue:d,className:k,testId:A})=>{const{labels:T}=dt.useUi(),[C,b]=yt(m),[R,E]=f.useState(()=>new Set),S=f.useMemo(()=>At(T==null?void 0:T.locale),[T==null?void 0:T.locale]),D=f.useMemo(()=>pt(T==null?void 0:T.locale),[T==null?void 0:T.locale]),z=d??D,N=f.useMemo(()=>n.map((a,h)=>({...a,tone:Tt(h,a.tone)})),[n]),I=f.useMemo(()=>N.filter(a=>!R.has(a.id)),[N,R]),P=f.useMemo(()=>{const a=e.length,h=a>0?Math.PI*2/a:0,r=e.map((W,U)=>U*h),o=Math.min(b*.22,Math.max(0,...e.map(W=>ht(W.label)))),x=Math.max(24,Math.min(i/2-24,b/2-o-le-4)),M=b/2,w=i/2;let y=0;for(const W of n)for(const U of e){const G=Dt(W,U.key);G!==null&&G>y&&(y=G)}const _=c!==void 0&&c>0?c:jt(0,y,4)[1],q=ot(0,_,4).filter(W=>W>0);return{cx:M,cy:w,radius:x,angles:r,step:h,top:_,rings:q,scale:W=>Math.min(Math.max(W,0),_)/_*x,labelRoom:o}},[e,n,c,b,i]),$=f.useMemo(()=>{const{cx:a,cy:h,angles:r,scale:o}=P;return I.map(x=>({...x,points:e.map((M,w)=>{const y=Dt(x,M.key);return{...tt(a,h,o(y??0),r[w]),value:y}})}))},[P,I,e]),j=f.useMemo(()=>{const{cx:a,cy:h,radius:r,angles:o,rings:x,scale:M,labelRoom:w}=P,y=x.length>0?M(x[0]):r,_=Math.max(1,Math.ceil(qn/Math.max(1,y))),q=S(x);return l.jsxs("g",{children:[l.jsxs("g",{"aria-hidden":!0,className:_t.grid,children:[x.map(L=>l.jsx("path",{d:Zt(o.map(W=>tt(a,h,M(L),W)))},L)),o.map((L,W)=>{const U=tt(a,h,r,L);return l.jsx("line",{x1:a,y1:h,x2:U.x,y2:U.y},e[W].key)})]}),$.map(L=>l.jsx("path",{className:_t.shape,d:Zt(L.points),style:{fill:`color-mix(in srgb, ${Y(L.tone)} 14%, transparent)`,stroke:Y(L.tone)}},L.id)),l.jsxs("g",{"aria-hidden":!0,className:_t.labels,children:[x.map((L,W)=>(x.length-1-W)%_===0?l.jsx("text",{x:a+4,y:h-M(L),dy:"1.1em",children:q[W]},L):null),e.map((L,W)=>{const U=o[W],G=tt(a,h,r+le,U),g=Math.sin(U),F=Math.cos(U),H=g>.3?"start":g<-.3?"end":"middle",X=F>.3?"-0.2em":F<-.3?"0.9em":"0.32em";return l.jsx("text",{className:_t.axisLabel,x:G.x,y:G.y,dy:X,textAnchor:H,children:St(L.label,H==="middle"?r*1.4:w)},L.key)})]})]})},[P,$,e,S]),u=f.useCallback((a,h)=>{const{cx:r,cy:o,radius:x,step:M}=P;if(e.length===0||Math.hypot(a-r,h-o)>x+Dn)return null;let w=Math.atan2(a-r,-(h-o));return w<0&&(w+=Math.PI*2),Math.round(w/M)%e.length},[P,e.length]),p=a=>$.map(h=>{const r=h.points[a].value;return{id:h.id,label:h.label,value:r===null?"—":z(r),tone:h.tone}});return l.jsx(ft,{label:t,description:s,containerRef:C,width:b,height:i,plot:j,overlay:a=>{const{cx:h,cy:r,radius:o,angles:x}=P,M=tt(h,r,o,x[a]);return l.jsxs("g",{children:[l.jsx("line",{className:_t.spoke,x1:h,y1:r,x2:M.x,y2:M.y}),$.map(w=>{const y=w.points[a];return y.value===null?null:l.jsx("circle",{className:_t.marker,cx:y.x,cy:y.y,r:4.5,style:{fill:Y(w.tone)}},w.id)})]})},itemCount:e.length,pick:u,tooltip:a=>({title:e[a].label,rows:p(a)}),anchor:a=>{const{cx:h,cy:r,radius:o,angles:x}=P;let M=0;for(const w of $){const y=w.points[a];M=Math.max(M,Math.hypot(y.x-h,y.y-r))}return tt(h,r,Math.min(o,M),x[a])},tooltipSide:"outward",announce:a=>`${e[a].label}: ${p(a).map(h=>`${h.label} ${h.value}`).join(", ")}`,table:{columns:[t,...N.map(a=>a.label)],rows:e.map(a=>[a.label,...N.map(h=>{const r=Dt(h,a.key);return r===null?"—":z(r)})])},legend:N.length>1?{entries:N.map(a=>({id:a.id,label:a.label,tone:a.tone})),hidden:R,onToggle:a=>E(h=>{const r=new Set(h);return r.has(a)?r.delete(a):N.length-h.size>1&&r.add(a),r})}:void 0,className:k,testId:A})},On=f.memo(at(Gn,"RadarChart"));exports.AreaChart=en;exports.BarChart=sn;exports.BoxPlot=An;exports.ComposedChart=an;exports.Heatmap=wn;exports.Histogram=Rn;exports.LineChart=Ke;exports.PieChart=un;exports.RadarChart=On;exports.ScatterPlot=yn;
|
|
2
|
+
//# sourceMappingURL=charts.cjs.map
|