@react-spectrum/checkbox 3.9.13 → 3.9.15

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.
@@ -1,5 +1,5 @@
1
1
  var $bdf3bf7fe71fe120$exports = require("./context.main.js");
2
- require("./vars.6d89b710.css");
2
+ require("./checkbox.155bd254.css");
3
3
  var $591f3ccba6339bdb$exports = require("./checkbox_vars_css.main.js");
4
4
  var $lfSyy$reactariacomponents = require("react-aria-components");
5
5
  var $lfSyy$spectrumiconsuiCheckmarkSmall = require("@spectrum-icons/ui/CheckmarkSmall");
@@ -79,7 +79,7 @@ const $096ccd12d23dd6cc$export$48513f6b9f8ce62d = /*#__PURE__*/ (0, $lfSyy$react
79
79
  }) : /*#__PURE__*/ (0, ($parcel$interopDefault($lfSyy$react))).createElement((0, ($parcel$interopDefault($lfSyy$spectrumiconsuiCheckmarkSmall))), {
80
80
  UNSAFE_className: (0, $lfSyy$reactspectrumutils.classNames)((0, ($parcel$interopDefault($591f3ccba6339bdb$exports))), 'spectrum-Checkbox-checkmark')
81
81
  });
82
- if (groupState) {
82
+ if (groupState && process.env.NODE_ENV !== 'production') {
83
83
  for (let key of [
84
84
  'isSelected',
85
85
  'defaultSelected',
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;AAsBM,MAAM,0DAAW,CAAA,GAAA,uBAAS,EAAE,SAAS,SAAS,KAA4B,EAAE,GAAmC;IACpH,IAAI,gBAAgB;IACpB,IAAI,WAAW,CAAA,GAAA,mBAAK,EAAoB;IACxC,IAAI,SAAS,CAAA,GAAA,yCAAc,EAAE,KAAK;IAElC,CAAC,OAAO,OAAO,GAAG,CAAA,GAAA,0CAAc,EAAE,OAAO,QAAQ,CAAA,GAAA,0CAAc;IAC/D,QAAQ,CAAA,GAAA,6CAAe,EAAE;IACzB,QAAQ,CAAA,GAAA,qCAAW,EAAE;IACrB,IA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,oCAAS,EACP,CAAA,GAAA,mDAAK,GACL,qBACA;YACE,cAAc,WAAW,OAAO;YAChC,oBAAoB;YACpB,4BAA4B,CAAC;YAC7B,cAAc;YACd,eAAe;YACf,cAAc;QAChB,GACA,WAAW,SAAS;qBAGxB,0DAAC,CAAA,GAAA,+BAAQ;QAAE,gBAAgB,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;QAAe,WAAW;qBACtE,0DAAC;QACE,GAAG,UAAU;QACd,KAAK;QACL,WAAW,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;uBAElC,0DAAC;QAAK,WAAW,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;OAA2B,WAC9D,0BACC,0DAAC;QAAK,WAAW,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;OACjC;AAKX","sources":["packages/@react-spectrum/checkbox/src/Checkbox.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 {CheckboxContext, useContextProps} from 'react-aria-components';\nimport {CheckboxGroupContext} from './context';\nimport CheckmarkSmall from '@spectrum-icons/ui/CheckmarkSmall';\nimport {classNames, useFocusableRef, useStyleProps} from '@react-spectrum/utils';\nimport DashSmall from '@spectrum-icons/ui/DashSmall';\nimport {FocusableRef} from '@react-types/shared';\nimport {FocusRing} from '@react-aria/focus';\nimport React, {forwardRef, useContext, useRef} from 'react';\nimport {SpectrumCheckboxProps} from '@react-types/checkbox';\nimport styles from '@adobe/spectrum-css-temp/components/checkbox/vars.css';\nimport {useCheckbox, useCheckboxGroupItem} from '@react-aria/checkbox';\nimport {useFormProps} from '@react-spectrum/form';\nimport {useHover} from '@react-aria/interactions';\nimport {useProviderProps} from '@react-spectrum/provider';\nimport {useToggleState} from '@react-stately/toggle';\n\n/**\n * Checkboxes allow users to select multiple items from a list of individual items,\n * or to mark one individual item as selected.\n */\nexport const Checkbox = forwardRef(function Checkbox(props: SpectrumCheckboxProps, ref: FocusableRef<HTMLLabelElement>) {\n let originalProps = props;\n let inputRef = useRef<HTMLInputElement>(null);\n let domRef = useFocusableRef(ref, inputRef);\n\n [props, domRef] = useContextProps(props, domRef, CheckboxContext);\n props = useProviderProps(props);\n props = useFormProps(props);\n let {\n isIndeterminate = false,\n isEmphasized = false,\n autoFocus,\n children,\n ...otherProps\n } = props;\n let {styleProps} = useStyleProps(otherProps);\n\n // Swap hooks depending on whether this checkbox is inside a CheckboxGroup.\n // This is a bit unorthodox. Typically, hooks cannot be called in a conditional,\n // but since the checkbox won't move in and out of a group, it should be safe.\n let groupState = useContext(CheckboxGroupContext);\n let {inputProps, isInvalid, isDisabled} = groupState\n // eslint-disable-next-line react-hooks/rules-of-hooks\n ? useCheckboxGroupItem({\n ...props,\n // Value is optional for standalone checkboxes, but required for CheckboxGroup items;\n // it's passed explicitly here to avoid typescript error (requires ignore).\n // @ts-ignore\n value: props.value,\n // Only pass isRequired and validationState to react-aria if they came from\n // the props for this individual checkbox, and not from the group via context.\n isRequired: originalProps.isRequired,\n validationState: originalProps.validationState,\n isInvalid: originalProps.isInvalid\n }, groupState, inputRef)\n // eslint-disable-next-line react-hooks/rules-of-hooks\n : useCheckbox(props, useToggleState(props), inputRef);\n\n let {hoverProps, isHovered} = useHover({isDisabled});\n\n let markIcon = isIndeterminate\n ? <DashSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-partialCheckmark')} />\n : <CheckmarkSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-checkmark')} />;\n\n if (groupState) {\n for (let key of ['isSelected', 'defaultSelected', 'isEmphasized']) {\n if (originalProps[key] != null) {\n console.warn(`${key} is unsupported on individual <Checkbox> elements within a <CheckboxGroup>. Please apply these props to the group instead.`);\n }\n }\n if (props.value == null) {\n console.warn('A <Checkbox> element within a <CheckboxGroup> requires a `value` property.');\n }\n }\n\n return (\n <label\n {...styleProps}\n {...hoverProps}\n ref={domRef}\n className={\n classNames(\n styles,\n 'spectrum-Checkbox',\n {\n 'is-checked': inputProps.checked,\n 'is-indeterminate': isIndeterminate,\n 'spectrum-Checkbox--quiet': !isEmphasized,\n 'is-invalid': isInvalid,\n 'is-disabled': isDisabled,\n 'is-hovered': isHovered\n },\n styleProps.className\n )\n }>\n <FocusRing focusRingClass={classNames(styles, 'focus-ring')} autoFocus={autoFocus}>\n <input\n {...inputProps}\n ref={inputRef}\n className={classNames(styles, 'spectrum-Checkbox-input')} />\n </FocusRing>\n <span className={classNames(styles, 'spectrum-Checkbox-box')}>{markIcon}</span>\n {children && (\n <span className={classNames(styles, 'spectrum-Checkbox-label')}>\n {children}\n </span>\n )}\n </label>\n );\n});\n"],"names":[],"version":3,"file":"Checkbox.main.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;AAsBM,MAAM,0DAAW,CAAA,GAAA,uBAAS,EAAE,SAAS,SAAS,KAA4B,EAAE,GAAmC;IACpH,IAAI,gBAAgB;IACpB,IAAI,WAAW,CAAA,GAAA,mBAAK,EAAoB;IACxC,IAAI,SAAS,CAAA,GAAA,yCAAc,EAAE,KAAK;IAElC,CAAC,OAAO,OAAO,GAAG,CAAA,GAAA,0CAAc,EAAE,OAAO,QAAQ,CAAA,GAAA,0CAAc;IAC/D,QAAQ,CAAA,GAAA,6CAAe,EAAE;IACzB,QAAQ,CAAA,GAAA,qCAAW,EAAE;IACrB,IAAI,mBACF,kBAAkB,qBAClB,eAAe,kBACf,SAAS,YACT,QAAQ,EACR,GAAG,YACJ,GAAG;I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ACA;YACE,cAAc,WAAW,OAAO;YAChC,oBAAoB;YACpB,4BAA4B,CAAC;YAC7B,cAAc;YACd,eAAe;YACf,cAAc;QAChB,GACA,WAAW,SAAS;qBAGxB,0DAAC,CAAA,GAAA,+BAAQ;QAAE,gBAAgB,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;QAAe,WAAW;qBACtE,0DAAC;QACE,GAAG,UAAU;QACd,KAAK;QACL,WAAW,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;uBAElC,0DAAC;QAAK,WAAW,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;OAA2B,WAC9D,0BACC,0DAAC;QAAK,WAAW,CAAA,GAAA,oCAAS,EAAE,CAAA,GAAA,mDAAK,GAAG;OACjC;AAKX","sources":["packages/@react-spectrum/checkbox/src/Checkbox.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 {CheckboxContext, useContextProps} from 'react-aria-components';\nimport {CheckboxGroupContext} from './context';\nimport CheckmarkSmall from '@spectrum-icons/ui/CheckmarkSmall';\nimport {classNames, useFocusableRef, useStyleProps} from '@react-spectrum/utils';\nimport DashSmall from '@spectrum-icons/ui/DashSmall';\nimport {FocusableRef} from '@react-types/shared';\nimport {FocusRing} from '@react-aria/focus';\nimport React, {forwardRef, useContext, useRef} from 'react';\nimport {SpectrumCheckboxProps} from '@react-types/checkbox';\nimport styles from '@adobe/spectrum-css-temp/components/checkbox/vars.css';\nimport {useCheckbox, useCheckboxGroupItem} from '@react-aria/checkbox';\nimport {useFormProps} from '@react-spectrum/form';\nimport {useHover} from '@react-aria/interactions';\nimport {useProviderProps} from '@react-spectrum/provider';\nimport {useToggleState} from '@react-stately/toggle';\n\n/**\n * Checkboxes allow users to select multiple items from a list of individual items,\n * or to mark one individual item as selected.\n */\nexport const Checkbox = forwardRef(function Checkbox(props: SpectrumCheckboxProps, ref: FocusableRef<HTMLLabelElement>) {\n let originalProps = props;\n let inputRef = useRef<HTMLInputElement>(null);\n let domRef = useFocusableRef(ref, inputRef);\n\n [props, domRef] = useContextProps(props, domRef, CheckboxContext);\n props = useProviderProps(props);\n props = useFormProps(props);\n let {\n isIndeterminate = false,\n isEmphasized = false,\n autoFocus,\n children,\n ...otherProps\n } = props;\n let {styleProps} = useStyleProps(otherProps);\n\n // Swap hooks depending on whether this checkbox is inside a CheckboxGroup.\n // This is a bit unorthodox. Typically, hooks cannot be called in a conditional,\n // but since the checkbox won't move in and out of a group, it should be safe.\n let groupState = useContext(CheckboxGroupContext);\n let {inputProps, isInvalid, isDisabled} = groupState\n // eslint-disable-next-line react-hooks/rules-of-hooks\n ? useCheckboxGroupItem({\n ...props,\n // Value is optional for standalone checkboxes, but required for CheckboxGroup items;\n // it's passed explicitly here to avoid typescript error (requires ignore).\n // @ts-ignore\n value: props.value,\n // Only pass isRequired and validationState to react-aria if they came from\n // the props for this individual checkbox, and not from the group via context.\n isRequired: originalProps.isRequired,\n validationState: originalProps.validationState,\n isInvalid: originalProps.isInvalid\n }, groupState, inputRef)\n // eslint-disable-next-line react-hooks/rules-of-hooks\n : useCheckbox(props, useToggleState(props), inputRef);\n\n let {hoverProps, isHovered} = useHover({isDisabled});\n\n let markIcon = isIndeterminate\n ? <DashSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-partialCheckmark')} />\n : <CheckmarkSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-checkmark')} />;\n\n if (groupState && process.env.NODE_ENV !== 'production') {\n for (let key of ['isSelected', 'defaultSelected', 'isEmphasized']) {\n if (originalProps[key] != null) {\n console.warn(`${key} is unsupported on individual <Checkbox> elements within a <CheckboxGroup>. Please apply these props to the group instead.`);\n }\n }\n if (props.value == null) {\n console.warn('A <Checkbox> element within a <CheckboxGroup> requires a `value` property.');\n }\n }\n\n return (\n <label\n {...styleProps}\n {...hoverProps}\n ref={domRef}\n className={\n classNames(\n styles,\n 'spectrum-Checkbox',\n {\n 'is-checked': inputProps.checked,\n 'is-indeterminate': isIndeterminate,\n 'spectrum-Checkbox--quiet': !isEmphasized,\n 'is-invalid': isInvalid,\n 'is-disabled': isDisabled,\n 'is-hovered': isHovered\n },\n styleProps.className\n )\n }>\n <FocusRing focusRingClass={classNames(styles, 'focus-ring')} autoFocus={autoFocus}>\n <input\n {...inputProps}\n ref={inputRef}\n className={classNames(styles, 'spectrum-Checkbox-input')} />\n </FocusRing>\n <span className={classNames(styles, 'spectrum-Checkbox-box')}>{markIcon}</span>\n {children && (\n <span className={classNames(styles, 'spectrum-Checkbox-label')}>\n {children}\n </span>\n )}\n </label>\n );\n});\n"],"names":[],"version":3,"file":"Checkbox.main.js.map"}
package/dist/Checkbox.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import {CheckboxGroupContext as $8c8ab388b155237e$export$baf37c4be89255b8} from "./context.mjs";
2
- import "./vars.6d89b710.css";
2
+ import "./checkbox.155bd254.css";
3
3
  import $cvQES$checkbox_vars_cssmodulejs from "./checkbox_vars_css.mjs";
4
4
  import {useContextProps as $cvQES$useContextProps, CheckboxContext as $cvQES$CheckboxContext} from "react-aria-components";
5
5
  import $cvQES$spectrumiconsuiCheckmarkSmall from "@spectrum-icons/ui/CheckmarkSmall";
@@ -73,7 +73,7 @@ const $25b6292d81af2844$export$48513f6b9f8ce62d = /*#__PURE__*/ (0, $cvQES$forwa
73
73
  }) : /*#__PURE__*/ (0, $cvQES$react).createElement((0, $cvQES$spectrumiconsuiCheckmarkSmall), {
74
74
  UNSAFE_className: (0, $cvQES$classNames)((0, ($parcel$interopDefault($cvQES$checkbox_vars_cssmodulejs))), 'spectrum-Checkbox-checkmark')
75
75
  });
76
- if (groupState) {
76
+ if (groupState && process.env.NODE_ENV !== 'production') {
77
77
  for (let key of [
78
78
  'isSelected',
79
79
  'defaultSelected',
@@ -1,5 +1,5 @@
1
1
  import {CheckboxGroupContext as $8c8ab388b155237e$export$baf37c4be89255b8} from "./context.module.js";
2
- import "./vars.6d89b710.css";
2
+ import "./checkbox.155bd254.css";
3
3
  import $cvQES$checkbox_vars_cssmodulejs from "./checkbox_vars_css.module.js";
4
4
  import {useContextProps as $cvQES$useContextProps, CheckboxContext as $cvQES$CheckboxContext} from "react-aria-components";
5
5
  import $cvQES$spectrumiconsuiCheckmarkSmall from "@spectrum-icons/ui/CheckmarkSmall";
@@ -73,7 +73,7 @@ const $25b6292d81af2844$export$48513f6b9f8ce62d = /*#__PURE__*/ (0, $cvQES$forwa
73
73
  }) : /*#__PURE__*/ (0, $cvQES$react).createElement((0, $cvQES$spectrumiconsuiCheckmarkSmall), {
74
74
  UNSAFE_className: (0, $cvQES$classNames)((0, ($parcel$interopDefault($cvQES$checkbox_vars_cssmodulejs))), 'spectrum-Checkbox-checkmark')
75
75
  });
76
- if (groupState) {
76
+ if (groupState && process.env.NODE_ENV !== 'production') {
77
77
  for (let key of [
78
78
  'isSelected',
79
79
  'defaultSelected',
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;AAsBM,MAAM,0DAAW,CAAA,GAAA,iBAAS,EAAE,SAAS,SAAS,KAA4B,EAAE,GAAmC;IACpH,IAAI,gBAAgB;IACpB,IAAI,WAAW,CAAA,GAAA,aAAK,EAAoB;IACxC,IAAI,SAAS,CAAA,GAAA,sBAAc,EAAE,KAAK;IAElC,CAAC,OAAO,OAAO,GAAG,CAAA,GAAA,sBAAc,EAAE,OAAO,QAAQ,CAAA,GAAA,sBAAc;IAC/D,QAAQ,CAAA,GAAA,uBAAe,EA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;QACb,GAAG,UAAU;QACd,KAAK;QACL,WACE,CAAA,GAAA,iBAAS,EACP,CAAA,GAAA,0DAAK,GACL,qBACA;YACE,cAAc,WAAW,OAAO;YAChC,oBAAoB;YACpB,4BAA4B,CAAC;YAC7B,cAAc;YACd,eAAe;YACf,cAAc;QAChB,GACA,WAAW,SAAS;qBAGxB,gCAAC,CAAA,GAAA,gBAAQ;QAAE,gBAAgB,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;QAAe,WAAW;qBACtE,gCAAC;QACE,GAAG,UAAU;QACd,KAAK;QACL,WAAW,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;uBAElC,gCAAC;QAAK,WAAW,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;OAA2B,WAC9D,0BACC,gCAAC;QAAK,WAAW,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;OACjC;AAKX","sources":["packages/@react-spectrum/checkbox/src/Checkbox.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 {CheckboxContext, useContextProps} from 'react-aria-components';\nimport {CheckboxGroupContext} from './context';\nimport CheckmarkSmall from '@spectrum-icons/ui/CheckmarkSmall';\nimport {classNames, useFocusableRef, useStyleProps} from '@react-spectrum/utils';\nimport DashSmall from '@spectrum-icons/ui/DashSmall';\nimport {FocusableRef} from '@react-types/shared';\nimport {FocusRing} from '@react-aria/focus';\nimport React, {forwardRef, useContext, useRef} from 'react';\nimport {SpectrumCheckboxProps} from '@react-types/checkbox';\nimport styles from '@adobe/spectrum-css-temp/components/checkbox/vars.css';\nimport {useCheckbox, useCheckboxGroupItem} from '@react-aria/checkbox';\nimport {useFormProps} from '@react-spectrum/form';\nimport {useHover} from '@react-aria/interactions';\nimport {useProviderProps} from '@react-spectrum/provider';\nimport {useToggleState} from '@react-stately/toggle';\n\n/**\n * Checkboxes allow users to select multiple items from a list of individual items,\n * or to mark one individual item as selected.\n */\nexport const Checkbox = forwardRef(function Checkbox(props: SpectrumCheckboxProps, ref: FocusableRef<HTMLLabelElement>) {\n let originalProps = props;\n let inputRef = useRef<HTMLInputElement>(null);\n let domRef = useFocusableRef(ref, inputRef);\n\n [props, domRef] = useContextProps(props, domRef, CheckboxContext);\n props = useProviderProps(props);\n props = useFormProps(props);\n let {\n isIndeterminate = false,\n isEmphasized = false,\n autoFocus,\n children,\n ...otherProps\n } = props;\n let {styleProps} = useStyleProps(otherProps);\n\n // Swap hooks depending on whether this checkbox is inside a CheckboxGroup.\n // This is a bit unorthodox. Typically, hooks cannot be called in a conditional,\n // but since the checkbox won't move in and out of a group, it should be safe.\n let groupState = useContext(CheckboxGroupContext);\n let {inputProps, isInvalid, isDisabled} = groupState\n // eslint-disable-next-line react-hooks/rules-of-hooks\n ? useCheckboxGroupItem({\n ...props,\n // Value is optional for standalone checkboxes, but required for CheckboxGroup items;\n // it's passed explicitly here to avoid typescript error (requires ignore).\n // @ts-ignore\n value: props.value,\n // Only pass isRequired and validationState to react-aria if they came from\n // the props for this individual checkbox, and not from the group via context.\n isRequired: originalProps.isRequired,\n validationState: originalProps.validationState,\n isInvalid: originalProps.isInvalid\n }, groupState, inputRef)\n // eslint-disable-next-line react-hooks/rules-of-hooks\n : useCheckbox(props, useToggleState(props), inputRef);\n\n let {hoverProps, isHovered} = useHover({isDisabled});\n\n let markIcon = isIndeterminate\n ? <DashSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-partialCheckmark')} />\n : <CheckmarkSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-checkmark')} />;\n\n if (groupState) {\n for (let key of ['isSelected', 'defaultSelected', 'isEmphasized']) {\n if (originalProps[key] != null) {\n console.warn(`${key} is unsupported on individual <Checkbox> elements within a <CheckboxGroup>. Please apply these props to the group instead.`);\n }\n }\n if (props.value == null) {\n console.warn('A <Checkbox> element within a <CheckboxGroup> requires a `value` property.');\n }\n }\n\n return (\n <label\n {...styleProps}\n {...hoverProps}\n ref={domRef}\n className={\n classNames(\n styles,\n 'spectrum-Checkbox',\n {\n 'is-checked': inputProps.checked,\n 'is-indeterminate': isIndeterminate,\n 'spectrum-Checkbox--quiet': !isEmphasized,\n 'is-invalid': isInvalid,\n 'is-disabled': isDisabled,\n 'is-hovered': isHovered\n },\n styleProps.className\n )\n }>\n <FocusRing focusRingClass={classNames(styles, 'focus-ring')} autoFocus={autoFocus}>\n <input\n {...inputProps}\n ref={inputRef}\n className={classNames(styles, 'spectrum-Checkbox-input')} />\n </FocusRing>\n <span className={classNames(styles, 'spectrum-Checkbox-box')}>{markIcon}</span>\n {children && (\n <span className={classNames(styles, 'spectrum-Checkbox-label')}>\n {children}\n </span>\n )}\n </label>\n );\n});\n"],"names":[],"version":3,"file":"Checkbox.module.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;AAsBM,MAAM,0DAAW,CAAA,GAAA,iBAAS,EAAE,SAAS,SAAS,KAA4B,EAAE,GAAmC;IACpH,IAAI,gBAAgB;IACpB,IAAI,WAAW,CAAA,GAAA,aAAK,EAAoB;IACxC,IAAI,SAAS,CAAA,GAAA,sBAAc,EAAE,KAAK;IAElC,CAAC,OAAO,OAAO,GAAG,CAAA,GAAA,sBAAc,EAAE,OAAO,QAAQ,CAAA,GAAA,sBAAc;IAC/D,QAAQ,CAAA,GAAA,uBAAe,EAAE;IACzB,QAAQ,CAAA,GAAA,mBAAW,EAAE;IACrB,IAAI,mBACF,kBAAkB,qBAClB,eAAe,kBACf,S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,iBAAS,EACP,CAAA,GAAA,0DAAK,GACL,qBACA;YACE,cAAc,WAAW,OAAO;YAChC,oBAAoB;YACpB,4BAA4B,CAAC;YAC7B,cAAc;YACd,eAAe;YACf,cAAc;QAChB,GACA,WAAW,SAAS;qBAGxB,gCAAC,CAAA,GAAA,gBAAQ;QAAE,gBAAgB,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;QAAe,WAAW;qBACtE,gCAAC;QACE,GAAG,UAAU;QACd,KAAK;QACL,WAAW,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;uBAElC,gCAAC;QAAK,WAAW,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;OAA2B,WAC9D,0BACC,gCAAC;QAAK,WAAW,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,0DAAK,GAAG;OACjC;AAKX","sources":["packages/@react-spectrum/checkbox/src/Checkbox.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 {CheckboxContext, useContextProps} from 'react-aria-components';\nimport {CheckboxGroupContext} from './context';\nimport CheckmarkSmall from '@spectrum-icons/ui/CheckmarkSmall';\nimport {classNames, useFocusableRef, useStyleProps} from '@react-spectrum/utils';\nimport DashSmall from '@spectrum-icons/ui/DashSmall';\nimport {FocusableRef} from '@react-types/shared';\nimport {FocusRing} from '@react-aria/focus';\nimport React, {forwardRef, useContext, useRef} from 'react';\nimport {SpectrumCheckboxProps} from '@react-types/checkbox';\nimport styles from '@adobe/spectrum-css-temp/components/checkbox/vars.css';\nimport {useCheckbox, useCheckboxGroupItem} from '@react-aria/checkbox';\nimport {useFormProps} from '@react-spectrum/form';\nimport {useHover} from '@react-aria/interactions';\nimport {useProviderProps} from '@react-spectrum/provider';\nimport {useToggleState} from '@react-stately/toggle';\n\n/**\n * Checkboxes allow users to select multiple items from a list of individual items,\n * or to mark one individual item as selected.\n */\nexport const Checkbox = forwardRef(function Checkbox(props: SpectrumCheckboxProps, ref: FocusableRef<HTMLLabelElement>) {\n let originalProps = props;\n let inputRef = useRef<HTMLInputElement>(null);\n let domRef = useFocusableRef(ref, inputRef);\n\n [props, domRef] = useContextProps(props, domRef, CheckboxContext);\n props = useProviderProps(props);\n props = useFormProps(props);\n let {\n isIndeterminate = false,\n isEmphasized = false,\n autoFocus,\n children,\n ...otherProps\n } = props;\n let {styleProps} = useStyleProps(otherProps);\n\n // Swap hooks depending on whether this checkbox is inside a CheckboxGroup.\n // This is a bit unorthodox. Typically, hooks cannot be called in a conditional,\n // but since the checkbox won't move in and out of a group, it should be safe.\n let groupState = useContext(CheckboxGroupContext);\n let {inputProps, isInvalid, isDisabled} = groupState\n // eslint-disable-next-line react-hooks/rules-of-hooks\n ? useCheckboxGroupItem({\n ...props,\n // Value is optional for standalone checkboxes, but required for CheckboxGroup items;\n // it's passed explicitly here to avoid typescript error (requires ignore).\n // @ts-ignore\n value: props.value,\n // Only pass isRequired and validationState to react-aria if they came from\n // the props for this individual checkbox, and not from the group via context.\n isRequired: originalProps.isRequired,\n validationState: originalProps.validationState,\n isInvalid: originalProps.isInvalid\n }, groupState, inputRef)\n // eslint-disable-next-line react-hooks/rules-of-hooks\n : useCheckbox(props, useToggleState(props), inputRef);\n\n let {hoverProps, isHovered} = useHover({isDisabled});\n\n let markIcon = isIndeterminate\n ? <DashSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-partialCheckmark')} />\n : <CheckmarkSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-checkmark')} />;\n\n if (groupState && process.env.NODE_ENV !== 'production') {\n for (let key of ['isSelected', 'defaultSelected', 'isEmphasized']) {\n if (originalProps[key] != null) {\n console.warn(`${key} is unsupported on individual <Checkbox> elements within a <CheckboxGroup>. Please apply these props to the group instead.`);\n }\n }\n if (props.value == null) {\n console.warn('A <Checkbox> element within a <CheckboxGroup> requires a `value` property.');\n }\n }\n\n return (\n <label\n {...styleProps}\n {...hoverProps}\n ref={domRef}\n className={\n classNames(\n styles,\n 'spectrum-Checkbox',\n {\n 'is-checked': inputProps.checked,\n 'is-indeterminate': isIndeterminate,\n 'spectrum-Checkbox--quiet': !isEmphasized,\n 'is-invalid': isInvalid,\n 'is-disabled': isDisabled,\n 'is-hovered': isHovered\n },\n styleProps.className\n )\n }>\n <FocusRing focusRingClass={classNames(styles, 'focus-ring')} autoFocus={autoFocus}>\n <input\n {...inputProps}\n ref={inputRef}\n className={classNames(styles, 'spectrum-Checkbox-input')} />\n </FocusRing>\n <span className={classNames(styles, 'spectrum-Checkbox-box')}>{markIcon}</span>\n {children && (\n <span className={classNames(styles, 'spectrum-Checkbox-label')}>\n {children}\n </span>\n )}\n </label>\n );\n});\n"],"names":[],"version":3,"file":"Checkbox.module.js.map"}
@@ -1,5 +1,5 @@
1
1
  var $bdf3bf7fe71fe120$exports = require("./context.main.js");
2
- require("./vars.1be3e4c7.css");
2
+ require("./checkbox.f39d58be.css");
3
3
  var $53124a3a0fd56fca$exports = require("./fieldgroup_vars_css.main.js");
4
4
  var $5yQLk$reactspectrumutils = require("@react-spectrum/utils");
5
5
  var $5yQLk$reactspectrumlabel = require("@react-spectrum/label");
@@ -1,5 +1,5 @@
1
1
  import {CheckboxGroupContext as $8c8ab388b155237e$export$baf37c4be89255b8} from "./context.mjs";
2
- import "./vars.1be3e4c7.css";
2
+ import "./checkbox.f39d58be.css";
3
3
  import $8sUxO$fieldgroup_vars_cssmodulejs from "./fieldgroup_vars_css.mjs";
4
4
  import {useDOMRef as $8sUxO$useDOMRef, classNames as $8sUxO$classNames} from "@react-spectrum/utils";
5
5
  import {Field as $8sUxO$Field} from "@react-spectrum/label";
@@ -1,5 +1,5 @@
1
1
  import {CheckboxGroupContext as $8c8ab388b155237e$export$baf37c4be89255b8} from "./context.module.js";
2
- import "./vars.1be3e4c7.css";
2
+ import "./checkbox.f39d58be.css";
3
3
  import $8sUxO$fieldgroup_vars_cssmodulejs from "./fieldgroup_vars_css.module.js";
4
4
  import {useDOMRef as $8sUxO$useDOMRef, classNames as $8sUxO$classNames} from "@react-spectrum/utils";
5
5
  import {Field as $8sUxO$Field} from "@react-spectrum/label";
@@ -485,4 +485,4 @@
485
485
  --spectrum-alias-toggle-color-selected: ButtonText;
486
486
  }
487
487
  }
488
- /*# sourceMappingURL=vars.6d89b710.css.map */
488
+ /*# sourceMappingURL=checkbox.155bd254.css.map */
@@ -1 +1 @@
1
- {"mappings":"AA4DA;;;;;AAIE;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAQA;;;;AAIA;;;;AAKF;;;;;;;;AAOE;;;;;;;;;;;AAqBE;;;;;AAQF;;;;AAKE;;;;;AAOJ;EACE;;;;EAIE;;;;;AAMJ;;;;;;;;;;;;AAiBA;;;;;;;;;;;;;;;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAgCE;;;;AAMI;;;;AASF;;;;AAIA;;;;AAIA;;;;;;AAWA;;;;AAKA;;;;;AAOJ;;;;;;;;;AASA;;;;;;;;;;AAaE;;;;;;;;;;;;;;AAiBA;;;;;;;;;;;AAiBF;;;;;;;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAeA;;;;AAgBA;;;;;;;;;;;;;;;;;;;;AAyBE;;;;AAME;;;;;AAMF;;;;AAQI;;;;AAQA;;;;AAIF;;;;AAKE;;;;AAQA;;;;AAIF;;;;AAKE;;;;AAUA;;;;;AAMF;;;;AANE;;;;;AAMF;;;;AAWI;;;;;AAMF;;;;AANE;;;;;AAMF;;;;AASE;;;;;AAKF;;;;AALE;;;;;AAKF;;;;AAWA;;;;;AAMA;;;;AAGA;;;;AAME;;;;AAKJ;;;;AAQI;;;;AAWF;;;;AAQE;;;;AASA;;;;AAcF;;;;AAKF;;;;AAOI;;;;AAKF;;;;AALE;;;;AAKF;;;;AASE;;;;AAKF;;;;AAQE;;;;AAKF;;;;AAON;EACE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2CE","sources":["packages/@adobe/spectrum-css-temp/components/checkbox/vars.css"],"sourcesContent":["/*\n * Copyright 2020 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\n@import './index.css';\n@import './skin.css';\n"],"names":[],"version":3,"file":"vars.6d89b710.css.map"}
1
+ {"mappings":"AA4DA;;;;;AAIE;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAQA;;;;AAIA;;;;AAKF;;;;;;;;AAOE;;;;;;;;;;;AAqBE;;;;;AAQF;;;;AAKE;;;;;AAOJ;EACE;;;;EAIE;;;;;AAMJ;;;;;;;;;;;;AAiBA;;;;;;;;;;;;;;;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAgCE;;;;AAMI;;;;AASF;;;;AAIA;;;;AAIA;;;;;;AAWA;;;;AAKA;;;;;AAOJ;;;;;;;;;AASA;;;;;;;;;;AAaE;;;;;;;;;;;;;;AAiBA;;;;;;;;;;;AAiBF;;;;;;;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAAA;;;;AAeA;;;;AAgBA;;;;;;;;;;;;;;;;;;;;AAyBE;;;;AAME;;;;;AAMF;;;;AAQI;;;;AAQA;;;;AAIF;;;;AAKE;;;;AAQA;;;;AAIF;;;;AAKE;;;;AAUA;;;;;AAMF;;;;AANE;;;;;AAMF;;;;AAWI;;;;;AAMF;;;;AANE;;;;;AAMF;;;;AASE;;;;;AAKF;;;;AALE;;;;;AAKF;;;;AAWA;;;;;AAMA;;;;AAGA;;;;AAME;;;;AAKJ;;;;AAQI;;;;AAWF;;;;AAQE;;;;AASA;;;;AAcF;;;;AAKF;;;;AAOI;;;;AAKF;;;;AALE;;;;AAKF;;;;AASE;;;;AAKF;;;;AAQE;;;;AAKF;;;;AAON;EACE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2CE","sources":["packages/@adobe/spectrum-css-temp/components/checkbox/vars.css"],"sourcesContent":["/*\n * Copyright 2020 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\n@import './index.css';\n@import './skin.css';\n"],"names":[],"version":3,"file":"checkbox.155bd254.css.map"}
@@ -91,4 +91,4 @@
91
91
  .cU1tAG_spectrum-FieldGroup-group--horizontal {
92
92
  flex-flow: wrap;
93
93
  }
94
- /*# sourceMappingURL=vars.1be3e4c7.css.map */
94
+ /*# sourceMappingURL=checkbox.f39d58be.css.map */
@@ -1 +1 @@
1
- {"mappings":"AA4DA;;;;;AAIE;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAQA;;;;AAIA;;;;AAKF;;;;;;;;AAOE;;;;;;;;;;;AAqBE;;;;;AAQF;;;;AAKE;;;;;AAOJ;EACE;;;;EAIE;;;;;AAQJ;;;;;AAKA;;;;;AAKA","sources":["packages/@adobe/spectrum-css-temp/components/fieldgroup/vars.css"],"sourcesContent":["/*\n * Copyright 2020 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\n@import './index.css';\n"],"names":[],"version":3,"file":"vars.1be3e4c7.css.map"}
1
+ {"mappings":"AA4DA;;;;;AAIE;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAIA;;;;AAQA;;;;AAIA;;;;AAKF;;;;;;;;AAOE;;;;;;;;;;;AAqBE;;;;;AAQF;;;;AAKE;;;;;AAOJ;EACE;;;;EAIE;;;;;AAQJ;;;;;AAKA;;;;;AAKA","sources":["packages/@adobe/spectrum-css-temp/components/fieldgroup/vars.css"],"sourcesContent":["/*\n * Copyright 2020 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\n@import './index.css';\n"],"names":[],"version":3,"file":"checkbox.f39d58be.css.map"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-spectrum/checkbox",
3
- "version": "3.9.13",
3
+ "version": "3.9.15",
4
4
  "description": "Spectrum UI components in React",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/main.js",
@@ -36,19 +36,19 @@
36
36
  "url": "https://github.com/adobe/react-spectrum"
37
37
  },
38
38
  "dependencies": {
39
- "@react-aria/checkbox": "^3.15.2",
40
- "@react-aria/focus": "^3.20.0",
41
- "@react-aria/interactions": "^3.24.0",
42
- "@react-spectrum/form": "^3.7.12",
43
- "@react-spectrum/label": "^3.16.12",
44
- "@react-spectrum/utils": "^3.12.2",
45
- "@react-stately/checkbox": "^3.6.12",
46
- "@react-stately/toggle": "^3.8.2",
47
- "@react-types/checkbox": "^3.9.2",
48
- "@react-types/shared": "^3.28.0",
49
- "@spectrum-icons/ui": "^3.6.13",
39
+ "@react-aria/checkbox": "^3.15.4",
40
+ "@react-aria/focus": "^3.20.2",
41
+ "@react-aria/interactions": "^3.25.0",
42
+ "@react-spectrum/form": "^3.7.14",
43
+ "@react-spectrum/label": "^3.16.14",
44
+ "@react-spectrum/utils": "^3.12.4",
45
+ "@react-stately/checkbox": "^3.6.13",
46
+ "@react-stately/toggle": "^3.8.3",
47
+ "@react-types/checkbox": "^3.9.3",
48
+ "@react-types/shared": "^3.29.0",
49
+ "@spectrum-icons/ui": "^3.6.15",
50
50
  "@swc/helpers": "^0.5.0",
51
- "react-aria-components": "^1.7.0"
51
+ "react-aria-components": "^1.8.0"
52
52
  },
53
53
  "devDependencies": {
54
54
  "@adobe/spectrum-css-temp": "3.0.0-alpha.1",
@@ -56,10 +56,11 @@
56
56
  },
57
57
  "peerDependencies": {
58
58
  "@react-spectrum/provider": "^3.0.0",
59
- "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1"
59
+ "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1",
60
+ "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1"
60
61
  },
61
62
  "publishConfig": {
62
63
  "access": "public"
63
64
  },
64
- "gitHead": "4d3c72c94eea2d72eb3a0e7d56000c6ef7e39726"
65
+ "gitHead": "9b66d270572f482948afee95622a85cdf68ed408"
65
66
  }
package/src/Checkbox.tsx CHANGED
@@ -74,7 +74,7 @@ export const Checkbox = forwardRef(function Checkbox(props: SpectrumCheckboxProp
74
74
  ? <DashSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-partialCheckmark')} />
75
75
  : <CheckmarkSmall UNSAFE_className={classNames(styles, 'spectrum-Checkbox-checkmark')} />;
76
76
 
77
- if (groupState) {
77
+ if (groupState && process.env.NODE_ENV !== 'production') {
78
78
  for (let key of ['isSelected', 'defaultSelected', 'isEmphasized']) {
79
79
  if (originalProps[key] != null) {
80
80
  console.warn(`${key} is unsupported on individual <Checkbox> elements within a <CheckboxGroup>. Please apply these props to the group instead.`);