@depup/react-aria-components 1.20.0-depup.0 → 1.21.0-depup.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/NavigationTree/package.json +5 -0
  2. package/README.md +2 -2
  3. package/changes.json +1 -1
  4. package/dist/exports/Menu.cjs +1 -0
  5. package/dist/exports/Menu.cjs.map +1 -1
  6. package/dist/exports/Menu.js +2 -2
  7. package/dist/exports/Menu.js.map +1 -1
  8. package/dist/exports/Menu.mjs +2 -2
  9. package/dist/exports/Menu.mjs.map +1 -1
  10. package/dist/exports/NavigationTree.cjs +37 -0
  11. package/dist/exports/NavigationTree.cjs.map +1 -0
  12. package/dist/exports/NavigationTree.js +25 -0
  13. package/dist/exports/NavigationTree.js.map +1 -0
  14. package/dist/exports/NavigationTree.mjs +25 -0
  15. package/dist/exports/NavigationTree.mjs.map +1 -0
  16. package/dist/exports/index.cjs +13 -0
  17. package/dist/exports/index.cjs.map +1 -1
  18. package/dist/exports/index.js +6 -2
  19. package/dist/exports/index.js.map +1 -1
  20. package/dist/exports/index.mjs +6 -2
  21. package/dist/exports/index.mjs.map +1 -1
  22. package/dist/private/Checkbox.cjs.map +1 -1
  23. package/dist/private/Checkbox.js.map +1 -1
  24. package/dist/private/Checkbox.mjs.map +1 -1
  25. package/dist/private/Dialog.cjs +6 -0
  26. package/dist/private/Dialog.cjs.map +1 -1
  27. package/dist/private/Dialog.js +6 -0
  28. package/dist/private/Dialog.js.map +1 -1
  29. package/dist/private/Dialog.mjs +6 -0
  30. package/dist/private/Dialog.mjs.map +1 -1
  31. package/dist/private/GridList.cjs.map +1 -1
  32. package/dist/private/GridList.js.map +1 -1
  33. package/dist/private/GridList.mjs.map +1 -1
  34. package/dist/private/ListBox.cjs.map +1 -1
  35. package/dist/private/ListBox.js.map +1 -1
  36. package/dist/private/ListBox.mjs.map +1 -1
  37. package/dist/private/Menu.cjs +55 -0
  38. package/dist/private/Menu.cjs.map +1 -1
  39. package/dist/private/Menu.js +56 -2
  40. package/dist/private/Menu.js.map +1 -1
  41. package/dist/private/Menu.mjs +56 -2
  42. package/dist/private/Menu.mjs.map +1 -1
  43. package/dist/private/NavigationTree.cjs +272 -0
  44. package/dist/private/NavigationTree.cjs.map +1 -0
  45. package/dist/private/NavigationTree.js +258 -0
  46. package/dist/private/NavigationTree.js.map +1 -0
  47. package/dist/private/NavigationTree.mjs +257 -0
  48. package/dist/private/NavigationTree.mjs.map +1 -0
  49. package/dist/private/RadioGroup.cjs.map +1 -1
  50. package/dist/private/RadioGroup.js.map +1 -1
  51. package/dist/private/RadioGroup.mjs.map +1 -1
  52. package/dist/private/Switch.cjs +8 -2
  53. package/dist/private/Switch.cjs.map +1 -1
  54. package/dist/private/Switch.js +9 -3
  55. package/dist/private/Switch.js.map +1 -1
  56. package/dist/private/Switch.mjs +9 -3
  57. package/dist/private/Switch.mjs.map +1 -1
  58. package/dist/private/Table.cjs.map +1 -1
  59. package/dist/private/Table.js.map +1 -1
  60. package/dist/private/Table.mjs.map +1 -1
  61. package/dist/private/Text.cjs +3 -1
  62. package/dist/private/Text.cjs.map +1 -1
  63. package/dist/private/Text.js +4 -2
  64. package/dist/private/Text.js.map +1 -1
  65. package/dist/private/Text.mjs +4 -2
  66. package/dist/private/Text.mjs.map +1 -1
  67. package/dist/private/TokenField.cjs +30 -2
  68. package/dist/private/TokenField.cjs.map +1 -1
  69. package/dist/private/TokenField.js +30 -2
  70. package/dist/private/TokenField.js.map +1 -1
  71. package/dist/private/TokenField.mjs +30 -2
  72. package/dist/private/TokenField.mjs.map +1 -1
  73. package/dist/private/Tree.cjs.map +1 -1
  74. package/dist/private/Tree.js.map +1 -1
  75. package/dist/private/Tree.mjs.map +1 -1
  76. package/dist/private/TreeDropTargetDelegate.cjs +11 -6
  77. package/dist/private/TreeDropTargetDelegate.cjs.map +1 -1
  78. package/dist/private/TreeDropTargetDelegate.js +11 -6
  79. package/dist/private/TreeDropTargetDelegate.js.map +1 -1
  80. package/dist/private/TreeDropTargetDelegate.mjs +11 -6
  81. package/dist/private/TreeDropTargetDelegate.mjs.map +1 -1
  82. package/dist/types/exports/Menu.d.ts +2 -2
  83. package/dist/types/exports/NavigationTree.d.ts +8 -0
  84. package/dist/types/exports/index.d.ts +7 -3
  85. package/dist/types/src/Breadcrumbs.d.ts +2 -2
  86. package/dist/types/src/Button.d.ts +1 -1
  87. package/dist/types/src/Calendar.d.ts +6 -6
  88. package/dist/types/src/Checkbox.d.ts +8 -8
  89. package/dist/types/src/Collection.d.ts +1 -1
  90. package/dist/types/src/ComboBox.d.ts +2 -2
  91. package/dist/types/src/DateField.d.ts +4 -4
  92. package/dist/types/src/DatePicker.d.ts +2 -2
  93. package/dist/types/src/Dialog.d.ts +2 -2
  94. package/dist/types/src/Disclosure.d.ts +2 -2
  95. package/dist/types/src/GridList.d.ts +6 -6
  96. package/dist/types/src/Group.d.ts +1 -1
  97. package/dist/types/src/Header.d.ts +1 -1
  98. package/dist/types/src/Input.d.ts +1 -1
  99. package/dist/types/src/Label.d.ts +1 -1
  100. package/dist/types/src/Link.d.ts +1 -1
  101. package/dist/types/src/ListBox.d.ts +5 -5
  102. package/dist/types/src/Menu.d.ts +25 -6
  103. package/dist/types/src/Meter.d.ts +1 -1
  104. package/dist/types/src/Modal.d.ts +2 -2
  105. package/dist/types/src/NavigationTree.d.ts +80 -0
  106. package/dist/types/src/NumberField.d.ts +1 -1
  107. package/dist/types/src/OverlayArrow.d.ts +1 -1
  108. package/dist/types/src/Popover.d.ts +1 -1
  109. package/dist/types/src/RadioGroup.d.ts +8 -8
  110. package/dist/types/src/SearchField.d.ts +1 -1
  111. package/dist/types/src/Select.d.ts +2 -2
  112. package/dist/types/src/Separator.d.ts +1 -1
  113. package/dist/types/src/Slider.d.ts +5 -5
  114. package/dist/types/src/Switch.d.ts +7 -7
  115. package/dist/types/src/Table.d.ts +8 -8
  116. package/dist/types/src/Tabs.d.ts +5 -5
  117. package/dist/types/src/TagGroup.d.ts +3 -3
  118. package/dist/types/src/Text.d.ts +1 -1
  119. package/dist/types/src/TextField.d.ts +1 -1
  120. package/dist/types/src/Toast.d.ts +3 -3
  121. package/dist/types/src/ToggleButton.d.ts +1 -1
  122. package/dist/types/src/ToggleButtonGroup.d.ts +1 -1
  123. package/dist/types/src/TokenField.d.ts +2 -2
  124. package/dist/types/src/Toolbar.d.ts +1 -1
  125. package/dist/types/src/Tooltip.d.ts +1 -1
  126. package/dist/types/src/Tree.d.ts +6 -6
  127. package/package.json +8 -7
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;;AAwMM,MAAM,0DAAgB,CAAA,GAAA,oBAAY,EAA+C;AACjF,MAAM,0DACX,CAAA,GAAA,oBAAY,EAAkD;AACzD,MAAM,yDAAqB,CAAA,GAAA,oBAAY,EAAsB;AAO7D,MAAM,4CAAuB,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,OAC1E,KAAkB,EAClB,GAAmC;IAEnC,IAAI,EAAC,UAAU,uBAAuB,IAAI,EAAE,GAAG,YAAW,GAAG;IAC7D,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,YAAY,KAAK;IAChD,IAAI,WAAW,CAAA,GAAA,mBAAW,EACxB,CAAA,GAAA,gBAAQ,EAAE,sBAAsB,MAAM,QAAQ,KAAK,YAAY,MAAM,QAAQ,GAAG;IAElF,IAAI,QAAQ,CAAA,GAAA,qBAAa,EAAE;IAC3B,IAAI,OAAO,CAAA,GAAA,gBAAQ,EACjB;QACE,GAAG,CAAA,GAAA,yCAAmB,EAAE,MAAM;QAC9B,kDAAkD;QAClD,UAAU,OAAO,MAAM,QAAQ,KAAK,aAAa,OAAO,MAAM,QAAQ;IACxE,GACA,OACA;IAGF,qBACE,gCAAC,CAAA,GAAA,yCAAO;QACN,QAAQ;YACN;gBAAC;gBAAoB;aAAM;YAC3B;gBACE;gBACA;oBAC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GAAA,uCAAa,EAAE;QAC/B,GAAG,KAAK;0BACR;QACA,QAAQ;wBACN;uBACA;uBACA;uBACA;4BACA;wBACA;wBACA;uBACA;YACA,YAAY,cAAc;mBAC1B;QACF;IACF;IAEA,IAAI,WAAW,CAAA,GAAA,qBAAa,EAAE,OAAO;QAAC,QAAQ;IAAI;IAClD,OAAO,SAAS,EAAE;IAClB,OAAO,SAAS,OAAO;IAEvB,qBACE,gCAAC,CAAA,GAAA,yCAAE,EAAE,KAAK;QACP,GAAG,CAAA,GAAA,iBAAS,EAAE,UAAU,YAAY,YAAY,YAAY;QAC7D,KAAK;QACL,MAAM,MAAM,IAAI,IAAI;QACpB,iBAAe,cAAc;QAC7B,gBAAc,aAAa;QAC3B,gBAAc,aAAa;QAC3B,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,iBAAe,cAAc;QAC7B,iBAAe,cAAc;QAC7B,gBAAc,aAAa;QAC3B,iBAAe,cAAc;qBAC7B,gCAAC,CAAA,GAAA,qBAAa;QAAE,aAAY;qBAC1B,gCAAC;QAAO,GAAG,CAAA,GAAA,iBAAS,EAAE,YAAY,WAAW;QAAE,KAAK;SAErD,YAAY,QAAQ;AAG3B","sources":["packages/react-aria-components/src/Switch.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 {AriaSwitchProps, SwitchAria, useSwitch} from 'react-aria/useSwitch';\n\nimport {\n ClassNameOrFunction,\n ContextValue,\n dom,\n Provider,\n RACValidation,\n removeDataAttributes,\n RenderProps,\n SlotProps,\n useContextProps,\n useRenderProps,\n useSlottedContext\n} from './utils';\nimport {FieldErrorContext} from './FieldError';\nimport {filterDOMProps} from 'react-aria/filterDOMProps';\nimport {FormContext} from './Form';\nimport {forwardRefType, GlobalDOMAttributes, RefObject} from '@react-types/shared';\nimport {HoverEvents} from '@react-types/shared';\nimport {mergeProps} from 'react-aria/mergeProps';\nimport {mergeRefs} from 'react-aria/mergeRefs';\nimport React, {createContext, ForwardedRef, forwardRef, useContext} from 'react';\nimport {TextContext} from './Text';\nimport {ToggleState, useToggleState} from 'react-stately/useToggleState';\nimport {useFocusRing} from 'react-aria/useFocusRing';\nimport {useHover} from 'react-aria/useHover';\nimport {useObjectRef} from 'react-aria/useObjectRef';\nimport {VisuallyHidden} from 'react-aria/VisuallyHidden';\n\nexport interface SwitchProps\n extends\n Omit<\n AriaSwitchProps,\n | 'children'\n | 'validationState'\n | 'validationBehavior'\n | 'isRequired'\n | 'isInvalid'\n | 'validate'\n >,\n HoverEvents,\n RenderProps<SwitchRenderProps, 'label'>,\n SlotProps,\n Omit<GlobalDOMAttributes<HTMLLabelElement>, 'onClick'> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n * element. A function may be provided to compute the class based on component state.\n *\n * @default 'react-aria-Switch'\n */\n className?: ClassNameOrFunction<SwitchRenderProps>;\n /**\n * A ref for the HTML input element.\n */\n inputRef?: RefObject<HTMLInputElement | null>;\n}\n\nexport interface SwitchFieldProps\n extends\n Omit<AriaSwitchProps, 'children' | 'validationState' | 'validationBehavior'>,\n RACValidation,\n RenderProps<SwitchFieldRenderProps>,\n SlotProps,\n Omit<GlobalDOMAttributes<HTMLDivElement>, 'onClick'> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n * element. A function may be provided to compute the class based on component state.\n *\n * @default 'react-aria-SwitchField'\n */\n className?: ClassNameOrFunction<SwitchFieldRenderProps>;\n /**\n * A ref for the HTML input element.\n */\n inputRef?: RefObject<HTMLInputElement | null>;\n}\n\nexport interface SwitchButtonProps\n extends\n HoverEvents,\n RenderProps<SwitchButtonRenderProps, 'label'>,\n SlotProps,\n GlobalDOMAttributes<HTMLLabelElement> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n * element. A function may be provided to compute the class based on component state.\n *\n * @default 'react-aria-SwitchButton'\n */\n className?: ClassNameOrFunction<SwitchButtonRenderProps>;\n}\n\nexport interface SwitchRenderProps {\n /**\n * Whether the switch is selected.\n *\n * @selector [data-selected]\n */\n isSelected: boolean;\n /**\n * Whether the switch is currently hovered with a mouse.\n *\n * @selector [data-hovered]\n */\n isHovered: boolean;\n /**\n * Whether the switch is currently in a pressed state.\n *\n * @selector [data-pressed]\n */\n isPressed: boolean;\n /**\n * Whether the switch is focused, either via a mouse or keyboard.\n *\n * @selector [data-focused]\n */\n isFocused: boolean;\n /**\n * Whether the switch is keyboard focused.\n *\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean;\n /**\n * Whether the switch is disabled.\n *\n * @selector [data-disabled]\n */\n isDisabled: boolean;\n /**\n * Whether the switch is read only.\n *\n * @selector [data-readonly]\n */\n isReadOnly: boolean;\n /**\n * State of the switch.\n */\n state: ToggleState;\n}\n\nexport interface SwitchFieldRenderProps {\n /**\n * Whether the switch is selected.\n *\n * @selector [data-selected]\n */\n isSelected: boolean;\n /**\n * Whether the switch is disabled.\n *\n * @selector [data-disabled]\n */\n isDisabled: boolean;\n /**\n * Whether the switch is read only.\n *\n * @selector [data-readonly]\n */\n isReadOnly: boolean;\n /**\n * Whether the switch invalid.\n *\n * @selector [data-invalid]\n */\n isInvalid: boolean;\n /**\n * Whether the switch is required.\n *\n * @selector [data-required]\n */\n isRequired: boolean;\n /**\n * State of the switch.\n */\n state: ToggleState;\n}\n\nexport interface SwitchButtonRenderProps extends SwitchRenderProps {\n /**\n * Whether the switch invalid.\n *\n * @selector [data-invalid]\n */\n isInvalid: boolean;\n /**\n * Whether the switch is required.\n *\n * @selector [data-required]\n */\n isRequired: boolean;\n /**\n * State of the switch.\n */\n state: ToggleState;\n}\n\nexport const SwitchContext = createContext<ContextValue<SwitchProps, HTMLLabelElement>>(null);\nexport const SwitchFieldContext =\n createContext<ContextValue<SwitchFieldProps, HTMLDivElement>>(null);\nexport const ToggleStateContext = createContext<ToggleState | null>(null);\n\n/**\n * A switch allows a user to turn a setting on or off.\n *\n * @deprecated Use SwitchField + SwitchButton instead.\n */\nexport const Switch = /*#__PURE__*/ (forwardRef as forwardRefType)(function Switch(\n props: SwitchProps,\n ref: ForwardedRef<HTMLLabelElement>\n) {\n let {inputRef: userProvidedInputRef = null, ...otherProps} = props;\n [props, ref] = useContextProps(otherProps, ref, SwitchContext);\n let inputRef = useObjectRef(\n mergeRefs(userProvidedInputRef, props.inputRef !== undefined ? props.inputRef : null)\n );\n let state = useToggleState(props);\n let aria = useSwitch(\n {\n ...removeDataAttributes(props),\n // ReactNode type doesn't allow function children.\n children: typeof props.children === 'function' ? true : props.children\n },\n state,\n inputRef\n );\n\n return (\n <Provider\n values={[\n [ToggleStateContext, state],\n [\n InternalSwitchContext,\n {\n ...aria,\n inputRef,\n defaultClassName: 'react-aria-Switch'\n }\n ]\n ]}>\n <SwitchButton {...props} ref={ref} />\n </Provider>\n );\n});\n\ninterface InternalSwitchContextValue extends SwitchAria {\n inputRef: RefObject<HTMLInputElement | null>;\n defaultClassName: string;\n isRequired?: boolean;\n}\n\nconst InternalSwitchContext = createContext<InternalSwitchContextValue | null>(null);\n\n/**\n * A switch allows a user to turn a setting on or off, with support for validation and help text.\n */\nexport const SwitchField = /*#__PURE__*/ (forwardRef as forwardRefType)(function Switch(\n props: SwitchFieldProps,\n ref: ForwardedRef<HTMLDivElement>\n) {\n let {inputRef: userProvidedInputRef = null, ...otherProps} = props;\n [props, ref] = useContextProps(otherProps, ref, SwitchFieldContext);\n let {validationBehavior: formValidationBehavior} = useSlottedContext(FormContext) || {};\n let validationBehavior = props.validationBehavior ?? formValidationBehavior ?? 'native';\n let inputRef = useObjectRef(\n mergeRefs(userProvidedInputRef, props.inputRef !== undefined ? props.inputRef : null)\n );\n let state = useToggleState(props);\n let aria = useSwitch(\n {\n ...removeDataAttributes(props),\n // ReactNode type doesn't allow function children.\n children: typeof props.children === 'function' ? true : props.children,\n validationBehavior\n },\n state,\n inputRef\n );\n let {\n descriptionProps,\n errorMessageProps,\n isSelected,\n isDisabled,\n isReadOnly,\n isInvalid,\n validationDetails,\n validationErrors\n } = aria;\n\n let renderProps = useRenderProps({\n ...props,\n defaultClassName: 'react-aria-SwitchField',\n values: {\n isSelected,\n isDisabled,\n isReadOnly,\n isInvalid,\n isRequired: props.isRequired || false,\n state\n }\n });\n\n let DOMProps = filterDOMProps(props, {global: true});\n delete DOMProps.id;\n delete DOMProps.onClick;\n\n return (\n <dom.div\n {...mergeProps(DOMProps, renderProps)}\n ref={ref}\n slot={props.slot || undefined}\n data-selected={isSelected || undefined}\n data-disabled={isDisabled || undefined}\n data-readonly={isReadOnly || undefined}\n data-invalid={isInvalid || undefined}\n data-required={props.isRequired || undefined}>\n <Provider\n values={[\n [ToggleStateContext, state],\n [\n InternalSwitchContext,\n {\n ...aria,\n inputRef,\n defaultClassName: 'react-aria-SwitchButton',\n isRequired: props.isRequired\n }\n ],\n [\n TextContext,\n {\n slots: {\n description: descriptionProps,\n errorMessage: errorMessageProps\n }\n }\n ],\n [FieldErrorContext, {isInvalid, validationDetails, validationErrors}]\n ]}>\n {renderProps.children}\n </Provider>\n </dom.div>\n );\n});\n\n/**\n * A switch button is the clickable area of a switch, including the indicator and label.\n */\nexport const SwitchButton = /*#__PURE__*/ (forwardRef as forwardRefType)(function SwitchButton(\n props: SwitchButtonProps,\n ref: ForwardedRef<HTMLLabelElement>\n) {\n let {\n labelProps,\n inputProps,\n isSelected,\n isDisabled,\n isReadOnly,\n isPressed,\n isInvalid,\n inputRef,\n defaultClassName,\n isRequired\n } = useContext(InternalSwitchContext)!;\n let {isFocused, isFocusVisible, focusProps} = useFocusRing();\n let isInteractionDisabled = isDisabled || isReadOnly;\n let state = useContext(ToggleStateContext)!;\n\n let {hoverProps, isHovered} = useHover({\n ...props,\n isDisabled: isInteractionDisabled\n });\n\n let renderProps = useRenderProps({\n ...props,\n defaultClassName,\n values: {\n isSelected,\n isPressed,\n isHovered,\n isFocused,\n isFocusVisible,\n isDisabled,\n isReadOnly,\n isInvalid,\n isRequired: isRequired || false,\n state\n }\n });\n\n let DOMProps = filterDOMProps(props, {global: true});\n delete DOMProps.id;\n delete DOMProps.onClick;\n\n return (\n <dom.label\n {...mergeProps(DOMProps, labelProps, hoverProps, renderProps)}\n ref={ref}\n slot={props.slot || undefined}\n data-selected={isSelected || undefined}\n data-pressed={isPressed || undefined}\n data-hovered={isHovered || undefined}\n data-focused={isFocused || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-disabled={isDisabled || undefined}\n data-readonly={isReadOnly || undefined}\n data-invalid={isInvalid || undefined}\n data-required={isRequired || undefined}>\n <VisuallyHidden elementType=\"span\">\n <input {...mergeProps(inputProps, focusProps)} ref={inputRef} />\n </VisuallyHidden>\n {renderProps.children}\n </dom.label>\n );\n});\n"],"names":[],"version":3,"file":"Switch.mjs.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;;AAwMM,MAAM,0DAAgB,CAAA,GAAA,oBAAY,EAA+C;AACjF,MAAM,0DACX,CAAA,GAAA,oBAAY,EAAkD;AACzD,MAAM,yDAAqB,CAAA,GAAA,oBAAY,EAAsB;AAO7D,MAAM,4CAAuB,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,OAC1E,KAAkB,EAClB,GAAmC;IAEnC,IAAI,EAAC,UAAU,uBAAuB,IAAI,EAAE,GAAG,YAAW,GAAG;IAC7D,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,YAAY,KAAK;IAChD,IAAI,WAAW,CAAA,GAAA,mBAAW,EACxB,CAAA,GAAA,cAA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WAAW;QAAE,KAAK;SAErD,YAAY,QAAQ;AAG3B","sources":["packages/react-aria-components/src/Switch.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 {AriaSwitchProps, SwitchAria, useSwitch} from 'react-aria/useSwitch';\n\nimport {\n ClassNameOrFunction,\n ContextValue,\n dom,\n Provider,\n RACValidation,\n removeDataAttributes,\n RenderProps,\n SlotProps,\n useContextProps,\n useRenderProps,\n useSlottedContext\n} from './utils';\nimport {FieldErrorContext} from './FieldError';\nimport {filterDOMProps} from 'react-aria/filterDOMProps';\nimport {FormContext} from './Form';\nimport {forwardRefType, GlobalDOMAttributes, RefObject} from '@react-types/shared';\nimport {HoverEvents} from '@react-types/shared';\nimport {mergeProps} from 'react-aria/mergeProps';\nimport {mergeRefs} from 'react-aria/mergeRefs';\nimport React, {createContext, ForwardedRef, forwardRef, Ref, useContext, useMemo} from 'react';\nimport {TextContext} from './Text';\nimport {ToggleState, useToggleState} from 'react-stately/useToggleState';\nimport {useFocusRing} from 'react-aria/useFocusRing';\nimport {useHover} from 'react-aria/useHover';\nimport {useObjectRef} from 'react-aria/useObjectRef';\nimport {VisuallyHidden} from 'react-aria/VisuallyHidden';\n\nexport interface SwitchProps\n extends\n Omit<\n AriaSwitchProps,\n | 'children'\n | 'validationState'\n | 'validationBehavior'\n | 'isRequired'\n | 'isInvalid'\n | 'validate'\n >,\n HoverEvents,\n RenderProps<SwitchRenderProps, 'label'>,\n SlotProps,\n Omit<GlobalDOMAttributes<HTMLLabelElement>, 'onClick'> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n * element. A function may be provided to compute the class based on component state.\n *\n * @default 'react-aria-Switch'\n */\n className?: ClassNameOrFunction<SwitchRenderProps>;\n /**\n * A ref for the HTML input element.\n */\n inputRef?: Ref<HTMLInputElement | null>;\n}\n\nexport interface SwitchFieldProps\n extends\n Omit<AriaSwitchProps, 'children' | 'validationState' | 'validationBehavior'>,\n RACValidation,\n RenderProps<SwitchFieldRenderProps>,\n SlotProps,\n Omit<GlobalDOMAttributes<HTMLDivElement>, 'onClick'> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n * element. A function may be provided to compute the class based on component state.\n *\n * @default 'react-aria-SwitchField'\n */\n className?: ClassNameOrFunction<SwitchFieldRenderProps>;\n /**\n * A ref for the HTML input element.\n */\n inputRef?: Ref<HTMLInputElement | null>;\n}\n\nexport interface SwitchButtonProps\n extends\n HoverEvents,\n RenderProps<SwitchButtonRenderProps, 'label'>,\n SlotProps,\n GlobalDOMAttributes<HTMLLabelElement> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n * element. A function may be provided to compute the class based on component state.\n *\n * @default 'react-aria-SwitchButton'\n */\n className?: ClassNameOrFunction<SwitchButtonRenderProps>;\n}\n\nexport interface SwitchRenderProps {\n /**\n * Whether the switch is selected.\n *\n * @selector [data-selected]\n */\n isSelected: boolean;\n /**\n * Whether the switch is currently hovered with a mouse.\n *\n * @selector [data-hovered]\n */\n isHovered: boolean;\n /**\n * Whether the switch is currently in a pressed state.\n *\n * @selector [data-pressed]\n */\n isPressed: boolean;\n /**\n * Whether the switch is focused, either via a mouse or keyboard.\n *\n * @selector [data-focused]\n */\n isFocused: boolean;\n /**\n * Whether the switch is keyboard focused.\n *\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean;\n /**\n * Whether the switch is disabled.\n *\n * @selector [data-disabled]\n */\n isDisabled: boolean;\n /**\n * Whether the switch is read only.\n *\n * @selector [data-readonly]\n */\n isReadOnly: boolean;\n /**\n * State of the switch.\n */\n state: ToggleState;\n}\n\nexport interface SwitchFieldRenderProps {\n /**\n * Whether the switch is selected.\n *\n * @selector [data-selected]\n */\n isSelected: boolean;\n /**\n * Whether the switch is disabled.\n *\n * @selector [data-disabled]\n */\n isDisabled: boolean;\n /**\n * Whether the switch is read only.\n *\n * @selector [data-readonly]\n */\n isReadOnly: boolean;\n /**\n * Whether the switch invalid.\n *\n * @selector [data-invalid]\n */\n isInvalid: boolean;\n /**\n * Whether the switch is required.\n *\n * @selector [data-required]\n */\n isRequired: boolean;\n /**\n * State of the switch.\n */\n state: ToggleState;\n}\n\nexport interface SwitchButtonRenderProps extends SwitchRenderProps {\n /**\n * Whether the switch invalid.\n *\n * @selector [data-invalid]\n */\n isInvalid: boolean;\n /**\n * Whether the switch is required.\n *\n * @selector [data-required]\n */\n isRequired: boolean;\n /**\n * State of the switch.\n */\n state: ToggleState;\n}\n\nexport const SwitchContext = createContext<ContextValue<SwitchProps, HTMLLabelElement>>(null);\nexport const SwitchFieldContext =\n createContext<ContextValue<SwitchFieldProps, HTMLDivElement>>(null);\nexport const ToggleStateContext = createContext<ToggleState | null>(null);\n\n/**\n * A switch allows a user to turn a setting on or off.\n *\n * @deprecated Use SwitchField + SwitchButton instead.\n */\nexport const Switch = /*#__PURE__*/ (forwardRef as forwardRefType)(function Switch(\n props: SwitchProps,\n ref: ForwardedRef<HTMLLabelElement>\n) {\n let {inputRef: userProvidedInputRef = null, ...otherProps} = props;\n [props, ref] = useContextProps(otherProps, ref, SwitchContext);\n let inputRef = useObjectRef(\n useMemo(\n () => mergeRefs(userProvidedInputRef, props.inputRef !== undefined ? props.inputRef : null),\n [userProvidedInputRef, props.inputRef]\n )\n );\n let state = useToggleState(props);\n let aria = useSwitch(\n {\n ...removeDataAttributes(props),\n // ReactNode type doesn't allow function children.\n children: typeof props.children === 'function' ? true : props.children\n },\n state,\n inputRef\n );\n\n return (\n <Provider\n values={[\n [ToggleStateContext, state],\n [\n InternalSwitchContext,\n {\n ...aria,\n inputRef,\n defaultClassName: 'react-aria-Switch'\n }\n ]\n ]}>\n <SwitchButton {...props} ref={ref} />\n </Provider>\n );\n});\n\ninterface InternalSwitchContextValue extends SwitchAria {\n inputRef: RefObject<HTMLInputElement | null>;\n defaultClassName: string;\n isRequired?: boolean;\n}\n\nconst InternalSwitchContext = createContext<InternalSwitchContextValue | null>(null);\n\n/**\n * A switch allows a user to turn a setting on or off, with support for validation and help text.\n */\nexport const SwitchField = /*#__PURE__*/ (forwardRef as forwardRefType)(function Switch(\n props: SwitchFieldProps,\n ref: ForwardedRef<HTMLDivElement>\n) {\n let {inputRef: userProvidedInputRef = null, ...otherProps} = props;\n [props, ref] = useContextProps(otherProps, ref, SwitchFieldContext);\n let {validationBehavior: formValidationBehavior} = useSlottedContext(FormContext) || {};\n let validationBehavior = props.validationBehavior ?? formValidationBehavior ?? 'native';\n let inputRef = useObjectRef(\n useMemo(\n () => mergeRefs(userProvidedInputRef, props.inputRef !== undefined ? props.inputRef : null),\n [userProvidedInputRef, props.inputRef]\n )\n );\n let state = useToggleState(props);\n let aria = useSwitch(\n {\n ...removeDataAttributes(props),\n // ReactNode type doesn't allow function children.\n children: typeof props.children === 'function' ? true : props.children,\n validationBehavior\n },\n state,\n inputRef\n );\n let {\n descriptionProps,\n errorMessageProps,\n isSelected,\n isDisabled,\n isReadOnly,\n isInvalid,\n validationDetails,\n validationErrors\n } = aria;\n\n let renderProps = useRenderProps({\n ...props,\n defaultClassName: 'react-aria-SwitchField',\n values: {\n isSelected,\n isDisabled,\n isReadOnly,\n isInvalid,\n isRequired: props.isRequired || false,\n state\n }\n });\n\n let DOMProps = filterDOMProps(props, {global: true});\n delete DOMProps.id;\n delete DOMProps.onClick;\n\n return (\n <dom.div\n {...mergeProps(DOMProps, renderProps)}\n ref={ref}\n slot={props.slot || undefined}\n data-selected={isSelected || undefined}\n data-disabled={isDisabled || undefined}\n data-readonly={isReadOnly || undefined}\n data-invalid={isInvalid || undefined}\n data-required={props.isRequired || undefined}>\n <Provider\n values={[\n [ToggleStateContext, state],\n [\n InternalSwitchContext,\n {\n ...aria,\n inputRef,\n defaultClassName: 'react-aria-SwitchButton',\n isRequired: props.isRequired\n }\n ],\n [\n TextContext,\n {\n slots: {\n description: descriptionProps,\n errorMessage: errorMessageProps\n }\n }\n ],\n [FieldErrorContext, {isInvalid, validationDetails, validationErrors}]\n ]}>\n {renderProps.children}\n </Provider>\n </dom.div>\n );\n});\n\n/**\n * A switch button is the clickable area of a switch, including the indicator and label.\n */\nexport const SwitchButton = /*#__PURE__*/ (forwardRef as forwardRefType)(function SwitchButton(\n props: SwitchButtonProps,\n ref: ForwardedRef<HTMLLabelElement>\n) {\n let {\n labelProps,\n inputProps,\n isSelected,\n isDisabled,\n isReadOnly,\n isPressed,\n isInvalid,\n inputRef,\n defaultClassName,\n isRequired\n } = useContext(InternalSwitchContext)!;\n let {isFocused, isFocusVisible, focusProps} = useFocusRing();\n let isInteractionDisabled = isDisabled || isReadOnly;\n let state = useContext(ToggleStateContext)!;\n\n let {hoverProps, isHovered} = useHover({\n ...props,\n isDisabled: isInteractionDisabled\n });\n\n let renderProps = useRenderProps({\n ...props,\n defaultClassName,\n values: {\n isSelected,\n isPressed,\n isHovered,\n isFocused,\n isFocusVisible,\n isDisabled,\n isReadOnly,\n isInvalid,\n isRequired: isRequired || false,\n state\n }\n });\n\n let DOMProps = filterDOMProps(props, {global: true});\n delete DOMProps.id;\n delete DOMProps.onClick;\n\n return (\n <dom.label\n {...mergeProps(DOMProps, labelProps, hoverProps, renderProps)}\n ref={ref}\n slot={props.slot || undefined}\n data-selected={isSelected || undefined}\n data-pressed={isPressed || undefined}\n data-hovered={isHovered || undefined}\n data-focused={isFocused || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-disabled={isDisabled || undefined}\n data-readonly={isReadOnly || undefined}\n data-invalid={isInvalid || undefined}\n data-required={isRequired || undefined}>\n <VisuallyHidden elementType=\"span\">\n <input {...mergeProps(inputProps, focusProps)} ref={inputRef} />\n </VisuallyHidden>\n {renderProps.children}\n </dom.label>\n );\n});\n"],"names":[],"version":3,"file":"Switch.mjs.map"}