@react-aria/steplist 3.0.0-alpha.25 → 3.0.0-alpha.26

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 (197) hide show
  1. package/dist/import.mjs +3 -3
  2. package/dist/main.js +4 -4
  3. package/dist/main.js.map +1 -1
  4. package/dist/module.js +3 -3
  5. package/dist/module.js.map +1 -1
  6. package/dist/types/src/index.d.ts +4 -0
  7. package/package.json +15 -16
  8. package/src/index.ts +4 -4
  9. package/dist/ar-AE.main.js +0 -6
  10. package/dist/ar-AE.main.js.map +0 -1
  11. package/dist/ar-AE.mjs +0 -8
  12. package/dist/ar-AE.module.js +0 -8
  13. package/dist/ar-AE.module.js.map +0 -1
  14. package/dist/bg-BG.main.js +0 -6
  15. package/dist/bg-BG.main.js.map +0 -1
  16. package/dist/bg-BG.mjs +0 -8
  17. package/dist/bg-BG.module.js +0 -8
  18. package/dist/bg-BG.module.js.map +0 -1
  19. package/dist/cs-CZ.main.js +0 -6
  20. package/dist/cs-CZ.main.js.map +0 -1
  21. package/dist/cs-CZ.mjs +0 -8
  22. package/dist/cs-CZ.module.js +0 -8
  23. package/dist/cs-CZ.module.js.map +0 -1
  24. package/dist/da-DK.main.js +0 -6
  25. package/dist/da-DK.main.js.map +0 -1
  26. package/dist/da-DK.mjs +0 -8
  27. package/dist/da-DK.module.js +0 -8
  28. package/dist/da-DK.module.js.map +0 -1
  29. package/dist/de-DE.main.js +0 -6
  30. package/dist/de-DE.main.js.map +0 -1
  31. package/dist/de-DE.mjs +0 -8
  32. package/dist/de-DE.module.js +0 -8
  33. package/dist/de-DE.module.js.map +0 -1
  34. package/dist/el-GR.main.js +0 -6
  35. package/dist/el-GR.main.js.map +0 -1
  36. package/dist/el-GR.mjs +0 -8
  37. package/dist/el-GR.module.js +0 -8
  38. package/dist/el-GR.module.js.map +0 -1
  39. package/dist/en-US.main.js +0 -6
  40. package/dist/en-US.main.js.map +0 -1
  41. package/dist/en-US.mjs +0 -8
  42. package/dist/en-US.module.js +0 -8
  43. package/dist/en-US.module.js.map +0 -1
  44. package/dist/es-ES.main.js +0 -6
  45. package/dist/es-ES.main.js.map +0 -1
  46. package/dist/es-ES.mjs +0 -8
  47. package/dist/es-ES.module.js +0 -8
  48. package/dist/es-ES.module.js.map +0 -1
  49. package/dist/et-EE.main.js +0 -6
  50. package/dist/et-EE.main.js.map +0 -1
  51. package/dist/et-EE.mjs +0 -8
  52. package/dist/et-EE.module.js +0 -8
  53. package/dist/et-EE.module.js.map +0 -1
  54. package/dist/fi-FI.main.js +0 -6
  55. package/dist/fi-FI.main.js.map +0 -1
  56. package/dist/fi-FI.mjs +0 -8
  57. package/dist/fi-FI.module.js +0 -8
  58. package/dist/fi-FI.module.js.map +0 -1
  59. package/dist/fr-FR.main.js +0 -6
  60. package/dist/fr-FR.main.js.map +0 -1
  61. package/dist/fr-FR.mjs +0 -8
  62. package/dist/fr-FR.module.js +0 -8
  63. package/dist/fr-FR.module.js.map +0 -1
  64. package/dist/he-IL.main.js +0 -6
  65. package/dist/he-IL.main.js.map +0 -1
  66. package/dist/he-IL.mjs +0 -8
  67. package/dist/he-IL.module.js +0 -8
  68. package/dist/he-IL.module.js.map +0 -1
  69. package/dist/hr-HR.main.js +0 -6
  70. package/dist/hr-HR.main.js.map +0 -1
  71. package/dist/hr-HR.mjs +0 -8
  72. package/dist/hr-HR.module.js +0 -8
  73. package/dist/hr-HR.module.js.map +0 -1
  74. package/dist/hu-HU.main.js +0 -6
  75. package/dist/hu-HU.main.js.map +0 -1
  76. package/dist/hu-HU.mjs +0 -8
  77. package/dist/hu-HU.module.js +0 -8
  78. package/dist/hu-HU.module.js.map +0 -1
  79. package/dist/intlStrings.main.js +0 -108
  80. package/dist/intlStrings.main.js.map +0 -1
  81. package/dist/intlStrings.mjs +0 -110
  82. package/dist/intlStrings.module.js +0 -110
  83. package/dist/intlStrings.module.js.map +0 -1
  84. package/dist/it-IT.main.js +0 -6
  85. package/dist/it-IT.main.js.map +0 -1
  86. package/dist/it-IT.mjs +0 -8
  87. package/dist/it-IT.module.js +0 -8
  88. package/dist/it-IT.module.js.map +0 -1
  89. package/dist/ja-JP.main.js +0 -6
  90. package/dist/ja-JP.main.js.map +0 -1
  91. package/dist/ja-JP.mjs +0 -8
  92. package/dist/ja-JP.module.js +0 -8
  93. package/dist/ja-JP.module.js.map +0 -1
  94. package/dist/ko-KR.main.js +0 -6
  95. package/dist/ko-KR.main.js.map +0 -1
  96. package/dist/ko-KR.mjs +0 -8
  97. package/dist/ko-KR.module.js +0 -8
  98. package/dist/ko-KR.module.js.map +0 -1
  99. package/dist/lt-LT.main.js +0 -6
  100. package/dist/lt-LT.main.js.map +0 -1
  101. package/dist/lt-LT.mjs +0 -8
  102. package/dist/lt-LT.module.js +0 -8
  103. package/dist/lt-LT.module.js.map +0 -1
  104. package/dist/lv-LV.main.js +0 -6
  105. package/dist/lv-LV.main.js.map +0 -1
  106. package/dist/lv-LV.mjs +0 -8
  107. package/dist/lv-LV.module.js +0 -8
  108. package/dist/lv-LV.module.js.map +0 -1
  109. package/dist/nb-NO.main.js +0 -6
  110. package/dist/nb-NO.main.js.map +0 -1
  111. package/dist/nb-NO.mjs +0 -8
  112. package/dist/nb-NO.module.js +0 -8
  113. package/dist/nb-NO.module.js.map +0 -1
  114. package/dist/nl-NL.main.js +0 -6
  115. package/dist/nl-NL.main.js.map +0 -1
  116. package/dist/nl-NL.mjs +0 -8
  117. package/dist/nl-NL.module.js +0 -8
  118. package/dist/nl-NL.module.js.map +0 -1
  119. package/dist/pl-PL.main.js +0 -6
  120. package/dist/pl-PL.main.js.map +0 -1
  121. package/dist/pl-PL.mjs +0 -8
  122. package/dist/pl-PL.module.js +0 -8
  123. package/dist/pl-PL.module.js.map +0 -1
  124. package/dist/pt-BR.main.js +0 -6
  125. package/dist/pt-BR.main.js.map +0 -1
  126. package/dist/pt-BR.mjs +0 -8
  127. package/dist/pt-BR.module.js +0 -8
  128. package/dist/pt-BR.module.js.map +0 -1
  129. package/dist/pt-PT.main.js +0 -6
  130. package/dist/pt-PT.main.js.map +0 -1
  131. package/dist/pt-PT.mjs +0 -8
  132. package/dist/pt-PT.module.js +0 -8
  133. package/dist/pt-PT.module.js.map +0 -1
  134. package/dist/ro-RO.main.js +0 -6
  135. package/dist/ro-RO.main.js.map +0 -1
  136. package/dist/ro-RO.mjs +0 -8
  137. package/dist/ro-RO.module.js +0 -8
  138. package/dist/ro-RO.module.js.map +0 -1
  139. package/dist/ru-RU.main.js +0 -6
  140. package/dist/ru-RU.main.js.map +0 -1
  141. package/dist/ru-RU.mjs +0 -8
  142. package/dist/ru-RU.module.js +0 -8
  143. package/dist/ru-RU.module.js.map +0 -1
  144. package/dist/sk-SK.main.js +0 -6
  145. package/dist/sk-SK.main.js.map +0 -1
  146. package/dist/sk-SK.mjs +0 -8
  147. package/dist/sk-SK.module.js +0 -8
  148. package/dist/sk-SK.module.js.map +0 -1
  149. package/dist/sl-SI.main.js +0 -6
  150. package/dist/sl-SI.main.js.map +0 -1
  151. package/dist/sl-SI.mjs +0 -8
  152. package/dist/sl-SI.module.js +0 -8
  153. package/dist/sl-SI.module.js.map +0 -1
  154. package/dist/sr-SP.main.js +0 -6
  155. package/dist/sr-SP.main.js.map +0 -1
  156. package/dist/sr-SP.mjs +0 -8
  157. package/dist/sr-SP.module.js +0 -8
  158. package/dist/sr-SP.module.js.map +0 -1
  159. package/dist/sv-SE.main.js +0 -6
  160. package/dist/sv-SE.main.js.map +0 -1
  161. package/dist/sv-SE.mjs +0 -8
  162. package/dist/sv-SE.module.js +0 -8
  163. package/dist/sv-SE.module.js.map +0 -1
  164. package/dist/tr-TR.main.js +0 -6
  165. package/dist/tr-TR.main.js.map +0 -1
  166. package/dist/tr-TR.mjs +0 -8
  167. package/dist/tr-TR.module.js +0 -8
  168. package/dist/tr-TR.module.js.map +0 -1
  169. package/dist/types.d.ts +0 -23
  170. package/dist/types.d.ts.map +0 -1
  171. package/dist/uk-UA.main.js +0 -6
  172. package/dist/uk-UA.main.js.map +0 -1
  173. package/dist/uk-UA.mjs +0 -8
  174. package/dist/uk-UA.module.js +0 -8
  175. package/dist/uk-UA.module.js.map +0 -1
  176. package/dist/useStepList.main.js +0 -54
  177. package/dist/useStepList.main.js.map +0 -1
  178. package/dist/useStepList.mjs +0 -49
  179. package/dist/useStepList.module.js +0 -49
  180. package/dist/useStepList.module.js.map +0 -1
  181. package/dist/useStepListItem.main.js +0 -53
  182. package/dist/useStepListItem.main.js.map +0 -1
  183. package/dist/useStepListItem.mjs +0 -48
  184. package/dist/useStepListItem.module.js +0 -48
  185. package/dist/useStepListItem.module.js.map +0 -1
  186. package/dist/zh-CN.main.js +0 -6
  187. package/dist/zh-CN.main.js.map +0 -1
  188. package/dist/zh-CN.mjs +0 -8
  189. package/dist/zh-CN.module.js +0 -8
  190. package/dist/zh-CN.module.js.map +0 -1
  191. package/dist/zh-TW.main.js +0 -6
  192. package/dist/zh-TW.main.js.map +0 -1
  193. package/dist/zh-TW.mjs +0 -8
  194. package/dist/zh-TW.module.js +0 -8
  195. package/dist/zh-TW.module.js.map +0 -1
  196. package/src/useStepList.ts +0 -53
  197. package/src/useStepListItem.ts +0 -67
