react-aria 3.51.0 → 3.52.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 (135) hide show
  1. package/dist/exports/index.cjs +1 -0
  2. package/dist/exports/index.cjs.map +1 -1
  3. package/dist/exports/index.js +2 -2
  4. package/dist/exports/index.js.map +1 -1
  5. package/dist/exports/index.mjs +2 -2
  6. package/dist/exports/index.mjs.map +1 -1
  7. package/dist/exports/private/utils/domHelpers.cjs +1 -0
  8. package/dist/exports/private/utils/domHelpers.cjs.map +1 -1
  9. package/dist/exports/private/utils/domHelpers.js +2 -2
  10. package/dist/exports/private/utils/domHelpers.js.map +1 -1
  11. package/dist/exports/private/utils/domHelpers.mjs +2 -2
  12. package/dist/exports/private/utils/domHelpers.mjs.map +1 -1
  13. package/dist/exports/useFocusVisible.cjs +1 -0
  14. package/dist/exports/useFocusVisible.cjs.map +1 -1
  15. package/dist/exports/useFocusVisible.js +2 -2
  16. package/dist/exports/useFocusVisible.js.map +1 -1
  17. package/dist/exports/useFocusVisible.mjs +2 -2
  18. package/dist/exports/useFocusVisible.mjs.map +1 -1
  19. package/dist/private/actiongroup/useActionGroup.cjs +3 -1
  20. package/dist/private/actiongroup/useActionGroup.cjs.map +1 -1
  21. package/dist/private/actiongroup/useActionGroup.js +3 -1
  22. package/dist/private/actiongroup/useActionGroup.js.map +1 -1
  23. package/dist/private/actiongroup/useActionGroup.mjs +3 -1
  24. package/dist/private/actiongroup/useActionGroup.mjs.map +1 -1
  25. package/dist/private/calendar/useRangeCalendar.cjs +1 -1
  26. package/dist/private/calendar/useRangeCalendar.cjs.map +1 -1
  27. package/dist/private/calendar/useRangeCalendar.js +2 -2
  28. package/dist/private/calendar/useRangeCalendar.js.map +1 -1
  29. package/dist/private/calendar/useRangeCalendar.mjs +2 -2
  30. package/dist/private/calendar/useRangeCalendar.mjs.map +1 -1
  31. package/dist/private/color/useColorField.cjs +26 -4
  32. package/dist/private/color/useColorField.cjs.map +1 -1
  33. package/dist/private/color/useColorField.js +26 -4
  34. package/dist/private/color/useColorField.js.map +1 -1
  35. package/dist/private/color/useColorField.mjs +26 -4
  36. package/dist/private/color/useColorField.mjs.map +1 -1
  37. package/dist/private/combobox/useComboBox.cjs +1 -1
  38. package/dist/private/combobox/useComboBox.cjs.map +1 -1
  39. package/dist/private/combobox/useComboBox.js +1 -1
  40. package/dist/private/combobox/useComboBox.js.map +1 -1
  41. package/dist/private/combobox/useComboBox.mjs +1 -1
  42. package/dist/private/combobox/useComboBox.mjs.map +1 -1
  43. package/dist/private/focus/FocusScope.cjs +7 -2
  44. package/dist/private/focus/FocusScope.cjs.map +1 -1
  45. package/dist/private/focus/FocusScope.js +7 -2
  46. package/dist/private/focus/FocusScope.js.map +1 -1
  47. package/dist/private/focus/FocusScope.mjs +7 -2
  48. package/dist/private/focus/FocusScope.mjs.map +1 -1
  49. package/dist/private/interactions/useFocusVisible.cjs +15 -3
  50. package/dist/private/interactions/useFocusVisible.cjs.map +1 -1
  51. package/dist/private/interactions/useFocusVisible.js +15 -3
  52. package/dist/private/interactions/useFocusVisible.js.map +1 -1
  53. package/dist/private/interactions/useFocusVisible.mjs +15 -3
  54. package/dist/private/interactions/useFocusVisible.mjs.map +1 -1
  55. package/dist/private/interactions/utils.cjs +23 -13
  56. package/dist/private/interactions/utils.cjs.map +1 -1
  57. package/dist/private/interactions/utils.js +25 -15
  58. package/dist/private/interactions/utils.js.map +1 -1
  59. package/dist/private/interactions/utils.mjs +25 -15
  60. package/dist/private/interactions/utils.mjs.map +1 -1
  61. package/dist/private/overlays/calculatePosition.cjs +3 -2
  62. package/dist/private/overlays/calculatePosition.cjs.map +1 -1
  63. package/dist/private/overlays/calculatePosition.js +5 -2
  64. package/dist/private/overlays/calculatePosition.js.map +1 -1
  65. package/dist/private/overlays/calculatePosition.mjs +3 -2
  66. package/dist/private/overlays/calculatePosition.mjs.map +1 -1
  67. package/dist/private/overlays/useOverlayPosition.cjs +5 -0
  68. package/dist/private/overlays/useOverlayPosition.cjs.map +1 -1
  69. package/dist/private/overlays/useOverlayPosition.js +6 -1
  70. package/dist/private/overlays/useOverlayPosition.js.map +1 -1
  71. package/dist/private/overlays/useOverlayPosition.mjs +6 -1
  72. package/dist/private/overlays/useOverlayPosition.mjs.map +1 -1
  73. package/dist/private/overlays/usePreventScroll.cjs +27 -35
  74. package/dist/private/overlays/usePreventScroll.cjs.map +1 -1
  75. package/dist/private/overlays/usePreventScroll.js +27 -35
  76. package/dist/private/overlays/usePreventScroll.js.map +1 -1
  77. package/dist/private/overlays/usePreventScroll.mjs +27 -35
  78. package/dist/private/overlays/usePreventScroll.mjs.map +1 -1
  79. package/dist/private/selection/useSelectableCollection.cjs +1 -0
  80. package/dist/private/selection/useSelectableCollection.cjs.map +1 -1
  81. package/dist/private/selection/useSelectableCollection.js +1 -0
  82. package/dist/private/selection/useSelectableCollection.js.map +1 -1
  83. package/dist/private/selection/useSelectableCollection.mjs +1 -0
  84. package/dist/private/selection/useSelectableCollection.mjs.map +1 -1
  85. package/dist/private/tabs/TabsKeyboardDelegate.cjs +3 -1
  86. package/dist/private/tabs/TabsKeyboardDelegate.cjs.map +1 -1
  87. package/dist/private/tabs/TabsKeyboardDelegate.js +3 -1
  88. package/dist/private/tabs/TabsKeyboardDelegate.js.map +1 -1
  89. package/dist/private/tabs/TabsKeyboardDelegate.mjs +3 -1
  90. package/dist/private/tabs/TabsKeyboardDelegate.mjs.map +1 -1
  91. package/dist/private/tokenfield/useToken.cjs +19 -4
  92. package/dist/private/tokenfield/useToken.cjs.map +1 -1
  93. package/dist/private/tokenfield/useToken.js +20 -4
  94. package/dist/private/tokenfield/useToken.js.map +1 -1
  95. package/dist/private/tokenfield/useToken.mjs +19 -4
  96. package/dist/private/tokenfield/useToken.mjs.map +1 -1
  97. package/dist/private/tokenfield/useTokenField.cjs +118 -42
  98. package/dist/private/tokenfield/useTokenField.cjs.map +1 -1
  99. package/dist/private/tokenfield/useTokenField.js +121 -44
  100. package/dist/private/tokenfield/useTokenField.js.map +1 -1
  101. package/dist/private/tokenfield/useTokenField.mjs +119 -43
  102. package/dist/private/tokenfield/useTokenField.mjs.map +1 -1
  103. package/dist/private/utils/domHelpers.cjs +21 -0
  104. package/dist/private/utils/domHelpers.cjs.map +1 -1
  105. package/dist/private/utils/domHelpers.js +20 -1
  106. package/dist/private/utils/domHelpers.js.map +1 -1
  107. package/dist/private/utils/domHelpers.mjs +20 -1
  108. package/dist/private/utils/domHelpers.mjs.map +1 -1
  109. package/dist/private/utils/getMetaValue.cjs +36 -0
  110. package/dist/private/utils/getMetaValue.cjs.map +1 -0
  111. package/dist/private/utils/getMetaValue.js +31 -0
  112. package/dist/private/utils/getMetaValue.js.map +1 -0
  113. package/dist/private/utils/getMetaValue.mjs +31 -0
  114. package/dist/private/utils/getMetaValue.mjs.map +1 -0
  115. package/dist/private/utils/getNonce.cjs +6 -10
  116. package/dist/private/utils/getNonce.cjs.map +1 -1
  117. package/dist/private/utils/getNonce.js +7 -11
  118. package/dist/private/utils/getNonce.js.map +1 -1
  119. package/dist/private/utils/getNonce.mjs +7 -11
  120. package/dist/private/utils/getNonce.mjs.map +1 -1
  121. package/dist/private/utils/useEvent.cjs +7 -9
  122. package/dist/private/utils/useEvent.cjs.map +1 -1
  123. package/dist/private/utils/useEvent.js +7 -9
  124. package/dist/private/utils/useEvent.js.map +1 -1
  125. package/dist/private/utils/useEvent.mjs +7 -9
  126. package/dist/private/utils/useEvent.mjs.map +1 -1
  127. package/dist/types/exports/index.d.ts +2 -2
  128. package/dist/types/exports/private/utils/domHelpers.d.ts +1 -1
  129. package/dist/types/exports/useFocusVisible.d.ts +2 -1
  130. package/dist/types/src/tokenfield/useTokenField.d.ts +3 -2
  131. package/dist/types/src/utils/domHelpers.d.ts +6 -2
  132. package/dist/types/src/utils/getMetaValue.d.ts +7 -0
  133. package/dist/types/src/utils/useEvent.d.ts +2 -2
  134. package/dist/types/src/virtualizer/Virtualizer.d.ts +3 -3
  135. package/package.json +6 -5
@@ -45,7 +45,26 @@ function $d447af545b77c9f1$export$f531f92e2a15358f(target, event, listener, opti
45
45
  for (let eventTarget of eventTargets)eventTarget.removeEventListener(event, listener, options);
46
46
  };
47
47
  }
