@react-spectrum/s2 3.0.0-nightly-5ae234603-240925 → 3.0.0-nightly-d57bd8d90-240927
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/dist/Accordion.cjs.map +1 -1
- package/dist/Accordion.css.map +1 -1
- package/dist/Accordion.mjs.map +1 -1
- package/dist/ActionButton.cjs.map +1 -1
- package/dist/ActionButton.css.map +1 -1
- package/dist/ActionButton.mjs.map +1 -1
- package/dist/AlertDialog.cjs.map +1 -1
- package/dist/AlertDialog.css.map +1 -1
- package/dist/AlertDialog.mjs.map +1 -1
- package/dist/Avatar.cjs.map +1 -1
- package/dist/Avatar.css.map +1 -1
- package/dist/Avatar.mjs.map +1 -1
- package/dist/AvatarGroup.cjs.map +1 -1
- package/dist/AvatarGroup.css.map +1 -1
- package/dist/AvatarGroup.mjs.map +1 -1
- package/dist/Badge.cjs.map +1 -1
- package/dist/Badge.css.map +1 -1
- package/dist/Badge.mjs.map +1 -1
- package/dist/Breadcrumbs.cjs.map +1 -1
- package/dist/Breadcrumbs.css.map +1 -1
- package/dist/Breadcrumbs.mjs.map +1 -1
- package/dist/Button.cjs +39 -5
- package/dist/Button.cjs.map +1 -1
- package/dist/Button.css +64 -0
- package/dist/Button.css.map +1 -1
- package/dist/Button.mjs +39 -5
- package/dist/Button.mjs.map +1 -1
- package/dist/ButtonGroup.cjs.map +1 -1
- package/dist/ButtonGroup.css.map +1 -1
- package/dist/ButtonGroup.mjs.map +1 -1
- package/dist/Card.cjs +2 -2
- package/dist/Card.cjs.map +1 -1
- package/dist/Card.css.map +1 -1
- package/dist/Card.mjs +2 -2
- package/dist/Card.mjs.map +1 -1
- package/dist/CardView.cjs.map +1 -1
- package/dist/CardView.css.map +1 -1
- package/dist/CardView.mjs.map +1 -1
- package/dist/CenterBaseline.cjs.map +1 -1
- package/dist/CenterBaseline.css.map +1 -1
- package/dist/CenterBaseline.mjs.map +1 -1
- package/dist/Checkbox.cjs +4 -1
- package/dist/Checkbox.cjs.map +1 -1
- package/dist/Checkbox.css +4 -0
- package/dist/Checkbox.css.map +1 -1
- package/dist/Checkbox.mjs +4 -1
- package/dist/Checkbox.mjs.map +1 -1
- package/dist/CheckboxGroup.cjs.map +1 -1
- package/dist/CheckboxGroup.css.map +1 -1
- package/dist/CheckboxGroup.mjs.map +1 -1
- package/dist/ClearButton.cjs.map +1 -1
- package/dist/ClearButton.css.map +1 -1
- package/dist/ClearButton.mjs.map +1 -1
- package/dist/CloseButton.cjs.map +1 -1
- package/dist/CloseButton.css.map +1 -1
- package/dist/CloseButton.mjs.map +1 -1
- package/dist/ColorArea.cjs.map +1 -1
- package/dist/ColorArea.css.map +1 -1
- package/dist/ColorArea.mjs.map +1 -1
- package/dist/ColorField.cjs.map +1 -1
- package/dist/ColorField.css.map +1 -1
- package/dist/ColorField.mjs.map +1 -1
- package/dist/ColorHandle.cjs.map +1 -1
- package/dist/ColorHandle.css.map +1 -1
- package/dist/ColorHandle.mjs.map +1 -1
- package/dist/ColorSlider.cjs.map +1 -1
- package/dist/ColorSlider.css.map +1 -1
- package/dist/ColorSlider.mjs.map +1 -1
- package/dist/ColorSwatch.cjs.map +1 -1
- package/dist/ColorSwatch.css.map +1 -1
- package/dist/ColorSwatch.mjs.map +1 -1
- package/dist/ColorSwatchPicker.cjs.map +1 -1
- package/dist/ColorSwatchPicker.css.map +1 -1
- package/dist/ColorSwatchPicker.mjs.map +1 -1
- package/dist/ColorWheel.cjs.map +1 -1
- package/dist/ColorWheel.css.map +1 -1
- package/dist/ColorWheel.mjs.map +1 -1
- package/dist/ComboBox.cjs +3 -0
- package/dist/ComboBox.cjs.map +1 -1
- package/dist/ComboBox.css.map +1 -1
- package/dist/ComboBox.mjs +3 -0
- package/dist/ComboBox.mjs.map +1 -1
- package/dist/Content.cjs +0 -2
- package/dist/Content.cjs.map +1 -1
- package/dist/Content.mjs +1 -2
- package/dist/Content.mjs.map +1 -1
- package/dist/ContextualHelp.cjs.map +1 -1
- package/dist/ContextualHelp.css.map +1 -1
- package/dist/ContextualHelp.mjs.map +1 -1
- package/dist/Dialog.cjs +7 -5
- package/dist/Dialog.cjs.map +1 -1
- package/dist/Dialog.css.map +1 -1
- package/dist/Dialog.mjs +8 -6
- package/dist/Dialog.mjs.map +1 -1
- package/dist/Disclosure.cjs.map +1 -1
- package/dist/Disclosure.css.map +1 -1
- package/dist/Disclosure.mjs.map +1 -1
- package/dist/Divider.cjs.map +1 -1
- package/dist/Divider.css.map +1 -1
- package/dist/Divider.mjs.map +1 -1
- package/dist/DropZone.cjs.map +1 -1
- package/dist/DropZone.css.map +1 -1
- package/dist/DropZone.mjs.map +1 -1
- package/dist/Field.cjs.map +1 -1
- package/dist/Field.css.map +1 -1
- package/dist/Field.mjs.map +1 -1
- package/dist/Form.cjs.map +1 -1
- package/dist/Form.css.map +1 -1
- package/dist/Form.mjs.map +1 -1
- package/dist/IllustratedMessage.cjs.map +1 -1
- package/dist/IllustratedMessage.css.map +1 -1
- package/dist/IllustratedMessage.mjs.map +1 -1
- package/dist/Image.cjs.map +1 -1
- package/dist/Image.css.map +1 -1
- package/dist/Image.mjs.map +1 -1
- package/dist/InlineAlert.cjs.map +1 -1
- package/dist/InlineAlert.css.map +1 -1
- package/dist/InlineAlert.mjs.map +1 -1
- package/dist/Link.cjs.map +1 -1
- package/dist/Link.css.map +1 -1
- package/dist/Link.mjs.map +1 -1
- package/dist/Menu.cjs.map +1 -1
- package/dist/Menu.css.map +1 -1
- package/dist/Menu.mjs.map +1 -1
- package/dist/Meter.cjs.map +1 -1
- package/dist/Meter.css.map +1 -1
- package/dist/Meter.mjs.map +1 -1
- package/dist/Modal.cjs.map +1 -1
- package/dist/Modal.css.map +1 -1
- package/dist/Modal.mjs.map +1 -1
- package/dist/MoveHorizontalCircleTableWidget.cjs +33 -0
- package/dist/MoveHorizontalCircleTableWidget.cjs.map +1 -0
- package/dist/MoveHorizontalCircleTableWidget.mjs +28 -0
- package/dist/MoveHorizontalCircleTableWidget.mjs.map +1 -0
- package/dist/NumberField.cjs.map +1 -1
- package/dist/NumberField.css.map +1 -1
- package/dist/NumberField.mjs.map +1 -1
- package/dist/Picker.cjs +3 -0
- package/dist/Picker.cjs.map +1 -1
- package/dist/Picker.css.map +1 -1
- package/dist/Picker.mjs +3 -0
- package/dist/Picker.mjs.map +1 -1
- package/dist/Popover.cjs +1 -0
- package/dist/Popover.cjs.map +1 -1
- package/dist/Popover.css +4 -0
- package/dist/Popover.css.map +1 -1
- package/dist/Popover.mjs +1 -0
- package/dist/Popover.mjs.map +1 -1
- package/dist/ProgressBar.cjs.map +1 -1
- package/dist/ProgressBar.css.map +1 -1
- package/dist/ProgressBar.mjs.map +1 -1
- package/dist/ProgressCircle.cjs +0 -1
- package/dist/ProgressCircle.cjs.map +1 -1
- package/dist/ProgressCircle.css +0 -4
- package/dist/ProgressCircle.css.map +1 -1
- package/dist/ProgressCircle.mjs +0 -1
- package/dist/ProgressCircle.mjs.map +1 -1
- package/dist/Provider.cjs.map +1 -1
- package/dist/Provider.css.map +1 -1
- package/dist/Provider.mjs.map +1 -1
- package/dist/Radio.cjs.map +1 -1
- package/dist/Radio.css.map +1 -1
- package/dist/Radio.mjs.map +1 -1
- package/dist/RadioGroup.cjs.map +1 -1
- package/dist/RadioGroup.css.map +1 -1
- package/dist/RadioGroup.mjs.map +1 -1
- package/dist/SearchField.cjs.map +1 -1
- package/dist/SearchField.css.map +1 -1
- package/dist/SearchField.mjs.map +1 -1
- package/dist/SegmentedControl.cjs +11 -8
- package/dist/SegmentedControl.cjs.map +1 -1
- package/dist/SegmentedControl.css.map +1 -1
- package/dist/SegmentedControl.mjs +11 -8
- package/dist/SegmentedControl.mjs.map +1 -1
- package/dist/SkeletonCollection.cjs.map +1 -1
- package/dist/SkeletonCollection.mjs.map +1 -1
- package/dist/Slider.cjs.map +1 -1
- package/dist/Slider.css.map +1 -1
- package/dist/Slider.mjs.map +1 -1
- package/dist/StatusLight.cjs.map +1 -1
- package/dist/StatusLight.css.map +1 -1
- package/dist/StatusLight.mjs.map +1 -1
- package/dist/Switch.cjs.map +1 -1
- package/dist/Switch.css.map +1 -1
- package/dist/Switch.mjs.map +1 -1
- package/dist/Table.cjs +1064 -0
- package/dist/Table.cjs.map +1 -0
- package/dist/Table.css +801 -0
- package/dist/Table.css.map +1 -0
- package/dist/Table.mjs +1054 -0
- package/dist/Table.mjs.map +1 -0
- package/dist/Tabs.cjs.map +1 -1
- package/dist/Tabs.css.map +1 -1
- package/dist/Tabs.mjs.map +1 -1
- package/dist/TagGroup.cjs +5 -3
- package/dist/TagGroup.cjs.map +1 -1
- package/dist/TagGroup.css.map +1 -1
- package/dist/TagGroup.mjs +5 -3
- package/dist/TagGroup.mjs.map +1 -1
- package/dist/TextField.cjs.map +1 -1
- package/dist/TextField.css.map +1 -1
- package/dist/TextField.mjs.map +1 -1
- package/dist/ToggleButton.cjs +2 -1
- package/dist/ToggleButton.cjs.map +1 -1
- package/dist/ToggleButton.css.map +1 -1
- package/dist/ToggleButton.mjs +2 -1
- package/dist/ToggleButton.mjs.map +1 -1
- package/dist/Tooltip.cjs.map +1 -1
- package/dist/Tooltip.css.map +1 -1
- package/dist/Tooltip.mjs.map +1 -1
- package/dist/ar-AE.cjs +5 -0
- package/dist/ar-AE.cjs.map +1 -1
- package/dist/ar-AE.mjs +5 -0
- package/dist/ar-AE.mjs.map +1 -1
- package/dist/bg-BG.cjs +5 -0
- package/dist/bg-BG.cjs.map +1 -1
- package/dist/bg-BG.mjs +5 -0
- package/dist/bg-BG.mjs.map +1 -1
- package/dist/cs-CZ.cjs +5 -0
- package/dist/cs-CZ.cjs.map +1 -1
- package/dist/cs-CZ.mjs +5 -0
- package/dist/cs-CZ.mjs.map +1 -1
- package/dist/da-DK.cjs +5 -0
- package/dist/da-DK.cjs.map +1 -1
- package/dist/da-DK.mjs +5 -0
- package/dist/da-DK.mjs.map +1 -1
- package/dist/de-DE.cjs +5 -0
- package/dist/de-DE.cjs.map +1 -1
- package/dist/de-DE.mjs +5 -0
- package/dist/de-DE.mjs.map +1 -1
- package/dist/el-GR.cjs +5 -0
- package/dist/el-GR.cjs.map +1 -1
- package/dist/el-GR.mjs +5 -0
- package/dist/el-GR.mjs.map +1 -1
- package/dist/en-US.cjs +5 -0
- package/dist/en-US.cjs.map +1 -1
- package/dist/en-US.mjs +5 -0
- package/dist/en-US.mjs.map +1 -1
- package/dist/es-ES.cjs +5 -0
- package/dist/es-ES.cjs.map +1 -1
- package/dist/es-ES.mjs +5 -0
- package/dist/es-ES.mjs.map +1 -1
- package/dist/et-EE.cjs +5 -0
- package/dist/et-EE.cjs.map +1 -1
- package/dist/et-EE.mjs +5 -0
- package/dist/et-EE.mjs.map +1 -1
- package/dist/fi-FI.cjs +5 -0
- package/dist/fi-FI.cjs.map +1 -1
- package/dist/fi-FI.mjs +5 -0
- package/dist/fi-FI.mjs.map +1 -1
- package/dist/fr-FR.cjs +5 -0
- package/dist/fr-FR.cjs.map +1 -1
- package/dist/fr-FR.mjs +5 -0
- package/dist/fr-FR.mjs.map +1 -1
- package/dist/he-IL.cjs +5 -0
- package/dist/he-IL.cjs.map +1 -1
- package/dist/he-IL.mjs +5 -0
- package/dist/he-IL.mjs.map +1 -1
- package/dist/hr-HR.cjs +5 -0
- package/dist/hr-HR.cjs.map +1 -1
- package/dist/hr-HR.mjs +5 -0
- package/dist/hr-HR.mjs.map +1 -1
- package/dist/hu-HU.cjs +5 -0
- package/dist/hu-HU.cjs.map +1 -1
- package/dist/hu-HU.mjs +5 -0
- package/dist/hu-HU.mjs.map +1 -1
- package/dist/it-IT.cjs +5 -0
- package/dist/it-IT.cjs.map +1 -1
- package/dist/it-IT.mjs +5 -0
- package/dist/it-IT.mjs.map +1 -1
- package/dist/ja-JP.cjs +5 -0
- package/dist/ja-JP.cjs.map +1 -1
- package/dist/ja-JP.mjs +5 -0
- package/dist/ja-JP.mjs.map +1 -1
- package/dist/ko-KR.cjs +5 -0
- package/dist/ko-KR.cjs.map +1 -1
- package/dist/ko-KR.mjs +5 -0
- package/dist/ko-KR.mjs.map +1 -1
- package/dist/lt-LT.cjs +5 -0
- package/dist/lt-LT.cjs.map +1 -1
- package/dist/lt-LT.mjs +5 -0
- package/dist/lt-LT.mjs.map +1 -1
- package/dist/lv-LV.cjs +5 -0
- package/dist/lv-LV.cjs.map +1 -1
- package/dist/lv-LV.mjs +5 -0
- package/dist/lv-LV.mjs.map +1 -1
- package/dist/main.cjs +11 -0
- package/dist/main.cjs.map +1 -1
- package/dist/module.mjs +5 -1
- package/dist/module.mjs.map +1 -1
- package/dist/nb-NO.cjs +5 -0
- package/dist/nb-NO.cjs.map +1 -1
- package/dist/nb-NO.mjs +5 -0
- package/dist/nb-NO.mjs.map +1 -1
- package/dist/nl-NL.cjs +5 -0
- package/dist/nl-NL.cjs.map +1 -1
- package/dist/nl-NL.mjs +5 -0
- package/dist/nl-NL.mjs.map +1 -1
- package/dist/pl-PL.cjs +5 -0
- package/dist/pl-PL.cjs.map +1 -1
- package/dist/pl-PL.mjs +5 -0
- package/dist/pl-PL.mjs.map +1 -1
- package/dist/pt-BR.cjs +5 -0
- package/dist/pt-BR.cjs.map +1 -1
- package/dist/pt-BR.mjs +5 -0
- package/dist/pt-BR.mjs.map +1 -1
- package/dist/pt-PT.cjs +5 -0
- package/dist/pt-PT.cjs.map +1 -1
- package/dist/pt-PT.mjs +5 -0
- package/dist/pt-PT.mjs.map +1 -1
- package/dist/ro-RO.cjs +5 -0
- package/dist/ro-RO.cjs.map +1 -1
- package/dist/ro-RO.mjs +5 -0
- package/dist/ro-RO.mjs.map +1 -1
- package/dist/ru-RU.cjs +5 -0
- package/dist/ru-RU.cjs.map +1 -1
- package/dist/ru-RU.mjs +5 -0
- package/dist/ru-RU.mjs.map +1 -1
- package/dist/sk-SK.cjs +5 -0
- package/dist/sk-SK.cjs.map +1 -1
- package/dist/sk-SK.mjs +5 -0
- package/dist/sk-SK.mjs.map +1 -1
- package/dist/sl-SI.cjs +5 -0
- package/dist/sl-SI.cjs.map +1 -1
- package/dist/sl-SI.mjs +5 -0
- package/dist/sl-SI.mjs.map +1 -1
- package/dist/sr-SP.cjs +5 -0
- package/dist/sr-SP.cjs.map +1 -1
- package/dist/sr-SP.mjs +5 -0
- package/dist/sr-SP.mjs.map +1 -1
- package/dist/sv-SE.cjs +5 -0
- package/dist/sv-SE.cjs.map +1 -1
- package/dist/sv-SE.mjs +5 -0
- package/dist/sv-SE.mjs.map +1 -1
- package/dist/tr-TR.cjs +5 -0
- package/dist/tr-TR.cjs.map +1 -1
- package/dist/tr-TR.mjs +5 -0
- package/dist/tr-TR.mjs.map +1 -1
- package/dist/types.d.ts +136 -30
- package/dist/types.d.ts.map +1 -1
- package/dist/uk-UA.cjs +5 -0
- package/dist/uk-UA.cjs.map +1 -1
- package/dist/uk-UA.mjs +5 -0
- package/dist/uk-UA.mjs.map +1 -1
- package/dist/utils.cjs +30 -0
- package/dist/utils.cjs.map +1 -0
- package/dist/utils.mjs +25 -0
- package/dist/utils.mjs.map +1 -0
- package/dist/zh-CN.cjs +5 -0
- package/dist/zh-CN.cjs.map +1 -1
- package/dist/zh-CN.mjs +5 -0
- package/dist/zh-CN.mjs.map +1 -1
- package/dist/zh-TW.cjs +5 -0
- package/dist/zh-TW.cjs.map +1 -1
- package/dist/zh-TW.mjs +5 -0
- package/dist/zh-TW.mjs.map +1 -1
- package/icons/Skeleton.cjs.map +1 -1
- package/icons/Skeleton.css.map +1 -1
- package/icons/Skeleton.mjs.map +1 -1
- package/package.json +18 -16
- package/src/Accordion.tsx +2 -2
- package/src/ActionButton.tsx +3 -3
- package/src/AlertDialog.tsx +1 -1
- package/src/Avatar.tsx +1 -1
- package/src/AvatarGroup.tsx +1 -1
- package/src/Badge.tsx +1 -1
- package/src/Breadcrumbs.tsx +2 -2
- package/src/Button.tsx +41 -19
- package/src/ButtonGroup.tsx +1 -1
- package/src/Card.tsx +7 -7
- package/src/CardView.tsx +2 -2
- package/src/CenterBaseline.tsx +1 -1
- package/src/Checkbox.tsx +3 -2
- package/src/CheckboxGroup.tsx +1 -1
- package/src/ClearButton.tsx +1 -1
- package/src/CloseButton.tsx +2 -2
- package/src/ColorArea.tsx +1 -1
- package/src/ColorField.tsx +1 -1
- package/src/ColorHandle.tsx +1 -1
- package/src/ColorSlider.tsx +1 -1
- package/src/ColorSwatch.tsx +3 -3
- package/src/ColorSwatchPicker.tsx +5 -5
- package/src/ColorWheel.tsx +1 -1
- package/src/ComboBox.tsx +7 -4
- package/src/Content.tsx +1 -3
- package/src/ContextualHelp.tsx +1 -1
- package/src/Dialog.tsx +4 -3
- package/src/Disclosure.tsx +4 -4
- package/src/Divider.tsx +1 -1
- package/src/DropZone.tsx +1 -1
- package/src/Field.tsx +2 -2
- package/src/Form.tsx +1 -1
- package/src/IllustratedMessage.tsx +1 -1
- package/src/Image.tsx +1 -1
- package/src/InlineAlert.tsx +2 -2
- package/src/Link.tsx +2 -2
- package/src/Menu.tsx +2 -2
- package/src/Meter.tsx +1 -1
- package/src/Modal.tsx +1 -1
- package/src/NumberField.tsx +2 -2
- package/src/Picker.tsx +7 -4
- package/src/Popover.tsx +5 -2
- package/src/ProgressBar.tsx +1 -1
- package/src/ProgressCircle.tsx +7 -5
- package/src/Provider.tsx +1 -1
- package/src/Radio.tsx +2 -2
- package/src/RadioGroup.tsx +1 -1
- package/src/SearchField.tsx +1 -1
- package/src/SegmentedControl.tsx +32 -22
- package/src/Skeleton.tsx +4 -1
- package/src/SkeletonCollection.tsx +4 -0
- package/src/Slider.tsx +2 -2
- package/src/StatusLight.tsx +1 -1
- package/src/Switch.tsx +2 -2
- package/src/Table.tsx +1063 -48
- package/src/Tabs.tsx +3 -3
- package/src/TagGroup.tsx +5 -4
- package/src/TextField.tsx +1 -1
- package/src/ToggleButton.tsx +3 -2
- package/src/Tooltip.tsx +1 -1
- package/src/index.ts +4 -0
- package/src/style-utils.ts +0 -10
- package/src/utils.ts +28 -0
- package/style/__tests__/mergeStyles.test.js +32 -0
- package/style/__tests__/style-macro.test.js +128 -0
- package/style/dist/main.cjs +38 -0
- package/style/dist/main.cjs.map +1 -0
- package/style/dist/module.mjs +26 -0
- package/style/dist/module.mjs.map +1 -0
- package/style/dist/spectrum-theme.cjs +1989 -0
- package/style/dist/spectrum-theme.cjs.map +1 -0
- package/style/dist/spectrum-theme.mjs +1978 -0
- package/style/dist/spectrum-theme.mjs.map +1 -0
- package/style/dist/style-macro.cjs +544 -0
- package/style/dist/style-macro.cjs.map +1 -0
- package/style/dist/style-macro.mjs +534 -0
- package/style/dist/style-macro.mjs.map +1 -0
- package/style/dist/types.d.ts +791 -0
- package/style/dist/types.d.ts.map +1 -0
- package/style/index.ts +24 -0
- package/style/runtime.ts +103 -0
- package/style/spectrum-theme.ts +980 -0
- package/style/style-macro.ts +638 -0
- package/style/tokens.ts +68 -0
- package/style/types.ts +178 -0
package/dist/ColorHandle.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"ACiCiB;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAgCI;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAkFJ;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EA6BE;;;;EAAA;;;;EAAA;;;;;AA/IF;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;;;AAAA;EAAA;IAAA;;;;IAgCI;;;;IA+GF;;;;;;AAtDI;;;;;;;AAOD;;;;;;;AAkBL","sources":["e345175c46126410","packages/@react-spectrum/s2/src/ColorHandle.tsx"],"sourcesContent":["@import \"63203eb3a948f993\";\n@import \"ba33a56d675003f7\";\n@import \"bf115cb0a25c2b12\";\n@import \"5d32c8c9143517d5\";\n@import \"cf10a6b7558ccf38\";\n@import \"d7c9e49b2d44a61e\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {cloneElement, JSX, RefObject, useState} from 'react';\nimport {ColorThumb} from 'react-aria-components';\nimport {createPortal} from 'react-dom';\nimport {keyframes} from '../style/style-macro' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":"ACiCiB;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAgCI;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAkFJ;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EA6BE;;;;EAAA;;;;EAAA;;;;;AA/IF;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;;;AAAA;EAAA;IAAA;;;;IAgCI;;;;IA+GF;;;;;;AAtDI;;;;;;;AAOD;;;;;;;AAkBL","sources":["e345175c46126410","packages/@react-spectrum/s2/src/ColorHandle.tsx"],"sourcesContent":["@import \"63203eb3a948f993\";\n@import \"ba33a56d675003f7\";\n@import \"bf115cb0a25c2b12\";\n@import \"5d32c8c9143517d5\";\n@import \"cf10a6b7558ccf38\";\n@import \"d7c9e49b2d44a61e\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {cloneElement, JSX, RefObject, useState} from 'react';\nimport {ColorThumb} from 'react-aria-components';\nimport {createPortal} from 'react-dom';\nimport {keyframes} from '../style/style-macro' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useId, useLayoutEffect} from '@react-aria/utils';\n\nconst HANDLE_SIZE = 16;\nconst LOUPE_HEIGHT = 64; // Does not include borders\nconst LOUPE_WIDTH = 48;\nconst LOUPE_BORDER_WIDTH = 1;\nconst LOUPE_OFFSET = 12; // Offset from handle to loupe\n\ninterface ColorHandleProps {\n containerRef: RefObject<HTMLElement | null>,\n getPosition: () => {x: number, y: number}\n}\n\nexport function ColorHandle({containerRef, getPosition}: ColorHandleProps) {\n return (\n <ColorThumb\n className={style({\n transition: '[width, height]',\n size: {\n default: HANDLE_SIZE,\n isFocusVisible: 32\n },\n backgroundColor: {\n isDisabled: 'disabled'\n },\n borderRadius: 'full',\n boxSizing: 'border-box',\n borderStyle: 'solid',\n borderWidth: 2,\n borderColor: {\n default: 'white',\n isDisabled: 'disabled'\n },\n outlineStyle: 'solid',\n outlineWidth: 1,\n outlineColor: {\n default: 'black/42',\n forcedColors: 'ButtonBorder'\n }\n })}\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : `linear-gradient(${defaultStyle.backgroundColor}, ${defaultStyle.backgroundColor}), repeating-conic-gradient(#E1E1E1 0% 25%, white 0% 50%) 50% / 16px 16px`,\n backgroundColor: undefined,\n top: defaultStyle.top || '50%',\n left: defaultStyle.left || '50%'\n })}>\n {({isDragging, color}) => (<>\n <div\n className={style({\n size: 'full',\n borderRadius: 'full',\n boxSizing: 'border-box',\n borderStyle: 'solid',\n borderWidth: 1,\n borderColor: {\n default: 'black/42',\n forcedColors: 'ButtonBorder'\n }\n })} />\n <ColorLoupePortal isOpen={isDragging}>\n <ColorLoupe containerRef={containerRef} color={color} getPosition={getPosition} />\n </ColorLoupePortal>\n </>)}\n </ColorThumb>\n );\n}\n\n// ColorLoupe is rendered in a portal so that it breaks out of clipped/scrolling containers (e.g. popovers).\nfunction ColorLoupePortal({isOpen, children}: { isOpen: boolean, children: JSX.Element }) {\n let [state, setState] = useState(isOpen ? 'open' : 'closed');\n if (isOpen && state === 'closed') {\n setState('open');\n }\n\n if (!isOpen && state === 'open') {\n setState('exiting');\n }\n\n if (isOpen || state === 'exiting') {\n return createPortal(cloneElement(children, {isExiting: state === 'exiting', onExited: () => setState('closed')}), document.body);\n }\n\n return null;\n}\n\nfunction ColorLoupe({isExiting, onExited, containerRef, loupeRef, getPosition, color}: any) {\n let patternId = useId();\n\n // Get the bounding rectangle of the container (e.g. ColorArea/ColorSlider).\n let [containerRect, setContainerRect] = useState({top: 0, left: 0, width: 0, height: 0});\n useLayoutEffect(() => {\n let rect = containerRef.current?.getBoundingClientRect();\n setContainerRect({\n top: rect?.top || 0,\n left: rect?.left || 0,\n width: rect?.width || 0,\n height: rect?.height || 0\n });\n }, [containerRef]);\n\n // Compute the pixel position of the thumb.\n let {x: thumbLeft, y: thumbTop} = getPosition();\n thumbTop *= containerRect.height;\n thumbLeft *= containerRect.width;\n\n let enterAnimation = keyframes(`\n from {\n transform: translateY(8px);\n opacity: 0;\n }\n `);\n\n let exitAnimation = keyframes(`\n to {\n transform: translateY(8px);\n opacity: 0;\n }\n `);\n\n return (\n <svg\n style={{\n // Position relative to the viewport.\n position: 'fixed',\n top: containerRect.top + thumbTop,\n left: containerRect.left + thumbLeft,\n marginTop: -LOUPE_HEIGHT - LOUPE_BORDER_WIDTH * 2 - HANDLE_SIZE / 2 - LOUPE_OFFSET,\n marginLeft: -LOUPE_WIDTH / 2 - LOUPE_BORDER_WIDTH,\n animationName: isExiting ? exitAnimation : enterAnimation\n }}\n className={style({\n filter: 'elevated',\n pointerEvents: 'none',\n animationDuration: 125,\n animationFillMode: 'forwards',\n animationTimingFunction: 'in-out',\n isolation: 'isolate'\n })}\n onAnimationEnd={e => {\n if (e.animationName === exitAnimation) {\n onExited();\n }\n }}\n width={LOUPE_WIDTH + LOUPE_BORDER_WIDTH * 2}\n height={LOUPE_HEIGHT + LOUPE_BORDER_WIDTH * 2}\n ref={loupeRef}\n aria-hidden=\"true\">\n <pattern id={patternId} x=\"0\" y=\"0\" width=\"16\" height=\"16\" patternUnits=\"userSpaceOnUse\">\n <rect fill=\"white\" x=\"0\" y=\"0\" width=\"16\" height=\"16\" />\n <rect fill=\"#E1E1E1\" x=\"0\" y=\"0\" width=\"8\" height=\"8\" />\n <rect fill=\"#E1E1E1\" x=\"8\" y=\"8\" width=\"8\" height=\"8\" />\n </pattern>\n <path\n d=\"M25 1a24 24 0 0124 24c0 16.255-24 40-24 40S1 41.255 1 25A24 24 0 0125 1z\"\n fill={`url(#${patternId})`} />\n <path\n d=\"M25 1a24 24 0 0124 24c0 16.255-24 40-24 40S1 41.255 1 25A24 24 0 0125 1z\"\n fill={color.toString()} />\n <path\n className={style({\n strokeWidth: 1,\n stroke: {\n default: 'transparent-black-200',\n forcedColors: 'ButtonBorder'\n },\n fill: 'white'\n })}\n d=\"M25 3A21.98 21.98 0 003 25c0 6.2 4 14.794 11.568 24.853A144.233 144.233 0 0025 62.132a144.085 144.085 0 0010.4-12.239C42.99 39.816 47 31.209 47 25A21.98 21.98 0 0025 3m0-2a24 24 0 0124 24c0 16.255-24 40-24 40S1 41.255 1 25A24 24 0 0125 1z\" />\n </svg>\n );\n}\n"],"names":[],"version":3,"file":"ColorHandle.css.map"}
|
package/dist/ColorHandle.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AASD,MAAM,oCAAc;AACpB,MAAM,qCAAe,IAAI,2BAA2B;AACpD,MAAM,oCAAc;AACpB,MAAM,2CAAqB;AAC3B,MAAM,qCAAe,IAAI,8BAA8B;AAOhD,SAAS,0CAAY,gBAAC,YAAY,eAAE,WAAW,EAAmB;IACvE,qBACE,gBAAC,CAAA,GAAA,iBAAS;QACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAwBA,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gBACtC,YAAY,aAAa,YAAY,CAAC,gBAAgB,EAAE,aAAa,eAAe,CAAC,EAAE,EAAE,aAAa,eAAe,CAAC,yEAAyE,CAAC;gBAChM,iBAAiB;gBACjB,KAAK,aAAa,GAAG,IAAI;gBACzB,MAAM,aAAa,IAAI,IAAI;YAC7B,CAAA;kBACC,CAAC,cAAC,UAAU,SAAE,KAAK,EAAC,iBAAM;;kCACzB,gBAAC;wBACC,SAAS;;kCAWX,gBAAC;wBAAiB,QAAQ;kCACxB,cAAA,gBAAC;4BAAW,cAAc;4BAAc,OAAO;4BAAO,aAAa;;;;;;AAK7E;AAEA,4GAA4G;AAC5G,SAAS,uCAAiB,UAAC,MAAM,YAAE,QAAQ,EAA6C;IACtF,IAAI,CAAC,OAAO,SAAS,GAAG,CAAA,GAAA,eAAO,EAAE,SAAS,SAAS;IACnD,IAAI,UAAU,UAAU,UACtB,SAAS;IAGX,IAAI,CAAC,UAAU,UAAU,QACvB,SAAS;IAGX,IAAI,UAAU,UAAU,WACtB,qBAAO,CAAA,GAAA,mBAAW,gBAAE,CAAA,GAAA,mBAAW,EAAE,UAAU;QAAC,WAAW,UAAU;QAAW,UAAU,IAAM,SAAS;IAAS,IAAI,SAAS,IAAI;IAGjI,OAAO;AACT;AAEA,SAAS,iCAAW,aAAC,SAAS,YAAE,QAAQ,gBAAE,YAAY,YAAE,QAAQ,eAAE,WAAW,SAAE,KAAK,EAAM;IACxF,IAAI,YAAY,CAAA,GAAA,YAAI;IAEpB,4EAA4E;IAC5E,IAAI,CAAC,eAAe,iBAAiB,GAAG,CAAA,GAAA,eAAO,EAAE;QAAC,KAAK;QAAG,MAAM;QAAG,OAAO;QAAG,QAAQ;IAAC;IACtF,CAAA,GAAA,sBAAc,EAAE;QACd,IAAI,OAAO,aAAa,OAAO,EAAE;QACjC,iBAAiB;YACf,KAAK,MAAM,OAAO;YAClB,MAAM,MAAM,QAAQ;YACpB,OAAO,MAAM,SAAS;YACtB,QAAQ,MAAM,UAAU;QAC1B;IACF,GAAG;QAAC;KAAa;IAEjB,2CAA2C;IAC3C,IAAI,EAAC,GAAG,SAAS,EAAE,GAAG,QAAQ,EAAC,GAAG;IAClC,YAAY,cAAc,MAAM;IAChC,aAAa,cAAc,KAAK;IAEhC,IAAI;IAOJ,IAAI;IAOJ,qBACE,iBAAC;QACC,OAAO;YACL,qCAAqC;YACrC,UAAU;YACV,KAAK,cAAc,GAAG,GAAG;YACzB,MAAM,cAAc,IAAI,GAAG;YAC3B,WAAW,CAAC,qCAAe,2CAAqB,IAAI,oCAAc,IAAI;YACtE,YAAY,CAAC,oCAAc,IAAI;YAC/B,eAAe,YAAY,gBAAgB;QAC7C;QACA,SAAS;QAQT,gBAAgB,CAAA;YACd,IAAI,EAAE,aAAa,KAAK,eACtB;QAEJ;QACA,OAAO,oCAAc,2CAAqB;QAC1C,QAAQ,qCAAe,2CAAqB;QAC5C,KAAK;QACL,eAAY;;0BACZ,iBAAC;gBAAQ,IAAI;gBAAW,GAAE;gBAAI,GAAE;gBAAI,OAAM;gBAAK,QAAO;gBAAK,cAAa;;kCACtE,gBAAC;wBAAK,MAAK;wBAAQ,GAAE;wBAAI,GAAE;wBAAI,OAAM;wBAAK,QAAO;;kCACjD,gBAAC;wBAAK,MAAK;wBAAU,GAAE;wBAAI,GAAE;wBAAI,OAAM;wBAAI,QAAO;;kCAClD,gBAAC;wBAAK,MAAK;wBAAU,GAAE;wBAAI,GAAE;wBAAI,OAAM;wBAAI,QAAO;;;;0BAEpD,gBAAC;gBACC,GAAE;gBACF,MAAM,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;;0BAC5B,gBAAC;gBACC,GAAE;gBACF,MAAM,MAAM,QAAQ;;0BACtB,gBAAC;gBACC,SAAS;gBAQT,GAAE;;;;AAGV","sources":["packages/@react-spectrum/s2/src/ColorHandle.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {cloneElement, JSX, RefObject, useState} from 'react';\nimport {ColorThumb} from 'react-aria-components';\nimport {createPortal} from 'react-dom';\nimport {keyframes} from '../style/style-macro' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AASD,MAAM,oCAAc;AACpB,MAAM,qCAAe,IAAI,2BAA2B;AACpD,MAAM,oCAAc;AACpB,MAAM,2CAAqB;AAC3B,MAAM,qCAAe,IAAI,8BAA8B;AAOhD,SAAS,0CAAY,gBAAC,YAAY,eAAE,WAAW,EAAmB;IACvE,qBACE,gBAAC,CAAA,GAAA,iBAAS;QACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAwBA,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gBACtC,YAAY,aAAa,YAAY,CAAC,gBAAgB,EAAE,aAAa,eAAe,CAAC,EAAE,EAAE,aAAa,eAAe,CAAC,yEAAyE,CAAC;gBAChM,iBAAiB;gBACjB,KAAK,aAAa,GAAG,IAAI;gBACzB,MAAM,aAAa,IAAI,IAAI;YAC7B,CAAA;kBACC,CAAC,cAAC,UAAU,SAAE,KAAK,EAAC,iBAAM;;kCACzB,gBAAC;wBACC,SAAS;;kCAWX,gBAAC;wBAAiB,QAAQ;kCACxB,cAAA,gBAAC;4BAAW,cAAc;4BAAc,OAAO;4BAAO,aAAa;;;;;;AAK7E;AAEA,4GAA4G;AAC5G,SAAS,uCAAiB,UAAC,MAAM,YAAE,QAAQ,EAA6C;IACtF,IAAI,CAAC,OAAO,SAAS,GAAG,CAAA,GAAA,eAAO,EAAE,SAAS,SAAS;IACnD,IAAI,UAAU,UAAU,UACtB,SAAS;IAGX,IAAI,CAAC,UAAU,UAAU,QACvB,SAAS;IAGX,IAAI,UAAU,UAAU,WACtB,qBAAO,CAAA,GAAA,mBAAW,gBAAE,CAAA,GAAA,mBAAW,EAAE,UAAU;QAAC,WAAW,UAAU;QAAW,UAAU,IAAM,SAAS;IAAS,IAAI,SAAS,IAAI;IAGjI,OAAO;AACT;AAEA,SAAS,iCAAW,aAAC,SAAS,YAAE,QAAQ,gBAAE,YAAY,YAAE,QAAQ,eAAE,WAAW,SAAE,KAAK,EAAM;IACxF,IAAI,YAAY,CAAA,GAAA,YAAI;IAEpB,4EAA4E;IAC5E,IAAI,CAAC,eAAe,iBAAiB,GAAG,CAAA,GAAA,eAAO,EAAE;QAAC,KAAK;QAAG,MAAM;QAAG,OAAO;QAAG,QAAQ;IAAC;IACtF,CAAA,GAAA,sBAAc,EAAE;QACd,IAAI,OAAO,aAAa,OAAO,EAAE;QACjC,iBAAiB;YACf,KAAK,MAAM,OAAO;YAClB,MAAM,MAAM,QAAQ;YACpB,OAAO,MAAM,SAAS;YACtB,QAAQ,MAAM,UAAU;QAC1B;IACF,GAAG;QAAC;KAAa;IAEjB,2CAA2C;IAC3C,IAAI,EAAC,GAAG,SAAS,EAAE,GAAG,QAAQ,EAAC,GAAG;IAClC,YAAY,cAAc,MAAM;IAChC,aAAa,cAAc,KAAK;IAEhC,IAAI;IAOJ,IAAI;IAOJ,qBACE,iBAAC;QACC,OAAO;YACL,qCAAqC;YACrC,UAAU;YACV,KAAK,cAAc,GAAG,GAAG;YACzB,MAAM,cAAc,IAAI,GAAG;YAC3B,WAAW,CAAC,qCAAe,2CAAqB,IAAI,oCAAc,IAAI;YACtE,YAAY,CAAC,oCAAc,IAAI;YAC/B,eAAe,YAAY,gBAAgB;QAC7C;QACA,SAAS;QAQT,gBAAgB,CAAA;YACd,IAAI,EAAE,aAAa,KAAK,eACtB;QAEJ;QACA,OAAO,oCAAc,2CAAqB;QAC1C,QAAQ,qCAAe,2CAAqB;QAC5C,KAAK;QACL,eAAY;;0BACZ,iBAAC;gBAAQ,IAAI;gBAAW,GAAE;gBAAI,GAAE;gBAAI,OAAM;gBAAK,QAAO;gBAAK,cAAa;;kCACtE,gBAAC;wBAAK,MAAK;wBAAQ,GAAE;wBAAI,GAAE;wBAAI,OAAM;wBAAK,QAAO;;kCACjD,gBAAC;wBAAK,MAAK;wBAAU,GAAE;wBAAI,GAAE;wBAAI,OAAM;wBAAI,QAAO;;kCAClD,gBAAC;wBAAK,MAAK;wBAAU,GAAE;wBAAI,GAAE;wBAAI,OAAM;wBAAI,QAAO;;;;0BAEpD,gBAAC;gBACC,GAAE;gBACF,MAAM,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;;0BAC5B,gBAAC;gBACC,GAAE;gBACF,MAAM,MAAM,QAAQ;;0BACtB,gBAAC;gBACC,SAAS;gBAQT,GAAE;;;;AAGV","sources":["packages/@react-spectrum/s2/src/ColorHandle.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {cloneElement, JSX, RefObject, useState} from 'react';\nimport {ColorThumb} from 'react-aria-components';\nimport {createPortal} from 'react-dom';\nimport {keyframes} from '../style/style-macro' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useId, useLayoutEffect} from '@react-aria/utils';\n\nconst HANDLE_SIZE = 16;\nconst LOUPE_HEIGHT = 64; // Does not include borders\nconst LOUPE_WIDTH = 48;\nconst LOUPE_BORDER_WIDTH = 1;\nconst LOUPE_OFFSET = 12; // Offset from handle to loupe\n\ninterface ColorHandleProps {\n containerRef: RefObject<HTMLElement | null>,\n getPosition: () => {x: number, y: number}\n}\n\nexport function ColorHandle({containerRef, getPosition}: ColorHandleProps) {\n return (\n <ColorThumb\n className={style({\n transition: '[width, height]',\n size: {\n default: HANDLE_SIZE,\n isFocusVisible: 32\n },\n backgroundColor: {\n isDisabled: 'disabled'\n },\n borderRadius: 'full',\n boxSizing: 'border-box',\n borderStyle: 'solid',\n borderWidth: 2,\n borderColor: {\n default: 'white',\n isDisabled: 'disabled'\n },\n outlineStyle: 'solid',\n outlineWidth: 1,\n outlineColor: {\n default: 'black/42',\n forcedColors: 'ButtonBorder'\n }\n })}\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : `linear-gradient(${defaultStyle.backgroundColor}, ${defaultStyle.backgroundColor}), repeating-conic-gradient(#E1E1E1 0% 25%, white 0% 50%) 50% / 16px 16px`,\n backgroundColor: undefined,\n top: defaultStyle.top || '50%',\n left: defaultStyle.left || '50%'\n })}>\n {({isDragging, color}) => (<>\n <div\n className={style({\n size: 'full',\n borderRadius: 'full',\n boxSizing: 'border-box',\n borderStyle: 'solid',\n borderWidth: 1,\n borderColor: {\n default: 'black/42',\n forcedColors: 'ButtonBorder'\n }\n })} />\n <ColorLoupePortal isOpen={isDragging}>\n <ColorLoupe containerRef={containerRef} color={color} getPosition={getPosition} />\n </ColorLoupePortal>\n </>)}\n </ColorThumb>\n );\n}\n\n// ColorLoupe is rendered in a portal so that it breaks out of clipped/scrolling containers (e.g. popovers).\nfunction ColorLoupePortal({isOpen, children}: { isOpen: boolean, children: JSX.Element }) {\n let [state, setState] = useState(isOpen ? 'open' : 'closed');\n if (isOpen && state === 'closed') {\n setState('open');\n }\n\n if (!isOpen && state === 'open') {\n setState('exiting');\n }\n\n if (isOpen || state === 'exiting') {\n return createPortal(cloneElement(children, {isExiting: state === 'exiting', onExited: () => setState('closed')}), document.body);\n }\n\n return null;\n}\n\nfunction ColorLoupe({isExiting, onExited, containerRef, loupeRef, getPosition, color}: any) {\n let patternId = useId();\n\n // Get the bounding rectangle of the container (e.g. ColorArea/ColorSlider).\n let [containerRect, setContainerRect] = useState({top: 0, left: 0, width: 0, height: 0});\n useLayoutEffect(() => {\n let rect = containerRef.current?.getBoundingClientRect();\n setContainerRect({\n top: rect?.top || 0,\n left: rect?.left || 0,\n width: rect?.width || 0,\n height: rect?.height || 0\n });\n }, [containerRef]);\n\n // Compute the pixel position of the thumb.\n let {x: thumbLeft, y: thumbTop} = getPosition();\n thumbTop *= containerRect.height;\n thumbLeft *= containerRect.width;\n\n let enterAnimation = keyframes(`\n from {\n transform: translateY(8px);\n opacity: 0;\n }\n `);\n\n let exitAnimation = keyframes(`\n to {\n transform: translateY(8px);\n opacity: 0;\n }\n `);\n\n return (\n <svg\n style={{\n // Position relative to the viewport.\n position: 'fixed',\n top: containerRect.top + thumbTop,\n left: containerRect.left + thumbLeft,\n marginTop: -LOUPE_HEIGHT - LOUPE_BORDER_WIDTH * 2 - HANDLE_SIZE / 2 - LOUPE_OFFSET,\n marginLeft: -LOUPE_WIDTH / 2 - LOUPE_BORDER_WIDTH,\n animationName: isExiting ? exitAnimation : enterAnimation\n }}\n className={style({\n filter: 'elevated',\n pointerEvents: 'none',\n animationDuration: 125,\n animationFillMode: 'forwards',\n animationTimingFunction: 'in-out',\n isolation: 'isolate'\n })}\n onAnimationEnd={e => {\n if (e.animationName === exitAnimation) {\n onExited();\n }\n }}\n width={LOUPE_WIDTH + LOUPE_BORDER_WIDTH * 2}\n height={LOUPE_HEIGHT + LOUPE_BORDER_WIDTH * 2}\n ref={loupeRef}\n aria-hidden=\"true\">\n <pattern id={patternId} x=\"0\" y=\"0\" width=\"16\" height=\"16\" patternUnits=\"userSpaceOnUse\">\n <rect fill=\"white\" x=\"0\" y=\"0\" width=\"16\" height=\"16\" />\n <rect fill=\"#E1E1E1\" x=\"0\" y=\"0\" width=\"8\" height=\"8\" />\n <rect fill=\"#E1E1E1\" x=\"8\" y=\"8\" width=\"8\" height=\"8\" />\n </pattern>\n <path\n d=\"M25 1a24 24 0 0124 24c0 16.255-24 40-24 40S1 41.255 1 25A24 24 0 0125 1z\"\n fill={`url(#${patternId})`} />\n <path\n d=\"M25 1a24 24 0 0124 24c0 16.255-24 40-24 40S1 41.255 1 25A24 24 0 0125 1z\"\n fill={color.toString()} />\n <path\n className={style({\n strokeWidth: 1,\n stroke: {\n default: 'transparent-black-200',\n forcedColors: 'ButtonBorder'\n },\n fill: 'white'\n })}\n d=\"M25 3A21.98 21.98 0 003 25c0 6.2 4 14.794 11.568 24.853A144.233 144.233 0 0025 62.132a144.085 144.085 0 0010.4-12.239C42.99 39.816 47 31.209 47 25A21.98 21.98 0 0025 3m0-2a24 24 0 0124 24c0 16.255-24 40-24 40S1 41.255 1 25A24 24 0 0125 1z\" />\n </svg>\n );\n}\n"],"names":[],"version":3,"file":"ColorHandle.mjs.map"}
|
package/dist/ColorSlider.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAuBM,MAAM,0DAAqB,CAAA,GAAA,0BAAY,EAA+D;AAE7G,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,MAAM,EAAC,GAAG;IACpD,IAAI,eAAe,CAAA,GAAA,mCAAQ,EAAE;IAC7B,IAAI,WAAW,CAAA,GAAA,mBAAK,EAAE;IACtB,IAAI,UAAC,MAAM,EAAC,GAAG,CAAA,GAAA,oCAAQ;IAEvB,qBACE,gCAAC,CAAA,GAAA,sCAAc;QACZ,GAAG,KAAK;QACT,KAAK;QACL,OAAO;QACP,8EAA8E;QAC9E,cAAY,KAAK,CAAC,aAAa,IAAK,CAAA,MAAM,WAAW,KAAK,aAAa,MAAM,KAAK,GAAG,SAAQ;QAC7F,WAAW,CAAA,cAAe,mBAAmB;;;;;;;;;;;;;;;;;;;;;;cAuBnB,aAAa;kBACtC,CAAC,cAAC,UAAU,eAAE,WAAW,SAAE,KAAK,EAAC,iBAAM;;oBACrC,gBAAgB,gBAAiB,CAAA,MAAM,KAAK,IAAK,MAAM,KAAK,KAAK,aAAa,CAAC,KAAK,CAAC,aAAa,IAAI,CAAC,KAAK,CAAC,kBAAkB,KAC9H,mEAAmE;oBACnE,qDAAqD;oBACrD,8FAA8F;oBAC9F,mEAAmE;kCACnE,gCAAC,CAAA,GAAA,oCAAS;wBAAE,YAAY;wBAAY,gBAAgB,MAAM,cAAc;kCACrE,MAAM,KAAK,IAAI,MAAM,KAAK,CAAC,cAAc,CAAC,MAAM,OAAO,EAAE;;oBAG7D,gBAAgB,8BACf,gCAAC,CAAA,GAAA,uCAAW;wBACV;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCAUJ,gCAAC,CAAA,GAAA,sCAAU;wBACT,KAAK;wBACL,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,CAAC,EAAE,aAAa,UAAU,CAAC,wEAAwE,CAAC;4BAC3I,CAAA;wBACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCA6BA,cAAA,gCAAC,CAAA,GAAA,qCAAU;4BACT,cAAc;4BACd,aAAa;gCACX,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,eAAe,CAAC,KAAK;gCACxE,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,IAAI,MAAM,eAAe,CAAC;gCAC7E,OAAO;uCAAC;uCAAG;gCAAC;4BACd;;;;;;AAKZ;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,uBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSlider.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSlider as AriaColorSlider,\n ColorSliderProps as AriaColorSliderProps,\n ContextValue,\n SliderOutput,\n SliderTrack,\n useLocale\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef, useRef} from 'react';\nimport {DOMRef, DOMRefValue, SpectrumLabelableProps} from '@react-types/shared';\nimport {FieldLabel} from './Field';\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAuBM,MAAM,0DAAqB,CAAA,GAAA,0BAAY,EAA+D;AAE7G,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,MAAM,EAAC,GAAG;IACpD,IAAI,eAAe,CAAA,GAAA,mCAAQ,EAAE;IAC7B,IAAI,WAAW,CAAA,GAAA,mBAAK,EAAE;IACtB,IAAI,UAAC,MAAM,EAAC,GAAG,CAAA,GAAA,oCAAQ;IAEvB,qBACE,gCAAC,CAAA,GAAA,sCAAc;QACZ,GAAG,KAAK;QACT,KAAK;QACL,OAAO;QACP,8EAA8E;QAC9E,cAAY,KAAK,CAAC,aAAa,IAAK,CAAA,MAAM,WAAW,KAAK,aAAa,MAAM,KAAK,GAAG,SAAQ;QAC7F,WAAW,CAAA,cAAe,mBAAmB;;;;;;;;;;;;;;;;;;;;;;cAuBnB,aAAa;kBACtC,CAAC,cAAC,UAAU,eAAE,WAAW,SAAE,KAAK,EAAC,iBAAM;;oBACrC,gBAAgB,gBAAiB,CAAA,MAAM,KAAK,IAAK,MAAM,KAAK,KAAK,aAAa,CAAC,KAAK,CAAC,aAAa,IAAI,CAAC,KAAK,CAAC,kBAAkB,KAC9H,mEAAmE;oBACnE,qDAAqD;oBACrD,8FAA8F;oBAC9F,mEAAmE;kCACnE,gCAAC,CAAA,GAAA,oCAAS;wBAAE,YAAY;wBAAY,gBAAgB,MAAM,cAAc;kCACrE,MAAM,KAAK,IAAI,MAAM,KAAK,CAAC,cAAc,CAAC,MAAM,OAAO,EAAE;;oBAG7D,gBAAgB,8BACf,gCAAC,CAAA,GAAA,uCAAW;wBACV;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCAUJ,gCAAC,CAAA,GAAA,sCAAU;wBACT,KAAK;wBACL,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,CAAC,EAAE,aAAa,UAAU,CAAC,wEAAwE,CAAC;4BAC3I,CAAA;wBACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCA6BA,cAAA,gCAAC,CAAA,GAAA,qCAAU;4BACT,cAAc;4BACd,aAAa;gCACX,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,eAAe,CAAC,KAAK;gCACxE,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,IAAI,MAAM,eAAe,CAAC;gCAC7E,OAAO;uCAAC;uCAAG;gCAAC;4BACd;;;;;;AAKZ;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,uBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSlider.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSlider as AriaColorSlider,\n ColorSliderProps as AriaColorSliderProps,\n ContextValue,\n SliderOutput,\n SliderTrack,\n useLocale\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef, useRef} from 'react';\nimport {DOMRef, DOMRefValue, SpectrumLabelableProps} from '@react-types/shared';\nimport {FieldLabel} from './Field';\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSliderProps extends Omit<AriaColorSliderProps, 'children' | 'className' | 'style'>, Pick<SpectrumLabelableProps, 'contextualHelp'>, StyleProps {\n label?: string\n}\n\nexport const ColorSliderContext = createContext<ContextValue<ColorSliderProps, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorSlider(props: ColorSliderProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSliderContext);\n let {UNSAFE_className = '', UNSAFE_style, styles} = props;\n let containerRef = useDOMRef(ref);\n let trackRef = useRef(null);\n let {locale} = useLocale();\n\n return (\n <AriaColorSlider\n {...props}\n ref={containerRef}\n style={UNSAFE_style}\n // The visual label is hidden when vertical, so make it an aria-label instead.\n aria-label={props['aria-label'] || (props.orientation === 'vertical' ? props.label : undefined)}\n className={renderProps => UNSAFE_className + style({\n width: {\n orientation: {\n horizontal: 192\n }\n },\n height: {\n orientation: {\n vertical: 192\n }\n },\n display: {\n orientation: {\n horizontal: 'grid',\n vertical: 'block'\n }\n },\n gridTemplateColumns: ['1fr', 'auto'],\n gridTemplateAreas: [\n 'label output',\n 'track track'\n ],\n rowGap: 4\n }, getAllowedOverrides())(renderProps, styles)}>\n {({isDisabled, orientation, state}) => (<>\n {orientation === 'horizontal' && (props.label || (props.label === undefined && !props['aria-label'] && !props['aria-labelledby'])) && (\n // If no external label, aria-label or aria-labelledby is provided,\n // default to displaying the localized channel value.\n // Specifically check if label is undefined. If label is `null` then display no visible label.\n // A default aria-label is provided by useColorSlider in that case.\n <FieldLabel isDisabled={isDisabled} contextualHelp={props.contextualHelp}>\n {props.label || state.value.getChannelName(props.channel, locale)}\n </FieldLabel>\n )}\n {orientation === 'horizontal' &&\n <SliderOutput\n className={style({\n gridArea: 'output',\n font: 'control',\n cursor: 'default',\n color: {\n default: 'neutral-subdued',\n isDisabled: 'disabled'\n }\n })} />\n }\n <SliderTrack\n ref={trackRef}\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : `${defaultStyle.background}, repeating-conic-gradient(#E1E1E1 0% 25%, white 0% 50%) 50% / 16px 16px`\n })}\n className={style({\n gridArea: 'track',\n width: {\n orientation: {\n horizontal: 'full',\n vertical: 24\n }\n },\n height: {\n orientation: {\n horizontal: 24,\n vertical: 'full'\n }\n },\n borderRadius: 'default',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineOffset: -1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n },\n backgroundColor: {\n isDisabled: 'disabled'\n }\n })}>\n <ColorHandle\n containerRef={trackRef}\n getPosition={() => {\n let x = state.orientation === 'horizontal' ? state.getThumbPercent(0) : 0.5;\n let y = state.orientation === 'horizontal' ? 0.5 : 1 - state.getThumbPercent(0);\n return {x, y};\n }} />\n </SliderTrack>\n </>)}\n </AriaColorSlider>\n );\n}\n\n/**\n * A ColorSlider allows users to adjust an individual channel of a color value.\n */\nlet _ColorSlider = forwardRef(ColorSlider);\nexport {_ColorSlider as ColorSlider};\n"],"names":[],"version":3,"file":"ColorSlider.cjs.map"}
|
package/dist/ColorSlider.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"ACiDmD;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;EAAA;;;;EAoC5B;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAeF;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AAnD8B;EAoC5B;;;;EAAA;;;;;AApC4B;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAoC5B;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAeF;;;;IAAA;;;;;;AAfE;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAeF;;;;AAAA;EAAA;IAAA","sources":["14771332a5b9bbc4","packages/@react-spectrum/s2/src/ColorSlider.tsx"],"sourcesContent":["@import \"d6c5746f419c314b\";\n@import \"59869632975fb938\";\n@import \"927ebdef839461cd\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSlider as AriaColorSlider,\n ColorSliderProps as AriaColorSliderProps,\n ContextValue,\n SliderOutput,\n SliderTrack,\n useLocale\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef, useRef} from 'react';\nimport {DOMRef, DOMRefValue, SpectrumLabelableProps} from '@react-types/shared';\nimport {FieldLabel} from './Field';\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":"ACiDmD;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;EAAA;;;;EAoC5B;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAeF;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AAnD8B;EAoC5B;;;;EAAA;;;;;AApC4B;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAoC5B;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAeF;;;;IAAA;;;;;;AAfE;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAAA;EAAA;;;;;AAeF;;;;AAAA;EAAA;IAAA","sources":["14771332a5b9bbc4","packages/@react-spectrum/s2/src/ColorSlider.tsx"],"sourcesContent":["@import \"d6c5746f419c314b\";\n@import \"59869632975fb938\";\n@import \"927ebdef839461cd\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSlider as AriaColorSlider,\n ColorSliderProps as AriaColorSliderProps,\n ContextValue,\n SliderOutput,\n SliderTrack,\n useLocale\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef, useRef} from 'react';\nimport {DOMRef, DOMRefValue, SpectrumLabelableProps} from '@react-types/shared';\nimport {FieldLabel} from './Field';\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSliderProps extends Omit<AriaColorSliderProps, 'children' | 'className' | 'style'>, Pick<SpectrumLabelableProps, 'contextualHelp'>, StyleProps {\n label?: string\n}\n\nexport const ColorSliderContext = createContext<ContextValue<ColorSliderProps, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorSlider(props: ColorSliderProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSliderContext);\n let {UNSAFE_className = '', UNSAFE_style, styles} = props;\n let containerRef = useDOMRef(ref);\n let trackRef = useRef(null);\n let {locale} = useLocale();\n\n return (\n <AriaColorSlider\n {...props}\n ref={containerRef}\n style={UNSAFE_style}\n // The visual label is hidden when vertical, so make it an aria-label instead.\n aria-label={props['aria-label'] || (props.orientation === 'vertical' ? props.label : undefined)}\n className={renderProps => UNSAFE_className + style({\n width: {\n orientation: {\n horizontal: 192\n }\n },\n height: {\n orientation: {\n vertical: 192\n }\n },\n display: {\n orientation: {\n horizontal: 'grid',\n vertical: 'block'\n }\n },\n gridTemplateColumns: ['1fr', 'auto'],\n gridTemplateAreas: [\n 'label output',\n 'track track'\n ],\n rowGap: 4\n }, getAllowedOverrides())(renderProps, styles)}>\n {({isDisabled, orientation, state}) => (<>\n {orientation === 'horizontal' && (props.label || (props.label === undefined && !props['aria-label'] && !props['aria-labelledby'])) && (\n // If no external label, aria-label or aria-labelledby is provided,\n // default to displaying the localized channel value.\n // Specifically check if label is undefined. If label is `null` then display no visible label.\n // A default aria-label is provided by useColorSlider in that case.\n <FieldLabel isDisabled={isDisabled} contextualHelp={props.contextualHelp}>\n {props.label || state.value.getChannelName(props.channel, locale)}\n </FieldLabel>\n )}\n {orientation === 'horizontal' &&\n <SliderOutput\n className={style({\n gridArea: 'output',\n font: 'control',\n cursor: 'default',\n color: {\n default: 'neutral-subdued',\n isDisabled: 'disabled'\n }\n })} />\n }\n <SliderTrack\n ref={trackRef}\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : `${defaultStyle.background}, repeating-conic-gradient(#E1E1E1 0% 25%, white 0% 50%) 50% / 16px 16px`\n })}\n className={style({\n gridArea: 'track',\n width: {\n orientation: {\n horizontal: 'full',\n vertical: 24\n }\n },\n height: {\n orientation: {\n horizontal: 24,\n vertical: 'full'\n }\n },\n borderRadius: 'default',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineOffset: -1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n },\n backgroundColor: {\n isDisabled: 'disabled'\n }\n })}>\n <ColorHandle\n containerRef={trackRef}\n getPosition={() => {\n let x = state.orientation === 'horizontal' ? state.getThumbPercent(0) : 0.5;\n let y = state.orientation === 'horizontal' ? 0.5 : 1 - state.getThumbPercent(0);\n return {x, y};\n }} />\n </SliderTrack>\n </>)}\n </AriaColorSlider>\n );\n}\n\n/**\n * A ColorSlider allows users to adjust an individual channel of a color value.\n */\nlet _ColorSlider = forwardRef(ColorSlider);\nexport {_ColorSlider as ColorSlider};\n"],"names":[],"version":3,"file":"ColorSlider.css.map"}
|
package/dist/ColorSlider.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAuBM,MAAM,0DAAqB,CAAA,GAAA,oBAAY,EAA+D;AAE7G,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,MAAM,EAAC,GAAG;IACpD,IAAI,eAAe,CAAA,GAAA,gBAAQ,EAAE;IAC7B,IAAI,WAAW,CAAA,GAAA,aAAK,EAAE;IACtB,IAAI,UAAC,MAAM,EAAC,GAAG,CAAA,GAAA,gBAAQ;IAEvB,qBACE,gBAAC,CAAA,GAAA,kBAAc;QACZ,GAAG,KAAK;QACT,KAAK;QACL,OAAO;QACP,8EAA8E;QAC9E,cAAY,KAAK,CAAC,aAAa,IAAK,CAAA,MAAM,WAAW,KAAK,aAAa,MAAM,KAAK,GAAG,SAAQ;QAC7F,WAAW,CAAA,cAAe,mBAAmB;;;;;;;;;;;;;;;;;;;;;;cAuBnB,aAAa;kBACtC,CAAC,cAAC,UAAU,eAAE,WAAW,SAAE,KAAK,EAAC,iBAAM;;oBACrC,gBAAgB,gBAAiB,CAAA,MAAM,KAAK,IAAK,MAAM,KAAK,KAAK,aAAa,CAAC,KAAK,CAAC,aAAa,IAAI,CAAC,KAAK,CAAC,kBAAkB,KAC9H,mEAAmE;oBACnE,qDAAqD;oBACrD,8FAA8F;oBAC9F,mEAAmE;kCACnE,gBAAC,CAAA,GAAA,yCAAS;wBAAE,YAAY;wBAAY,gBAAgB,MAAM,cAAc;kCACrE,MAAM,KAAK,IAAI,MAAM,KAAK,CAAC,cAAc,CAAC,MAAM,OAAO,EAAE;;oBAG7D,gBAAgB,8BACf,gBAAC,CAAA,GAAA,mBAAW;wBACV;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCAUJ,gBAAC,CAAA,GAAA,kBAAU;wBACT,KAAK;wBACL,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,CAAC,EAAE,aAAa,UAAU,CAAC,wEAAwE,CAAC;4BAC3I,CAAA;wBACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCA6BA,cAAA,gBAAC,CAAA,GAAA,yCAAU;4BACT,cAAc;4BACd,aAAa;gCACX,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,eAAe,CAAC,KAAK;gCACxE,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,IAAI,MAAM,eAAe,CAAC;gCAC7E,OAAO;uCAAC;uCAAG;gCAAC;4BACd;;;;;;AAKZ;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,iBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSlider.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSlider as AriaColorSlider,\n ColorSliderProps as AriaColorSliderProps,\n ContextValue,\n SliderOutput,\n SliderTrack,\n useLocale\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef, useRef} from 'react';\nimport {DOMRef, DOMRefValue, SpectrumLabelableProps} from '@react-types/shared';\nimport {FieldLabel} from './Field';\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAuBM,MAAM,0DAAqB,CAAA,GAAA,oBAAY,EAA+D;AAE7G,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,MAAM,EAAC,GAAG;IACpD,IAAI,eAAe,CAAA,GAAA,gBAAQ,EAAE;IAC7B,IAAI,WAAW,CAAA,GAAA,aAAK,EAAE;IACtB,IAAI,UAAC,MAAM,EAAC,GAAG,CAAA,GAAA,gBAAQ;IAEvB,qBACE,gBAAC,CAAA,GAAA,kBAAc;QACZ,GAAG,KAAK;QACT,KAAK;QACL,OAAO;QACP,8EAA8E;QAC9E,cAAY,KAAK,CAAC,aAAa,IAAK,CAAA,MAAM,WAAW,KAAK,aAAa,MAAM,KAAK,GAAG,SAAQ;QAC7F,WAAW,CAAA,cAAe,mBAAmB;;;;;;;;;;;;;;;;;;;;;;cAuBnB,aAAa;kBACtC,CAAC,cAAC,UAAU,eAAE,WAAW,SAAE,KAAK,EAAC,iBAAM;;oBACrC,gBAAgB,gBAAiB,CAAA,MAAM,KAAK,IAAK,MAAM,KAAK,KAAK,aAAa,CAAC,KAAK,CAAC,aAAa,IAAI,CAAC,KAAK,CAAC,kBAAkB,KAC9H,mEAAmE;oBACnE,qDAAqD;oBACrD,8FAA8F;oBAC9F,mEAAmE;kCACnE,gBAAC,CAAA,GAAA,yCAAS;wBAAE,YAAY;wBAAY,gBAAgB,MAAM,cAAc;kCACrE,MAAM,KAAK,IAAI,MAAM,KAAK,CAAC,cAAc,CAAC,MAAM,OAAO,EAAE;;oBAG7D,gBAAgB,8BACf,gBAAC,CAAA,GAAA,mBAAW;wBACV;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCAUJ,gBAAC,CAAA,GAAA,kBAAU;wBACT,KAAK;wBACL,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,CAAC,EAAE,aAAa,UAAU,CAAC,wEAAwE,CAAC;4BAC3I,CAAA;wBACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCA6BA,cAAA,gBAAC,CAAA,GAAA,yCAAU;4BACT,cAAc;4BACd,aAAa;gCACX,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,eAAe,CAAC,KAAK;gCACxE,IAAI,IAAI,MAAM,WAAW,KAAK,eAAe,MAAM,IAAI,MAAM,eAAe,CAAC;gCAC7E,OAAO;uCAAC;uCAAG;gCAAC;4BACd;;;;;;AAKZ;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,iBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSlider.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSlider as AriaColorSlider,\n ColorSliderProps as AriaColorSliderProps,\n ContextValue,\n SliderOutput,\n SliderTrack,\n useLocale\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef, useRef} from 'react';\nimport {DOMRef, DOMRefValue, SpectrumLabelableProps} from '@react-types/shared';\nimport {FieldLabel} from './Field';\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSliderProps extends Omit<AriaColorSliderProps, 'children' | 'className' | 'style'>, Pick<SpectrumLabelableProps, 'contextualHelp'>, StyleProps {\n label?: string\n}\n\nexport const ColorSliderContext = createContext<ContextValue<ColorSliderProps, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorSlider(props: ColorSliderProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSliderContext);\n let {UNSAFE_className = '', UNSAFE_style, styles} = props;\n let containerRef = useDOMRef(ref);\n let trackRef = useRef(null);\n let {locale} = useLocale();\n\n return (\n <AriaColorSlider\n {...props}\n ref={containerRef}\n style={UNSAFE_style}\n // The visual label is hidden when vertical, so make it an aria-label instead.\n aria-label={props['aria-label'] || (props.orientation === 'vertical' ? props.label : undefined)}\n className={renderProps => UNSAFE_className + style({\n width: {\n orientation: {\n horizontal: 192\n }\n },\n height: {\n orientation: {\n vertical: 192\n }\n },\n display: {\n orientation: {\n horizontal: 'grid',\n vertical: 'block'\n }\n },\n gridTemplateColumns: ['1fr', 'auto'],\n gridTemplateAreas: [\n 'label output',\n 'track track'\n ],\n rowGap: 4\n }, getAllowedOverrides())(renderProps, styles)}>\n {({isDisabled, orientation, state}) => (<>\n {orientation === 'horizontal' && (props.label || (props.label === undefined && !props['aria-label'] && !props['aria-labelledby'])) && (\n // If no external label, aria-label or aria-labelledby is provided,\n // default to displaying the localized channel value.\n // Specifically check if label is undefined. If label is `null` then display no visible label.\n // A default aria-label is provided by useColorSlider in that case.\n <FieldLabel isDisabled={isDisabled} contextualHelp={props.contextualHelp}>\n {props.label || state.value.getChannelName(props.channel, locale)}\n </FieldLabel>\n )}\n {orientation === 'horizontal' &&\n <SliderOutput\n className={style({\n gridArea: 'output',\n font: 'control',\n cursor: 'default',\n color: {\n default: 'neutral-subdued',\n isDisabled: 'disabled'\n }\n })} />\n }\n <SliderTrack\n ref={trackRef}\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : `${defaultStyle.background}, repeating-conic-gradient(#E1E1E1 0% 25%, white 0% 50%) 50% / 16px 16px`\n })}\n className={style({\n gridArea: 'track',\n width: {\n orientation: {\n horizontal: 'full',\n vertical: 24\n }\n },\n height: {\n orientation: {\n horizontal: 24,\n vertical: 'full'\n }\n },\n borderRadius: 'default',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineOffset: -1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n },\n backgroundColor: {\n isDisabled: 'disabled'\n }\n })}>\n <ColorHandle\n containerRef={trackRef}\n getPosition={() => {\n let x = state.orientation === 'horizontal' ? state.getThumbPercent(0) : 0.5;\n let y = state.orientation === 'horizontal' ? 0.5 : 1 - state.getThumbPercent(0);\n return {x, y};\n }} />\n </SliderTrack>\n </>)}\n </AriaColorSlider>\n );\n}\n\n/**\n * A ColorSlider allows users to adjust an individual channel of a color value.\n */\nlet _ColorSlider = forwardRef(ColorSlider);\nexport {_ColorSlider as ColorSlider};\n"],"names":[],"version":3,"file":"ColorSlider.mjs.map"}
|
package/dist/ColorSwatch.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AAmCM,MAAM,0DAAqB,CAAA,GAAA,0BAAY,EAA+D;AACtG,MAAM,0DAA6B,CAAA,GAAA,0BAAY,EAA0C;AAEhG,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,SAAS,CAAA,GAAA,mCAAQ,EAAE;IACvB,IAAI,MAAM,CAAA,GAAA,uBAAS,EAAE;IACrB,IAAI,QACF,OAAO,KAAK,QAAQ,eACpB,WAAW,KAAK,YAAY,kBAC5B,KAAK,EACN,GAAG;IACJ,IAAI,eAAe,SAAS;IAC5B,QAAQ,CAAA,GAAA,oBAAM,EAAE,IAAM,OAAO,iBAAiB,WAAW,CAAA,GAAA,qCAAS,EAAE,gBAAgB,cAAc;QAAC;KAAa;IAEhH,IAAI,uBACF,gCAAC,CAAA,GAAA,sCAAc;QACZ,GAAG,KAAK;QACT,OAAO;QACP,KAAK;QACL,OAAO,CAAC,SAAC,KAAK,EAAC,GAAM,CAAA;gBACnB,oFAAoF;gBACpF,YAAY,MAAM,eAAe,CAAC,WAAW,IACzC,CAAC,gBAAgB,EAAE,MAAM,EAAE,EAAE,MAAM,4EAA4E,CAAC,GAEhH;YACN,CAAA;QACA,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAyB6B;kBAAC;sBAAM;QAAQ,GAAG,MAAM,MAAM;;IAG1E,+DAA+D;IAC/D,IAAI,KACF,OAAO,IAAI,UAAU,CAAC,QAAQ,OAAO;IAGvC,OAAO;AACT;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,uBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSwatch.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSwatch as AriaColorSwatch,\n ColorSwatchProps as AriaColorSwatchProps,\n ContextValue,\n parseColor\n} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {createContext, forwardRef, JSX, ReactElement, useContext, useMemo} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {getAllowedOverrides, StylesPropWithHeight, UnsafeStyles} from './style-utils' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AAmCM,MAAM,0DAAqB,CAAA,GAAA,0BAAY,EAA+D;AACtG,MAAM,0DAA6B,CAAA,GAAA,0BAAY,EAA0C;AAEhG,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,SAAS,CAAA,GAAA,mCAAQ,EAAE;IACvB,IAAI,MAAM,CAAA,GAAA,uBAAS,EAAE;IACrB,IAAI,QACF,OAAO,KAAK,QAAQ,eACpB,WAAW,KAAK,YAAY,kBAC5B,KAAK,EACN,GAAG;IACJ,IAAI,eAAe,SAAS;IAC5B,QAAQ,CAAA,GAAA,oBAAM,EAAE,IAAM,OAAO,iBAAiB,WAAW,CAAA,GAAA,qCAAS,EAAE,gBAAgB,cAAc;QAAC;KAAa;IAEhH,IAAI,uBACF,gCAAC,CAAA,GAAA,sCAAc;QACZ,GAAG,KAAK;QACT,OAAO;QACP,KAAK;QACL,OAAO,CAAC,SAAC,KAAK,EAAC,GAAM,CAAA;gBACnB,oFAAoF;gBACpF,YAAY,MAAM,eAAe,CAAC,WAAW,IACzC,CAAC,gBAAgB,EAAE,MAAM,EAAE,EAAE,MAAM,4EAA4E,CAAC,GAEhH;YACN,CAAA;QACA,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAyB6B;kBAAC;sBAAM;QAAQ,GAAG,MAAM,MAAM;;IAG1E,+DAA+D;IAC/D,IAAI,KACF,OAAO,IAAI,UAAU,CAAC,QAAQ,OAAO;IAGvC,OAAO;AACT;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,uBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSwatch.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSwatch as AriaColorSwatch,\n ColorSwatchProps as AriaColorSwatchProps,\n ContextValue,\n parseColor\n} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {createContext, forwardRef, JSX, ReactElement, useContext, useMemo} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {getAllowedOverrides, StylesPropWithHeight, UnsafeStyles} from './style-utils' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSwatchProps extends Omit<AriaColorSwatchProps, 'className' | 'style'>, UnsafeStyles {\n /**\n * The size of the ColorSwatch.\n * @default 'M'\n */\n size?: 'XS' | 'S' | 'M' | 'L',\n /**\n * The corner rounding of the ColorSwatch.\n * @default 'default'\n */\n rounding?: 'default' | 'none' | 'full',\n /** Spectrum-defined styles, returned by the `style()` macro. */\n styles?: StylesPropWithHeight\n}\n\ninterface SpectrumColorSwatchContextValue extends Pick<ColorSwatchProps, 'size' | 'rounding'> {\n useWrapper: (swatch: ReactElement, color: Color, rounding: ColorSwatchProps['rounding']) => JSX.Element\n}\n\nexport const ColorSwatchContext = createContext<ContextValue<ColorSwatchProps, DOMRefValue<HTMLDivElement>>>(null);\nexport const InternalColorSwatchContext = createContext<SpectrumColorSwatchContextValue | null>(null);\n\nfunction ColorSwatch(props: ColorSwatchProps, ref: DOMRef<HTMLDivElement>): JSX.Element {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSwatchContext);\n let domRef = useDOMRef(ref);\n let ctx = useContext(InternalColorSwatchContext);\n let {\n size = ctx?.size || 'M',\n rounding = ctx?.rounding || 'default',\n color\n } = props;\n let nonNullValue = color || '#fff0';\n color = useMemo(() => typeof nonNullValue === 'string' ? parseColor(nonNullValue) : nonNullValue, [nonNullValue]);\n\n let swatch = (\n <AriaColorSwatch\n {...props}\n color={color}\n ref={domRef}\n style={({color}) => ({\n // TODO: should there be a distinction between transparent and no value (e.g. null)?\n background: color.getChannelValue('alpha') > 0\n ? `linear-gradient(${color}, ${color}), repeating-conic-gradient(#e6e6e6 0% 25%, white 0% 50%) 0% 50% / 16px 16px`\n // Red slash to indicate there is no selected color.\n : 'linear-gradient(to bottom right, transparent calc(50% - 2px), var(--slash-color) calc(50% - 2px) calc(50% + 2px), transparent calc(50% + 2px)) no-repeat'\n })}\n className={style({\n size: {\n size: {\n XS: 16,\n S: 24,\n M: 32,\n L: 40\n }\n },\n borderRadius: {\n rounding: {\n default: 'sm',\n none: 'none',\n full: 'full'\n }\n },\n borderColor: 'gray-1000/42',\n borderWidth: 1,\n borderStyle: 'solid',\n boxSizing: 'border-box',\n forcedColorAdjust: 'none',\n '--slash-color': {\n type: 'color',\n value: 'red-900'\n }\n }, getAllowedOverrides({height: true}))({size, rounding}, props.styles)} />\n );\n\n // ColorSwatchPicker needs to wrap the swatch in a ListBoxItem.\n if (ctx) {\n return ctx.useWrapper(swatch, color, rounding);\n }\n\n return swatch;\n}\n\n/**\n * A ColorSwatch displays a preview of a selected color.\n */\nlet _ColorSwatch = forwardRef(ColorSwatch);\nexport {_ColorSwatch as ColorSwatch};\n"],"names":[],"version":3,"file":"ColorSwatch.cjs.map"}
|
package/dist/ColorSwatch.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAwEiB;;;;AAAA;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AAAA;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA","sources":["packages/@react-spectrum/s2/src/ColorSwatch.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSwatch as AriaColorSwatch,\n ColorSwatchProps as AriaColorSwatchProps,\n ContextValue,\n parseColor\n} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {createContext, forwardRef, JSX, ReactElement, useContext, useMemo} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {getAllowedOverrides, StylesPropWithHeight, UnsafeStyles} from './style-utils' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":"AAwEiB;;;;AAAA;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AAAA;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;IAAA","sources":["packages/@react-spectrum/s2/src/ColorSwatch.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSwatch as AriaColorSwatch,\n ColorSwatchProps as AriaColorSwatchProps,\n ContextValue,\n parseColor\n} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {createContext, forwardRef, JSX, ReactElement, useContext, useMemo} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {getAllowedOverrides, StylesPropWithHeight, UnsafeStyles} from './style-utils' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSwatchProps extends Omit<AriaColorSwatchProps, 'className' | 'style'>, UnsafeStyles {\n /**\n * The size of the ColorSwatch.\n * @default 'M'\n */\n size?: 'XS' | 'S' | 'M' | 'L',\n /**\n * The corner rounding of the ColorSwatch.\n * @default 'default'\n */\n rounding?: 'default' | 'none' | 'full',\n /** Spectrum-defined styles, returned by the `style()` macro. */\n styles?: StylesPropWithHeight\n}\n\ninterface SpectrumColorSwatchContextValue extends Pick<ColorSwatchProps, 'size' | 'rounding'> {\n useWrapper: (swatch: ReactElement, color: Color, rounding: ColorSwatchProps['rounding']) => JSX.Element\n}\n\nexport const ColorSwatchContext = createContext<ContextValue<ColorSwatchProps, DOMRefValue<HTMLDivElement>>>(null);\nexport const InternalColorSwatchContext = createContext<SpectrumColorSwatchContextValue | null>(null);\n\nfunction ColorSwatch(props: ColorSwatchProps, ref: DOMRef<HTMLDivElement>): JSX.Element {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSwatchContext);\n let domRef = useDOMRef(ref);\n let ctx = useContext(InternalColorSwatchContext);\n let {\n size = ctx?.size || 'M',\n rounding = ctx?.rounding || 'default',\n color\n } = props;\n let nonNullValue = color || '#fff0';\n color = useMemo(() => typeof nonNullValue === 'string' ? parseColor(nonNullValue) : nonNullValue, [nonNullValue]);\n\n let swatch = (\n <AriaColorSwatch\n {...props}\n color={color}\n ref={domRef}\n style={({color}) => ({\n // TODO: should there be a distinction between transparent and no value (e.g. null)?\n background: color.getChannelValue('alpha') > 0\n ? `linear-gradient(${color}, ${color}), repeating-conic-gradient(#e6e6e6 0% 25%, white 0% 50%) 0% 50% / 16px 16px`\n // Red slash to indicate there is no selected color.\n : 'linear-gradient(to bottom right, transparent calc(50% - 2px), var(--slash-color) calc(50% - 2px) calc(50% + 2px), transparent calc(50% + 2px)) no-repeat'\n })}\n className={style({\n size: {\n size: {\n XS: 16,\n S: 24,\n M: 32,\n L: 40\n }\n },\n borderRadius: {\n rounding: {\n default: 'sm',\n none: 'none',\n full: 'full'\n }\n },\n borderColor: 'gray-1000/42',\n borderWidth: 1,\n borderStyle: 'solid',\n boxSizing: 'border-box',\n forcedColorAdjust: 'none',\n '--slash-color': {\n type: 'color',\n value: 'red-900'\n }\n }, getAllowedOverrides({height: true}))({size, rounding}, props.styles)} />\n );\n\n // ColorSwatchPicker needs to wrap the swatch in a ListBoxItem.\n if (ctx) {\n return ctx.useWrapper(swatch, color, rounding);\n }\n\n return swatch;\n}\n\n/**\n * A ColorSwatch displays a preview of a selected color.\n */\nlet _ColorSwatch = forwardRef(ColorSwatch);\nexport {_ColorSwatch as ColorSwatch};\n"],"names":[],"version":3,"file":"ColorSwatch.css.map"}
|
package/dist/ColorSwatch.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AAmCM,MAAM,0DAAqB,CAAA,GAAA,oBAAY,EAA+D;AACtG,MAAM,0DAA6B,CAAA,GAAA,oBAAY,EAA0C;AAEhG,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,SAAS,CAAA,GAAA,gBAAQ,EAAE;IACvB,IAAI,MAAM,CAAA,GAAA,iBAAS,EAAE;IACrB,IAAI,QACF,OAAO,KAAK,QAAQ,eACpB,WAAW,KAAK,YAAY,kBAC5B,KAAK,EACN,GAAG;IACJ,IAAI,eAAe,SAAS;IAC5B,QAAQ,CAAA,GAAA,cAAM,EAAE,IAAM,OAAO,iBAAiB,WAAW,CAAA,GAAA,iBAAS,EAAE,gBAAgB,cAAc;QAAC;KAAa;IAEhH,IAAI,uBACF,gBAAC,CAAA,GAAA,kBAAc;QACZ,GAAG,KAAK;QACT,OAAO;QACP,KAAK;QACL,OAAO,CAAC,SAAC,KAAK,EAAC,GAAM,CAAA;gBACnB,oFAAoF;gBACpF,YAAY,MAAM,eAAe,CAAC,WAAW,IACzC,CAAC,gBAAgB,EAAE,MAAM,EAAE,EAAE,MAAM,4EAA4E,CAAC,GAEhH;YACN,CAAA;QACA,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAyB6B;kBAAC;sBAAM;QAAQ,GAAG,MAAM,MAAM;;IAG1E,+DAA+D;IAC/D,IAAI,KACF,OAAO,IAAI,UAAU,CAAC,QAAQ,OAAO;IAGvC,OAAO;AACT;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,iBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSwatch.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSwatch as AriaColorSwatch,\n ColorSwatchProps as AriaColorSwatchProps,\n ContextValue,\n parseColor\n} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {createContext, forwardRef, JSX, ReactElement, useContext, useMemo} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {getAllowedOverrides, StylesPropWithHeight, UnsafeStyles} from './style-utils' with {type: 'macro'};\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AAmCM,MAAM,0DAAqB,CAAA,GAAA,oBAAY,EAA+D;AACtG,MAAM,0DAA6B,CAAA,GAAA,oBAAY,EAA0C;AAEhG,SAAS,kCAAY,KAAuB,EAAE,GAA2B;IACvE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,SAAS,CAAA,GAAA,gBAAQ,EAAE;IACvB,IAAI,MAAM,CAAA,GAAA,iBAAS,EAAE;IACrB,IAAI,QACF,OAAO,KAAK,QAAQ,eACpB,WAAW,KAAK,YAAY,kBAC5B,KAAK,EACN,GAAG;IACJ,IAAI,eAAe,SAAS;IAC5B,QAAQ,CAAA,GAAA,cAAM,EAAE,IAAM,OAAO,iBAAiB,WAAW,CAAA,GAAA,iBAAS,EAAE,gBAAgB,cAAc;QAAC;KAAa;IAEhH,IAAI,uBACF,gBAAC,CAAA,GAAA,kBAAc;QACZ,GAAG,KAAK;QACT,OAAO;QACP,KAAK;QACL,OAAO,CAAC,SAAC,KAAK,EAAC,GAAM,CAAA;gBACnB,oFAAoF;gBACpF,YAAY,MAAM,eAAe,CAAC,WAAW,IACzC,CAAC,gBAAgB,EAAE,MAAM,EAAE,EAAE,MAAM,4EAA4E,CAAC,GAEhH;YACN,CAAA;QACA,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAyB6B;kBAAC;sBAAM;QAAQ,GAAG,MAAM,MAAM;;IAG1E,+DAA+D;IAC/D,IAAI,KACF,OAAO,IAAI,UAAU,CAAC,QAAQ,OAAO;IAGvC,OAAO;AACT;AAEA;;CAEC,GACD,IAAI,0DAAe,CAAA,GAAA,iBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorSwatch.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorSwatch as AriaColorSwatch,\n ColorSwatchProps as AriaColorSwatchProps,\n ContextValue,\n parseColor\n} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {createContext, forwardRef, JSX, ReactElement, useContext, useMemo} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {getAllowedOverrides, StylesPropWithHeight, UnsafeStyles} from './style-utils' with {type: 'macro'};\nimport {style} from '../style' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSwatchProps extends Omit<AriaColorSwatchProps, 'className' | 'style'>, UnsafeStyles {\n /**\n * The size of the ColorSwatch.\n * @default 'M'\n */\n size?: 'XS' | 'S' | 'M' | 'L',\n /**\n * The corner rounding of the ColorSwatch.\n * @default 'default'\n */\n rounding?: 'default' | 'none' | 'full',\n /** Spectrum-defined styles, returned by the `style()` macro. */\n styles?: StylesPropWithHeight\n}\n\ninterface SpectrumColorSwatchContextValue extends Pick<ColorSwatchProps, 'size' | 'rounding'> {\n useWrapper: (swatch: ReactElement, color: Color, rounding: ColorSwatchProps['rounding']) => JSX.Element\n}\n\nexport const ColorSwatchContext = createContext<ContextValue<ColorSwatchProps, DOMRefValue<HTMLDivElement>>>(null);\nexport const InternalColorSwatchContext = createContext<SpectrumColorSwatchContextValue | null>(null);\n\nfunction ColorSwatch(props: ColorSwatchProps, ref: DOMRef<HTMLDivElement>): JSX.Element {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSwatchContext);\n let domRef = useDOMRef(ref);\n let ctx = useContext(InternalColorSwatchContext);\n let {\n size = ctx?.size || 'M',\n rounding = ctx?.rounding || 'default',\n color\n } = props;\n let nonNullValue = color || '#fff0';\n color = useMemo(() => typeof nonNullValue === 'string' ? parseColor(nonNullValue) : nonNullValue, [nonNullValue]);\n\n let swatch = (\n <AriaColorSwatch\n {...props}\n color={color}\n ref={domRef}\n style={({color}) => ({\n // TODO: should there be a distinction between transparent and no value (e.g. null)?\n background: color.getChannelValue('alpha') > 0\n ? `linear-gradient(${color}, ${color}), repeating-conic-gradient(#e6e6e6 0% 25%, white 0% 50%) 0% 50% / 16px 16px`\n // Red slash to indicate there is no selected color.\n : 'linear-gradient(to bottom right, transparent calc(50% - 2px), var(--slash-color) calc(50% - 2px) calc(50% + 2px), transparent calc(50% + 2px)) no-repeat'\n })}\n className={style({\n size: {\n size: {\n XS: 16,\n S: 24,\n M: 32,\n L: 40\n }\n },\n borderRadius: {\n rounding: {\n default: 'sm',\n none: 'none',\n full: 'full'\n }\n },\n borderColor: 'gray-1000/42',\n borderWidth: 1,\n borderStyle: 'solid',\n boxSizing: 'border-box',\n forcedColorAdjust: 'none',\n '--slash-color': {\n type: 'color',\n value: 'red-900'\n }\n }, getAllowedOverrides({height: true}))({size, rounding}, props.styles)} />\n );\n\n // ColorSwatchPicker needs to wrap the swatch in a ListBoxItem.\n if (ctx) {\n return ctx.useWrapper(swatch, color, rounding);\n }\n\n return swatch;\n}\n\n/**\n * A ColorSwatch displays a preview of a selected color.\n */\nlet _ColorSwatch = forwardRef(ColorSwatch);\nexport {_ColorSwatch as ColorSwatch};\n"],"names":[],"version":3,"file":"ColorSwatch.mjs.map"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAgCM,MAAM,0DAA2B,CAAA,GAAA,0BAAY,EAA8E;AAElI,SAAS,wCAAkB,KAA6B,EAAE,GAA2B;IACnF,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,WACF,UAAU,iBACV,OAAO,eACP,WAAW,QACX,GAAG,YACJ,GAAG;IACJ,IAAI,SAAS,CAAA,GAAA,mCAAQ,EAAE;IAEvB,qBACE,gCAAC,CAAA,GAAA,4CAAoB;QAClB,GAAG,UAAU;QACd,KAAK;QACL,WAAW,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;UAUV;qBAAC;QAAO,GAAG,MAAM,MAAM;kBACjD,cAAA,gCAAC,CAAA,GAAA,oDAAyB,EAAE,QAAQ;YAAC,OAAO;4BAAC;sBAAY;0BAAM;YAAQ;sBACpE,MAAM,QAAQ;;;AAIvB;AAEA;;CAEC,GACD,IAAI,0DAAqB,CAAA,GAAA,uBAAS,EAAE;AAGpC,SAAS,iCAAW,MAAoB,EAAE,KAAY,EAAE,QAAsC;IAC5F,qBACE,gCAAC,CAAA,GAAA,gDAAwB;QACvB,OAAO;QACP,WAAW,CAAA,cAAe;;;;;;;;;;;;;;;;;;;;;;eAUvB;gBAAC,GAAG,WAAW;0BAAE;YAAQ;kBAC3B,CAAC,cAAC,UAAU,EAAC,iBAAM;;oBACjB;oBACA,4BACC,gCAAC;wBACC,aAAW;wBACX,SAAS;;;;;AAmBrB","sources":["packages/@react-spectrum/s2/src/ColorSwatchPicker.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ColorSwatchPicker as AriaColorSwatchPicker, ColorSwatchPickerItem as AriaColorSwatchPickerItem, ContextValue, SlotProps} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {ColorSwatchProps, InternalColorSwatchContext} from './ColorSwatch';\nimport {createContext, forwardRef, ReactElement, ReactNode} from 'react';\nimport {DOMRef, DOMRefValue, ValueBase} from '@react-types/shared';\nimport {focusRing,
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAgCM,MAAM,0DAA2B,CAAA,GAAA,0BAAY,EAA8E;AAElI,SAAS,wCAAkB,KAA6B,EAAE,GAA2B;IACnF,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,WACF,UAAU,iBACV,OAAO,eACP,WAAW,QACX,GAAG,YACJ,GAAG;IACJ,IAAI,SAAS,CAAA,GAAA,mCAAQ,EAAE;IAEvB,qBACE,gCAAC,CAAA,GAAA,4CAAoB;QAClB,GAAG,UAAU;QACd,KAAK;QACL,WAAW,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;UAUV;qBAAC;QAAO,GAAG,MAAM,MAAM;kBACjD,cAAA,gCAAC,CAAA,GAAA,oDAAyB,EAAE,QAAQ;YAAC,OAAO;4BAAC;sBAAY;0BAAM;YAAQ;sBACpE,MAAM,QAAQ;;;AAIvB;AAEA;;CAEC,GACD,IAAI,0DAAqB,CAAA,GAAA,uBAAS,EAAE;AAGpC,SAAS,iCAAW,MAAoB,EAAE,KAAY,EAAE,QAAsC;IAC5F,qBACE,gCAAC,CAAA,GAAA,gDAAwB;QACvB,OAAO;QACP,WAAW,CAAA,cAAe;;;;;;;;;;;;;;;;;;;;;;eAUvB;gBAAC,GAAG,WAAW;0BAAE;YAAQ;kBAC3B,CAAC,cAAC,UAAU,EAAC,iBAAM;;oBACjB;oBACA,4BACC,gCAAC;wBACC,aAAW;wBACX,SAAS;;;;;AAmBrB","sources":["packages/@react-spectrum/s2/src/ColorSwatchPicker.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ColorSwatchPicker as AriaColorSwatchPicker, ColorSwatchPickerItem as AriaColorSwatchPickerItem, ContextValue, SlotProps} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {ColorSwatchProps, InternalColorSwatchContext} from './ColorSwatch';\nimport {createContext, forwardRef, ReactElement, ReactNode} from 'react';\nimport {DOMRef, DOMRefValue, ValueBase} from '@react-types/shared';\nimport {focusRing, size as sizeValue, style} from '../style' with {type: 'macro'};\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSwatchPickerProps extends ValueBase<string | Color, Color>, StyleProps, SlotProps {\n /** The ColorSwatches within the ColorSwatchPicker. */\n children: ReactNode,\n /**\n * The amount of padding between the swatches.\n * @default 'regular'\n */\n density?: 'compact' | 'regular' | 'spacious',\n /**\n * The size of the color swatches.\n * @default 'M'\n */\n size?: 'XS' | 'S' | 'M' | 'L',\n /**\n * The corner rounding of the color swatches.\n * @default 'none'\n */\n rounding?: 'none' | 'default' | 'full'\n}\n\nexport const ColorSwatchPickerContext = createContext<ContextValue<Partial<ColorSwatchPickerProps>, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorSwatchPicker(props: ColorSwatchPickerProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSwatchPickerContext);\n let {\n density = 'regular',\n size = 'M',\n rounding = 'none',\n ...otherProps\n } = props;\n let domRef = useDOMRef(ref);\n\n return (\n <AriaColorSwatchPicker\n {...otherProps}\n ref={domRef}\n className={props.UNSAFE_className + style({\n display: 'flex',\n flexWrap: 'wrap',\n gap: {\n density: {\n compact: sizeValue(2),\n regular: 4,\n spacious: sizeValue(6)\n }\n }\n }, getAllowedOverrides())({density}, props.styles)}>\n <InternalColorSwatchContext.Provider value={{useWrapper, size, rounding}}>\n {props.children}\n </InternalColorSwatchContext.Provider>\n </AriaColorSwatchPicker>\n );\n}\n\n/**\n * A ColorSwatchPicker displays a list of color swatches and allows a user to select one of them.\n */\nlet _ColorSwatchPicker = forwardRef(ColorSwatchPicker);\nexport {_ColorSwatchPicker as ColorSwatchPicker};\n\nfunction useWrapper(swatch: ReactElement, color: Color, rounding: ColorSwatchProps['rounding']) {\n return (\n <AriaColorSwatchPickerItem\n color={color}\n className={renderProps => style({\n ...focusRing(),\n position: 'relative',\n borderRadius: {\n rounding: {\n none: 'none',\n default: 'sm',\n full: 'full'\n }\n }\n })({...renderProps, rounding})}>\n {({isSelected}) => (<>\n {swatch}\n {isSelected && (\n <div\n aria-hidden\n className={style({\n position: 'absolute',\n pointerEvents: 'none',\n inset: 0,\n boxSizing: 'border-box',\n borderColor: 'gray-900',\n borderStyle: 'solid',\n borderWidth: 2,\n outlineColor: 'gray-25',\n outlineStyle: 'solid',\n outlineWidth: 2,\n outlineOffset: -4,\n forcedColorAdjust: 'none',\n borderRadius: '[inherit]'\n })} />\n )}\n </>)}\n </AriaColorSwatchPickerItem>\n );\n}\n"],"names":[],"version":3,"file":"ColorSwatchPicker.cjs.map"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AC0D0C;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EA4BV;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAgBT;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AA5CmB;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;;;AA4BV;EAAA;IAAA;;;;;;AAgBT","sources":["26baf334ec196f8c","packages/@react-spectrum/s2/src/ColorSwatchPicker.tsx"],"sourcesContent":["@import \"e16c0c8e50c537a4\";\n@import \"6325f62168102e9d\";\n@import \"aa108d3a66fddade\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ColorSwatchPicker as AriaColorSwatchPicker, ColorSwatchPickerItem as AriaColorSwatchPickerItem, ContextValue, SlotProps} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {ColorSwatchProps, InternalColorSwatchContext} from './ColorSwatch';\nimport {createContext, forwardRef, ReactElement, ReactNode} from 'react';\nimport {DOMRef, DOMRefValue, ValueBase} from '@react-types/shared';\nimport {focusRing,
|
|
1
|
+
{"mappings":"AC0D0C;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EA4BV;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAgBT;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AA5CmB;;AAAA;EAAA;IAAA;;;;IAAA;;;;IAAA;;;;IAAA;;;;;;AA4BV;EAAA;IAAA;;;;;;AAgBT","sources":["26baf334ec196f8c","packages/@react-spectrum/s2/src/ColorSwatchPicker.tsx"],"sourcesContent":["@import \"e16c0c8e50c537a4\";\n@import \"6325f62168102e9d\";\n@import \"aa108d3a66fddade\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ColorSwatchPicker as AriaColorSwatchPicker, ColorSwatchPickerItem as AriaColorSwatchPickerItem, ContextValue, SlotProps} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {ColorSwatchProps, InternalColorSwatchContext} from './ColorSwatch';\nimport {createContext, forwardRef, ReactElement, ReactNode} from 'react';\nimport {DOMRef, DOMRefValue, ValueBase} from '@react-types/shared';\nimport {focusRing, size as sizeValue, style} from '../style' with {type: 'macro'};\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSwatchPickerProps extends ValueBase<string | Color, Color>, StyleProps, SlotProps {\n /** The ColorSwatches within the ColorSwatchPicker. */\n children: ReactNode,\n /**\n * The amount of padding between the swatches.\n * @default 'regular'\n */\n density?: 'compact' | 'regular' | 'spacious',\n /**\n * The size of the color swatches.\n * @default 'M'\n */\n size?: 'XS' | 'S' | 'M' | 'L',\n /**\n * The corner rounding of the color swatches.\n * @default 'none'\n */\n rounding?: 'none' | 'default' | 'full'\n}\n\nexport const ColorSwatchPickerContext = createContext<ContextValue<Partial<ColorSwatchPickerProps>, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorSwatchPicker(props: ColorSwatchPickerProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSwatchPickerContext);\n let {\n density = 'regular',\n size = 'M',\n rounding = 'none',\n ...otherProps\n } = props;\n let domRef = useDOMRef(ref);\n\n return (\n <AriaColorSwatchPicker\n {...otherProps}\n ref={domRef}\n className={props.UNSAFE_className + style({\n display: 'flex',\n flexWrap: 'wrap',\n gap: {\n density: {\n compact: sizeValue(2),\n regular: 4,\n spacious: sizeValue(6)\n }\n }\n }, getAllowedOverrides())({density}, props.styles)}>\n <InternalColorSwatchContext.Provider value={{useWrapper, size, rounding}}>\n {props.children}\n </InternalColorSwatchContext.Provider>\n </AriaColorSwatchPicker>\n );\n}\n\n/**\n * A ColorSwatchPicker displays a list of color swatches and allows a user to select one of them.\n */\nlet _ColorSwatchPicker = forwardRef(ColorSwatchPicker);\nexport {_ColorSwatchPicker as ColorSwatchPicker};\n\nfunction useWrapper(swatch: ReactElement, color: Color, rounding: ColorSwatchProps['rounding']) {\n return (\n <AriaColorSwatchPickerItem\n color={color}\n className={renderProps => style({\n ...focusRing(),\n position: 'relative',\n borderRadius: {\n rounding: {\n none: 'none',\n default: 'sm',\n full: 'full'\n }\n }\n })({...renderProps, rounding})}>\n {({isSelected}) => (<>\n {swatch}\n {isSelected && (\n <div\n aria-hidden\n className={style({\n position: 'absolute',\n pointerEvents: 'none',\n inset: 0,\n boxSizing: 'border-box',\n borderColor: 'gray-900',\n borderStyle: 'solid',\n borderWidth: 2,\n outlineColor: 'gray-25',\n outlineStyle: 'solid',\n outlineWidth: 2,\n outlineOffset: -4,\n forcedColorAdjust: 'none',\n borderRadius: '[inherit]'\n })} />\n )}\n </>)}\n </AriaColorSwatchPickerItem>\n );\n}\n"],"names":[],"version":3,"file":"ColorSwatchPicker.css.map"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAgCM,MAAM,0DAA2B,CAAA,GAAA,oBAAY,EAA8E;AAElI,SAAS,wCAAkB,KAA6B,EAAE,GAA2B;IACnF,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,WACF,UAAU,iBACV,OAAO,eACP,WAAW,QACX,GAAG,YACJ,GAAG;IACJ,IAAI,SAAS,CAAA,GAAA,gBAAQ,EAAE;IAEvB,qBACE,gBAAC,CAAA,GAAA,wBAAoB;QAClB,GAAG,UAAU;QACd,KAAK;QACL,WAAW,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;UAUV;qBAAC;QAAO,GAAG,MAAM,MAAM;kBACjD,cAAA,gBAAC,CAAA,GAAA,yCAAyB,EAAE,QAAQ;YAAC,OAAO;4BAAC;sBAAY;0BAAM;YAAQ;sBACpE,MAAM,QAAQ;;;AAIvB;AAEA;;CAEC,GACD,IAAI,0DAAqB,CAAA,GAAA,iBAAS,EAAE;AAGpC,SAAS,iCAAW,MAAoB,EAAE,KAAY,EAAE,QAAsC;IAC5F,qBACE,gBAAC,CAAA,GAAA,4BAAwB;QACvB,OAAO;QACP,WAAW,CAAA,cAAe;;;;;;;;;;;;;;;;;;;;;;eAUvB;gBAAC,GAAG,WAAW;0BAAE;YAAQ;kBAC3B,CAAC,cAAC,UAAU,EAAC,iBAAM;;oBACjB;oBACA,4BACC,gBAAC;wBACC,aAAW;wBACX,SAAS;;;;;AAmBrB","sources":["packages/@react-spectrum/s2/src/ColorSwatchPicker.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ColorSwatchPicker as AriaColorSwatchPicker, ColorSwatchPickerItem as AriaColorSwatchPickerItem, ContextValue, SlotProps} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {ColorSwatchProps, InternalColorSwatchContext} from './ColorSwatch';\nimport {createContext, forwardRef, ReactElement, ReactNode} from 'react';\nimport {DOMRef, DOMRefValue, ValueBase} from '@react-types/shared';\nimport {focusRing,
|
|
1
|
+
{"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAgCM,MAAM,0DAA2B,CAAA,GAAA,oBAAY,EAA8E;AAElI,SAAS,wCAAkB,KAA6B,EAAE,GAA2B;IACnF,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,WACF,UAAU,iBACV,OAAO,eACP,WAAW,QACX,GAAG,YACJ,GAAG;IACJ,IAAI,SAAS,CAAA,GAAA,gBAAQ,EAAE;IAEvB,qBACE,gBAAC,CAAA,GAAA,wBAAoB;QAClB,GAAG,UAAU;QACd,KAAK;QACL,WAAW,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;UAUV;qBAAC;QAAO,GAAG,MAAM,MAAM;kBACjD,cAAA,gBAAC,CAAA,GAAA,yCAAyB,EAAE,QAAQ;YAAC,OAAO;4BAAC;sBAAY;0BAAM;YAAQ;sBACpE,MAAM,QAAQ;;;AAIvB;AAEA;;CAEC,GACD,IAAI,0DAAqB,CAAA,GAAA,iBAAS,EAAE;AAGpC,SAAS,iCAAW,MAAoB,EAAE,KAAY,EAAE,QAAsC;IAC5F,qBACE,gBAAC,CAAA,GAAA,4BAAwB;QACvB,OAAO;QACP,WAAW,CAAA,cAAe;;;;;;;;;;;;;;;;;;;;;;eAUvB;gBAAC,GAAG,WAAW;0BAAE;YAAQ;kBAC3B,CAAC,cAAC,UAAU,EAAC,iBAAM;;oBACjB;oBACA,4BACC,gBAAC;wBACC,aAAW;wBACX,SAAS;;;;;AAmBrB","sources":["packages/@react-spectrum/s2/src/ColorSwatchPicker.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ColorSwatchPicker as AriaColorSwatchPicker, ColorSwatchPickerItem as AriaColorSwatchPickerItem, ContextValue, SlotProps} from 'react-aria-components';\nimport {Color} from '@react-types/color';\nimport {ColorSwatchProps, InternalColorSwatchContext} from './ColorSwatch';\nimport {createContext, forwardRef, ReactElement, ReactNode} from 'react';\nimport {DOMRef, DOMRefValue, ValueBase} from '@react-types/shared';\nimport {focusRing, size as sizeValue, style} from '../style' with {type: 'macro'};\nimport {getAllowedOverrides, StyleProps} from './style-utils' with {type: 'macro'};\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorSwatchPickerProps extends ValueBase<string | Color, Color>, StyleProps, SlotProps {\n /** The ColorSwatches within the ColorSwatchPicker. */\n children: ReactNode,\n /**\n * The amount of padding between the swatches.\n * @default 'regular'\n */\n density?: 'compact' | 'regular' | 'spacious',\n /**\n * The size of the color swatches.\n * @default 'M'\n */\n size?: 'XS' | 'S' | 'M' | 'L',\n /**\n * The corner rounding of the color swatches.\n * @default 'none'\n */\n rounding?: 'none' | 'default' | 'full'\n}\n\nexport const ColorSwatchPickerContext = createContext<ContextValue<Partial<ColorSwatchPickerProps>, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorSwatchPicker(props: ColorSwatchPickerProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorSwatchPickerContext);\n let {\n density = 'regular',\n size = 'M',\n rounding = 'none',\n ...otherProps\n } = props;\n let domRef = useDOMRef(ref);\n\n return (\n <AriaColorSwatchPicker\n {...otherProps}\n ref={domRef}\n className={props.UNSAFE_className + style({\n display: 'flex',\n flexWrap: 'wrap',\n gap: {\n density: {\n compact: sizeValue(2),\n regular: 4,\n spacious: sizeValue(6)\n }\n }\n }, getAllowedOverrides())({density}, props.styles)}>\n <InternalColorSwatchContext.Provider value={{useWrapper, size, rounding}}>\n {props.children}\n </InternalColorSwatchContext.Provider>\n </AriaColorSwatchPicker>\n );\n}\n\n/**\n * A ColorSwatchPicker displays a list of color swatches and allows a user to select one of them.\n */\nlet _ColorSwatchPicker = forwardRef(ColorSwatchPicker);\nexport {_ColorSwatchPicker as ColorSwatchPicker};\n\nfunction useWrapper(swatch: ReactElement, color: Color, rounding: ColorSwatchProps['rounding']) {\n return (\n <AriaColorSwatchPickerItem\n color={color}\n className={renderProps => style({\n ...focusRing(),\n position: 'relative',\n borderRadius: {\n rounding: {\n none: 'none',\n default: 'sm',\n full: 'full'\n }\n }\n })({...renderProps, rounding})}>\n {({isSelected}) => (<>\n {swatch}\n {isSelected && (\n <div\n aria-hidden\n className={style({\n position: 'absolute',\n pointerEvents: 'none',\n inset: 0,\n boxSizing: 'border-box',\n borderColor: 'gray-900',\n borderStyle: 'solid',\n borderWidth: 2,\n outlineColor: 'gray-25',\n outlineStyle: 'solid',\n outlineWidth: 2,\n outlineOffset: -4,\n forcedColorAdjust: 'none',\n borderRadius: '[inherit]'\n })} />\n )}\n </>)}\n </AriaColorSwatchPickerItem>\n );\n}\n"],"names":[],"version":3,"file":"ColorSwatchPicker.mjs.map"}
|
package/dist/ColorWheel.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAuBM,MAAM,0DAAoB,CAAA,GAAA,0BAAY,EAA8D;AAE3G,SAAS,iCAAW,KAAsB,EAAE,GAA2B;IACrE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,SAAS,IAAG,GAAG;IACzD,IAAI,eAAe,CAAA,GAAA,mCAAQ,EAAE;IAC7B,kCAAkC;IAClC,IAAI,QAAC,OAAO,KAAI,GAAG;IACnB,IAAI,cAAc,KAAK,GAAG,CAAC,MAAM,OAAO;IACxC,IAAI,YAAY;IAChB,IAAI,cAAc,cAAc;IAChC,qBACE,gCAAC,CAAA,GAAA,qCAAa;QACX,GAAG,KAAK;QACT,aAAa;QACb,aAAa;QACb,KAAK;QACL,OAAO;QACP,WAAW,mBAAmB;kBAC7B,CAAC,cAAC,UAAU,SAAE,KAAK,EAAC,iBAAM;;kCACzB,gCAAC,CAAA,GAAA,0CAAc;wBACb,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,aAAa,UAAU;4BAC9D,CAAA;wBACA;;;;;;;;;;;;;;;;kCAiBF,gCAAC;wBACC,WAAW;;;;;;;;;;;;;;;;;;0BAeR;wCAAC;wBAAU;;kCAChB,gCAAC,CAAA,GAAA,qCAAU;wBACT,cAAc;wBACd,aAAa;4BACX,IAAI,KAAC,CAAC,KAAE,CAAC,EAAC,GAAG,MAAM,gBAAgB,CAAC,cAAc,YAAY;4BAC9D,OAAO;gCACL,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;gCACtC,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;4BACxC;wBACF;;;;;AAIV;AAEA;;CAEC,GACD,IAAI,0DAAc,CAAA,GAAA,uBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorWheel.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorWheel as AriaColorWheel,\n ColorWheelProps as AriaColorWheelProps,\n ColorWheelTrack,\n ContextValue\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAuBM,MAAM,0DAAoB,CAAA,GAAA,0BAAY,EAA8D;AAE3G,SAAS,iCAAW,KAAsB,EAAE,GAA2B;IACrE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,iDAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,SAAS,IAAG,GAAG;IACzD,IAAI,eAAe,CAAA,GAAA,mCAAQ,EAAE;IAC7B,kCAAkC;IAClC,IAAI,QAAC,OAAO,KAAI,GAAG;IACnB,IAAI,cAAc,KAAK,GAAG,CAAC,MAAM,OAAO;IACxC,IAAI,YAAY;IAChB,IAAI,cAAc,cAAc;IAChC,qBACE,gCAAC,CAAA,GAAA,qCAAa;QACX,GAAG,KAAK;QACT,aAAa;QACb,aAAa;QACb,KAAK;QACL,OAAO;QACP,WAAW,mBAAmB;kBAC7B,CAAC,cAAC,UAAU,SAAE,KAAK,EAAC,iBAAM;;kCACzB,gCAAC,CAAA,GAAA,0CAAc;wBACb,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,aAAa,UAAU;4BAC9D,CAAA;wBACA;;;;;;;;;;;;;;;;kCAiBF,gCAAC;wBACC,WAAW;;;;;;;;;;;;;;;;;;0BAeR;wCAAC;wBAAU;;kCAChB,gCAAC,CAAA,GAAA,qCAAU;wBACT,cAAc;wBACd,aAAa;4BACX,IAAI,KAAC,CAAC,KAAE,CAAC,EAAC,GAAG,MAAM,gBAAgB,CAAC,cAAc,YAAY;4BAC9D,OAAO;gCACL,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;gCACtC,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;4BACxC;wBACF;;;;;AAIV;AAEA;;CAEC,GACD,IAAI,0DAAc,CAAA,GAAA,uBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorWheel.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorWheel as AriaColorWheel,\n ColorWheelProps as AriaColorWheelProps,\n ColorWheelTrack,\n ContextValue\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {style} from '../style' with {type: 'macro'};\nimport {StyleProps} from './style-utils';\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorWheelProps extends Omit<AriaColorWheelProps, 'children' | 'className' | 'style' | 'outerRadius' | 'innerRadius'>, StyleProps {\n /**\n * @default 192\n */\n size?: number\n}\n\nexport const ColorWheelContext = createContext<ContextValue<ColorWheelProps, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorWheel(props: ColorWheelProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorWheelContext);\n let {UNSAFE_className = '', UNSAFE_style, styles = ''} = props;\n let containerRef = useDOMRef(ref);\n // TODO: how to do mobile scaling?\n let {size = 192} = props;\n let outerRadius = Math.max(size, 175) / 2;\n let thickness = 24;\n let innerRadius = outerRadius - 24;\n return (\n <AriaColorWheel \n {...props}\n outerRadius={outerRadius}\n innerRadius={innerRadius}\n ref={containerRef}\n style={UNSAFE_style}\n className={UNSAFE_className + styles}>\n {({isDisabled, state}) => (<>\n <ColorWheelTrack\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : defaultStyle.background\n })}\n className={style({\n // Outer border\n borderRadius: 'full',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineOffset: -1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n },\n backgroundColor: {\n isDisabled: 'disabled'\n }\n })} />\n <div\n className={style({\n // Inner border\n position: 'absolute',\n inset: 24,\n pointerEvents: 'none',\n borderRadius: 'full',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n }\n })({isDisabled})} />\n <ColorHandle\n containerRef={containerRef}\n getPosition={() => {\n let {x, y} = state.getThumbPosition(outerRadius - thickness / 2);\n return {\n x: (outerRadius + x) / (outerRadius * 2),\n y: (outerRadius + y) / (outerRadius * 2)\n };\n }} />\n </>)}\n </AriaColorWheel>\n );\n}\n\n/**\n * A ColorWheel allows users to adjust the hue of an HSL or HSB color value on a circular track.\n */\nlet _ColorWheel = forwardRef(ColorWheel);\nexport {_ColorWheel as ColorWheel};\n"],"names":[],"version":3,"file":"ColorWheel.cjs.map"}
|
package/dist/ColorWheel.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"ACyDqB;EAAA;;;;EAAA;;;;EAkBA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AAlBA;;AAAA;EAAA;IAAA;;;;;;AAkBA","sources":["08c4afb7d0604130","packages/@react-spectrum/s2/src/ColorWheel.tsx"],"sourcesContent":["@import \"54eced5f2b164503\";\n@import \"1e65bf1fcba37015\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorWheel as AriaColorWheel,\n ColorWheelProps as AriaColorWheelProps,\n ColorWheelTrack,\n ContextValue\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {style} from '../style
|
|
1
|
+
{"mappings":"ACyDqB;EAAA;;;;EAAA;;;;EAkBA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;EAAA;;;;;AAlBA;;AAAA;EAAA;IAAA;;;;;;AAkBA","sources":["08c4afb7d0604130","packages/@react-spectrum/s2/src/ColorWheel.tsx"],"sourcesContent":["@import \"54eced5f2b164503\";\n@import \"1e65bf1fcba37015\";\n","/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorWheel as AriaColorWheel,\n ColorWheelProps as AriaColorWheelProps,\n ColorWheelTrack,\n ContextValue\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {style} from '../style' with {type: 'macro'};\nimport {StyleProps} from './style-utils';\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorWheelProps extends Omit<AriaColorWheelProps, 'children' | 'className' | 'style' | 'outerRadius' | 'innerRadius'>, StyleProps {\n /**\n * @default 192\n */\n size?: number\n}\n\nexport const ColorWheelContext = createContext<ContextValue<ColorWheelProps, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorWheel(props: ColorWheelProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorWheelContext);\n let {UNSAFE_className = '', UNSAFE_style, styles = ''} = props;\n let containerRef = useDOMRef(ref);\n // TODO: how to do mobile scaling?\n let {size = 192} = props;\n let outerRadius = Math.max(size, 175) / 2;\n let thickness = 24;\n let innerRadius = outerRadius - 24;\n return (\n <AriaColorWheel \n {...props}\n outerRadius={outerRadius}\n innerRadius={innerRadius}\n ref={containerRef}\n style={UNSAFE_style}\n className={UNSAFE_className + styles}>\n {({isDisabled, state}) => (<>\n <ColorWheelTrack\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : defaultStyle.background\n })}\n className={style({\n // Outer border\n borderRadius: 'full',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineOffset: -1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n },\n backgroundColor: {\n isDisabled: 'disabled'\n }\n })} />\n <div\n className={style({\n // Inner border\n position: 'absolute',\n inset: 24,\n pointerEvents: 'none',\n borderRadius: 'full',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n }\n })({isDisabled})} />\n <ColorHandle\n containerRef={containerRef}\n getPosition={() => {\n let {x, y} = state.getThumbPosition(outerRadius - thickness / 2);\n return {\n x: (outerRadius + x) / (outerRadius * 2),\n y: (outerRadius + y) / (outerRadius * 2)\n };\n }} />\n </>)}\n </AriaColorWheel>\n );\n}\n\n/**\n * A ColorWheel allows users to adjust the hue of an HSL or HSB color value on a circular track.\n */\nlet _ColorWheel = forwardRef(ColorWheel);\nexport {_ColorWheel as ColorWheel};\n"],"names":[],"version":3,"file":"ColorWheel.css.map"}
|
package/dist/ColorWheel.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAuBM,MAAM,0DAAoB,CAAA,GAAA,oBAAY,EAA8D;AAE3G,SAAS,iCAAW,KAAsB,EAAE,GAA2B;IACrE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,SAAS,IAAG,GAAG;IACzD,IAAI,eAAe,CAAA,GAAA,gBAAQ,EAAE;IAC7B,kCAAkC;IAClC,IAAI,QAAC,OAAO,KAAI,GAAG;IACnB,IAAI,cAAc,KAAK,GAAG,CAAC,MAAM,OAAO;IACxC,IAAI,YAAY;IAChB,IAAI,cAAc,cAAc;IAChC,qBACE,gBAAC,CAAA,GAAA,iBAAa;QACX,GAAG,KAAK;QACT,aAAa;QACb,aAAa;QACb,KAAK;QACL,OAAO;QACP,WAAW,mBAAmB;kBAC7B,CAAC,cAAC,UAAU,SAAE,KAAK,EAAC,iBAAM;;kCACzB,gBAAC,CAAA,GAAA,sBAAc;wBACb,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,aAAa,UAAU;4BAC9D,CAAA;wBACA;;;;;;;;;;;;;;;;kCAiBF,gBAAC;wBACC,WAAW;;;;;;;;;;;;;;;;;;0BAeR;wCAAC;wBAAU;;kCAChB,gBAAC,CAAA,GAAA,yCAAU;wBACT,cAAc;wBACd,aAAa;4BACX,IAAI,KAAC,CAAC,KAAE,CAAC,EAAC,GAAG,MAAM,gBAAgB,CAAC,cAAc,YAAY;4BAC9D,OAAO;gCACL,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;gCACtC,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;4BACxC;wBACF;;;;;AAIV;AAEA;;CAEC,GACD,IAAI,0DAAc,CAAA,GAAA,iBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorWheel.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorWheel as AriaColorWheel,\n ColorWheelProps as AriaColorWheelProps,\n ColorWheelTrack,\n ContextValue\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {style} from '../style
|
|
1
|
+
{"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAuBM,MAAM,0DAAoB,CAAA,GAAA,oBAAY,EAA8D;AAE3G,SAAS,iCAAW,KAAsB,EAAE,GAA2B;IACrE,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAsB,EAAE,OAAO,KAAK;IACnD,IAAI,oBAAC,mBAAmB,kBAAI,YAAY,UAAE,SAAS,IAAG,GAAG;IACzD,IAAI,eAAe,CAAA,GAAA,gBAAQ,EAAE;IAC7B,kCAAkC;IAClC,IAAI,QAAC,OAAO,KAAI,GAAG;IACnB,IAAI,cAAc,KAAK,GAAG,CAAC,MAAM,OAAO;IACxC,IAAI,YAAY;IAChB,IAAI,cAAc,cAAc;IAChC,qBACE,gBAAC,CAAA,GAAA,iBAAa;QACX,GAAG,KAAK;QACT,aAAa;QACb,aAAa;QACb,KAAK;QACL,OAAO;QACP,WAAW,mBAAmB;kBAC7B,CAAC,cAAC,UAAU,SAAE,KAAK,EAAC,iBAAM;;kCACzB,gBAAC,CAAA,GAAA,sBAAc;wBACb,OAAO,CAAC,gBAAC,YAAY,cAAE,UAAU,EAAC,GAAM,CAAA;gCACtC,YAAY,aAAa,YAAY,aAAa,UAAU;4BAC9D,CAAA;wBACA;;;;;;;;;;;;;;;;kCAiBF,gBAAC;wBACC,WAAW;;;;;;;;;;;;;;;;;;0BAeR;wCAAC;wBAAU;;kCAChB,gBAAC,CAAA,GAAA,yCAAU;wBACT,cAAc;wBACd,aAAa;4BACX,IAAI,KAAC,CAAC,KAAE,CAAC,EAAC,GAAG,MAAM,gBAAgB,CAAC,cAAc,YAAY;4BAC9D,OAAO;gCACL,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;gCACtC,GAAG,AAAC,CAAA,cAAc,CAAA,IAAM,CAAA,cAAc,CAAA;4BACxC;wBACF;;;;;AAIV;AAEA;;CAEC,GACD,IAAI,0DAAc,CAAA,GAAA,iBAAS,EAAE","sources":["packages/@react-spectrum/s2/src/ColorWheel.tsx"],"sourcesContent":["/*\n * Copyright 2024 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {\n ColorWheel as AriaColorWheel,\n ColorWheelProps as AriaColorWheelProps,\n ColorWheelTrack,\n ContextValue\n} from 'react-aria-components';\nimport {ColorHandle} from './ColorHandle';\nimport {createContext, forwardRef} from 'react';\nimport {DOMRef, DOMRefValue} from '@react-types/shared';\nimport {style} from '../style' with {type: 'macro'};\nimport {StyleProps} from './style-utils';\nimport {useDOMRef} from '@react-spectrum/utils';\nimport {useSpectrumContextProps} from './useSpectrumContextProps';\n\nexport interface ColorWheelProps extends Omit<AriaColorWheelProps, 'children' | 'className' | 'style' | 'outerRadius' | 'innerRadius'>, StyleProps {\n /**\n * @default 192\n */\n size?: number\n}\n\nexport const ColorWheelContext = createContext<ContextValue<ColorWheelProps, DOMRefValue<HTMLDivElement>>>(null);\n\nfunction ColorWheel(props: ColorWheelProps, ref: DOMRef<HTMLDivElement>) {\n [props, ref] = useSpectrumContextProps(props, ref, ColorWheelContext);\n let {UNSAFE_className = '', UNSAFE_style, styles = ''} = props;\n let containerRef = useDOMRef(ref);\n // TODO: how to do mobile scaling?\n let {size = 192} = props;\n let outerRadius = Math.max(size, 175) / 2;\n let thickness = 24;\n let innerRadius = outerRadius - 24;\n return (\n <AriaColorWheel \n {...props}\n outerRadius={outerRadius}\n innerRadius={innerRadius}\n ref={containerRef}\n style={UNSAFE_style}\n className={UNSAFE_className + styles}>\n {({isDisabled, state}) => (<>\n <ColorWheelTrack\n style={({defaultStyle, isDisabled}) => ({\n background: isDisabled ? undefined : defaultStyle.background\n })}\n className={style({\n // Outer border\n borderRadius: 'full',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineOffset: -1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n },\n backgroundColor: {\n isDisabled: 'disabled'\n }\n })} />\n <div\n className={style({\n // Inner border\n position: 'absolute',\n inset: 24,\n pointerEvents: 'none',\n borderRadius: 'full',\n outlineColor: {\n default: 'gray-1000/10',\n forcedColors: 'ButtonBorder'\n },\n outlineWidth: 1,\n outlineStyle: {\n default: 'solid',\n isDisabled: 'none'\n }\n })({isDisabled})} />\n <ColorHandle\n containerRef={containerRef}\n getPosition={() => {\n let {x, y} = state.getThumbPosition(outerRadius - thickness / 2);\n return {\n x: (outerRadius + x) / (outerRadius * 2),\n y: (outerRadius + y) / (outerRadius * 2)\n };\n }} />\n </>)}\n </AriaColorWheel>\n );\n}\n\n/**\n * A ColorWheel allows users to adjust the hue of an HSL or HSB color value on a circular track.\n */\nlet _ColorWheel = forwardRef(ColorWheel);\nexport {_ColorWheel as ColorWheel};\n"],"names":[],"version":3,"file":"ColorWheel.mjs.map"}
|
package/dist/ComboBox.cjs
CHANGED
|
@@ -327,6 +327,9 @@ function $a2d5b35c01bebcd6$var$ComboBox(props1, ref) {
|
|
|
327
327
|
}),
|
|
328
328
|
/*#__PURE__*/ (0, $1KUtr$reactjsxruntime.jsx)((0, $1KUtr$reactariacomponents.Button), {
|
|
329
329
|
ref: buttonRef,
|
|
330
|
+
// Prevent press scale from sticking while ComboBox is open.
|
|
331
|
+
// @ts-ignore
|
|
332
|
+
isPressed: false,
|
|
330
333
|
style: (renderProps)=>(0, $2061c83559b50a66$exports.pressScale)(buttonRef)(renderProps),
|
|
331
334
|
className: (renderProps)=>$a2d5b35c01bebcd6$var$inputButton({
|
|
332
335
|
...renderProps,
|