@@ -1 +0,0 @@
1
- {"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;AAoBM,SAAS,0CAAmB,KAA4B,EAAE,KAAuB,EAAE,GAAkC;IAC1H,MAAM,OAAC,GAAG,EAAC,GAAG;IACd,IAAI,EAAC,kBAAkB,OAAO,eAAE,WAAW,EAAC,GAAG;IAE/C,IAAI,aAAa,CAAC,MAAM,YAAY,CAAC;IAErC,IAAI,aAAC,SAAS,EAAC,GAAG,CAAA,GAAA,2CAAgB,EAAE;oBAClC;aACA;aACA;QACA,kBAAkB;IACpB;IAEA,MAAM,aAAa,gBAAgB;IAEnC,IAAI,YAAY,CAAC;YAQf;QAPA,MAAM,EAAC,KAAK,QAAQ,EAAC,GAAG;QAExB,IAAI,aAAa,eAAe,aAAa,WAAW;YACtD,MAAM,cAAc;YACpB,MAAM,eAAe;QACvB;SAEA,uBAAA,UAAU,SAAS,cAAnB,2CAAA,0BAAA,WAAsB;IACxB;IAEA,OAAO;QACL,WAAW;YACT,GAAG,SAAS;uBACZ;YACA,MAAM;YACN,gBAAgB,aAAa,SAAS;YACtC,iBAAiB,aAAa,OAAO;YACrC,UAAU,CAAC,aAAa,IAAI;QAC9B;IACF;AACF","sources":["packages/@react-aria/steplist/src/useStepListItem.ts"],"sourcesContent":["/*\n * Copyright 2023 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 {HTMLAttributes} from 'react';\nimport {Key, RefObject} from '@react-types/shared';\nimport {StepListState} from '@react-stately/steplist';\nimport {useSelectableItem} from '@react-aria/selection';\n\nexport interface AriaStepListItemProps {\n key: Key\n}\n\nexport interface StepListItemAria {\n /** Props for the step link element. */\n stepProps: HTMLAttributes<HTMLElement>,\n /** Props for the visually hidden element indicating the step state. */\n stepStateProps?: HTMLAttributes<HTMLElement>,\n /** Text content for the visually hidden message indicating the status of the step state. */\n stepStateText?: String\n}\n\nexport function useStepListItem<T>(props: AriaStepListItemProps, state: StepListState<T>, ref: RefObject<HTMLElement | null>): StepListItemAria {\n const {key} = props;\n let {selectionManager: manager, selectedKey} = state;\n\n let isDisabled = !state.isSelectable(key);\n\n let {itemProps} = useSelectableItem({\n isDisabled,\n key,\n ref,\n selectionManager: manager\n });\n\n const isSelected = selectedKey === key;\n\n let onKeyDown = (event) => {\n const {key: eventKey} = event;\n\n if (eventKey === 'ArrowDown' || eventKey === 'ArrowUp') {\n event.preventDefault();\n event.stopPropagation();\n }\n\n itemProps.onKeyDown?.(event);\n };\n\n return {\n stepProps: {\n ...itemProps,\n onKeyDown,\n role: 'link',\n 'aria-current': isSelected ? 'step' : undefined,\n 'aria-disabled': isDisabled ? true : undefined,\n tabIndex: !isDisabled ? 0 : undefined\n }\n };\n}\n"],"names":[],"version":3,"file":"useStepListItem.main.js.map"}
@@ -1,48 +0,0 @@
1
- import {useSelectableItem as $12xzF$useSelectableItem} from "@react-aria/selection";
2
-
3
- /*
4
- * Copyright 2023 Adobe. All rights reserved.
5
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License. You may obtain a copy
7
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
8
- *
9
- * Unless required by applicable law or agreed to in writing, software distributed under
10
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
11
- * OF ANY KIND, either express or implied. See the License for the specific language
12
- * governing permissions and limitations under the License.
13
- */
14
- function $dd7f9f4bee5b11b8$export$fd9dc107b7325b53(props, state, ref) {
15
- const { key: key } = props;
16
- let { selectionManager: manager, selectedKey: selectedKey } = state;
17
- let isDisabled = !state.isSelectable(key);
18
- let { itemProps: itemProps } = (0, $12xzF$useSelectableItem)({
19
- isDisabled: isDisabled,
20
- key: key,
21
- ref: ref,
22
- selectionManager: manager
23
- });
24
- const isSelected = selectedKey === key;
25
- let onKeyDown = (event)=>{
26
- var _itemProps_onKeyDown;
27
- const { key: eventKey } = event;
28
- if (eventKey === 'ArrowDown' || eventKey === 'ArrowUp') {
29
- event.preventDefault();
30
- event.stopPropagation();
31
- }
32
- (_itemProps_onKeyDown = itemProps.onKeyDown) === null || _itemProps_onKeyDown === void 0 ? void 0 : _itemProps_onKeyDown.call(itemProps, event);
33
- };
34
- return {
35
- stepProps: {
36
- ...itemProps,
37
- onKeyDown: onKeyDown,
38
- role: 'link',
39
- 'aria-current': isSelected ? 'step' : undefined,
40
- 'aria-disabled': isDisabled ? true : undefined,
41
- tabIndex: !isDisabled ? 0 : undefined
42
- }
43
- };
44
- }
45
-
46
-
47
- export {$dd7f9f4bee5b11b8$export$fd9dc107b7325b53 as useStepListItem};
48
- //# sourceMappingURL=useStepListItem.module.js.map
@@ -1,48 +0,0 @@
1
- import {useSelectableItem as $12xzF$useSelectableItem} from "@react-aria/selection";
2
-
3
- /*
4
- * Copyright 2023 Adobe. All rights reserved.
5
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License. You may obtain a copy
7
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
8
- *
9
- * Unless required by applicable law or agreed to in writing, software distributed under
10
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
11
- * OF ANY KIND, either express or implied. See the License for the specific language
12
- * governing permissions and limitations under the License.
13
- */
14
- function $dd7f9f4bee5b11b8$export$fd9dc107b7325b53(props, state, ref) {
15
- const { key: key } = props;
16
- let { selectionManager: manager, selectedKey: selectedKey } = state;
17
- let isDisabled = !state.isSelectable(key);
18
- let { itemProps: itemProps } = (0, $12xzF$useSelectableItem)({
19
- isDisabled: isDisabled,
20
- key: key,
21
- ref: ref,
22
- selectionManager: manager
23
- });
24
- const isSelected = selectedKey === key;
25
- let onKeyDown = (event)=>{
26
- var _itemProps_onKeyDown;
27
- const { key: eventKey } = event;
28
- if (eventKey === 'ArrowDown' || eventKey === 'ArrowUp') {
29
- event.preventDefault();
30
- event.stopPropagation();
31
- }
32
- (_itemProps_onKeyDown = itemProps.onKeyDown) === null || _itemProps_onKeyDown === void 0 ? void 0 : _itemProps_onKeyDown.call(itemProps, event);
33
- };
34
- return {
35
- stepProps: {
36
- ...itemProps,
37
- onKeyDown: onKeyDown,
38
- role: 'link',
39
- 'aria-current': isSelected ? 'step' : undefined,
40
- 'aria-disabled': isDisabled ? true : undefined,
41
- tabIndex: !isDisabled ? 0 : undefined
42
- }
43
- };
44
- }
45
-
46
-
47
- export {$dd7f9f4bee5b11b8$export$fd9dc107b7325b53 as useStepListItem};
48
- //# sourceMappingURL=useStepListItem.module.js.map
@@ -1 +0,0 @@
1
- {"mappings":";;AAAA;;;;;;;;;;CAUC;AAoBM,SAAS,0CAAmB,KAA4B,EAAE,KAAuB,EAAE,GAAkC;IAC1H,MAAM,OAAC,GAAG,EAAC,GAAG;IACd,IAAI,EAAC,kBAAkB,OAAO,eAAE,WAAW,EAAC,GAAG;IAE/C,IAAI,aAAa,CAAC,MAAM,YAAY,CAAC;IAErC,IAAI,aAAC,SAAS,EAAC,GAAG,CAAA,GAAA,wBAAgB,EAAE;oBAClC;aACA;aACA;QACA,kBAAkB;IACpB;IAEA,MAAM,aAAa,gBAAgB;IAEnC,IAAI,YAAY,CAAC;YAQf;QAPA,MAAM,EAAC,KAAK,QAAQ,EAAC,GAAG;QAExB,IAAI,aAAa,eAAe,aAAa,WAAW;YACtD,MAAM,cAAc;YACpB,MAAM,eAAe;QACvB;SAEA,uBAAA,UAAU,SAAS,cAAnB,2CAAA,0BAAA,WAAsB;IACxB;IAEA,OAAO;QACL,WAAW;YACT,GAAG,SAAS;uBACZ;YACA,MAAM;YACN,gBAAgB,aAAa,SAAS;YACtC,iBAAiB,aAAa,OAAO;YACrC,UAAU,CAAC,aAAa,IAAI;QAC9B;IACF;AACF","sources":["packages/@react-aria/steplist/src/useStepListItem.ts"],"sourcesContent":["/*\n * Copyright 2023 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 {HTMLAttributes} from 'react';\nimport {Key, RefObject} from '@react-types/shared';\nimport {StepListState} from '@react-stately/steplist';\nimport {useSelectableItem} from '@react-aria/selection';\n\nexport interface AriaStepListItemProps {\n key: Key\n}\n\nexport interface StepListItemAria {\n /** Props for the step link element. */\n stepProps: HTMLAttributes<HTMLElement>,\n /** Props for the visually hidden element indicating the step state. */\n stepStateProps?: HTMLAttributes<HTMLElement>,\n /** Text content for the visually hidden message indicating the status of the step state. */\n stepStateText?: String\n}\n\nexport function useStepListItem<T>(props: AriaStepListItemProps, state: StepListState<T>, ref: RefObject<HTMLElement | null>): StepListItemAria {\n const {key} = props;\n let {selectionManager: manager, selectedKey} = state;\n\n let isDisabled = !state.isSelectable(key);\n\n let {itemProps} = useSelectableItem({\n isDisabled,\n key,\n ref,\n selectionManager: manager\n });\n\n const isSelected = selectedKey === key;\n\n let onKeyDown = (event) => {\n const {key: eventKey} = event;\n\n if (eventKey === 'ArrowDown' || eventKey === 'ArrowUp') {\n event.preventDefault();\n event.stopPropagation();\n }\n\n itemProps.onKeyDown?.(event);\n };\n\n return {\n stepProps: {\n ...itemProps,\n onKeyDown,\n role: 'link',\n 'aria-current': isSelected ? 'step' : undefined,\n 'aria-disabled': isDisabled ? true : undefined,\n tabIndex: !isDisabled ? 0 : undefined\n }\n };\n}\n"],"names":[],"version":3,"file":"useStepListItem.module.js.map"}
@@ -1,6 +0,0 @@
1
- module.exports = {
2
- "steplist": `\u{6B65}\u{9AA4}\u{5217}\u{8868}`
3
- };
4
-
5
-
6
- //# sourceMappingURL=zh-CN.main.js.map
@@ -1 +0,0 @@
1
- {"mappings":"AAAA,iBAAiB;IAAG,YAAY,CAAC,gCAAI,CAAC;AACtC","sources":["packages/@react-aria/steplist/intl/zh-CN.json"],"sourcesContent":["{\n \"steplist\": \"步骤列表\"\n}\n"],"names":[],"version":3,"file":"zh-CN.main.js.map"}
package/dist/zh-CN.mjs DELETED
@@ -1,8 +0,0 @@
1
- var $149dc62f4be0749a$exports = {};
2
- $149dc62f4be0749a$exports = {
3
- "steplist": `\u{6B65}\u{9AA4}\u{5217}\u{8868}`
4
- };
5
-
6
-
7
- export {$149dc62f4be0749a$exports as default};
8
- //# sourceMappingURL=zh-CN.module.js.map
@@ -1,8 +0,0 @@
1
- var $149dc62f4be0749a$exports = {};
2
- $149dc62f4be0749a$exports = {
3
- "steplist": `\u{6B65}\u{9AA4}\u{5217}\u{8868}`
4
- };
5
-
6
-
7
- export {$149dc62f4be0749a$exports as default};
8
- //# sourceMappingURL=zh-CN.module.js.map
@@ -1 +0,0 @@
1
- {"mappings":";AAAA,4BAAiB;IAAG,YAAY,CAAC,gCAAI,CAAC;AACtC","sources":["packages/@react-aria/steplist/intl/zh-CN.json"],"sourcesContent":["{\n \"steplist\": \"步骤列表\"\n}\n"],"names":[],"version":3,"file":"zh-CN.module.js.map"}
@@ -1,6 +0,0 @@
1
- module.exports = {
2
- "steplist": `\u{6B65}\u{9A5F}\u{6E05}\u{55AE}`
3
- };
4
-
5
-
6
- //# sourceMappingURL=zh-TW.main.js.map
@@ -1 +0,0 @@
1
- {"mappings":"AAAA,iBAAiB;IAAG,YAAY,CAAC,gCAAI,CAAC;AACtC","sources":["packages/@react-aria/steplist/intl/zh-TW.json"],"sourcesContent":["{\n \"steplist\": \"步驟清單\"\n}\n"],"names":[],"version":3,"file":"zh-TW.main.js.map"}
package/dist/zh-TW.mjs DELETED
@@ -1,8 +0,0 @@
1
- var $a71aa6ab92482f8d$exports = {};
2
- $a71aa6ab92482f8d$exports = {
3
- "steplist": `\u{6B65}\u{9A5F}\u{6E05}\u{55AE}`
4
- };
5
-
6
-
7
- export {$a71aa6ab92482f8d$exports as default};
8
- //# sourceMappingURL=zh-TW.module.js.map
@@ -1,8 +0,0 @@
1
- var $a71aa6ab92482f8d$exports = {};
2
- $a71aa6ab92482f8d$exports = {
3
- "steplist": `\u{6B65}\u{9A5F}\u{6E05}\u{55AE}`
4
- };
5
-
6
-
7
- export {$a71aa6ab92482f8d$exports as default};
8
- //# sourceMappingURL=zh-TW.module.js.map
@@ -1 +0,0 @@
1
- {"mappings":";AAAA,4BAAiB;IAAG,YAAY,CAAC,gCAAI,CAAC;AACtC","sources":["packages/@react-aria/steplist/intl/zh-TW.json"],"sourcesContent":["{\n \"steplist\": \"步驟清單\"\n}\n"],"names":[],"version":3,"file":"zh-TW.module.js.map"}
@@ -1,53 +0,0 @@
1
- /*
2
- * Copyright 2023 Adobe. All rights reserved.
3
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- * you may not use this file except in compliance with the License. You may obtain a copy
5
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
6
- *
7
- * Unless required by applicable law or agreed to in writing, software distributed under
8
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- * OF ANY KIND, either express or implied. See the License for the specific language
10
- * governing permissions and limitations under the License.
11
- */
12
-
13
- import {AriaLabelingProps, DOMProps, RefObject} from '@react-types/shared';
14
- import {filterDOMProps, mergeProps} from '@react-aria/utils';
15
- import {HTMLAttributes} from 'react';
16
- // @ts-ignore
17
- import intlMessages from '../intl/*.json';
18
- import {StepListProps, StepListState} from '@react-stately/steplist';
19
- import {useLocalizedStringFormatter} from '@react-aria/i18n';
20
- import {useSelectableList} from '@react-aria/selection';
21
-
22
- export interface AriaStepListProps<T> extends StepListProps<T>, AriaLabelingProps, DOMProps {}
23
-
24
- export interface StepListAria {
25
- listProps: HTMLAttributes<HTMLElement>
26
- }
27
-
28
- export function useStepList<T>(props: AriaStepListProps<T>, state: StepListState<T>, ref: RefObject<HTMLOListElement | null>): StepListAria {
29
- let {
30
- 'aria-label': ariaLabel
31
- } = props;
32
- let {listProps} = useSelectableList({
33
- ...props,
34
- ...state,
35
- allowsTabNavigation: true,
36
- ref
37
- });
38
-
39
- const strings = useLocalizedStringFormatter(intlMessages, '@react-aria/steplist');
40
- const stepListProps: HTMLAttributes<HTMLElement> = {
41
- ...mergeProps(listProps, filterDOMProps(props, {labelable: true})),
42
- 'aria-label': ariaLabel || strings.format('steplist')
43
- };
44
-
45
- return {
46
- listProps: {
47
- ...stepListProps,
48
- tabIndex: undefined
49
- }
50
- };
51
- }
52
-
53
-
@@ -1,67 +0,0 @@
1
- /*
2
- * Copyright 2023 Adobe. All rights reserved.
3
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- * you may not use this file except in compliance with the License. You may obtain a copy
5
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
6
- *
7
- * Unless required by applicable law or agreed to in writing, software distributed under
8
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- * OF ANY KIND, either express or implied. See the License for the specific language
10
- * governing permissions and limitations under the License.
11
- */
12
-
13
- import {HTMLAttributes} from 'react';
14
- import {Key, RefObject} from '@react-types/shared';
15
- import {StepListState} from '@react-stately/steplist';
16
- import {useSelectableItem} from '@react-aria/selection';
17
-
18
- export interface AriaStepListItemProps {
19
- key: Key
20
- }
21
-
22
- export interface StepListItemAria {
23
- /** Props for the step link element. */
24
- stepProps: HTMLAttributes<HTMLElement>,
25
- /** Props for the visually hidden element indicating the step state. */
26
- stepStateProps?: HTMLAttributes<HTMLElement>,
27
- /** Text content for the visually hidden message indicating the status of the step state. */
28
- stepStateText?: String
29
- }
30
-
31
- export function useStepListItem<T>(props: AriaStepListItemProps, state: StepListState<T>, ref: RefObject<HTMLElement | null>): StepListItemAria {
32
- const {key} = props;
33
- let {selectionManager: manager, selectedKey} = state;
34
-
35
- let isDisabled = !state.isSelectable(key);
36
-
37
- let {itemProps} = useSelectableItem({
38
- isDisabled,
39
- key,
40
- ref,
41
- selectionManager: manager
42
- });
43
-
44
- const isSelected = selectedKey === key;
45
-
46
- let onKeyDown = (event) => {
47
- const {key: eventKey} = event;
48
-
49
- if (eventKey === 'ArrowDown' || eventKey === 'ArrowUp') {
50
- event.preventDefault();
51
- event.stopPropagation();
52
- }
53
-
54
- itemProps.onKeyDown?.(event);
55
- };
56
-
57
- return {
58
- stepProps: {
59
- ...itemProps,
60
- onKeyDown,
61
- role: 'link',
62
- 'aria-current': isSelected ? 'step' : undefined,
63
- 'aria-disabled': isDisabled ? true : undefined,
64
- tabIndex: !isDisabled ? 0 : undefined
65
- }
66
- };
67
- }