48
+ function $d447af545b77c9f1$export$37a5fde709c1db82(target, property, value, priority) {
49
+ if (target == null) return ()=>{};
50
+ let restore = new Array();
51
+ let styleTargets = Array.isArray(target) ? target : [
52
+ target
53
+ ];
54
+ for (let styleTarget of styleTargets){
55
+ let initialValue = styleTarget.style.getPropertyValue(property);
56
+ let initialPriority = styleTarget.style.getPropertyPriority(property);
57
+ styleTarget.style.setProperty(property, value, priority);
58
+ restore.unshift(()=>{
59
+ if (initialValue) styleTarget.style.setProperty(property, initialValue, initialPriority);
60
+ else styleTarget.style.removeProperty(property);
61
+ });
62
+ }
63
+ return ()=>{
64
+ for (let cleanup of restore)cleanup();
65
+ };
66
+ }
48
67
 
49
68
 
50
- export {$d447af545b77c9f1$export$b204af158042fbac as getOwnerDocument, $d447af545b77c9f1$export$62858bae88b53fd0 as isDocument, $d447af545b77c9f1$export$f21a1ffae260145a as getOwnerWindow, $d447af545b77c9f1$export$8ee0fc9ee280b4ee as isNode, $d447af545b77c9f1$export$af51f0f06c0f328a as isShadowRoot, $d447af545b77c9f1$export$f531f92e2a15358f as addEvent};
69
+ export {$d447af545b77c9f1$export$b204af158042fbac as getOwnerDocument, $d447af545b77c9f1$export$62858bae88b53fd0 as isDocument, $d447af545b77c9f1$export$f21a1ffae260145a as getOwnerWindow, $d447af545b77c9f1$export$8ee0fc9ee280b4ee as isNode, $d447af545b77c9f1$export$af51f0f06c0f328a as isShadowRoot, $d447af545b77c9f1$export$f531f92e2a15358f as addEvent, $d447af545b77c9f1$export$37a5fde709c1db82 as setStyle};
51
70
  //# sourceMappingURL=domHelpers.mjs.map
