@react-aria/tag 3.0.0-nightly.1658 → 3.0.0-nightly.1663

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.
package/dist/main.js CHANGED
@@ -4,31 +4,16 @@ var $bSzeT$reactariai18n = require("@react-aria/i18n");
4
4
  var $bSzeT$react = require("react");
5
5
  var $bSzeT$reactariainteractions = require("@react-aria/interactions");
6
6
 
7
- function $parcel$exportWildcard(dest, source) {
8
- Object.keys(source).forEach(function(key) {
9
- if (key === 'default' || key === '__esModule' || dest.hasOwnProperty(key)) {
10
- return;
11
- }
12
-
13
- Object.defineProperty(dest, key, {
14
- enumerable: true,
15
- get: function get() {
16
- return source[key];
17
- }
18
- });
19
- });
20
-
21
- return dest;
22
- }
23
7
  function $parcel$export(e, n, v, s) {
24
8
  Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
25
9
  }
26
10
  function $parcel$interopDefault(a) {
27
11
  return a && a.__esModule ? a.default : a;
28
12
  }
29
- var $d3d7c73f2e3f4edb$exports = {};
30
13
 
31
- $parcel$export($d3d7c73f2e3f4edb$exports, "TagKeyboardDelegate", () => $d3d7c73f2e3f4edb$export$b00754732e683b92);
14
+ $parcel$export(module.exports, "TagKeyboardDelegate", () => $d3d7c73f2e3f4edb$export$b00754732e683b92);
15
+ $parcel$export(module.exports, "useTag", () => $a442534c81d8ad16$export$3f568fff7dff2f03);
16
+ $parcel$export(module.exports, "useTagGroup", () => $09704b0efefe5140$export$4f8b5cda58b7e8ff);
32
17
 
