@esri/calcite-components 5.1.0-next.51 → 5.1.0-next.53

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 (156) hide show
  1. package/dist/cdn/{ZMX2MKUW.js → 2NNRJTQ3.js} +1 -1
  2. package/dist/cdn/{QLOR2RB5.js → 2VFFQBRM.js} +1 -1
  3. package/dist/cdn/{C53YAAVC.js → 374BVOQW.js} +1 -1
  4. package/dist/cdn/{PDXU6HPZ.js → 3C3ZPDYP.js} +1 -1
  5. package/dist/cdn/{WBP7WHU4.js → 3R6YKVGT.js} +1 -1
  6. package/dist/cdn/{IZEFSP2C.js → 3VHKPO2P.js} +1 -1
  7. package/dist/cdn/{RGLUZ76B.js → 46NKKCSK.js} +1 -1
  8. package/dist/cdn/{HGRS2NBC.js → 52ZZNTUN.js} +1 -1
  9. package/dist/cdn/5GQVDBDB.js +2 -0
  10. package/dist/cdn/{NPKYZEEF.js → 5NGMYY26.js} +1 -1
  11. package/dist/cdn/{7RZYNANK.js → 5SVZLVMH.js} +1 -1
  12. package/dist/cdn/{7ECSU3T3.js → 6E2D3DUD.js} +1 -1
  13. package/dist/cdn/{MU5LNKS7.js → 6G54JNZ3.js} +1 -1
  14. package/dist/cdn/{ZKHWMGW5.js → 6MNWSHJ2.js} +1 -1
  15. package/dist/cdn/{MVK6LWK5.js → 6P7QJ4OD.js} +1 -1
  16. package/dist/cdn/{MRXZATZZ.js → 6VOREOHN.js} +1 -1
  17. package/dist/cdn/{FB545PKU.js → 7ARUHJIG.js} +1 -1
  18. package/dist/cdn/{M4BORA6H.js → 7HZB4NYI.js} +1 -1
  19. package/dist/cdn/{M77EYDBR.js → 7NI5WUF3.js} +1 -1
  20. package/dist/cdn/{4J3DARRE.js → 7P64IPQZ.js} +1 -1
  21. package/dist/cdn/{DWPX74WA.js → 7U3I7VRF.js} +1 -1
  22. package/dist/cdn/{MUMG74E5.js → AOREK7XG.js} +1 -1
  23. package/dist/cdn/{43E5QBXB.js → AQB4NRJ6.js} +1 -1
  24. package/dist/cdn/{MAH7GW3L.js → AX7IKIXB.js} +1 -1
  25. package/dist/cdn/{RPAL2ENA.js → B55L2WAB.js} +1 -1
  26. package/dist/cdn/{3ZXALV6G.js → BE7EEFQ3.js} +1 -1
  27. package/dist/cdn/{SXV7WCPS.js → BJY3GM77.js} +1 -1
  28. package/dist/cdn/{NIASU3O6.js → BMJZRWPQ.js} +1 -1
  29. package/dist/cdn/{MYKZPZDR.js → BTJXCIJF.js} +1 -1
  30. package/dist/cdn/{KWNGJXWC.js → BUYT2OB4.js} +1 -1
  31. package/dist/cdn/{UPTGE4WC.js → CCDFL6R7.js} +1 -1
  32. package/dist/cdn/{U63LB523.js → CMDW563I.js} +1 -1
  33. package/dist/cdn/{4RTJFM5B.js → COIF2UAL.js} +1 -1
  34. package/dist/cdn/{GFPWU57X.js → CW5DSGCU.js} +1 -1
  35. package/dist/cdn/{OL7ZYBX6.js → DBMOHP75.js} +1 -1
  36. package/dist/cdn/{75SY2WE4.js → DT26BBAC.js} +1 -1
  37. package/dist/cdn/{QJBPXLTP.js → DZLM5KCC.js} +1 -1
  38. package/dist/cdn/{CDSIG642.js → DZNJ47YX.js} +1 -1
  39. package/dist/cdn/{IHLWJXZV.js → EJUBVZVG.js} +1 -1
  40. package/dist/cdn/{AR7ZPQQG.js → ELGTRNFS.js} +1 -1
  41. package/dist/cdn/{4F5KQIRB.js → EQPMYOET.js} +1 -1
  42. package/dist/cdn/{QVXAQXDL.js → F4YFAW3E.js} +1 -1
  43. package/dist/cdn/{SKAIHX6Z.js → FLS2RIBD.js} +1 -1
  44. package/dist/cdn/{2RVF53XU.js → FMYXWCIG.js} +1 -1
  45. package/dist/cdn/{7NDXWX7R.js → G5ZTMQIQ.js} +1 -1
  46. package/dist/cdn/{AK66BMBC.js → G7NS66JL.js} +1 -1
  47. package/dist/cdn/{IIBZXYLU.js → GBBBONE4.js} +1 -1
  48. package/dist/cdn/{4R54D2BX.js → GM4IXLKU.js} +1 -1
  49. package/dist/cdn/{CRL6VQWS.js → GMFFXYYG.js} +1 -1
  50. package/dist/cdn/{S7EIG7Q5.js → GNOGZAA3.js} +1 -1
  51. package/dist/cdn/{R2ZRQO3L.js → H74DQJ5F.js} +1 -1
  52. package/dist/cdn/{JA5TE633.js → I4UCJQSK.js} +1 -1
  53. package/dist/cdn/{I24CZVLP.js → IQOUDTMQ.js} +1 -1
  54. package/dist/cdn/{K7UPFMP3.js → IYDA2M2N.js} +1 -1
  55. package/dist/cdn/{HPVBLELP.js → J47CBEIO.js} +1 -1
  56. package/dist/cdn/{BF7DR726.js → JGLBWEES.js} +1 -1
  57. package/dist/cdn/{3FXX3SBS.js → JMR6BPUR.js} +1 -1
  58. package/dist/cdn/{XUYLYALV.js → JZUVLVC3.js} +1 -1
  59. package/dist/cdn/{JLGDNYBI.js → K6LR7A3G.js} +1 -1
  60. package/dist/cdn/{JKAB4LS7.js → KEGLBRYW.js} +1 -1
  61. package/dist/cdn/{ZRXGDZZT.js → KIVCCNSA.js} +1 -1
  62. package/dist/cdn/{C42SNF33.js → KMRVKC2B.js} +1 -1
  63. package/dist/cdn/{2VEIQ62E.js → L7VRUUJ5.js} +1 -1
  64. package/dist/cdn/{MFLXU5FA.js → L7WEEHWA.js} +1 -1
  65. package/dist/cdn/{LSOSPUDS.js → LQ2L5WDO.js} +1 -1
  66. package/dist/cdn/{BHS72XYT.js → LU3AN5PO.js} +1 -1
  67. package/dist/cdn/{456IFPIW.js → MB3SHKVV.js} +1 -1
  68. package/dist/cdn/{DAQX6BT3.js → MKHCIJUO.js} +1 -1
  69. package/dist/cdn/{6TSA7FLB.js → MMXNR5RX.js} +1 -1
  70. package/dist/cdn/{LA3AJSXV.js → MOK6MFBM.js} +1 -1
  71. package/dist/cdn/{VRI5YMPE.js → N73KWKN3.js} +1 -1
  72. package/dist/cdn/{3BZBBTUA.js → NGYBT3KZ.js} +1 -1
  73. package/dist/cdn/{6D5PCSHS.js → NUSST644.js} +1 -1
  74. package/dist/cdn/{EW3UPJT7.js → NUW2SVAZ.js} +1 -1
  75. package/dist/cdn/{KXSIX7V7.js → NXNHPGTQ.js} +1 -1
  76. package/dist/cdn/{P6VMV62Z.js → OGYP4PT3.js} +1 -1
  77. package/dist/cdn/{H6UBX3WZ.js → OH2HEEFB.js} +1 -1
  78. package/dist/cdn/{GTALENKO.js → OKMZYNYT.js} +1 -1
  79. package/dist/cdn/{TGQJUML7.js → OMJD4F3K.js} +1 -1
  80. package/dist/cdn/{73ORJJZS.js → OSG4TJAG.js} +1 -1
  81. package/dist/cdn/{ZEUCKTPG.js → OUOS6BJZ.js} +1 -1
  82. package/dist/cdn/{K43SJYRB.js → OZRCBV7E.js} +1 -1
  83. package/dist/cdn/{OFR37WBK.js → P2WOGWXH.js} +1 -1
  84. package/dist/cdn/{KIIYDDSF.js → P56VBKLA.js} +1 -1
  85. package/dist/cdn/{AEPM5SJO.js → P6DAEHHY.js} +1 -1
  86. package/dist/cdn/{5WVRAQRW.js → PAIESPRF.js} +1 -1
  87. package/dist/cdn/{5M27WGKA.js → PF62P6EA.js} +1 -1
  88. package/dist/cdn/{TZ7BLX2N.js → PFZ2Y2IO.js} +1 -1
  89. package/dist/cdn/{A2KNWLOL.js → PJIRZ5JN.js} +1 -1
  90. package/dist/cdn/{3B5PYTVX.js → PV4NC3RW.js} +1 -1
  91. package/dist/cdn/{QTHYRIFY.js → QJ6JEAFQ.js} +1 -1
  92. package/dist/cdn/{USOHYTXD.js → QNF3JMOQ.js} +1 -1
  93. package/dist/cdn/{H5UVCR64.js → R67UKCVU.js} +1 -1
  94. package/dist/cdn/{PJ4SD5FY.js → R6UGDU2R.js} +1 -1
  95. package/dist/cdn/{3JTJC2PS.js → RQP3QJZI.js} +1 -1
  96. package/dist/cdn/{SCXKWH7Z.js → RVDBHDXS.js} +1 -1
  97. package/dist/cdn/{HULUX4S6.js → RYI46JK6.js} +1 -1
  98. package/dist/cdn/{52IJCUEV.js → S4O5SCPG.js} +1 -1
  99. package/dist/cdn/{2MK42DZ4.js → S5CHO4U4.js} +1 -1
  100. package/dist/cdn/{UY7QVK74.js → SEOCJRMP.js} +1 -1
  101. package/dist/cdn/{PPBHKZJI.js → SH5OX57L.js} +1 -1
  102. package/dist/cdn/{HPWLGQL6.js → SHNVFDYZ.js} +1 -1
  103. package/dist/cdn/{U6HPCAAW.js → SJ2QKTB2.js} +1 -1
  104. package/dist/cdn/{2I23BJUK.js → SKNYDJDG.js} +1 -1
  105. package/dist/cdn/{WZ6F5SCK.js → SZKYMSWE.js} +1 -1
  106. package/dist/cdn/{ISMO77VP.js → T3SBFTTU.js} +1 -1
  107. package/dist/cdn/{5EOFDLJO.js → TG3SE24X.js} +1 -1
  108. package/dist/cdn/{7GZ4RW44.js → TG44VRS3.js} +1 -1
  109. package/dist/cdn/{XYFV7S74.js → TGFI5Y54.js} +1 -1
  110. package/dist/cdn/{VHLCDJKY.js → TMF6RUSK.js} +1 -1
  111. package/dist/cdn/{KJUZSP7X.js → TOJO3DZJ.js} +1 -1
  112. package/dist/cdn/{KC5UAIPG.js → TQSBMZUH.js} +1 -1
  113. package/dist/cdn/{NL6QGGPB.js → UPMXPJRW.js} +1 -1
  114. package/dist/cdn/UWICRJQO.js +2 -0
  115. package/dist/cdn/{X44HUYME.js → UYLTPVFT.js} +1 -1
  116. package/dist/cdn/{KDMQ3W3P.js → VFFODXE5.js} +1 -1
  117. package/dist/cdn/{ZOQOJDXL.js → VGIY62WD.js} +1 -1
  118. package/dist/cdn/{JOTX7MS6.js → VKN6JJHH.js} +1 -1
  119. package/dist/cdn/{AEZOU5JE.js → VXD77BNL.js} +1 -1
  120. package/dist/cdn/{PLG6IIYK.js → W4U75XMI.js} +1 -1
  121. package/dist/cdn/{6BFJTIPA.js → WG4Y2YXD.js} +1 -1
  122. package/dist/cdn/{36JLOHBC.js → WU2FYJPY.js} +1 -1
  123. package/dist/cdn/{X2NBQO5I.js → X2VMJBUA.js} +1 -1
  124. package/dist/cdn/X3KQ4SRN.js +4 -0
  125. package/dist/cdn/{4HQ5QYH2.js → X3X7MERT.js} +1 -1
  126. package/dist/cdn/{B6R2YN2X.js → X4R2U7OM.js} +1 -1
  127. package/dist/cdn/{KVNTMFIR.js → XBBOJCAG.js} +1 -1
  128. package/dist/cdn/{Q75PWKQ3.js → XD3JL5DR.js} +1 -1
  129. package/dist/cdn/{DUAPF33E.js → XNHSUYWZ.js} +1 -1
  130. package/dist/cdn/{RRJKRT7F.js → XVE4JN3H.js} +1 -1
  131. package/dist/cdn/{NKBT2QG4.js → XW3IP2CH.js} +1 -1
  132. package/dist/cdn/{TSNOYPVI.js → Y5EX4HUW.js} +1 -1
  133. package/dist/cdn/{VFLSIH3H.js → YBTRE55X.js} +1 -1
  134. package/dist/cdn/{HM2E526S.js → YGSUEQMS.js} +1 -1
  135. package/dist/cdn/{XUU2MRGP.js → YONIKQC3.js} +1 -1
  136. package/dist/cdn/{WXDRYIO2.js → YRBYKWDO.js} +1 -1
  137. package/dist/cdn/{XKYXT27V.js → YZ6XKB4F.js} +1 -1
  138. package/dist/cdn/{T4Q6C4CT.js → YZIPHHRW.js} +1 -1
  139. package/dist/cdn/{4TA4AAFT.js → Z7XEAFTW.js} +1 -1
  140. package/dist/cdn/{PIKLS5KR.js → ZELB53ZU.js} +1 -1
  141. package/dist/cdn/{WCTTX5WL.js → ZER7OLYY.js} +1 -1
  142. package/dist/cdn/{IRVWWA2A.js → ZFSMJ5LH.js} +1 -1
  143. package/dist/cdn/{ZQCRV5XI.js → ZO3LKLON.js} +1 -1
  144. package/dist/cdn/index.js +1 -1
  145. package/dist/chunks/runtime.js +4 -4
  146. package/dist/components/calcite-combobox/customElement.js +1 -1
  147. package/dist/components/calcite-dialog/customElement.js +1 -1
  148. package/dist/components/calcite-sheet/customElement.js +1 -1
  149. package/dist/components/calcite-tree/customElement.js +1 -1
  150. package/dist/docs/api.json +1 -1
  151. package/dist/docs/docs.json +1 -1
  152. package/dist/docs/web-types.json +1 -1
  153. package/package.json +11 -11
  154. package/dist/cdn/3N3O22QG.js +0 -2
  155. package/dist/cdn/CJGERVGF.js +0 -4
  156. package/dist/cdn/EBGVT22W.js +0 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@esri/calcite-components",