@@ -1 +1 @@
1
- {"mappings":"AAAA;;;;;;;;;;CAUC,GAIM,MAAM,4CAAmB,CAAC;IAC/B,IAAI,+BAAS,SAAS,OAAO,OAAO,QAAQ;IAE5C,IAAI,0CAAW,SAAS,OAAO;IAE/B,2DAA2D;IAC3D,OAAO,QAAQ,iBAAkB,CAAA,OAAO,aAAa,cAAc,WAAW,SAAQ;AACxF;AAEO,MAAM,4CAAiB,CAAC;IAC7B,IAAI,gBAAgB,0CAAiB;IAErC,2DAA2D;IAC3D,OAAO,eAAe,eAAgB,CAAA,OAAO,WAAW,cAAc,SAAS,SAAQ;AACzF;AAMO,SAAS,0CAAO,KAAc;IACnC,OACE,UAAU,QACV,OAAO,UAAU,YACjB,cAAc,SACd,OAAO,MAAM,QAAQ,KAAK;AAE9B;AAEA;;;CAGC,GACD,SAAS,+BAAS,KAAc;IAC9B,OAAO,OAAO,UAAU,YAAY,SAAS,QAAQ,YAAY,SAAS,MAAM,MAAM,KAAK;AAC7F;AAMO,SAAS,0CAAW,KAAc;IACvC,OAAO,0CAAO,UAAU,MAAM,QAAQ,KAAK;AAC7C;AAMO,SAAS,0CAAa,KAAc;IACzC,8BAA8B;IAC9B,OAAO,0CAAO,UAAU,MAAM,QAAQ,KAAK,MAAM,UAAU;AAC7D;AAKO,SAAS,0CACd,MAAgC,EAChC,KAAyC,EACzC,QAAkE,EAClE,OAA2C;IAE3C,IAAI,YAAY,QAAQ,UAAU,MAChC,OAAO,KAAO;IAGhB,IAAI,eAAe,MAAM,OAAO,CAAC,UAAU,SAAS;QAAC;KAAO;IAE5D,KAAK,IAAI,eAAe,aACtB,YAAY,gBAAgB,CAAC,OAAO,UAA2B;IAGjE,OAAO;QACL,KAAK,IAAI,eAAe,aACtB,YAAY,mBAAmB,CAAC,OAAO,UAA2B;IAEtE;AACF","sources":["packages/react-aria/src/utils/domHelpers.ts"],"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 type {EventMapType} from '@react-types/shared';\n\nexport const getOwnerDocument = (target?: EventTarget | null): Document => {\n if (isWindow(target)) return target.document;\n\n if (isDocument(target)) return target;\n\n // @ts-expect-error Ensure safe access in SSR environments.\n return target?.ownerDocument ?? (typeof document !== 'undefined' ? document : undefined);\n};\n\nexport const getOwnerWindow = (target?: EventTarget | null): Window & typeof globalThis => {\n let ownerDocument = getOwnerDocument(target);\n\n // @ts-expect-error Ensure safe access in SSR environments.\n return ownerDocument?.defaultView ?? (typeof window !== 'undefined' ? window : undefined);\n};\n\n/**\n * Type guard that checks if a value is a Node. Verifies the presence and type of the nodeType\n * property.\n */\nexport function isNode(value: unknown): value is Node {\n return (\n value !== null &&\n typeof value === 'object' &&\n 'nodeType' in value &&\n typeof value.nodeType === 'number'\n );\n}\n\n/**\n * Type guard that checks if a value is a Window. Uses window self reference checks to\n * distinguish Window from other values.\n */\nfunction isWindow(value: unknown): value is Window & typeof globalThis {\n return typeof value === 'object' && value != null && 'window' in value && value.window === value;\n}\n\n/**\n * Type guard that checks if a value is a Document. Uses nodeType and host property checks to\n * distinguish Document from other values.\n */\nexport function isDocument(value: unknown): value is Document {\n return isNode(value) && value.nodeType === 9;\n}\n\n/**\n * Type guard that checks if a value is a ShadowRoot. Uses nodeType and host property checks to\n * distinguish ShadowRoot from other values.\n */\nexport function isShadowRoot(value: unknown): value is ShadowRoot {\n // 11 = DOCUMENT_FRAGMENT_NODE\n return isNode(value) && value.nodeType === 11 && 'host' in value;\n}\n\n/**\n * Attaches an event listener on target(s) and returns a cleanup function.\n */\nexport function addEvent<T extends EventTarget, K extends keyof EventMapType<Exclude<T, null>>>(\n target: T | EventTarget[] | null,\n event: Extract<K, string> | (string & {}),\n listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any,\n options?: boolean | AddEventListenerOptions\n): () => void {\n if (listener == null || target == null) {\n return () => {};\n }\n\n let eventTargets = Array.isArray(target) ? target : [target];\n\n for (let eventTarget of eventTargets) {\n eventTarget.addEventListener(event, listener as EventListener, options);\n }\n\n return () => {\n for (let eventTarget of eventTargets) {\n eventTarget.removeEventListener(event, listener as EventListener, options);\n }\n };\n}\n"],"names":[],"version":3,"file":"domHelpers.mjs.map"}
1
+ {"mappings":"AAAA;;;;;;;;;;CAUC,GAIM,MAAM,4CAAmB,CAAC;IAC/B,IAAI,+BAAS,SAAS,OAAO,OAAO,QAAQ;IAE5C,IAAI,0CAAW,SAAS,OAAO;IAE/B,2DAA2D;IAC3D,OAAO,QAAQ,iBAAkB,CAAA,OAAO,aAAa,cAAc,WAAW,SAAQ;AACxF;AAEO,MAAM,4CAAiB,CAAC;IAC7B,IAAI,gBAAgB,0CAAiB;IAErC,2DAA2D;IAC3D,OAAO,eAAe,eAAgB,CAAA,OAAO,WAAW,cAAc,SAAS,SAAQ;AACzF;AAMO,SAAS,0CAAO,KAAc;IACnC,OACE,UAAU,QACV,OAAO,UAAU,YACjB,cAAc,SACd,OAAO,MAAM,QAAQ,KAAK;AAE9B;AAEA;;;CAGC,GACD,SAAS,+BAAS,KAAc;IAC9B,OAAO,OAAO,UAAU,YAAY,SAAS,QAAQ,YAAY,SAAS,MAAM,MAAM,KAAK;AAC7F;AAMO,SAAS,0CAAW,KAAc;IACvC,OAAO,0CAAO,UAAU,MAAM,QAAQ,KAAK;AAC7C;AAMO,SAAS,0CAAa,KAAc;IACzC,8BAA8B;IAC9B,OAAO,0CAAO,UAAU,MAAM,QAAQ,KAAK,MAAM,UAAU;AAC7D;AAKO,SAAS,0CACd,MAAgC,EAChC,KAAyC,EACzC,QAAkE,EAClE,OAA2C;IAE3C,IAAI,YAAY,QAAQ,UAAU,MAChC,OAAO,KAAO;IAGhB,IAAI,eAAe,MAAM,OAAO,CAAC,UAAU,SAAS;QAAC;KAAO;IAE5D,KAAK,IAAI,eAAe,aACtB,YAAY,gBAAgB,CAAC,OAAO,UAA2B;IAGjE,OAAO;QACL,KAAK,IAAI,eAAe,aACtB,YAAY,mBAAmB,CAAC,OAAO,UAA2B;IAEtE;AACF;AAKO,SAAS,0CACd,MAA0C,EAC1C,QAAgB,EAChB,KAAa,EACb,QAAiB;IAEjB,IAAI,UAAU,MACZ,OAAO,KAAO;IAGhB,IAAI,UAAU,IAAI;IAClB,IAAI,eAAe,MAAM,OAAO,CAAC,UAAU,SAAS;QAAC;KAAO;IAE5D,KAAK,IAAI,eAAe,aAAc;QACpC,IAAI,eAAe,YAAY,KAAK,CAAC,gBAAgB,CAAC;QACtD,IAAI,kBAAkB,YAAY,KAAK,CAAC,mBAAmB,CAAC;QAE5D,YAAY,KAAK,CAAC,WAAW,CAAC,UAAU,OAAO;QAE/C,QAAQ,OAAO,CAAC;YACd,IAAI,cACF,YAAY,KAAK,CAAC,WAAW,CAAC,UAAU,cAAc;iBAEtD,YAAY,KAAK,CAAC,cAAc,CAAC;QAErC;IACF;IAEA,OAAO;QACL,KAAK,IAAI,WAAW,QAClB;IAEJ;AACF","sources":["packages/react-aria/src/utils/domHelpers.ts"],"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 type {EventMapType} from '@react-types/shared';\n\nexport const getOwnerDocument = (target?: EventTarget | null): Document => {\n if (isWindow(target)) return target.document;\n\n if (isDocument(target)) return target;\n\n // @ts-expect-error Ensure safe access in SSR environments.\n return target?.ownerDocument ?? (typeof document !== 'undefined' ? document : undefined);\n};\n\nexport const getOwnerWindow = (target?: EventTarget | null): Window & typeof globalThis => {\n let ownerDocument = getOwnerDocument(target);\n\n // @ts-expect-error Ensure safe access in SSR environments.\n return ownerDocument?.defaultView ?? (typeof window !== 'undefined' ? window : undefined);\n};\n\n/**\n * Type guard that checks if a value is a Node. Verifies the presence and type of the nodeType\n * property.\n */\nexport function isNode(value: unknown): value is Node {\n return (\n value !== null &&\n typeof value === 'object' &&\n 'nodeType' in value &&\n typeof value.nodeType === 'number'\n );\n}\n\n/**\n * Type guard that checks if a value is a Window. Uses window self reference checks to\n * distinguish Window from other values.\n */\nfunction isWindow(value: unknown): value is Window & typeof globalThis {\n return typeof value === 'object' && value != null && 'window' in value && value.window === value;\n}\n\n/**\n * Type guard that checks if a value is a Document. Uses nodeType and host property checks to\n * distinguish Document from other values.\n */\nexport function isDocument(value: unknown): value is Document {\n return isNode(value) && value.nodeType === 9;\n}\n\n/**\n * Type guard that checks if a value is a ShadowRoot. Uses nodeType and host property checks to\n * distinguish ShadowRoot from other values.\n */\nexport function isShadowRoot(value: unknown): value is ShadowRoot {\n // 11 = DOCUMENT_FRAGMENT_NODE\n return isNode(value) && value.nodeType === 11 && 'host' in value;\n}\n\n/**\n * Attaches an event listener on target(s) and returns a cleanup function.\n */\nexport function addEvent<T extends EventTarget, K extends keyof EventMapType<Exclude<T, null>>>(\n target: T | EventTarget[] | null,\n event: Extract<K, string> | (string & {}),\n listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any,\n options?: boolean | AddEventListenerOptions\n): () => void {\n if (listener == null || target == null) {\n return () => {};\n }\n\n let eventTargets = Array.isArray(target) ? target : [target];\n\n for (let eventTarget of eventTargets) {\n eventTarget.addEventListener(event, listener as EventListener, options);\n }\n\n return () => {\n for (let eventTarget of eventTargets) {\n eventTarget.removeEventListener(event, listener as EventListener, options);\n }\n };\n}\n\n/**\n * Sets a CSS property on an element and returns a cleanup function.\n */\nexport function setStyle(\n target: HTMLElement | HTMLElement[] | null,\n property: string,\n value: string,\n priority?: string\n): () => void {\n if (target == null) {\n return () => {};\n }\n\n let restore = new Array<Function>();\n let styleTargets = Array.isArray(target) ? target : [target];\n\n for (let styleTarget of styleTargets) {\n let initialValue = styleTarget.style.getPropertyValue(property);\n let initialPriority = styleTarget.style.getPropertyPriority(property);\n\n styleTarget.style.setProperty(property, value, priority);\n\n restore.unshift(() => {\n if (initialValue) {\n styleTarget.style.setProperty(property, initialValue, initialPriority);\n } else {\n styleTarget.style.removeProperty(property);\n }\n });\n }\n\n return () => {\n for (let cleanup of restore) {\n cleanup();\n }\n };\n}\n"],"names":[],"version":3,"file":"domHelpers.mjs.map"}
@@ -0,0 +1,36 @@
1
+ var $49582955cc364b1c$exports = require("./domHelpers.cjs");
2
+
3
+
4
+ function $parcel$export(e, n, v, s) {
5
+ Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
6
+ }
7
+
8
+ $parcel$export(module.exports, "getMetaValue", function () { return $3632a2abc5d34548$export$a929f3f93e2cc67e; });
9
+ /*
10
+ * Copyright 2026 Adobe. All rights reserved.
11
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License. You may obtain a copy
13
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
14
+ *
15
+ * Unless required by applicable law or agreed to in writing, software distributed under
16
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
17
+ * OF ANY KIND, either express or implied. See the License for the specific language
18
+ * governing permissions and limitations under the License.
19
+ */
20
+ function $3632a2abc5d34548$export$a929f3f93e2cc67e(key, doc) {
21
+ let ownerWindow = (0, $49582955cc364b1c$exports.getOwnerWindow)(doc);
22
+ let ownerDocument = (0, $49582955cc364b1c$exports.getOwnerDocument)(doc);
23
+ if (ownerDocument == null || ownerWindow == null) return;
24
+ let content = undefined;
25
+ let selector = `meta[name="${CSS.escape(key)}"], meta[property="${CSS.escape(key)}"]`;
26
+ let meta = ownerDocument.querySelector(selector);
27
+ if (meta && meta instanceof ownerWindow.HTMLMetaElement) {
28
+ if (key === 'csp-nonce' && meta.nonce) content ??= meta.nonce || undefined;
29
+ if (meta.content) content ??= meta.content || undefined;
30
+ }
31
+ if (key === 'csp-nonce') content ??= ownerWindow.__webpack_nonce__ || globalThis.__webpack_nonce__ || undefined;
32
+ return content;
33
+ }
34
+
35
+
36
+ //# sourceMappingURL=getMetaValue.cjs.map
@@ -0,0 +1 @@
1
+ {"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;AAWM,SAAS,0CAAa,GAAW,EAAE,GAAc;IACtD,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;IACjC,IAAI,gBAAgB,CAAA,GAAA,0CAAe,EAAE;IAErC,IAAI,iBAAiB,QAAQ,eAAe,MAC1C;IAGF,IAAI,UAA8B;IAClC,IAAI,WAAW,CAAC,WAAW,EAAE,IAAI,MAAM,CAAC,KAAK,mBAAmB,EAAE,IAAI,MAAM,CAAC,KAAK,EAAE,CAAC;IACrF,IAAI,OAAO,cAAc,aAAa,CAAC;IAEvC,IAAI,QAAQ,gBAAgB,YAAY,eAAe,EAAE;QACvD,IAAI,QAAQ,eAAe,KAAK,KAAK,EACnC,YAAY,KAAK,KAAK,IAAI;QAG5B,IAAI,KAAK,OAAO,EACd,YAAY,KAAK,OAAO,IAAI;IAEhC;IAEA,IAAI,QAAQ,aACV,YAAY,YAAY,iBAAiB,IAAI,WAAW,iBAAiB,IAAI;IAG/E,OAAO;AACT","sources":["packages/react-aria/src/utils/getMetaValue.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getOwnerDocument, getOwnerWindow} from './domHelpers';\n\ndeclare global {\n interface Window {\n __webpack_nonce__?: string;\n }\n var __webpack_nonce__: string | undefined;\n}\n\nexport function getMetaValue(key: string, doc?: Document): string | undefined {\n let ownerWindow = getOwnerWindow(doc);\n let ownerDocument = getOwnerDocument(doc);\n\n if (ownerDocument == null || ownerWindow == null) {\n return;\n }\n\n let content: string | undefined = undefined;\n let selector = `meta[name=\"${CSS.escape(key)}\"], meta[property=\"${CSS.escape(key)}\"]`;\n let meta = ownerDocument.querySelector(selector);\n\n if (meta && meta instanceof ownerWindow.HTMLMetaElement) {\n if (key === 'csp-nonce' && meta.nonce) {\n content ??= meta.nonce || undefined;\n }\n\n if (meta.content) {\n content ??= meta.content || undefined;\n }\n }\n\n if (key === 'csp-nonce') {\n content ??= ownerWindow.__webpack_nonce__ || globalThis.__webpack_nonce__ || undefined;\n }\n\n return content;\n}\n"],"names":[],"version":3,"file":"getMetaValue.cjs.map"}
@@ -0,0 +1,31 @@
1
+ import {getOwnerDocument as $cc3c3666b64debad$export$b204af158042fbac, getOwnerWindow as $cc3c3666b64debad$export$f21a1ffae260145a} from "./domHelpers.js";
2
+
3
+ /*
4
+ * Copyright 2026 Adobe. All rights reserved.
5
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
6
+ * you may not use this file except in compliance with the License. You may obtain a copy
7
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
8
+ *
9
+ * Unless required by applicable law or agreed to in writing, software distributed under
10
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
11
+ * OF ANY KIND, either express or implied. See the License for the specific language
12
+ * governing permissions and limitations under the License.
13
+ */
14
+ function $e5cbb54a67a6569d$export$a929f3f93e2cc67e(key, doc) {
15
+ let ownerWindow = (0, $cc3c3666b64debad$export$f21a1ffae260145a)(doc);
16
+ let ownerDocument = (0, $cc3c3666b64debad$export$b204af158042fbac)(doc);
17
+ if (ownerDocument == null || ownerWindow == null) return;
18
+ let content = undefined;
19
+ let selector = `meta[name="${CSS.escape(key)}"], meta[property="${CSS.escape(key)}"]`;
20
+ let meta = ownerDocument.querySelector(selector);
21
+ if (meta && meta instanceof ownerWindow.HTMLMetaElement) {
22
+ if (key === 'csp-nonce' && meta.nonce) content !== null && content !== void 0 ? content : content = meta.nonce || undefined;
23
+ if (meta.content) content !== null && content !== void 0 ? content : content = meta.content || undefined;
24
+ }
25
+ if (key === 'csp-nonce') content !== null && content !== void 0 ? content : content = ownerWindow.__webpack_nonce__ || globalThis.__webpack_nonce__ || undefined;
26
+ return content;
27
+ }
28
+
29
+
30
+ export {$e5cbb54a67a6569d$export$a929f3f93e2cc67e as getMetaValue};
31
+ //# sourceMappingURL=getMetaValue.js.map
@@ -0,0 +1 @@
1
+ {"mappings":";;AAAA;;;;;;;;;;CAUC;AAWM,SAAS,0CAAa,GAAW,EAAE,GAAc;IACtD,IAAI,cAAc,CAAA,GAAA,yCAAa,EAAE;IACjC,IAAI,gBAAgB,CAAA,GAAA,yCAAe,EAAE;IAErC,IAAI,iBAAiB,QAAQ,eAAe,MAC1C;IAGF,IAAI,UAA8B;IAClC,IAAI,WAAW,CAAC,WAAW,EAAE,IAAI,MAAM,CAAC,KAAK,mBAAmB,EAAE,IAAI,MAAM,CAAC,KAAK,EAAE,CAAC;IACrF,IAAI,OAAO,cAAc,aAAa,CAAC;IAEvC,IAAI,QAAQ,gBAAgB,YAAY,eAAe,EAAE;QACvD,IAAI,QAAQ,eAAe,KAAK,KAAK,EACnC,oBAAA,qBAAA,UAAA,UAAY,KAAK,KAAK,IAAI;QAG5B,IAAI,KAAK,OAAO,EACd,oBAAA,qBAAA,UAAA,UAAY,KAAK,OAAO,IAAI;IAEhC;IAEA,IAAI,QAAQ,aACV,oBAAA,qBAAA,UAAA,UAAY,YAAY,iBAAiB,IAAI,WAAW,iBAAiB,IAAI;IAG/E,OAAO;AACT","sources":["packages/react-aria/src/utils/getMetaValue.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getOwnerDocument, getOwnerWindow} from './domHelpers';\n\ndeclare global {\n interface Window {\n __webpack_nonce__?: string;\n }\n var __webpack_nonce__: string | undefined;\n}\n\nexport function getMetaValue(key: string, doc?: Document): string | undefined {\n let ownerWindow = getOwnerWindow(doc);\n let ownerDocument = getOwnerDocument(doc);\n\n if (ownerDocument == null || ownerWindow == null) {\n return;\n }\n\n let content: string | undefined = undefined;\n let selector = `meta[name=\"${CSS.escape(key)}\"], meta[property=\"${CSS.escape(key)}\"]`;\n let meta = ownerDocument.querySelector(selector);\n\n if (meta && meta instanceof ownerWindow.HTMLMetaElement) {\n if (key === 'csp-nonce' && meta.nonce) {\n content ??= meta.nonce || undefined;\n }\n\n if (meta.content) {\n content ??= meta.content || undefined;\n }\n }\n\n if (key === 'csp-nonce') {\n content ??= ownerWindow.__webpack_nonce__ || globalThis.__webpack_nonce__ || undefined;\n }\n\n return content;\n}\n"],"names":[],"version":3,"file":"getMetaValue.js.map"}
@@ -0,0 +1,31 @@
1
+ import {getOwnerDocument as $d447af545b77c9f1$export$b204af158042fbac, getOwnerWindow as $d447af545b77c9f1$export$f21a1ffae260145a} from "./domHelpers.mjs";
2
+
3
+ /*
4
+ * Copyright 2026 Adobe. All rights reserved.
5
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
6
+ * you may not use this file except in compliance with the License. You may obtain a copy
7
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
8
+ *
9
+ * Unless required by applicable law or agreed to in writing, software distributed under
10
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
11
+ * OF ANY KIND, either express or implied. See the License for the specific language
12
+ * governing permissions and limitations under the License.
13
+ */
14
+ function $7096878c21af5e66$export$a929f3f93e2cc67e(key, doc) {
15
+ let ownerWindow = (0, $d447af545b77c9f1$export$f21a1ffae260145a)(doc);
16
+ let ownerDocument = (0, $d447af545b77c9f1$export$b204af158042fbac)(doc);
17
+ if (ownerDocument == null || ownerWindow == null) return;
18
+ let content = undefined;
19
+ let selector = `meta[name="${CSS.escape(key)}"], meta[property="${CSS.escape(key)}"]`;
20
+ let meta = ownerDocument.querySelector(selector);
21
+ if (meta && meta instanceof ownerWindow.HTMLMetaElement) {
22
+ if (key === 'csp-nonce' && meta.nonce) content ??= meta.nonce || undefined;
23
+ if (meta.content) content ??= meta.content || undefined;
24
+ }
25
+ if (key === 'csp-nonce') content ??= ownerWindow.__webpack_nonce__ || globalThis.__webpack_nonce__ || undefined;
26
+ return content;
27
+ }
28
+
29
+
30
+ export {$7096878c21af5e66$export$a929f3f93e2cc67e as getMetaValue};
31
+ //# sourceMappingURL=getMetaValue.mjs.map
@@ -0,0 +1 @@
1
+ {"mappings":";;AAAA;;;;;;;;;;CAUC;AAWM,SAAS,0CAAa,GAAW,EAAE,GAAc;IACtD,IAAI,cAAc,CAAA,GAAA,yCAAa,EAAE;IACjC,IAAI,gBAAgB,CAAA,GAAA,yCAAe,EAAE;IAErC,IAAI,iBAAiB,QAAQ,eAAe,MAC1C;IAGF,IAAI,UAA8B;IAClC,IAAI,WAAW,CAAC,WAAW,EAAE,IAAI,MAAM,CAAC,KAAK,mBAAmB,EAAE,IAAI,MAAM,CAAC,KAAK,EAAE,CAAC;IACrF,IAAI,OAAO,cAAc,aAAa,CAAC;IAEvC,IAAI,QAAQ,gBAAgB,YAAY,eAAe,EAAE;QACvD,IAAI,QAAQ,eAAe,KAAK,KAAK,EACnC,YAAY,KAAK,KAAK,IAAI;QAG5B,IAAI,KAAK,OAAO,EACd,YAAY,KAAK,OAAO,IAAI;IAEhC;IAEA,IAAI,QAAQ,aACV,YAAY,YAAY,iBAAiB,IAAI,WAAW,iBAAiB,IAAI;IAG/E,OAAO;AACT","sources":["packages/react-aria/src/utils/getMetaValue.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getOwnerDocument, getOwnerWindow} from './domHelpers';\n\ndeclare global {\n interface Window {\n __webpack_nonce__?: string;\n }\n var __webpack_nonce__: string | undefined;\n}\n\nexport function getMetaValue(key: string, doc?: Document): string | undefined {\n let ownerWindow = getOwnerWindow(doc);\n let ownerDocument = getOwnerDocument(doc);\n\n if (ownerDocument == null || ownerWindow == null) {\n return;\n }\n\n let content: string | undefined = undefined;\n let selector = `meta[name=\"${CSS.escape(key)}\"], meta[property=\"${CSS.escape(key)}\"]`;\n let meta = ownerDocument.querySelector(selector);\n\n if (meta && meta instanceof ownerWindow.HTMLMetaElement) {\n if (key === 'csp-nonce' && meta.nonce) {\n content ??= meta.nonce || undefined;\n }\n\n if (meta.content) {\n content ??= meta.content || undefined;\n }\n }\n\n if (key === 'csp-nonce') {\n content ??= ownerWindow.__webpack_nonce__ || globalThis.__webpack_nonce__ || undefined;\n }\n\n return content;\n}\n"],"names":[],"version":3,"file":"getMetaValue.mjs.map"}
@@ -1,3 +1,4 @@
1
+ var $3632a2abc5d34548$exports = require("./getMetaValue.cjs");
1
2
  var $49582955cc364b1c$exports = require("./domHelpers.cjs");