33
18
  class $d3d7c73f2e3f4edb$export$b00754732e683b92 extends $bSzeT$reactariagrid.GridKeyboardDelegate {
34
19
  getFirstKey() {
@@ -108,9 +93,6 @@ class $d3d7c73f2e3f4edb$export$b00754732e683b92 extends $bSzeT$reactariagrid.Gri
108
93
  }
109
94
 
110
95
 
111
- var $a442534c81d8ad16$exports = {};
112
-
113
- $parcel$export($a442534c81d8ad16$exports, "useTag", () => $a442534c81d8ad16$export$3f568fff7dff2f03);
114
96
 
115
97
  var $29abb9209b62cd49$exports = {};
116
98
  var $6a4ddf1abe55d42a$exports = {};
@@ -343,9 +325,6 @@ function $a442534c81d8ad16$export$3f568fff7dff2f03(props, state) {
343
325
  }
344
326
 
345
327
 
346
- var $09704b0efefe5140$exports = {};
347
-
348
- $parcel$export($09704b0efefe5140$exports, "useTagGroup", () => $09704b0efefe5140$export$4f8b5cda58b7e8ff);
349
328
 
350
329
 
351
330
 
@@ -373,9 +352,6 @@ function $09704b0efefe5140$export$4f8b5cda58b7e8ff(props, listState) {
373
352
  }
374
353
 
375
354
 
376
- $parcel$exportWildcard(module.exports, $d3d7c73f2e3f4edb$exports);
377
- $parcel$exportWildcard(module.exports, $a442534c81d8ad16$exports);
378
- $parcel$exportWildcard(module.exports, $09704b0efefe5140$exports);
379
355
 
380
356
 
381
357
  //# sourceMappingURL=main.js.map
package/dist/main.js.map CHANGED
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MCgBa,yCAAmB,SAAY,yCAAoB;IAC9D,WAAW,GAAG,CAAC;QACb,GAAG,CAAC,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,WAAW;QACrC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG;QACtC,GAAG,CAAC,MAAM,GAAG,CAAC;eAAG,IAAI,CAAC,UAAU;QAAA,CAAC,CAAC,CAAC,EAAE,GAAG;QAExC,EAAE,EAAE,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,MAAM,GAC9B,MAAM,GAAG,IAAI,CAAC,WAAW,CAAC,MAAM;QAElC,MAAM,CAAC,MAAM;IACf,CAAC;IAED,UAAU,GAAG,CAAC;QACZ,GAAG,CAAC,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,UAAU;QACpC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG;QACtC,GAAG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7C,CAAe,gBAAE,UAAU;YAC3B,CAAmB,oBAAE,KAAK,CAAC,CAAmB;YAC9C,CAAY,aAAE,KAAK,CAAC,CAAY;YAChC,SAAS,GAAG,UAAU,IAAI,WAAW,GAAG,SAAS,GAAG,IAAI;YACxD,QAAQ,GAAG,SAAS,IAAI,KAAK,CAAC,gBAAgB,CAAC,UAAU,IAAI,IAAI,MAAM,UAAU,GAAG,CAAC,GAAG,EAAE;QAC5F,CAAC;IACH,CAAC;AACH,CAAC;;;;;;;;;SoC3De,yCAAW,CAAC,KAAwB,EAAE,SAAS,EAAgB,CAAC;IAC9E,GAAG,CAAC,CAAC,aAAA,UAAU,EAAA,CAAC,GAAG,KAAK;IACxB,GAAG,EAAE,aAAa,EAAE,cAAc,IAAI,qBAAQ,CAAC,KAAK;IACpD,GAAG,CAAC,CAAC,mBAAA,gBAAgB,EAAA,CAAC,GAAG,2CAAc,CAAC,CAAC;QACvC,mBAAmB,EAAE,cAAc;IACrC,CAAC;IACD,GAAG,CAAC,OAAO,GAAG,CAAC;WAAG,SAAS,CAAC,UAAU,CAAC,OAAO;IAAE,CAAC;IACjD,EAAE,GAAG,OAAO,CAAC,IAAI,EAAC,GAAG,IAAK,SAAS,CAAC,YAAY,CAAC,GAAG,CAAC,GAAG;OACtD,UAAU,GAAG,IAAI;IAEnB,GAAG,CAAC,QAAQ,GAAG,oCAAc,CAAC,KAAK;IACnC,MAAM,CAAC,CAAC;QACN,aAAa,EAAE,gCAAU,CAAC,QAAQ,EAAE,CAAC;YACnC,CAAa,cAAE,KAAK;YACpB,CAAe,gBAAE,CAAW;YAC5B,CAAW,YAAE,aAAa,GAAG,CAAQ,UAAG,CAAK;YAC7C,CAAe,gBAAE,UAAU,KAAK,IAAI;eACjC,gBAAgB;QACrB,CAAC;IACH,CAAC;AACH,CAAC;","sources":["packages/@react-aria/tag/src/index.ts","packages/@react-aria/tag/src/TagKeyboardDelegate.ts","packages/@react-aria/tag/src/useTag.ts","packages/@react-aria/tag/intl/*.js","packages/@react-aria/tag/intl/ar-AE.json","packages/@react-aria/tag/intl/bg-BG.json","packages/@react-aria/tag/intl/cs-CZ.json","packages/@react-aria/tag/intl/da-DK.json","packages/@react-aria/tag/intl/de-DE.json","packages/@react-aria/tag/intl/el-GR.json","packages/@react-aria/tag/intl/en-US.json","packages/@react-aria/tag/intl/es-ES.json","packages/@react-aria/tag/intl/et-EE.json","packages/@react-aria/tag/intl/fi-FI.json","packages/@react-aria/tag/intl/fr-FR.json","packages/@react-aria/tag/intl/he-IL.json","packages/@react-aria/tag/intl/hr-HR.json","packages/@react-aria/tag/intl/hu-HU.json","packages/@react-aria/tag/intl/it-IT.json","packages/@react-aria/tag/intl/ja-JP.json","packages/@react-aria/tag/intl/ko-KR.json","packages/@react-aria/tag/intl/lt-LT.json","packages/@react-aria/tag/intl/lv-LV.json","packages/@react-aria/tag/intl/nb-NO.json","packages/@react-aria/tag/intl/nl-NL.json","packages/@react-aria/tag/intl/pl-PL.json","packages/@react-aria/tag/intl/pt-BR.json","packages/@react-aria/tag/intl/pt-PT.json","packages/@react-aria/tag/intl/ro-RO.json","packages/@react-aria/tag/intl/ru-RU.json","packages/@react-aria/tag/intl/sk-SK.json","packages/@react-aria/tag/intl/sl-SI.json","packages/@react-aria/tag/intl/sr-SP.json","packages/@react-aria/tag/intl/sv-SE.json","packages/@react-aria/tag/intl/tr-TR.json","packages/@react-aria/tag/intl/uk-UA.json","packages/@react-aria/tag/intl/zh-CN.json","packages/@react-aria/tag/intl/zh-TW.json","packages/@react-aria/tag/src/useTagGroup.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport * from './TagKeyboardDelegate';\nexport * from './useTag';\nexport * from './useTagGroup';\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {GridCollection} from '@react-types/grid';\nimport {GridKeyboardDelegate} from '@react-aria/grid';\nimport {Key} from 'react';\n\nexport class TagKeyboardDelegate<T> extends GridKeyboardDelegate<T, GridCollection<T>> {\n getFirstKey() {\n let key = this.collection.getFirstKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n getLastKey() {\n let key = this.collection.getLastKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n getKeyRightOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyAbove(key) : this.getKeyBelow(key);\n }\n\n getKeyLeftOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyBelow(key) : this.getKeyAbove(key);\n }\n\n getKeyBelow(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus was on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the next item\n key = this.findNextKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the next row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // Ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the next row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getFirstKey();\n }\n }\n\n getKeyAbove(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus is on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the previous item\n key = this.findPreviousKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the previous row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the previous row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getLastKey();\n }\n }\n\n getKeyPageAbove(key) {\n return this.getKeyAbove(key);\n }\n\n getKeyPageBelow(key) {\n return this.getKeyBelow(key);\n }\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ButtonHTMLAttributes, HTMLAttributes, KeyboardEvent} from 'react';\nimport {filterDOMProps, mergeProps, useId} from '@react-aria/utils';\nimport {GridState} from '@react-stately/grid';\n// @ts-ignore\nimport intlMessages from '../intl/*.json';\nimport {TagProps} from '@react-types/tag';\nimport {useGridCell, useGridRow} from '@react-aria/grid';\nimport {useMessageFormatter} from '@react-aria/i18n';\n\n\nexport interface TagAria {\n labelProps: HTMLAttributes<HTMLElement>,\n tagProps: HTMLAttributes<HTMLElement>,\n tagRowProps: HTMLAttributes<HTMLElement>,\n clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>\n}\n\nexport function useTag(props: TagProps<any>, state: GridState<any, any>): TagAria {\n let {isFocused} = props;\n const {\n isDisabled,\n isRemovable,\n onRemove,\n children,\n item,\n tagRef,\n tagRowRef\n } = props;\n const formatMessage = useMessageFormatter(intlMessages);\n const removeString = formatMessage('remove');\n const labelId = useId();\n const buttonId = useId();\n\n let {rowProps} = useGridRow({\n node: item\n }, state, tagRowRef);\n // Don't want the row to be focusable or accessible via keyboard\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {tabIndex, ...otherRowProps} = rowProps;\n\n let {gridCellProps} = useGridCell({\n node: [...item.childNodes][0],\n focusMode: 'cell'\n }, state, tagRef);\n\n function onKeyDown(e: KeyboardEvent<HTMLElement>) {\n if (e.key === 'Delete' || e.key === 'Backspace' || e.key === ' ') {\n onRemove(children, e);\n e.preventDefault();\n }\n }\n const pressProps = {\n onPress: e => onRemove?.(children, e)\n };\n\n isFocused = isFocused || state.selectionManager.focusedKey === item.childNodes[0].key;\n let domProps = filterDOMProps(props);\n return {\n clearButtonProps: mergeProps(pressProps, {\n 'aria-label': removeString,\n 'aria-labelledby': `${buttonId} ${labelId}`,\n id: buttonId,\n isDisabled\n }),\n labelProps: {\n id: labelId\n },\n tagRowProps: otherRowProps,\n tagProps: mergeProps(domProps, gridCellProps, {\n 'aria-disabled': isDisabled,\n 'aria-errormessage': props['aria-errormessage'],\n 'aria-label': props['aria-label'],\n onKeyDown: !isDisabled && isRemovable ? onKeyDown : null,\n tabIndex: (isFocused || state.selectionManager.focusedKey == null) && !isDisabled ? 0 : -1\n })\n };\n}\n","const _temp0 = require(\"./ar-AE.json\");\nconst _temp1 = require(\"./bg-BG.json\");\nconst _temp2 = require(\"./cs-CZ.json\");\nconst _temp3 = require(\"./da-DK.json\");\nconst _temp4 = require(\"./de-DE.json\");\nconst _temp5 = require(\"./el-GR.json\");\nconst _temp6 = require(\"./en-US.json\");\nconst _temp7 = require(\"./es-ES.json\");\nconst _temp8 = require(\"./et-EE.json\");\nconst _temp9 = require(\"./fi-FI.json\");\nconst _temp10 = require(\"./fr-FR.json\");\nconst _temp11 = require(\"./he-IL.json\");\nconst _temp12 = require(\"./hr-HR.json\");\nconst _temp13 = require(\"./hu-HU.json\");\nconst _temp14 = require(\"./it-IT.json\");\nconst _temp15 = require(\"./ja-JP.json\");\nconst _temp16 = require(\"./ko-KR.json\");\nconst _temp17 = require(\"./lt-LT.json\");\nconst _temp18 = require(\"./lv-LV.json\");\nconst _temp19 = require(\"./nb-NO.json\");\nconst _temp20 = require(\"./nl-NL.json\");\nconst _temp21 = require(\"./pl-PL.json\");\nconst _temp22 = require(\"./pt-BR.json\");\nconst _temp23 = require(\"./pt-PT.json\");\nconst _temp24 = require(\"./ro-RO.json\");\nconst _temp25 = require(\"./ru-RU.json\");\nconst _temp26 = require(\"./sk-SK.json\");\nconst _temp27 = require(\"./sl-SI.json\");\nconst _temp28 = require(\"./sr-SP.json\");\nconst _temp29 = require(\"./sv-SE.json\");\nconst _temp30 = require(\"./tr-TR.json\");\nconst _temp31 = require(\"./uk-UA.json\");\nconst _temp32 = require(\"./zh-CN.json\");\nconst _temp33 = require(\"./zh-TW.json\");\nmodule.exports = {\n \"ar-AE\": _temp0,\n \"bg-BG\": _temp1,\n \"cs-CZ\": _temp2,\n \"da-DK\": _temp3,\n \"de-DE\": _temp4,\n \"el-GR\": _temp5,\n \"en-US\": _temp6,\n \"es-ES\": _temp7,\n \"et-EE\": _temp8,\n \"fi-FI\": _temp9,\n \"fr-FR\": _temp10,\n \"he-IL\": _temp11,\n \"hr-HR\": _temp12,\n \"hu-HU\": _temp13,\n \"it-IT\": _temp14,\n \"ja-JP\": _temp15,\n \"ko-KR\": _temp16,\n \"lt-LT\": _temp17,\n \"lv-LV\": _temp18,\n \"nb-NO\": _temp19,\n \"nl-NL\": _temp20,\n \"pl-PL\": _temp21,\n \"pt-BR\": _temp22,\n \"pt-PT\": _temp23,\n \"ro-RO\": _temp24,\n \"ru-RU\": _temp25,\n \"sk-SK\": _temp26,\n \"sl-SI\": _temp27,\n \"sr-SP\": _temp28,\n \"sv-SE\": _temp29,\n \"tr-TR\": _temp30,\n \"uk-UA\": _temp31,\n \"zh-CN\": _temp32,\n \"zh-TW\": _temp33\n}","{\n \"remove\": \"إزالة\"\n}\n","{\n \"remove\": \"Премахване\"\n}\n","{\n \"remove\": \"Odebrat\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Entfernen\"\n}\n","{\n \"remove\": \"Κατάργηση\"\n}\n","{\n \"remove\": \"Remove\"\n}\n","{\n \"remove\": \"Quitar\"\n}\n","{\n \"remove\": \"Eemalda\"\n}\n","{\n \"remove\": \"Poista\"\n}\n","{\n \"remove\": \"Supprimer\"\n}\n","{\n \"remove\": \"הסר\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Eltávolítás\"\n}\n","{\n \"remove\": \"Rimuovi\"\n}\n","{\n \"remove\": \"削除\"\n}\n","{\n \"remove\": \"제거\"\n}\n","{\n \"remove\": \"Pašalinti\"\n}\n","{\n \"remove\": \"Noņemt\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Verwijderen\"\n}\n","{\n \"remove\": \"Usuń\"\n}\n","{\n \"remove\": \"Remover\"\n}\n","{\n \"remove\": \"Eliminar\"\n}\n","{\n \"remove\": \"Îndepărtaţi\"\n}\n","{\n \"remove\": \"Удалить\"\n}\n","{\n \"remove\": \"Odstrániť\"\n}\n","{\n \"remove\": \"Odstrani\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Ta bort\"\n}\n","{\n \"remove\": \"Kaldır\"\n}\n","{\n \"remove\": \"Видалити\"\n}\n","{\n \"remove\": \"删除\"\n}\n","{\n \"remove\": \"移除\"\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {DOMProps} from '@react-types/shared';\nimport {filterDOMProps, mergeProps} from '@react-aria/utils';\nimport {HTMLAttributes, Key, ReactNode, useState} from 'react';\nimport {useFocusWithin} from '@react-aria/interactions';\n\ninterface AriaTagGroupProps extends DOMProps {\n children: ReactNode,\n disabledKeys?: Iterable<Key>,\n isDisabled?: boolean,\n isReadOnly?: boolean, // removes close button\n validationState?: 'valid' | 'invalid'\n}\n\ninterface TagGroupAria {\n tagGroupProps: HTMLAttributes<HTMLElement>\n}\n\nexport function useTagGroup(props: AriaTagGroupProps, listState): TagGroupAria {\n let {isDisabled} = props;\n let [isFocusWithin, setFocusWithin] = useState(false);\n let {focusWithinProps} = useFocusWithin({\n onFocusWithinChange: setFocusWithin\n });\n let allKeys = [...listState.collection.getKeys()];\n if (!allKeys.some(key => !listState.disabledKeys.has(key))) {\n isDisabled = true;\n }\n let domProps = filterDOMProps(props);\n return {\n tagGroupProps: mergeProps(domProps, {\n 'aria-atomic': false,\n 'aria-relevant': 'additions',\n 'aria-live': isFocusWithin ? 'polite' : 'off',\n 'aria-disabled': isDisabled === true,\n ...focusWithinProps\n } as HTMLAttributes<HTMLElement>)\n };\n}\n"],"names":[],"version":3,"file":"main.js.map"}
1
+ {"mappings":";;;;;;;;;;;;;;;;;MCgBa,yCAAmB,SAAY,yCAAoB;IAC9D,WAAW,GAAG,CAAC;QACb,GAAG,CAAC,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,WAAW;QACrC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG;QACtC,GAAG,CAAC,MAAM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AAC,KAAK;IACnC,MAAM,CAAC,CAAC;QACN,aAAa,EAAE,gCAAU,CAAC,QAAQ,EAAE,CAAC;YACnC,CAAa,cAAE,KAAK;YACpB,CAAe,gBAAE,CAAW;YAC5B,CAAW,YAAE,aAAa,GAAG,CAAQ,UAAG,CAAK;YAC7C,CAAe,gBAAE,UAAU,KAAK,IAAI;eACjC,gBAAgB;QACrB,CAAC;IACH,CAAC;AACH,CAAC;","sources":["packages/@react-aria/tag/src/index.ts","packages/@react-aria/tag/src/TagKeyboardDelegate.ts","packages/@react-aria/tag/src/useTag.ts","packages/@react-aria/tag/intl/*.js","packages/@react-aria/tag/intl/ar-AE.json","packages/@react-aria/tag/intl/bg-BG.json","packages/@react-aria/tag/intl/cs-CZ.json","packages/@react-aria/tag/intl/da-DK.json","packages/@react-aria/tag/intl/de-DE.json","packages/@react-aria/tag/intl/el-GR.json","packages/@react-aria/tag/intl/en-US.json","packages/@react-aria/tag/intl/es-ES.json","packages/@react-aria/tag/intl/et-EE.json","packages/@react-aria/tag/intl/fi-FI.json","packages/@react-aria/tag/intl/fr-FR.json","packages/@react-aria/tag/intl/he-IL.json","packages/@react-aria/tag/intl/hr-HR.json","packages/@react-aria/tag/intl/hu-HU.json","packages/@react-aria/tag/intl/it-IT.json","packages/@react-aria/tag/intl/ja-JP.json","packages/@react-aria/tag/intl/ko-KR.json","packages/@react-aria/tag/intl/lt-LT.json","packages/@react-aria/tag/intl/lv-LV.json","packages/@react-aria/tag/intl/nb-NO.json","packages/@react-aria/tag/intl/nl-NL.json","packages/@react-aria/tag/intl/pl-PL.json","packages/@react-aria/tag/intl/pt-BR.json","packages/@react-aria/tag/intl/pt-PT.json","packages/@react-aria/tag/intl/ro-RO.json","packages/@react-aria/tag/intl/ru-RU.json","packages/@react-aria/tag/intl/sk-SK.json","packages/@react-aria/tag/intl/sl-SI.json","packages/@react-aria/tag/intl/sr-SP.json","packages/@react-aria/tag/intl/sv-SE.json","packages/@react-aria/tag/intl/tr-TR.json","packages/@react-aria/tag/intl/uk-UA.json","packages/@react-aria/tag/intl/zh-CN.json","packages/@react-aria/tag/intl/zh-TW.json","packages/@react-aria/tag/src/useTagGroup.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport type {TagAria} from './useTag';\nexport {TagKeyboardDelegate} from './TagKeyboardDelegate';\nexport {useTag} from './useTag';\nexport {useTagGroup} from './useTagGroup';\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {GridCollection} from '@react-types/grid';\nimport {GridKeyboardDelegate} from '@react-aria/grid';\nimport {Key} from 'react';\n\nexport class TagKeyboardDelegate<T> extends GridKeyboardDelegate<T, GridCollection<T>> {\n getFirstKey() {\n let key = this.collection.getFirstKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n getLastKey() {\n let key = this.collection.getLastKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n getKeyRightOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyAbove(key) : this.getKeyBelow(key);\n }\n\n getKeyLeftOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyBelow(key) : this.getKeyAbove(key);\n }\n\n getKeyBelow(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus was on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the next item\n key = this.findNextKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the next row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // Ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the next row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getFirstKey();\n }\n }\n\n getKeyAbove(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus is on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the previous item\n key = this.findPreviousKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the previous row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the previous row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getLastKey();\n }\n }\n\n getKeyPageAbove(key) {\n return this.getKeyAbove(key);\n }\n\n getKeyPageBelow(key) {\n return this.getKeyBelow(key);\n }\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ButtonHTMLAttributes, KeyboardEvent} from 'react';\nimport {DOMAttributes} from '@react-types/shared';\nimport {filterDOMProps, mergeProps, useId} from '@react-aria/utils';\nimport {GridState} from '@react-stately/grid';\n// @ts-ignore\nimport intlMessages from '../intl/*.json';\nimport {TagProps} from '@react-types/tag';\nimport {useGridCell, useGridRow} from '@react-aria/grid';\nimport {useMessageFormatter} from '@react-aria/i18n';\n\n\nexport interface TagAria {\n labelProps: DOMAttributes,\n tagProps: DOMAttributes,\n tagRowProps: DOMAttributes,\n clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>\n}\n\nexport function useTag(props: TagProps<any>, state: GridState<any, any>): TagAria {\n let {isFocused} = props;\n const {\n isDisabled,\n isRemovable,\n onRemove,\n children,\n item,\n tagRef,\n tagRowRef\n } = props;\n const formatMessage = useMessageFormatter(intlMessages);\n const removeString = formatMessage('remove');\n const labelId = useId();\n const buttonId = useId();\n\n let {rowProps} = useGridRow({\n node: item\n }, state, tagRowRef);\n // Don't want the row to be focusable or accessible via keyboard\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {tabIndex, ...otherRowProps} = rowProps;\n\n let {gridCellProps} = useGridCell({\n node: [...item.childNodes][0],\n focusMode: 'cell'\n }, state, tagRef);\n\n function onKeyDown(e: KeyboardEvent<Element>) {\n if (e.key === 'Delete' || e.key === 'Backspace' || e.key === ' ') {\n onRemove(children, e);\n e.preventDefault();\n }\n }\n const pressProps = {\n onPress: e => onRemove?.(children, e)\n };\n\n isFocused = isFocused || state.selectionManager.focusedKey === item.childNodes[0].key;\n let domProps = filterDOMProps(props);\n return {\n clearButtonProps: mergeProps(pressProps, {\n 'aria-label': removeString,\n 'aria-labelledby': `${buttonId} ${labelId}`,\n id: buttonId,\n isDisabled\n }),\n labelProps: {\n id: labelId\n },\n tagRowProps: otherRowProps,\n tagProps: mergeProps(domProps, gridCellProps, {\n 'aria-disabled': isDisabled,\n 'aria-errormessage': props['aria-errormessage'],\n 'aria-label': props['aria-label'],\n onKeyDown: !isDisabled && isRemovable ? onKeyDown : null,\n tabIndex: (isFocused || state.selectionManager.focusedKey == null) && !isDisabled ? 0 : -1\n })\n };\n}\n","const _temp0 = require(\"./ar-AE.json\");\nconst _temp1 = require(\"./bg-BG.json\");\nconst _temp2 = require(\"./cs-CZ.json\");\nconst _temp3 = require(\"./da-DK.json\");\nconst _temp4 = require(\"./de-DE.json\");\nconst _temp5 = require(\"./el-GR.json\");\nconst _temp6 = require(\"./en-US.json\");\nconst _temp7 = require(\"./es-ES.json\");\nconst _temp8 = require(\"./et-EE.json\");\nconst _temp9 = require(\"./fi-FI.json\");\nconst _temp10 = require(\"./fr-FR.json\");\nconst _temp11 = require(\"./he-IL.json\");\nconst _temp12 = require(\"./hr-HR.json\");\nconst _temp13 = require(\"./hu-HU.json\");\nconst _temp14 = require(\"./it-IT.json\");\nconst _temp15 = require(\"./ja-JP.json\");\nconst _temp16 = require(\"./ko-KR.json\");\nconst _temp17 = require(\"./lt-LT.json\");\nconst _temp18 = require(\"./lv-LV.json\");\nconst _temp19 = require(\"./nb-NO.json\");\nconst _temp20 = require(\"./nl-NL.json\");\nconst _temp21 = require(\"./pl-PL.json\");\nconst _temp22 = require(\"./pt-BR.json\");\nconst _temp23 = require(\"./pt-PT.json\");\nconst _temp24 = require(\"./ro-RO.json\");\nconst _temp25 = require(\"./ru-RU.json\");\nconst _temp26 = require(\"./sk-SK.json\");\nconst _temp27 = require(\"./sl-SI.json\");\nconst _temp28 = require(\"./sr-SP.json\");\nconst _temp29 = require(\"./sv-SE.json\");\nconst _temp30 = require(\"./tr-TR.json\");\nconst _temp31 = require(\"./uk-UA.json\");\nconst _temp32 = require(\"./zh-CN.json\");\nconst _temp33 = require(\"./zh-TW.json\");\nmodule.exports = {\n \"ar-AE\": _temp0,\n \"bg-BG\": _temp1,\n \"cs-CZ\": _temp2,\n \"da-DK\": _temp3,\n \"de-DE\": _temp4,\n \"el-GR\": _temp5,\n \"en-US\": _temp6,\n \"es-ES\": _temp7,\n \"et-EE\": _temp8,\n \"fi-FI\": _temp9,\n \"fr-FR\": _temp10,\n \"he-IL\": _temp11,\n \"hr-HR\": _temp12,\n \"hu-HU\": _temp13,\n \"it-IT\": _temp14,\n \"ja-JP\": _temp15,\n \"ko-KR\": _temp16,\n \"lt-LT\": _temp17,\n \"lv-LV\": _temp18,\n \"nb-NO\": _temp19,\n \"nl-NL\": _temp20,\n \"pl-PL\": _temp21,\n \"pt-BR\": _temp22,\n \"pt-PT\": _temp23,\n \"ro-RO\": _temp24,\n \"ru-RU\": _temp25,\n \"sk-SK\": _temp26,\n \"sl-SI\": _temp27,\n \"sr-SP\": _temp28,\n \"sv-SE\": _temp29,\n \"tr-TR\": _temp30,\n \"uk-UA\": _temp31,\n \"zh-CN\": _temp32,\n \"zh-TW\": _temp33\n}","{\n \"remove\": \"إزالة\"\n}\n","{\n \"remove\": \"Премахване\"\n}\n","{\n \"remove\": \"Odebrat\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Entfernen\"\n}\n","{\n \"remove\": \"Κατάργηση\"\n}\n","{\n \"remove\": \"Remove\"\n}\n","{\n \"remove\": \"Quitar\"\n}\n","{\n \"remove\": \"Eemalda\"\n}\n","{\n \"remove\": \"Poista\"\n}\n","{\n \"remove\": \"Supprimer\"\n}\n","{\n \"remove\": \"הסר\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Eltávolítás\"\n}\n","{\n \"remove\": \"Rimuovi\"\n}\n","{\n \"remove\": \"削除\"\n}\n","{\n \"remove\": \"제거\"\n}\n","{\n \"remove\": \"Pašalinti\"\n}\n","{\n \"remove\": \"Noņemt\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Verwijderen\"\n}\n","{\n \"remove\": \"Usuń\"\n}\n","{\n \"remove\": \"Remover\"\n}\n","{\n \"remove\": \"Eliminar\"\n}\n","{\n \"remove\": \"Îndepărtaţi\"\n}\n","{\n \"remove\": \"Удалить\"\n}\n","{\n \"remove\": \"Odstrániť\"\n}\n","{\n \"remove\": \"Odstrani\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Ta bort\"\n}\n","{\n \"remove\": \"Kaldır\"\n}\n","{\n \"remove\": \"Видалити\"\n}\n","{\n \"remove\": \"删除\"\n}\n","{\n \"remove\": \"移除\"\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {DOMAttributes, DOMProps} from '@react-types/shared';\nimport {filterDOMProps, mergeProps} from '@react-aria/utils';\nimport {Key, ReactNode, useState} from 'react';\nimport {useFocusWithin} from '@react-aria/interactions';\n\ninterface AriaTagGroupProps extends DOMProps {\n children: ReactNode,\n disabledKeys?: Iterable<Key>,\n isDisabled?: boolean,\n isReadOnly?: boolean, // removes close button\n validationState?: 'valid' | 'invalid'\n}\n\ninterface TagGroupAria {\n tagGroupProps: DOMAttributes\n}\n\nexport function useTagGroup(props: AriaTagGroupProps, listState): TagGroupAria {\n let {isDisabled} = props;\n let [isFocusWithin, setFocusWithin] = useState(false);\n let {focusWithinProps} = useFocusWithin({\n onFocusWithinChange: setFocusWithin\n });\n let allKeys = [...listState.collection.getKeys()];\n if (!allKeys.some(key => !listState.disabledKeys.has(key))) {\n isDisabled = true;\n }\n let domProps = filterDOMProps(props);\n return {\n tagGroupProps: mergeProps(domProps, {\n 'aria-atomic': false,\n 'aria-relevant': 'additions',\n 'aria-live': isFocusWithin ? 'polite' : 'off',\n 'aria-disabled': isDisabled === true,\n ...focusWithinProps\n } as DOMAttributes)\n };\n}\n"],"names":[],"version":3,"file":"main.js.map"}
package/dist/module.js CHANGED
@@ -4,15 +4,9 @@ import {useMessageFormatter as $aIvin$useMessageFormatter} from "@react-aria/i18
4
4
  import {useState as $aIvin$useState} from "react";
5
5
  import {useFocusWithin as $aIvin$useFocusWithin} from "@react-aria/interactions";
6
6
 
7
- function $parcel$export(e, n, v, s) {
8
- Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
9
- }
10
7
  function $parcel$interopDefault(a) {
11
8
  return a && a.__esModule ? a.default : a;
12
9
  }
13
- var $542448901dbd2c36$exports = {};
14
-
15
- $parcel$export($542448901dbd2c36$exports, "TagKeyboardDelegate", () => $542448901dbd2c36$export$b00754732e683b92);
16
10
 
17
11
  class $542448901dbd2c36$export$b00754732e683b92 extends $aIvin$GridKeyboardDelegate {
18
12
  getFirstKey() {
@@ -92,9 +86,6 @@ class $542448901dbd2c36$export$b00754732e683b92 extends $aIvin$GridKeyboardDeleg
92
86
  }
93
87
 
94
88
 
95
- var $fc6126c82a4601f1$exports = {};
96
-
97
- $parcel$export($fc6126c82a4601f1$exports, "useTag", () => $fc6126c82a4601f1$export$3f568fff7dff2f03);
98
89
 
99
90
  var $4d1b62e0e67c00a4$exports = {};
100
91
  var $84925f526f90eebd$exports = {};
@@ -327,9 +318,6 @@ function $fc6126c82a4601f1$export$3f568fff7dff2f03(props, state) {
327
318
  }
328
319
 
329
320
 
330
- var $d7323bca8d074eeb$exports = {};
331
-
332
- $parcel$export($d7323bca8d074eeb$exports, "useTagGroup", () => $d7323bca8d074eeb$export$4f8b5cda58b7e8ff);
333
321
 
334
322
 
335
323
 
@@ -1 +1 @@
1
- {"mappings":";;;;;;;;;;;;;;;;MCgBa,yCAAmB,SAAY,2BAAoB;IAC9D,WAAW,GAAG,CAAC;QACb,GAAG,CAAC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AO,CAAC,IAAI,EAAC,GAAG,IAAK,SAAS,CAAC,YAAY,CAAC,GAAG,CAAC,GAAG;OACtD,UAAU,GAAG,IAAI;IAEnB,GAAG,CAAC,QAAQ,GAAG,qBAAc,CAAC,KAAK;IACnC,MAAM,CAAC,CAAC;QACN,aAAa,EAAE,iBAAU,CAAC,QAAQ,EAAE,CAAC;YACnC,CAAa,cAAE,KAAK;YACpB,CAAe,gBAAE,CAAW;YAC5B,CAAW,YAAE,aAAa,GAAG,CAAQ,UAAG,CAAK;YAC7C,CAAe,gBAAE,UAAU,KAAK,IAAI;eACjC,gBAAgB;QACrB,CAAC;IACH,CAAC;AACH,CAAC;","sources":["packages/@react-aria/tag/src/index.ts","packages/@react-aria/tag/src/TagKeyboardDelegate.ts","packages/@react-aria/tag/src/useTag.ts","packages/@react-aria/tag/intl/*.js","packages/@react-aria/tag/intl/ar-AE.json","packages/@react-aria/tag/intl/bg-BG.json","packages/@react-aria/tag/intl/cs-CZ.json","packages/@react-aria/tag/intl/da-DK.json","packages/@react-aria/tag/intl/de-DE.json","packages/@react-aria/tag/intl/el-GR.json","packages/@react-aria/tag/intl/en-US.json","packages/@react-aria/tag/intl/es-ES.json","packages/@react-aria/tag/intl/et-EE.json","packages/@react-aria/tag/intl/fi-FI.json","packages/@react-aria/tag/intl/fr-FR.json","packages/@react-aria/tag/intl/he-IL.json","packages/@react-aria/tag/intl/hr-HR.json","packages/@react-aria/tag/intl/hu-HU.json","packages/@react-aria/tag/intl/it-IT.json","packages/@react-aria/tag/intl/ja-JP.json","packages/@react-aria/tag/intl/ko-KR.json","packages/@react-aria/tag/intl/lt-LT.json","packages/@react-aria/tag/intl/lv-LV.json","packages/@react-aria/tag/intl/nb-NO.json","packages/@react-aria/tag/intl/nl-NL.json","packages/@react-aria/tag/intl/pl-PL.json","packages/@react-aria/tag/intl/pt-BR.json","packages/@react-aria/tag/intl/pt-PT.json","packages/@react-aria/tag/intl/ro-RO.json","packages/@react-aria/tag/intl/ru-RU.json","packages/@react-aria/tag/intl/sk-SK.json","packages/@react-aria/tag/intl/sl-SI.json","packages/@react-aria/tag/intl/sr-SP.json","packages/@react-aria/tag/intl/sv-SE.json","packages/@react-aria/tag/intl/tr-TR.json","packages/@react-aria/tag/intl/uk-UA.json","packages/@react-aria/tag/intl/zh-CN.json","packages/@react-aria/tag/intl/zh-TW.json","packages/@react-aria/tag/src/useTagGroup.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport * from './TagKeyboardDelegate';\nexport * from './useTag';\nexport * from './useTagGroup';\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {GridCollection} from '@react-types/grid';\nimport {GridKeyboardDelegate} from '@react-aria/grid';\nimport {Key} from 'react';\n\nexport class TagKeyboardDelegate<T> extends GridKeyboardDelegate<T, GridCollection<T>> {\n getFirstKey() {\n let key = this.collection.getFirstKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n getLastKey() {\n let key = this.collection.getLastKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n getKeyRightOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyAbove(key) : this.getKeyBelow(key);\n }\n\n getKeyLeftOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyBelow(key) : this.getKeyAbove(key);\n }\n\n getKeyBelow(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus was on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the next item\n key = this.findNextKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the next row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // Ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the next row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getFirstKey();\n }\n }\n\n getKeyAbove(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus is on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the previous item\n key = this.findPreviousKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the previous row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the previous row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getLastKey();\n }\n }\n\n getKeyPageAbove(key) {\n return this.getKeyAbove(key);\n }\n\n getKeyPageBelow(key) {\n return this.getKeyBelow(key);\n }\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ButtonHTMLAttributes, HTMLAttributes, KeyboardEvent} from 'react';\nimport {filterDOMProps, mergeProps, useId} from '@react-aria/utils';\nimport {GridState} from '@react-stately/grid';\n// @ts-ignore\nimport intlMessages from '../intl/*.json';\nimport {TagProps} from '@react-types/tag';\nimport {useGridCell, useGridRow} from '@react-aria/grid';\nimport {useMessageFormatter} from '@react-aria/i18n';\n\n\nexport interface TagAria {\n labelProps: HTMLAttributes<HTMLElement>,\n tagProps: HTMLAttributes<HTMLElement>,\n tagRowProps: HTMLAttributes<HTMLElement>,\n clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>\n}\n\nexport function useTag(props: TagProps<any>, state: GridState<any, any>): TagAria {\n let {isFocused} = props;\n const {\n isDisabled,\n isRemovable,\n onRemove,\n children,\n item,\n tagRef,\n tagRowRef\n } = props;\n const formatMessage = useMessageFormatter(intlMessages);\n const removeString = formatMessage('remove');\n const labelId = useId();\n const buttonId = useId();\n\n let {rowProps} = useGridRow({\n node: item\n }, state, tagRowRef);\n // Don't want the row to be focusable or accessible via keyboard\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {tabIndex, ...otherRowProps} = rowProps;\n\n let {gridCellProps} = useGridCell({\n node: [...item.childNodes][0],\n focusMode: 'cell'\n }, state, tagRef);\n\n function onKeyDown(e: KeyboardEvent<HTMLElement>) {\n if (e.key === 'Delete' || e.key === 'Backspace' || e.key === ' ') {\n onRemove(children, e);\n e.preventDefault();\n }\n }\n const pressProps = {\n onPress: e => onRemove?.(children, e)\n };\n\n isFocused = isFocused || state.selectionManager.focusedKey === item.childNodes[0].key;\n let domProps = filterDOMProps(props);\n return {\n clearButtonProps: mergeProps(pressProps, {\n 'aria-label': removeString,\n 'aria-labelledby': `${buttonId} ${labelId}`,\n id: buttonId,\n isDisabled\n }),\n labelProps: {\n id: labelId\n },\n tagRowProps: otherRowProps,\n tagProps: mergeProps(domProps, gridCellProps, {\n 'aria-disabled': isDisabled,\n 'aria-errormessage': props['aria-errormessage'],\n 'aria-label': props['aria-label'],\n onKeyDown: !isDisabled && isRemovable ? onKeyDown : null,\n tabIndex: (isFocused || state.selectionManager.focusedKey == null) && !isDisabled ? 0 : -1\n })\n };\n}\n","const _temp0 = require(\"./ar-AE.json\");\nconst _temp1 = require(\"./bg-BG.json\");\nconst _temp2 = require(\"./cs-CZ.json\");\nconst _temp3 = require(\"./da-DK.json\");\nconst _temp4 = require(\"./de-DE.json\");\nconst _temp5 = require(\"./el-GR.json\");\nconst _temp6 = require(\"./en-US.json\");\nconst _temp7 = require(\"./es-ES.json\");\nconst _temp8 = require(\"./et-EE.json\");\nconst _temp9 = require(\"./fi-FI.json\");\nconst _temp10 = require(\"./fr-FR.json\");\nconst _temp11 = require(\"./he-IL.json\");\nconst _temp12 = require(\"./hr-HR.json\");\nconst _temp13 = require(\"./hu-HU.json\");\nconst _temp14 = require(\"./it-IT.json\");\nconst _temp15 = require(\"./ja-JP.json\");\nconst _temp16 = require(\"./ko-KR.json\");\nconst _temp17 = require(\"./lt-LT.json\");\nconst _temp18 = require(\"./lv-LV.json\");\nconst _temp19 = require(\"./nb-NO.json\");\nconst _temp20 = require(\"./nl-NL.json\");\nconst _temp21 = require(\"./pl-PL.json\");\nconst _temp22 = require(\"./pt-BR.json\");\nconst _temp23 = require(\"./pt-PT.json\");\nconst _temp24 = require(\"./ro-RO.json\");\nconst _temp25 = require(\"./ru-RU.json\");\nconst _temp26 = require(\"./sk-SK.json\");\nconst _temp27 = require(\"./sl-SI.json\");\nconst _temp28 = require(\"./sr-SP.json\");\nconst _temp29 = require(\"./sv-SE.json\");\nconst _temp30 = require(\"./tr-TR.json\");\nconst _temp31 = require(\"./uk-UA.json\");\nconst _temp32 = require(\"./zh-CN.json\");\nconst _temp33 = require(\"./zh-TW.json\");\nmodule.exports = {\n \"ar-AE\": _temp0,\n \"bg-BG\": _temp1,\n \"cs-CZ\": _temp2,\n \"da-DK\": _temp3,\n \"de-DE\": _temp4,\n \"el-GR\": _temp5,\n \"en-US\": _temp6,\n \"es-ES\": _temp7,\n \"et-EE\": _temp8,\n \"fi-FI\": _temp9,\n \"fr-FR\": _temp10,\n \"he-IL\": _temp11,\n \"hr-HR\": _temp12,\n \"hu-HU\": _temp13,\n \"it-IT\": _temp14,\n \"ja-JP\": _temp15,\n \"ko-KR\": _temp16,\n \"lt-LT\": _temp17,\n \"lv-LV\": _temp18,\n \"nb-NO\": _temp19,\n \"nl-NL\": _temp20,\n \"pl-PL\": _temp21,\n \"pt-BR\": _temp22,\n \"pt-PT\": _temp23,\n \"ro-RO\": _temp24,\n \"ru-RU\": _temp25,\n \"sk-SK\": _temp26,\n \"sl-SI\": _temp27,\n \"sr-SP\": _temp28,\n \"sv-SE\": _temp29,\n \"tr-TR\": _temp30,\n \"uk-UA\": _temp31,\n \"zh-CN\": _temp32,\n \"zh-TW\": _temp33\n}","{\n \"remove\": \"إزالة\"\n}\n","{\n \"remove\": \"Премахване\"\n}\n","{\n \"remove\": \"Odebrat\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Entfernen\"\n}\n","{\n \"remove\": \"Κατάργηση\"\n}\n","{\n \"remove\": \"Remove\"\n}\n","{\n \"remove\": \"Quitar\"\n}\n","{\n \"remove\": \"Eemalda\"\n}\n","{\n \"remove\": \"Poista\"\n}\n","{\n \"remove\": \"Supprimer\"\n}\n","{\n \"remove\": \"הסר\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Eltávolítás\"\n}\n","{\n \"remove\": \"Rimuovi\"\n}\n","{\n \"remove\": \"削除\"\n}\n","{\n \"remove\": \"제거\"\n}\n","{\n \"remove\": \"Pašalinti\"\n}\n","{\n \"remove\": \"Noņemt\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Verwijderen\"\n}\n","{\n \"remove\": \"Usuń\"\n}\n","{\n \"remove\": \"Remover\"\n}\n","{\n \"remove\": \"Eliminar\"\n}\n","{\n \"remove\": \"Îndepărtaţi\"\n}\n","{\n \"remove\": \"Удалить\"\n}\n","{\n \"remove\": \"Odstrániť\"\n}\n","{\n \"remove\": \"Odstrani\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Ta bort\"\n}\n","{\n \"remove\": \"Kaldır\"\n}\n","{\n \"remove\": \"Видалити\"\n}\n","{\n \"remove\": \"删除\"\n}\n","{\n \"remove\": \"移除\"\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {DOMProps} from '@react-types/shared';\nimport {filterDOMProps, mergeProps} from '@react-aria/utils';\nimport {HTMLAttributes, Key, ReactNode, useState} from 'react';\nimport {useFocusWithin} from '@react-aria/interactions';\n\ninterface AriaTagGroupProps extends DOMProps {\n children: ReactNode,\n disabledKeys?: Iterable<Key>,\n isDisabled?: boolean,\n isReadOnly?: boolean, // removes close button\n validationState?: 'valid' | 'invalid'\n}\n\ninterface TagGroupAria {\n tagGroupProps: HTMLAttributes<HTMLElement>\n}\n\nexport function useTagGroup(props: AriaTagGroupProps, listState): TagGroupAria {\n let {isDisabled} = props;\n let [isFocusWithin, setFocusWithin] = useState(false);\n let {focusWithinProps} = useFocusWithin({\n onFocusWithinChange: setFocusWithin\n });\n let allKeys = [...listState.collection.getKeys()];\n if (!allKeys.some(key => !listState.disabledKeys.has(key))) {\n isDisabled = true;\n }\n let domProps = filterDOMProps(props);\n return {\n tagGroupProps: mergeProps(domProps, {\n 'aria-atomic': false,\n 'aria-relevant': 'additions',\n 'aria-live': isFocusWithin ? 'polite' : 'off',\n 'aria-disabled': isDisabled === true,\n ...focusWithinProps\n } as HTMLAttributes<HTMLElement>)\n };\n}\n"],"names":[],"version":3,"file":"module.js.map"}
1
+ {"mappings":";;;;;;;;;;MCgBa,yCAAmB,SAAY,2BAAoB;IAC9D,WAAW,GAAG,CAAC;QACb,GAAG,CAAC,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,WAAW;QACrC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG;QACtC,GAAG,CAAC,MAAM,GAAG,CAAC;eAAG,IAAI,CAAC,UAAU;QAAA,CAAC,CAAC,CAAC,EAAE,GAAG;QAExC,EAAE,EAAE,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,MAAM,GAC9B,MAAM,GAAG,IAAI,CAAC,WAAW,CAAC,MAAM;QAElC,MAAM,CAAC,MAAM;IACf,CAAC;IAED,UAAU,GAAG,CAAC;QACZ,GAAG,CAAC,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,UAAU;QACpC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG;QACtC,GAAG,CAAC,MAAM,GAAG,CAAC;eAAG,IAAI,CAAC,UAAU;QAAA,CAAC,CAAC,CAAC,EAAE,GAAG;QAExC,EAAE,EAAE,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,MAAM,GAC9B,MAAM,GAAG,IAAI,CAAC,WAAW,CAAC,MAAM;QAElC,MAAM,CAAC,MAAM;IACf,CAAC;IAED,aAAa,CAAC,GAAQ,EAAE,CAAC;QACvB,MAAM,CAAC,IAAI,CAAC,SAAS,KAAK,CAAK,OAAG,IAAI,CAAC,WAAW,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AAE,SAAS,EAAgB,CAAC;IAC9E,GAAG,CAAC,CAAC,aAAA,UAAU,EAAA,CAAC,GAAG,KAAK;IACxB,GAAG,EAAE,aAAa,EAAE,cAAc,IAAI,eAAQ,CAAC,KAAK;IACpD,GAAG,CAAC,CAAC,mBAAA,gBAAgB,EAAA,CAAC,GAAG,qBAAc,CAAC,CAAC;QACvC,mBAAmB,EAAE,cAAc;IACrC,CAAC;IACD,GAAG,CAAC,OAAO,GAAG,CAAC;WAAG,SAAS,CAAC,UAAU,CAAC,OAAO;IAAE,CAAC;IACjD,EAAE,GAAG,OAAO,CAAC,IAAI,EAAC,GAAG,IAAK,SAAS,CAAC,YAAY,CAAC,GAAG,CAAC,GAAG;OACtD,UAAU,GAAG,IAAI;IAEnB,GAAG,CAAC,QAAQ,GAAG,qBAAc,CAAC,KAAK;IACnC,MAAM,CAAC,CAAC;QACN,aAAa,EAAE,iBAAU,CAAC,QAAQ,EAAE,CAAC;YACnC,CAAa,cAAE,KAAK;YACpB,CAAe,gBAAE,CAAW;YAC5B,CAAW,YAAE,aAAa,GAAG,CAAQ,UAAG,CAAK;YAC7C,CAAe,gBAAE,UAAU,KAAK,IAAI;eACjC,gBAAgB;QACrB,CAAC;IACH,CAAC;AACH,CAAC;","sources":["packages/@react-aria/tag/src/index.ts","packages/@react-aria/tag/src/TagKeyboardDelegate.ts","packages/@react-aria/tag/src/useTag.ts","packages/@react-aria/tag/intl/*.js","packages/@react-aria/tag/intl/ar-AE.json","packages/@react-aria/tag/intl/bg-BG.json","packages/@react-aria/tag/intl/cs-CZ.json","packages/@react-aria/tag/intl/da-DK.json","packages/@react-aria/tag/intl/de-DE.json","packages/@react-aria/tag/intl/el-GR.json","packages/@react-aria/tag/intl/en-US.json","packages/@react-aria/tag/intl/es-ES.json","packages/@react-aria/tag/intl/et-EE.json","packages/@react-aria/tag/intl/fi-FI.json","packages/@react-aria/tag/intl/fr-FR.json","packages/@react-aria/tag/intl/he-IL.json","packages/@react-aria/tag/intl/hr-HR.json","packages/@react-aria/tag/intl/hu-HU.json","packages/@react-aria/tag/intl/it-IT.json","packages/@react-aria/tag/intl/ja-JP.json","packages/@react-aria/tag/intl/ko-KR.json","packages/@react-aria/tag/intl/lt-LT.json","packages/@react-aria/tag/intl/lv-LV.json","packages/@react-aria/tag/intl/nb-NO.json","packages/@react-aria/tag/intl/nl-NL.json","packages/@react-aria/tag/intl/pl-PL.json","packages/@react-aria/tag/intl/pt-BR.json","packages/@react-aria/tag/intl/pt-PT.json","packages/@react-aria/tag/intl/ro-RO.json","packages/@react-aria/tag/intl/ru-RU.json","packages/@react-aria/tag/intl/sk-SK.json","packages/@react-aria/tag/intl/sl-SI.json","packages/@react-aria/tag/intl/sr-SP.json","packages/@react-aria/tag/intl/sv-SE.json","packages/@react-aria/tag/intl/tr-TR.json","packages/@react-aria/tag/intl/uk-UA.json","packages/@react-aria/tag/intl/zh-CN.json","packages/@react-aria/tag/intl/zh-TW.json","packages/@react-aria/tag/src/useTagGroup.ts"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport type {TagAria} from './useTag';\nexport {TagKeyboardDelegate} from './TagKeyboardDelegate';\nexport {useTag} from './useTag';\nexport {useTagGroup} from './useTagGroup';\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {GridCollection} from '@react-types/grid';\nimport {GridKeyboardDelegate} from '@react-aria/grid';\nimport {Key} from 'react';\n\nexport class TagKeyboardDelegate<T> extends GridKeyboardDelegate<T, GridCollection<T>> {\n getFirstKey() {\n let key = this.collection.getFirstKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n getLastKey() {\n let key = this.collection.getLastKey();\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][0].key;\n\n if (this.disabledKeys.has(newKey)) {\n newKey = this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n getKeyRightOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyAbove(key) : this.getKeyBelow(key);\n }\n\n getKeyLeftOf(key: Key) {\n return this.direction === 'rtl' ? this.getKeyBelow(key) : this.getKeyAbove(key);\n }\n\n getKeyBelow(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus was on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the next item\n key = this.findNextKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the next row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // Ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyBelow(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the next row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getFirstKey();\n }\n }\n\n getKeyAbove(key) {\n let startItem = this.collection.getItem(key);\n if (!startItem) {\n return;\n }\n\n // If focus is on a cell, start searching from the parent row\n if (this.isCell(startItem)) {\n key = startItem.parentKey;\n }\n\n // Find the previous item\n key = this.findPreviousKey(key);\n if (key != null) {\n // If focus was on a cell, focus the cell with the same index in the previous row.\n if (this.isCell(startItem)) {\n let item = this.collection.getItem(key);\n let newKey = [...item.childNodes][startItem.index].key;\n\n // ignore disabled tags\n if (this.disabledKeys.has(newKey)) {\n return this.getKeyAbove(newKey);\n }\n return newKey;\n }\n\n // Otherwise, focus the previous row\n if (this.focusMode === 'row') {\n return key;\n }\n } else {\n return this.getLastKey();\n }\n }\n\n getKeyPageAbove(key) {\n return this.getKeyAbove(key);\n }\n\n getKeyPageBelow(key) {\n return this.getKeyBelow(key);\n }\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ButtonHTMLAttributes, KeyboardEvent} from 'react';\nimport {DOMAttributes} from '@react-types/shared';\nimport {filterDOMProps, mergeProps, useId} from '@react-aria/utils';\nimport {GridState} from '@react-stately/grid';\n// @ts-ignore\nimport intlMessages from '../intl/*.json';\nimport {TagProps} from '@react-types/tag';\nimport {useGridCell, useGridRow} from '@react-aria/grid';\nimport {useMessageFormatter} from '@react-aria/i18n';\n\n\nexport interface TagAria {\n labelProps: DOMAttributes,\n tagProps: DOMAttributes,\n tagRowProps: DOMAttributes,\n clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>\n}\n\nexport function useTag(props: TagProps<any>, state: GridState<any, any>): TagAria {\n let {isFocused} = props;\n const {\n isDisabled,\n isRemovable,\n onRemove,\n children,\n item,\n tagRef,\n tagRowRef\n } = props;\n const formatMessage = useMessageFormatter(intlMessages);\n const removeString = formatMessage('remove');\n const labelId = useId();\n const buttonId = useId();\n\n let {rowProps} = useGridRow({\n node: item\n }, state, tagRowRef);\n // Don't want the row to be focusable or accessible via keyboard\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n let {tabIndex, ...otherRowProps} = rowProps;\n\n let {gridCellProps} = useGridCell({\n node: [...item.childNodes][0],\n focusMode: 'cell'\n }, state, tagRef);\n\n function onKeyDown(e: KeyboardEvent<Element>) {\n if (e.key === 'Delete' || e.key === 'Backspace' || e.key === ' ') {\n onRemove(children, e);\n e.preventDefault();\n }\n }\n const pressProps = {\n onPress: e => onRemove?.(children, e)\n };\n\n isFocused = isFocused || state.selectionManager.focusedKey === item.childNodes[0].key;\n let domProps = filterDOMProps(props);\n return {\n clearButtonProps: mergeProps(pressProps, {\n 'aria-label': removeString,\n 'aria-labelledby': `${buttonId} ${labelId}`,\n id: buttonId,\n isDisabled\n }),\n labelProps: {\n id: labelId\n },\n tagRowProps: otherRowProps,\n tagProps: mergeProps(domProps, gridCellProps, {\n 'aria-disabled': isDisabled,\n 'aria-errormessage': props['aria-errormessage'],\n 'aria-label': props['aria-label'],\n onKeyDown: !isDisabled && isRemovable ? onKeyDown : null,\n tabIndex: (isFocused || state.selectionManager.focusedKey == null) && !isDisabled ? 0 : -1\n })\n };\n}\n","const _temp0 = require(\"./ar-AE.json\");\nconst _temp1 = require(\"./bg-BG.json\");\nconst _temp2 = require(\"./cs-CZ.json\");\nconst _temp3 = require(\"./da-DK.json\");\nconst _temp4 = require(\"./de-DE.json\");\nconst _temp5 = require(\"./el-GR.json\");\nconst _temp6 = require(\"./en-US.json\");\nconst _temp7 = require(\"./es-ES.json\");\nconst _temp8 = require(\"./et-EE.json\");\nconst _temp9 = require(\"./fi-FI.json\");\nconst _temp10 = require(\"./fr-FR.json\");\nconst _temp11 = require(\"./he-IL.json\");\nconst _temp12 = require(\"./hr-HR.json\");\nconst _temp13 = require(\"./hu-HU.json\");\nconst _temp14 = require(\"./it-IT.json\");\nconst _temp15 = require(\"./ja-JP.json\");\nconst _temp16 = require(\"./ko-KR.json\");\nconst _temp17 = require(\"./lt-LT.json\");\nconst _temp18 = require(\"./lv-LV.json\");\nconst _temp19 = require(\"./nb-NO.json\");\nconst _temp20 = require(\"./nl-NL.json\");\nconst _temp21 = require(\"./pl-PL.json\");\nconst _temp22 = require(\"./pt-BR.json\");\nconst _temp23 = require(\"./pt-PT.json\");\nconst _temp24 = require(\"./ro-RO.json\");\nconst _temp25 = require(\"./ru-RU.json\");\nconst _temp26 = require(\"./sk-SK.json\");\nconst _temp27 = require(\"./sl-SI.json\");\nconst _temp28 = require(\"./sr-SP.json\");\nconst _temp29 = require(\"./sv-SE.json\");\nconst _temp30 = require(\"./tr-TR.json\");\nconst _temp31 = require(\"./uk-UA.json\");\nconst _temp32 = require(\"./zh-CN.json\");\nconst _temp33 = require(\"./zh-TW.json\");\nmodule.exports = {\n \"ar-AE\": _temp0,\n \"bg-BG\": _temp1,\n \"cs-CZ\": _temp2,\n \"da-DK\": _temp3,\n \"de-DE\": _temp4,\n \"el-GR\": _temp5,\n \"en-US\": _temp6,\n \"es-ES\": _temp7,\n \"et-EE\": _temp8,\n \"fi-FI\": _temp9,\n \"fr-FR\": _temp10,\n \"he-IL\": _temp11,\n \"hr-HR\": _temp12,\n \"hu-HU\": _temp13,\n \"it-IT\": _temp14,\n \"ja-JP\": _temp15,\n \"ko-KR\": _temp16,\n \"lt-LT\": _temp17,\n \"lv-LV\": _temp18,\n \"nb-NO\": _temp19,\n \"nl-NL\": _temp20,\n \"pl-PL\": _temp21,\n \"pt-BR\": _temp22,\n \"pt-PT\": _temp23,\n \"ro-RO\": _temp24,\n \"ru-RU\": _temp25,\n \"sk-SK\": _temp26,\n \"sl-SI\": _temp27,\n \"sr-SP\": _temp28,\n \"sv-SE\": _temp29,\n \"tr-TR\": _temp30,\n \"uk-UA\": _temp31,\n \"zh-CN\": _temp32,\n \"zh-TW\": _temp33\n}","{\n \"remove\": \"إزالة\"\n}\n","{\n \"remove\": \"Премахване\"\n}\n","{\n \"remove\": \"Odebrat\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Entfernen\"\n}\n","{\n \"remove\": \"Κατάργηση\"\n}\n","{\n \"remove\": \"Remove\"\n}\n","{\n \"remove\": \"Quitar\"\n}\n","{\n \"remove\": \"Eemalda\"\n}\n","{\n \"remove\": \"Poista\"\n}\n","{\n \"remove\": \"Supprimer\"\n}\n","{\n \"remove\": \"הסר\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Eltávolítás\"\n}\n","{\n \"remove\": \"Rimuovi\"\n}\n","{\n \"remove\": \"削除\"\n}\n","{\n \"remove\": \"제거\"\n}\n","{\n \"remove\": \"Pašalinti\"\n}\n","{\n \"remove\": \"Noņemt\"\n}\n","{\n \"remove\": \"Fjern\"\n}\n","{\n \"remove\": \"Verwijderen\"\n}\n","{\n \"remove\": \"Usuń\"\n}\n","{\n \"remove\": \"Remover\"\n}\n","{\n \"remove\": \"Eliminar\"\n}\n","{\n \"remove\": \"Îndepărtaţi\"\n}\n","{\n \"remove\": \"Удалить\"\n}\n","{\n \"remove\": \"Odstrániť\"\n}\n","{\n \"remove\": \"Odstrani\"\n}\n","{\n \"remove\": \"Ukloni\"\n}\n","{\n \"remove\": \"Ta bort\"\n}\n","{\n \"remove\": \"Kaldır\"\n}\n","{\n \"remove\": \"Видалити\"\n}\n","{\n \"remove\": \"删除\"\n}\n","{\n \"remove\": \"移除\"\n}\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {DOMAttributes, DOMProps} from '@react-types/shared';\nimport {filterDOMProps, mergeProps} from '@react-aria/utils';\nimport {Key, ReactNode, useState} from 'react';\nimport {useFocusWithin} from '@react-aria/interactions';\n\ninterface AriaTagGroupProps extends DOMProps {\n children: ReactNode,\n disabledKeys?: Iterable<Key>,\n isDisabled?: boolean,\n isReadOnly?: boolean, // removes close button\n validationState?: 'valid' | 'invalid'\n}\n\ninterface TagGroupAria {\n tagGroupProps: DOMAttributes\n}\n\nexport function useTagGroup(props: AriaTagGroupProps, listState): TagGroupAria {\n let {isDisabled} = props;\n let [isFocusWithin, setFocusWithin] = useState(false);\n let {focusWithinProps} = useFocusWithin({\n onFocusWithinChange: setFocusWithin\n });\n let allKeys = [...listState.collection.getKeys()];\n if (!allKeys.some(key => !listState.disabledKeys.has(key))) {\n isDisabled = true;\n }\n let domProps = filterDOMProps(props);\n return {\n tagGroupProps: mergeProps(domProps, {\n 'aria-atomic': false,\n 'aria-relevant': 'additions',\n 'aria-live': isFocusWithin ? 'polite' : 'off',\n 'aria-disabled': isDisabled === true,\n ...focusWithinProps\n } as DOMAttributes)\n };\n}\n"],"names":[],"version":3,"file":"module.js.map"}
package/dist/types.d.ts CHANGED
@@ -1,9 +1,16 @@
1
- import { GridCollection } from "@react-types/grid";
2
- import { GridKeyboardDelegate } from "@react-aria/grid";
3
- import { Key, ButtonHTMLAttributes, HTMLAttributes, ReactNode } from "react";
1
+ import { ButtonHTMLAttributes, Key, ReactNode } from "react";
2
+ import { DOMAttributes, DOMProps } from "@react-types/shared";
4
3
  import { GridState } from "@react-stately/grid";
5
4
  import { TagProps } from "@react-types/tag";
6
- import { DOMProps } from "@react-types/shared";
5
+ import { GridCollection } from "@react-types/grid";
6
+ import { GridKeyboardDelegate } from "@react-aria/grid";
7
+ export interface TagAria {
8
+ labelProps: DOMAttributes;
9
+ tagProps: DOMAttributes;
10
+ tagRowProps: DOMAttributes;
11
+ clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>;
12
+ }
13
+ export function useTag(props: TagProps<any>, state: GridState<any, any>): TagAria;
7
14
  export class TagKeyboardDelegate<T> extends GridKeyboardDelegate<T, GridCollection<T>> {
8
15
  getFirstKey(): any;
9
16
  getLastKey(): any;
@@ -14,13 +21,6 @@ export class TagKeyboardDelegate<T> extends GridKeyboardDelegate<T, GridCollecti
14
21
  getKeyPageAbove(key: any): any;
15
22
  getKeyPageBelow(key: any): any;
16
23
  }
17
- export interface TagAria {
18
- labelProps: HTMLAttributes<HTMLElement>;
19
- tagProps: HTMLAttributes<HTMLElement>;
20
- tagRowProps: HTMLAttributes<HTMLElement>;
21
- clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>;
22
- }
23
- export function useTag(props: TagProps<any>, state: GridState<any, any>): TagAria;
24
24
  interface AriaTagGroupProps extends DOMProps {
25
25
  children: ReactNode;
26
26
  disabledKeys?: Iterable<Key>;
@@ -29,7 +29,7 @@ interface AriaTagGroupProps extends DOMProps {
29
29
  validationState?: 'valid' | 'invalid';
30
30
  }
31
31
  interface TagGroupAria {
32
- tagGroupProps: HTMLAttributes<HTMLElement>;
32
+ tagGroupProps: DOMAttributes;
33
33
  }
34
34
  export function useTagGroup(props: AriaTagGroupProps, listState: any): TagGroupAria;
35
35
 
@@ -1 +1 @@
1
- {"mappings":";;;;;;AAgBA,iCAAiC,CAAC,CAAE,SAAQ,qBAAqB,CAAC,EAAE,eAAe,CAAC,CAAC,CAAC;IACpF,WAAW;IAWX,UAAU;IAWV,aAAa,CAAC,GAAG,EAAE,GAAG;IAItB,YAAY,CAAC,GAAG,EAAE,GAAG;IAIrB,WAAW,CAAC,GAAG,KAAA;IAmCf,WAAW,CAAC,GAAG,KAAA;IAmCf,eAAe,CAAC,GAAG,KAAA;IAInB,eAAe,CAAC,GAAG,KAAA;CAGpB;ACtGD;IACE,UAAU,EAAE,eAAe,WAAW,CAAC,CAAC;IACxC,QAAQ,EAAE,eAAe,WAAW,CAAC,CAAC;IACtC,WAAW,EAAE,eAAe,WAAW,CAAC,CAAC;IACzC,gBAAgB,EAAE,qBAAqB,iBAAiB,CAAC,CAAA;CAC1D;AAED,uBAAuB,KAAK,EAAE,SAAS,GAAG,CAAC,EAAE,KAAK,EAAE,UAAU,GAAG,EAAE,GAAG,CAAC,GAAG,OAAO,CA2DhF;ACvED,2BAA4B,SAAQ,QAAQ;IAC1C,QAAQ,EAAE,SAAS,CAAC;IACpB,YAAY,CAAC,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC;IAC7B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,eAAe,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CACtC;AAED;IACE,aAAa,EAAE,eAAe,WAAW,CAAC,CAAA;CAC3C;AAED,4BAA4B,KAAK,EAAE,iBAAiB,EAAE,SAAS,KAAA,GAAG,YAAY,CAoB7E","sources":["packages/@react-aria/tag/src/packages/@react-aria/tag/src/TagKeyboardDelegate.ts","packages/@react-aria/tag/src/packages/@react-aria/tag/src/useTag.ts","packages/@react-aria/tag/src/packages/@react-aria/tag/src/useTagGroup.ts","packages/@react-aria/tag/src/packages/@react-aria/tag/src/index.ts","packages/@react-aria/tag/src/index.ts"],"sourcesContent":[null,null,null,null,"/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport * from './TagKeyboardDelegate';\nexport * from './useTag';\nexport * from './useTagGroup';\n"],"names":[],"version":3,"file":"types.d.ts.map"}
1
+ {"mappings":";;;;;;AAuBA;IACE,UAAU,EAAE,aAAa,CAAC;IAC1B,QAAQ,EAAE,aAAa,CAAC;IACxB,WAAW,EAAE,aAAa,CAAC;IAC3B,gBAAgB,EAAE,qBAAqB,iBAAiB,CAAC,CAAA;CAC1D;AAED,uBAAuB,KAAK,EAAE,SAAS,GAAG,CAAC,EAAE,KAAK,EAAE,UAAU,GAAG,EAAE,GAAG,CAAC,GAAG,OAAO,CA2DhF;ACzED,iCAAiC,CAAC,CAAE,SAAQ,qBAAqB,CAAC,EAAE,eAAe,CAAC,CAAC,CAAC;IACpF,WAAW;IAWX,UAAU;IAWV,aAAa,CAAC,GAAG,EAAE,GAAG;IAItB,YAAY,CAAC,GAAG,EAAE,GAAG;IAIrB,WAAW,CAAC,GAAG,KAAA;IAmCf,WAAW,CAAC,GAAG,KAAA;IAmCf,eAAe,CAAC,GAAG,KAAA;IAInB,eAAe,CAAC,GAAG,KAAA;CAGpB;AC3GD,2BAA4B,SAAQ,QAAQ;IAC1C,QAAQ,EAAE,SAAS,CAAC;IACpB,YAAY,CAAC,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC;IAC7B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,eAAe,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CACtC;AAED;IACE,aAAa,EAAE,aAAa,CAAA;CAC7B;AAED,4BAA4B,KAAK,EAAE,iBAAiB,EAAE,SAAS,KAAA,GAAG,YAAY,CAoB7E","sources":["packages/@react-aria/tag/src/packages/@react-aria/tag/src/useTag.ts","packages/@react-aria/tag/src/packages/@react-aria/tag/src/TagKeyboardDelegate.ts","packages/@react-aria/tag/src/packages/@react-aria/tag/src/useTagGroup.ts","packages/@react-aria/tag/src/packages/@react-aria/tag/src/index.ts","packages/@react-aria/tag/src/index.ts"],"sourcesContent":[null,null,null,null,"/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nexport type {TagAria} from './useTag';\nexport {TagKeyboardDelegate} from './TagKeyboardDelegate';\nexport {useTag} from './useTag';\nexport {useTagGroup} from './useTagGroup';\n"],"names":[],"version":3,"file":"types.d.ts.map"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-aria/tag",
3
- "version": "3.0.0-nightly.1658+a5a9d95db",
3
+ "version": "3.0.0-nightly.1663+2a6c48eb0",
4
4
  "description": "Spectrum UI components in React",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/main.js",
@@ -18,14 +18,14 @@
18
18
  },
19
19
  "dependencies": {
20
20
  "@babel/runtime": "^7.6.2",
21
- "@react-aria/grid": "3.3.2-nightly.3358+a5a9d95db",
22
- "@react-aria/i18n": "3.0.0-nightly.1658+a5a9d95db",
23
- "@react-aria/interactions": "3.0.0-nightly.1658+a5a9d95db",
24
- "@react-aria/utils": "3.0.0-nightly.1658+a5a9d95db",
25
- "@react-stately/grid": "3.2.2-nightly.3358+a5a9d95db",
26
- "@react-types/grid": "3.1.2-nightly.3358+a5a9d95db",
27
- "@react-types/shared": "3.0.0-nightly.1658+a5a9d95db",
28
- "@react-types/tag": "3.0.0-nightly.1658+a5a9d95db"
21
+ "@react-aria/grid": "3.3.2-nightly.3363+2a6c48eb0",
22
+ "@react-aria/i18n": "3.0.0-nightly.1663+2a6c48eb0",
23
+ "@react-aria/interactions": "3.0.0-nightly.1663+2a6c48eb0",
24
+ "@react-aria/utils": "3.0.0-nightly.1663+2a6c48eb0",
25
+ "@react-stately/grid": "3.2.2-nightly.3363+2a6c48eb0",
26
+ "@react-types/grid": "3.1.2-nightly.3363+2a6c48eb0",
27
+ "@react-types/shared": "3.0.0-nightly.1663+2a6c48eb0",
28
+ "@react-types/tag": "3.0.0-nightly.1663+2a6c48eb0"
29
29
  },
30
30
  "peerDependencies": {
31
31
  "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0"
@@ -33,5 +33,5 @@
33
33
  "publishConfig": {
34
34
  "access": "public"
35
35
  },
36
- "gitHead": "a5a9d95db94da277dca6267cca8bbe55dd6ccc69"
36
+ "gitHead": "2a6c48eb0099671cf9b530ec3d75882c549e9cb5"
37
37
  }
package/src/index.ts CHANGED
@@ -10,6 +10,7 @@
10
10
  * governing permissions and limitations under the License.
11
11
  */
12
12
 
13
- export * from './TagKeyboardDelegate';
14
- export * from './useTag';
15
- export * from './useTagGroup';
13
+ export type {TagAria} from './useTag';
14
+ export {TagKeyboardDelegate} from './TagKeyboardDelegate';
15
+ export {useTag} from './useTag';
16
+ export {useTagGroup} from './useTagGroup';
package/src/useTag.ts CHANGED
@@ -10,7 +10,8 @@
10
10
  * governing permissions and limitations under the License.
11
11
  */
12
12
 
13
- import {ButtonHTMLAttributes, HTMLAttributes, KeyboardEvent} from 'react';
13
+ import {ButtonHTMLAttributes, KeyboardEvent} from 'react';
14
+ import {DOMAttributes} from '@react-types/shared';
14
15
  import {filterDOMProps, mergeProps, useId} from '@react-aria/utils';
15
16
  import {GridState} from '@react-stately/grid';
16
17
  // @ts-ignore
@@ -21,9 +22,9 @@ import {useMessageFormatter} from '@react-aria/i18n';
21
22
 
22
23
 
23
24
  export interface TagAria {
24
- labelProps: HTMLAttributes<HTMLElement>,
25
- tagProps: HTMLAttributes<HTMLElement>,
26
- tagRowProps: HTMLAttributes<HTMLElement>,
25
+ labelProps: DOMAttributes,
26
+ tagProps: DOMAttributes,
27
+ tagRowProps: DOMAttributes,
27
28
  clearButtonProps: ButtonHTMLAttributes<HTMLButtonElement>
28
29
  }
29
30
 
@@ -55,7 +56,7 @@ export function useTag(props: TagProps<any>, state: GridState<any, any>): TagAri
55
56
  focusMode: 'cell'
56
57
  }, state, tagRef);