3
- "version": "5.1.0-next.51",
3
+ "version": "5.1.0-next.53",
4
4
  "description": "Web Components for Esri's Calcite Design System.",
5
5
  "homepage": "https://developers.arcgis.com/calcite-design-system/",
6
6
  "repository": {
@@ -50,13 +50,13 @@
50
50
  "screenshot-tests:preview": "npm run util:prep-build-reqs && NODE_OPTIONS=--openssl-legacy-provider STORYBOOK_SCREENSHOT_LOCAL_BUILD=true storybook dev",
51
51
  "screenshot-tests:publish": "npm run screenshot-tests && storybook-to-ghpages --existing-output-dir=docs",
52
52
  "start": "npm run util:clean-js-files && concurrently --kill-others --raw \"trap 'npm run util:clean-js-files' INT TERM EXIT >/dev/null 2>&1 || true && tsc --project ./tsconfig.demos.json --watch\" \"npm run build:watch-dev\"",
53
- "test": "concurrently --passthrough-arguments \"npm:test:stable -- {@}\" \"npm:test:experimental -- {@}\" --",
54
- "test:ci": "concurrently --passthrough-arguments --names stable,experimental \"npm run test:stable 2>test-stable.err.log\" \"npm run test:experimental 2>test-experimental.err.log\" || node ./support/log-test-output.mts",
55
- "test:stable": "vitest run",
56
- "test:experimental": "npm run util:install-playwright && EXPERIMENTAL_TESTS=true vitest run",
57
- "test:watch": "concurrently --passthrough-arguments \"npm run test:watch:stable -- {@}\" \"npm run test:watch:experimental -- {@}\" --",
58
- "test:watch:stable": "vitest watch",
59
- "test:watch:experimental": "npm run util:install-playwright && EXPERIMENTAL_TESTS=true vitest watch",
53
+ "test": "concurrently --passthrough-arguments \"npm:test:node -- {@}\" \"npm:test:browser -- {@}\" --",
54
+ "test:ci": "concurrently --passthrough-arguments --names node,browser \"npm run test:node 2>test-node.err.log\" \"npm run test:browser 2>test-browser.err.log\" || node ./support/log-test-output.mts",
55
+ "test:node": "vitest run",
56
+ "test:browser": "npm run util:install-playwright && BROWSER_TESTS=true vitest run",
57
+ "test:watch": "concurrently --passthrough-arguments \"npm run test:watch:node -- {@}\" \"npm run test:watch:browser -- {@}\" --",
58
+ "test:watch:node": "vitest watch",
59
+ "test:watch:browser": "npm run util:install-playwright && BROWSER_TESTS=true vitest watch",
60
60
  "util:add-internal-custom-css-prop-doc": "node support/add-internal-custom-prop-doc.ts",
61
61
  "util:clean-js-files": "rimraf --glob -- *.js {src,.storybook,support}/**/*.js",
62
62
  "util:install-playwright": "node support/install-playwright.ts",
@@ -74,14 +74,14 @@
74
74
  "dependencies": {
75
75
  "@arcgis/lumina": ">=5.1.0-next.96 <6.0.0",
76
76
  "@arcgis/toolkit": ">=5.1.0-next.96 <6.0.0",
77
- "@esri/calcite-ui-icons": "4.5.0-next.13",
77
+ "@esri/calcite-ui-icons": "4.5.0-next.14",
78
78
  "@floating-ui/dom": "^1.6.12",
79
79
  "@floating-ui/utils": "^0.2.8",
80
80
  "@types/sortablejs": "^1.15.8",
81
81
  "color": "^5.0.3",
82
82
  "composed-offset-position": "^0.0.6",
83
83
  "es-toolkit": "^1.39.8",
84
- "focus-trap": "^8.0.1",
84
+ "focus-trap": "^8.2.1",
85
85
  "interactjs": "^1.10.27",
86
86
  "lit": "^3.3.0",
87
87
  "sortablejs": "^1.15.6",
@@ -106,5 +106,5 @@
106
106
  "dist/docs/vscode.html-custom-data.json"
107
107
  ],
108
108
  "web-types": "dist/docs/web-types.json",
109
- "gitHead": "afc65b899f7a66bed1550a58025e4bad57f7b5e5"
109
+ "gitHead": "f700da4ec7eb8b3e3adb10625d823edab1f8cbf7"
110
110
  }
