@konstructio/ui 0.1.2-alpha.105 → 0.1.2-alpha.107
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +118 -31
- package/dist/{AdditionalOptions-D0BAS2HG.js → AdditionalOptions-Crcnz0_g.js} +1 -1
- package/dist/{AlertDialogTrigger-BGo_acd5.js → AlertDialogTrigger-ouMGAlJW.js} +39 -39
- package/dist/{Breadcrumb-Cp3abB2w.js → Breadcrumb-MrF1Z6w2.js} +3 -3
- package/dist/{Checkbox-B_ngk9Dj.js → Checkbox-8KnRLpQG.js} +60 -61
- package/dist/{CommandInput-BLq69pOT.js → CommandInput-CGnqfudl.js} +4 -4
- package/dist/{Counter-BV680M5r.js → Counter-CDXdP1Af.js} +3 -3
- package/dist/{DayPicker-kweJz134.js → DayPicker-C22j0Y-u.js} +539 -518
- package/dist/{DropdownButton-DfNojmCW.js → DropdownButton-D4QlKGg7.js} +7 -7
- package/dist/{FlagSelectorList-CkTR3j6O.js → FlagSelectorList-tYZNl-tz.js} +31 -24
- package/dist/{HamburgerTrigger-DRylBL2d.js → HamburgerTrigger-B_NGSZ2r.js} +20 -20
- package/dist/{ImageUpload-DiwymQcU.js → ImageUpload-D7HKSXK8.js} +71 -66
- package/dist/Input-is8n7emP.js +195 -0
- package/dist/{Loading-DUh9PMJN.js → Loading-DO8JOWBV.js} +1 -1
- package/dist/{Modal-Dyn088X7.js → Modal-Dq9BHD_9.js} +4 -4
- package/dist/{Spinner-CUwE2bLm.js → Spinner-BJE79VTl.js} +1 -1
- package/dist/{StepIndicatorContent-CjbjVjS1.js → StepIndicatorContent-BGDvxLzV.js} +1 -1
- package/dist/Switch-C7286Bcu.js +199 -0
- package/dist/{Toast-3NEz7LLa.js → Toast-jSx3Lao8.js} +8 -7
- package/dist/Wrapper-2AUlYAHQ.js +195 -0
- package/dist/{Wrapper-CVJSuYWx.js → Wrapper-CyHxGs4E.js} +4 -4
- package/dist/{Wrapper-DP6Sxngx.js → Wrapper-a7RVCcrn.js} +248 -242
- package/dist/components/Alert/Alert.js +2 -2
- package/dist/components/AlertDialog/AlertDialog.js +2 -2
- package/dist/components/AlertDialog/components/AlertDialogTrigger.js +1 -1
- package/dist/components/AlertDialog/components/index.js +1 -1
- package/dist/components/Autocomplete/Autocomplete.js +1 -1
- package/dist/components/Autocomplete/components/List/List.js +1 -1
- package/dist/components/Autocomplete/hooks/useAutocomplete.js +27 -25
- package/dist/components/Autocomplete/hooks/useNavigationList.js +2 -3
- package/dist/components/Badge/Badge.js +2 -2
- package/dist/components/Breadcrumb/Breadcrumb.js +1 -1
- package/dist/components/Breadcrumb/components/BackButton/BackButton.js +2 -2
- package/dist/components/Breadcrumb/components/Item/Item.js +2 -2
- package/dist/components/Breadcrumb/hooks/useBreadcrumb.js +1 -1
- package/dist/components/Button/Button.js +1 -1
- package/dist/components/ButtonGroup/ButtonGroup.js +65 -60
- package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.js +2 -2
- package/dist/components/ButtonGroup/components/ButtonGroupLabel/ButtonGroupLabel.js +10 -9
- package/dist/components/ButtonGroup/components/ButtonGroupMessage/ButtonGroupMessage.js +8 -6
- package/dist/components/Card/Card.js +25 -22
- package/dist/components/Checkbox/Checkbox.js +1 -1
- package/dist/components/Command/Command.js +2 -2
- package/dist/components/Command/components/Command.js +1 -1
- package/dist/components/Command/components/CommandEmpty.js +1 -1
- package/dist/components/Command/components/CommandGroup.js +2 -2
- package/dist/components/Command/components/CommandInput.js +1 -1
- package/dist/components/Command/components/CommandItem.js +2 -2
- package/dist/components/Command/components/CommandList.js +2 -2
- package/dist/components/Command/components/CommandSeparator.js +2 -2
- package/dist/components/Command/components/CommandShortcut.js +1 -1
- package/dist/components/Command/components/DialogContent.js +3 -3
- package/dist/components/Command/components/DialogOverlay.js +2 -2
- package/dist/components/Command/components/index.js +1 -1
- package/dist/components/Counter/Counter.js +1 -1
- package/dist/components/DateRangePicker/DateRangePicker.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/components/CalendarDivider/CalendarDivider.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/components/CalendarMonth/CalendarMonth.js +3 -3
- package/dist/components/DateRangePicker/components/CalendarPanel/components/IndependentModeCalendar/IndependentModeCalendar.js +3 -3
- package/dist/components/DateRangePicker/components/CalendarPanel/components/NavigationButton/NavigationButton.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/components/TogetherModeCalendar/TogetherModeCalendar.js +2 -2
- package/dist/components/DateRangePicker/components/CalendarPanel/constants/dayPickerClassNames.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/constants/index.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/hooks/index.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/hooks/useIndependentCarousel.js +30 -28
- package/dist/components/DateRangePicker/components/CalendarPanel/hooks/useTogetherCarousel.js +23 -21
- package/dist/components/DateRangePicker/components/CalendarPanel/utils/index.js +1 -1
- package/dist/components/DateRangePicker/components/DateTimeInputs/DateTimeInputs.js +1 -1
- package/dist/components/DateRangePicker/components/DateTimeInputs/components/EndInputFields/EndInputFields.js +48 -41
- package/dist/components/DateRangePicker/components/DateTimeInputs/components/StartInputFields/StartInputFields.js +48 -41
- package/dist/components/DateRangePicker/components/PresetPanel/PresetPanel.js +1 -1
- package/dist/components/Datepicker/DatePicker.js +2 -2
- package/dist/components/Divider/Divider.js +7 -7
- package/dist/components/Drawer/Drawer.js +28 -26
- package/dist/components/Drawer/components/Body/Body.js +1 -1
- package/dist/components/Drawer/components/Footer/Footer.js +1 -1
- package/dist/components/Drawer/components/Header/Header.js +1 -1
- package/dist/components/DropdownButton/DropdownButton.js +1 -1
- package/dist/components/Filter/Filter.js +1 -1
- package/dist/components/Filter/components/BadgeDropdown/BadgeMultiSelect.hook.js +51 -36
- package/dist/components/Filter/components/BadgeDropdown/BadgeMultiSelect.js +40 -38
- package/dist/components/Filter/components/DateFilterDropdown/DateFilterDropdown.hook.js +1 -1
- package/dist/components/Filter/components/DateFilterDropdown/DateFilterDropdown.js +1 -1
- package/dist/components/Filter/components/DateRangeFilterDropdown/DateRangeFilterDropdown.hook.js +1 -1
- package/dist/components/Filter/components/DateRangeFilterDropdown/DateRangeFilterDropdown.js +1 -1
- package/dist/components/Filter/components/FilterDropdown/FilterDropdown.js +2 -2
- package/dist/components/Filter/components/ResetButton/ResetButton.js +1 -1
- package/dist/components/Filter/components/TextMultiSelect/TextMultiSelect.js +43 -41
- package/dist/components/Filter/components/TimeFilterDropdown/TimeFilterDropdown.js +1 -1
- package/dist/components/Filter/utils/index.js +1 -1
- package/dist/components/ImageUpload/ImageUpload.js +1 -1
- package/dist/components/Input/Input.js +1 -1
- package/dist/components/LineChart/LineChart.js +2 -2
- package/dist/components/Loading/Loading.js +1 -1
- package/dist/components/Modal/Modal.js +1 -1
- package/dist/components/Modal/components/Body/Body.js +1 -1
- package/dist/components/Modal/components/Footer/Footer.js +1 -1
- package/dist/components/Modal/components/Header/Header.js +1 -1
- package/dist/components/Modal/components/Wrapper/Wrapper.js +1 -1
- package/dist/components/Modal/components/index.js +1 -1
- package/dist/components/MultiSelectDropdown/MultiSelectDropdown.js +1 -1
- package/dist/components/MultiSelectDropdown/components/Item/Item.js +1 -1
- package/dist/components/MultiSelectDropdown/components/List/List.js +1 -1
- package/dist/components/MultiSelectDropdown/components/Wrapper/Wrapper.js +1 -1
- package/dist/components/MultiSelectDropdown/components/index.js +1 -1
- package/dist/components/MultiSelectDropdown/contexts/MultiSelectDropdown.context.js +4 -3
- package/dist/components/MultiSelectDropdown/contexts/MultiSelectDropdown.provider.js +17 -16
- package/dist/components/MultiSelectDropdown/hooks/useMultiSelectDropdown.js +11 -11
- package/dist/components/PhoneNumberInput/PhoneNumberInput.js +2 -2
- package/dist/components/PhoneNumberInput/components/FlagContent/FlagContent.js +1 -1
- package/dist/components/PhoneNumberInput/components/FlagSelectorList/FlagSelectorList.js +1 -1
- package/dist/components/PhoneNumberInput/components/FlagSelectorWrapper/FlagSelectorWrapper.js +3 -3
- package/dist/components/PhoneNumberInput/components/TruncateText/TruncateText.js +3 -3
- package/dist/components/PhoneNumberInput/components/Wrapper.js +1 -1
- package/dist/components/PhoneNumberInput/components/index.js +2 -2
- package/dist/components/PhoneNumberInput/contexts/index.js +1 -1
- package/dist/components/PhoneNumberInput/contexts/phone-number.provider.js +1 -1
- package/dist/components/PhoneNumberInput/utils/index.js +1 -1
- package/dist/components/PieChart/PieChart.js +31 -28
- package/dist/components/ProgressBar/ProgressBar.js +1 -1
- package/dist/components/Radio/Radio.js +1 -1
- package/dist/components/RadioCard/RadioCard.js +1 -1
- package/dist/components/RadioCardGroup/RadioCardGroup.js +1 -1
- package/dist/components/RadioGroup/RadioGroup.js +1 -1
- package/dist/components/Range/Range.js +2 -2
- package/dist/components/Select/Select.js +43 -36
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.js +1 -1
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.variants.js +1 -1
- package/dist/components/Select/components/List/List.js +78 -67
- package/dist/components/Select/components/ListItem/ListItem.js +1 -1
- package/dist/components/Select/components/Wrapper.js +1 -1
- package/dist/components/Select/components/index.js +2 -2
- package/dist/components/Select/hooks/useNavigationList.js +2 -3
- package/dist/components/Select/hooks/useSelect.js +8 -8
- package/dist/components/Sidebar/components/CollapseTrigger/CollapseTrigger.js +1 -1
- package/dist/components/Sidebar/components/Footer/Footer.js +1 -1
- package/dist/components/Sidebar/components/HamburgerTrigger/HamburgerTrigger.js +1 -1
- package/dist/components/Sidebar/components/Label/Label.js +1 -1
- package/dist/components/Sidebar/components/Logo/Logo.js +1 -1
- package/dist/components/Sidebar/components/Navigation/Navigation.js +1 -1
- package/dist/components/Sidebar/components/NavigationGroup/NavigationGroup.js +1 -1
- package/dist/components/Sidebar/components/NavigationOption/NavigationOption.js +2 -2
- package/dist/components/Sidebar/components/NavigationSeparator/NavigationSeparator.js +1 -1
- package/dist/components/Sidebar/components/NavigationTitle/NavigationTitle.js +1 -1
- package/dist/components/Sidebar/components/Wrapper/Wrapper.js +25 -24
- package/dist/components/Sidebar/components/index.js +1 -1
- package/dist/components/Slider/Slider.js +2 -2
- package/dist/components/Spinner/Spinner.js +1 -1
- package/dist/components/Stepper/Stepper.js +1 -1
- package/dist/components/Stepper/components/HorizontalStepItem/HorizontalStepItem.js +2 -2
- package/dist/components/Stepper/components/StepConnector/StepConnector.js +1 -1
- package/dist/components/Stepper/components/StepIndicatorContent/StepIndicatorContent.js +1 -1
- package/dist/components/Stepper/components/VerticalStepItem/VerticalStepItem.js +2 -2
- package/dist/components/Switch/Switch.js +1 -1
- package/dist/components/Switch/Switch.variants.js +15 -7
- package/dist/components/Table/Table.js +1 -1
- package/dist/components/Table/components/Body.js +1 -1
- package/dist/components/Table/components/Filter.js +1 -1
- package/dist/components/Table/components/Head.js +1 -1
- package/dist/components/Table/components/Row.js +1 -1
- package/dist/components/Tabs/Tabs.js +2 -2
- package/dist/components/Tabs/components/Content.js +2 -2
- package/dist/components/Tabs/components/List.js +2 -2
- package/dist/components/Tabs/components/Trigger.js +2 -2
- package/dist/components/Tag/Tag.js +8 -8
- package/dist/components/TagSelect/TagSelect.js +1 -1
- package/dist/components/TagSelect/components/Item/Item.js +1 -1
- package/dist/components/TagSelect/components/List/List.js +1 -1
- package/dist/components/TagSelect/components/Wrapper/Wrapper.js +1 -1
- package/dist/components/TagSelect/components/index.js +1 -1
- package/dist/components/TagSelect/hooks/useTagSelect.js +11 -11
- package/dist/components/TextArea/TextArea.js +71 -26
- package/dist/components/TextArea/TextArea.variants.js +49 -13
- package/dist/components/TimePicker/components/HoursList/HoursList.js +1 -1
- package/dist/components/TimePicker/components/MeridianList/MeridianList.js +1 -1
- package/dist/components/TimePicker/components/MinutesList/MinutesList.js +1 -1
- package/dist/components/TimePicker/components/Wrapper/Wrapper.js +114 -99
- package/dist/components/TimePicker/components/WrapperList/WrapperList.js +19 -18
- package/dist/components/Toast/Toast.js +1 -1
- package/dist/components/Tooltip/Tooltip.js +2 -2
- package/dist/components/Typography/Typography.js +19 -16
- package/dist/components/VirtualizedTable/VirtualizedTable.js +2 -2
- package/dist/components/VirtualizedTable/components/Actions/Actions.js +1 -1
- package/dist/components/VirtualizedTable/components/Body/Body.js +2 -2
- package/dist/components/VirtualizedTable/components/DotPaginate/DotPaginate.js +1 -1
- package/dist/components/VirtualizedTable/components/DropdownPaginate/DropdownPaginate.js +2 -2
- package/dist/components/VirtualizedTable/components/ExpandableRow/ExpandableRow.js +1 -1
- package/dist/components/VirtualizedTable/components/Filter/Filter.js +4 -4
- package/dist/components/VirtualizedTable/components/FormPaginate/FormPaginate.js +1 -1
- package/dist/components/VirtualizedTable/components/Header/Header.js +2 -2
- package/dist/components/VirtualizedTable/components/Pagination/Pagination.js +1 -1
- package/dist/components/VirtualizedTable/components/Skeleton/Skeleton.js +1 -1
- package/dist/components/VirtualizedTable/components/TruncateText/TruncateText.js +3 -3
- package/dist/components/VirtualizedTable/components/WrapperBody/WrapperBody.js +1 -1
- package/dist/components/VirtualizedTable/contexts/index.js +1 -1
- package/dist/components/VirtualizedTable/contexts/table.provider.js +1 -1
- package/dist/components/index.js +12 -12
- package/dist/{components-Cf345jTv.js → components-CaEW5ge4.js} +32 -32
- package/dist/{constants-CxJJRVK3.js → constants-HQIXhj2t.js} +2 -2
- package/dist/contexts/index.js +1 -1
- package/dist/contexts/theme.provider.js +1 -1
- package/dist/{debounce-C5Ycjilj.js → debounce-BdyZeJQk.js} +2 -2
- package/dist/{dist-DFCz63oC2.js → dist-9WbMf_jT.js} +158 -159
- package/dist/{dist-tGUUcv8n.js → dist-AxOGvL82.js} +114 -115
- package/dist/{dist-DDck_2lb.js → dist-BIBFLVt1.js} +117 -116
- package/dist/{dist-BZNE2Tnx.js → dist-BbX4Nrk2.js} +1 -1
- package/dist/{dist-BaPW7qXd2.js → dist-BnCbAI-c.js} +1 -1
- package/dist/{dist-BdobXn93.js → dist-CszFjHAP.js} +2 -2
- package/dist/{dist-C3YVLapk.js → dist-DO3apbIh.js} +24 -24
- package/dist/{dist-CzKqHuqJ2.js → dist-DwxO2RoR.js} +38 -38
- package/dist/{dist-AihTpWdF.js → dist-iUAHw-3y.js} +272 -272
- package/dist/{dist-BlPTJNIm.js → dist-pxvIAJzo.js} +2 -2
- package/dist/es2015-B_07N-UL.js +796 -0
- package/dist/hooks/useMediaQuery.js +1 -1
- package/dist/index.js +14 -14
- package/dist/{isObject-BeFFiVJK.js → isObject-pLoSfdr0.js} +1 -1
- package/dist/lib/components/ButtonGroup/components/ButtonGroupLabel/ButtonGroupLabel.types.d.ts +1 -1
- package/dist/lib/components/ButtonGroup/components/ButtonGroupMessage/ButtonGroupMessage.types.d.ts +2 -0
- package/dist/lib/components/Card/Card.types.d.ts +1 -0
- package/dist/lib/components/Checkbox/Checkbox.d.ts +1 -1
- package/dist/lib/components/Checkbox/Checkbox.types.d.ts +2 -1
- package/dist/lib/components/DateRangePicker/components/DateTimeInputs/components/EndInputFields/EndInputFields.types.d.ts +1 -0
- package/dist/lib/components/DateRangePicker/components/DateTimeInputs/components/StartInputFields/StartInputFields.types.d.ts +1 -0
- package/dist/lib/components/Divider/Divider.d.ts +3 -2
- package/dist/lib/components/Divider/Divider.types.d.ts +4 -0
- package/dist/lib/components/Input/Input.types.d.ts +4 -0
- package/dist/lib/components/MultiSelectDropdown/MultiSelectDropdown.types.d.ts +2 -0
- package/dist/lib/components/MultiSelectDropdown/contexts/MultiSelectDropdown.types.d.ts +2 -0
- package/dist/lib/components/Select/Select.types.d.ts +2 -0
- package/dist/lib/components/Select/components/List/List.types.d.ts +3 -0
- package/dist/lib/components/Select/components/Wrapper.d.ts +2 -0
- package/dist/lib/components/Sidebar/Sidebar.types.d.ts +2 -0
- package/dist/lib/components/Sidebar/components/HamburgerTrigger/HamburgerTrigger.types.d.ts +2 -0
- package/dist/lib/components/Switch/Switch.variants.d.ts +3 -1
- package/dist/lib/components/Tag/Tag.types.d.ts +1 -0
- package/dist/lib/components/TextArea/TextArea.d.ts +6 -0
- package/dist/lib/components/TextArea/TextArea.types.d.ts +13 -2
- package/dist/lib/components/TextArea/TextArea.variants.d.ts +4 -1
- package/dist/lib/components/TimePicker/TimePicker.types.d.ts +4 -0
- package/dist/lib/components/TimePicker/components/WrapperList/WrapperList.types.d.ts +1 -0
- package/dist/lib/utils/index.d.ts +1 -0
- package/dist/{libphonenumber-hGupNnJu.js → libphonenumber-BMq3Thej.js} +356 -347
- package/dist/package.json +27 -27
- package/dist/{phone-number.provider-BxQCTxp8.js → phone-number.provider-Dkq_p1Gi.js} +2 -2
- package/dist/{prop-types-CfEYxTbR.js → prop-types-BCUW56rg.js} +1 -1
- package/dist/{react-CvUtBTMg.js → react-7zQ6bvbE.js} +837 -828
- package/dist/{rolldown-runtime-Ck3dxwZt.js → rolldown-runtime-Dw9YIBcH.js} +1 -1
- package/dist/styles.css +1 -1
- package/dist/{table.provider-B0BafHuU.js → table.provider-CWzODR1t.js} +96 -96
- package/dist/{theme.provider-Dw4O3ocC.js → theme.provider-CSL1WCYG.js} +1 -1
- package/dist/{useBreadcrumb-DYfZL_2p.js → useBreadcrumb-Ds_9BeFz.js} +7 -6
- package/dist/utils/index.js +6 -5
- package/dist/{utils-Cx-WzRZF.js → utils-B-6R7kNE.js} +8 -4
- package/dist/{utils-B-BTGYA5.js → utils-DVYdP0CJ.js} +2 -3
- package/dist/{x-BI9jmc7e.js → x-Ierxf0uI.js} +2 -2
- package/package.json +27 -27
- package/dist/Input-Cf44DzfE.js +0 -188
- package/dist/Switch-aPhL5rNG.js +0 -196
- package/dist/Wrapper-R8fik3ah.js +0 -182
- package/dist/es2015-DigR3dar.js +0 -795
- /package/dist/{dist-DGOjiAnB2.js → dist-DGOjiAnB.js} +0 -0
- /package/dist/{dist-pWlMx4Fi2.js → dist-pWlMx4Fi.js} +0 -0
- /package/dist/{x-a_LpoXzG2.js → x-a_LpoXzG.js} +0 -0
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
import { a as D } from "./dist-xCbHbMLA.js";
|
|
2
2
|
import { t as B } from "./dist-CCdbu9GU.js";
|
|
3
|
-
import { i as
|
|
4
|
-
import { t as
|
|
5
|
-
import { t as
|
|
6
|
-
import { t as
|
|
3
|
+
import { i as Pe, r as T, t as Re } from "./dist-D-yS0HN8.js";
|
|
4
|
+
import { t as _e } from "./dist-pWlMx4Fi.js";
|
|
5
|
+
import { t as xe } from "./dist-DwxO2RoR.js";
|
|
6
|
+
import { t as Ee } from "./dist-DGOjiAnB.js";
|
|
7
7
|
import * as u from "react";
|
|
8
|
-
import { Fragment as
|
|
9
|
-
var
|
|
8
|
+
import { Fragment as ye, jsx as h, jsxs as Ce } from "react/jsx-runtime";
|
|
9
|
+
var Me = Object.defineProperty, Te = (t, e) => Me(t, "name", {
|
|
10
10
|
value: e,
|
|
11
11
|
configurable: !0
|
|
12
12
|
});
|
|
13
13
|
function j(t, [e, r]) {
|
|
14
14
|
return Math.min(r, Math.max(e, t));
|
|
15
15
|
}
|
|
16
|
-
|
|
17
|
-
var
|
|
16
|
+
Te(j, "clamp");
|
|
17
|
+
var De = Object.defineProperty, Ve = (t, e) => De(t, "name", {
|
|
18
18
|
value: e,
|
|
19
19
|
configurable: !0
|
|
20
20
|
});
|
|
21
|
-
function
|
|
21
|
+
function ne(t) {
|
|
22
22
|
const e = u.useRef({
|
|
23
23
|
value: t,
|
|
24
24
|
previous: t
|
|
25
25
|
});
|
|
26
26
|
return u.useMemo(() => (e.current.value !== t && (e.current.previous = e.current.value, e.current.value = t), e.current.previous), [t]);
|
|
27
27
|
}
|
|
28
|
-
|
|
29
|
-
var
|
|
28
|
+
Ve(ne, "usePrevious");
|
|
29
|
+
var Ie = Object.defineProperty, c = (t, e) => Ie(t, "name", {
|
|
30
30
|
value: e,
|
|
31
31
|
configurable: !0
|
|
32
|
-
}),
|
|
32
|
+
}), re = ["PageUp", "PageDown"], oe = [
|
|
33
33
|
"ArrowUp",
|
|
34
34
|
"ArrowDown",
|
|
35
35
|
"ArrowLeft",
|
|
36
36
|
"ArrowRight"
|
|
37
|
-
],
|
|
37
|
+
], ie = {
|
|
38
38
|
"from-left": [
|
|
39
39
|
"Home",
|
|
40
40
|
"PageDown",
|
|
@@ -59,32 +59,32 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
59
59
|
"ArrowUp",
|
|
60
60
|
"ArrowLeft"
|
|
61
61
|
]
|
|
62
|
-
}, A = "Slider", [U,
|
|
63
|
-
const { name: o, min: i = 0, max: n = 100, step: l = 1, orientation: s = "horizontal", disabled: d = !1, minStepsBetweenThumbs: f = 0, defaultValue:
|
|
62
|
+
}, A = "Slider", [U, Be, Ae] = xe(A), [Y, Je] = Pe(A, [Ae]), [Ke, K] = Y(A), Qe = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
63
|
+
const { name: o, min: i = 0, max: n = 100, step: l = 1, orientation: s = "horizontal", disabled: d = !1, minStepsBetweenThumbs: f = 0, defaultValue: S = [i], value: p, onValueChange: a = /* @__PURE__ */ c(() => {
|
|
64
64
|
}, "onValueChange"), onValueCommit: m = /* @__PURE__ */ c(() => {
|
|
65
|
-
}, "onValueCommit"), inverted: P = !1, form: g, ...v } = e, w = u.useRef(/* @__PURE__ */ new Set()), R = u.useRef(0), x = u.useRef(!1), E = s === "horizontal" ?
|
|
65
|
+
}, "onValueCommit"), inverted: P = !1, form: g, ...v } = e, w = u.useRef(/* @__PURE__ */ new Set()), R = u.useRef(0), x = u.useRef(!1), E = s === "horizontal" ? Fe : Ne, [_, O] = u.useState(null), be = D(r, O), [y = [], k] = Re({
|
|
66
66
|
prop: p,
|
|
67
|
-
defaultProp:
|
|
67
|
+
defaultProp: S,
|
|
68
68
|
onChange: /* @__PURE__ */ c((b) => {
|
|
69
69
|
[...w.current][R.current]?.focus({
|
|
70
70
|
preventScroll: !0,
|
|
71
71
|
focusVisible: x.current
|
|
72
72
|
}), x.current = !1, a(b);
|
|
73
73
|
}, "onChange")
|
|
74
|
-
}), W = u.useRef(y),
|
|
74
|
+
}), W = u.useRef(y), we = u.useRef(y);
|
|
75
75
|
u.useEffect(() => {
|
|
76
76
|
const b = g ? _?.ownerDocument.getElementById(g) : _?.closest("form");
|
|
77
77
|
if (b instanceof HTMLFormElement) {
|
|
78
|
-
const M = /* @__PURE__ */ c(() =>
|
|
78
|
+
const M = /* @__PURE__ */ c(() => k(we.current), "reset");
|
|
79
79
|
return b.addEventListener("reset", M), () => b.removeEventListener("reset", M);
|
|
80
80
|
}
|
|
81
81
|
}, [
|
|
82
82
|
_,
|
|
83
83
|
g,
|
|
84
|
-
|
|
84
|
+
k
|
|
85
85
|
]);
|
|
86
86
|
function q(b) {
|
|
87
|
-
C(b,
|
|
87
|
+
C(b, me(y, b));
|
|
88
88
|
}
|
|
89
89
|
c(q, "handleSlideStart");
|
|
90
90
|
function J(b) {
|
|
@@ -95,18 +95,18 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
95
95
|
String(y) !== String(W.current) && m(y);
|
|
96
96
|
}
|
|
97
97
|
c(Q, "handleSlideEnd");
|
|
98
|
-
function C(b, M, { commit:
|
|
99
|
-
const F = X(l),
|
|
100
|
-
|
|
101
|
-
const V =
|
|
102
|
-
if (
|
|
103
|
-
R.current = V.indexOf(
|
|
104
|
-
const
|
|
105
|
-
return
|
|
106
|
-
} else return
|
|
98
|
+
function C(b, M, { commit: z } = { commit: !1 }) {
|
|
99
|
+
const F = X(l), L = I(Math.round((b - i) / l) * l + i, F), Z = j(L, [i, n]);
|
|
100
|
+
k((N = []) => {
|
|
101
|
+
const V = de(N, Z, M);
|
|
102
|
+
if (pe(V, f * l)) {
|
|
103
|
+
R.current = V.indexOf(Z);
|
|
104
|
+
const ee = String(V) !== String(N);
|
|
105
|
+
return ee && z && m(V), ee ? V : N;
|
|
106
|
+
} else return N;
|
|
107
107
|
});
|
|
108
108
|
}
|
|
109
|
-
return c(C, "updateValues"), /* @__PURE__ */
|
|
109
|
+
return c(C, "updateValues"), /* @__PURE__ */ h(Ke, {
|
|
110
110
|
scope: e.__scopeSlider,
|
|
111
111
|
name: o,
|
|
112
112
|
disabled: d,
|
|
@@ -117,15 +117,15 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
117
117
|
values: y,
|
|
118
118
|
orientation: s,
|
|
119
119
|
form: g,
|
|
120
|
-
children: /* @__PURE__ */
|
|
120
|
+
children: /* @__PURE__ */ h(U.Provider, {
|
|
121
121
|
scope: e.__scopeSlider,
|
|
122
|
-
children: /* @__PURE__ */
|
|
122
|
+
children: /* @__PURE__ */ h(U.Slot, {
|
|
123
123
|
scope: e.__scopeSlider,
|
|
124
|
-
children: /* @__PURE__ */
|
|
124
|
+
children: /* @__PURE__ */ h(E, {
|
|
125
125
|
"aria-disabled": d,
|
|
126
126
|
"data-disabled": d ? "" : void 0,
|
|
127
127
|
...v,
|
|
128
|
-
ref:
|
|
128
|
+
ref: be,
|
|
129
129
|
onPointerDown: T(v.onPointerDown, () => {
|
|
130
130
|
d || (W.current = y, x.current = !1);
|
|
131
131
|
}),
|
|
@@ -144,12 +144,12 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
144
144
|
onStepKeyDown: ({ event: b, direction: M }) => {
|
|
145
145
|
if (!d) {
|
|
146
146
|
x.current = !0;
|
|
147
|
-
const
|
|
148
|
-
C(
|
|
147
|
+
const z = re.includes(b.key) || b.shiftKey && oe.includes(b.key) ? 10 : 1, F = R.current, L = y[F];
|
|
148
|
+
C(ge(L, {
|
|
149
149
|
min: i,
|
|
150
150
|
step: l,
|
|
151
151
|
direction: M,
|
|
152
|
-
multiplier:
|
|
152
|
+
multiplier: z
|
|
153
153
|
}), F, { commit: !0 });
|
|
154
154
|
}
|
|
155
155
|
}
|
|
@@ -157,24 +157,24 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
157
157
|
})
|
|
158
158
|
})
|
|
159
159
|
});
|
|
160
|
-
}, "Slider")), [
|
|
160
|
+
}, "Slider")), [ae, se] = Y(A, {
|
|
161
161
|
startEdge: "left",
|
|
162
162
|
endEdge: "right",
|
|
163
163
|
size: "width",
|
|
164
164
|
direction: 1
|
|
165
|
-
}),
|
|
166
|
-
const { min: o, max: i, dir: n, inverted: l, onSlideStart: s, onSlideMove: d, onSlideEnd: f, onStepKeyDown:
|
|
165
|
+
}), Fe = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
166
|
+
const { min: o, max: i, dir: n, inverted: l, onSlideStart: s, onSlideMove: d, onSlideEnd: f, onStepKeyDown: S, ...p } = e, [a, m] = u.useState(null), P = D(r, m), g = u.useRef(void 0), v = Ee(n), w = v === "ltr", R = w && !l || !w && l;
|
|
167
167
|
function x(E) {
|
|
168
|
-
const _ = g.current || a.getBoundingClientRect(),
|
|
169
|
-
return g.current = _,
|
|
168
|
+
const _ = g.current || a.getBoundingClientRect(), O = H([0, _.width], R ? [o, i] : [i, o]);
|
|
169
|
+
return g.current = _, O(E - _.left);
|
|
170
170
|
}
|
|
171
|
-
return c(x, "getValueFromPointer"), /* @__PURE__ */
|
|
171
|
+
return c(x, "getValueFromPointer"), /* @__PURE__ */ h(ae, {
|
|
172
172
|
scope: e.__scopeSlider,
|
|
173
173
|
startEdge: R ? "left" : "right",
|
|
174
174
|
endEdge: R ? "right" : "left",
|
|
175
175
|
direction: R ? 1 : -1,
|
|
176
176
|
size: "width",
|
|
177
|
-
children: /* @__PURE__ */
|
|
177
|
+
children: /* @__PURE__ */ h(le, {
|
|
178
178
|
dir: v,
|
|
179
179
|
"data-orientation": "horizontal",
|
|
180
180
|
...p,
|
|
@@ -195,32 +195,32 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
195
195
|
g.current = void 0, f?.();
|
|
196
196
|
},
|
|
197
197
|
onStepKeyDown: (E) => {
|
|
198
|
-
const _ =
|
|
199
|
-
|
|
198
|
+
const _ = ie[R ? "from-left" : "from-right"].includes(E.key);
|
|
199
|
+
S?.({
|
|
200
200
|
event: E,
|
|
201
201
|
direction: _ ? -1 : 1
|
|
202
202
|
});
|
|
203
203
|
}
|
|
204
204
|
})
|
|
205
205
|
});
|
|
206
|
-
}, "SliderHorizontal")),
|
|
207
|
-
const { min: o, max: i, inverted: n, onSlideStart: l, onSlideMove: s, onSlideEnd: d, onStepKeyDown: f, ...
|
|
206
|
+
}, "SliderHorizontal")), Ne = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
207
|
+
const { min: o, max: i, inverted: n, onSlideStart: l, onSlideMove: s, onSlideEnd: d, onStepKeyDown: f, ...S } = e, p = u.useRef(null), a = D(r, p), m = u.useRef(void 0), P = !n;
|
|
208
208
|
function g(v) {
|
|
209
|
-
const w = m.current || p.current.getBoundingClientRect(), R =
|
|
209
|
+
const w = m.current || p.current.getBoundingClientRect(), R = H([0, w.height], P ? [i, o] : [o, i]);
|
|
210
210
|
return m.current = w, R(v - w.top);
|
|
211
211
|
}
|
|
212
|
-
return c(g, "getValueFromPointer"), /* @__PURE__ */
|
|
212
|
+
return c(g, "getValueFromPointer"), /* @__PURE__ */ h(ae, {
|
|
213
213
|
scope: e.__scopeSlider,
|
|
214
214
|
startEdge: P ? "bottom" : "top",
|
|
215
215
|
endEdge: P ? "top" : "bottom",
|
|
216
216
|
size: "height",
|
|
217
217
|
direction: P ? 1 : -1,
|
|
218
|
-
children: /* @__PURE__ */
|
|
218
|
+
children: /* @__PURE__ */ h(le, {
|
|
219
219
|
"data-orientation": "vertical",
|
|
220
|
-
...
|
|
220
|
+
...S,
|
|
221
221
|
ref: a,
|
|
222
222
|
style: {
|
|
223
|
-
...
|
|
223
|
+
...S.style,
|
|
224
224
|
"--radix-slider-thumb-transform": "translateY(50%)"
|
|
225
225
|
},
|
|
226
226
|
onSlideStart: (v) => {
|
|
@@ -235,7 +235,7 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
235
235
|
m.current = void 0, d?.();
|
|
236
236
|
},
|
|
237
237
|
onStepKeyDown: (v) => {
|
|
238
|
-
const w =
|
|
238
|
+
const w = ie[P ? "from-bottom" : "from-top"].includes(v.key);
|
|
239
239
|
f?.({
|
|
240
240
|
event: v,
|
|
241
241
|
direction: w ? -1 : 1
|
|
@@ -243,13 +243,13 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
243
243
|
}
|
|
244
244
|
})
|
|
245
245
|
});
|
|
246
|
-
}, "SliderVertical")),
|
|
247
|
-
const { __scopeSlider: o, onSlideStart: i, onSlideMove: n, onSlideEnd: l, onHomeKeyDown: s, onEndKeyDown: d, onStepKeyDown: f, ...
|
|
248
|
-
return /* @__PURE__ */
|
|
249
|
-
...
|
|
246
|
+
}, "SliderVertical")), le = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
247
|
+
const { __scopeSlider: o, onSlideStart: i, onSlideMove: n, onSlideEnd: l, onHomeKeyDown: s, onEndKeyDown: d, onStepKeyDown: f, ...S } = e, p = K(A, o);
|
|
248
|
+
return /* @__PURE__ */ h(B.span, {
|
|
249
|
+
...S,
|
|
250
250
|
ref: r,
|
|
251
251
|
onKeyDown: T(e.onKeyDown, (a) => {
|
|
252
|
-
a.key === "Home" ? (s(a), a.preventDefault()) : a.key === "End" ? (d(a), a.preventDefault()) :
|
|
252
|
+
a.key === "Home" ? (s(a), a.preventDefault()) : a.key === "End" ? (d(a), a.preventDefault()) : re.concat(oe).includes(a.key) && (f(a), a.preventDefault());
|
|
253
253
|
}),
|
|
254
254
|
onPointerDown: T(e.onPointerDown, (a) => {
|
|
255
255
|
const m = a.target;
|
|
@@ -266,30 +266,30 @@ var Ve = Object.defineProperty, c = (t, e) => Ve(t, "name", {
|
|
|
266
266
|
m.hasPointerCapture(a.pointerId) && (m.releasePointerCapture(a.pointerId), l(a));
|
|
267
267
|
})
|
|
268
268
|
});
|
|
269
|
-
}, "SliderImpl")),
|
|
270
|
-
const { __scopeSlider: o, ...i } = e, n = K(
|
|
271
|
-
return /* @__PURE__ */
|
|
269
|
+
}, "SliderImpl")), He = "SliderTrack", Ze = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
270
|
+
const { __scopeSlider: o, ...i } = e, n = K(He, o);
|
|
271
|
+
return /* @__PURE__ */ h(B.span, {
|
|
272
272
|
"data-disabled": n.disabled ? "" : void 0,
|
|
273
273
|
"data-orientation": n.orientation,
|
|
274
274
|
...i,
|
|
275
275
|
ref: r
|
|
276
276
|
});
|
|
277
|
-
}, "SliderTrack")),
|
|
278
|
-
const { __scopeSlider: o, ...i } = e, n = K(
|
|
279
|
-
return /* @__PURE__ */
|
|
277
|
+
}, "SliderTrack")), te = "SliderRange", et = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
278
|
+
const { __scopeSlider: o, ...i } = e, n = K(te, o), l = se(te, o), s = u.useRef(null), d = D(r, s), f = n.values.length, S = n.values.map((m) => G(m, n.min, n.max)), p = f > 1 ? Math.min(...S) : 0, a = 100 - Math.max(...S);
|
|
279
|
+
return /* @__PURE__ */ h(B.span, {
|
|
280
280
|
"data-orientation": n.orientation,
|
|
281
281
|
"data-disabled": n.disabled ? "" : void 0,
|
|
282
282
|
...i,
|
|
283
|
-
ref:
|
|
283
|
+
ref: d,
|
|
284
284
|
style: {
|
|
285
285
|
...e.style,
|
|
286
|
-
[l.startEdge]:
|
|
287
|
-
[l.endEdge]:
|
|
286
|
+
[l.startEdge]: p + "%",
|
|
287
|
+
[l.endEdge]: a + "%"
|
|
288
288
|
}
|
|
289
289
|
});
|
|
290
|
-
}, "SliderRange")), [
|
|
291
|
-
function
|
|
292
|
-
const { __scopeSlider: e, name: r, children: o, internal_do_not_use_render: i } = t, n = K(
|
|
290
|
+
}, "SliderRange")), [Oe, ce] = Y("SliderThumb"), ke = "SliderThumbProvider";
|
|
291
|
+
function ue(t) {
|
|
292
|
+
const { __scopeSlider: e, name: r, children: o, internal_do_not_use_render: i } = t, n = K(ke, e), l = Be(e), [s, d] = u.useState(null), f = u.useMemo(() => s ? l().findIndex((v) => v.ref.current === s) : -1, [l, s]), S = _e(s), p = s ? !!n.form || !!s.closest("form") : !0, a = n.values[f], m = r ?? (n.name ? n.name + (n.values.length > 1 ? "[]" : "") : void 0), P = a === void 0 ? 0 : G(a, n.min, n.max);
|
|
293
293
|
u.useEffect(() => {
|
|
294
294
|
if (s)
|
|
295
295
|
return n.thumbs.add(s), () => {
|
|
@@ -305,26 +305,26 @@ function ce(t) {
|
|
|
305
305
|
thumb: s,
|
|
306
306
|
onThumbChange: d,
|
|
307
307
|
percent: P,
|
|
308
|
-
size:
|
|
308
|
+
size: S
|
|
309
309
|
};
|
|
310
|
-
return /* @__PURE__ */
|
|
310
|
+
return /* @__PURE__ */ h(Oe, {
|
|
311
311
|
scope: e,
|
|
312
312
|
...g,
|
|
313
|
-
children:
|
|
313
|
+
children: ve(i) ? i(g) : o
|
|
314
314
|
});
|
|
315
315
|
}
|
|
316
|
-
c(
|
|
317
|
-
var $ = "SliderThumbTrigger",
|
|
318
|
-
const { __scopeSlider: o, ...i } = e, n = K($, o), l =
|
|
319
|
-
return /* @__PURE__ */
|
|
316
|
+
c(ue, "SliderThumbProvider");
|
|
317
|
+
var $ = "SliderThumbTrigger", ze = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
318
|
+
const { __scopeSlider: o, ...i } = e, n = K($, o), l = se($, o), { index: s, value: d, percent: f, size: S, onThumbChange: p } = ce($, o), a = D(r, p), m = fe(s, n.values.length), P = S?.[l.size], g = P ? Se(P, f, l.direction) : 0;
|
|
319
|
+
return /* @__PURE__ */ h("span", {
|
|
320
320
|
style: {
|
|
321
321
|
transform: "var(--radix-slider-thumb-transform)",
|
|
322
322
|
position: "absolute",
|
|
323
323
|
[l.startEdge]: `calc(${f}% + ${g}px)`
|
|
324
324
|
},
|
|
325
|
-
children: /* @__PURE__ */
|
|
325
|
+
children: /* @__PURE__ */ h(U.ItemSlot, {
|
|
326
326
|
scope: o,
|
|
327
|
-
children: /* @__PURE__ */
|
|
327
|
+
children: /* @__PURE__ */ h(B.span, {
|
|
328
328
|
role: "slider",
|
|
329
329
|
"aria-label": e["aria-label"] || m,
|
|
330
330
|
"aria-valuemin": n.min,
|
|
@@ -343,28 +343,28 @@ var $ = "SliderThumbTrigger", ke = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */
|
|
|
343
343
|
})
|
|
344
344
|
})
|
|
345
345
|
});
|
|
346
|
-
}, "SliderThumbTrigger")),
|
|
346
|
+
}, "SliderThumbTrigger")), tt = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function(e, r) {
|
|
347
347
|
const { __scopeSlider: o, name: i, ...n } = e;
|
|
348
|
-
return /* @__PURE__ */
|
|
348
|
+
return /* @__PURE__ */ h(ue, {
|
|
349
349
|
__scopeSlider: o,
|
|
350
350
|
name: i,
|
|
351
|
-
internal_do_not_use_render: ({ index: l, isFormControl: s }) => /* @__PURE__ */ ye
|
|
351
|
+
internal_do_not_use_render: ({ index: l, isFormControl: s }) => /* @__PURE__ */ Ce(ye, { children: [/* @__PURE__ */ h(ze, {
|
|
352
352
|
...n,
|
|
353
353
|
ref: r,
|
|
354
354
|
__scopeSlider: o
|
|
355
|
-
}), s ? /* @__PURE__ */
|
|
355
|
+
}), s ? /* @__PURE__ */ h($e, { __scopeSlider: o }, l) : null] })
|
|
356
356
|
});
|
|
357
|
-
}, "SliderThumb")),
|
|
358
|
-
const { value: i, name: n, form: l } =
|
|
357
|
+
}, "SliderThumb")), Le = "SliderBubbleInput", $e = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */ c(function({ __scopeSlider: e, ...r }, o) {
|
|
358
|
+
const { value: i, name: n, form: l } = ce(Le, e), s = u.useRef(null), d = D(s, o), f = ne(i);
|
|
359
359
|
return u.useEffect(() => {
|
|
360
|
-
const
|
|
361
|
-
if (!
|
|
360
|
+
const S = s.current;
|
|
361
|
+
if (!S) return;
|
|
362
362
|
const p = window.HTMLInputElement.prototype, a = Object.getOwnPropertyDescriptor(p, "value").set;
|
|
363
363
|
if (f !== i && a) {
|
|
364
364
|
const m = new Event("input", { bubbles: !0 });
|
|
365
|
-
a.call(
|
|
365
|
+
a.call(S, i), S.dispatchEvent(m);
|
|
366
366
|
}
|
|
367
|
-
}, [f, i]), /* @__PURE__ */
|
|
367
|
+
}, [f, i]), /* @__PURE__ */ h(B.input, {
|
|
368
368
|
style: { display: "none" },
|
|
369
369
|
name: n,
|
|
370
370
|
form: l,
|
|
@@ -373,50 +373,51 @@ var $ = "SliderThumbTrigger", ke = /* @__PURE__ */ u.forwardRef(/* @__PURE__ */
|
|
|
373
373
|
defaultValue: i
|
|
374
374
|
});
|
|
375
375
|
}, "SliderBubbleInput"));
|
|
376
|
-
function
|
|
376
|
+
function de(t = [], e, r) {
|
|
377
377
|
const o = [...t];
|
|
378
378
|
return o[r] = e, o.sort((i, n) => i - n);
|
|
379
379
|
}
|
|
380
|
-
c(
|
|
380
|
+
c(de, "getNextSortedValues");
|
|
381
381
|
function G(t, e, r) {
|
|
382
|
-
|
|
382
|
+
const o = 100 / (r - e) * (t - e);
|
|
383
|
+
return j(o, [0, 100]);
|
|
383
384
|
}
|
|
384
385
|
c(G, "convertValueToPercentage");
|
|
385
|
-
function
|
|
386
|
+
function fe(t, e) {
|
|
386
387
|
return e > 2 ? `Value ${t + 1} of ${e}` : e === 2 ? ["Minimum", "Maximum"][t] : void 0;
|
|
387
388
|
}
|
|
388
|
-
c(
|
|
389
|
-
function
|
|
389
|
+
c(fe, "getLabel");
|
|
390
|
+
function me(t, e) {
|
|
390
391
|
if (t.length === 1) return 0;
|
|
391
392
|
const r = t.map((i) => Math.abs(i - e)), o = Math.min(...r);
|
|
392
393
|
return r.indexOf(o);
|
|
393
394
|
}
|
|
394
|
-
c(
|
|
395
|
-
function
|
|
395
|
+
c(me, "getClosestValueIndex");
|
|
396
|
+
function Se(t, e, r) {
|
|
396
397
|
const o = t / 2;
|
|
397
|
-
return (o -
|
|
398
|
+
return (o - H([0, 50], [0, o])(e) * r) * r;
|
|
398
399
|
}
|
|
399
|
-
c(
|
|
400
|
-
function
|
|
400
|
+
c(Se, "getThumbInBoundsOffset");
|
|
401
|
+
function he(t) {
|
|
401
402
|
return t.slice(0, -1).map((e, r) => t[r + 1] - e);
|
|
402
403
|
}
|
|
403
|
-
c(
|
|
404
|
-
function
|
|
404
|
+
c(he, "getStepsBetweenValues");
|
|
405
|
+
function pe(t, e) {
|
|
405
406
|
if (e > 0) {
|
|
406
|
-
const r =
|
|
407
|
+
const r = he(t);
|
|
407
408
|
return Math.min(...r) >= e;
|
|
408
409
|
}
|
|
409
410
|
return !0;
|
|
410
411
|
}
|
|
411
|
-
c(
|
|
412
|
-
function
|
|
412
|
+
c(pe, "hasMinStepsBetweenValues");
|
|
413
|
+
function H(t, e) {
|
|
413
414
|
return (r) => {
|
|
414
415
|
if (t[0] === t[1] || e[0] === e[1]) return e[0];
|
|
415
416
|
const o = (e[1] - e[0]) / (t[1] - t[0]);
|
|
416
417
|
return e[0] + o * (r - t[0]);
|
|
417
418
|
};
|
|
418
419
|
}
|
|
419
|
-
c(
|
|
420
|
+
c(H, "linearScale");
|
|
420
421
|
function X(t) {
|
|
421
422
|
if (!Number.isFinite(t)) return 0;
|
|
422
423
|
const e = t.toString();
|
|
@@ -433,19 +434,19 @@ function I(t, e) {
|
|
|
433
434
|
return Math.round(t * r) / r;
|
|
434
435
|
}
|
|
435
436
|
c(I, "roundValue");
|
|
436
|
-
function
|
|
437
|
+
function ge(t, { min: e, step: r, direction: o, multiplier: i }) {
|
|
437
438
|
const n = X(r), l = (t - e) / r, s = Math.round(l), d = I(s * r + e, n) === I(t, n);
|
|
438
439
|
let f;
|
|
439
440
|
return d ? f = s + i * o : o > 0 ? f = Math.ceil(l) : f = Math.floor(l), I(f * r + e, n);
|
|
440
441
|
}
|
|
441
|
-
c(
|
|
442
|
-
function
|
|
442
|
+
c(ge, "getNextStepValue");
|
|
443
|
+
function ve(t) {
|
|
443
444
|
return typeof t == "function";
|
|
444
445
|
}
|
|
445
|
-
c(
|
|
446
|
+
c(ve, "isFunction");
|
|
446
447
|
export {
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
448
|
+
Ze as i,
|
|
449
|
+
et as n,
|
|
450
|
+
tt as r,
|
|
451
|
+
Qe as t
|
|
451
452
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { i as j } from "./dist-xCbHbMLA.js";
|
|
2
2
|
import { t as R } from "./dist-CCdbu9GU.js";
|
|
3
3
|
import { t as q } from "./dist-DYIabsrY.js";
|
|
4
|
-
import { a as Ee, o as ke, r as Se, t as Ie } from "./dist-
|
|
4
|
+
import { a as Ee, o as ke, r as Se, t as Ie } from "./dist-DO3apbIh.js";
|
|
5
5
|
import * as n from "react";
|
|
6
6
|
var ce = 1, xe = 0.9, Ce = 0.8, Re = 0.17, Y = 0.1, Q = 0.999, Ae = 0.9999, Me = 0.99, $e = /[\\\/_+.#"@\[\(\{&]/, De = /[\\\/_+.#"@\[\(\{&]/g, Fe = /[\s-]/, fe = /[\s-]/g;
|
|
7
7
|
function _(t, l, r, f, u, c, d) {
|
|
@@ -7,7 +7,7 @@ import { n as N, r as $, t as G } from "./es2015-CoHq2g4y.js";
|
|
|
7
7
|
import { t as L } from "./dist-C4j75TwZ.js";
|
|
8
8
|
import { t as A } from "./dist-BUocnzkM.js";
|
|
9
9
|
import { t as j } from "./Combination-CnMM05mt.js";
|
|
10
|
-
import { a as b, i as H, r as K, t as U } from "./dist-
|
|
10
|
+
import { a as b, i as H, r as K, t as U } from "./dist-9WbMf_jT.js";
|
|
11
11
|
import * as i from "react";
|
|
12
12
|
import { jsx as s } from "react/jsx-runtime";
|
|
13
13
|
var V = Object.defineProperty, l = (p, e) => V(p, "name", {
|
|
@@ -3,8 +3,8 @@ import { t as L } from "./dist-CCdbu9GU.js";
|
|
|
3
3
|
import { i as Q, n as W, r as F, t as X } from "./dist-D-yS0HN8.js";
|
|
4
4
|
import { t as Z } from "./dist-DYIabsrY.js";
|
|
5
5
|
import { t as ee } from "./dist-D5XYRjmR.js";
|
|
6
|
-
import { t as te } from "./dist-
|
|
7
|
-
import { t as oe } from "./dist-
|
|
6
|
+
import { t as te } from "./dist-DwxO2RoR.js";
|
|
7
|
+
import { t as oe } from "./dist-DGOjiAnB.js";
|
|
8
8
|
import * as r from "react";
|
|
9
9
|
import { jsx as m } from "react/jsx-runtime";
|
|
10
10
|
var re = Object.defineProperty, O = (t, e) => re(t, "name", {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as R, n as
|
|
1
|
+
import { a as R, n as w } from "./dist-xCbHbMLA.js";
|
|
2
2
|
import { t as D } from "./dist-CCdbu9GU.js";
|
|
3
3
|
import { i as N, n as h, r as d, t as L } from "./dist-D-yS0HN8.js";
|
|
4
4
|
import { t as m } from "./dist-DYIabsrY.js";
|
|
@@ -9,30 +9,30 @@ import { t as P } from "./dist-BUocnzkM.js";
|
|
|
9
9
|
import { t as U } from "./Combination-CnMM05mt.js";
|
|
10
10
|
import * as i from "react";
|
|
11
11
|
import { Fragment as V, jsx as s } from "react/jsx-runtime";
|
|
12
|
-
var Y = Object.defineProperty, u = (
|
|
12
|
+
var Y = Object.defineProperty, u = (c, o) => Y(c, "name", {
|
|
13
13
|
value: o,
|
|
14
14
|
configurable: !0
|
|
15
|
-
}), O = "Dialog", [E, ge] = N(O), [Z, g] = E(O), de = /* @__PURE__ */ u((
|
|
16
|
-
const { __scopeDialog: o, children: a, open: n, defaultOpen: r, onOpenChange: t, modal: e = !0 } =
|
|
15
|
+
}), O = "Dialog", [E, ge] = N(O), [Z, g] = E(O), de = /* @__PURE__ */ u((c) => {
|
|
16
|
+
const { __scopeDialog: o, children: a, open: n, defaultOpen: r, onOpenChange: t, modal: e = !0 } = c, l = i.useRef(null), f = i.useRef(null), [x, C] = L({
|
|
17
17
|
prop: n,
|
|
18
18
|
defaultProp: r ?? !1,
|
|
19
19
|
onChange: t,
|
|
20
20
|
caller: O
|
|
21
|
-
}), [T,
|
|
21
|
+
}), [T, b] = i.useState(0), [A, F] = i.useState(0);
|
|
22
22
|
return /* @__PURE__ */ s(Z, {
|
|
23
23
|
scope: o,
|
|
24
|
-
triggerRef:
|
|
24
|
+
triggerRef: l,
|
|
25
25
|
contentRef: f,
|
|
26
26
|
contentId: m(),
|
|
27
27
|
titleId: m(),
|
|
28
28
|
descriptionId: m(),
|
|
29
29
|
titlePresent: T > 0,
|
|
30
|
-
descriptionPresent:
|
|
31
|
-
setTitleCount:
|
|
30
|
+
descriptionPresent: A > 0,
|
|
31
|
+
setTitleCount: b,
|
|
32
32
|
setDescriptionCount: F,
|
|
33
33
|
open: x,
|
|
34
34
|
onOpenChange: C,
|
|
35
|
-
onOpenToggle: i.useCallback(() => C((
|
|
35
|
+
onOpenToggle: i.useCallback(() => C((S) => !S), [C]),
|
|
36
36
|
modal: e,
|
|
37
37
|
children: a
|
|
38
38
|
});
|
|
@@ -48,8 +48,8 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
48
48
|
ref: e,
|
|
49
49
|
onClick: d(o.onClick, t.onOpenToggle)
|
|
50
50
|
});
|
|
51
|
-
}, "DialogTrigger")), I = "DialogPortal", [z, y] = E(I, { forceMount: void 0 }), De = /* @__PURE__ */ u((
|
|
52
|
-
const { __scopeDialog: o, forceMount: a, children: n, container: r } =
|
|
51
|
+
}, "DialogTrigger")), I = "DialogPortal", [z, y] = E(I, { forceMount: void 0 }), De = /* @__PURE__ */ u((c) => {
|
|
52
|
+
const { __scopeDialog: o, forceMount: a, children: n, container: r } = c, t = g(I, o);
|
|
53
53
|
return /* @__PURE__ */ s(z, {
|
|
54
54
|
scope: o,
|
|
55
55
|
forceMount: a,
|
|
@@ -71,8 +71,8 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
71
71
|
ref: a
|
|
72
72
|
})
|
|
73
73
|
}) : null;
|
|
74
|
-
}, "DialogOverlay")), B =
|
|
75
|
-
const { __scopeDialog: n, ...r } = o, t = g(_, n), e = R(a,
|
|
74
|
+
}, "DialogOverlay")), B = w("DialogOverlay.RemoveScroll"), J = /* @__PURE__ */ i.forwardRef(/* @__PURE__ */ u(function(o, a) {
|
|
75
|
+
const { __scopeDialog: n, ...r } = o, t = g(_, n), e = k(), l = R(a, e);
|
|
76
76
|
return /* @__PURE__ */ s(U, {
|
|
77
77
|
as: B,
|
|
78
78
|
allowPinchZoom: !0,
|
|
@@ -80,7 +80,7 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
80
80
|
children: /* @__PURE__ */ s(D.div, {
|
|
81
81
|
"data-state": v(t.open),
|
|
82
82
|
...r,
|
|
83
|
-
ref:
|
|
83
|
+
ref: l,
|
|
84
84
|
style: {
|
|
85
85
|
pointerEvents: "auto",
|
|
86
86
|
...r.style
|
|
@@ -113,8 +113,8 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
113
113
|
e.preventDefault(), n.triggerRef.current?.focus();
|
|
114
114
|
}),
|
|
115
115
|
onPointerDownOutside: d(o.onPointerDownOutside, (e) => {
|
|
116
|
-
const
|
|
117
|
-
(
|
|
116
|
+
const l = e.detail.originalEvent, f = l.button === 0 && l.ctrlKey === !0;
|
|
117
|
+
(l.button === 2 || f) && e.preventDefault();
|
|
118
118
|
}),
|
|
119
119
|
onFocusOutside: d(o.onFocusOutside, (e) => e.preventDefault())
|
|
120
120
|
});
|
|
@@ -130,12 +130,12 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
130
130
|
},
|
|
131
131
|
onInteractOutside: (e) => {
|
|
132
132
|
o.onInteractOutside?.(e), e.defaultPrevented || (r.current = !0, e.detail.originalEvent.type === "pointerdown" && (t.current = !0));
|
|
133
|
-
const
|
|
134
|
-
n.triggerRef.current?.contains(
|
|
133
|
+
const l = e.target;
|
|
134
|
+
n.triggerRef.current?.contains(l) && e.preventDefault(), e.detail.originalEvent.type === "focusin" && t.current && e.preventDefault();
|
|
135
135
|
}
|
|
136
136
|
});
|
|
137
137
|
}, "DialogContentNonModal")), M = /* @__PURE__ */ i.forwardRef(/* @__PURE__ */ u(function(o, a) {
|
|
138
|
-
const { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: t, onCloseAutoFocus: e, ...
|
|
138
|
+
const { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: t, onCloseAutoFocus: e, ...l } = o, f = g(p, n);
|
|
139
139
|
return $(), /* @__PURE__ */ s(V, { children: /* @__PURE__ */ s(j, {
|
|
140
140
|
asChild: !0,
|
|
141
141
|
loop: !0,
|
|
@@ -148,7 +148,7 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
148
148
|
"aria-describedby": f.descriptionPresent ? f.descriptionId : void 0,
|
|
149
149
|
"aria-labelledby": f.titlePresent ? f.titleId : void 0,
|
|
150
150
|
"data-state": v(f.open),
|
|
151
|
-
...
|
|
151
|
+
...l,
|
|
152
152
|
ref: a,
|
|
153
153
|
deferPointerDownOutside: !0,
|
|
154
154
|
onDismiss: () => f.onOpenChange(!1)
|
|
@@ -156,14 +156,14 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
156
156
|
}) });
|
|
157
157
|
}, "DialogContentImpl")), X = "DialogTitle", me = /* @__PURE__ */ i.forwardRef(/* @__PURE__ */ u(function(o, a) {
|
|
158
158
|
const { __scopeDialog: n, ...r } = o, t = g(X, n), { setTitleCount: e } = t;
|
|
159
|
-
return h(() => (e((
|
|
159
|
+
return h(() => (e((l) => l + 1), () => e((l) => l - 1)), [e]), /* @__PURE__ */ s(D.h2, {
|
|
160
160
|
id: t.titleId,
|
|
161
161
|
...r,
|
|
162
162
|
ref: a
|
|
163
163
|
});
|
|
164
164
|
}, "DialogTitle")), ee = "DialogDescription", _e = /* @__PURE__ */ i.forwardRef(/* @__PURE__ */ u(function(o, a) {
|
|
165
165
|
const { __scopeDialog: n, ...r } = o, t = g(ee, n), { setDescriptionCount: e } = t;
|
|
166
|
-
return h(() => (e((
|
|
166
|
+
return h(() => (e((l) => l + 1), () => e((l) => l - 1)), [e]), /* @__PURE__ */ s(D.p, {
|
|
167
167
|
id: t.descriptionId,
|
|
168
168
|
...r,
|
|
169
169
|
ref: a
|
|
@@ -177,8 +177,8 @@ var Y = Object.defineProperty, u = (l, o) => Y(l, "name", {
|
|
|
177
177
|
onClick: d(o.onClick, () => t.onOpenChange(!1))
|
|
178
178
|
});
|
|
179
179
|
}, "DialogClose"));
|
|
180
|
-
function v(
|
|
181
|
-
return
|
|
180
|
+
function v(c) {
|
|
181
|
+
return c ? "open" : "closed";
|
|
182
182
|
}
|
|
183
183
|
u(v, "getState");
|
|
184
184
|
export {
|