react-aria-components 1.12.2 → 1.14.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 (370) hide show
  1. package/dist/Autocomplete.main.js +3 -3
  2. package/dist/Autocomplete.main.js.map +1 -1
  3. package/dist/Autocomplete.mjs +3 -3
  4. package/dist/Autocomplete.module.js +3 -3
  5. package/dist/Autocomplete.module.js.map +1 -1
  6. package/dist/Breadcrumbs.main.js +5 -3
  7. package/dist/Breadcrumbs.main.js.map +1 -1
  8. package/dist/Breadcrumbs.mjs +5 -3
  9. package/dist/Breadcrumbs.module.js +5 -3
  10. package/dist/Breadcrumbs.module.js.map +1 -1
  11. package/dist/Button.main.js +5 -11
  12. package/dist/Button.main.js.map +1 -1
  13. package/dist/Button.mjs +5 -11
  14. package/dist/Button.module.js +5 -11
  15. package/dist/Button.module.js.map +1 -1
  16. package/dist/Calendar.main.js +2 -2
  17. package/dist/Calendar.main.js.map +1 -1
  18. package/dist/Calendar.mjs +2 -2
  19. package/dist/Calendar.module.js +2 -2
  20. package/dist/Calendar.module.js.map +1 -1
  21. package/dist/Checkbox.main.js.map +1 -1
  22. package/dist/Checkbox.module.js.map +1 -1
  23. package/dist/Collection.main.js +1 -1
  24. package/dist/Collection.main.js.map +1 -1
  25. package/dist/Collection.mjs +1 -1
  26. package/dist/Collection.module.js +1 -1
  27. package/dist/Collection.module.js.map +1 -1
  28. package/dist/ColorArea.main.js +1 -1
  29. package/dist/ColorArea.main.js.map +1 -1
  30. package/dist/ColorArea.mjs +1 -1
  31. package/dist/ColorArea.module.js +1 -1
  32. package/dist/ColorArea.module.js.map +1 -1
  33. package/dist/ColorField.main.js +1 -1
  34. package/dist/ColorField.main.js.map +1 -1
  35. package/dist/ColorField.mjs +1 -1
  36. package/dist/ColorField.module.js +1 -1
  37. package/dist/ColorField.module.js.map +1 -1
  38. package/dist/ColorPicker.main.js +1 -1
  39. package/dist/ColorPicker.main.js.map +1 -1
  40. package/dist/ColorPicker.mjs +1 -1
  41. package/dist/ColorPicker.module.js +1 -1
  42. package/dist/ColorPicker.module.js.map +1 -1
  43. package/dist/ColorSlider.main.js +1 -1
  44. package/dist/ColorSlider.main.js.map +1 -1
  45. package/dist/ColorSlider.mjs +1 -1
  46. package/dist/ColorSlider.module.js +1 -1
  47. package/dist/ColorSlider.module.js.map +1 -1
  48. package/dist/ColorSwatch.main.js.map +1 -1
  49. package/dist/ColorSwatch.module.js.map +1 -1
  50. package/dist/ColorSwatchPicker.main.js +1 -1
  51. package/dist/ColorSwatchPicker.main.js.map +1 -1
  52. package/dist/ColorSwatchPicker.mjs +1 -1
  53. package/dist/ColorSwatchPicker.module.js +1 -1
  54. package/dist/ColorSwatchPicker.module.js.map +1 -1
  55. package/dist/ColorThumb.main.js.map +1 -1
  56. package/dist/ColorThumb.module.js.map +1 -1
  57. package/dist/ColorWheel.main.js +1 -1
  58. package/dist/ColorWheel.main.js.map +1 -1
  59. package/dist/ColorWheel.mjs +1 -1
  60. package/dist/ColorWheel.module.js +1 -1
  61. package/dist/ColorWheel.module.js.map +1 -1
  62. package/dist/ComboBox.main.js.map +1 -1
  63. package/dist/ComboBox.module.js.map +1 -1
  64. package/dist/DateField.main.js +15 -9
  65. package/dist/DateField.main.js.map +1 -1
  66. package/dist/DateField.mjs +15 -9
  67. package/dist/DateField.module.js +15 -9
  68. package/dist/DateField.module.js.map +1 -1
  69. package/dist/DatePicker.main.js +6 -2
  70. package/dist/DatePicker.main.js.map +1 -1
  71. package/dist/DatePicker.mjs +6 -2
  72. package/dist/DatePicker.module.js +6 -2
  73. package/dist/DatePicker.module.js.map +1 -1
  74. package/dist/Dialog.main.js.map +1 -1
  75. package/dist/Dialog.module.js.map +1 -1
  76. package/dist/Disclosure.main.js +2 -1
  77. package/dist/Disclosure.main.js.map +1 -1
  78. package/dist/Disclosure.mjs +2 -1
  79. package/dist/Disclosure.module.js +2 -1
  80. package/dist/Disclosure.module.js.map +1 -1
  81. package/dist/DragAndDrop.main.js.map +1 -1
  82. package/dist/DragAndDrop.module.js.map +1 -1
  83. package/dist/DropZone.main.js.map +1 -1
  84. package/dist/DropZone.module.js.map +1 -1
  85. package/dist/FieldError.main.js.map +1 -1
  86. package/dist/FieldError.module.js.map +1 -1
  87. package/dist/FileTrigger.main.js +1 -0
  88. package/dist/FileTrigger.main.js.map +1 -1
  89. package/dist/FileTrigger.mjs +1 -0
  90. package/dist/FileTrigger.module.js +1 -0
  91. package/dist/FileTrigger.module.js.map +1 -1
  92. package/dist/Form.main.js.map +1 -1
  93. package/dist/Form.module.js.map +1 -1
  94. package/dist/GridList.main.js +25 -22
  95. package/dist/GridList.main.js.map +1 -1
  96. package/dist/GridList.mjs +26 -24
  97. package/dist/GridList.module.js +26 -24
  98. package/dist/GridList.module.js.map +1 -1
  99. package/dist/Group.main.js +5 -4
  100. package/dist/Group.main.js.map +1 -1
  101. package/dist/Group.mjs +5 -4
  102. package/dist/Group.module.js +5 -4
  103. package/dist/Group.module.js.map +1 -1
  104. package/dist/HiddenDateInput.main.js +5 -3
  105. package/dist/HiddenDateInput.main.js.map +1 -1
  106. package/dist/HiddenDateInput.mjs +5 -3
  107. package/dist/HiddenDateInput.module.js +5 -3
  108. package/dist/HiddenDateInput.module.js.map +1 -1
  109. package/dist/Input.main.js +4 -1
  110. package/dist/Input.main.js.map +1 -1
  111. package/dist/Input.mjs +4 -1
  112. package/dist/Input.module.js +4 -1
  113. package/dist/Input.module.js.map +1 -1
  114. package/dist/Link.main.js.map +1 -1
  115. package/dist/Link.module.js.map +1 -1
  116. package/dist/ListBox.main.js +20 -7
  117. package/dist/ListBox.main.js.map +1 -1
  118. package/dist/ListBox.mjs +21 -8
  119. package/dist/ListBox.module.js +21 -8
  120. package/dist/ListBox.module.js.map +1 -1
  121. package/dist/Menu.main.js +17 -7
  122. package/dist/Menu.main.js.map +1 -1
  123. package/dist/Menu.mjs +17 -7
  124. package/dist/Menu.module.js +17 -7
  125. package/dist/Menu.module.js.map +1 -1
  126. package/dist/Meter.main.js.map +1 -1
  127. package/dist/Meter.module.js.map +1 -1
  128. package/dist/Modal.main.js +9 -1
  129. package/dist/Modal.main.js.map +1 -1
  130. package/dist/Modal.mjs +10 -2
  131. package/dist/Modal.module.js +10 -2
  132. package/dist/Modal.module.js.map +1 -1
  133. package/dist/NumberField.main.js +2 -1
  134. package/dist/NumberField.main.js.map +1 -1
  135. package/dist/NumberField.mjs +2 -1
  136. package/dist/NumberField.module.js +2 -1
  137. package/dist/NumberField.module.js.map +1 -1
  138. package/dist/OverlayArrow.main.js.map +1 -1
  139. package/dist/OverlayArrow.module.js.map +1 -1
  140. package/dist/Popover.main.js.map +1 -1
  141. package/dist/Popover.module.js.map +1 -1
  142. package/dist/ProgressBar.main.js.map +1 -1
  143. package/dist/ProgressBar.module.js.map +1 -1
  144. package/dist/RSPContexts.main.js +4 -0
  145. package/dist/RSPContexts.main.js.map +1 -1
  146. package/dist/RSPContexts.mjs +3 -1
  147. package/dist/RSPContexts.module.js +3 -1
  148. package/dist/RSPContexts.module.js.map +1 -1
  149. package/dist/RadioGroup.main.js +10 -2
  150. package/dist/RadioGroup.main.js.map +1 -1
  151. package/dist/RadioGroup.mjs +10 -2
  152. package/dist/RadioGroup.module.js +10 -2
  153. package/dist/RadioGroup.module.js.map +1 -1
  154. package/dist/SearchField.main.js +7 -3
  155. package/dist/SearchField.main.js.map +1 -1
  156. package/dist/SearchField.mjs +7 -3
  157. package/dist/SearchField.module.js +7 -3
  158. package/dist/SearchField.module.js.map +1 -1
  159. package/dist/Select.main.js +62 -22
  160. package/dist/Select.main.js.map +1 -1
  161. package/dist/Select.mjs +65 -25
  162. package/dist/Select.module.js +65 -25
  163. package/dist/Select.module.js.map +1 -1
  164. package/dist/SelectionIndicator.main.js +45 -0
  165. package/dist/SelectionIndicator.main.js.map +1 -0
  166. package/dist/SelectionIndicator.mjs +35 -0
  167. package/dist/SelectionIndicator.module.js +35 -0
  168. package/dist/SelectionIndicator.module.js.map +1 -0
  169. package/dist/Separator.main.js.map +1 -1
  170. package/dist/Separator.module.js.map +1 -1
  171. package/dist/SharedElementTransition.main.js +139 -0
  172. package/dist/SharedElementTransition.main.js.map +1 -0
  173. package/dist/SharedElementTransition.mjs +129 -0
  174. package/dist/SharedElementTransition.module.js +129 -0
  175. package/dist/SharedElementTransition.module.js.map +1 -0
  176. package/dist/Slider.main.js.map +1 -1
  177. package/dist/Slider.module.js.map +1 -1
  178. package/dist/Switch.main.js.map +1 -1
  179. package/dist/Switch.module.js.map +1 -1
  180. package/dist/Table.main.js +142 -53
  181. package/dist/Table.main.js.map +1 -1
  182. package/dist/Table.mjs +143 -54
  183. package/dist/Table.module.js +143 -54
  184. package/dist/Table.module.js.map +1 -1
  185. package/dist/Tabs.main.js +86 -9
  186. package/dist/Tabs.main.js.map +1 -1
  187. package/dist/Tabs.mjs +88 -12
  188. package/dist/Tabs.module.js +88 -12
  189. package/dist/Tabs.module.js.map +1 -1
  190. package/dist/TagGroup.main.js +29 -17
  191. package/dist/TagGroup.main.js.map +1 -1
  192. package/dist/TagGroup.mjs +29 -17
  193. package/dist/TagGroup.module.js +29 -17
  194. package/dist/TagGroup.module.js.map +1 -1
  195. package/dist/TextArea.main.js.map +1 -1
  196. package/dist/TextArea.module.js.map +1 -1
  197. package/dist/TextField.main.js +2 -2
  198. package/dist/TextField.main.js.map +1 -1
  199. package/dist/TextField.mjs +2 -2
  200. package/dist/TextField.module.js +2 -2
  201. package/dist/TextField.module.js.map +1 -1
  202. package/dist/Toast.main.js.map +1 -1
  203. package/dist/Toast.module.js.map +1 -1
  204. package/dist/ToggleButton.main.js +7 -1
  205. package/dist/ToggleButton.main.js.map +1 -1
  206. package/dist/ToggleButton.mjs +7 -1
  207. package/dist/ToggleButton.module.js +7 -1
  208. package/dist/ToggleButton.module.js.map +1 -1
  209. package/dist/ToggleButtonGroup.main.js +4 -1
  210. package/dist/ToggleButtonGroup.main.js.map +1 -1
  211. package/dist/ToggleButtonGroup.mjs +4 -1
  212. package/dist/ToggleButtonGroup.module.js +4 -1
  213. package/dist/ToggleButtonGroup.module.js.map +1 -1
  214. package/dist/Toolbar.main.js.map +1 -1
  215. package/dist/Toolbar.module.js.map +1 -1
  216. package/dist/Tooltip.main.js.map +1 -1
  217. package/dist/Tooltip.module.js.map +1 -1
  218. package/dist/Tree.main.js +16 -4
  219. package/dist/Tree.main.js.map +1 -1
  220. package/dist/Tree.mjs +16 -4
  221. package/dist/Tree.module.js +16 -4
  222. package/dist/Tree.module.js.map +1 -1
  223. package/dist/import.mjs +13 -7
  224. package/dist/main.js +23 -3
  225. package/dist/main.js.map +1 -1
  226. package/dist/module.js +13 -7
  227. package/dist/module.js.map +1 -1
  228. package/dist/types.d.ts +663 -58
  229. package/dist/types.d.ts.map +1 -1
  230. package/dist/utils.main.js +0 -1
  231. package/dist/utils.main.js.map +1 -1
  232. package/dist/utils.mjs +0 -1
  233. package/dist/utils.module.js +0 -1
  234. package/dist/utils.module.js.map +1 -1
  235. package/i18n/ar-AE.js +1 -1
  236. package/i18n/ar-AE.mjs +1 -1
  237. package/i18n/bg-BG.js +1 -1
  238. package/i18n/bg-BG.mjs +1 -1
  239. package/i18n/cs-CZ.js +1 -1
  240. package/i18n/cs-CZ.mjs +1 -1
  241. package/i18n/da-DK.js +1 -1
  242. package/i18n/da-DK.mjs +1 -1
  243. package/i18n/de-DE.js +1 -1
  244. package/i18n/de-DE.mjs +1 -1
  245. package/i18n/el-GR.js +1 -1
  246. package/i18n/el-GR.mjs +1 -1
  247. package/i18n/en-US.js +1 -1
  248. package/i18n/en-US.mjs +1 -1
  249. package/i18n/es-ES.js +1 -1
  250. package/i18n/es-ES.mjs +1 -1
  251. package/i18n/et-EE.js +1 -1
  252. package/i18n/et-EE.mjs +1 -1
  253. package/i18n/fi-FI.js +1 -1
  254. package/i18n/fi-FI.mjs +1 -1
  255. package/i18n/fr-FR.js +1 -1
  256. package/i18n/fr-FR.mjs +1 -1
  257. package/i18n/he-IL.js +1 -1
  258. package/i18n/he-IL.mjs +1 -1
  259. package/i18n/hr-HR.js +1 -1
  260. package/i18n/hr-HR.mjs +1 -1
  261. package/i18n/hu-HU.js +1 -1
  262. package/i18n/hu-HU.mjs +1 -1
  263. package/i18n/index.js +67 -67
  264. package/i18n/index.mjs +67 -67
  265. package/i18n/it-IT.js +1 -1
  266. package/i18n/it-IT.mjs +1 -1
  267. package/i18n/ja-JP.js +1 -1
  268. package/i18n/ja-JP.mjs +1 -1
  269. package/i18n/ko-KR.js +1 -1
  270. package/i18n/ko-KR.mjs +1 -1
  271. package/i18n/lt-LT.js +1 -1
  272. package/i18n/lt-LT.mjs +1 -1
  273. package/i18n/lv-LV.js +1 -1
  274. package/i18n/lv-LV.mjs +1 -1
  275. package/i18n/nb-NO.js +1 -1
  276. package/i18n/nb-NO.mjs +1 -1
  277. package/i18n/nl-NL.js +1 -1
  278. package/i18n/nl-NL.mjs +1 -1
  279. package/i18n/pl-PL.js +1 -1
  280. package/i18n/pl-PL.mjs +1 -1
  281. package/i18n/pt-BR.js +1 -1
  282. package/i18n/pt-BR.mjs +1 -1
  283. package/i18n/pt-PT.js +1 -1
  284. package/i18n/pt-PT.mjs +1 -1
  285. package/i18n/ro-RO.js +1 -1
  286. package/i18n/ro-RO.mjs +1 -1
  287. package/i18n/ru-RU.js +1 -1
  288. package/i18n/ru-RU.mjs +1 -1
  289. package/i18n/sk-SK.js +1 -1
  290. package/i18n/sk-SK.mjs +1 -1
  291. package/i18n/sl-SI.js +1 -1
  292. package/i18n/sl-SI.mjs +1 -1
  293. package/i18n/sr-SP.js +1 -1
  294. package/i18n/sr-SP.mjs +1 -1
  295. package/i18n/sv-SE.js +1 -1
  296. package/i18n/sv-SE.mjs +1 -1
  297. package/i18n/tr-TR.js +1 -1
  298. package/i18n/tr-TR.mjs +1 -1
  299. package/i18n/uk-UA.js +1 -1
  300. package/i18n/uk-UA.mjs +1 -1
  301. package/i18n/zh-CN.js +1 -1
  302. package/i18n/zh-CN.mjs +1 -1
  303. package/i18n/zh-TW.js +1 -1
  304. package/i18n/zh-TW.mjs +1 -1
  305. package/package.json +25 -25
  306. package/src/Autocomplete.tsx +2 -2
  307. package/src/Breadcrumbs.tsx +25 -6
  308. package/src/Button.tsx +15 -11
  309. package/src/Calendar.tsx +51 -6
  310. package/src/Checkbox.tsx +25 -2
  311. package/src/Collection.tsx +1 -1
  312. package/src/ColorArea.tsx +15 -2
  313. package/src/ColorField.tsx +16 -1
  314. package/src/ColorPicker.tsx +5 -2
  315. package/src/ColorSlider.tsx +16 -2
  316. package/src/ColorSwatch.tsx +15 -2
  317. package/src/ColorSwatchPicker.tsx +18 -1
  318. package/src/ColorThumb.tsx +8 -2
  319. package/src/ColorWheel.tsx +24 -3
  320. package/src/ComboBox.tsx +18 -1
  321. package/src/DateField.tsx +60 -16
  322. package/src/DatePicker.tsx +38 -5
  323. package/src/Dialog.tsx +5 -0
  324. package/src/Disclosure.tsx +30 -5
  325. package/src/DragAndDrop.tsx +8 -2
  326. package/src/DropZone.tsx +16 -2
  327. package/src/FieldError.tsx +8 -2
  328. package/src/FileTrigger.tsx +1 -0
  329. package/src/Form.tsx +5 -0
  330. package/src/GridList.tsx +66 -35
  331. package/src/Group.tsx +32 -18
  332. package/src/HiddenDateInput.tsx +6 -4
  333. package/src/Input.tsx +23 -3
  334. package/src/Link.tsx +15 -2
  335. package/src/ListBox.tsx +58 -14
  336. package/src/Menu.tsx +41 -8
  337. package/src/Meter.tsx +16 -2
  338. package/src/Modal.tsx +30 -3
  339. package/src/NumberField.tsx +21 -3
  340. package/src/OverlayArrow.tsx +14 -2
  341. package/src/Popover.tsx +13 -1
  342. package/src/ProgressBar.tsx +17 -3
  343. package/src/RSPContexts.ts +19 -0
  344. package/src/RadioGroup.tsx +33 -4
  345. package/src/SearchField.tsx +36 -4
  346. package/src/Select.tsx +100 -36
  347. package/src/SelectionIndicator.tsx +46 -0
  348. package/src/Separator.tsx +10 -1
  349. package/src/SharedElementTransition.tsx +185 -0
  350. package/src/Slider.tsx +35 -3
  351. package/src/Switch.tsx +18 -5
  352. package/src/Table.tsx +204 -83
  353. package/src/Tabs.tsx +158 -15
  354. package/src/TagGroup.tsx +60 -26
  355. package/src/TextArea.tsx +14 -2
  356. package/src/TextField.tsx +20 -2
  357. package/src/Toast.tsx +22 -2
  358. package/src/ToggleButton.tsx +19 -2
  359. package/src/ToggleButtonGroup.tsx +26 -4
  360. package/src/Toolbar.tsx +13 -1
  361. package/src/Tooltip.tsx +13 -1
  362. package/src/Tree.tsx +76 -40
  363. package/src/index.ts +17 -10
  364. package/src/utils.tsx +2 -3
  365. package/dist/context.main.js +0 -25
  366. package/dist/context.main.js.map +0 -1
  367. package/dist/context.mjs +0 -19
  368. package/dist/context.module.js +0 -19
  369. package/dist/context.module.js.map +0 -1
  370. package/src/context.tsx +0 -34
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;;;;;;AAyEM,MAAM,0DAAkB,CAAA,GAAA,oBAAY,EAAoD;AAMxF,MAAM,4CAAyB,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,SAA2B,KAAuB,EAAE,GAAiC;IACjK,+FAA+F;IAC/F,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAE3C,qBACE,gCAAC,CAAA,GAAA,wBAAgB;QAAE,uBAAS,gCAAC,CAAA,GAAA,iBAAS,GAAM;OACzC,CAAA,2BAAc,gCAAC;YAAc,OAAO;YAAO,YAAY;YAAY,aAAa;;AAGvF;AAQA,SAAS,oCAAgC,SAAC,KAAK,cAAE,UAAU,EAAE,aAAa,GAAG,EAAwB;IACnG,+HAA+H;IAC/H,2FAA2F;IAC3F,IAAI;IACJ,CAAC,aAAa,GAAG,CAAA,GAAA,yCAAc,EAAE,CAAC,GAAG,MAAM,CAAA,GAAA,yCAA0B;IACrE,IAAI,UAAC,MAAM,EAAE,GAAG,iBAAgB,GAAG;IACnC,6DAA6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EAAE;QACjE,cAAc,CAAA,mBAAA,KAAK,CAAC,aAAa,cAAnB,8BAAA,mBAAuB;IACvC,GAAG,OAAO;IACV,IAAI,cAAc,CAAA,GAAA,uCAAa,EAAE;QAC/B,kBAAkB;QAClB,WAAW,MAAM,SAAS;QAC1B,OAAO,MAAM,KAAK;QAClB,QAAQ,CAAC;IACX;IAEA,IAAI,WAAW,CAAA,GAAA,qBAAa,EAAE,OAAc;QAAC,QAAQ;IAAI;IACzD,OAAO,SAAS,EAAE;IAElB,qBACE,gCAAC;QACE,GAAG,CAAA,GAAA,iBAAS,EAAE,UAAU,aAAa,cAAc;QACpD,KAAK;qBACL,gCAAC,CAAA,GAAA,yCAAO;QACN,QAAQ;YACN;gBAAC,CAAA,GAAA,yCAAY;gBAAG;oBAAC,GAAG,QAAQ;oBAAE,KAAK;gBAAU;aAAE;YAC/C;gBAAC;gBAAuB;oBAAC,GAAG,cAAc;gBAAA;aAAE;SAC7C;qBACD,gCAAC;QACC,YAAY,MAAM,UAAU;QAC5B,QAAQ;;AAIlB;AAEA,MAAM,4DAAwB,CAAA,GAAA,oBAAY,EAAsC;AAEzE,MAAM,4CAAiB,WAAW,GAAG,CAAA,GAAA,0BAAkB,EAAE,CAAA,GAAA,iBAAS,GAAG,SAAS,OAAO,KAAkC,EAAE,GAA8B;IAC5J,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK,CAAA,GAAA,yCAAY;IACvD,IAAI,iBAAiB,CAAA,GAAA,iBAAS,EAAE;IAEhC,qBACE,gCAAC;QAAO,WAAU;QAA4B,KAAK;QAAM,GAAG,KAAK;qBAC/D,gCAAC;QAAK,GAAG,cAAc;QAAE,OAAO;YAAC,SAAS;QAAU;OACjD,MAAM,QAAQ;AAIvB","sources":["packages/react-aria-components/src/GridList.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 */\nimport {AriaGridListProps, DraggableItemResult, DragPreviewRenderer, DropIndicatorAria, DroppableCollectionResult, FocusScope, ListKeyboardDelegate, mergeProps, useCollator, useFocusRing, useGridList, useGridListItem, useGridListSection, useGridListSelectionCheckbox, useHover, useLocale, useVisuallyHidden} from 'react-aria';\nimport {ButtonContext} from './Button';\nimport {CheckboxContext} from './RSPContexts';\nimport {Collection, CollectionBuilder, createBranchComponent, createLeafComponent, HeaderNode, ItemNode, LoaderNode, SectionNode} from '@react-aria/collections';\nimport {CollectionProps, CollectionRendererContext, DefaultCollectionRenderer, ItemRenderProps, SectionProps} from './Collection';\nimport {ContextValue, DEFAULT_SLOT, Provider, RenderProps, SlotProps, StyleProps, StyleRenderProps, useContextProps, useRenderProps} from './utils';\nimport {DragAndDropContext, DropIndicatorContext, DropIndicatorProps, useDndPersistedKeys, useRenderDropIndicator} from './DragAndDrop';\nimport {DragAndDropHooks} from './useDragAndDrop';\nimport {DraggableCollectionState, DroppableCollectionState, Collection as ICollection, ListState, Node, SelectionBehavior, UNSTABLE_useFilteredListState, useListState} from 'react-stately';\nimport {FieldInputContext, SelectableCollectionContext} from './context';\nimport {filterDOMProps, inertValue, LoadMoreSentinelProps, useLoadMoreSentinel, useObjectRef} from '@react-aria/utils';\nimport {forwardRefType, GlobalDOMAttributes, HoverEvents, Key, LinkDOMProps, PressEvents, RefObject} from '@react-types/shared';\nimport {HeaderContext} from './Header';\nimport {ListStateContext} from './ListBox';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes, JSX, ReactNode, useContext, useEffect, useMemo, useRef} from 'react';\nimport {TextContext} from './Text';\n\nexport interface GridListRenderProps {\n /**\n * Whether the list has no items and should display its empty state.\n * @selector [data-empty]\n */\n isEmpty: boolean,\n /**\n * Whether the grid list is currently focused.\n * @selector [data-focused]\n */\n isFocused: boolean,\n /**\n * Whether the grid list is currently keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the grid list is currently the active drop target.\n * @selector [data-drop-target]\n */\n isDropTarget: boolean,\n /**\n * Whether the items are arranged in a stack or grid.\n * @selector [data-layout=\"stack | grid\"]\n */\n layout: 'stack' | 'grid',\n /**\n * State of the grid list.\n */\n state: ListState<unknown>\n}\n\nexport interface GridListProps<T> extends Omit<AriaGridListProps<T>, 'children'>, CollectionProps<T>, StyleRenderProps<GridListRenderProps>, SlotProps, GlobalDOMAttributes<HTMLDivElement> {\n /**\n * Whether typeahead navigation is disabled.\n * @default false\n */\n disallowTypeAhead?: boolean,\n /**\n * How multiple selection should behave in the collection.\n * @default \"toggle\"\n */\n selectionBehavior?: SelectionBehavior,\n /** The drag and drop hooks returned by `useDragAndDrop` used to enable drag and drop behavior for the GridList. */\n dragAndDropHooks?: DragAndDropHooks<NoInfer<T>>,\n /** Provides content to display when there are no items in the list. */\n renderEmptyState?: (props: GridListRenderProps) => ReactNode,\n /**\n * Whether the items are arranged in a stack or grid.\n * @default 'stack'\n */\n layout?: 'stack' | 'grid'\n}\n\n\nexport const GridListContext = createContext<ContextValue<GridListProps<any>, HTMLDivElement>>(null);\n\n/**\n * A grid list displays a list of interactive items, with support for keyboard navigation,\n * single or multiple selection, and row actions.\n */\nexport const GridList = /*#__PURE__*/ (forwardRef as forwardRefType)(function GridList<T extends object>(props: GridListProps<T>, ref: ForwardedRef<HTMLDivElement>) {\n // Render the portal first so that we have the collection by the time we render the DOM in SSR.\n [props, ref] = useContextProps(props, ref, GridListContext);\n\n return (\n <CollectionBuilder content={<Collection {...props} />}>\n {collection => <GridListInner props={props} collection={collection} gridListRef={ref} />}\n </CollectionBuilder>\n );\n});\n\ninterface GridListInnerProps<T extends object> {\n props: GridListProps<T>,\n collection: ICollection<Node<object>>,\n gridListRef: RefObject<HTMLDivElement | null>\n}\n\nfunction GridListInner<T extends object>({props, collection, gridListRef: ref}: GridListInnerProps<T>) {\n // TODO: for now, don't grab collection ref and collectionProps from the autocomplete, rely on the user tabbing to the gridlist\n // figure out if we want to support virtual focus for grids when wrapped in an autocomplete\n let contextProps;\n [contextProps] = useContextProps({}, null, SelectableCollectionContext);\n let {filter, ...collectionProps} = contextProps;\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {shouldUseVirtualFocus, disallowTypeAhead, ...DOMCollectionProps} = collectionProps || {};\n let {dragAndDropHooks, keyboardNavigationBehavior = 'arrow', layout = 'stack'} = props;\n let {CollectionRoot, isVirtualized, layoutDelegate, dropTargetDelegate: ctxDropTargetDelegate} = useContext(CollectionRendererContext);\n let gridlistState = useListState({\n ...props,\n collection,\n children: undefined,\n layoutDelegate\n });\n\n let filteredState = UNSTABLE_useFilteredListState(gridlistState, filter);\n let collator = useCollator({usage: 'search', sensitivity: 'base'});\n let {disabledBehavior, disabledKeys} = filteredState.selectionManager;\n let {direction} = useLocale();\n let keyboardDelegate = useMemo(() => (\n new ListKeyboardDelegate({\n collection: filteredState.collection,\n collator,\n ref,\n disabledKeys,\n disabledBehavior,\n layoutDelegate,\n layout,\n direction\n })\n ), [filteredState.collection, ref, layout, disabledKeys, disabledBehavior, layoutDelegate, collator, direction]);\n\n let {gridProps} = useGridList({\n ...props,\n ...DOMCollectionProps,\n keyboardDelegate,\n // Only tab navigation is supported in grid layout.\n keyboardNavigationBehavior: layout === 'grid' ? 'tab' : keyboardNavigationBehavior,\n isVirtualized,\n shouldSelectOnPressUp: props.shouldSelectOnPressUp\n }, filteredState, ref);\n\n let selectionManager = filteredState.selectionManager;\n let isListDraggable = !!dragAndDropHooks?.useDraggableCollectionState;\n let isListDroppable = !!dragAndDropHooks?.useDroppableCollectionState;\n let dragHooksProvided = useRef(isListDraggable);\n let dropHooksProvided = useRef(isListDroppable);\n useEffect(() => {\n if (process.env.NODE_ENV === 'production') {\n return;\n }\n if (dragHooksProvided.current !== isListDraggable) {\n console.warn('Drag hooks were provided during one render, but not another. This should be avoided as it may produce unexpected behavior.');\n }\n if (dropHooksProvided.current !== isListDroppable) {\n console.warn('Drop hooks were provided during one render, but not another. This should be avoided as it may produce unexpected behavior.');\n }\n }, [isListDraggable, isListDroppable]);\n\n let dragState: DraggableCollectionState | undefined = undefined;\n let dropState: DroppableCollectionState | undefined = undefined;\n let droppableCollection: DroppableCollectionResult | undefined = undefined;\n let isRootDropTarget = false;\n let dragPreview: JSX.Element | null = null;\n let preview = useRef<DragPreviewRenderer>(null);\n\n if (isListDraggable && dragAndDropHooks) {\n dragState = dragAndDropHooks.useDraggableCollectionState!({\n collection: filteredState.collection,\n selectionManager,\n preview: dragAndDropHooks.renderDragPreview ? preview : undefined\n });\n dragAndDropHooks.useDraggableCollection!({}, dragState, ref);\n\n let DragPreview = dragAndDropHooks.DragPreview!;\n dragPreview = dragAndDropHooks.renderDragPreview\n ? <DragPreview ref={preview}>{dragAndDropHooks.renderDragPreview}</DragPreview>\n : null;\n }\n\n if (isListDroppable && dragAndDropHooks) {\n dropState = dragAndDropHooks.useDroppableCollectionState!({\n collection: filteredState.collection,\n selectionManager\n });\n\n let keyboardDelegate = new ListKeyboardDelegate({\n collection: filteredState.collection,\n disabledKeys: selectionManager.disabledKeys,\n disabledBehavior: selectionManager.disabledBehavior,\n ref\n });\n let dropTargetDelegate = dragAndDropHooks.dropTargetDelegate || ctxDropTargetDelegate || new dragAndDropHooks.ListDropTargetDelegate(collection, ref, {layout, direction});\n droppableCollection = dragAndDropHooks.useDroppableCollection!({\n keyboardDelegate,\n dropTargetDelegate\n }, dropState, ref);\n\n isRootDropTarget = dropState.isDropTarget({type: 'root'});\n }\n\n let {focusProps, isFocused, isFocusVisible} = useFocusRing();\n let isEmpty = filteredState.collection.size === 0;\n let renderValues = {\n isDropTarget: isRootDropTarget,\n isEmpty,\n isFocused,\n isFocusVisible,\n layout,\n state: filteredState\n };\n let renderProps = useRenderProps({\n className: props.className,\n style: props.style,\n defaultClassName: 'react-aria-GridList',\n values: renderValues\n });\n\n let emptyState: ReactNode = null;\n let emptyStatePropOverrides: HTMLAttributes<HTMLElement> | null = null;\n\n if (isEmpty && props.renderEmptyState) {\n let content = props.renderEmptyState(renderValues);\n emptyState = (\n <div role=\"row\" aria-rowindex={1} style={{display: 'contents'}}>\n <div role=\"gridcell\" style={{display: 'contents'}}>\n {content}\n </div>\n </div>\n );\n }\n\n let DOMProps = filterDOMProps(props, {global: true});\n\n return (\n <FocusScope>\n <div\n {...mergeProps(DOMProps, renderProps, gridProps, focusProps, droppableCollection?.collectionProps, emptyStatePropOverrides)}\n ref={ref}\n slot={props.slot || undefined}\n onScroll={props.onScroll}\n data-drop-target={isRootDropTarget || undefined}\n data-empty={isEmpty || undefined}\n data-focused={isFocused || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-layout={layout}>\n <Provider\n values={[\n [ListStateContext, filteredState],\n [DragAndDropContext, {dragAndDropHooks, dragState, dropState}],\n [DropIndicatorContext, {render: GridListDropIndicatorWrapper}]\n ]}>\n {isListDroppable && <RootDropIndicator />}\n <CollectionRoot\n collection={filteredState.collection}\n scrollRef={ref}\n persistedKeys={useDndPersistedKeys(selectionManager, dragAndDropHooks, dropState)}\n renderDropIndicator={useRenderDropIndicator(dragAndDropHooks, dropState)} />\n </Provider>\n {emptyState}\n {dragPreview}\n </div>\n </FocusScope>\n );\n}\n\nexport interface GridListItemRenderProps extends ItemRenderProps {}\n\nexport interface GridListItemProps<T = object> extends RenderProps<GridListItemRenderProps>, LinkDOMProps, HoverEvents, PressEvents, Omit<GlobalDOMAttributes<HTMLDivElement>, 'onClick'> {\n /** The unique id of the item. */\n id?: Key,\n /** The object value that this item represents. When using dynamic collections, this is set automatically. */\n value?: T,\n /** A string representation of the item's contents, used for features like typeahead. */\n textValue?: string,\n /** Whether the item is disabled. */\n isDisabled?: boolean,\n /**\n * Handler that is called when a user performs an action on the item. The exact user event depends on\n * the collection's `selectionBehavior` prop and the interaction modality.\n */\n onAction?: () => void\n}\n\n/**\n * A GridListItem represents an individual item in a GridList.\n */\nexport const GridListItem = /*#__PURE__*/ createLeafComponent(ItemNode, function GridListItem<T extends object>(props: GridListItemProps<T>, forwardedRef: ForwardedRef<HTMLDivElement>, item: Node<T>) {\n let state = useContext(ListStateContext)!;\n let {dragAndDropHooks, dragState, dropState} = useContext(DragAndDropContext);\n let ref = useObjectRef<HTMLDivElement>(forwardedRef);\n let {isVirtualized} = useContext(CollectionRendererContext);\n let {rowProps, gridCellProps, descriptionProps, ...states} = useGridListItem(\n {\n node: item,\n shouldSelectOnPressUp: !!dragState,\n isVirtualized\n },\n state,\n ref\n );\n\n let {hoverProps, isHovered} = useHover({\n isDisabled: !states.allowsSelection && !states.hasAction,\n onHoverStart: item.props.onHoverStart,\n onHoverChange: item.props.onHoverChange,\n onHoverEnd: item.props.onHoverEnd\n });\n\n let {isFocusVisible, focusProps} = useFocusRing();\n let {checkboxProps} = useGridListSelectionCheckbox(\n {key: item.key},\n state\n );\n\n let buttonProps = state.selectionManager.disabledBehavior === 'all' && states.isDisabled ? {isDisabled: true} : {};\n\n let draggableItem: DraggableItemResult | null = null;\n if (dragState && dragAndDropHooks) {\n draggableItem = dragAndDropHooks.useDraggableItem!({key: item.key, hasDragButton: true}, dragState);\n }\n\n let dropIndicator: DropIndicatorAria | null = null;\n let dropIndicatorRef = useRef<HTMLDivElement>(null);\n let {visuallyHiddenProps} = useVisuallyHidden();\n if (dropState && dragAndDropHooks) {\n dropIndicator = dragAndDropHooks.useDropIndicator!({\n target: {type: 'item', key: item.key, dropPosition: 'on'}\n }, dropState, dropIndicatorRef);\n }\n\n let isDragging = dragState && dragState.isDragging(item.key);\n let renderProps = useRenderProps({\n ...props,\n id: undefined,\n children: item.rendered,\n defaultClassName: 'react-aria-GridListItem',\n values: {\n ...states,\n isHovered,\n isFocusVisible,\n selectionMode: state.selectionManager.selectionMode,\n selectionBehavior: state.selectionManager.selectionBehavior,\n allowsDragging: !!dragState,\n isDragging,\n isDropTarget: dropIndicator?.isDropTarget\n }\n });\n\n let dragButtonRef = useRef<HTMLButtonElement>(null);\n useEffect(() => {\n if (dragState && !dragButtonRef.current) {\n console.warn('Draggable items in a GridList must contain a <Button slot=\"drag\"> element so that keyboard and screen reader users can drag them.');\n }\n // eslint-disable-next-line\n }, []);\n\n useEffect(() => {\n if (!item.textValue && process.env.NODE_ENV !== 'production') {\n console.warn('A `textValue` prop is required for <GridListItem> elements with non-plain text children in order to support accessibility features such as type to select.');\n }\n }, [item.textValue]);\n\n let DOMProps = filterDOMProps(props as any, {global: true});\n delete DOMProps.id;\n delete DOMProps.onClick;\n\n return (\n <>\n {dropIndicator && !dropIndicator.isHidden &&\n <div role=\"row\" style={{position: 'absolute'}}>\n <div role=\"gridcell\">\n <div role=\"button\" {...visuallyHiddenProps} {...dropIndicator?.dropIndicatorProps} ref={dropIndicatorRef} />\n </div>\n </div>\n }\n <div\n {...mergeProps(DOMProps, renderProps, rowProps, focusProps, hoverProps, draggableItem?.dragProps)}\n ref={ref}\n data-selected={states.isSelected || undefined}\n data-disabled={states.isDisabled || undefined}\n data-hovered={isHovered || undefined}\n data-focused={states.isFocused || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-pressed={states.isPressed || undefined}\n data-allows-dragging={!!dragState || undefined}\n data-dragging={isDragging || undefined}\n data-drop-target={dropIndicator?.isDropTarget || undefined}\n data-selection-mode={state.selectionManager.selectionMode === 'none' ? undefined : state.selectionManager.selectionMode}>\n <div {...gridCellProps} style={{display: 'contents'}}>\n <Provider\n values={[\n [CheckboxContext, {\n slots: {\n [DEFAULT_SLOT]: {},\n selection: checkboxProps\n }\n }],\n [ButtonContext, {\n slots: {\n [DEFAULT_SLOT]: buttonProps,\n drag: {\n ...draggableItem?.dragButtonProps,\n ref: dragButtonRef,\n style: {\n pointerEvents: 'none'\n }\n }\n }\n }],\n [TextContext, {\n slots: {\n [DEFAULT_SLOT]: {},\n description: descriptionProps\n }\n }],\n [CollectionRendererContext, DefaultCollectionRenderer],\n [ListStateContext, null],\n [SelectableCollectionContext, null],\n [FieldInputContext, null]\n ]}>\n {renderProps.children}\n </Provider>\n </div>\n </div>\n </>\n );\n});\n\nfunction GridListDropIndicatorWrapper(props: DropIndicatorProps, ref: ForwardedRef<HTMLElement>) {\n ref = useObjectRef(ref);\n let {dragAndDropHooks, dropState} = useContext(DragAndDropContext);\n let buttonRef = useRef<HTMLDivElement>(null);\n let {dropIndicatorProps, isHidden, isDropTarget} = dragAndDropHooks!.useDropIndicator!(\n props,\n dropState!,\n buttonRef\n );\n\n if (isHidden) {\n return null;\n }\n\n return (\n <GridListDropIndicatorForwardRef {...props} dropIndicatorProps={dropIndicatorProps} isDropTarget={isDropTarget} buttonRef={buttonRef} ref={ref} />\n );\n}\n\ninterface GridListDropIndicatorProps extends DropIndicatorProps {\n dropIndicatorProps: React.HTMLAttributes<HTMLElement>,\n isDropTarget: boolean,\n buttonRef: RefObject<HTMLDivElement | null>\n}\n\nfunction GridListDropIndicator(props: GridListDropIndicatorProps, ref: ForwardedRef<HTMLElement>) {\n let {\n dropIndicatorProps,\n isDropTarget,\n buttonRef,\n ...otherProps\n } = props;\n\n let {visuallyHiddenProps} = useVisuallyHidden();\n let renderProps = useRenderProps({\n ...otherProps,\n defaultClassName: 'react-aria-DropIndicator',\n values: {\n isDropTarget\n }\n });\n\n return (\n <div\n {...renderProps}\n role=\"row\"\n ref={ref as RefObject<HTMLDivElement | null>}\n data-drop-target={isDropTarget || undefined}>\n <div role=\"gridcell\">\n <div {...visuallyHiddenProps} role=\"button\" {...dropIndicatorProps} ref={buttonRef} />\n {renderProps.children}\n </div>\n </div>\n );\n}\n\nconst GridListDropIndicatorForwardRef = forwardRef(GridListDropIndicator);\n\nfunction RootDropIndicator() {\n let {dragAndDropHooks, dropState} = useContext(DragAndDropContext);\n let ref = useRef<HTMLDivElement>(null);\n let {dropIndicatorProps} = dragAndDropHooks!.useDropIndicator!({\n target: {type: 'root'}\n }, dropState!, ref);\n let isDropTarget = dropState!.isDropTarget({type: 'root'});\n let {visuallyHiddenProps} = useVisuallyHidden();\n\n if (!isDropTarget && dropIndicatorProps['aria-hidden']) {\n return null;\n }\n\n return (\n <div role=\"row\" aria-hidden={dropIndicatorProps['aria-hidden']} style={{position: 'absolute'}}>\n <div role=\"gridcell\">\n <div role=\"button\" {...visuallyHiddenProps} {...dropIndicatorProps} ref={ref} />\n </div>\n </div>\n );\n}\n\nexport interface GridListLoadMoreItemProps extends Omit<LoadMoreSentinelProps, 'collection'>, StyleProps, GlobalDOMAttributes<HTMLDivElement> {\n /**\n * The load more spinner to render when loading additional items.\n */\n children?: ReactNode,\n /**\n * Whether or not the loading spinner should be rendered or not.\n */\n isLoading?: boolean\n}\n\nexport const GridListLoadMoreItem = createLeafComponent(LoaderNode, function GridListLoadingIndicator(props: GridListLoadMoreItemProps, ref: ForwardedRef<HTMLDivElement>, item: Node<object>) {\n let state = useContext(ListStateContext)!;\n let {isVirtualized} = useContext(CollectionRendererContext);\n let {isLoading, onLoadMore, scrollOffset, ...otherProps} = props;\n\n let sentinelRef = useRef(null);\n let memoedLoadMoreProps = useMemo(() => ({\n onLoadMore,\n collection: state?.collection,\n sentinelRef,\n scrollOffset\n }), [onLoadMore, scrollOffset, state?.collection]);\n useLoadMoreSentinel(memoedLoadMoreProps, sentinelRef);\n\n let renderProps = useRenderProps({\n ...otherProps,\n id: undefined,\n children: item.rendered,\n defaultClassName: 'react-aria-GridListLoadingIndicator',\n values: null\n });\n // For now don't include aria-posinset and aria-setsize on loader since they aren't keyboard focusable\n // Arguably shouldn't include them ever since it might be confusing to the user to include the loaders as part of the\n // item count\n\n return (\n <>\n {/* Alway render the sentinel. For now onus is on the user for styling when using flex + gap (this would introduce a gap even though it doesn't take room) */}\n {/* @ts-ignore - compatibility with React < 19 */}\n <div style={{position: 'relative', width: 0, height: 0}} inert={inertValue(true)} >\n <div data-testid=\"loadMoreSentinel\" ref={sentinelRef} style={{position: 'absolute', height: 1, width: 1}} />\n </div>\n {isLoading && renderProps.children && (\n <div\n {...renderProps}\n {...filterDOMProps(props, {global: true})}\n role=\"row\"\n ref={ref}>\n <div\n aria-colindex={isVirtualized ? 1 : undefined}\n role=\"gridcell\">\n {renderProps.children}\n </div>\n </div>\n )}\n </>\n );\n});\n\nexport interface GridListSectionProps<T> extends SectionProps<T> {}\n\n/**\n * A GridListSection represents a section within a GridList.\n */\nexport const GridListSection = /*#__PURE__*/ createBranchComponent(SectionNode, <T extends object>(props: GridListSectionProps<T>, ref: ForwardedRef<HTMLElement>, item: Node<T>) => {\n let state = useContext(ListStateContext)!;\n let {CollectionBranch} = useContext(CollectionRendererContext);\n let headingRef = useRef(null);\n ref = useObjectRef<HTMLElement>(ref);\n let {rowHeaderProps, rowProps, rowGroupProps} = useGridListSection({\n 'aria-label': props['aria-label'] ?? undefined\n }, state, ref);\n let renderProps = useRenderProps({\n defaultClassName: 'react-aria-GridListSection',\n className: props.className,\n style: props.style,\n values: {}\n });\n\n let DOMProps = filterDOMProps(props as any, {global: true});\n delete DOMProps.id;\n\n return (\n <section\n {...mergeProps(DOMProps, renderProps, rowGroupProps)}\n ref={ref}>\n <Provider\n values={[\n [HeaderContext, {...rowProps, ref: headingRef}],\n [GridListHeaderContext, {...rowHeaderProps}]\n ]}>\n <CollectionBranch\n collection={state.collection}\n parent={item} />\n </Provider>\n </section>\n );\n});\n\nconst GridListHeaderContext = createContext<HTMLAttributes<HTMLElement> | null>(null);\n\nexport const GridListHeader = /*#__PURE__*/ createLeafComponent(HeaderNode, function Header(props: HTMLAttributes<HTMLElement>, ref: ForwardedRef<HTMLElement>) {\n [props, ref] = useContextProps(props, ref, HeaderContext);\n let rowHeaderProps = useContext(GridListHeaderContext);\n\n return (\n <header className=\"react-aria-GridListHeader\" ref={ref} {...props}>\n <div {...rowHeaderProps} style={{display: 'contents'}}>\n {props.children}\n </div>\n </header>\n );\n});\n"],"names":[],"version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Q;oBAAE,KAAK;gBAAU;aAAE;YACvD;gBAAC;gBAA4B;oBAAC,GAAG,cAAc;gBAAA;aAAE;SAClD;qBACD,gCAAC;QACC,YAAY,MAAM,UAAU;QAC5B,QAAQ;;AAIlB;AAEO,MAAM,0DAAwB,CAAA,GAAA,oBAAY,EAAgE,CAAC;AAClH,MAAM,iEAA6B,CAAA,GAAA,oBAAY,EAAsC;AAE9E,MAAM,4CAAiB,WAAW,GAAG,CAAA,GAAA,0BAAkB,EAAE,CAAA,GAAA,iBAAS,GAAG,SAAS,OAAO,KAAkC,EAAE,GAAiC;IAC/J,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,iBAAiB,CAAA,GAAA,iBAAS,EAAE;IAEhC,qBACE,gCAAC;QAAI,WAAU;QAA4B,KAAK;QAAM,GAAG,KAAK;qBAC5D,gCAAC;QAAK,GAAG,cAAc;QAAE,OAAO;YAAC,SAAS;QAAU;OACjD,MAAM,QAAQ;AAIvB","sources":["packages/react-aria-components/src/GridList.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 */\nimport {AriaGridListProps, DraggableItemResult, DragPreviewRenderer, DropIndicatorAria, DroppableCollectionResult, FocusScope, ListKeyboardDelegate, mergeProps, useCollator, useFocusRing, useGridList, useGridListItem, useGridListSection, useGridListSelectionCheckbox, useHover, useLocale, useVisuallyHidden} from 'react-aria';\nimport {ButtonContext} from './Button';\nimport {CheckboxContext, FieldInputContext, SelectableCollectionContext, SelectableCollectionContextValue} from './RSPContexts';\nimport {\n ClassNameOrFunction,\n ContextValue,\n DEFAULT_SLOT,\n Provider,\n RenderProps,\n SlotProps,\n StyleProps,\n StyleRenderProps,\n useContextProps,\n useRenderProps\n} from './utils';\nimport {Collection, CollectionBuilder, createBranchComponent, createLeafComponent, HeaderNode, ItemNode, LoaderNode, SectionNode} from '@react-aria/collections';\nimport {CollectionProps, CollectionRendererContext, DefaultCollectionRenderer, ItemRenderProps, SectionProps} from './Collection';\nimport {DragAndDropContext, DropIndicatorContext, DropIndicatorProps, useDndPersistedKeys, useRenderDropIndicator} from './DragAndDrop';\nimport {DragAndDropHooks} from './useDragAndDrop';\nimport {DraggableCollectionState, DroppableCollectionState, Collection as ICollection, ListState, Node, SelectionBehavior, UNSTABLE_useFilteredListState, useListState} from 'react-stately';\nimport {filterDOMProps, inertValue, LoadMoreSentinelProps, useLoadMoreSentinel, useObjectRef} from '@react-aria/utils';\nimport {forwardRefType, GlobalDOMAttributes, HoverEvents, Key, LinkDOMProps, PressEvents, RefObject} from '@react-types/shared';\nimport {ListStateContext} from './ListBox';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes, JSX, ReactNode, useContext, useEffect, useMemo, useRef} from 'react';\nimport {SelectionIndicatorContext} from './SelectionIndicator';\nimport {SharedElementTransition} from './SharedElementTransition';\nimport {TextContext} from './Text';\n\nexport interface GridListRenderProps {\n /**\n * Whether the list has no items and should display its empty state.\n * @selector [data-empty]\n */\n isEmpty: boolean,\n /**\n * Whether the grid list is currently focused.\n * @selector [data-focused]\n */\n isFocused: boolean,\n /**\n * Whether the grid list is currently keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the grid list is currently the active drop target.\n * @selector [data-drop-target]\n */\n isDropTarget: boolean,\n /**\n * Whether the items are arranged in a stack or grid.\n * @selector [data-layout=\"stack | grid\"]\n */\n layout: 'stack' | 'grid',\n /**\n * State of the grid list.\n */\n state: ListState<unknown>\n}\n\nexport interface GridListProps<T> extends Omit<AriaGridListProps<T>, 'children'>, CollectionProps<T>, StyleRenderProps<GridListRenderProps>, SlotProps, GlobalDOMAttributes<HTMLDivElement> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element. A function may be provided to compute the class based on component state.\n * @default 'react-aria-GridList'\n */\n className?: ClassNameOrFunction<GridListRenderProps>,\n /**\n * Whether typeahead navigation is disabled.\n * @default false\n */\n disallowTypeAhead?: boolean,\n /**\n * How multiple selection should behave in the collection.\n * @default \"toggle\"\n */\n selectionBehavior?: SelectionBehavior,\n /** The drag and drop hooks returned by `useDragAndDrop` used to enable drag and drop behavior for the GridList. */\n dragAndDropHooks?: DragAndDropHooks<NoInfer<T>>,\n /** Provides content to display when there are no items in the list. */\n renderEmptyState?: (props: GridListRenderProps) => ReactNode,\n /**\n * Whether the items are arranged in a stack or grid.\n * @default 'stack'\n */\n layout?: 'stack' | 'grid'\n}\n\n\nexport const GridListContext = createContext<ContextValue<GridListProps<any>, HTMLDivElement>>(null);\n\n/**\n * A grid list displays a list of interactive items, with support for keyboard navigation,\n * single or multiple selection, and row actions.\n */\nexport const GridList = /*#__PURE__*/ (forwardRef as forwardRefType)(function GridList<T extends object>(props: GridListProps<T>, ref: ForwardedRef<HTMLDivElement>) {\n // Render the portal first so that we have the collection by the time we render the DOM in SSR.\n [props, ref] = useContextProps(props, ref, GridListContext);\n\n return (\n <CollectionBuilder content={<Collection {...props} />}>\n {collection => <GridListInner props={props} collection={collection} gridListRef={ref} />}\n </CollectionBuilder>\n );\n});\n\ninterface GridListInnerProps<T extends object> {\n props: GridListProps<T> & SelectableCollectionContextValue<T>,\n collection: ICollection<Node<object>>,\n gridListRef: RefObject<HTMLElement | null>\n}\n\nfunction GridListInner<T extends object>({props, collection, gridListRef: ref}: GridListInnerProps<T>) {\n [props, ref] = useContextProps(props, ref, SelectableCollectionContext);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {shouldUseVirtualFocus, filter, disallowTypeAhead, ...DOMCollectionProps} = props;\n let {dragAndDropHooks, keyboardNavigationBehavior = 'arrow', layout = 'stack'} = props;\n let {CollectionRoot, isVirtualized, layoutDelegate, dropTargetDelegate: ctxDropTargetDelegate} = useContext(CollectionRendererContext);\n let gridlistState = useListState({\n ...DOMCollectionProps,\n collection,\n children: undefined,\n layoutDelegate\n });\n\n let filteredState = UNSTABLE_useFilteredListState(gridlistState as ListState<T>, filter);\n let collator = useCollator({usage: 'search', sensitivity: 'base'});\n let {disabledBehavior, disabledKeys} = filteredState.selectionManager;\n let {direction} = useLocale();\n let keyboardDelegate = useMemo(() => (\n new ListKeyboardDelegate({\n collection: filteredState.collection,\n collator,\n ref,\n disabledKeys,\n disabledBehavior,\n layoutDelegate,\n layout,\n direction\n })\n ), [filteredState.collection, ref, layout, disabledKeys, disabledBehavior, layoutDelegate, collator, direction]);\n\n let {gridProps} = useGridList({\n ...DOMCollectionProps,\n keyboardDelegate,\n // Only tab navigation is supported in grid layout.\n keyboardNavigationBehavior: layout === 'grid' ? 'tab' : keyboardNavigationBehavior,\n isVirtualized,\n shouldSelectOnPressUp: props.shouldSelectOnPressUp\n }, filteredState, ref);\n\n let selectionManager = filteredState.selectionManager;\n let isListDraggable = !!dragAndDropHooks?.useDraggableCollectionState;\n let isListDroppable = !!dragAndDropHooks?.useDroppableCollectionState;\n let dragHooksProvided = useRef(isListDraggable);\n let dropHooksProvided = useRef(isListDroppable);\n useEffect(() => {\n if (process.env.NODE_ENV === 'production') {\n return;\n }\n if (dragHooksProvided.current !== isListDraggable) {\n console.warn('Drag hooks were provided during one render, but not another. This should be avoided as it may produce unexpected behavior.');\n }\n if (dropHooksProvided.current !== isListDroppable) {\n console.warn('Drop hooks were provided during one render, but not another. This should be avoided as it may produce unexpected behavior.');\n }\n }, [isListDraggable, isListDroppable]);\n\n let dragState: DraggableCollectionState | undefined = undefined;\n let dropState: DroppableCollectionState | undefined = undefined;\n let droppableCollection: DroppableCollectionResult | undefined = undefined;\n let isRootDropTarget = false;\n let dragPreview: JSX.Element | null = null;\n let preview = useRef<DragPreviewRenderer>(null);\n\n if (isListDraggable && dragAndDropHooks) {\n dragState = dragAndDropHooks.useDraggableCollectionState!({\n collection: filteredState.collection,\n selectionManager,\n preview: dragAndDropHooks.renderDragPreview ? preview : undefined\n });\n dragAndDropHooks.useDraggableCollection!({}, dragState, ref);\n\n let DragPreview = dragAndDropHooks.DragPreview!;\n dragPreview = dragAndDropHooks.renderDragPreview\n ? <DragPreview ref={preview}>{dragAndDropHooks.renderDragPreview}</DragPreview>\n : null;\n }\n\n if (isListDroppable && dragAndDropHooks) {\n dropState = dragAndDropHooks.useDroppableCollectionState!({\n collection: filteredState.collection,\n selectionManager\n });\n\n let keyboardDelegate = new ListKeyboardDelegate({\n collection: filteredState.collection,\n disabledKeys: selectionManager.disabledKeys,\n disabledBehavior: selectionManager.disabledBehavior,\n ref\n });\n let dropTargetDelegate = dragAndDropHooks.dropTargetDelegate || ctxDropTargetDelegate || new dragAndDropHooks.ListDropTargetDelegate(collection, ref, {layout, direction});\n droppableCollection = dragAndDropHooks.useDroppableCollection!({\n keyboardDelegate,\n dropTargetDelegate\n }, dropState, ref);\n\n isRootDropTarget = dropState.isDropTarget({type: 'root'});\n }\n\n let {focusProps, isFocused, isFocusVisible} = useFocusRing();\n let isEmpty = filteredState.collection.size === 0;\n let renderValues = {\n isDropTarget: isRootDropTarget,\n isEmpty,\n isFocused,\n isFocusVisible,\n layout,\n state: filteredState\n };\n let renderProps = useRenderProps({\n className: props.className,\n style: props.style,\n defaultClassName: 'react-aria-GridList',\n values: renderValues\n });\n\n let emptyState: ReactNode = null;\n let emptyStatePropOverrides: HTMLAttributes<HTMLElement> | null = null;\n\n if (isEmpty && props.renderEmptyState) {\n let content = props.renderEmptyState(renderValues);\n emptyState = (\n <div role=\"row\" aria-rowindex={1} style={{display: 'contents'}}>\n <div role=\"gridcell\" style={{display: 'contents'}}>\n {content}\n </div>\n </div>\n );\n }\n\n let DOMProps = filterDOMProps(props, {global: true});\n\n return (\n <FocusScope>\n <div\n {...mergeProps(DOMProps, renderProps, gridProps, focusProps, droppableCollection?.collectionProps, emptyStatePropOverrides)}\n ref={ref as RefObject<HTMLDivElement>}\n slot={props.slot || undefined}\n onScroll={props.onScroll}\n data-drop-target={isRootDropTarget || undefined}\n data-empty={isEmpty || undefined}\n data-focused={isFocused || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-layout={layout}>\n <Provider\n values={[\n [ListStateContext, filteredState],\n [DragAndDropContext, {dragAndDropHooks, dragState, dropState}],\n [DropIndicatorContext, {render: GridListDropIndicatorWrapper}]\n ]}>\n {isListDroppable && <RootDropIndicator />}\n <SharedElementTransition>\n <CollectionRoot\n collection={filteredState.collection}\n scrollRef={ref}\n persistedKeys={useDndPersistedKeys(selectionManager, dragAndDropHooks, dropState)}\n renderDropIndicator={useRenderDropIndicator(dragAndDropHooks, dropState)} />\n </SharedElementTransition>\n </Provider>\n {emptyState}\n {dragPreview}\n </div>\n </FocusScope>\n );\n}\n\nexport interface GridListItemRenderProps extends ItemRenderProps {}\n\nexport interface GridListItemProps<T = object> extends RenderProps<GridListItemRenderProps>, LinkDOMProps, HoverEvents, PressEvents, Omit<GlobalDOMAttributes<HTMLDivElement>, 'onClick'> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element. A function may be provided to compute the class based on component state.\n * @default 'react-aria-GridListItem'\n */\n className?: ClassNameOrFunction<GridListItemRenderProps>,\n /** The unique id of the item. */\n id?: Key,\n /** The object value that this item represents. When using dynamic collections, this is set automatically. */\n value?: T,\n /** A string representation of the item's contents, used for features like typeahead. */\n textValue?: string,\n /** Whether the item is disabled. */\n isDisabled?: boolean,\n /**\n * Handler that is called when a user performs an action on the item. The exact user event depends on\n * the collection's `selectionBehavior` prop and the interaction modality.\n */\n onAction?: () => void\n}\n\n/**\n * A GridListItem represents an individual item in a GridList.\n */\nexport const GridListItem = /*#__PURE__*/ createLeafComponent(ItemNode, function GridListItem<T extends object>(props: GridListItemProps<T>, forwardedRef: ForwardedRef<HTMLDivElement>, item: Node<T>) {\n let state = useContext(ListStateContext)!;\n let {dragAndDropHooks, dragState, dropState} = useContext(DragAndDropContext);\n let ref = useObjectRef<HTMLDivElement>(forwardedRef);\n let {isVirtualized} = useContext(CollectionRendererContext);\n let {rowProps, gridCellProps, descriptionProps, ...states} = useGridListItem(\n {\n node: item,\n shouldSelectOnPressUp: !!dragState,\n isVirtualized\n },\n state,\n ref\n );\n\n let {hoverProps, isHovered} = useHover({\n isDisabled: !states.allowsSelection && !states.hasAction,\n onHoverStart: item.props.onHoverStart,\n onHoverChange: item.props.onHoverChange,\n onHoverEnd: item.props.onHoverEnd\n });\n\n let {isFocusVisible, focusProps} = useFocusRing();\n let {checkboxProps} = useGridListSelectionCheckbox(\n {key: item.key},\n state\n );\n\n let buttonProps = state.selectionManager.disabledBehavior === 'all' && states.isDisabled ? {isDisabled: true} : {};\n\n let draggableItem: DraggableItemResult | null = null;\n if (dragState && dragAndDropHooks) {\n draggableItem = dragAndDropHooks.useDraggableItem!({key: item.key, hasDragButton: true}, dragState);\n }\n\n let dropIndicator: DropIndicatorAria | null = null;\n let dropIndicatorRef = useRef<HTMLDivElement>(null);\n let {visuallyHiddenProps} = useVisuallyHidden();\n if (dropState && dragAndDropHooks) {\n dropIndicator = dragAndDropHooks.useDropIndicator!({\n target: {type: 'item', key: item.key, dropPosition: 'on'}\n }, dropState, dropIndicatorRef);\n }\n\n let isDragging = dragState && dragState.isDragging(item.key);\n let renderProps = useRenderProps({\n ...props,\n id: undefined,\n children: item.rendered,\n defaultClassName: 'react-aria-GridListItem',\n values: {\n ...states,\n isHovered,\n isFocusVisible,\n selectionMode: state.selectionManager.selectionMode,\n selectionBehavior: state.selectionManager.selectionBehavior,\n allowsDragging: !!dragState,\n isDragging,\n isDropTarget: dropIndicator?.isDropTarget\n }\n });\n\n let dragButtonRef = useRef<HTMLButtonElement>(null);\n useEffect(() => {\n if (dragState && !dragButtonRef.current) {\n console.warn('Draggable items in a GridList must contain a <Button slot=\"drag\"> element so that keyboard and screen reader users can drag them.');\n }\n // eslint-disable-next-line\n }, []);\n\n useEffect(() => {\n if (!item.textValue && process.env.NODE_ENV !== 'production') {\n console.warn('A `textValue` prop is required for <GridListItem> elements with non-plain text children in order to support accessibility features such as type to select.');\n }\n }, [item.textValue]);\n\n let DOMProps = filterDOMProps(props as any, {global: true});\n delete DOMProps.id;\n delete DOMProps.onClick;\n\n return (\n <>\n {dropIndicator && !dropIndicator.isHidden &&\n <div role=\"row\" style={{position: 'absolute'}}>\n <div role=\"gridcell\">\n <div role=\"button\" {...visuallyHiddenProps} {...dropIndicator?.dropIndicatorProps} ref={dropIndicatorRef} />\n </div>\n </div>\n }\n <div\n {...mergeProps(DOMProps, renderProps, rowProps, focusProps, hoverProps, draggableItem?.dragProps)}\n ref={ref}\n data-selected={states.isSelected || undefined}\n data-disabled={states.isDisabled || undefined}\n data-hovered={isHovered || undefined}\n data-focused={states.isFocused || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-pressed={states.isPressed || undefined}\n data-allows-dragging={!!dragState || undefined}\n data-dragging={isDragging || undefined}\n data-drop-target={dropIndicator?.isDropTarget || undefined}\n data-selection-mode={state.selectionManager.selectionMode === 'none' ? undefined : state.selectionManager.selectionMode}>\n <div {...gridCellProps} style={{display: 'contents'}}>\n <Provider\n values={[\n [CheckboxContext, {\n slots: {\n [DEFAULT_SLOT]: {},\n selection: checkboxProps\n }\n }],\n [ButtonContext, {\n slots: {\n [DEFAULT_SLOT]: buttonProps,\n drag: {\n ...draggableItem?.dragButtonProps,\n ref: dragButtonRef,\n style: {\n pointerEvents: 'none'\n }\n }\n }\n }],\n [TextContext, {\n slots: {\n [DEFAULT_SLOT]: {},\n description: descriptionProps\n }\n }],\n [CollectionRendererContext, DefaultCollectionRenderer],\n [ListStateContext, null],\n [SelectableCollectionContext, null],\n [FieldInputContext, null],\n [SelectionIndicatorContext, {isSelected: states.isSelected}]\n ]}>\n {renderProps.children}\n </Provider>\n </div>\n </div>\n </>\n );\n});\n\nfunction GridListDropIndicatorWrapper(props: DropIndicatorProps, ref: ForwardedRef<HTMLElement>) {\n ref = useObjectRef(ref);\n let {dragAndDropHooks, dropState} = useContext(DragAndDropContext);\n let buttonRef = useRef<HTMLDivElement>(null);\n let {dropIndicatorProps, isHidden, isDropTarget} = dragAndDropHooks!.useDropIndicator!(\n props,\n dropState!,\n buttonRef\n );\n\n if (isHidden) {\n return null;\n }\n\n return (\n <GridListDropIndicatorForwardRef {...props} dropIndicatorProps={dropIndicatorProps} isDropTarget={isDropTarget} buttonRef={buttonRef} ref={ref} />\n );\n}\n\ninterface GridListDropIndicatorProps extends DropIndicatorProps {\n dropIndicatorProps: React.HTMLAttributes<HTMLElement>,\n isDropTarget: boolean,\n buttonRef: RefObject<HTMLDivElement | null>\n}\n\nfunction GridListDropIndicator(props: GridListDropIndicatorProps, ref: ForwardedRef<HTMLElement>) {\n let {\n dropIndicatorProps,\n isDropTarget,\n buttonRef,\n ...otherProps\n } = props;\n\n let {visuallyHiddenProps} = useVisuallyHidden();\n let renderProps = useRenderProps({\n ...otherProps,\n defaultClassName: 'react-aria-DropIndicator',\n values: {\n isDropTarget\n }\n });\n\n return (\n <div\n {...renderProps}\n role=\"row\"\n ref={ref as RefObject<HTMLDivElement | null>}\n data-drop-target={isDropTarget || undefined}>\n <div role=\"gridcell\">\n <div {...visuallyHiddenProps} role=\"button\" {...dropIndicatorProps} ref={buttonRef} />\n {renderProps.children}\n </div>\n </div>\n );\n}\n\nconst GridListDropIndicatorForwardRef = forwardRef(GridListDropIndicator);\n\nfunction RootDropIndicator() {\n let {dragAndDropHooks, dropState} = useContext(DragAndDropContext);\n let ref = useRef<HTMLDivElement>(null);\n let {dropIndicatorProps} = dragAndDropHooks!.useDropIndicator!({\n target: {type: 'root'}\n }, dropState!, ref);\n let isDropTarget = dropState!.isDropTarget({type: 'root'});\n let {visuallyHiddenProps} = useVisuallyHidden();\n\n if (!isDropTarget && dropIndicatorProps['aria-hidden']) {\n return null;\n }\n\n return (\n <div role=\"row\" aria-hidden={dropIndicatorProps['aria-hidden']} style={{position: 'absolute'}}>\n <div role=\"gridcell\">\n <div role=\"button\" {...visuallyHiddenProps} {...dropIndicatorProps} ref={ref} />\n </div>\n </div>\n );\n}\n\nexport interface GridListLoadMoreItemProps extends Omit<LoadMoreSentinelProps, 'collection'>, StyleProps, GlobalDOMAttributes<HTMLDivElement> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element.\n * @default 'react-aria-GridListLoadMoreItem'\n */\n className?: string,\n /**\n * The load more spinner to render when loading additional items.\n */\n children?: ReactNode,\n /**\n * Whether or not the loading spinner should be rendered or not.\n */\n isLoading?: boolean\n}\n\nexport const GridListLoadMoreItem = createLeafComponent(LoaderNode, function GridListLoadingIndicator(props: GridListLoadMoreItemProps, ref: ForwardedRef<HTMLDivElement>, item: Node<object>) {\n let state = useContext(ListStateContext)!;\n let {isVirtualized} = useContext(CollectionRendererContext);\n let {isLoading, onLoadMore, scrollOffset, ...otherProps} = props;\n\n let sentinelRef = useRef(null);\n let memoedLoadMoreProps = useMemo(() => ({\n onLoadMore,\n collection: state?.collection,\n sentinelRef,\n scrollOffset\n }), [onLoadMore, scrollOffset, state?.collection]);\n useLoadMoreSentinel(memoedLoadMoreProps, sentinelRef);\n\n let renderProps = useRenderProps({\n ...otherProps,\n id: undefined,\n children: item.rendered,\n defaultClassName: 'react-aria-GridListLoadingIndicator',\n values: null\n });\n // For now don't include aria-posinset and aria-setsize on loader since they aren't keyboard focusable\n // Arguably shouldn't include them ever since it might be confusing to the user to include the loaders as part of the\n // item count\n\n return (\n <>\n {/* Alway render the sentinel. For now onus is on the user for styling when using flex + gap (this would introduce a gap even though it doesn't take room) */}\n {/* @ts-ignore - compatibility with React < 19 */}\n <div style={{position: 'relative', width: 0, height: 0}} inert={inertValue(true)} >\n <div data-testid=\"loadMoreSentinel\" ref={sentinelRef} style={{position: 'absolute', height: 1, width: 1}} />\n </div>\n {isLoading && renderProps.children && (\n <div\n {...renderProps}\n {...filterDOMProps(props, {global: true})}\n role=\"row\"\n ref={ref}>\n <div\n aria-colindex={isVirtualized ? 1 : undefined}\n role=\"gridcell\">\n {renderProps.children}\n </div>\n </div>\n )}\n </>\n );\n});\n\nexport interface GridListSectionProps<T> extends SectionProps<T> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element.\n * @default 'react-aria-GridListSection'\n */\n className?: string\n}\n\n/**\n * A GridListSection represents a section within a GridList.\n */\nexport const GridListSection = /*#__PURE__*/ createBranchComponent(SectionNode, <T extends object>(props: GridListSectionProps<T>, ref: ForwardedRef<HTMLDivElement>, item: Node<T>) => {\n let state = useContext(ListStateContext)!;\n let {CollectionBranch} = useContext(CollectionRendererContext);\n let headingRef = useRef(null);\n ref = useObjectRef<HTMLDivElement>(ref);\n let {rowHeaderProps, rowProps, rowGroupProps} = useGridListSection({\n 'aria-label': props['aria-label'] ?? undefined\n }, state, ref);\n let renderProps = useRenderProps({\n defaultClassName: 'react-aria-GridListSection',\n className: props.className,\n style: props.style,\n values: {}\n });\n\n let DOMProps = filterDOMProps(props as any, {global: true});\n delete DOMProps.id;\n\n return (\n <div\n {...mergeProps(DOMProps, renderProps, rowGroupProps)}\n ref={ref}>\n <Provider\n values={[\n [GridListHeaderContext, {...rowProps, ref: headingRef}],\n [GridListHeaderInnerContext, {...rowHeaderProps}]\n ]}>\n <CollectionBranch\n collection={state.collection}\n parent={item} />\n </Provider>\n </div>\n );\n});\n\nexport const GridListHeaderContext = createContext<ContextValue<HTMLAttributes<HTMLDivElement>, HTMLDivElement>>({});\nconst GridListHeaderInnerContext = createContext<HTMLAttributes<HTMLElement> | null>(null);\n\nexport const GridListHeader = /*#__PURE__*/ createLeafComponent(HeaderNode, function Header(props: HTMLAttributes<HTMLElement>, ref: ForwardedRef<HTMLDivElement>) {\n [props, ref] = useContextProps(props, ref, GridListHeaderContext);\n let rowHeaderProps = useContext(GridListHeaderInnerContext);\n\n return (\n <div className=\"react-aria-GridListHeader\" ref={ref} {...props}>\n <div {...rowHeaderProps} style={{display: 'contents'}}>\n {props.children}\n </div>\n </div>\n );\n});\n"],"names":[],"version":3,"file":"GridList.module.js.map"}
@@ -29,7 +29,9 @@ $parcel$export(module.exports, "Group", () => $dcae72abc18c0045$export$eb2fcfdbd
29
29
  const $dcae72abc18c0045$export$f9c6924e160136d1 = /*#__PURE__*/ (0, $1Rw7b$react.createContext)({});
30
30
  const $dcae72abc18c0045$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $1Rw7b$react.forwardRef)(function Group(props, ref) {
31
31
  [props, ref] = (0, $c5ccf687772c0422$exports.useContextProps)(props, ref, $dcae72abc18c0045$export$f9c6924e160136d1);
32
- let { isDisabled: isDisabled, isInvalid: isInvalid, onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, ...otherProps } = props;
32
+ let { isDisabled: isDisabled, isInvalid: isInvalid, isReadOnly: isReadOnly, onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, ...otherProps } = props;
33
+ isDisabled !== null && isDisabled !== void 0 ? isDisabled : isDisabled = !!props['aria-disabled'] && props['aria-disabled'] !== 'false';
34
+ isInvalid !== null && isInvalid !== void 0 ? isInvalid : isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';
33
35
  let { hoverProps: hoverProps, isHovered: isHovered } = (0, $1Rw7b$reactaria.useHover)({
34
36
  onHoverStart: onHoverStart,
35
37
  onHoverChange: onHoverChange,
@@ -39,8 +41,6 @@ const $dcae72abc18c0045$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $1Rw7b$react
39
41
  let { isFocused: isFocused, isFocusVisible: isFocusVisible, focusProps: focusProps } = (0, $1Rw7b$reactaria.useFocusRing)({
40
42
  within: true
41
43
  });
42
- isDisabled !== null && isDisabled !== void 0 ? isDisabled : isDisabled = !!props['aria-disabled'] && props['aria-disabled'] !== 'false';
43
- isInvalid !== null && isInvalid !== void 0 ? isInvalid : isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';
44
44
  let renderProps = (0, $c5ccf687772c0422$exports.useRenderProps)({
45
45
  ...props,
46
46
  values: {
@@ -63,7 +63,8 @@ const $dcae72abc18c0045$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $1Rw7b$react
63
63
  "data-hovered": isHovered || undefined,
64
64
  "data-focus-visible": isFocusVisible || undefined,
65
65
  "data-disabled": isDisabled || undefined,
66
- "data-invalid": isInvalid || undefined
66
+ "data-invalid": isInvalid || undefined,
67
+ "data-readonly": isReadOnly || undefined
67
68
  }, renderProps.children);
68
69
  });
69
70
 
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;AAkDM,MAAM,0DAAe,CAAA,GAAA,0BAAY,EAA4C,CAAC;AAK9E,MAAM,4CAAsB,AAAd,WAAW,GAAI,CAAA,GAAA,uBAAS,EAAqB,SAAS,MAAM,KAAiB,EAAE,GAAiC;IACnI,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,cAAC,UAAU,aAAE,SAAS,gBAAE,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAEtF,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,yBAAO,EAAE;sBAAC;uBAAc;oBAAe;oBAAY;IAAU;IAC3F,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,6BAAW,EAAE;QACzD,QAAQ;IACV;IAEA,uBAAA,wBAAA,aAAA,aAAe,CAAC,CAAC,KAAK,CAAC,gBAAgB,IAAI,KAAK,CAAC,gBAAgB,KAAK;IACtE,sBAAA,uBAAA,YAAA,YAAc,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IAEnE,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBAAC;YAAW,eAAe;4BAAW;wBAAgB;uBAAY;QAAS;QACnF,kBAAkB;IACpB;QAOU,aACA;IANV,qBACE,0DAAC;QACE,GAAG,CAAA,GAAA,2BAAS,EAAE,YAAY,YAAY,WAAW;QACjD,GAAG,WAAW;QACf,KAAK;QACL,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,qBAAmB,aAAa;QAChC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,iBAAe,cAAc;QAC7B,gBAAc,aAAa;OAC1B,YAAY,QAAQ;AAG3B","sources":["packages/react-aria-components/src/Group.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 {AriaLabelingProps, DOMProps, forwardRefType} from '@react-types/shared';\nimport {ContextValue, RenderProps, SlotProps, useContextProps, useRenderProps} from './utils';\nimport {HoverProps, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes} from 'react';\n\nexport interface GroupRenderProps {\n /**\n * Whether the group is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether an element within the group is focused, either via a mouse or keyboard.\n * @selector [data-focus-within]\n */\n isFocusWithin: boolean,\n /**\n * Whether an element within the group is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the group is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the group is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface GroupProps extends AriaLabelingProps, Omit<HTMLAttributes<HTMLElement>, 'children' | 'className' | 'style' | 'role' | 'slot'>, DOMProps, HoverProps, RenderProps<GroupRenderProps>, SlotProps {\n /** Whether the group is disabled. */\n isDisabled?: boolean,\n /** Whether the group is invalid. */\n isInvalid?: boolean,\n /**\n * An accessibility role for the group. By default, this is set to `'group'`.\n * Use `'region'` when the contents of the group is important enough to be\n * included in the page table of contents. Use `'presentation'` if the group\n * is visual only and does not represent a semantic grouping of controls.\n * @default 'group'\n */\n role?: 'group' | 'region' | 'presentation'\n}\n\nexport const GroupContext = createContext<ContextValue<GroupProps, HTMLDivElement>>({});\n\n/**\n * A group represents a set of related UI controls, and supports interactive states for styling.\n */\nexport const Group = /*#__PURE__*/ (forwardRef as forwardRefType)(function Group(props: GroupProps, ref: ForwardedRef<HTMLDivElement>) {\n [props, ref] = useContextProps(props, ref, GroupContext);\n let {isDisabled, isInvalid, onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n\n let {hoverProps, isHovered} = useHover({onHoverStart, onHoverChange, onHoverEnd, isDisabled});\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n within: true\n });\n\n isDisabled ??= !!props['aria-disabled'] && props['aria-disabled'] !== 'false';\n isInvalid ??= !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n\n let renderProps = useRenderProps({\n ...props,\n values: {isHovered, isFocusWithin: isFocused, isFocusVisible, isDisabled, isInvalid},\n defaultClassName: 'react-aria-Group'\n });\n\n return (\n <div\n {...mergeProps(otherProps, focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n role={props.role ?? 'group'}\n slot={props.slot ?? undefined}\n data-focus-within={isFocused || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-disabled={isDisabled || undefined}\n data-invalid={isInvalid || undefined}>\n {renderProps.children}\n </div>\n );\n});\n"],"names":[],"version":3,"file":"Group.main.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;AAgEM,MAAM,0DAAe,CAAA,GAAA,0BAAY,EAA4C,CAAC;AAK9E,MAAM,4CAAsB,AAAd,WAAW,GAAI,CAAA,GAAA,uBAAS,EAAqB,SAAS,MAAM,KAAiB,EAAE,GAAiC;IACnI,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,cAAC,UAAU,aAAE,SAAS,cAAE,UAAU,gBAAE,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAClG,uBAAA,wBAAA,aAAA,aAAe,CAAC,CAAC,KAAK,CAAC,gBAAgB,IAAI,KAAK,CAAC,gBAAgB,KAAK;IACtE,sBAAA,uBAAA,YAAA,YAAc,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IAEnE,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,yBAAO,EAAE;sBAAC;uBAAc;oBAAe;oBAAY;IAAU;IAC3F,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,6BAAW,EAAE;QACzD,QAAQ;IACV;IAEA,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBAAC;YAAW,eAAe;4BAAW;wBAAgB;uBAAY;QAAS;QACnF,kBAAkB;IACpB;QAOU,aACA;IANV,qBACE,0DAAC;QACE,GAAG,CAAA,GAAA,2BAAS,EAAE,YAAY,YAAY,WAAW;QACjD,GAAG,WAAW;QACf,KAAK;QACL,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,qBAAmB,aAAa;QAChC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,iBAAe,cAAc;QAC7B,gBAAc,aAAa;QAC3B,iBAAe,cAAc;OAC5B,YAAY,QAAQ;AAG3B","sources":["packages/react-aria-components/src/Group.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 {AriaLabelingProps, DOMProps, forwardRefType} from '@react-types/shared';\nimport {\n ClassNameOrFunction,\n ContextValue,\n RenderProps,\n SlotProps,\n useContextProps,\n useRenderProps\n} from './utils';\nimport {HoverProps, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes} from 'react';\n\nexport interface GroupRenderProps {\n /**\n * Whether the group is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether an element within the group is focused, either via a mouse or keyboard.\n * @selector [data-focus-within]\n */\n isFocusWithin: boolean,\n /**\n * Whether an element within the group is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the group is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the group is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface GroupProps extends AriaLabelingProps, Omit<HTMLAttributes<HTMLElement>, 'children' | 'className' | 'style' | 'role' | 'slot'>, DOMProps, HoverProps, RenderProps<GroupRenderProps>, SlotProps {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element. A function may be provided to compute the class based on component state.\n * @default 'react-aria-Group'\n */\n className?: ClassNameOrFunction<GroupRenderProps>,\n /** Whether the group is disabled. */\n isDisabled?: boolean,\n /** Whether the group is invalid. */\n isInvalid?: boolean,\n /** Whether the group is read only. */\n isReadOnly?: boolean,\n /**\n * An accessibility role for the group. By default, this is set to `'group'`.\n * Use `'region'` when the contents of the group is important enough to be\n * included in the page table of contents. Use `'presentation'` if the group\n * is visual only and does not represent a semantic grouping of controls.\n * @default 'group'\n */\n role?: 'group' | 'region' | 'presentation'\n}\n\nexport const GroupContext = createContext<ContextValue<GroupProps, HTMLDivElement>>({});\n\n/**\n * A group represents a set of related UI controls, and supports interactive states for styling.\n */\nexport const Group = /*#__PURE__*/ (forwardRef as forwardRefType)(function Group(props: GroupProps, ref: ForwardedRef<HTMLDivElement>) {\n [props, ref] = useContextProps(props, ref, GroupContext);\n let {isDisabled, isInvalid, isReadOnly, onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n isDisabled ??= !!props['aria-disabled'] && props['aria-disabled'] !== 'false';\n isInvalid ??= !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n\n let {hoverProps, isHovered} = useHover({onHoverStart, onHoverChange, onHoverEnd, isDisabled});\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n within: true\n });\n\n let renderProps = useRenderProps({\n ...props,\n values: {isHovered, isFocusWithin: isFocused, isFocusVisible, isDisabled, isInvalid},\n defaultClassName: 'react-aria-Group'\n });\n\n return (\n <div\n {...mergeProps(otherProps, focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n role={props.role ?? 'group'}\n slot={props.slot ?? undefined}\n data-focus-within={isFocused || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-disabled={isDisabled || undefined}\n data-invalid={isInvalid || undefined}\n data-readonly={isReadOnly || undefined}>\n {renderProps.children}\n </div>\n );\n});\n"],"names":[],"version":3,"file":"Group.main.js.map"}
package/dist/Group.mjs CHANGED
@@ -18,7 +18,9 @@ import $gZciS$react, {createContext as $gZciS$createContext, forwardRef as $gZci
18
18
  const $a049562f99e7db0e$export$f9c6924e160136d1 = /*#__PURE__*/ (0, $gZciS$createContext)({});
19
19
  const $a049562f99e7db0e$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $gZciS$forwardRef)(function Group(props, ref) {
20
20
  [props, ref] = (0, $64fa3d84918910a7$export$29f1550f4b0d4415)(props, ref, $a049562f99e7db0e$export$f9c6924e160136d1);
21
- let { isDisabled: isDisabled, isInvalid: isInvalid, onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, ...otherProps } = props;
21
+ let { isDisabled: isDisabled, isInvalid: isInvalid, isReadOnly: isReadOnly, onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, ...otherProps } = props;
22
+ isDisabled !== null && isDisabled !== void 0 ? isDisabled : isDisabled = !!props['aria-disabled'] && props['aria-disabled'] !== 'false';
23
+ isInvalid !== null && isInvalid !== void 0 ? isInvalid : isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';
22
24
  let { hoverProps: hoverProps, isHovered: isHovered } = (0, $gZciS$useHover)({
23
25
  onHoverStart: onHoverStart,
24
26
  onHoverChange: onHoverChange,
@@ -28,8 +30,6 @@ const $a049562f99e7db0e$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $gZciS$forwa
28
30
  let { isFocused: isFocused, isFocusVisible: isFocusVisible, focusProps: focusProps } = (0, $gZciS$useFocusRing)({
29
31
  within: true
30
32
  });
31
- isDisabled !== null && isDisabled !== void 0 ? isDisabled : isDisabled = !!props['aria-disabled'] && props['aria-disabled'] !== 'false';
32
- isInvalid !== null && isInvalid !== void 0 ? isInvalid : isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';
33
33
  let renderProps = (0, $64fa3d84918910a7$export$4d86445c2cf5e3)({
34
34
  ...props,
35
35
  values: {
@@ -52,7 +52,8 @@ const $a049562f99e7db0e$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $gZciS$forwa
52
52
  "data-hovered": isHovered || undefined,
53
53
  "data-focus-visible": isFocusVisible || undefined,
54
54
  "data-disabled": isDisabled || undefined,
55
- "data-invalid": isInvalid || undefined
55
+ "data-invalid": isInvalid || undefined,
56
+ "data-readonly": isReadOnly || undefined
56
57
  }, renderProps.children);
57
58
  });
58
59
 
@@ -18,7 +18,9 @@ import $gZciS$react, {createContext as $gZciS$createContext, forwardRef as $gZci
18
18
  const $a049562f99e7db0e$export$f9c6924e160136d1 = /*#__PURE__*/ (0, $gZciS$createContext)({});
19
19
  const $a049562f99e7db0e$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $gZciS$forwardRef)(function Group(props, ref) {
20
20
  [props, ref] = (0, $64fa3d84918910a7$export$29f1550f4b0d4415)(props, ref, $a049562f99e7db0e$export$f9c6924e160136d1);
21
- let { isDisabled: isDisabled, isInvalid: isInvalid, onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, ...otherProps } = props;
21
+ let { isDisabled: isDisabled, isInvalid: isInvalid, isReadOnly: isReadOnly, onHoverStart: onHoverStart, onHoverChange: onHoverChange, onHoverEnd: onHoverEnd, ...otherProps } = props;
22
+ isDisabled !== null && isDisabled !== void 0 ? isDisabled : isDisabled = !!props['aria-disabled'] && props['aria-disabled'] !== 'false';
23
+ isInvalid !== null && isInvalid !== void 0 ? isInvalid : isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';
22
24
  let { hoverProps: hoverProps, isHovered: isHovered } = (0, $gZciS$useHover)({
23
25
  onHoverStart: onHoverStart,
24
26
  onHoverChange: onHoverChange,
@@ -28,8 +30,6 @@ const $a049562f99e7db0e$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $gZciS$forwa
28
30
  let { isFocused: isFocused, isFocusVisible: isFocusVisible, focusProps: focusProps } = (0, $gZciS$useFocusRing)({
29
31
  within: true
30
32
  });
31
- isDisabled !== null && isDisabled !== void 0 ? isDisabled : isDisabled = !!props['aria-disabled'] && props['aria-disabled'] !== 'false';
32
- isInvalid !== null && isInvalid !== void 0 ? isInvalid : isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';
33
33
  let renderProps = (0, $64fa3d84918910a7$export$4d86445c2cf5e3)({
34
34
  ...props,
35
35
  values: {
@@ -52,7 +52,8 @@ const $a049562f99e7db0e$export$eb2fcfdbd7ba97d4 = /*#__PURE__*/ (0, $gZciS$forwa
52
52
  "data-hovered": isHovered || undefined,
53
53
  "data-focus-visible": isFocusVisible || undefined,
54
54
  "data-disabled": isDisabled || undefined,
55
- "data-invalid": isInvalid || undefined
55
+ "data-invalid": isInvalid || undefined,
56
+ "data-readonly": isReadOnly || undefined
56
57
  }, renderProps.children);
57
58
  });
58
59
 
@@ -1 +1 @@
1
- {"mappings":";;;;AAAA;;;;;;;;;;CAUC;;;AAkDM,MAAM,0DAAe,CAAA,GAAA,oBAAY,EAA4C,CAAC;AAK9E,MAAM,4CAAsB,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,MAAM,KAAiB,EAAE,GAAiC;IACnI,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,cAAC,UAAU,aAAE,SAAS,gBAAE,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAEtF,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,eAAO,EAAE;sBAAC;uBAAc;oBAAe;oBAAY;IAAU;IAC3F,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,mBAAW,EAAE;QACzD,QAAQ;IACV;IAEA,uBAAA,wBAAA,aAAA,aAAe,CAAC,CAAC,KAAK,CAAC,gBAAgB,IAAI,KAAK,CAAC,gBAAgB,KAAK;IACtE,sBAAA,uBAAA,YAAA,YAAc,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IAEnE,IAAI,cAAc,CAAA,GAAA,uCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBAAC;YAAW,eAAe;4BAAW;wBAAgB;uBAAY;QAAS;QACnF,kBAAkB;IACpB;QAOU,aACA;IANV,qBACE,gCAAC;QACE,GAAG,CAAA,GAAA,iBAAS,EAAE,YAAY,YAAY,WAAW;QACjD,GAAG,WAAW;QACf,KAAK;QACL,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,qBAAmB,aAAa;QAChC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,iBAAe,cAAc;QAC7B,gBAAc,aAAa;OAC1B,YAAY,QAAQ;AAG3B","sources":["packages/react-aria-components/src/Group.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 {AriaLabelingProps, DOMProps, forwardRefType} from '@react-types/shared';\nimport {ContextValue, RenderProps, SlotProps, useContextProps, useRenderProps} from './utils';\nimport {HoverProps, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes} from 'react';\n\nexport interface GroupRenderProps {\n /**\n * Whether the group is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether an element within the group is focused, either via a mouse or keyboard.\n * @selector [data-focus-within]\n */\n isFocusWithin: boolean,\n /**\n * Whether an element within the group is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the group is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the group is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface GroupProps extends AriaLabelingProps, Omit<HTMLAttributes<HTMLElement>, 'children' | 'className' | 'style' | 'role' | 'slot'>, DOMProps, HoverProps, RenderProps<GroupRenderProps>, SlotProps {\n /** Whether the group is disabled. */\n isDisabled?: boolean,\n /** Whether the group is invalid. */\n isInvalid?: boolean,\n /**\n * An accessibility role for the group. By default, this is set to `'group'`.\n * Use `'region'` when the contents of the group is important enough to be\n * included in the page table of contents. Use `'presentation'` if the group\n * is visual only and does not represent a semantic grouping of controls.\n * @default 'group'\n */\n role?: 'group' | 'region' | 'presentation'\n}\n\nexport const GroupContext = createContext<ContextValue<GroupProps, HTMLDivElement>>({});\n\n/**\n * A group represents a set of related UI controls, and supports interactive states for styling.\n */\nexport const Group = /*#__PURE__*/ (forwardRef as forwardRefType)(function Group(props: GroupProps, ref: ForwardedRef<HTMLDivElement>) {\n [props, ref] = useContextProps(props, ref, GroupContext);\n let {isDisabled, isInvalid, onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n\n let {hoverProps, isHovered} = useHover({onHoverStart, onHoverChange, onHoverEnd, isDisabled});\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n within: true\n });\n\n isDisabled ??= !!props['aria-disabled'] && props['aria-disabled'] !== 'false';\n isInvalid ??= !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n\n let renderProps = useRenderProps({\n ...props,\n values: {isHovered, isFocusWithin: isFocused, isFocusVisible, isDisabled, isInvalid},\n defaultClassName: 'react-aria-Group'\n });\n\n return (\n <div\n {...mergeProps(otherProps, focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n role={props.role ?? 'group'}\n slot={props.slot ?? undefined}\n data-focus-within={isFocused || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-disabled={isDisabled || undefined}\n data-invalid={isInvalid || undefined}>\n {renderProps.children}\n </div>\n );\n});\n"],"names":[],"version":3,"file":"Group.module.js.map"}
1
+ {"mappings":";;;;AAAA;;;;;;;;;;CAUC;;;AAgEM,MAAM,0DAAe,CAAA,GAAA,oBAAY,EAA4C,CAAC;AAK9E,MAAM,4CAAsB,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,MAAM,KAAiB,EAAE,GAAiC;IACnI,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,cAAC,UAAU,aAAE,SAAS,cAAE,UAAU,gBAAE,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAClG,uBAAA,wBAAA,aAAA,aAAe,CAAC,CAAC,KAAK,CAAC,gBAAgB,IAAI,KAAK,CAAC,gBAAgB,KAAK;IACtE,sBAAA,uBAAA,YAAA,YAAc,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IAEnE,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,eAAO,EAAE;sBAAC;uBAAc;oBAAe;oBAAY;IAAU;IAC3F,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,mBAAW,EAAE;QACzD,QAAQ;IACV;IAEA,IAAI,cAAc,CAAA,GAAA,uCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBAAC;YAAW,eAAe;4BAAW;wBAAgB;uBAAY;QAAS;QACnF,kBAAkB;IACpB;QAOU,aACA;IANV,qBACE,gCAAC;QACE,GAAG,CAAA,GAAA,iBAAS,EAAE,YAAY,YAAY,WAAW;QACjD,GAAG,WAAW;QACf,KAAK;QACL,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,MAAM,CAAA,cAAA,MAAM,IAAI,cAAV,yBAAA,cAAc;QACpB,qBAAmB,aAAa;QAChC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,iBAAe,cAAc;QAC7B,gBAAc,aAAa;QAC3B,iBAAe,cAAc;OAC5B,YAAY,QAAQ;AAG3B","sources":["packages/react-aria-components/src/Group.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 {AriaLabelingProps, DOMProps, forwardRefType} from '@react-types/shared';\nimport {\n ClassNameOrFunction,\n ContextValue,\n RenderProps,\n SlotProps,\n useContextProps,\n useRenderProps\n} from './utils';\nimport {HoverProps, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes} from 'react';\n\nexport interface GroupRenderProps {\n /**\n * Whether the group is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether an element within the group is focused, either via a mouse or keyboard.\n * @selector [data-focus-within]\n */\n isFocusWithin: boolean,\n /**\n * Whether an element within the group is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the group is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the group is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface GroupProps extends AriaLabelingProps, Omit<HTMLAttributes<HTMLElement>, 'children' | 'className' | 'style' | 'role' | 'slot'>, DOMProps, HoverProps, RenderProps<GroupRenderProps>, SlotProps {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element. A function may be provided to compute the class based on component state.\n * @default 'react-aria-Group'\n */\n className?: ClassNameOrFunction<GroupRenderProps>,\n /** Whether the group is disabled. */\n isDisabled?: boolean,\n /** Whether the group is invalid. */\n isInvalid?: boolean,\n /** Whether the group is read only. */\n isReadOnly?: boolean,\n /**\n * An accessibility role for the group. By default, this is set to `'group'`.\n * Use `'region'` when the contents of the group is important enough to be\n * included in the page table of contents. Use `'presentation'` if the group\n * is visual only and does not represent a semantic grouping of controls.\n * @default 'group'\n */\n role?: 'group' | 'region' | 'presentation'\n}\n\nexport const GroupContext = createContext<ContextValue<GroupProps, HTMLDivElement>>({});\n\n/**\n * A group represents a set of related UI controls, and supports interactive states for styling.\n */\nexport const Group = /*#__PURE__*/ (forwardRef as forwardRefType)(function Group(props: GroupProps, ref: ForwardedRef<HTMLDivElement>) {\n [props, ref] = useContextProps(props, ref, GroupContext);\n let {isDisabled, isInvalid, isReadOnly, onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n isDisabled ??= !!props['aria-disabled'] && props['aria-disabled'] !== 'false';\n isInvalid ??= !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n\n let {hoverProps, isHovered} = useHover({onHoverStart, onHoverChange, onHoverEnd, isDisabled});\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n within: true\n });\n\n let renderProps = useRenderProps({\n ...props,\n values: {isHovered, isFocusWithin: isFocused, isFocusVisible, isDisabled, isInvalid},\n defaultClassName: 'react-aria-Group'\n });\n\n return (\n <div\n {...mergeProps(otherProps, focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n role={props.role ?? 'group'}\n slot={props.slot ?? undefined}\n data-focus-within={isFocused || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-disabled={isDisabled || undefined}\n data-invalid={isInvalid || undefined}\n data-readonly={isReadOnly || undefined}>\n {renderProps.children}\n </div>\n );\n});\n"],"names":[],"version":3,"file":"Group.module.js.map"}
@@ -87,12 +87,14 @@ function $7753596769f21492$export$f6a685cd1acbd1fa(props, state) {
87
87
  if (state.granularity === 'day') targetValue = (0, $bChuM$internationalizeddate.parseDate)(targetString);
88
88
  // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.
89
89
  // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.
90
- // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue
91
- // which is why in the code below we first set each segment to validate it before committing the new value.
92
- // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to
90
+ // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue
91
+ // which is why in the code below we first set each segment to validate it before committing the new value.
92
+ // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to
93
93
  // set a new value when the field itself is empty.
94
94
  if ('setSegment' in state) for(let type in targetValue){
95
+ // eslint-disable-next-line max-depth
95
96
  if ($7753596769f21492$var$dateSegments.includes(type)) state.setSegment(type, targetValue[type]);
97
+ // eslint-disable-next-line max-depth
96
98
  if (timeSegments.includes(type)) state.setSegment(type, targetValue[type]);
97
99
  }
98
100
  state.setValue(targetValue);
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;AAiCD,MAAM,qCAAe;IAAC;IAAO;IAAS;CAAO;AAC7C,MAAM,uCAAiB;IAAC,QAAQ;IAAG,UAAU;IAAG,UAAU;AAAC;AAEpD,SAAS,0CAAmB,KAA2B,EAAE,KAAuC;IACrG,IAAI,gBACF,YAAY,cACZ,UAAU,QACV,IAAI,EACL,GAAG;IACJ,IAAI,uBAAC,mBAAmB,EAAC,GAAG,CAAA,GAAA,kCAAgB,EAAE;QAC5C,OAAO;YACL,0BAA0B;YAC1B,UAAU;YACV,KAAK;YACL,MAAM;QACR;IACF;IAEA,IAAI,YAAY;IAChB,IAAI,MAAM,WAAW,KAAK,UACxB,YAAY;SACP,IAAI,MAA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SAAS,0CAAgB,KAA2B;IACzD,IAAI,SAAC,KAAK,EAAC,GAAG;IACd,IAAI,kBAAC,cAAc,cAAE,UAAU,EAAC,GAAG,0CAAmB;QAAC,GAAG,KAAK;IAAA,GAAG;IAClE,qBACE,0DAAC;QAAK,GAAG,cAAc;QAAE,eAAY;qBACnC,0DAAC,SAAU;AAGjB","sources":["packages/react-aria-components/src/HiddenDateInput.tsx"],"sourcesContent":["/*\n * Copyright 2025 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n\nimport {CalendarDate, CalendarDateTime, parseDate, parseDateTime} from '@internationalized/date';\nimport {DateFieldState, DatePickerState, DateSegmentType} from 'react-stately';\nimport React, {ReactNode} from 'react';\nimport {useVisuallyHidden} from 'react-aria';\n\ninterface AriaHiddenDateInputProps {\n /**\n * Describes the type of autocomplete functionality the input should provide if any. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdefautocomplete).\n */\n autoComplete?: string,\n /** HTML form input name. */\n name?: string,\n /** Sets the disabled state of the input. */\n isDisabled?: boolean\n}\n\ninterface HiddenDateInputProps extends AriaHiddenDateInputProps {\n /**\n * State for the input.\n */\n state: DateFieldState | DatePickerState\n}\n\nexport interface HiddenDateAria {\n /** Props for the container element. */\n containerProps: React.HTMLAttributes<HTMLDivElement>,\n /** Props for the hidden input element. */\n inputProps: React.InputHTMLAttributes<HTMLInputElement>\n}\n\nconst dateSegments = ['day', 'month', 'year'];\nconst granularityMap = {'hour': 1, 'minute': 2, 'second': 3};\n\nexport function useHiddenDateInput(props: HiddenDateInputProps, state: DateFieldState | DatePickerState) : HiddenDateAria {\n let {\n autoComplete,\n isDisabled,\n name\n } = props;\n let {visuallyHiddenProps} = useVisuallyHidden({\n style: {\n // Prevent page scrolling.\n position: 'fixed',\n top: 0,\n left: 0\n }\n });\n\n let inputStep = 60;\n if (state.granularity === 'second') {\n inputStep = 1;\n } else if (state.granularity === 'hour') {\n inputStep = 3600; \n }\n\n let dateValue = state.value == null ? '' : state.value.toString();\n\n let inputType = state.granularity === 'day' ? 'date' : 'datetime-local';\n\n let timeSegments = ['hour', 'minute', 'second'];\n // Depending on the granularity, we only want to validate certain time segments\n let end = 0;\n if (timeSegments.includes(state.granularity)) {\n end = granularityMap[state.granularity];\n timeSegments = timeSegments.slice(0, end);\n }\n\n return {\n containerProps: {\n ...visuallyHiddenProps,\n 'aria-hidden': true,\n // @ts-ignore\n ['data-react-aria-prevent-focus']: true,\n // @ts-ignore\n ['data-a11y-ignore']: 'aria-hidden-focus'\n },\n inputProps: {\n tabIndex: -1,\n autoComplete,\n disabled: isDisabled,\n type: inputType,\n // We set the form prop to an empty string to prevent the hidden date input's value from being submitted\n form: '',\n name,\n step: inputStep,\n value: dateValue,\n onChange: (e) => {\n let targetString = e.target.value.toString();\n if (targetString) {\n try {\n let targetValue: CalendarDateTime | CalendarDate = parseDateTime(targetString);\n if (state.granularity === 'day') {\n targetValue = parseDate(targetString);\n }\n // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.\n // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.\n // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue \n // which is why in the code below we first set each segment to validate it before committing the new value. \n // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to \n // set a new value when the field itself is empty.\n if ('setSegment' in state) {\n for (let type in targetValue) {\n if (dateSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n if (timeSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n }\n }\n state.setValue(targetValue);\n } catch {\n // ignore\n }\n }\n }\n }\n };\n}\n\nexport function HiddenDateInput(props: HiddenDateInputProps): ReactNode | null {\n let {state} = props;\n let {containerProps, inputProps} = useHiddenDateInput({...props}, state);\n return (\n <div {...containerProps} data-testid=\"hidden-dateinput-container\">\n <input {...inputProps} />\n </div>\n );\n}\n"],"names":[],"version":3,"file":"HiddenDateInput.main.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;AAiCD,MAAM,qCAAe;IAAC;IAAO;IAAS;CAAO;AAC7C,MAAM,uCAAiB;IAAC,QAAQ;IAAG,UAAU;IAAG,UAAU;AAAC;AAEpD,SAAS,0CAAmB,KAA2B,EAAE,KAAuC;IACrG,IAAI,gBACF,YAAY,cACZ,UAAU,QACV,IAAI,EACL,GAAG;IACJ,IAAI,uBAAC,mBAAmB,EAAC,GAAG,CAAA,GAAA,kCAAgB,EAAE;QAC5C,OAAO;YACL,0BAA0B;YAC1B,UAAU;YACV,KAAK;YACL,MAAM;QACR;IACF;IAEA,IAAI,YAAY;IAChB,IAAI,MAAM,WAAW,KAAK,UACxB,YAAY;SACP,IAAI,MAAM,WAAW,KAAK,QAC/B,YAAY;IAGd,IAAI,YAAY,MAAM,KAAK,IAAI,OAAO,KAAK,MAAM,KAAK,CAAC,QAAQ;IAE/D,IAAI,YAAY,MAAM,WAAW,KAAK,QAAQ,SAAS;IAEvD,IAAI,eAAe;QAAC;QAAQ;QAAU;KAAS;IAC/C,+EAA+E;IAC/E,IAAI,MAAM;IACV,IAAI,aAAa,QAAQ,CAAC,MAAM,WAAW,GAAG;QAC5C,MAAM,oCAAc,CAAC,MAAM,WAAW,CAAC;QACvC,eAAe,aAAa,KAAK,CAAC,GAAG;IACvC;IAEA,OAAO;QACL,gBAAgB;YACd,GAAG,mBAAmB;YACtB,eAAe;YACf,aAAa;YACb,CAAC,gCAAgC,EAAE;YACnC,aAAa;YACb,CAAC,mBAAmB,EAAE;QACxB;QACA,YAAY;YACV,UAAU;0BACV;YACA,UAAU;YACV,MAAM;YACN,wGAAwG;YACxG,MAAM;kBACN;YACA,MAAM;YACN,OAAO;YACP,UAAU,CAAC;gBACT,IAAI,eAAe,EAAE,MAAM,CAAC,KAAK,CAAC,QAAQ;gBAC1C,IAAI,cACF,IAAI;oBACF,IAAI,cAA+C,CAAA,GAAA,0CAAY,EAAE;oBACjE,IAAI,MAAM,WAAW,KAAK,OACxB,cAAc,CAAA,GAAA,sCAAQ,EAAE;oBAE1B,uHAAuH;oBACvH,iHAAiH;oBACjH,oHAAoH;oBACpH,2GAA2G;oBAC3G,wHAAwH;oBACxH,kDAAkD;oBAClD,IAAI,gBAAgB,OAClB,IAAK,IAAI,QAAQ,YAAa;wBAC5B,qCAAqC;wBACrC,IAAI,mCAAa,QAAQ,CAAC,OACxB,MAAM,UAAU,CAAC,MAAyB,WAAW,CAAC,KAAK;wBAE7D,qCAAqC;wBACrC,IAAI,aAAa,QAAQ,CAAC,OACxB,MAAM,UAAU,CAAC,MAAyB,WAAW,CAAC,KAAK;oBAE/D;oBAEF,MAAM,QAAQ,CAAC;gBACjB,EAAE,OAAM;gBACN,SAAS;gBACX;YAEJ;QACF;IACF;AACF;AAEO,SAAS,0CAAgB,KAA2B;IACzD,IAAI,SAAC,KAAK,EAAC,GAAG;IACd,IAAI,kBAAC,cAAc,cAAE,UAAU,EAAC,GAAG,0CAAmB;QAAC,GAAG,KAAK;IAAA,GAAG;IAClE,qBACE,0DAAC;QAAK,GAAG,cAAc;QAAE,eAAY;qBACnC,0DAAC,SAAU;AAGjB","sources":["packages/react-aria-components/src/HiddenDateInput.tsx"],"sourcesContent":["/*\n * Copyright 2025 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n\nimport {CalendarDate, CalendarDateTime, parseDate, parseDateTime} from '@internationalized/date';\nimport {DateFieldState, DatePickerState, DateSegmentType} from 'react-stately';\nimport React, {ReactNode} from 'react';\nimport {useVisuallyHidden} from 'react-aria';\n\ninterface AriaHiddenDateInputProps {\n /**\n * Describes the type of autocomplete functionality the input should provide if any. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdefautocomplete).\n */\n autoComplete?: string,\n /** HTML form input name. */\n name?: string,\n /** Sets the disabled state of the input. */\n isDisabled?: boolean\n}\n\ninterface HiddenDateInputProps extends AriaHiddenDateInputProps {\n /**\n * State for the input.\n */\n state: DateFieldState | DatePickerState\n}\n\nexport interface HiddenDateAria {\n /** Props for the container element. */\n containerProps: React.HTMLAttributes<HTMLDivElement>,\n /** Props for the hidden input element. */\n inputProps: React.InputHTMLAttributes<HTMLInputElement>\n}\n\nconst dateSegments = ['day', 'month', 'year'];\nconst granularityMap = {'hour': 1, 'minute': 2, 'second': 3};\n\nexport function useHiddenDateInput(props: HiddenDateInputProps, state: DateFieldState | DatePickerState) : HiddenDateAria {\n let {\n autoComplete,\n isDisabled,\n name\n } = props;\n let {visuallyHiddenProps} = useVisuallyHidden({\n style: {\n // Prevent page scrolling.\n position: 'fixed',\n top: 0,\n left: 0\n }\n });\n\n let inputStep = 60;\n if (state.granularity === 'second') {\n inputStep = 1;\n } else if (state.granularity === 'hour') {\n inputStep = 3600;\n }\n\n let dateValue = state.value == null ? '' : state.value.toString();\n\n let inputType = state.granularity === 'day' ? 'date' : 'datetime-local';\n\n let timeSegments = ['hour', 'minute', 'second'];\n // Depending on the granularity, we only want to validate certain time segments\n let end = 0;\n if (timeSegments.includes(state.granularity)) {\n end = granularityMap[state.granularity];\n timeSegments = timeSegments.slice(0, end);\n }\n\n return {\n containerProps: {\n ...visuallyHiddenProps,\n 'aria-hidden': true,\n // @ts-ignore\n ['data-react-aria-prevent-focus']: true,\n // @ts-ignore\n ['data-a11y-ignore']: 'aria-hidden-focus'\n },\n inputProps: {\n tabIndex: -1,\n autoComplete,\n disabled: isDisabled,\n type: inputType,\n // We set the form prop to an empty string to prevent the hidden date input's value from being submitted\n form: '',\n name,\n step: inputStep,\n value: dateValue,\n onChange: (e) => {\n let targetString = e.target.value.toString();\n if (targetString) {\n try {\n let targetValue: CalendarDateTime | CalendarDate = parseDateTime(targetString);\n if (state.granularity === 'day') {\n targetValue = parseDate(targetString);\n }\n // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.\n // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.\n // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue\n // which is why in the code below we first set each segment to validate it before committing the new value.\n // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to\n // set a new value when the field itself is empty.\n if ('setSegment' in state) {\n for (let type in targetValue) {\n // eslint-disable-next-line max-depth\n if (dateSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n // eslint-disable-next-line max-depth\n if (timeSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n }\n }\n state.setValue(targetValue);\n } catch {\n // ignore\n }\n }\n }\n }\n };\n}\n\nexport function HiddenDateInput(props: HiddenDateInputProps): ReactNode | null {\n let {state} = props;\n let {containerProps, inputProps} = useHiddenDateInput({...props}, state);\n return (\n <div {...containerProps} data-testid=\"hidden-dateinput-container\">\n <input {...inputProps} />\n </div>\n );\n}\n"],"names":[],"version":3,"file":"HiddenDateInput.main.js.map"}
@@ -77,12 +77,14 @@ function $c699643d2073b351$export$f6a685cd1acbd1fa(props, state) {
77
77
  if (state.granularity === 'day') targetValue = (0, $62z4d$parseDate)(targetString);
78
78
  // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.
79
79
  // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.
80
- // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue
81
- // which is why in the code below we first set each segment to validate it before committing the new value.
82
- // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to
80
+ // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue
81
+ // which is why in the code below we first set each segment to validate it before committing the new value.
82
+ // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to
83
83
  // set a new value when the field itself is empty.
84
84
  if ('setSegment' in state) for(let type in targetValue){
85
+ // eslint-disable-next-line max-depth
85
86
  if ($c699643d2073b351$var$dateSegments.includes(type)) state.setSegment(type, targetValue[type]);
87
+ // eslint-disable-next-line max-depth
86
88
  if (timeSegments.includes(type)) state.setSegment(type, targetValue[type]);
87
89
  }
88
90
  state.setValue(targetValue);
@@ -77,12 +77,14 @@ function $c699643d2073b351$export$f6a685cd1acbd1fa(props, state) {
77
77
  if (state.granularity === 'day') targetValue = (0, $62z4d$parseDate)(targetString);
78
78
  // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.
79
79
  // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.
80
- // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue
81
- // which is why in the code below we first set each segment to validate it before committing the new value.
82
- // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to
80
+ // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue
81
+ // which is why in the code below we first set each segment to validate it before committing the new value.
82
+ // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to
83
83
  // set a new value when the field itself is empty.
84
84
  if ('setSegment' in state) for(let type in targetValue){
85
+ // eslint-disable-next-line max-depth
85
86
  if ($c699643d2073b351$var$dateSegments.includes(type)) state.setSegment(type, targetValue[type]);
87
+ // eslint-disable-next-line max-depth
86
88
  if (timeSegments.includes(type)) state.setSegment(type, targetValue[type]);
87
89
  }
88
90
  state.setValue(targetValue);
@@ -1 +1 @@
1
- {"mappings":";;;;AAAA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AAA,GAAA,gBAAQ,EAAE;oBAE1B,uHAAuH;oBACvH,iHAAiH;oBACjH,qHAAqH;oBACrH,4GAA4G;oBAC5G,yHAAyH;oBACzH,kDAAkD;oBAClD,IAAI,gBAAgB,OAClB,IAAK,IAAI,QAAQ,YAAa;wBAC5B,IAAI,mCAAa,QAAQ,CAAC,OACxB,MAAM,UAAU,CAAC,MAAyB,WAAW,CAAC,KAAK;wBAE7D,IAAI,aAAa,QAAQ,CAAC,OACxB,MAAM,UAAU,CAAC,MAAyB,WAAW,CAAC,KAAK;oBAE/D;oBAEF,MAAM,QAAQ,CAAC;gBACjB,EAAE,OAAM;gBACN,SAAS;gBACX;YAEJ;QACF;IACF;AACF;AAEO,SAAS,0CAAgB,KAA2B;IACzD,IAAI,SAAC,KAAK,EAAC,GAAG;IACd,IAAI,kBAAC,cAAc,cAAE,UAAU,EAAC,GAAG,0CAAmB;QAAC,GAAG,KAAK;IAAA,GAAG;IAClE,qBACE,gCAAC;QAAK,GAAG,cAAc;QAAE,eAAY;qBACnC,gCAAC,SAAU;AAGjB","sources":["packages/react-aria-components/src/HiddenDateInput.tsx"],"sourcesContent":["/*\n * Copyright 2025 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n\nimport {CalendarDate, CalendarDateTime, parseDate, parseDateTime} from '@internationalized/date';\nimport {DateFieldState, DatePickerState, DateSegmentType} from 'react-stately';\nimport React, {ReactNode} from 'react';\nimport {useVisuallyHidden} from 'react-aria';\n\ninterface AriaHiddenDateInputProps {\n /**\n * Describes the type of autocomplete functionality the input should provide if any. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdefautocomplete).\n */\n autoComplete?: string,\n /** HTML form input name. */\n name?: string,\n /** Sets the disabled state of the input. */\n isDisabled?: boolean\n}\n\ninterface HiddenDateInputProps extends AriaHiddenDateInputProps {\n /**\n * State for the input.\n */\n state: DateFieldState | DatePickerState\n}\n\nexport interface HiddenDateAria {\n /** Props for the container element. */\n containerProps: React.HTMLAttributes<HTMLDivElement>,\n /** Props for the hidden input element. */\n inputProps: React.InputHTMLAttributes<HTMLInputElement>\n}\n\nconst dateSegments = ['day', 'month', 'year'];\nconst granularityMap = {'hour': 1, 'minute': 2, 'second': 3};\n\nexport function useHiddenDateInput(props: HiddenDateInputProps, state: DateFieldState | DatePickerState) : HiddenDateAria {\n let {\n autoComplete,\n isDisabled,\n name\n } = props;\n let {visuallyHiddenProps} = useVisuallyHidden({\n style: {\n // Prevent page scrolling.\n position: 'fixed',\n top: 0,\n left: 0\n }\n });\n\n let inputStep = 60;\n if (state.granularity === 'second') {\n inputStep = 1;\n } else if (state.granularity === 'hour') {\n inputStep = 3600; \n }\n\n let dateValue = state.value == null ? '' : state.value.toString();\n\n let inputType = state.granularity === 'day' ? 'date' : 'datetime-local';\n\n let timeSegments = ['hour', 'minute', 'second'];\n // Depending on the granularity, we only want to validate certain time segments\n let end = 0;\n if (timeSegments.includes(state.granularity)) {\n end = granularityMap[state.granularity];\n timeSegments = timeSegments.slice(0, end);\n }\n\n return {\n containerProps: {\n ...visuallyHiddenProps,\n 'aria-hidden': true,\n // @ts-ignore\n ['data-react-aria-prevent-focus']: true,\n // @ts-ignore\n ['data-a11y-ignore']: 'aria-hidden-focus'\n },\n inputProps: {\n tabIndex: -1,\n autoComplete,\n disabled: isDisabled,\n type: inputType,\n // We set the form prop to an empty string to prevent the hidden date input's value from being submitted\n form: '',\n name,\n step: inputStep,\n value: dateValue,\n onChange: (e) => {\n let targetString = e.target.value.toString();\n if (targetString) {\n try {\n let targetValue: CalendarDateTime | CalendarDate = parseDateTime(targetString);\n if (state.granularity === 'day') {\n targetValue = parseDate(targetString);\n }\n // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.\n // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.\n // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue \n // which is why in the code below we first set each segment to validate it before committing the new value. \n // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to \n // set a new value when the field itself is empty.\n if ('setSegment' in state) {\n for (let type in targetValue) {\n if (dateSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n if (timeSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n }\n }\n state.setValue(targetValue);\n } catch {\n // ignore\n }\n }\n }\n }\n };\n}\n\nexport function HiddenDateInput(props: HiddenDateInputProps): ReactNode | null {\n let {state} = props;\n let {containerProps, inputProps} = useHiddenDateInput({...props}, state);\n return (\n <div {...containerProps} data-testid=\"hidden-dateinput-container\">\n <input {...inputProps} />\n </div>\n );\n}\n"],"names":[],"version":3,"file":"HiddenDateInput.module.js.map"}
1
+ {"mappings":";;;;AAAA;;;;;;;;;;CAUC;;;AAiCD,MAAM,qCAAe;IAAC;IAAO;IAAS;CAAO;AAC7C,MAAM,uCAAiB;IAAC,QAAQ;IAAG,UAAU;IAAG,UAAU;AAAC;AAEpD,SAAS,0CAAmB,KAA2B,EAAE,KAAuC;IACrG,IAAI,gBACF,YAAY,cACZ,UAAU,QACV,IAAI,EACL,GAAG;IACJ,IAAI,uBAAC,mBAAmB,EAAC,GAAG,CAAA,GAAA,wBAAgB,EAAE;QAC5C,OAAO;YACL,0BAA0B;YAC1B,UAAU;YACV,KAAK;YACL,MAAM;QACR;IACF;IAEA,IAAI,YAAY;IAChB,IAAI,MAAM,WAAW,KAAK,UACxB,YAAY;SACP,IAAI,MAAM,WAAW,KAAK,QAC/B,YAAY;IAGd,IAAI,YAAY,MAAM,KAAK,IAAI,OAAO,KAAK,MAAM,KAAK,CAAC,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IAAI,kBAAC,cAAc,cAAE,UAAU,EAAC,GAAG,0CAAmB;QAAC,GAAG,KAAK;IAAA,GAAG;IAClE,qBACE,gCAAC;QAAK,GAAG,cAAc;QAAE,eAAY;qBACnC,gCAAC,SAAU;AAGjB","sources":["packages/react-aria-components/src/HiddenDateInput.tsx"],"sourcesContent":["/*\n * Copyright 2025 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n\nimport {CalendarDate, CalendarDateTime, parseDate, parseDateTime} from '@internationalized/date';\nimport {DateFieldState, DatePickerState, DateSegmentType} from 'react-stately';\nimport React, {ReactNode} from 'react';\nimport {useVisuallyHidden} from 'react-aria';\n\ninterface AriaHiddenDateInputProps {\n /**\n * Describes the type of autocomplete functionality the input should provide if any. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdefautocomplete).\n */\n autoComplete?: string,\n /** HTML form input name. */\n name?: string,\n /** Sets the disabled state of the input. */\n isDisabled?: boolean\n}\n\ninterface HiddenDateInputProps extends AriaHiddenDateInputProps {\n /**\n * State for the input.\n */\n state: DateFieldState | DatePickerState\n}\n\nexport interface HiddenDateAria {\n /** Props for the container element. */\n containerProps: React.HTMLAttributes<HTMLDivElement>,\n /** Props for the hidden input element. */\n inputProps: React.InputHTMLAttributes<HTMLInputElement>\n}\n\nconst dateSegments = ['day', 'month', 'year'];\nconst granularityMap = {'hour': 1, 'minute': 2, 'second': 3};\n\nexport function useHiddenDateInput(props: HiddenDateInputProps, state: DateFieldState | DatePickerState) : HiddenDateAria {\n let {\n autoComplete,\n isDisabled,\n name\n } = props;\n let {visuallyHiddenProps} = useVisuallyHidden({\n style: {\n // Prevent page scrolling.\n position: 'fixed',\n top: 0,\n left: 0\n }\n });\n\n let inputStep = 60;\n if (state.granularity === 'second') {\n inputStep = 1;\n } else if (state.granularity === 'hour') {\n inputStep = 3600;\n }\n\n let dateValue = state.value == null ? '' : state.value.toString();\n\n let inputType = state.granularity === 'day' ? 'date' : 'datetime-local';\n\n let timeSegments = ['hour', 'minute', 'second'];\n // Depending on the granularity, we only want to validate certain time segments\n let end = 0;\n if (timeSegments.includes(state.granularity)) {\n end = granularityMap[state.granularity];\n timeSegments = timeSegments.slice(0, end);\n }\n\n return {\n containerProps: {\n ...visuallyHiddenProps,\n 'aria-hidden': true,\n // @ts-ignore\n ['data-react-aria-prevent-focus']: true,\n // @ts-ignore\n ['data-a11y-ignore']: 'aria-hidden-focus'\n },\n inputProps: {\n tabIndex: -1,\n autoComplete,\n disabled: isDisabled,\n type: inputType,\n // We set the form prop to an empty string to prevent the hidden date input's value from being submitted\n form: '',\n name,\n step: inputStep,\n value: dateValue,\n onChange: (e) => {\n let targetString = e.target.value.toString();\n if (targetString) {\n try {\n let targetValue: CalendarDateTime | CalendarDate = parseDateTime(targetString);\n if (state.granularity === 'day') {\n targetValue = parseDate(targetString);\n }\n // We check to to see if setSegment exists in the state since it only exists in DateFieldState and not DatePickerState.\n // The setValue method has different behavior depending on if it's coming from DateFieldState or DatePickerState.\n // In DateFieldState, setValue firsts checks to make sure that each segment is filled before committing the newValue\n // which is why in the code below we first set each segment to validate it before committing the new value.\n // However, in DatePickerState, since we have to be able to commit values from the Calendar popover, we are also able to\n // set a new value when the field itself is empty.\n if ('setSegment' in state) {\n for (let type in targetValue) {\n // eslint-disable-next-line max-depth\n if (dateSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n // eslint-disable-next-line max-depth\n if (timeSegments.includes(type)) {\n state.setSegment(type as DateSegmentType, targetValue[type]);\n }\n }\n }\n state.setValue(targetValue);\n } catch {\n // ignore\n }\n }\n }\n }\n };\n}\n\nexport function HiddenDateInput(props: HiddenDateInputProps): ReactNode | null {\n let {state} = props;\n let {containerProps, inputProps} = useHiddenDateInput({...props}, state);\n return (\n <div {...containerProps} data-testid=\"hidden-dateinput-container\">\n <input {...inputProps} />\n </div>\n );\n}\n"],"names":[],"version":3,"file":"HiddenDateInput.module.js.map"}
@@ -36,7 +36,10 @@ let $1bcfcef5af644e13$var$filterHoverProps = (props)=>{
36
36
  };
37
37
  const $1bcfcef5af644e13$export$f5b8910cec6cf069 = /*#__PURE__*/ (0, $fA2o8$reactariacollections.createHideableComponent)(function Input(props, ref) {
38
38
  [props, ref] = (0, $c5ccf687772c0422$exports.useContextProps)(props, ref, $1bcfcef5af644e13$export$37fb8590cf2c088c);
39
- let { hoverProps: hoverProps, isHovered: isHovered } = (0, $fA2o8$reactaria.useHover)(props);
39
+ let { hoverProps: hoverProps, isHovered: isHovered } = (0, $fA2o8$reactaria.useHover)({
40
+ ...props,
41
+ isDisabled: props.disabled
42
+ });
40
43
  let { isFocused: isFocused, isFocusVisible: isFocusVisible, focusProps: focusProps } = (0, $fA2o8$reactaria.useFocusRing)({
41
44
  isTextInput: true,
42
45
  autoFocus: props.autoFocus
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;AAqCM,MAAM,0DAAe,CAAA,GAAA,0BAAY,EAA8C,CAAC;AAEvF,IAAI,yCAAmB,CAAC;IACtB,6DAA6D;IAC7D,IAAI,gBAAC,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAC/D,OAAO;AACT;AAKO,MAAM,4CAAQ,WAAW,GAAG,CAAA,GAAA,mDAAsB,EAAE,SAAS,MAAM,KAAiB,EAAE,GAAmC;IAC9H,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAE3C,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,yBAAO,EAAE;IACvC,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,6BAAW,EAAE;QACzD,aAAa;QACb,WAAW,MAAM,SAAS;IAC5B;IAEA,IAAI,YAAY,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IACrE,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBACN;uBACA;4BACA;YACA,YAAY,MAAM,QAAQ,IAAI;uBAC9B;QACF;QACA,kBAAkB;IACpB;IAEA,qBACE,0DAAC;QACE,GAAG,CAAA,GAAA,2BAAS,EAAE,uCAAiB,QAAQ,YAAY,WAAW;QAC9D,GAAG,WAAW;QACf,KAAK;QACL,gBAAc,aAAa;QAC3B,iBAAe,MAAM,QAAQ,IAAI;QACjC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,gBAAc,aAAa;;AAEjC","sources":["packages/react-aria-components/src/Input.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 {ContextValue, StyleRenderProps, useContextProps, useRenderProps} from './utils';\nimport {createHideableComponent} from '@react-aria/collections';\nimport {HoverEvents, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, InputHTMLAttributes} from 'react';\n\nexport interface InputRenderProps {\n /**\n * Whether the input is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether the input is focused, either via a mouse or keyboard.\n * @selector [data-focused]\n */\n isFocused: boolean,\n /**\n * Whether the input is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the input is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the input is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'style'>, HoverEvents, StyleRenderProps<InputRenderProps> {}\n\nexport const InputContext = createContext<ContextValue<InputProps, HTMLInputElement>>({});\n\nlet filterHoverProps = (props: InputProps) => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n return otherProps;\n};\n\n/**\n * An input allows a user to input text.\n */\nexport const Input = /*#__PURE__*/ createHideableComponent(function Input(props: InputProps, ref: ForwardedRef<HTMLInputElement>) {\n [props, ref] = useContextProps(props, ref, InputContext);\n\n let {hoverProps, isHovered} = useHover(props);\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n isTextInput: true,\n autoFocus: props.autoFocus\n });\n\n let isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n let renderProps = useRenderProps({\n ...props,\n values: {\n isHovered,\n isFocused,\n isFocusVisible,\n isDisabled: props.disabled || false,\n isInvalid\n },\n defaultClassName: 'react-aria-Input'\n });\n\n return (\n <input\n {...mergeProps(filterHoverProps(props), focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n data-focused={isFocused || undefined}\n data-disabled={props.disabled || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-invalid={isInvalid || undefined} />\n );\n});\n"],"names":[],"version":3,"file":"Input.main.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;AAsDM,MAAM,0DAAe,CAAA,GAAA,0BAAY,EAA8C,CAAC;AAEvF,IAAI,yCAAmB,CAAC;IACtB,6DAA6D;IAC7D,IAAI,gBAAC,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAC/D,OAAO;AACT;AAKO,MAAM,4CAAQ,WAAW,GAAG,CAAA,GAAA,mDAAsB,EAAE,SAAS,MAAM,KAAiB,EAAE,GAAmC;IAC9H,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAE3C,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,yBAAO,EAAE;QACrC,GAAG,KAAK;QACR,YAAY,MAAM,QAAQ;IAC5B;IACA,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,6BAAW,EAAE;QACzD,aAAa;QACb,WAAW,MAAM,SAAS;IAC5B;IAEA,IAAI,YAAY,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IACrE,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBACN;uBACA;4BACA;YACA,YAAY,MAAM,QAAQ,IAAI;uBAC9B;QACF;QACA,kBAAkB;IACpB;IAEA,qBACE,0DAAC;QACE,GAAG,CAAA,GAAA,2BAAS,EAAE,uCAAiB,QAAQ,YAAY,WAAW;QAC9D,GAAG,WAAW;QACf,KAAK;QACL,gBAAc,aAAa;QAC3B,iBAAe,MAAM,QAAQ,IAAI;QACjC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,gBAAc,aAAa;;AAEjC","sources":["packages/react-aria-components/src/Input.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 {\n ClassNameOrFunction,\n ContextValue,\n StyleRenderProps,\n useContextProps,\n useRenderProps\n} from './utils';\nimport {createHideableComponent} from '@react-aria/collections';\nimport {HoverEvents, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, InputHTMLAttributes} from 'react';\n\nexport interface InputRenderProps {\n /**\n * Whether the input is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether the input is focused, either via a mouse or keyboard.\n * @selector [data-focused]\n */\n isFocused: boolean,\n /**\n * Whether the input is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the input is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the input is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'style'>, HoverEvents, StyleRenderProps<InputRenderProps> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element. A function may be provided to compute the class based on component state.\n * @default 'react-aria-Input'\n */\n className?: ClassNameOrFunction<InputRenderProps>,\n /**\n * Temporary text that occupies the text input when it is empty.\n * See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes/placeholder).\n */\n placeholder?: string\n}\n\nexport const InputContext = createContext<ContextValue<InputProps, HTMLInputElement>>({});\n\nlet filterHoverProps = (props: InputProps) => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n return otherProps;\n};\n\n/**\n * An input allows a user to input text.\n */\nexport const Input = /*#__PURE__*/ createHideableComponent(function Input(props: InputProps, ref: ForwardedRef<HTMLInputElement>) {\n [props, ref] = useContextProps(props, ref, InputContext);\n\n let {hoverProps, isHovered} = useHover({\n ...props,\n isDisabled: props.disabled\n });\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n isTextInput: true,\n autoFocus: props.autoFocus\n });\n\n let isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n let renderProps = useRenderProps({\n ...props,\n values: {\n isHovered,\n isFocused,\n isFocusVisible,\n isDisabled: props.disabled || false,\n isInvalid\n },\n defaultClassName: 'react-aria-Input'\n });\n\n return (\n <input\n {...mergeProps(filterHoverProps(props), focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n data-focused={isFocused || undefined}\n data-disabled={props.disabled || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-invalid={isInvalid || undefined} />\n );\n});\n"],"names":[],"version":3,"file":"Input.main.js.map"}
package/dist/Input.mjs CHANGED
@@ -25,7 +25,10 @@ let $3985021b0ad6602f$var$filterHoverProps = (props)=>{
25
25
  };
26
26
  const $3985021b0ad6602f$export$f5b8910cec6cf069 = /*#__PURE__*/ (0, $jMZTB$createHideableComponent)(function Input(props, ref) {
27
27
  [props, ref] = (0, $64fa3d84918910a7$export$29f1550f4b0d4415)(props, ref, $3985021b0ad6602f$export$37fb8590cf2c088c);
28
- let { hoverProps: hoverProps, isHovered: isHovered } = (0, $jMZTB$useHover)(props);
28
+ let { hoverProps: hoverProps, isHovered: isHovered } = (0, $jMZTB$useHover)({
29
+ ...props,
30
+ isDisabled: props.disabled
31
+ });
29
32
  let { isFocused: isFocused, isFocusVisible: isFocusVisible, focusProps: focusProps } = (0, $jMZTB$useFocusRing)({
30
33
  isTextInput: true,
31
34
  autoFocus: props.autoFocus
@@ -25,7 +25,10 @@ let $3985021b0ad6602f$var$filterHoverProps = (props)=>{
25
25
  };
26
26
  const $3985021b0ad6602f$export$f5b8910cec6cf069 = /*#__PURE__*/ (0, $jMZTB$createHideableComponent)(function Input(props, ref) {
27
27
  [props, ref] = (0, $64fa3d84918910a7$export$29f1550f4b0d4415)(props, ref, $3985021b0ad6602f$export$37fb8590cf2c088c);
28
- let { hoverProps: hoverProps, isHovered: isHovered } = (0, $jMZTB$useHover)(props);
28
+ let { hoverProps: hoverProps, isHovered: isHovered } = (0, $jMZTB$useHover)({
29
+ ...props,
30
+ isDisabled: props.disabled
31
+ });
29
32
  let { isFocused: isFocused, isFocusVisible: isFocusVisible, focusProps: focusProps } = (0, $jMZTB$useFocusRing)({
30
33
  isTextInput: true,
31
34
  autoFocus: props.autoFocus
@@ -1 +1 @@
1
- {"mappings":";;;;;AAAA;;;;;;;;;;CAUC;;;;AAqCM,MAAM,0DAAe,CAAA,GAAA,oBAAY,EAA8C,CAAC;AAEvF,IAAI,yCAAmB,CAAC;IACtB,6DAA6D;IAC7D,IAAI,gBAAC,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAC/D,OAAO;AACT;AAKO,MAAM,4CAAQ,WAAW,GAAG,CAAA,GAAA,8BAAsB,EAAE,SAAS,MAAM,KAAiB,EAAE,GAAmC;IAC9H,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAE3C,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,eAAO,EAAE;IACvC,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,mBAAW,EAAE;QACzD,aAAa;QACb,WAAW,MAAM,SAAS;IAC5B;IAEA,IAAI,YAAY,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IACrE,IAAI,cAAc,CAAA,GAAA,uCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBACN;uBACA;4BACA;YACA,YAAY,MAAM,QAAQ,IAAI;uBAC9B;QACF;QACA,kBAAkB;IACpB;IAEA,qBACE,gCAAC;QACE,GAAG,CAAA,GAAA,iBAAS,EAAE,uCAAiB,QAAQ,YAAY,WAAW;QAC9D,GAAG,WAAW;QACf,KAAK;QACL,gBAAc,aAAa;QAC3B,iBAAe,MAAM,QAAQ,IAAI;QACjC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,gBAAc,aAAa;;AAEjC","sources":["packages/react-aria-components/src/Input.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 {ContextValue, StyleRenderProps, useContextProps, useRenderProps} from './utils';\nimport {createHideableComponent} from '@react-aria/collections';\nimport {HoverEvents, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, InputHTMLAttributes} from 'react';\n\nexport interface InputRenderProps {\n /**\n * Whether the input is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether the input is focused, either via a mouse or keyboard.\n * @selector [data-focused]\n */\n isFocused: boolean,\n /**\n * Whether the input is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the input is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the input is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'style'>, HoverEvents, StyleRenderProps<InputRenderProps> {}\n\nexport const InputContext = createContext<ContextValue<InputProps, HTMLInputElement>>({});\n\nlet filterHoverProps = (props: InputProps) => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n return otherProps;\n};\n\n/**\n * An input allows a user to input text.\n */\nexport const Input = /*#__PURE__*/ createHideableComponent(function Input(props: InputProps, ref: ForwardedRef<HTMLInputElement>) {\n [props, ref] = useContextProps(props, ref, InputContext);\n\n let {hoverProps, isHovered} = useHover(props);\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n isTextInput: true,\n autoFocus: props.autoFocus\n });\n\n let isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n let renderProps = useRenderProps({\n ...props,\n values: {\n isHovered,\n isFocused,\n isFocusVisible,\n isDisabled: props.disabled || false,\n isInvalid\n },\n defaultClassName: 'react-aria-Input'\n });\n\n return (\n <input\n {...mergeProps(filterHoverProps(props), focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n data-focused={isFocused || undefined}\n data-disabled={props.disabled || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-invalid={isInvalid || undefined} />\n );\n});\n"],"names":[],"version":3,"file":"Input.module.js.map"}
1
+ {"mappings":";;;;;AAAA;;;;;;;;;;CAUC;;;;AAsDM,MAAM,0DAAe,CAAA,GAAA,oBAAY,EAA8C,CAAC;AAEvF,IAAI,yCAAmB,CAAC;IACtB,6DAA6D;IAC7D,IAAI,gBAAC,YAAY,iBAAE,aAAa,cAAE,UAAU,EAAE,GAAG,YAAW,GAAG;IAC/D,OAAO;AACT;AAKO,MAAM,4CAAQ,WAAW,GAAG,CAAA,GAAA,8BAAsB,EAAE,SAAS,MAAM,KAAiB,EAAE,GAAmC;IAC9H,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAE3C,IAAI,cAAC,UAAU,aAAE,SAAS,EAAC,GAAG,CAAA,GAAA,eAAO,EAAE;QACrC,GAAG,KAAK;QACR,YAAY,MAAM,QAAQ;IAC5B;IACA,IAAI,aAAC,SAAS,kBAAE,cAAc,cAAE,UAAU,EAAC,GAAG,CAAA,GAAA,mBAAW,EAAE;QACzD,aAAa;QACb,WAAW,MAAM,SAAS;IAC5B;IAEA,IAAI,YAAY,CAAC,CAAC,KAAK,CAAC,eAAe,IAAI,KAAK,CAAC,eAAe,KAAK;IACrE,IAAI,cAAc,CAAA,GAAA,uCAAa,EAAE;QAC/B,GAAG,KAAK;QACR,QAAQ;uBACN;uBACA;4BACA;YACA,YAAY,MAAM,QAAQ,IAAI;uBAC9B;QACF;QACA,kBAAkB;IACpB;IAEA,qBACE,gCAAC;QACE,GAAG,CAAA,GAAA,iBAAS,EAAE,uCAAiB,QAAQ,YAAY,WAAW;QAC9D,GAAG,WAAW;QACf,KAAK;QACL,gBAAc,aAAa;QAC3B,iBAAe,MAAM,QAAQ,IAAI;QACjC,gBAAc,aAAa;QAC3B,sBAAoB,kBAAkB;QACtC,gBAAc,aAAa;;AAEjC","sources":["packages/react-aria-components/src/Input.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 {\n ClassNameOrFunction,\n ContextValue,\n StyleRenderProps,\n useContextProps,\n useRenderProps\n} from './utils';\nimport {createHideableComponent} from '@react-aria/collections';\nimport {HoverEvents, mergeProps, useFocusRing, useHover} from 'react-aria';\nimport React, {createContext, ForwardedRef, InputHTMLAttributes} from 'react';\n\nexport interface InputRenderProps {\n /**\n * Whether the input is currently hovered with a mouse.\n * @selector [data-hovered]\n */\n isHovered: boolean,\n /**\n * Whether the input is focused, either via a mouse or keyboard.\n * @selector [data-focused]\n */\n isFocused: boolean,\n /**\n * Whether the input is keyboard focused.\n * @selector [data-focus-visible]\n */\n isFocusVisible: boolean,\n /**\n * Whether the input is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean,\n /**\n * Whether the input is invalid.\n * @selector [data-invalid]\n */\n isInvalid: boolean\n}\n\nexport interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'style'>, HoverEvents, StyleRenderProps<InputRenderProps> {\n /**\n * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the element. A function may be provided to compute the class based on component state.\n * @default 'react-aria-Input'\n */\n className?: ClassNameOrFunction<InputRenderProps>,\n /**\n * Temporary text that occupies the text input when it is empty.\n * See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes/placeholder).\n */\n placeholder?: string\n}\n\nexport const InputContext = createContext<ContextValue<InputProps, HTMLInputElement>>({});\n\nlet filterHoverProps = (props: InputProps) => {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {onHoverStart, onHoverChange, onHoverEnd, ...otherProps} = props;\n return otherProps;\n};\n\n/**\n * An input allows a user to input text.\n */\nexport const Input = /*#__PURE__*/ createHideableComponent(function Input(props: InputProps, ref: ForwardedRef<HTMLInputElement>) {\n [props, ref] = useContextProps(props, ref, InputContext);\n\n let {hoverProps, isHovered} = useHover({\n ...props,\n isDisabled: props.disabled\n });\n let {isFocused, isFocusVisible, focusProps} = useFocusRing({\n isTextInput: true,\n autoFocus: props.autoFocus\n });\n\n let isInvalid = !!props['aria-invalid'] && props['aria-invalid'] !== 'false';\n let renderProps = useRenderProps({\n ...props,\n values: {\n isHovered,\n isFocused,\n isFocusVisible,\n isDisabled: props.disabled || false,\n isInvalid\n },\n defaultClassName: 'react-aria-Input'\n });\n\n return (\n <input\n {...mergeProps(filterHoverProps(props), focusProps, hoverProps)}\n {...renderProps}\n ref={ref}\n data-focused={isFocused || undefined}\n data-disabled={props.disabled || undefined}\n data-hovered={isHovered || undefined}\n data-focus-visible={isFocusVisible || undefined}\n data-invalid={isInvalid || undefined} />\n );\n});\n"],"names":[],"version":3,"file":"Input.module.js.map"}