@@ -1,2 +0,0 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as j}from"./BF7DR726.js";import{a as y,b as K}from"./X44HUYME.js";import{a as _}from"./CJGERVGF.js";import{a as S}from"./3PITBECR.js";import{a as F}from"./KDMQ3W3P.js";import{a as U}from"./I24CZVLP.js";import{a as H}from"./NIASU3O6.js";import{a as u}from"./WKR7R7AZ.js";import{a as E}from"./ENDXE7YY.js";import{a as A}from"./IHLWJXZV.js";import{a as P}from"./HM2E526S.js";import"./WGGFNK4Z.js";import{e as L}from"./P6VMV62Z.js";import"./JKAB4LS7.js";import{D as h,b as M}from"./QVXAQXDL.js";import"./OAOQ5BXS.js";import{E as w,F as b,G as C,H as d,K as O,M as R,O as V,P as $,S as T,g as D,h as g,p as m}from"./ZRXGDZZT.js";var l={scrim:"scrim",container:"container",containerOpen:"container--open",content:"content",contentContainer:"content-container",containerEmbedded:"container--embedded",resizeHandle:"resize-handle",resizeHandleBar:"resize-handle-bar"},Y={sheetContent:"sheet-content"},N={dragVertical:"drag-resize-vertical",dragHorizontal:"drag-resize-horizontal"},Z=D`:host{position:absolute;inset:0;display:flex;visibility:hidden!important;--calcite-sheet-scrim-background-internal: rgba(0, 0, 0, .85);--calcite-scrim-shadow-block-start-internal: 0 4px 8px -1px rgba(0, 0, 0, .08), 0 2px 4px -1px rgba(0, 0, 0, .04);--calcite-scrim-shadow-block-end-internal: 0 -4px 8px -1px rgba(0, 0, 0, .08), 0 -2px 4px -1px rgba(0, 0, 0, .04);--calcite-scrim-shadow-inline-start-internal: 4px 0 8px -1px rgba(0, 0, 0, .08), 2px 0 4px -1px rgba(0, 0, 0, .04);--calcite-scrim-shadow-inline-end-internal: -4px 0 8px -1px rgba(0, 0, 0, .08), -2px 0 4px -1px rgba(0, 0, 0, .04)}:host([embedded]){z-index:var(--calcite-z-index-overlay)}.calcite--rtl{--calcite-scrim-shadow-inline-start-internal: -4px 0 8px -1px rgba(0, 0, 0, .08), -2px 0 4px -1px rgba(0, 0, 0, .04);--calcite-scrim-shadow-inline-end-internal: 4px 0 8px -1px rgba(0, 0, 0, .08), 2px 0 4px -1px rgba(0, 0, 0, .04)}.assistive-text{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.container{visibility:hidden;position:fixed;box-sizing:border-box;display:flex;opacity:0;color:var(--calcite-sheet-text-color, var(--calcite-color-text-2));transition:visibility 0ms linear var(--calcite-internal-animation-timing-medium),opacity var(--calcite-internal-animation-timing-medium) ease-in-out}:host([top-layer-disabled]) .container,:host([embedded]) .container{z-index:var(--calcite-z-index-overlay)}:host([position=inline-start]) .container{justify-content:flex-start;inset-block:0;inset-inline:0 auto;--calcite-sheet-hidden-position-internal: translate3d(-1rem, 0, 0)}:host([position=inline-end]) .container{justify-content:flex-end;inset-block:0;inset-inline:auto 0;--calcite-sheet-hidden-position-internal: translate3d(1rem, 0, 0)}:host([position=block-start]) .container{align-items:flex-start;inset-block:0 auto;inset-inline:0;--calcite-sheet-hidden-position-internal: translate3d(0, -1rem, 0)}:host([position=block-end]) .container{align-items:flex-end;inset-block:auto 0;inset-inline:0;--calcite-sheet-hidden-position-internal: translate3d(0, 1rem, 0)}:host([display-mode=float]) .content{--tw-shadow: 0 2px 12px -4px rgba(0, 0, 0, .2), 0 2px 4px -2px rgba(0, 0, 0, .16);--tw-shadow-colored: 0 2px 12px -4px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--calcite-sheet-shadow, var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)), var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)), var(--tw-shadow))}:host([display-mode=overlay][position=inline-start]) .container{box-shadow:var(--calcite-scrim-shadow-inline-start-internal)}:host([display-mode=overlay][position=inline-end]) .container{box-shadow:var(--calcite-scrim-shadow-inline-end-internal)}:host([display-mode=overlay][position=block-start]) .container{box-shadow:var(--calcite-scrim-shadow-block-start-internal)}:host([display-mode=overlay][position=block-end]) .container{box-shadow:var(--calcite-scrim-shadow-block-end-internal)}:host([position^=inline]) .content{inline-size:var(--calcite-sheet-width-internal);max-inline-size:var(--calcite-sheet-max-width-internal);min-inline-size:var(--calcite-sheet-min-width-internal)}:host([position^=block]) .content{block-size:var(--calcite-sheet-height-internal);max-block-size:var(--calcite-sheet-max-height-internal);min-block-size:var(--calcite-sheet-min-height-internal)}:host([position^=inline]) .width-s{--calcite-sheet-width-internal: var(--calcite-sheet-width, 15vw);--calcite-sheet-max-width-internal: var(--calcite-sheet-max-width, 360px);--calcite-sheet-min-width-internal: var(--calcite-sheet-min-width, 260px)}:host([position^=inline]) .width-m{--calcite-sheet-width-internal: var(--calcite-sheet-width, 25vw);--calcite-sheet-max-width-internal: var(--calcite-sheet-max-width, 420px);--calcite-sheet-min-width-internal: var(--calcite-sheet-min-width, 300px)}:host([position^=inline]) .width-l{--calcite-sheet-width-internal: var(--calcite-sheet-width, 45vw);--calcite-sheet-max-width-internal: var(--calcite-sheet-max-width, 680px);--calcite-sheet-min-width-internal: var(--calcite-sheet-min-width, 340px)}:host([position^=block]) .height-s{--calcite-sheet-min-height-internal: var(--calcite-sheet-min-height, 160px);--calcite-sheet-height-internal: var(--calcite-sheet-height, 30vh);--calcite-sheet-max-height-internal: var(--calcite-sheet-max-height, 30vh)}:host([position^=block]) .height-m{--calcite-sheet-min-height-internal: var(--calcite-sheet-min-height, 200px);--calcite-sheet-height-internal: var(--calcite-sheet-height, 45vh);--calcite-sheet-max-height-internal: var(--calcite-sheet-max-height, 50vh)}:host([position^=block]) .height-l{--calcite-sheet-min-height-internal: var(--calcite-sheet-min-height, 240px);--calcite-sheet-height-internal: var(--calcite-sheet-height, 60vh);--calcite-sheet-max-height-internal: var(--calcite-sheet-max-height, 70vh)}.scrim{--calcite-scrim-background: var(--calcite-sheet-scrim-background, var(--calcite-sheet-scrim-background-internal));position:fixed;inset:0;display:flex;overflow:hidden;z-index:calc(var(--calcite-z-index) * -1)}:host([top-layer-disabled]) .scrim{z-index:unset}[popover]{padding:0;margin:0;border:none;background-color:transparent;position:fixed;display:flex;inline-size:100%;block-size:100%}[popover]:popover-open{display:flex}:host([opened]){visibility:visible!important}.content{position:relative;box-sizing:border-box;display:flex;max-inline-size:100%;padding:0;background-color:var(--calcite-sheet-background-color, var(--calcite-color-foreground-1));max-block-size:100%;visibility:hidden;transition:transform var(--calcite-internal-animation-timing-medium) ease-in-out,visibility 0ms linear var(--calcite-internal-animation-timing-medium),opacity var(--calcite-internal-animation-timing-medium) ease-in-out;transform:var(--calcite-sheet-hidden-position-internal)}:host([top-layer-disabled]),:host([top-layer-disabled]) .content,:host([embedded]) .content{z-index:var(--calcite-z-index-modal)}.content-container{position:relative;display:flex;max-block-size:100%;max-inline-size:100%;flex:1 1 0%;overflow:hidden}.content-container ::slotted(*){block-size:auto}.container--open .content{transform:translateZ(0)}:host([display-mode=float]) .content,:host([display-mode=float]) .container,:host([display-mode=float]) .content-container{border-radius:var(--calcite-sheet-corner-radius, var(--calcite-corner-radius-round))}:host([display-mode=float]) .container{padding:var(--calcite-spacing-md)}.container--open{visibility:visible;opacity:1;transition-delay:0ms}.container--open .content{pointer-events:auto;visibility:visible;opacity:1;transition:transform var(--calcite-internal-animation-timing-medium) ease-in-out,visibility 0ms linear,opacity var(--calcite-internal-animation-timing-medium) ease-in-out,max-inline-size var(--calcite-internal-animation-timing-medium) ease-in-out,max-block-size var(--calcite-internal-animation-timing-medium) ease-in-out;transition-delay:0ms}@starting-style{.container--open{opacity:0;visibility:hidden}}:host([position=inline-start]) .content,:host([position=inline-end]) .content{block-size:100%}:host([position=inline-start]) .content{flex-direction:row}:host([position=inline-end]) .content{flex-direction:row-reverse}:host([position=block-start]) .content,:host([position=block-end]) .content{inline-size:100%}:host([position=block-start]) .content{flex-direction:column}:host([position=block-end]) .content{flex-direction:column-reverse}:host([resizable][position=inline-start]) .content{padding-inline-end:var(--calcite-size-fixed-sm-plus)}:host([resizable][position=inline-end]) .content{padding-inline-start:var(--calcite-size-fixed-sm-plus)}:host([resizable][position=block-start]) .content{padding-block-end:var(--calcite-size-fixed-sm-plus)}:host([resizable][position=block-end]) .content{padding-block-start:var(--calcite-size-fixed-sm-plus)}.resize-handle{position:absolute;box-sizing:border-box;display:flex;-webkit-user-select:none;user-select:none;align-items:center;justify-content:center;outline:2px solid transparent;outline-offset:2px;--calcite-internal-sheet-resize-handle-offset: calc( (var(--calcite-size-fixed-xxl) - var(--calcite-size-fixed-sm-plus)) / 2 * -1 );z-index:var(--calcite-z-index-header)}.resize-handle:active .resize-handle-bar,.resize-handle:hover .resize-handle-bar{color:var(--calcite-sheet-resize-icon-color, var(--calcite-color-text-1));background-color:var(--calcite-sheet-resize-background-color, var(--calcite-color-foreground-3))}.resize-handle-bar{pointer-events:none;display:flex;align-items:center;justify-content:center;color:var(--calcite-sheet-resize-icon-color, var(--calcite-color-border-input));background-color:var(--calcite-sheet-resize-background-color, var(--calcite-color-background))}.resize-handle:focus .resize-handle-bar{outline-color:transparent;outline:var(--calcite-border-width-md) solid var(--calcite-color-focus, var(--calcite-ui-focus-color, var(--calcite-color-brand)))}:host([position=inline-start]) .resize-handle{inline-size:var(--calcite-size-fixed-xxl);inset-inline-end:var(--calcite-internal-sheet-resize-handle-offset);block-size:100%}:host([position=inline-start]) .resize-handle-bar{block-size:100%;inline-size:var(--calcite-size-fixed-sm-plus);border-inline-start:var(--calcite-border-width-sm) solid var(--calcite-sheet-border-color, var(--calcite-color-border-3))}:host([position=inline-start]):host([display-mode=float]) .resize-handle-bar{border-start-end-radius:var(--calcite-sheet-corner-radius, var(--calcite-corner-radius-round));border-end-end-radius:var(--calcite-sheet-corner-radius, var(--calcite-corner-radius-round))}:host([position=inline-end]) .resize-handle{inline-size:var(--calcite-size-fixed-xxl);inset-inline-start:var(--calcite-internal-sheet-resize-handle-offset);block-size:100%}:host([position=inline-end]) .resize-handle-bar{block-size:100%;inline-size:var(--calcite-size-fixed-sm-plus);border-inline-end:var(--calcite-border-width-sm) solid var(--calcite-sheet-border-color, var(--calcite-color-border-3))}:host([position=inline-end]):host([display-mode=float]) .resize-handle-bar{border-start-start-radius:.25rem;border-end-start-radius:.25rem}:host([position=block-start]) .resize-handle{block-size:var(--calcite-size-fixed-xxl);inline-size:100%;inset-block-end:var(--calcite-internal-sheet-resize-handle-offset)}:host([position=block-start]) .resize-handle-bar{inline-size:100%;block-size:var(--calcite-size-fixed-sm-plus);border-block-start:var(--calcite-border-width-sm) solid var(--calcite-sheet-border-color, var(--calcite-color-border-3))}:host([position=block-start]):host([display-mode=float]) .resize-handle-bar{border-end-end-radius:.25rem;border-end-start-radius:.25rem}:host([position=block-end]) .resize-handle{block-size:var(--calcite-size-fixed-xxl);inline-size:100%;inset-block-start:var(--calcite-internal-sheet-resize-handle-offset)}:host([position=block-end]) .resize-handle-bar{inline-size:100%;block-size:var(--calcite-size-fixed-sm-plus);border-block-end:var(--calcite-border-width-sm) solid var(--calcite-sheet-border-color, var(--calcite-color-border-3))}:host([position=block-end]):host([display-mode=float]) .resize-handle-bar{border-start-start-radius:var(--calcite-sheet-corner-radius, var(--calcite-corner-radius-round));border-start-end-radius:var(--calcite-sheet-corner-radius, var(--calcite-corner-radius-round))}:host([position]) .container--embedded{pointer-events:auto;position:absolute;inline-size:100%;max-inline-size:100%;min-inline-size:100%;block-size:100%;max-block-size:100%;min-block-size:100%}:host([position]) .container--embedded calcite-scrim{position:absolute}:host([hidden]){display:none}[hidden]{display:none}`,I=class extends C{constructor(){super(),this.contentRef=w(),this.direction=L(),this.focusTrap=_({triggerProp:"open",focusTrapOptions:{clickOutsideDeactivates:()=>this.embedded,escapeDeactivates:e=>(!e.defaultPrevented&&!this.escapeDisabled&&(this.open=!1,e.preventDefault()),!1)}})(this),this.usePreventDocumentScroll=j()(this),this.messages=A(),this.mutationObserver=E("mutation",()=>this.handleMutationObserver()),this._open=!1,this.openProp="opened",this.transitionProp="opacity",this.transitionRef=w(),this.focusSetter=P()(this),this.keyDownHandler=e=>{let{defaultPrevented:n,key:t}=e;!n&&!this.escapeDisabled&&this.focusTrapDisabled&&this.open&&t==="Escape"&&(e.preventDefault(),this.open=!1)},this.sizeOverride=K({targetElement:this.contentRef,getBounds:()=>({inline:{min:this.resizeValues.minInlineSize,max:this.resizeValues.maxInlineSize},block:{min:this.resizeValues.minBlockSize,max:this.resizeValues.maxBlockSize}}),onResize:e=>{this.resizeValues={...e}}}),this.topLayer=F({disabledOverride:()=>this.embedded,target:this.transitionRef})(this),this.resizeValues={inlineSize:null,blockSize:null,minInlineSize:null,minBlockSize:null,maxInlineSize:null,maxBlockSize:null},this.displayMode="overlay",this.embedded=!1,this.escapeDisabled=!1,this.focusTrapDisabled=!1,this.heightScale="m",this.opened=!1,this.outsideCloseDisabled=!1,this.position="inline-start",this.resizable=!1,this.topLayerDisabled=!1,this.widthScale="m",this.calciteSheetBeforeClose=m({cancelable:!1}),this.calciteSheetBeforeOpen=m({cancelable:!1}),this.calciteSheetClose=m({cancelable:!1}),this.calciteSheetOpen=m({cancelable:!1}),this.listen("keydown",this.keyDownHandler)}static{this.properties={resizeValues:[16,{},{state:!0}],beforeClose:[0,{},{attribute:!1}],displayMode:[3,{},{reflect:!0}],embedded:[7,{},{reflect:!0,type:Boolean}],escapeDisabled:[7,{},{reflect:!0,type:Boolean}],focusTrapDisabled:[7,{},{reflect:!0,type:Boolean}],focusTrapOptions:[0,{},{attribute:!1}],heightScale:[3,{},{reflect:!0}],height:[3,{},{reflect:!0}],label:1,messageOverrides:[0,{},{attribute:!1}],open:[7,{},{reflect:!0,type:Boolean}],opened:[7,{},{reflect:!0,type:Boolean}],outsideCloseDisabled:[7,{},{reflect:!0,type:Boolean}],position:[3,{},{reflect:!0}],resizable:[7,{},{reflect:!0,type:Boolean}],topLayerDisabled:[7,{},{reflect:!0,type:Boolean}],widthScale:[3,{},{reflect:!0}],width:[3,{},{reflect:!0}]}}static{this.styles=Z}get preventDocumentScroll(){return!this.embedded}get open(){return this._open}set open(e){let n=this._open;e!==n&&this.setOpenState(e)}async setFocus(e){return this.focusSetter(()=>this.el,e)}async updateFocusTrapElements(e){this.focusTrap.setExtraContainers(e),this.focusTrap.updateContainerElements()}async updateSize(e){this.updateSizeInternal(e)}connectedCallback(){super.connectedCallback(),this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.setupInteractions()}willUpdate(e){e.has("opened")&&(this.hasUpdated||this.opened!==!1)&&this.transitionRef.value&&U(this),(e.has("open")&&(this.hasUpdated||this.open!==!1)||e.has("position")&&(this.hasUpdated||this.position!=="inline-start")||e.has("resizable")&&(this.hasUpdated||this.resizable!==!1)||e.has("direction"))&&this.setupInteractions(),this.contentRef.value&&(this.contentId=M(this.contentRef.value))}disconnectedCallback(){super.disconnectedCallback(),this.mutationObserver?.disconnect(),this.embedded=!1,this.cleanupInteractions()}async setOpenState(e){if(this.beforeClose&&!e)try{await this.beforeClose?.(this.el)}catch{return}this._open=e,e&&await this.componentOnReady(),this.opened=e}getResizeIcon(){let{position:e}=this;return e==="block-start"||e==="block-end"?N.dragVertical:N.dragHorizontal}getContentRefDOMRect(){return this.contentRef.value?.getBoundingClientRect()}handleKeyDown(e){let{key:n,defaultPrevented:t,shiftKey:s}=e,{contentRef:r,position:i,resizable:c,resizeValues:{maxBlockSize:z,maxInlineSize:f,minBlockSize:v,minInlineSize:x}}=this,k=[...i==="block-end"||i==="block-start"?["ArrowUp","ArrowDown"]:["ArrowLeft","ArrowRight"],"Home","End"];if(!c||!r.value||t||!k.includes(n))return;let o=this.getContentRefDOMRect(),p=this.direction==="rtl"?-1:1,a=s?$:V;switch(n){case"ArrowUp":this.updateSizeInternal({block:o.height+(i==="block-end"?a:-a)}),e.preventDefault();break;case"ArrowDown":this.updateSizeInternal({block:o.height+(i==="block-end"?-a:a)}),e.preventDefault();break;case"ArrowLeft":this.updateSizeInternal({inline:o.width+(i==="inline-end"?a:-a)*p}),e.preventDefault();break;case"ArrowRight":this.updateSizeInternal({inline:o.width+(i==="inline-end"?-a:a)*p}),e.preventDefault();break;case"Home":this.updateSizeInternal(i==="block-start"||i==="block-end"?{block:v}:{inline:x}),e.preventDefault();break;case"End":this.updateSizeInternal(i==="block-start"||i==="block-end"?{block:z}:{inline:f}),e.preventDefault();break}}updateSizeInternal(e){this.contentRef.value&&this.sizeOverride.resize(e)}cleanupInteractions(){this.interaction?.unset()}async setupInteractions(){this.cleanupInteractions();let{contentRef:e,el:n,resizable:t,position:s,open:r,resizeHandleEl:i}=this;if(!e.value||!r||!t||!i)return;await this.el.componentOnReady();let c=window.getComputedStyle(e.value);this.resizeValues.minInlineSize=parseInt(c.minInlineSize)||0,this.resizeValues.maxInlineSize=parseInt(c.maxInlineSize)||window.innerWidth,this.resizeValues.minBlockSize=parseInt(c.minBlockSize)||0,this.resizeValues.maxBlockSize=parseInt(c.maxBlockSize)||window.innerHeight;let{inlineSize:z,minInlineSize:f,blockSize:v,minBlockSize:x,maxInlineSize:B,maxBlockSize:k}=c,o={inlineSize:h(z),blockSize:h(v),minInlineSize:h(f),minBlockSize:h(x),maxInlineSize:h(B)||window.innerWidth,maxBlockSize:h(k)||window.innerHeight};this.resizeValues=o;let p=this.direction==="rtl";this.interaction=y(e.value,{context:n.ownerDocument}).resizable({edges:{top:s==="block-end"?i:!1,right:s===(p?"inline-end":"inline-start")?i:!1,bottom:s==="block-start"?i:!1,left:s===(p?"inline-start":"inline-end")?i:!1},modifiers:[y.modifiers.restrictSize({min:{width:o.minInlineSize,height:o.minBlockSize},max:{width:o.maxInlineSize,height:o.maxBlockSize}})],listeners:{move:({rect:a})=>{let W=s==="block-start"||s==="block-end";this.updateSizeInternal(W?{block:a.height}:{inline:a.width})}}})}onBeforeOpen(){this.calciteSheetBeforeOpen.emit(),this.topLayer.show()}onOpen(){this.focusTrapDisabled&&this.setFocus(),this.focusTrap.activate(),this.calciteSheetOpen.emit()}onBeforeClose(){this.calciteSheetBeforeClose.emit()}onClose(){this.calciteSheetClose.emit(),this.focusTrap.deactivate(),this.topLayer.hide()}setResizeHandleEl(e){this.resizeHandleEl=e,this.setupInteractions()}handleOutsideClose(){this.outsideCloseDisabled||(this.open=!1)}handleMutationObserver(){this.focusTrap.updateContainerElements()}render(){let{resizable:e,position:n,resizeValues:t}=this,s=this.direction,r=n==="block-start"||n==="block-end";return O(this.el,"aria-describedby",this.contentId),this.el.ariaLabel=this.label,this.el.ariaModal="true",this.el.role="dialog",g`<div class=${d({[l.container]:!0,[l.containerOpen]:this.opened,[l.containerEmbedded]:this.embedded,[R.rtl]:s==="rtl",[S("width",this.width,this.widthScale)]:!!(this.width||this.widthScale),[S("height",this.height,this.heightScale)]:!!(this.height||this.heightScale)})} .popover=${this.embedded?null:"manual"} ${b(this.transitionRef)}><calcite-scrim class=${d(l.scrim)} @click=${this.handleOutsideClose}></calcite-scrim><div class=${d(l.content)} id=${Y.sheetContent} ${b(this.contentRef)}><div class=${d(l.contentContainer)}><slot></slot></div>${e?H("resize-handle",g`<div .ariaLabel=${this.messages.resizeEnabled} .ariaOrientation=${r?"vertical":"horizontal"} .ariaValueMax=${u(r?"block":"inline",t.maxBlockSize,t.maxInlineSize)} .ariaValueMin=${u(r?"block":"inline",t.minBlockSize,t.minInlineSize)} .ariaValueNow=${u(r?"block":"inline",t.blockSize,t.inlineSize)} class=${d(l.resizeHandle)} @keydown=${this.handleKeyDown} role=separator tabindex=0 touch-action=none ${b(this.setResizeHandleEl)}><div class=${d(l.resizeHandleBar)}><calcite-icon .icon=${this.getResizeIcon()} scale=s></calcite-icon></div></div>`):null}</div></div>`}};T("calcite-sheet",I);export{I as Sheet};
@@ -1,4 +0,0 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{b as fe}from"./P6VMV62Z.js";import{a as de,l as ve}from"./QVXAQXDL.js";import{Q as le}from"./ZRXGDZZT.js";var pe=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],$=pe.join(","),he=typeof Element>"u",G=he?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,J=!he&&Element.prototype.getRootNode?function(r){var e;return r==null||(e=r.getRootNode)===null||e===void 0?void 0:e.call(r)}:function(r){return r?.ownerDocument},Q=function(e,t){var n;t===void 0&&(t=!0);var u=e==null||(n=e.getAttribute)===null||n===void 0?void 0:n.call(e,"inert"),c=u===""||u==="true",a=c||t&&e&&(typeof e.closest=="function"?e.closest("[inert]"):Q(e.parentNode));return a},Ce=function(e){var t,n=e==null||(t=e.getAttribute)===null||t===void 0?void 0:t.call(e,"contenteditable");return n===""||n==="true"},ye=function(e,t,n){if(Q(e))return[];var u=Array.prototype.slice.apply(e.querySelectorAll($));return t&&G.call(e,$)&&u.unshift(e),u=u.filter(n),u},ee=function(e,t,n){for(var u=[],c=Array.from(e);c.length;){var a=c.shift();if(!Q(a,!1))if(a.tagName==="SLOT"){var s=a.assignedElements(),f=s.length?s:a.children,p=ee(f,!0,n);n.flatten?u.push.apply(u,p):u.push({scopeParent:a,candidates:p})}else{var F=G.call(a,$);F&&n.filter(a)&&(t||!e.includes(a))&&u.push(a);var w=a.shadowRoot||typeof n.getShadowRoot=="function"&&n.getShadowRoot(a),R=!Q(w,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(a));if(w&&R){var A=ee(w===!0?a.children:w.children,!0,n);n.flatten?u.push.apply(u,A):u.push({scopeParent:a,candidates:A})}else c.unshift.apply(c,a.children)}}return u},me=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},L=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||Ce(e))&&!me(e)?0:e.tabIndex},je=function(e,t){var n=L(e);return n<0&&t&&!me(e)?0:n},xe=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},ge=function(e){return e.tagName==="INPUT"},Le=function(e){return ge(e)&&e.type==="hidden"},Be=function(e){var t=e.tagName==="DETAILS"&&Array.prototype.slice.apply(e.children).some(function(n){return n.tagName==="SUMMARY"});return t},_e=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},Ge=function(e){if(!e.name)return!0;var t=e.form||J(e),n=function(s){return t.querySelectorAll('input[type="radio"][name="'+s+'"]')},u;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")u=n(window.CSS.escape(e.name));else try{u=n(e.name)}catch(a){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",a.message),!1}var c=_e(u,e.form);return!c||c===e},Ke=function(e){return ge(e)&&e.type==="radio"},Me=function(e){return Ke(e)&&!Ge(e)},Ve=function(e){var t,n=e&&J(e),u=(t=n)===null||t===void 0?void 0:t.host,c=!1;if(n&&n!==e){var a,s,f;for(c=!!((a=u)!==null&&a!==void 0&&(s=a.ownerDocument)!==null&&s!==void 0&&s.contains(u)||e!=null&&(f=e.ownerDocument)!==null&&f!==void 0&&f.contains(e));!c&&u;){var p,F,w;n=J(u),u=(p=n)===null||p===void 0?void 0:p.host,c=!!((F=u)!==null&&F!==void 0&&(w=F.ownerDocument)!==null&&w!==void 0&&w.contains(u))}}return c},be=function(e){var t=e.getBoundingClientRect(),n=t.width,u=t.height;return n===0&&u===0},qe=function(e,t){var n=t.displayCheck,u=t.getShadowRoot;if(n==="full-native"&&"checkVisibility"in e){var c=e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!c}if(getComputedStyle(e).visibility==="hidden")return!0;var a=G.call(e,"details>summary:first-of-type"),s=a?e.parentElement:e;if(G.call(s,"details:not([open]) *"))return!0;if(!n||n==="full"||n==="full-native"||n==="legacy-full"){if(typeof u=="function"){for(var f=e;e;){var p=e.parentElement,F=J(e);if(p&&!p.shadowRoot&&u(p)===!0)return be(e);e.assignedSlot?e=e.assignedSlot:!p&&F!==e.ownerDocument?e=F.host:e=p}e=f}if(Ve(e))return!e.getClientRects().length;if(n!=="legacy-full")return!0}else if(n==="non-zero-area")return be(e);return!1},Ue=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName==="FIELDSET"&&t.disabled){for(var n=0;n<t.children.length;n++){var u=t.children.item(n);if(u.tagName==="LEGEND")return G.call(t,"fieldset[disabled] *")?!0:!u.contains(e)}return!0}t=t.parentElement}return!1},te=function(e,t){return!(t.disabled||Le(t)||qe(t,e)||Be(t)||Ue(t))},ce=function(e,t){return!(Me(t)||L(t)<0||!te(e,t))},We=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},we=function(e){var t=[],n=[];return e.forEach(function(u,c){var a=!!u.scopeParent,s=a?u.scopeParent:u,f=je(s,a),p=a?we(u.candidates):s;f===0?a?t.push.apply(t,p):t.push(s):n.push({documentOrder:c,tabIndex:f,item:u,isScope:a,content:p})}),n.sort(xe).reduce(function(u,c){return c.isScope?u.push.apply(u,c.content):u.push(c.content),u},[]).concat(t)},Te=function(e,t){t=t||{};var n;return t.getShadowRoot?n=ee([e],t.includeContainer,{filter:ce.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:We}):n=ye(e,t.includeContainer,ce.bind(null,t)),we(n)},Se=function(e,t){t=t||{};var n;return t.getShadowRoot?n=ee([e],t.includeContainer,{filter:te.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):n=ye(e,t.includeContainer,te.bind(null,t)),n},K=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return G.call(e,$)===!1?!1:ce(t,e)},Ye=pe.concat("iframe:not([inert]):not([inert] *)").join(","),re=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return G.call(e,Ye)===!1?!1:te(t,e)};function se(r,e){(e==null||e>r.length)&&(e=r.length);for(var t=0,n=Array(e);t<e;t++)n[t]=r[t];return n}function He(r){if(Array.isArray(r))return se(r)}function Fe(r,e,t,n,u,c,a){try{var s=r[c](a),f=s.value}catch(p){return void t(p)}s.done?e(f):Promise.resolve(f).then(n,u)}function Ne(r){return function(){var e=this,t=arguments;return new Promise(function(n,u){var c=r.apply(e,t);function a(f){Fe(c,n,u,a,s,"next",f)}function s(f){Fe(c,n,u,a,s,"throw",f)}a(void 0)})}}function Ee(r,e){var t=typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=Oe(r))||e){t&&(r=t);var n=0,u=function(){};return{s:u,n:function(){return n>=r.length?{done:!0}:{done:!1,value:r[n++]}},e:function(f){throw f},f:u}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
3
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var c,a=!0,s=!1;return{s:function(){t=t.call(r)},n:function(){var f=t.next();return a=f.done,f},e:function(f){s=!0,c=f},f:function(){try{a||t.return==null||t.return()}finally{if(s)throw c}}}}function Ze(r,e,t){return(e=Qe(e))in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function ze(r){if(typeof Symbol<"u"&&r[Symbol.iterator]!=null||r["@@iterator"]!=null)return Array.from(r)}function Xe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
4
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ke(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(u){return Object.getOwnPropertyDescriptor(r,u).enumerable})),t.push.apply(t,n)}return t}function Ae(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?ke(Object(t),!0).forEach(function(n){Ze(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):ke(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function U(){var r,e,t=typeof Symbol=="function"?Symbol:{},n=t.iterator||"@@iterator",u=t.toStringTag||"@@toStringTag";function c(A,I,Y,H){var M=I&&I.prototype instanceof s?I:s,V=Object.create(M.prototype);return O(V,"_invoke",(function(ie,Z,z){var P,T,E,B=0,X=z||[],C=!1,N={p:0,n:0,v:r,a:g,f:g.bind(r,4),d:function(i,o){return P=i,T=0,E=r,N.n=o,a}};function g(i,o){for(T=i,E=o,e=0;!C&&B&&!l&&e<X.length;e++){var l,d=X[e],b=N.p,h=d[2];i>3?(l=h===o)&&(E=d[(T=d[4])?5:(T=3,3)],d[4]=d[5]=r):d[0]<=b&&((l=i<2&&b<d[1])?(T=0,N.v=o,N.n=d[1]):b<h&&(l=i<3||d[0]>o||o>h)&&(d[4]=i,d[5]=o,N.n=h,T=0))}if(l||i>1)return a;throw C=!0,o}return function(i,o,l){if(B>1)throw TypeError("Generator is already running");for(C&&o===1&&g(o,l),T=o,E=l;(e=T<2?r:E)||!C;){P||(T?T<3?(T>1&&(N.n=-1),g(T,E)):N.n=E:N.v=E);try{if(B=2,P){if(T||(i="next"),e=P[i]){if(!(e=e.call(P,E)))throw TypeError("iterator result is not an object");if(!e.done)return e;E=e.value,T<2&&(T=0)}else T===1&&(e=P.return)&&e.call(P),T<2&&(E=TypeError("The iterator does not provide a '"+i+"' method"),T=1);P=r}else if((e=(C=N.n<0)?E:ie.call(Z,N))!==a)break}catch(d){P=r,T=1,E=d}finally{B=1}}return{value:e,done:C}}})(A,Y,H),!0),V}var a={};function s(){}function f(){}function p(){}e=Object.getPrototypeOf;var F=[][n]?e(e([][n]())):(O(e={},n,function(){return this}),e),w=p.prototype=s.prototype=Object.create(F);function R(A){return Object.setPrototypeOf?Object.setPrototypeOf(A,p):(A.__proto__=p,O(A,u,"GeneratorFunction")),A.prototype=Object.create(w),A}return f.prototype=p,O(w,"constructor",p),O(p,"constructor",f),f.displayName="GeneratorFunction",O(p,u,"GeneratorFunction"),O(w),O(w,u,"Generator"),O(w,n,function(){return this}),O(w,"toString",function(){return"[object Generator]"}),(U=function(){return{w:c,m:R}})()}function O(r,e,t,n){var u=Object.defineProperty;try{u({},"",{})}catch{u=0}O=function(c,a,s,f){function p(F,w){O(c,F,function(R){return this._invoke(F,w,R)})}a?u?u(c,a,{value:s,enumerable:!f,configurable:!f,writable:!f}):c[a]=s:(p("next",0),p("throw",1),p("return",2))},O(r,e,t,n)}function $e(r){return He(r)||ze(r)||Oe(r)||Xe()}function Je(r,e){if(typeof r!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function Qe(r){var e=Je(r,"string");return typeof e=="symbol"?e:e+""}function Oe(r,e){if(r){if(typeof r=="string")return se(r,e);var t={}.toString.call(r).slice(8,-1);return t==="Object"&&r.constructor&&(t=r.constructor.name),t==="Map"||t==="Set"?Array.from(r):t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?se(r,e):void 0}}var j={getActiveTrap:function(e){return e?.length>0?e[e.length-1]:null},activateTrap:function(e,t){var n=j.getActiveTrap(e);t!==n&&j.pauseTrap(e);var u=e.indexOf(t);u===-1||e.splice(u,1),e.push(t)},deactivateTrap:function(e,t){var n=e.indexOf(t);n!==-1&&e.splice(n,1),j.unpauseTrap(e)},pauseTrap:function(e){var t=j.getActiveTrap(e);t?._setPausedState(!0)},unpauseTrap:function(e){var t=j.getActiveTrap(e);t&&!t._isManuallyPaused()&&t._setPausedState(!1)}},et=function(e){return e.tagName&&e.tagName.toLowerCase()==="input"&&typeof e.select=="function"},tt=function(e){return e?.key==="Escape"||e?.key==="Esc"||e?.keyCode===27},W=function(e){return e?.key==="Tab"||e?.keyCode===9},rt=function(e){return W(e)&&!e.shiftKey},at=function(e){return W(e)&&e.shiftKey},De=function(e){return setTimeout(e,0)},q=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),u=1;u<t;u++)n[u-1]=arguments[u];return typeof e=="function"?e.apply(void 0,n):e},ae=function(e){return e.target.shadowRoot&&typeof e.composedPath=="function"?e.composedPath()[0]:e.target},nt=[],Re=function(e,t){var n=t?.document||document,u=t?.trapStack||nt,c=Ae({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,delayReturnFocus:!0,isolateSubtrees:!1,isKeyForward:rt,isKeyBackward:at},t),a={containers:[],containerGroups:[],tabbableGroups:[],adjacentElements:new Set,alreadySilent:new Set,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,manuallyPaused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0},s,f=function(i,o,l){return i&&i[o]!==void 0?i[o]:c[l||o]},p=function(i,o){var l=typeof o?.composedPath=="function"?o.composedPath():void 0;return a.containerGroups.findIndex(function(d){var b=d.container,h=d.tabbableNodes;return b.contains(i)||l?.includes(b)||h.find(function(v){return v===i})})},F=function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l=o.hasFallback,d=l===void 0?!1:l,b=o.params,h=b===void 0?[]:b,v=c[i];if(typeof v=="function"&&(v=v.apply(void 0,$e(h))),v===!0&&(v=void 0),!v){if(v===void 0||v===!1)return v;throw new Error("`".concat(i,"` was specified but was not a node, or did not return a node"))}var m=v;if(typeof v=="string"){try{m=n.querySelector(v)}catch(y){throw new Error("`".concat(i,'` appears to be an invalid selector; error="').concat(y.message,'"'))}if(!m&&!d)throw new Error("`".concat(i,"` as selector refers to no known node"))}return m},w=function(){var i=F("initialFocus",{hasFallback:!0});if(i===!1)return!1;if(i===void 0||i&&!re(i,c.tabbableOptions))if(p(n.activeElement)>=0)i=n.activeElement;else{var o=a.tabbableGroups[0],l=o&&o.firstTabbableNode;i=l||F("fallbackFocus")}else i===null&&(i=F("fallbackFocus"));if(!i)throw new Error("Your focus-trap needs to have at least one focusable element");return i},R=function(){if(a.containerGroups=a.containers.map(function(i){var o=Te(i,c.tabbableOptions),l=Se(i,c.tabbableOptions),d=o.length>0?o[0]:void 0,b=o.length>0?o[o.length-1]:void 0,h=l.find(function(y){return K(y)}),v=l.slice().reverse().find(function(y){return K(y)}),m=!!o.find(function(y){return L(y)>0});return{container:i,tabbableNodes:o,focusableNodes:l,posTabIndexesFound:m,firstTabbableNode:d,lastTabbableNode:b,firstDomTabbableNode:h,lastDomTabbableNode:v,nextTabbableNode:function(S){var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,k=o.indexOf(S);return k<0?D?l.slice(l.indexOf(S)+1).find(function(_){return K(_)}):l.slice(0,l.indexOf(S)).reverse().find(function(_){return K(_)}):o[k+(D?1:-1)]}}}),a.tabbableGroups=a.containerGroups.filter(function(i){return i.tabbableNodes.length>0}),a.tabbableGroups.length<=0&&!F("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(a.containerGroups.find(function(i){return i.posTabIndexesFound})&&a.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},A=function(i){var o=i.activeElement;if(o)return o.shadowRoot&&o.shadowRoot.activeElement!==null?A(o.shadowRoot):o},I=function(i){if(i!==!1&&i!==A(document)){if(!i||!i.focus){I(w());return}i.focus({preventScroll:!!c.preventScroll}),a.mostRecentlyFocusedNode=i,et(i)&&i.select()}},Y=function(i){var o=F("setReturnFocus",{params:[i]});return o||(o===!1?!1:i)},H=function(i){var o=i.target,l=i.event,d=i.isBackward,b=d===void 0?!1:d;o=o||ae(l),R();var h=null;if(a.tabbableGroups.length>0){var v=p(o,l),m=v>=0?a.containerGroups[v]:void 0;if(v<0)b?h=a.tabbableGroups[a.tabbableGroups.length-1].lastTabbableNode:h=a.tabbableGroups[0].firstTabbableNode;else if(b){var y=a.tabbableGroups.findIndex(function(oe){var ue=oe.firstTabbableNode;return o===ue});if(y<0&&(m.container===o||re(o,c.tabbableOptions)&&!K(o,c.tabbableOptions)&&!m.nextTabbableNode(o,!1))&&(y=v),y>=0){var S=y===0?a.tabbableGroups.length-1:y-1,D=a.tabbableGroups[S];h=L(o)>=0?D.lastTabbableNode:D.lastDomTabbableNode}else W(l)||(h=m.nextTabbableNode(o,!1))}else{var k=a.tabbableGroups.findIndex(function(oe){var ue=oe.lastTabbableNode;return o===ue});if(k<0&&(m.container===o||re(o,c.tabbableOptions)&&!K(o,c.tabbableOptions)&&!m.nextTabbableNode(o))&&(k=v),k>=0){var _=k===a.tabbableGroups.length-1?0:k+1,x=a.tabbableGroups[_];h=L(o)>=0?x.firstTabbableNode:x.firstDomTabbableNode}else W(l)||(h=m.nextTabbableNode(o))}}else h=F("fallbackFocus");return h},M=function(i){var o=ae(i);if(!(p(o,i)>=0)){if(q(c.clickOutsideDeactivates,i)){s.deactivate({returnFocus:c.returnFocusOnDeactivate});return}q(c.allowOutsideClick,i)||i.preventDefault()}},V=function(i){var o=ae(i),l=p(o,i)>=0;if(l||o instanceof Document)l&&(a.mostRecentlyFocusedNode=o);else{i.stopImmediatePropagation();var d,b=!0;if(a.mostRecentlyFocusedNode)if(L(a.mostRecentlyFocusedNode)>0){var h=p(a.mostRecentlyFocusedNode),v=a.containerGroups[h].tabbableNodes;if(v.length>0){var m=v.findIndex(function(y){return y===a.mostRecentlyFocusedNode});m>=0&&(c.isKeyForward(a.recentNavEvent)?m+1<v.length&&(d=v[m+1],b=!1):m-1>=0&&(d=v[m-1],b=!1))}}else a.containerGroups.some(function(y){return y.tabbableNodes.some(function(S){return L(S)>0})})||(b=!1);else b=!1;b&&(d=H({target:a.mostRecentlyFocusedNode,isBackward:c.isKeyBackward(a.recentNavEvent)})),I(d||a.mostRecentlyFocusedNode||w())}a.recentNavEvent=void 0},ie=function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;a.recentNavEvent=i;var l=H({event:i,isBackward:o});l&&(W(i)&&i.preventDefault(),I(l))},Z=function(i){(c.isKeyForward(i)||c.isKeyBackward(i))&&ie(i,c.isKeyBackward(i))},z=function(i){tt(i)&&q(c.escapeDeactivates,i)!==!1&&(i.preventDefault(),s.deactivate())},P=function(i){var o=ae(i);p(o,i)>=0||q(c.clickOutsideDeactivates,i)||q(c.allowOutsideClick,i)||(i.preventDefault(),i.stopImmediatePropagation())},T=function(){if(!a.active)return Promise.resolve();j.activateTrap(u,s);var i;return c.delayInitialFocus?i=new Promise(function(o){a.delayInitialFocusTimer=De(function(){I(w()),o()})}):(i=Promise.resolve(),I(w())),n.addEventListener("focusin",V,!0),n.addEventListener("mousedown",M,{capture:!0,passive:!1}),n.addEventListener("touchstart",M,{capture:!0,passive:!1}),n.addEventListener("click",P,{capture:!0,passive:!1}),n.addEventListener("keydown",Z,{capture:!0,passive:!1}),n.addEventListener("keydown",z),i},E=function(i){a.active&&!a.paused&&s._setSubtreeIsolation(!1),a.adjacentElements.clear(),a.alreadySilent.clear();var o=new Set,l=new Set,d=Ee(i),b;try{for(d.s();!(b=d.n()).done;){var h=b.value;o.add(h);for(var v=typeof ShadowRoot<"u"&&h.getRootNode()instanceof ShadowRoot,m=h;m;){o.add(m);var y=m.parentElement,S=[];y?S=y.children:!y&&v&&(S=m.getRootNode().children,y=m.getRootNode().host,v=typeof ShadowRoot<"u"&&y.getRootNode()instanceof ShadowRoot);var D=Ee(S),k;try{for(D.s();!(k=D.n()).done;){var _=k.value;l.add(_)}}catch(x){D.e(x)}finally{D.f()}m=y}}}catch(x){d.e(x)}finally{d.f()}o.forEach(function(x){l.delete(x)}),a.adjacentElements=l},B=function(){if(a.active)return n.removeEventListener("focusin",V,!0),n.removeEventListener("mousedown",M,!0),n.removeEventListener("touchstart",M,!0),n.removeEventListener("click",P,!0),n.removeEventListener("keydown",Z,!0),n.removeEventListener("keydown",z),s},X=function(i){var o=a.mostRecentlyFocusedNode;if(o){var l=i.some(function(b){var h=Array.from(b.removedNodes);return h.some(function(v){return v===o||typeof v.contains=="function"&&v.contains(o)})});if(l&&a.containers.some(function(b){return b?.isConnected})){R();var d=w();I(d)}}},C=typeof window<"u"&&"MutationObserver"in window?new MutationObserver(X):void 0,N=function(){C&&(C.disconnect(),a.active&&!a.paused&&a.containers.map(function(i){C.observe(i,{subtree:!0,childList:!0})}))};return s={get active(){return a.active},get paused(){return a.paused},activate:function(i){if(a.active)return this;var o=f(i,"onActivate"),l=f(i,"onPostActivate"),d=f(i,"checkCanFocusTrap"),b=j.getActiveTrap(u),h=!1;if(b&&!b.paused){var v;(v=b._setSubtreeIsolation)===null||v===void 0||v.call(b,!1),h=!0}try{d||R(),a.active=!0,a.paused=!1,a.nodeFocusedBeforeActivation=A(n),o?.({trap:s});var m=(function(){var S=Ne(U().m(function D(){return U().w(function(k){for(;;)switch(k.n){case 0:return d&&R(),k.n=1,T();case 1:s._setSubtreeIsolation(!0),N(),l?.({trap:s});case 2:return k.a(2)}},D)}));return function(){return S.apply(this,arguments)}})();if(d)return d(a.containers.concat()).then(m,m),this;m()}catch(S){if(b===j.getActiveTrap(u)&&h){var y;(y=b._setSubtreeIsolation)===null||y===void 0||y.call(b,!0)}throw S}return this},deactivate:function(i){if(!a.active)return this;var o=Ae({onDeactivate:c.onDeactivate,onPostDeactivate:c.onPostDeactivate,checkCanReturnFocus:c.checkCanReturnFocus},i);clearTimeout(a.delayInitialFocusTimer),a.delayInitialFocusTimer=void 0,a.paused||s._setSubtreeIsolation(!1),a.alreadySilent.clear(),B(),a.active=!1,a.paused=!1,N(),j.deactivateTrap(u,s);var l=f(o,"onDeactivate"),d=f(o,"onPostDeactivate"),b=f(o,"checkCanReturnFocus"),h=f(o,"delayReturnFocus"),v=f(o,"returnFocus","returnFocusOnDeactivate");l?.({trap:s});var m=function(){v&&I(Y(a.nodeFocusedBeforeActivation)),d?.({trap:s})},y=function(){h&&v?De(m):m()};return v&&b?(b(Y(a.nodeFocusedBeforeActivation)).then(y,y),this):(y(),this)},pause:function(i){return a.active?(a.manuallyPaused=!0,this._setPausedState(!0,i)):this},unpause:function(i){return a.active?(a.manuallyPaused=!1,u[u.length-1]!==this?this:this._setPausedState(!1,i)):this},updateContainerElements:function(i){var o=[].concat(i).filter(Boolean);return a.containers=o.map(function(l){return typeof l=="string"?n.querySelector(l):l}),c.isolateSubtrees&&E(a.containers),a.active&&(R(),a.paused||s._setSubtreeIsolation(!0)),N(),this}},Object.defineProperties(s,{_isManuallyPaused:{value:function(){return a.manuallyPaused}},_setPausedState:{value:function(i,o){if(a.paused===i)return this;if(a.paused=i,i){var l=f(o,"onPause"),d=f(o,"onPostPause");l?.({trap:s}),B(),s._setSubtreeIsolation(!1),N(),d?.({trap:s})}else{var b=f(o,"onUnpause"),h=f(o,"onPostUnpause");b?.({trap:s});var v=(function(){var m=Ne(U().m(function y(){return U().w(function(S){for(;;)switch(S.n){case 0:return R(),S.n=1,T();case 1:s._setSubtreeIsolation(!0),N(),h?.({trap:s});case 2:return S.a(2)}},y)}));return function(){return m.apply(this,arguments)}})();v()}return this}},_setSubtreeIsolation:{value:function(i){c.isolateSubtrees&&a.adjacentElements.forEach(function(o){var l;i?c.isolateSubtrees==="aria-hidden"?((o.ariaHidden==="true"||((l=o.getAttribute("aria-hidden"))===null||l===void 0?void 0:l.toLowerCase())==="true")&&a.alreadySilent.add(o),o.setAttribute("aria-hidden","true")):((o.inert||o.hasAttribute("inert"))&&a.alreadySilent.add(o),o.setAttribute("inert",!0)):a.alreadySilent.has(o)||(c.isolateSubtrees==="aria-hidden"?o.removeAttribute("aria-hidden"):o.removeAttribute("inert"))})}}}),s.updateContainerElements(e),s};function Ie(r,{focusTrapOptions:e},t){return!e?.extraContainers&&!t?r:[r,...Pe(e?.extraContainers),...Pe(t)]}function Pe(r=[]){return Array.isArray(r)?r:[r]}var ne=new WeakSet;function it(r,e){let t=e&&e!==document.body&&e!==document.documentElement;return!ne.has(r)&&t&&ve(e),!1}function ot(r,e){let t=e?.fallbackFocus||r,n=e?.clickOutsideDeactivates??!0,u;return{fallbackFocus:t,...e,document:r.ownerDocument,tabbableOptions:de,trapStack:le().focusTrapStack,clickOutsideDeactivates:c=>(ne.has(r)||ne.add(r),typeof n=="function"?n(c):n),onActivate:c=>{e?.escapeDeactivates&&(u=new AbortController,r.addEventListener("keydown",a=>{if(a.key==="Escape"){let s=e?.escapeDeactivates;(typeof s=="function"?s(a):s??!0)&&c.trap.deactivate()}},{signal:u.signal})),e?.onActivate?.(c)},onDeactivate:c=>{u?.abort(),u=void 0,e?.onDeactivate?.(c)},onPostDeactivate:()=>{ne.delete(r)},setReturnFocus:c=>{let a=typeof e?.setReturnFocus=="function"?e.setReturnFocus(c):e?.setReturnFocus;return a===void 0?it(r,c):a}}}var bt=r=>fe((e,t)=>{let n,u,c,a=r.focusTrapOptions;t.onConnected(()=>{e[r.triggerProp]&&n&&s.activate()}),t.onUpdate(f=>{e.hasUpdated&&f.has("focusTrapDisabled")&&(e.focusTrapDisabled?s.deactivate():s.activate())}),t.onDisconnected(()=>s.deactivate());let s={get _instance(){},activate:()=>{let f=u||e.el;f.isConnected&&(n||(c||=Ie(f,e),n=Re(c,ot(f,{...a,...e.focusTrapOptions}))),(typeof e.focusTrapDisabledOverride=="function"?!e.focusTrapDisabledOverride():!e.focusTrapDisabled)&&n.activate())},deactivate:()=>n?.deactivate(),overrideFocusTrapEl:f=>{if(n)throw new Error("Focus trap already created");u=f},setExtraContainers:f=>{let p=u||e.el;c=Ie(p,e,f)},updateContainerElements:()=>n?.updateContainerElements(c)};return s});export{bt as a};
@@ -1,2 +0,0 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{b as C}from"./WKR7R7AZ.js";import{c as h,l as M,u as S}from"./QVXAQXDL.js";import"./OAOQ5BXS.js";import{G as A,K as T,S as b,g as x,h as y,p as E}from"./ZRXGDZZT.js";function w(u){return u?.tagName==="CALCITE-TREE-ITEM"}function D(u){return Array.from(u.querySelectorAll("calcite-tree-item:not([disabled])")).filter(t=>{let e=t;for(;e!==u&&e!==void 0;){let i=e.parentElement;if(!(!w(i)||!i.hasChildren||i.expanded))return!1;e=e.parentElement}return!0})}var k=x`:host{display:block}:host(:focus){outline:2px solid transparent;outline-offset:2px}:host([hidden]){display:none}[hidden]{display:none}`,g=class extends A{constructor(){super(),this.items=[],this.lines=!1,this.parentExpanded=!1,this.scale="m",this.selectedItems=[],this.selectionMode="single",this.calciteTreeSelect=E({cancelable:!1}),this.listen("focus",this.onFocus),this.listen("focusin",this.onFocusIn),this.listen("focusout",this.onFocusOut),this.listen("calciteInternalTreeItemSelect",this.onInternalTreeItemSelect),this.listen("keydown",this.keyDownHandler)}static{this.properties={child:[7,{},{reflect:!0,type:Boolean}],lines:[7,{},{reflect:!0,type:Boolean}],parentExpanded:[5,{},{type:Boolean}],scale:[3,{},{reflect:!0}],selectedItems:[0,{},{attribute:!1}],selectionMode:[3,{},{reflect:!0}]}}static{this.styles=k}willUpdate(t){t.has("parentExpanded")&&(this.hasUpdated||this.parentExpanded!==!1)&&this.updateItems();let e=this.el.parentElement?.closest("calcite-tree");this.lines=e?e.lines:this.lines,this.scale=e?e.scale:this.scale,this.selectionMode=e?e.selectionMode:this.selectionMode,this.child=!!e}onFocus(){if(!this.child){let t=this.el.querySelector("calcite-tree-item[selected]:not([disabled])")||this.el.querySelector("calcite-tree-item:not([disabled])");M(t)}}onFocusIn(t){(t.relatedTarget===this.el||!this.el.contains(t.relatedTarget))&&this.el.removeAttribute("tabindex")}onFocusOut(t){!this.el.contains(t.relatedTarget)&&(this.el.tabIndex=this.getRootTabIndex())}onInternalTreeItemSelect(t){if(this.child)return;let e=t.target,i=h(e.querySelectorAll("calcite-tree-item"));if(t.preventDefault(),t.stopPropagation(),this.selectionMode==="ancestors"){this.updateAncestorTree(t);return}let o=this.selectionMode==="none",n=this.selectionMode!==null&&(!e.hasChildren||e.hasChildren&&(this.selectionMode==="children"||this.selectionMode==="multichildren")),l=this.selectionMode==="multichildren"&&e.hasChildren,c=!o&&t.detail.modifyCurrentSelection&&(this.selectionMode==="multiple"||this.selectionMode==="multichildren"),f=!c&&((this.selectionMode==="single"||this.selectionMode==="multiple")&&i.length<=0||this.selectionMode==="children"||this.selectionMode==="multichildren"||this.selectionMode==="single-persist"&&!e.hasChildren),d=["multiple","none","single","single-persist"].includes(this.selectionMode)&&e.hasChildren,a=[];n&&a.push(e),f&&h(this.el.querySelectorAll("calcite-tree-item[selected]")).forEach(r=>{a.includes(r)||(r.selected=!1)}),d&&["multiple","none","single","single-persist"].includes(this.selectionMode)&&(e.expanded=!e.expanded),l&&i.forEach(s=>{s.selected=!1,s.hasChildren&&(s.expanded=!1)}),c&&window.getSelection().removeAllRanges(),c&&e.selected?a.forEach(s=>{s.disabled||(s.selected=!1)}):o||a.forEach(s=>{s.disabled||(s.selected=this.selectionMode!=="single"||!s.selected)}),this.selectedItems=o?[]:h(this.el.querySelectorAll("calcite-tree-item")).filter(s=>s.selected),this.calciteTreeSelect.emit(),t.stopPropagation()}keyDownHandler(t){if(this.child)return;let e=this.el,i=t.target,o=["ArrowRight","ArrowDown","ArrowLeft","ArrowUp","Home","End","Tab"];if(!(w(i)&&this.el.contains(i))||!o.includes(t.key))return;let n=D(e);if(t.key==="Tab"){n.forEach(l=>l.tabIndex=-1);return}if(t.key==="ArrowDown"){let l=n.indexOf(i);n[l+1]?.focus(),t.preventDefault();return}if(t.key==="ArrowUp"){let l=n.indexOf(i);n[l-1]?.focus(),t.preventDefault();return}if(t.key==="ArrowLeft"){if(i.hasChildren&&i.expanded){i.expanded=!1,t.preventDefault();return}n.slice(0,n.indexOf(i)).reverse().find(f=>f.depth===i.depth-1)?.focus(),t.preventDefault();return}if(t.key==="ArrowRight"){if(!i.disabled&&i.hasChildren)if(!i.expanded)i.expanded=!0,t.preventDefault();else{let l=n.indexOf(i);n[l+1]?.focus(),t.preventDefault()}return}if(t.key==="Home"){let l=n.shift();l&&(l.focus(),t.preventDefault());return}if(t.key==="End"){let l=n.pop();l&&(l.focus(),t.preventDefault());return}}updateAncestorTree(t){let e=t.target,i=t.detail.updateItem;if(e.disabled||e.indeterminate&&!i)return;let o=[],n=e.parentElement.closest("calcite-tree-item");for(;n;)o.push(n),n=n.parentElement.closest("calcite-tree-item");let l=Array.from(e.querySelectorAll("calcite-tree-item:not([disabled])")),c=l.filter(s=>!s.hasChildren),f=l.filter(s=>s.hasChildren),d;i?d=e.hasChildren?!(e.selected||e.indeterminate):!e.selected:d=e.selected,c.forEach(s=>{s.selected=d,s.indeterminate=!1});function a(s,r){let m=s.filter(p=>p.selected),I=s.filter(p=>!p.selected);r.selected=m.length===s.length,r.indeterminate=m.length>0&&I.length>0}f.reverse().forEach(s=>{let r=Array.from(s.querySelectorAll(":scope > calcite-tree > calcite-tree-item"));a(r,s)}),i&&(e.hasChildren?a(l,e):(e.selected=d,e.indeterminate=!1)),o.forEach(s=>{let r=h(s.querySelectorAll("calcite-tree-item")),m=r.filter(p=>p.selected);if(m.length===0){s.selected=!1,s.indeterminate=!1;return}let I=m.length<r.length;s.indeterminate=I,s.selected=!I}),this.selectedItems=h(this.el.querySelectorAll("calcite-tree-item")).filter(s=>s.selected),i&&this.calciteTreeSelect.emit()}updateItems(){this.items.forEach(t=>t.parentExpanded=this.parentExpanded)}handleDefaultSlotChange(t){let e=S(t).filter(i=>i.matches("calcite-tree-item"));this.items=e,this.updateItems()}getRootTabIndex(){return this.child?-1:0}render(){return this.el.ariaMultiSelectable=this.child?void 0:C(this.selectionMode==="multiple"||this.selectionMode==="multichildren"),this.el.role=this.child?void 0:"tree",T(this.el,"tabIndex",this.getRootTabIndex()),y`<slot @slotchange=${this.handleDefaultSlotChange}></slot>`}};b("calcite-tree",g);export{g as Tree};