57
58
 
58
- function onKeyDown(e: KeyboardEvent<HTMLElement>) {
59
+ function onKeyDown(e: KeyboardEvent<Element>) {
59
60
  if (e.key === 'Delete' || e.key === 'Backspace' || e.key === ' ') {
60
61
  onRemove(children, e);
61
62
  e.preventDefault();
@@ -10,9 +10,9 @@
10
10
  * governing permissions and limitations under the License.
11
11
  */
12
12
 
13
- import {DOMProps} from '@react-types/shared';
13
+ import {DOMAttributes, DOMProps} from '@react-types/shared';
14
14
  import {filterDOMProps, mergeProps} from '@react-aria/utils';
15
- import {HTMLAttributes, Key, ReactNode, useState} from 'react';
15
+ import {Key, ReactNode, useState} from 'react';
16
16
  import {useFocusWithin} from '@react-aria/interactions';
17
17
 
18
18
  interface AriaTagGroupProps extends DOMProps {
@@ -24,7 +24,7 @@ interface AriaTagGroupProps extends DOMProps {
24
24
  }
25
25
 
26
26
  interface TagGroupAria {
27
- tagGroupProps: HTMLAttributes<HTMLElement>
27
+ tagGroupProps: DOMAttributes
28
28
  }
29
29
 
30
30
  export function useTagGroup(props: AriaTagGroupProps, listState): TagGroupAria {
@@ -45,6 +45,6 @@ export function useTagGroup(props: AriaTagGroupProps, listState): TagGroupAria {
45
45
  'aria-live': isFocusWithin ? 'polite' : 'off',
46
46
  'aria-disabled': isDisabled === true,
47
47
  ...focusWithinProps
48
- } as HTMLAttributes<HTMLElement>)
48
+ } as DOMAttributes)
49
49
  };
50
50
  }