2
3
 
3
4
 
@@ -17,21 +18,16 @@ $parcel$export(module.exports, "getNonce", function () { return $a9ae3cc70c0e209
17
18
  * OF ANY KIND, either express or implied. See the License for the specific language
18
19
  * governing permissions and limitations under the License.
19
20
  */
20
- function $a9ae3cc70c0e2090$var$getWebpackNonce(doc) {
21
- let ownerWindow = doc?.defaultView;
22
- return ownerWindow?.__webpack_nonce__ || globalThis['__webpack_nonce__'] || undefined;
23
- }
21
+
24
22
  let $a9ae3cc70c0e2090$var$nonceCache = new WeakMap();
25
23
  function $a9ae3cc70c0e2090$export$88b319273f3705b4() {
26
24
  $a9ae3cc70c0e2090$var$nonceCache = new WeakMap();
27
25
  }
28
26
  function $a9ae3cc70c0e2090$export$2b85b721e524d74b(doc) {
29
- let d = doc ?? (typeof document !== 'undefined' ? document : undefined);
30
- if (!d) return $a9ae3cc70c0e2090$var$getWebpackNonce(d);
31
- if ($a9ae3cc70c0e2090$var$nonceCache.has(d)) return $a9ae3cc70c0e2090$var$nonceCache.get(d);
32
- let meta = d.querySelector('meta[property="csp-nonce"]');
33
- let nonce = meta && meta instanceof (0, $49582955cc364b1c$exports.getOwnerWindow)(meta).HTMLMetaElement && (meta.nonce || meta.content) || $a9ae3cc70c0e2090$var$getWebpackNonce(d) || undefined;
34
- if (nonce !== undefined) $a9ae3cc70c0e2090$var$nonceCache.set(d, nonce);
27
+ let ownerDocument = (0, $49582955cc364b1c$exports.getOwnerDocument)(doc);
28
+ let nonce = $a9ae3cc70c0e2090$var$nonceCache.get(ownerDocument);
29
+ nonce ??= (0, $3632a2abc5d34548$exports.getMetaValue)('csp-nonce', ownerDocument);
30
+ if (nonce !== undefined) $a9ae3cc70c0e2090$var$nonceCache.set(ownerDocument, nonce);
35
31
  return nonce;
36
32
  }
37
33
 
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;AASD,SAAS,sCAAgB,GAAc;IACrC,IAAI,cAAc,KAAK;IACvB,OAAO,aAAa,qBAAqB,UAAU,CAAC,oBAAoB,IAAI;AAC9E;AAEA,IAAI,mCAAa,IAAI;AAGd,SAAS;IACd,mCAAa,IAAI;AACnB;AAOO,SAAS,0CAAS,GAAc;IACrC,IAAI,IAAI,OAAQ,CAAA,OAAO,aAAa,cAAc,WAAW,SAAQ;IACrE,IAAI,CAAC,GACH,OAAO,sCAAgB;IAGzB,IAAI,iCAAW,GAAG,CAAC,IACjB,OAAO,iCAAW,GAAG,CAAC;IAGxB,IAAI,OAAO,EAAE,aAAa,CAAC;IAC3B,IAAI,QACF,AAAC,QACC,gBAAgB,CAAA,GAAA,wCAAa,EAAE,MAAM,eAAe,IACnD,CAAA,KAAK,KAAK,IAAI,KAAK,OAAO,AAAD,KAC5B,sCAAgB,MAChB;IAEF,IAAI,UAAU,WACZ,iCAAW,GAAG,CAAC,GAAG;IAEpB,OAAO;AACT","sources":["packages/react-aria/src/utils/getNonce.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getOwnerWindow} from './domHelpers';\n\ntype NonceWindow = Window &\n typeof globalThis & {\n __webpack_nonce__?: string;\n };\n\nfunction getWebpackNonce(doc?: Document): string | undefined {\n let ownerWindow = doc?.defaultView as NonceWindow | null | undefined;\n return ownerWindow?.__webpack_nonce__ || globalThis['__webpack_nonce__'] || undefined;\n}\n\nlet nonceCache = new WeakMap<Document, string>();\n\n/** Reset the cached nonce value. Exported for testing only. */\nexport function resetNonceCache(): void {\n nonceCache = new WeakMap();\n}\n\n/**\n * Returns the CSP nonce, if configured via a `<meta property=\"csp-nonce\">` tag or\n * `__webpack_nonce__`. This allows dynamically injected `<style>` elements to work with Content\n * Security Policy.\n */\nexport function getNonce(doc?: Document): string | undefined {\n let d = doc ?? (typeof document !== 'undefined' ? document : undefined);\n if (!d) {\n return getWebpackNonce(d);\n }\n\n if (nonceCache.has(d)) {\n return nonceCache.get(d);\n }\n\n let meta = d.querySelector('meta[property=\"csp-nonce\"]');\n let nonce =\n (meta &&\n meta instanceof getOwnerWindow(meta).HTMLMetaElement &&\n (meta.nonce || meta.content)) ||\n getWebpackNonce(d) ||\n undefined;\n\n if (nonce !== undefined) {\n nonceCache.set(d, nonce);\n }\n return nonce;\n}\n"],"names":[],"version":3,"file":"getNonce.cjs.map"}
1
+ {"mappings":";;;;;;;;;AAAA;;;;;;;;;;CAUC;;AAKD,IAAI,mCAAa,IAAI;AAGd,SAAS;IACd,mCAAa,IAAI;AACnB;AAOO,SAAS,0CAAS,GAAc;IACrC,IAAI,gBAAgB,CAAA,GAAA,0CAAe,EAAE;IAErC,IAAI,QAAQ,iCAAW,GAAG,CAAC;IAC3B,UAAU,CAAA,GAAA,sCAAW,EAAE,aAAa;IAEpC,IAAI,UAAU,WACZ,iCAAW,GAAG,CAAC,eAAe;IAEhC,OAAO;AACT","sources":["packages/react-aria/src/utils/getNonce.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getMetaValue} from './getMetaValue';\nimport {getOwnerDocument} from './domHelpers';\n\nlet nonceCache = new WeakMap<Document, string>();\n\n/** Reset the cached nonce value. Exported for testing only. */\nexport function resetNonceCache(): void {\n nonceCache = new WeakMap();\n}\n\n/**\n * Returns the CSP nonce, if configured via a `<meta property=\"csp-nonce\">` tag or\n * `__webpack_nonce__`. This allows dynamically injected `<style>` elements to work with Content\n * Security Policy.\n */\nexport function getNonce(doc?: Document): string | undefined {\n let ownerDocument = getOwnerDocument(doc);\n\n let nonce = nonceCache.get(ownerDocument);\n nonce ??= getMetaValue('csp-nonce', ownerDocument);\n\n if (nonce !== undefined) {\n nonceCache.set(ownerDocument, nonce);\n }\n return nonce;\n}\n"],"names":[],"version":3,"file":"getNonce.cjs.map"}
@@ -1,4 +1,5 @@
1
- import {getOwnerWindow as $cc3c3666b64debad$export$f21a1ffae260145a} from "./domHelpers.js";
1
+ import {getMetaValue as $e5cbb54a67a6569d$export$a929f3f93e2cc67e} from "./getMetaValue.js";
2
+ import {getOwnerDocument as $cc3c3666b64debad$export$b204af158042fbac} from "./domHelpers.js";
2
3
 
3
4
  /*
4
5
  * Copyright 2026 Adobe. All rights reserved.
@@ -11,21 +12,16 @@ import {getOwnerWindow as $cc3c3666b64debad$export$f21a1ffae260145a} from "./dom
11
12
  * OF ANY KIND, either express or implied. See the License for the specific language
12
13
  * governing permissions and limitations under the License.
13
14
  */
14
- function $fb5d33e131fca75a$var$getWebpackNonce(doc) {
15
- let ownerWindow = doc === null || doc === void 0 ? void 0 : doc.defaultView;
16
- return (ownerWindow === null || ownerWindow === void 0 ? void 0 : ownerWindow.__webpack_nonce__) || globalThis['__webpack_nonce__'] || undefined;
17
- }
15
+
18
16
  let $fb5d33e131fca75a$var$nonceCache = new WeakMap();
19
17
  function $fb5d33e131fca75a$export$88b319273f3705b4() {
20
18
  $fb5d33e131fca75a$var$nonceCache = new WeakMap();
21
19
  }
22
20
  function $fb5d33e131fca75a$export$2b85b721e524d74b(doc) {
23
- let d = doc !== null && doc !== void 0 ? doc : typeof document !== 'undefined' ? document : undefined;
24
- if (!d) return $fb5d33e131fca75a$var$getWebpackNonce(d);
25
- if ($fb5d33e131fca75a$var$nonceCache.has(d)) return $fb5d33e131fca75a$var$nonceCache.get(d);
26
- let meta = d.querySelector('meta[property="csp-nonce"]');
27
- let nonce = meta && meta instanceof (0, $cc3c3666b64debad$export$f21a1ffae260145a)(meta).HTMLMetaElement && (meta.nonce || meta.content) || $fb5d33e131fca75a$var$getWebpackNonce(d) || undefined;
28
- if (nonce !== undefined) $fb5d33e131fca75a$var$nonceCache.set(d, nonce);
21
+ let ownerDocument = (0, $cc3c3666b64debad$export$b204af158042fbac)(doc);
22
+ let nonce = $fb5d33e131fca75a$var$nonceCache.get(ownerDocument);
23
+ nonce !== null && nonce !== void 0 ? nonce : nonce = (0, $e5cbb54a67a6569d$export$a929f3f93e2cc67e)('csp-nonce', ownerDocument);
24
+ if (nonce !== undefined) $fb5d33e131fca75a$var$nonceCache.set(ownerDocument, nonce);
29
25
  return nonce;
30
26
  }
31
27
 
@@ -1 +1 @@
1
- {"mappings":";;AAAA;;;;;;;;;;CAUC;AASD,SAAS,sCAAgB,GAAc;IACrC,IAAI,cAAc,gBAAA,0BAAA,IAAK,WAAW;IAClC,OAAO,CAAA,wBAAA,kCAAA,YAAa,iBAAiB,KAAI,UAAU,CAAC,oBAAoB,IAAI;AAC9E;AAEA,IAAI,mCAAa,IAAI;AAGd,SAAS;IACd,mCAAa,IAAI;AACnB;AAOO,SAAS,0CAAS,GAAc;IACrC,IAAI,IAAI,gBAAA,iBAAA,MAAQ,OAAO,aAAa,cAAc,WAAW;IAC7D,IAAI,CAAC,GACH,OAAO,sCAAgB;IAGzB,IAAI,iCAAW,GAAG,CAAC,IACjB,OAAO,iCAAW,GAAG,CAAC;IAGxB,IAAI,OAAO,EAAE,aAAa,CAAC;IAC3B,IAAI,QACF,AAAC,QACC,gBAAgB,CAAA,GAAA,yCAAa,EAAE,MAAM,eAAe,IACnD,CAAA,KAAK,KAAK,IAAI,KAAK,OAAO,AAAD,KAC5B,sCAAgB,MAChB;IAEF,IAAI,UAAU,WACZ,iCAAW,GAAG,CAAC,GAAG;IAEpB,OAAO;AACT","sources":["packages/react-aria/src/utils/getNonce.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getOwnerWindow} from './domHelpers';\n\ntype NonceWindow = Window &\n typeof globalThis & {\n __webpack_nonce__?: string;\n };\n\nfunction getWebpackNonce(doc?: Document): string | undefined {\n let ownerWindow = doc?.defaultView as NonceWindow | null | undefined;\n return ownerWindow?.__webpack_nonce__ || globalThis['__webpack_nonce__'] || undefined;\n}\n\nlet nonceCache = new WeakMap<Document, string>();\n\n/** Reset the cached nonce value. Exported for testing only. */\nexport function resetNonceCache(): void {\n nonceCache = new WeakMap();\n}\n\n/**\n * Returns the CSP nonce, if configured via a `<meta property=\"csp-nonce\">` tag or\n * `__webpack_nonce__`. This allows dynamically injected `<style>` elements to work with Content\n * Security Policy.\n */\nexport function getNonce(doc?: Document): string | undefined {\n let d = doc ?? (typeof document !== 'undefined' ? document : undefined);\n if (!d) {\n return getWebpackNonce(d);\n }\n\n if (nonceCache.has(d)) {\n return nonceCache.get(d);\n }\n\n let meta = d.querySelector('meta[property=\"csp-nonce\"]');\n let nonce =\n (meta &&\n meta instanceof getOwnerWindow(meta).HTMLMetaElement &&\n (meta.nonce || meta.content)) ||\n getWebpackNonce(d) ||\n undefined;\n\n if (nonce !== undefined) {\n nonceCache.set(d, nonce);\n }\n return nonce;\n}\n"],"names":[],"version":3,"file":"getNonce.js.map"}
1
+ {"mappings":";;;AAAA;;;;;;;;;;CAUC;;AAKD,IAAI,mCAAa,IAAI;AAGd,SAAS;IACd,mCAAa,IAAI;AACnB;AAOO,SAAS,0CAAS,GAAc;IACrC,IAAI,gBAAgB,CAAA,GAAA,yCAAe,EAAE;IAErC,IAAI,QAAQ,iCAAW,GAAG,CAAC;IAC3B,kBAAA,mBAAA,QAAA,QAAU,CAAA,GAAA,yCAAW,EAAE,aAAa;IAEpC,IAAI,UAAU,WACZ,iCAAW,GAAG,CAAC,eAAe;IAEhC,OAAO;AACT","sources":["packages/react-aria/src/utils/getNonce.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getMetaValue} from './getMetaValue';\nimport {getOwnerDocument} from './domHelpers';\n\nlet nonceCache = new WeakMap<Document, string>();\n\n/** Reset the cached nonce value. Exported for testing only. */\nexport function resetNonceCache(): void {\n nonceCache = new WeakMap();\n}\n\n/**\n * Returns the CSP nonce, if configured via a `<meta property=\"csp-nonce\">` tag or\n * `__webpack_nonce__`. This allows dynamically injected `<style>` elements to work with Content\n * Security Policy.\n */\nexport function getNonce(doc?: Document): string | undefined {\n let ownerDocument = getOwnerDocument(doc);\n\n let nonce = nonceCache.get(ownerDocument);\n nonce ??= getMetaValue('csp-nonce', ownerDocument);\n\n if (nonce !== undefined) {\n nonceCache.set(ownerDocument, nonce);\n }\n return nonce;\n}\n"],"names":[],"version":3,"file":"getNonce.js.map"}
@@ -1,4 +1,5 @@
1
- import {getOwnerWindow as $d447af545b77c9f1$export$f21a1ffae260145a} from "./domHelpers.mjs";
1
+ import {getMetaValue as $7096878c21af5e66$export$a929f3f93e2cc67e} from "./getMetaValue.mjs";
2
+ import {getOwnerDocument as $d447af545b77c9f1$export$b204af158042fbac} from "./domHelpers.mjs";
2
3
 
3
4
  /*
4
5
  * Copyright 2026 Adobe. All rights reserved.
@@ -11,21 +12,16 @@ import {getOwnerWindow as $d447af545b77c9f1$export$f21a1ffae260145a} from "./dom
11
12
  * OF ANY KIND, either express or implied. See the License for the specific language
12
13
  * governing permissions and limitations under the License.
13
14
  */
14
- function $2b2d34ff061957fb$var$getWebpackNonce(doc) {
15
- let ownerWindow = doc?.defaultView;
16
- return ownerWindow?.__webpack_nonce__ || globalThis['__webpack_nonce__'] || undefined;
17
- }
15
+
18
16
  let $2b2d34ff061957fb$var$nonceCache = new WeakMap();
19
17
  function $2b2d34ff061957fb$export$88b319273f3705b4() {
20
18
  $2b2d34ff061957fb$var$nonceCache = new WeakMap();
21
19
  }
22
20
  function $2b2d34ff061957fb$export$2b85b721e524d74b(doc) {
23
- let d = doc ?? (typeof document !== 'undefined' ? document : undefined);
24
- if (!d) return $2b2d34ff061957fb$var$getWebpackNonce(d);
25
- if ($2b2d34ff061957fb$var$nonceCache.has(d)) return $2b2d34ff061957fb$var$nonceCache.get(d);
26
- let meta = d.querySelector('meta[property="csp-nonce"]');
27
- let nonce = meta && meta instanceof (0, $d447af545b77c9f1$export$f21a1ffae260145a)(meta).HTMLMetaElement && (meta.nonce || meta.content) || $2b2d34ff061957fb$var$getWebpackNonce(d) || undefined;
28
- if (nonce !== undefined) $2b2d34ff061957fb$var$nonceCache.set(d, nonce);
21
+ let ownerDocument = (0, $d447af545b77c9f1$export$b204af158042fbac)(doc);
22
+ let nonce = $2b2d34ff061957fb$var$nonceCache.get(ownerDocument);
23
+ nonce ??= (0, $7096878c21af5e66$export$a929f3f93e2cc67e)('csp-nonce', ownerDocument);
24
+ if (nonce !== undefined) $2b2d34ff061957fb$var$nonceCache.set(ownerDocument, nonce);
29
25
  return nonce;
30
26
  }
31
27
 
@@ -1 +1 @@
1
- {"mappings":";;AAAA;;;;;;;;;;CAUC;AASD,SAAS,sCAAgB,GAAc;IACrC,IAAI,cAAc,KAAK;IACvB,OAAO,aAAa,qBAAqB,UAAU,CAAC,oBAAoB,IAAI;AAC9E;AAEA,IAAI,mCAAa,IAAI;AAGd,SAAS;IACd,mCAAa,IAAI;AACnB;AAOO,SAAS,0CAAS,GAAc;IACrC,IAAI,IAAI,OAAQ,CAAA,OAAO,aAAa,cAAc,WAAW,SAAQ;IACrE,IAAI,CAAC,GACH,OAAO,sCAAgB;IAGzB,IAAI,iCAAW,GAAG,CAAC,IACjB,OAAO,iCAAW,GAAG,CAAC;IAGxB,IAAI,OAAO,EAAE,aAAa,CAAC;IAC3B,IAAI,QACF,AAAC,QACC,gBAAgB,CAAA,GAAA,yCAAa,EAAE,MAAM,eAAe,IACnD,CAAA,KAAK,KAAK,IAAI,KAAK,OAAO,AAAD,KAC5B,sCAAgB,MAChB;IAEF,IAAI,UAAU,WACZ,iCAAW,GAAG,CAAC,GAAG;IAEpB,OAAO;AACT","sources":["packages/react-aria/src/utils/getNonce.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getOwnerWindow} from './domHelpers';\n\ntype NonceWindow = Window &\n typeof globalThis & {\n __webpack_nonce__?: string;\n };\n\nfunction getWebpackNonce(doc?: Document): string | undefined {\n let ownerWindow = doc?.defaultView as NonceWindow | null | undefined;\n return ownerWindow?.__webpack_nonce__ || globalThis['__webpack_nonce__'] || undefined;\n}\n\nlet nonceCache = new WeakMap<Document, string>();\n\n/** Reset the cached nonce value. Exported for testing only. */\nexport function resetNonceCache(): void {\n nonceCache = new WeakMap();\n}\n\n/**\n * Returns the CSP nonce, if configured via a `<meta property=\"csp-nonce\">` tag or\n * `__webpack_nonce__`. This allows dynamically injected `<style>` elements to work with Content\n * Security Policy.\n */\nexport function getNonce(doc?: Document): string | undefined {\n let d = doc ?? (typeof document !== 'undefined' ? document : undefined);\n if (!d) {\n return getWebpackNonce(d);\n }\n\n if (nonceCache.has(d)) {\n return nonceCache.get(d);\n }\n\n let meta = d.querySelector('meta[property=\"csp-nonce\"]');\n let nonce =\n (meta &&\n meta instanceof getOwnerWindow(meta).HTMLMetaElement &&\n (meta.nonce || meta.content)) ||\n getWebpackNonce(d) ||\n undefined;\n\n if (nonce !== undefined) {\n nonceCache.set(d, nonce);\n }\n return nonce;\n}\n"],"names":[],"version":3,"file":"getNonce.mjs.map"}
1
+ {"mappings":";;;AAAA;;;;;;;;;;CAUC;;AAKD,IAAI,mCAAa,IAAI;AAGd,SAAS;IACd,mCAAa,IAAI;AACnB;AAOO,SAAS,0CAAS,GAAc;IACrC,IAAI,gBAAgB,CAAA,GAAA,yCAAe,EAAE;IAErC,IAAI,QAAQ,iCAAW,GAAG,CAAC;IAC3B,UAAU,CAAA,GAAA,yCAAW,EAAE,aAAa;IAEpC,IAAI,UAAU,WACZ,iCAAW,GAAG,CAAC,eAAe;IAEhC,OAAO;AACT","sources":["packages/react-aria/src/utils/getNonce.ts"],"sourcesContent":["/*\n * Copyright 2026 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 {getMetaValue} from './getMetaValue';\nimport {getOwnerDocument} from './domHelpers';\n\nlet nonceCache = new WeakMap<Document, string>();\n\n/** Reset the cached nonce value. Exported for testing only. */\nexport function resetNonceCache(): void {\n nonceCache = new WeakMap();\n}\n\n/**\n * Returns the CSP nonce, if configured via a `<meta property=\"csp-nonce\">` tag or\n * `__webpack_nonce__`. This allows dynamically injected `<style>` elements to work with Content\n * Security Policy.\n */\nexport function getNonce(doc?: Document): string | undefined {\n let ownerDocument = getOwnerDocument(doc);\n\n let nonce = nonceCache.get(ownerDocument);\n nonce ??= getMetaValue('csp-nonce', ownerDocument);\n\n if (nonce !== undefined) {\n nonceCache.set(ownerDocument, nonce);\n }\n return nonce;\n}\n"],"names":[],"version":3,"file":"getNonce.mjs.map"}
@@ -1,3 +1,4 @@
1
+ var $49582955cc364b1c$exports = require("./domHelpers.cjs");
1
2
  var $d6e22460ce4d6b26$exports = require("./useEffectEvent.cjs");
2
3
  var $iuD9A$react = require("react");
3
4
 
@@ -19,16 +20,13 @@ $parcel$export(module.exports, "useEvent", function () { return $6e76e65001bbcda
19
20
  * governing permissions and limitations under the License.
20
21
  */
21
22
 
22
- function $6e76e65001bbcda2$export$90fc3a17d93f704c(ref, event, handler, options) {
23
- let handleEvent = (0, $d6e22460ce4d6b26$exports.useEffectEvent)(handler);
24
- let isDisabled = handler == null;
23
+
24
+ function $6e76e65001bbcda2$export$90fc3a17d93f704c(ref, event, listener, options) {
25
+ let handleEvent = (0, $d6e22460ce4d6b26$exports.useEffectEvent)(listener);
26
+ let isDisabled = listener == null;
25
27
  (0, $iuD9A$react.useEffect)(()=>{
26
- if (isDisabled || !ref.current) return;
27
- let element = ref.current;
28
- element.addEventListener(event, handleEvent, options);
29
- return ()=>{
30
- element.removeEventListener(event, handleEvent, options);
31
- };
28
+ if (isDisabled || ref.current == null) return;
29
+ return (0, $49582955cc364b1c$exports.addEvent)(ref.current, event, handleEvent, options);
32
30
  }, [
33
31
  ref,
34
32
  event,
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;AAAA;;;;;;;;;;CAUC;;AAMM,SAAS,0CACd,GAAkC,EAClC,KAAwB,EACxB,OAAqE,EACrE,OAA2C;IAE3C,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;IACjC,IAAI,aAAa,WAAW;IAE5B,CAAA,GAAA,sBAAQ,EAAE;QACR,IAAI,cAAc,CAAC,IAAI,OAAO,EAC5B;QAGF,IAAI,UAAU,IAAI,OAAO;QACzB,QAAQ,gBAAgB,CAAC,OAAO,aAA8B;QAC9D,OAAO;YACL,QAAQ,mBAAmB,CAAC,OAAO,aAA8B;QACnE;IACF,GAAG;QAAC;QAAK;QAAO;QAAS;KAAW;AACtC","sources":["packages/react-aria/src/utils/useEvent.ts"],"sourcesContent":["/*\n * Copyright 2021 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 {RefObject} from '@react-types/shared';\nimport {useEffect} from 'react';\nimport {useEffectEvent} from './useEffectEvent';\n\nexport function useEvent<K extends keyof GlobalEventHandlersEventMap>(\n ref: RefObject<EventTarget | null>,\n event: K | (string & {}),\n handler?: (this: Document, ev: GlobalEventHandlersEventMap[K]) => any,\n options?: boolean | AddEventListenerOptions\n): void {\n let handleEvent = useEffectEvent(handler);\n let isDisabled = handler == null;\n\n useEffect(() => {\n if (isDisabled || !ref.current) {\n return;\n }\n\n let element = ref.current;\n element.addEventListener(event, handleEvent as EventListener, options);\n return () => {\n element.removeEventListener(event, handleEvent as EventListener, options);\n };\n }, [ref, event, options, isDisabled]);\n}\n"],"names":[],"version":3,"file":"useEvent.cjs.map"}
1
+ {"mappings":";;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;AAOM,SAAS,0CACd,GAAwB,EACxB,KAAyC,EACzC,QAAkE,EAClE,OAA2C;IAE3C,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;IACjC,IAAI,aAAa,YAAY;IAE7B,CAAA,GAAA,sBAAQ,EAAE;QACR,IAAI,cAAc,IAAI,OAAO,IAAI,MAC/B;QAGF,OAAO,CAAA,GAAA,kCAAO,EAAE,IAAI,OAAO,EAAE,OAAO,aAAa;IACnD,GAAG;QAAC;QAAK;QAAO;QAAS;KAAW;AACtC","sources":["packages/react-aria/src/utils/useEvent.ts"],"sourcesContent":["/*\n * Copyright 2021 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 {addEvent} from './domHelpers';\nimport {EventMapType, RefObject} from '@react-types/shared';\nimport {useEffect} from 'react';\nimport {useEffectEvent} from './useEffectEvent';\n\nexport function useEvent<T extends EventTarget, K extends keyof EventMapType<T>>(\n ref: RefObject<T | null>,\n event: Extract<K, string> | (string & {}),\n listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any,\n options?: boolean | AddEventListenerOptions\n): void {\n let handleEvent = useEffectEvent(listener);\n let isDisabled = listener == null;\n\n useEffect(() => {\n if (isDisabled || ref.current == null) {\n return;\n }\n\n return addEvent(ref.current, event, handleEvent, options);\n }, [ref, event, options, isDisabled]);\n}\n"],"names":[],"version":3,"file":"useEvent.cjs.map"}
@@ -1,3 +1,4 @@
1
+ import {addEvent as $cc3c3666b64debad$export$f531f92e2a15358f} from "./domHelpers.js";
1
2
  import {useEffectEvent as $85567ef950781b7d$export$7f54fc3180508a52} from "./useEffectEvent.js";
2
3
  import {useEffect as $1eh8F$useEffect} from "react";
3
4
 
@@ -13,16 +14,13 @@ import {useEffect as $1eh8F$useEffect} from "react";
13
14
  * governing permissions and limitations under the License.
14
15
  */
15
16
 
16
- function $c3cab330536504ec$export$90fc3a17d93f704c(ref, event, handler, options) {
17
- let handleEvent = (0, $85567ef950781b7d$export$7f54fc3180508a52)(handler);
18
- let isDisabled = handler == null;
17
+
18
+ function $c3cab330536504ec$export$90fc3a17d93f704c(ref, event, listener, options) {
19
+ let handleEvent = (0, $85567ef950781b7d$export$7f54fc3180508a52)(listener);
20
+ let isDisabled = listener == null;
19
21
  (0, $1eh8F$useEffect)(()=>{
20
- if (isDisabled || !ref.current) return;
21
- let element = ref.current;
22
- element.addEventListener(event, handleEvent, options);
23
- return ()=>{
24
- element.removeEventListener(event, handleEvent, options);
25
- };
22
+ if (isDisabled || ref.current == null) return;
23
+ return (0, $cc3c3666b64debad$export$f531f92e2a15358f)(ref.current, event, handleEvent, options);
26
24
  }, [
27
25
  ref,
28
26
  event,
@@ -1 +1 @@
1
- {"mappings":";;;AAAA;;;;;;;;;;CAUC;;AAMM,SAAS,0CACd,GAAkC,EAClC,KAAwB,EACxB,OAAqE,EACrE,OAA2C;IAE3C,IAAI,cAAc,CAAA,GAAA,yCAAa,EAAE;IACjC,IAAI,aAAa,WAAW;IAE5B,CAAA,GAAA,gBAAQ,EAAE;QACR,IAAI,cAAc,CAAC,IAAI,OAAO,EAC5B;QAGF,IAAI,UAAU,IAAI,OAAO;QACzB,QAAQ,gBAAgB,CAAC,OAAO,aAA8B;QAC9D,OAAO;YACL,QAAQ,mBAAmB,CAAC,OAAO,aAA8B;QACnE;IACF,GAAG;QAAC;QAAK;QAAO;QAAS;KAAW;AACtC","sources":["packages/react-aria/src/utils/useEvent.ts"],"sourcesContent":["/*\n * Copyright 2021 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 {RefObject} from '@react-types/shared';\nimport {useEffect} from 'react';\nimport {useEffectEvent} from './useEffectEvent';\n\nexport function useEvent<K extends keyof GlobalEventHandlersEventMap>(\n ref: RefObject<EventTarget | null>,\n event: K | (string & {}),\n handler?: (this: Document, ev: GlobalEventHandlersEventMap[K]) => any,\n options?: boolean | AddEventListenerOptions\n): void {\n let handleEvent = useEffectEvent(handler);\n let isDisabled = handler == null;\n\n useEffect(() => {\n if (isDisabled || !ref.current) {\n return;\n }\n\n let element = ref.current;\n element.addEventListener(event, handleEvent as EventListener, options);\n return () => {\n element.removeEventListener(event, handleEvent as EventListener, options);\n };\n }, [ref, event, options, isDisabled]);\n}\n"],"names":[],"version":3,"file":"useEvent.js.map"}
1
+ {"mappings":";;;;AAAA;;;;;;;;;;CAUC;;;AAOM,SAAS,0CACd,GAAwB,EACxB,KAAyC,EACzC,QAAkE,EAClE,OAA2C;IAE3C,IAAI,cAAc,CAAA,GAAA,yCAAa,EAAE;IACjC,IAAI,aAAa,YAAY;IAE7B,CAAA,GAAA,gBAAQ,EAAE;QACR,IAAI,cAAc,IAAI,OAAO,IAAI,MAC/B;QAGF,OAAO,CAAA,GAAA,yCAAO,EAAE,IAAI,OAAO,EAAE,OAAO,aAAa;IACnD,GAAG;QAAC;QAAK;QAAO;QAAS;KAAW;AACtC","sources":["packages/react-aria/src/utils/useEvent.ts"],"sourcesContent":["/*\n * Copyright 2021 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 {addEvent} from './domHelpers';\nimport {EventMapType, RefObject} from '@react-types/shared';\nimport {useEffect} from 'react';\nimport {useEffectEvent} from './useEffectEvent';\n\nexport function useEvent<T extends EventTarget, K extends keyof EventMapType<T>>(\n ref: RefObject<T | null>,\n event: Extract<K, string> | (string & {}),\n listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any,\n options?: boolean | AddEventListenerOptions\n): void {\n let handleEvent = useEffectEvent(listener);\n let isDisabled = listener == null;\n\n useEffect(() => {\n if (isDisabled || ref.current == null) {\n return;\n }\n\n return addEvent(ref.current, event, handleEvent, options);\n }, [ref, event, options, isDisabled]);\n}\n"],"names":[],"version":3,"file":"useEvent.js.map"}
@@ -1,3 +1,4 @@
1
+ import {addEvent as $d447af545b77c9f1$export$f531f92e2a15358f} from "./domHelpers.mjs";
1
2
  import {useEffectEvent as $fe16bffc7a557bf0$export$7f54fc3180508a52} from "./useEffectEvent.mjs";
2
3
  import {useEffect as $jBdOV$useEffect} from "react";
3
4
 
@@ -13,16 +14,13 @@ import {useEffect as $jBdOV$useEffect} from "react";
13
14
  * governing permissions and limitations under the License.
14
15
  */
15
16
 
16
- function $600b3cf69ae46262$export$90fc3a17d93f704c(ref, event, handler, options) {
17
- let handleEvent = (0, $fe16bffc7a557bf0$export$7f54fc3180508a52)(handler);
18
- let isDisabled = handler == null;
17
+
18
+ function $600b3cf69ae46262$export$90fc3a17d93f704c(ref, event, listener, options) {
19
+ let handleEvent = (0, $fe16bffc7a557bf0$export$7f54fc3180508a52)(listener);
20
+ let isDisabled = listener == null;
19
21
  (0, $jBdOV$useEffect)(()=>{
20
- if (isDisabled || !ref.current) return;
21
- let element = ref.current;
22
- element.addEventListener(event, handleEvent, options);
23
- return ()=>{
24
- element.removeEventListener(event, handleEvent, options);
25
- };
22
+ if (isDisabled || ref.current == null) return;
23
+ return (0, $d447af545b77c9f1$export$f531f92e2a15358f)(ref.current, event, handleEvent, options);
26
24
  }, [
27
25
  ref,
28
26
  event,
@@ -1 +1 @@
1
- {"mappings":";;;AAAA;;;;;;;;;;CAUC;;AAMM,SAAS,0CACd,GAAkC,EAClC,KAAwB,EACxB,OAAqE,EACrE,OAA2C;IAE3C,IAAI,cAAc,CAAA,GAAA,yCAAa,EAAE;IACjC,IAAI,aAAa,WAAW;IAE5B,CAAA,GAAA,gBAAQ,EAAE;QACR,IAAI,cAAc,CAAC,IAAI,OAAO,EAC5B;QAGF,IAAI,UAAU,IAAI,OAAO;QACzB,QAAQ,gBAAgB,CAAC,OAAO,aAA8B;QAC9D,OAAO;YACL,QAAQ,mBAAmB,CAAC,OAAO,aAA8B;QACnE;IACF,GAAG;QAAC;QAAK;QAAO;QAAS;KAAW;AACtC","sources":["packages/react-aria/src/utils/useEvent.ts"],"sourcesContent":["/*\n * Copyright 2021 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 {RefObject} from '@react-types/shared';\nimport {useEffect} from 'react';\nimport {useEffectEvent} from './useEffectEvent';\n\nexport function useEvent<K extends keyof GlobalEventHandlersEventMap>(\n ref: RefObject<EventTarget | null>,\n event: K | (string & {}),\n handler?: (this: Document, ev: GlobalEventHandlersEventMap[K]) => any,\n options?: boolean | AddEventListenerOptions\n): void {\n let handleEvent = useEffectEvent(handler);\n let isDisabled = handler == null;\n\n useEffect(() => {\n if (isDisabled || !ref.current) {\n return;\n }\n\n let element = ref.current;\n element.addEventListener(event, handleEvent as EventListener, options);\n return () => {\n element.removeEventListener(event, handleEvent as EventListener, options);\n };\n }, [ref, event, options, isDisabled]);\n}\n"],"names":[],"version":3,"file":"useEvent.mjs.map"}
1
+ {"mappings":";;;;AAAA;;;;;;;;;;CAUC;;;AAOM,SAAS,0CACd,GAAwB,EACxB,KAAyC,EACzC,QAAkE,EAClE,OAA2C;IAE3C,IAAI,cAAc,CAAA,GAAA,yCAAa,EAAE;IACjC,IAAI,aAAa,YAAY;IAE7B,CAAA,GAAA,gBAAQ,EAAE;QACR,IAAI,cAAc,IAAI,OAAO,IAAI,MAC/B;QAGF,OAAO,CAAA,GAAA,yCAAO,EAAE,IAAI,OAAO,EAAE,OAAO,aAAa;IACnD,GAAG;QAAC;QAAK;QAAO;QAAS;KAAW;AACtC","sources":["packages/react-aria/src/utils/useEvent.ts"],"sourcesContent":["/*\n * Copyright 2021 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 {addEvent} from './domHelpers';\nimport {EventMapType, RefObject} from '@react-types/shared';\nimport {useEffect} from 'react';\nimport {useEffectEvent} from './useEffectEvent';\n\nexport function useEvent<T extends EventTarget, K extends keyof EventMapType<T>>(\n ref: RefObject<T | null>,\n event: Extract<K, string> | (string & {}),\n listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any,\n options?: boolean | AddEventListenerOptions\n): void {\n let handleEvent = useEffectEvent(listener);\n let isDisabled = listener == null;\n\n useEffect(() => {\n if (isDisabled || ref.current == null) {\n return;\n }\n\n return addEvent(ref.current, event, handleEvent, options);\n }, [ref, event, options, isDisabled]);\n}\n"],"names":[],"version":3,"file":"useEvent.mjs.map"}
@@ -51,7 +51,7 @@ export { useLocalizedStringFormatter, useLocalizedStringDictionary } from '../sr
51
51
  export { useNumberFormatter } from '../src/i18n/useNumberFormatter';
52
52
  export { useListFormatter } from '../src/i18n/useListFormatter';
53
53
  export { useFocus } from '../src/interactions/useFocus';
54
- export { useFocusVisible } from '../src/interactions/useFocusVisible';
54
+ export { setInteractionModality, useFocusVisible } from '../src/interactions/useFocusVisible';
55
55
  export { useFocusWithin } from '../src/interactions/useFocusWithin';
56
56
  export { useHover } from '../src/interactions/useHover';
57
57
  export { useInteractOutside } from '../src/interactions/useInteractOutside';
@@ -188,7 +188,7 @@ export type { DropOptions, DropResult } from '../src/dnd/useDrop';
188
188
  export type { DroppableCollectionOptions, DroppableCollectionResult } from '../src/dnd/useDroppableCollection';
189
189
  export type { DroppableItemOptions, DroppableItemResult } from '../src/dnd/useDroppableItem';
190
190
  export type { FocusProps, FocusResult } from '../src/interactions/useFocus';
191
- export type { FocusVisibleProps, FocusVisibleResult } from '../src/interactions/useFocusVisible';
191
+ export type { Modality, FocusVisibleProps, FocusVisibleResult } from '../src/interactions/useFocusVisible';
192
192
  export type { FocusWithinProps, FocusWithinResult } from '../src/interactions/useFocusWithin';
193
193
  export type { HoverProps, HoverResult } from '../src/interactions/useHover';
194
194
  export type { InteractOutsideProps } from '../src/interactions/useInteractOutside';
@@ -1 +1 @@
1
- export { addEvent, getOwnerDocument, getOwnerWindow, isShadowRoot } from '../../../src/utils/domHelpers';
1
+ export { addEvent, getOwnerDocument, getOwnerWindow, isDocument, isShadowRoot } from '../../../src/utils/domHelpers';
@@ -1,3 +1,4 @@
1
- export { useFocusVisible } from '../src/interactions/useFocusVisible';
1
+ export { setInteractionModality, useFocusVisible } from '../src/interactions/useFocusVisible';
2
2
  export type { FocusVisibleProps, FocusVisibleResult } from '../src/interactions/useFocusVisible';
3
3
  export type { FocusEvents } from '@react-types/shared';
4
+ export type { Modality } from '../src/interactions/useFocusVisible';
@@ -1,6 +1,6 @@
1
1
  import { AriaLabelingProps, DOMAttributes, FocusableProps } from '@react-types/shared';
2
2
  import { ClipboardEventHandler, HTMLAttributes, RefObject } from 'react';
3
- import { Position, TokenFieldProps, TokenFieldState, TokenFieldValue } from 'react-stately/useTokenFieldState';
3
+ import { Position, SelectedRange, TokenFieldProps, TokenFieldState, TokenFieldValue } from 'react-stately/useTokenFieldState';
4
4
  export interface AriaTokenFieldProps<T extends TokenFieldValue = TokenFieldValue> extends TokenFieldProps<T>, FocusableProps, AriaLabelingProps {
5
5
  /**
6
6
  * The accessibility role of the token field.
@@ -53,5 +53,6 @@ export interface TokenFieldAria {
53
53
  */
54
54
  export declare function useTokenField<T extends TokenFieldValue = TokenFieldValue>(props: AriaTokenFieldProps<T>, state: TokenFieldState, ref: RefObject<HTMLDivElement | null>): TokenFieldAria;
55
55
  export declare function getSelection(container: Element): [Position, Position] | null;
56
- export declare function setTokenFieldSelection(root: Element, start: Position, end: Position, fireEvent?: boolean): void;
56
+ export declare function getSelectedRange(container: Element): SelectedRange | null;
57
+ export declare function setTokenFieldSelection(root: Element, selectedRange: SelectedRange, fireEvent?: boolean): void;
57
58
  export declare function tokenFieldPositionToDOMRange(root: Element, pos: Position): Range;
@@ -1,6 +1,6 @@
1
1
  import type { EventMapType } from '@react-types/shared';
2
- export declare const getOwnerDocument: (target?: EventTarget | null | undefined) => Document;
3
- export declare const getOwnerWindow: (target?: EventTarget | null | undefined) => Window & typeof globalThis;
2
+ export declare const getOwnerDocument: (target?: EventTarget | null) => Document;
3
+ export declare const getOwnerWindow: (target?: EventTarget | null) => Window & typeof globalThis;
4
4
  /**
5
5
  * Type guard that checks if a value is a Node. Verifies the presence and type of the nodeType
6
6
  * property.
@@ -20,3 +20,7 @@ export declare function isShadowRoot(value: unknown): value is ShadowRoot;
20
20
  * Attaches an event listener on target(s) and returns a cleanup function.
21
21
  */
22
22
  export declare function addEvent<T extends EventTarget, K extends keyof EventMapType<Exclude<T, null>>>(target: T | EventTarget[] | null, event: Extract<K, string> | (string & {}), listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any, options?: boolean | AddEventListenerOptions): () => void;
23
+ /**
24
+ * Sets a CSS property on an element and returns a cleanup function.
25
+ */
26
+ export declare function setStyle(target: HTMLElement | HTMLElement[] | null, property: string, value: string, priority?: string): () => void;
@@ -0,0 +1,7 @@
1
+ declare global {
2
+ interface Window {
3
+ __webpack_nonce__?: string;
4
+ }
5
+ var __webpack_nonce__: string | undefined;
6
+ }
7
+ export declare function getMetaValue(key: string, doc?: Document): string | undefined;
@@ -1,2 +1,2 @@
1
- import { RefObject } from '@react-types/shared';
2
- export declare function useEvent<K extends keyof GlobalEventHandlersEventMap>(ref: RefObject<EventTarget | null>, event: K | (string & {}), handler?: (this: Document, ev: GlobalEventHandlersEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
1
+ import { EventMapType, RefObject } from '@react-types/shared';
2
+ export declare function useEvent<T extends EventTarget, K extends keyof EventMapType<T>>(ref: RefObject<T | null>, event: Extract<K, string> | (string & {}), listener?: (this: T, ev: EventMapType<Exclude<T, null>>[K]) => any, options?: boolean | AddEventListenerOptions): void;
@@ -1,6 +1,6 @@
1
1
  import { Collection, Key, RefObject } from '@react-types/shared';
2
2
  import { Layout, ReusableView } from 'react-stately/useVirtualizerState';
3
- import React, { HTMLAttributes, ReactElement } from 'react';
3
+ import { HTMLAttributes, ReactElement } from 'react';
4
4
  type RenderWrapper<T extends object, V> = (parent: ReusableView<T, V> | null, reusableView: ReusableView<T, V>, children: ReusableView<T, V>[], renderChildren: (views: ReusableView<T, V>[]) => ReactElement[]) => ReactElement | null;
5
5
  interface VirtualizerProps<T extends object, V, O> extends Omit<HTMLAttributes<HTMLElement>, 'children' | 'onScroll'> {
6
6
  children: (type: string, content: T) => V;
@@ -15,6 +15,6 @@ interface VirtualizerProps<T extends object, V, O> extends Omit<HTMLAttributes<H
15
15
  onScroll?: (e: Event) => void;
16
16
  }
17
17
  export declare const Virtualizer: <T extends object, V, O>(props: VirtualizerProps<T, V, O> & {
18
- ref?: RefObject<HTMLDivElement | null> | undefined;
19
- }) => ReactElement<unknown, string | React.JSXElementConstructor<any>>;
18
+ ref?: RefObject<HTMLDivElement | null>;
19
+ }) => ReactElement;
20
20
  export {};