@quartzds/core 1.0.0-beta.121 → 1.0.0-beta.122

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 (230) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/components/index.js +1 -1
  3. package/components/{p-CURs27Ur.js → p-BalM52S_.js} +3 -3
  4. package/components/{p-CURs27Ur.js.map → p-BalM52S_.js.map} +1 -1
  5. package/components/{p-CkyaV9az.js → p-C0VgKX4J.js} +9 -9
  6. package/components/p-C0VgKX4J.js.map +1 -0
  7. package/components/{p-DtxwXYGb.js → p-C9R8N06B.js} +5 -31
  8. package/components/p-C9R8N06B.js.map +1 -0
  9. package/components/{p-DR79BVX5.js → p-CKp062X8.js} +6 -6
  10. package/components/p-CKp062X8.js.map +1 -0
  11. package/components/{p-CjVnGhSO.js → p-CVuTVnQo.js} +3 -3
  12. package/components/{p-CjVnGhSO.js.map → p-CVuTVnQo.js.map} +1 -1
  13. package/components/{p-CkUTS1aU.js → p-Ck9w5WIb.js} +6 -6
  14. package/components/p-Ck9w5WIb.js.map +1 -0
  15. package/components/p-DCAlWquR.js +200 -0
  16. package/components/p-DCAlWquR.js.map +1 -0
  17. package/components/{p-DNHI4C-W.js → p-DRcxeXWE.js} +58 -22
  18. package/components/p-DRcxeXWE.js.map +1 -0
  19. package/components/{p-B2ZVUvk9.js → p-DgYrfIr_.js} +5 -5
  20. package/components/{p-B2ZVUvk9.js.map → p-DgYrfIr_.js.map} +1 -1
  21. package/components/{p-CDRwHAIT.js → p-XP2CY_fo.js} +3 -3
  22. package/components/p-XP2CY_fo.js.map +1 -0
  23. package/components/{p-C1c4JVlg.js → p-io1iVgY1.js} +47 -28
  24. package/components/p-io1iVgY1.js.map +1 -0
  25. package/components/{p-D82sb4oJ.js → p-oqmnh-8P.js} +4 -4
  26. package/components/{p-D82sb4oJ.js.map → p-oqmnh-8P.js.map} +1 -1
  27. package/components/{p-5dwtV5iH.js → p-yb0Kv4Y6.js} +24 -6
  28. package/components/p-yb0Kv4Y6.js.map +1 -0
  29. package/components/qds-action-item.js +4 -4
  30. package/components/qds-action-item.js.map +1 -1
  31. package/components/qds-avatar-media.js +1 -1
  32. package/components/qds-badge-counter.js +1 -1
  33. package/components/qds-breadcrumb-item.js +5 -5
  34. package/components/qds-breadcrumb-item.js.map +1 -1
  35. package/components/qds-button.js +5 -5
  36. package/components/qds-button.js.map +1 -1
  37. package/components/qds-checkbox.js +1 -1
  38. package/components/qds-chip.js +9 -9
  39. package/components/qds-chip.js.map +1 -1
  40. package/components/qds-dialog.js +6 -6
  41. package/components/qds-divider.js +1 -1
  42. package/components/qds-dropdown.js +1 -1
  43. package/components/qds-form-message.js +4 -4
  44. package/components/qds-form-message.js.map +1 -1
  45. package/components/qds-icon-button.js +1 -1
  46. package/components/qds-icon-tab.js +8 -8
  47. package/components/qds-icon.js +1 -1
  48. package/components/qds-inline-link.js +4 -4
  49. package/components/qds-inline-link.js.map +1 -1
  50. package/components/qds-input.js +17 -13
  51. package/components/qds-input.js.map +1 -1
  52. package/components/qds-label.js +153 -1
  53. package/components/qds-label.js.map +1 -1
  54. package/components/qds-list-item.js +25 -29
  55. package/components/qds-list-item.js.map +1 -1
  56. package/components/qds-loader.js +2 -2
  57. package/components/qds-loader.js.map +1 -1
  58. package/components/qds-menu-item.js +6 -6
  59. package/components/qds-mini-button.js +1 -1
  60. package/components/qds-progress-bar.js +1 -1
  61. package/components/qds-radio.js +1 -1
  62. package/components/qds-select.js +6 -6
  63. package/components/qds-select.js.map +1 -1
  64. package/components/qds-standalone-link.js +5 -5
  65. package/components/qds-standalone-link.js.map +1 -1
  66. package/components/qds-switch.js +5 -5
  67. package/components/qds-tab.js +20 -15
  68. package/components/qds-tab.js.map +1 -1
  69. package/components/qds-tabbar.js +95 -34
  70. package/components/qds-tabbar.js.map +1 -1
  71. package/components/qds-table-cell.js +32 -4
  72. package/components/qds-table-cell.js.map +1 -1
  73. package/components/qds-table-head-cell.js +32 -4
  74. package/components/qds-table-head-cell.js.map +1 -1
  75. package/components/qds-table-row.js +2 -2
  76. package/components/qds-table-row.js.map +1 -1
  77. package/components/qds-table.js +1 -1
  78. package/components/qds-tag.js +1 -1
  79. package/components/qds-textarea.js +4 -4
  80. package/components/qds-textarea.js.map +1 -1
  81. package/components/qds-title.js +1 -1
  82. package/components/qds-tooltip.js +1 -1
  83. package/dist/cjs/loader.cjs.js +1 -1
  84. package/dist/cjs/qds-action-item.cjs.entry.js +1 -1
  85. package/dist/cjs/qds-action-item.entry.cjs.js.map +1 -1
  86. package/dist/cjs/qds-avatar-media.qds-checkbox.qds-radio.entry.cjs.js.map +1 -1
  87. package/dist/cjs/qds-avatar-media_3.cjs.entry.js +144 -41
  88. package/dist/cjs/qds-badge-counter.qds-badge-indicator.entry.cjs.js.map +1 -1
  89. package/dist/cjs/qds-badge-counter_2.cjs.entry.js +1 -1
  90. package/dist/cjs/qds-breadcrumb-item.cjs.entry.js +2 -2
  91. package/dist/cjs/qds-breadcrumb-item.entry.cjs.js.map +1 -1
  92. package/dist/cjs/qds-button.cjs.entry.js +1 -1
  93. package/dist/cjs/qds-button.entry.cjs.js.map +1 -1
  94. package/dist/cjs/qds-chip.cjs.entry.js +5 -5
  95. package/dist/cjs/qds-chip.entry.cjs.js.map +1 -1
  96. package/dist/cjs/qds-dialog.cjs.entry.js +1 -1
  97. package/dist/cjs/qds-divider.qds-icon-button.entry.cjs.js.map +1 -1
  98. package/dist/cjs/qds-divider_2.cjs.entry.js +4 -4
  99. package/dist/cjs/qds-dropdown.cjs.entry.js +21 -3
  100. package/dist/cjs/qds-dropdown.entry.cjs.js.map +1 -1
  101. package/dist/cjs/qds-form-message.cjs.entry.js +2 -2
  102. package/dist/cjs/qds-form-message.entry.cjs.js.map +1 -1
  103. package/dist/cjs/qds-icon-tab.cjs.entry.js +3 -3
  104. package/dist/cjs/qds-icon.cjs.entry.js +9 -29
  105. package/dist/cjs/qds-icon.entry.cjs.js.map +1 -1
  106. package/dist/cjs/qds-inline-link.cjs.entry.js +2 -2
  107. package/dist/cjs/qds-inline-link.entry.cjs.js.map +1 -1
  108. package/dist/cjs/qds-input.cjs.entry.js +14 -10
  109. package/dist/cjs/qds-input.entry.cjs.js.map +1 -1
  110. package/dist/cjs/qds-label.cjs.entry.js +2 -2
  111. package/dist/cjs/qds-list-item.cjs.entry.js +6 -4
  112. package/dist/cjs/qds-list-item.entry.cjs.js.map +1 -1
  113. package/dist/cjs/qds-loader.cjs.entry.js +1 -1
  114. package/dist/cjs/qds-loader.entry.cjs.js.map +1 -1
  115. package/dist/cjs/qds-menu-item.cjs.entry.js +2 -2
  116. package/dist/cjs/qds-mini-button.cjs.entry.js +1 -1
  117. package/dist/cjs/qds-progress-bar.cjs.entry.js +1 -1
  118. package/dist/cjs/qds-select.cjs.entry.js +4 -4
  119. package/dist/cjs/qds-select.entry.cjs.js.map +1 -1
  120. package/dist/cjs/qds-standalone-link.cjs.entry.js +3 -3
  121. package/dist/cjs/qds-standalone-link.entry.cjs.js.map +1 -1
  122. package/dist/cjs/qds-switch.cjs.entry.js +3 -3
  123. package/dist/cjs/qds-tab.cjs.entry.js +15 -10
  124. package/dist/cjs/qds-tab.entry.cjs.js.map +1 -1
  125. package/dist/cjs/qds-tabbar.cjs.entry.js +83 -27
  126. package/dist/cjs/qds-tabbar.entry.cjs.js.map +1 -1
  127. package/dist/cjs/qds-table-cell.cjs.entry.js +30 -3
  128. package/dist/cjs/qds-table-cell.entry.cjs.js.map +1 -1
  129. package/dist/cjs/qds-table-head-cell.cjs.entry.js +30 -3
  130. package/dist/cjs/qds-table-head-cell.entry.cjs.js.map +1 -1
  131. package/dist/cjs/qds-table-row.cjs.entry.js +2 -2
  132. package/dist/cjs/qds-table-row.entry.cjs.js.map +1 -1
  133. package/dist/cjs/qds-table.cjs.entry.js +1 -1
  134. package/dist/cjs/qds-tag.cjs.entry.js +2 -2
  135. package/dist/cjs/qds-tag.entry.cjs.js.map +1 -1
  136. package/dist/cjs/qds-textarea.cjs.entry.js +3 -3
  137. package/dist/cjs/qds-textarea.entry.cjs.js.map +1 -1
  138. package/dist/cjs/qds-title.cjs.entry.js +3 -3
  139. package/dist/cjs/qds-title.entry.cjs.js.map +1 -1
  140. package/dist/cjs/qds-tooltip.cjs.entry.js +1 -1
  141. package/dist/cjs/qds.cjs.js +1 -1
  142. package/dist/custom-elements.json +365 -30
  143. package/dist/docs.json +319 -63
  144. package/dist/esm/{helpers-eFD8hV6J.js → helpers-Fe2AA6uo.js} +3 -3
  145. package/dist/esm/{helpers-eFD8hV6J.js.map → helpers-Fe2AA6uo.js.map} +1 -1
  146. package/dist/esm/loader.js +1 -1
  147. package/dist/esm/qds-action-item.entry.js +2 -2
  148. package/dist/esm/qds-action-item.entry.js.map +1 -1
  149. package/dist/esm/qds-avatar-media.qds-checkbox.qds-radio.entry.js.map +1 -1
  150. package/dist/esm/qds-avatar-media_3.entry.js +146 -43
  151. package/dist/esm/qds-badge-counter.qds-badge-indicator.entry.js.map +1 -1
  152. package/dist/esm/qds-badge-counter_2.entry.js +1 -1
  153. package/dist/esm/qds-breadcrumb-item.entry.js +3 -3
  154. package/dist/esm/qds-breadcrumb-item.entry.js.map +1 -1
  155. package/dist/esm/qds-button.entry.js +2 -2
  156. package/dist/esm/qds-button.entry.js.map +1 -1
  157. package/dist/esm/qds-chip.entry.js +6 -6
  158. package/dist/esm/qds-chip.entry.js.map +1 -1
  159. package/dist/esm/qds-dialog.entry.js +2 -2
  160. package/dist/esm/qds-divider.qds-icon-button.entry.js.map +1 -1
  161. package/dist/esm/qds-divider_2.entry.js +5 -5
  162. package/dist/esm/qds-dropdown.entry.js +22 -4
  163. package/dist/esm/qds-dropdown.entry.js.map +1 -1
  164. package/dist/esm/qds-form-message.entry.js +3 -3
  165. package/dist/esm/qds-form-message.entry.js.map +1 -1
  166. package/dist/esm/qds-icon-tab.entry.js +4 -4
  167. package/dist/esm/qds-icon.entry.js +10 -30
  168. package/dist/esm/qds-icon.entry.js.map +1 -1
  169. package/dist/esm/qds-inline-link.entry.js +3 -3
  170. package/dist/esm/qds-inline-link.entry.js.map +1 -1
  171. package/dist/esm/qds-input.entry.js +15 -11
  172. package/dist/esm/qds-input.entry.js.map +1 -1
  173. package/dist/esm/qds-label.entry.js +3 -3
  174. package/dist/esm/qds-list-item.entry.js +7 -5
  175. package/dist/esm/qds-list-item.entry.js.map +1 -1
  176. package/dist/esm/qds-loader.entry.js +1 -1
  177. package/dist/esm/qds-loader.entry.js.map +1 -1
  178. package/dist/esm/qds-menu-item.entry.js +3 -3
  179. package/dist/esm/qds-mini-button.entry.js +2 -2
  180. package/dist/esm/qds-progress-bar.entry.js +1 -1
  181. package/dist/esm/qds-select.entry.js +5 -5
  182. package/dist/esm/qds-select.entry.js.map +1 -1
  183. package/dist/esm/qds-standalone-link.entry.js +4 -4
  184. package/dist/esm/qds-standalone-link.entry.js.map +1 -1
  185. package/dist/esm/qds-switch.entry.js +4 -4
  186. package/dist/esm/qds-tab.entry.js +16 -11
  187. package/dist/esm/qds-tab.entry.js.map +1 -1
  188. package/dist/esm/qds-tabbar.entry.js +84 -28
  189. package/dist/esm/qds-tabbar.entry.js.map +1 -1
  190. package/dist/esm/qds-table-cell.entry.js +30 -3
  191. package/dist/esm/qds-table-cell.entry.js.map +1 -1
  192. package/dist/esm/qds-table-head-cell.entry.js +30 -3
  193. package/dist/esm/qds-table-head-cell.entry.js.map +1 -1
  194. package/dist/esm/qds-table-row.entry.js +2 -2
  195. package/dist/esm/qds-table-row.entry.js.map +1 -1
  196. package/dist/esm/qds-table.entry.js +1 -1
  197. package/dist/esm/qds-tag.entry.js +3 -3
  198. package/dist/esm/qds-tag.entry.js.map +1 -1
  199. package/dist/esm/qds-textarea.entry.js +4 -4
  200. package/dist/esm/qds-textarea.entry.js.map +1 -1
  201. package/dist/esm/qds-title.entry.js +3 -3
  202. package/dist/esm/qds-title.entry.js.map +1 -1
  203. package/dist/esm/qds-tooltip.entry.js +2 -2
  204. package/dist/esm/qds.js +1 -1
  205. package/dist/types/components/avatar-media/avatar-media.d.ts +14 -5
  206. package/dist/types/components/checkbox/checkbox.d.ts +4 -0
  207. package/dist/types/components/icon/icon.d.ts +1 -2
  208. package/dist/types/components/radio/radio.d.ts +4 -0
  209. package/dist/types/components/tab/tab.d.ts +1 -1
  210. package/dist/types/components/tabbar/tabbar.d.ts +27 -1
  211. package/dist/types/components/table-cell/table-cell.d.ts +6 -0
  212. package/dist/types/components/table-head-cell/table-head-cell.d.ts +6 -0
  213. package/dist/types/components.d.ts +72 -15
  214. package/dist/vscode.html-custom-data.json +79 -4
  215. package/hydrate/index.js +962 -732
  216. package/hydrate/index.mjs +962 -732
  217. package/package.json +1 -1
  218. package/styles/core.css +24 -22
  219. package/components/p-5dwtV5iH.js.map +0 -1
  220. package/components/p-C1c4JVlg.js.map +0 -1
  221. package/components/p-CDRwHAIT.js.map +0 -1
  222. package/components/p-CkUTS1aU.js.map +0 -1
  223. package/components/p-CkyaV9az.js.map +0 -1
  224. package/components/p-D9pW936J.js +0 -164
  225. package/components/p-D9pW936J.js.map +0 -1
  226. package/components/p-DNHI4C-W.js.map +0 -1
  227. package/components/p-DR79BVX5.js.map +0 -1
  228. package/components/p-DtxwXYGb.js.map +0 -1
  229. package/components/p-laE-pGH7.js +0 -163
  230. package/components/p-laE-pGH7.js.map +0 -1
@@ -1 +1 @@
1
- {"file":"qds-select.js","mappings":";;;;;;;;;;AAAA,MAAM,SAAS,GAAG,wgLAAwgL;;ACA1hL;AACA;AACA;;;;;;;;;;;;;;;;;;AAiCA,MAAM,UAAU,GAAG,MAAY;IAC7B,SAAS,CAAC,KAAK,CAAC;AAClB,CAAC;AACD,MAAM,wBAAwB,GAAiC;AAC7D,IAAA,MAAM,EAAE,CAAC;IACT,aAAa,EAAE,EAAE;AACjB,IAAA,GAAG,EAAE,UAAU;AACf,IAAA,MAAM,EAAE,UAAU;AAClB,IAAA,IAAI,EAAE,UAAU;AAChB,IAAA,SAAS,EAAE,UAAU;AACrB,IAAA,C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I,CAAC,MAAM;AACjB,QAAA,KAAK,OAAO;AACZ,QAAA,KAAK,SAAS;QACd,KAAK,SAAS,EAAE;YACd,OAAO,IAAI,CAAC,MAAM;;QAEpB,SAAS;AACP,YAAA,OAAO,SAAS;;;AAGtB,CAAC,EAAA,wBAAA,GAAA,SAAA,wBAAA,GAAA;AAGC,IAAA,QAAQ,IAAI,CAAC,IAAI;AACf,QAAA,KAAK,UAAU;AACf,QAAA,KAAK,OAAO;QACZ,KAAK,OAAO,EAAE;YACZ,OAAO,IAAI,CAAC,IAAI;;QAElB,SAAS;AACP,YAAA,OAAO,UAAU;;;AAGvB,CAAC,EAAA,wBAAA,GAAA,SAAA,wBAAA,GAAA;IAGC,SAAS,CAAC,sBAAA,CAAA,IAAI,EAAA,cAAA,EAAA,GAAA,CAAQ,CAAC;IAEvB,OAAO,sBAAA,CAAA,IAAI,EAAQ,cAAA,EAAA,GAAA,CAAA,CAAC,IAAI;AAC1B,CAAC,EAAA,yBAAA,GAAA,SAAA,yBAAA,GAAA;AAGC,IAAA,OAAO,IAAI,CAAC,KAAK,IAAI,EAAE;AACzB,CAAC,EAAA,mCAAA,GAAA,SAAA,mCAAA,GAAA;IAGC,SAAS,CAAC,sBAAA,CAAA,IAAI,EAAA,cAAA,EAAA,GAAA,CAAQ,CAAC;IAEvB,OAAO,sBAAA,CAAA,IAAI,EAAQ,cAAA,EAAA,GAAA,CAAA,CAAC,eAAe;AACrC,CAAC,EAAA,oBAAA,GAAA,SAAA,oBAAA,CAqMa,CAAc,EAAE,GAAkB,EAAA;AAC9C,IAAA,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC;AAChE,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/select/select.css?tag=qds-select&encapsulation=shadow","src/components/select/select.tsx"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: © 2024 Schneider Electric\n *\n * SPDX-License-Identifier: Apache-2.0\n */\n\n@import url('../shared.css');\n\n:host {\n display: inline-block;\n}\n\nslot {\n display: none;\n}\n\n.qds-container {\n box-sizing: border-box;\n display: grid;\n grid-template-areas: 'select';\n}\n\n.qds-container,\n.qds-select {\n width: inherit;\n}\n\n.qds-icon,\n.qds-select {\n color: var(--qds-theme-form-input-text-placeholder);\n grid-area: select;\n}\n\n.qds-icon {\n place-self: center end;\n pointer-events: none;\n}\n\n.qds-select {\n appearance: none;\n background-color: var(--qds-theme-form-input-background-default);\n border-color: var(--qds-theme-form-input-border-default);\n border-radius: var(\n --qds-control-border-radius-top-left,\n var(--qds-form-input-border-radius)\n )\n var(\n --qds-control-border-radius-top-right,\n var(--qds-form-input-border-radius)\n )\n var(\n --qds-control-border-radius-bottom-right,\n var(--qds-form-input-border-radius)\n )\n var(\n --qds-control-border-radius-bottom-left,\n var(--qds-form-input-border-radius)\n );\n border-style: solid;\n border-width: var(--qds-form-input-border-width-default)\n var(\n --qds-control-border-width-inline-end,\n var(--qds-form-input-border-width-default)\n )\n var(\n --qds-control-border-width-block-end,\n var(--qds-form-input-border-width-default)\n )\n var(--qds-form-input-border-width-default);\n margin: 0;\n outline: 0;\n padding-block: 0;\n text-overflow: ellipsis;\n\n &:enabled:hover {\n background-color: var(--qds-theme-form-input-background-hover);\n border-color: var(--qds-theme-form-input-border-hover);\n }\n\n &:enabled:active {\n background-color: var(--qds-theme-form-input-background-active);\n color: var(--qds-theme-form-input-text-active);\n }\n\n &:not(:focus):user-invalid {\n border-color: var(--qds-theme-feedback-result-failure);\n }\n\n &[data-status] {\n border-width: var(--qds-form-input-border-width-status)\n var(\n --qds-control-border-width-inline-end,\n var(--qds-form-input-border-width-status)\n )\n var(\n --qds-control-border-width-block-end,\n var(--qds-form-input-border-width-status)\n )\n var(--qds-form-input-border-width-status);\n }\n\n &[data-status='success'] {\n border-color: var(--qds-theme-form-input-border-success);\n }\n\n &[data-status='warning'] {\n border-color: var(--qds-theme-form-input-border-warning);\n }\n\n &[data-status='error'],\n :not(:focus):user-invalid {\n border-color: var(--qds-theme-form-input-border-error);\n }\n}\n\n.qds-select:disabled,\n.qds-select:disabled + .qds-icon {\n opacity: var(--qds-theme-disabled);\n}\n\n:is(\n ::slotted(optgroup),\n ::slotted(optgroup:not(:disabled) > option),\n ::slotted(option)\n):disabled {\n opacity: var(--qds-theme-disabled);\n}\n\n::slotted(optgroup) {\n font: var(--qds-accessory-section-title);\n}\n\n::slotted(optgroup > option),\n::slotted(option) {\n font: var(--qds-list-item-label-main);\n}\n\n[data-size='small'] {\n &.qds-select {\n font: var(--qds-form-small-text);\n padding-inline: var(--qds-form-input-small-padding-start)\n var(--qds-form-input-small-padding-end);\n\n &:not([multiple]) {\n min-height: var(--qds-form-input-small-height);\n padding-inline-end: calc(\n var(--qds-control-small-icon-size) +\n var(--qds-form-input-small-gap-internal) +\n var(--qds-form-input-small-padding-end)\n );\n }\n }\n\n &.qds-icon {\n margin-inline-end: calc(\n var(--qds-form-input-small-padding-end) +\n var(--qds-form-input-border-width-default)\n );\n height: var(--qds-control-small-icon-size);\n width: var(--qds-control-small-icon-size);\n }\n}\n\n[data-size='standard'] {\n &.qds-select {\n font: var(--qds-form-standard-text);\n padding-inline: var(--qds-form-input-standard-padding-start)\n var(--qds-form-input-standard-padding-end);\n\n &:not([multiple]) {\n min-height: var(--qds-form-input-standard-height);\n padding-inline-end: calc(\n var(--qds-control-standard-icon-size) +\n var(--qds-form-input-standard-gap-internal) +\n var(--qds-form-input-standard-padding-end)\n );\n }\n }\n\n &.qds-icon {\n margin-inline-end: calc(\n var(--qds-form-input-standard-padding-end) +\n var(--qds-form-input-border-width-default)\n );\n height: var(--qds-control-standard-icon-size);\n width: var(--qds-control-standard-icon-size);\n }\n}\n\n[data-size='large'] {\n &.qds-select {\n font: var(--qds-form-large-text);\n padding-inline: var(--qds-form-input-large-padding-start)\n var(--qds-form-input-large-padding-end);\n\n &:not([multiple]) {\n min-height: var(--qds-form-input-large-height);\n padding-inline-end: calc(\n var(--qds-control-large-icon-size) +\n var(--qds-form-input-large-gap-internal) +\n var(--qds-form-input-large-padding-end)\n );\n }\n }\n\n &.qds-icon {\n margin-inline-end: calc(\n var(--qds-form-input-large-padding-end) +\n var(--qds-form-input-border-width-default)\n );\n height: var(--qds-control-large-icon-size);\n width: var(--qds-control-large-icon-size);\n }\n}\n\n.qds-focus-ring {\n border-radius: max(\n 1px,\n var(\n --qds-control-border-radius-top-left,\n var(--qds-form-input-border-radius)\n )\n )\n max(\n 1px,\n var(\n --qds-control-border-radius-top-right,\n var(--qds-form-input-border-radius)\n )\n )\n max(\n 1px,\n var(\n --qds-control-border-radius-bottom-right,\n var(--qds-form-input-border-radius)\n )\n )\n max(\n 1px,\n var(\n --qds-control-border-radius-bottom-left,\n var(--qds-form-input-border-radius)\n )\n );\n grid-area: select;\n isolation: isolate;\n\n /* inner ring */\n outline: var(--qds-theme-focus-border-contrast) solid\n var(--qds-focus-light-border-width);\n outline-offset: 0;\n\n /* outer ring */\n box-shadow: 0 0 0 var(--qds-focus-heavy-border-width)\n var(--qds-theme-focus-border);\n pointer-events: none;\n visibility: hidden;\n width: calc(\n 100% + var(--qds-form-input-border-width-default) -\n var(\n --qds-control-border-width-inline-end,\n var(--qds-form-input-border-width-default)\n )\n );\n height: calc(\n 100% + var(--qds-form-input-border-width-default) -\n var(\n --qds-control-border-width-block-end,\n var(--qds-form-input-border-width-default)\n )\n );\n}\n\n.qds-select:focus-visible ~ .qds-focus-ring {\n visibility: visible;\n}\n","// SPDX-FileCopyrightText: © 2024 Schneider Electric\n//\n// SPDX-License-Identifier: Apache-2.0\n\nimport type { ComponentInterface, EventEmitter } from '@stencil/core'\nimport {\n AttachInternals,\n Component,\n Element,\n Event,\n h,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core'\n\nimport type {\n Attributes,\n QdsFocusEventDetail,\n QdsInputEventDetail,\n} from '../../helpers'\nimport {\n inheritAriaAttributes,\n invariant,\n pickFocusEventAttributes,\n pickInputEventAttributes,\n} from '../../helpers'\nimport type { AutoComplete } from '../controls'\nimport { CUSTOM_ERROR_FLAGS, NO_ERROR_FLAGS, VALID_STATE } from '../controls'\nimport type { Size, Status } from '../shared'\n\nexport type SelectType = 'select-multiple' | 'select-one'\nexport type SelectStatus = Exclude<Status, 'info'>\n\nconst throwError = (): never => {\n invariant(false)\n}\nconst EMPTY_OPTIONS_COLLECTION: HTMLSelectElement['options'] = {\n length: 0,\n selectedIndex: -1,\n add: throwError,\n remove: throwError,\n item: throwError,\n namedItem: throwError,\n [Symbol.iterator]: throwError,\n}\n\n/**\n * The `<qds-select>` element represents a control that provides a menu of\n * options.\n *\n * @see https://quartz.se.com/build/components/select\n */\n@Component({\n tag: 'qds-select',\n formAssociated: true,\n shadow: { delegatesFocus: true },\n styleUrl: 'select.css',\n})\nexport class Select implements ComponentInterface {\n /**\n * The select's status.\n */\n @Prop() public readonly status?: SelectStatus\n\n /**\n * The select's size.\n *\n * > ***NOTE:*** The native [`size` HTML attribute] is not supported. CSS\n * `height` should be used instead if this functionality is needed.\n *\n * [`size` HTML attribute]: https://developer.mozilla.org/docs/Web/HTML/Attributes/size\n */\n @Prop() public readonly size?: Size = 'standard'\n\n /**\n * Provides a hint for a [user agent's][] autocomplete feature. See\n * [the HTML `autocomplete` attribute][] for a complete list of values and\n * details on how to use `autoComplete`.\n *\n * [user agent's]: https://developer.mozilla.org/docs/Glossary/User_agent\n * [the HTML `autocomplete` attribute]: https://developer.mozilla.org/docs/Web/HTML/Attributes/autocomplete\n *\n * @webnative\n */\n @Prop({ attribute: 'autocomplete' })\n public readonly autoComplete?: AutoComplete\n\n /**\n * Prevents the select from being interacted with: it cannot be pressed or\n * focused.\n *\n * @webnative\n */\n @Prop() public readonly disabled?: boolean\n\n /**\n * The [`<form>`][] element to associate the select with (its form owner).\n *\n * The value of this attribute must be the id of a `<form>` in the same\n * document. If this attribute is not set, the `<qds-select>` is associated\n * with its ancestor `<form>` element, if any.\n *\n * This attribute lets you associate `<qds-select>` elements to `<form>`s\n * anywhere in the document, not just inside a `<form>`. It can also override\n * an ancestor `<form>` element.\n *\n * [`<form>`]: https://developer.mozilla.org/docs/Web/HTML/Element/form\n *\n * @readonly\n * @webnative\n */\n // eslint-disable-next-line unicorn/no-null\n @Prop() public readonly form: ElementInternals['form'] | string = null\n\n /**\n * Returns the number of elements in the [`<option>`s collection][].\n *\n * [`<option>`s collection]: https://developer.mozilla.org/docs/Web/API/HTMLOptionsCollection\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly length: HTMLSelectElement['length'] = 0\n\n /**\n * Indicates that multiple options can be selected in the list. If it is not\n * specified, then only one option can be selected at a time. When `multiple`\n * is specified, most browsers will show a scrolling list box instead of a\n * single line dropdown.\n *\n * @webnative\n */\n @Prop() public multiple?: boolean\n\n /**\n * The name of the select, which is submitted with the form data.\n *\n * @webnative\n */\n @Prop() public readonly name?: string\n\n /**\n * An [`HTMLOptionsCollection`][] of the [`<option>`][] elements contained by\n * the `<qds-select>` element.\n *\n * [`HTMLOptionsCollection`]: https://developer.mozilla.org/docs/Web/API/HTMLOptionsCollection\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly options: HTMLSelectElement['options'] =\n EMPTY_OPTIONS_COLLECTION\n\n /**\n * An `<option>` with a non-empty string value must be selected before this\n * select can be submitted.\n *\n * See [Client-side validation] and the [HTML attribute: `required`] for more\n * information.\n *\n * [Client-side validation]: https://developer.mozilla.org/docs/Web/HTML/Element/input#client-side_validation\n * [HTML attribute: `required`]: https://developer.mozilla.org/docs/Web/HTML/Attributes/required\n *\n * @webnative\n */\n @Prop() public readonly required?: boolean\n\n /**\n * The index of the first or last selected [`<option>`][] element, depending\n * on the value of `multiple`. The value `-1` indicates that no element is\n * selected.\n *\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @webnative\n */\n @Prop({ mutable: true })\n public selectedIndex: HTMLSelectElement['selectedIndex'] = -1\n\n /**\n * Collection of the [`<option>`][] elements contained within the\n * `<qds-select>` element that are currently selected.\n *\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @readonly\n * @webnative\n */\n @Prop()\n public readonly selectedOptions: HTMLSelectElement['selectedOptions'] =\n EMPTY_OPTIONS_COLLECTION\n\n /**\n * Returns `select-multiple` if the `multiple` attribute is true;\n * `select-one` otherwise.\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly type: SelectType = 'select-one'\n\n /**\n * The error message that would be shown to the user if the `<qds-select>`\n * was to be checked for validity.\n *\n * @readonly\n * @webnative\n */\n @Prop()\n public readonly validationMessage: ElementInternals['validationMessage'] = ''\n\n /**\n * The [`ValidityState`][] object for this `<qds-select>`.\n *\n * [`ValidityState`]: https://developer.mozilla.org/docs/Web/API/ValidityState\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly validity: ElementInternals['validity'] = VALID_STATE\n\n /**\n * The `value` property of the first selected [`<option>`][] element, or the\n * empty string if no options are selected.\n *\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @webnative\n */\n @Prop({ mutable: true }) public value? = ''\n\n /**\n * True if `<qds-select>` will be validated when the form is submitted;\n * false otherwise.\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly willValidate: ElementInternals['willValidate'] = false\n\n @AttachInternals() private readonly internals!: ElementInternals\n\n /**\n * Emitted when the select loses focus.\n */\n @Event({ eventName: 'qdsBlur', bubbles: false, cancelable: false })\n private readonly blurEmitter!: EventEmitter<QdsFocusEventDetail>\n\n /**\n * Emitted when an alteration to the select's value is committed by the\n * user.\n */\n @Event({ eventName: 'qdsChange', cancelable: false })\n private readonly changeEmitter!: EventEmitter<void>\n\n /**\n * Emitted when the select gains focus.\n */\n @Event({ eventName: 'qdsFocus', bubbles: false, cancelable: false })\n private readonly focusEmitter!: EventEmitter<QdsFocusEventDetail>\n\n /**\n * Emitted when the select's value changes.\n */\n @Event({ eventName: 'qdsInput', cancelable: false })\n private readonly inputEmitter!: EventEmitter<QdsInputEventDetail>\n\n @Element() private readonly host!: HTMLElement\n\n @State() private tabIndex?: number\n\n #inheritedAttributes: Attributes = {}\n\n #select?: HTMLSelectElement\n\n get #computedDisabled(): boolean {\n return (\n (this.host.matches(':disabled') || (this.disabled ?? false)) &&\n this.host.getAttribute('disabled') !== 'false'\n )\n }\n\n get #computedOptions(): HTMLSelectElement['options'] {\n invariant(this.#select)\n\n return this.#select.options\n }\n\n get #computedStatus(): SelectStatus | undefined {\n switch (this.status) {\n case 'error':\n case 'success':\n case 'warning': {\n return this.status\n }\n default: {\n return undefined\n }\n }\n }\n\n get #computedSize(): Size {\n switch (this.size) {\n case 'standard':\n case 'small':\n case 'large': {\n return this.size\n }\n default: {\n return 'standard'\n }\n }\n }\n\n get #computedType(): HTMLSelectElement['type'] {\n invariant(this.#select)\n\n return this.#select.type\n }\n\n get #computedValue(): string {\n return this.value ?? ''\n }\n\n get #computedSelectedOptions(): HTMLSelectElement['selectedOptions'] {\n invariant(this.#select)\n\n return this.#select.selectedOptions\n }\n\n @Listen('click')\n protected onClick(event: MouseEvent): void {\n if (this.#computedDisabled) event.stopImmediatePropagation()\n }\n\n @Watch('disabled')\n protected disabledChanged(): void {\n if (this.#computedDisabled)\n // eslint-disable-next-line unicorn/no-null\n this.internals.setFormValue(null)\n else this.internals.setFormValue(this.#computedValue)\n }\n\n @Watch('selectedIndex')\n protected selectedIndexChanged(): void {\n invariant(this.#select)\n\n this.#select.selectedIndex = this.selectedIndex\n }\n\n @Watch('tabindex')\n protected tabindexChanged(newValue: string): void {\n const parsedValue = Number.parseInt(newValue, 10)\n this.tabIndex =\n parsedValue === 0 || Number.isNaN(parsedValue) ? undefined : parsedValue\n }\n\n @Watch('required')\n @Watch('value')\n protected validationChanged(): void {\n invariant(this.#select)\n\n this.#select.value = this.#computedValue\n this.#select.required = this.required ?? false\n\n const { valid } = this.#select.validity\n if (valid)\n this.internals.setValidity(NO_ERROR_FLAGS, undefined, this.#select)\n else\n this.internals.setValidity(\n this.#select.validity,\n this.#select.validationMessage,\n this.#select,\n )\n }\n\n @Watch('status')\n protected statusChanged(): void {\n this.internals.ariaInvalid = (this.#computedStatus === 'error').toString()\n }\n\n public componentWillLoad(): void {\n this.#defineGetter('form', () => this.internals.form)\n this.#defineGetter('willValidate', () => this.internals.willValidate)\n this.#defineGetter('validity', () => this.internals.validity)\n this.#defineGetter(\n 'validationMessage',\n () => this.internals.validationMessage,\n )\n\n this.#defineGetter('type', () => this.#computedType)\n this.#defineGetter('options', () => this.#computedOptions)\n this.#defineGetter('length', () => this.#computedOptions.length)\n this.#defineGetter('selectedOptions', () => this.#computedSelectedOptions)\n\n this.#inheritedAttributes = inheritAriaAttributes(this.host)\n this.tabindexChanged(this.host.getAttribute('tabindex') ?? '0')\n this.statusChanged()\n }\n\n public componentDidLoad(): void {\n invariant(this.#select)\n\n this.validationChanged()\n this.selectedIndex = this.#select.selectedIndex\n }\n\n public render() {\n return (\n <div\n class={{\n 'qds-container': true,\n 'qds-multiple': this.multiple ?? false,\n }}\n data-size={this.#computedSize}\n >\n <select\n autoComplete={this.autoComplete}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={this.host.autofocus}\n class=\"qds-select\"\n data-size={this.#computedSize}\n data-status={this.#computedStatus}\n disabled={this.#computedDisabled}\n multiple={this.multiple}\n name={this.name}\n onBlur={this.#onBlur}\n onChange={this.#onChange}\n onFocus={this.#onFocus}\n onInput={this.#onInput}\n ref={this.#ref}\n required={this.required}\n tabIndex={this.#computedDisabled ? undefined : this.tabIndex}\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...this.#inheritedAttributes}\n />\n {this.multiple !== true && (\n <qds-icon\n aria-hidden=\"true\"\n class=\"qds-icon\"\n data-size={this.#computedSize}\n library=\"core\"\n name=\"dropdown\"\n />\n )}\n <slot onSlotchange={this.#onSlotchange} />\n <div class=\"qds-focus-ring\" />\n </div>\n )\n }\n\n public checkValidity: ElementInternals['checkValidity'] = () =>\n this.internals.checkValidity()\n\n public reportValidity: ElementInternals['reportValidity'] = () =>\n this.internals.reportValidity()\n\n public setCustomValidity: HTMLSelectElement['setCustomValidity'] = (\n error,\n ) => {\n invariant(this.#select)\n\n this.#select.setCustomValidity(error)\n if (error)\n this.internals.setValidity(CUSTOM_ERROR_FLAGS, error, this.#select)\n else this.internals.setValidity(NO_ERROR_FLAGS)\n }\n\n public addItem: HTMLSelectElement['add'] = (element, before) => {\n invariant(this.#select)\n\n this.#select.add(element, before)\n }\n\n public removeItem = (index: number): void => {\n invariant(this.#select)\n\n this.#select.remove(index)\n }\n\n public item: HTMLSelectElement['item'] = (index) => {\n invariant(this.#select)\n\n return this.#select.item(index)\n }\n\n public namedItem: HTMLSelectElement['namedItem'] = (name) => {\n invariant(this.#select)\n\n return this.#select.namedItem(name)\n }\n\n readonly #ref = (select?: HTMLSelectElement): void => {\n this.#select = select\n }\n\n readonly #onBlur = (event: FocusEvent): void => {\n this.blurEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onChange = (): void => {\n this.changeEmitter.emit()\n }\n\n readonly #onFocus = (event: FocusEvent): void => {\n this.focusEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onInput = (event: InputEvent): void => {\n invariant(this.#select)\n\n this.value = this.#select.value\n this.inputEmitter.emit(pickInputEventAttributes(event))\n }\n\n readonly #onSlotchange = (event: Event): void => {\n invariant(this.#select)\n const { currentTarget } = event\n invariant(currentTarget instanceof HTMLSlotElement)\n\n this.#select.replaceChildren(\n ...currentTarget.assignedNodes().map((node) => node.cloneNode(true)),\n )\n }\n\n #defineGetter(p: PropertyKey, get: () => unknown): void {\n Object.defineProperty(this.host, p, { enumerable: true, get })\n }\n}\n"],"version":3}
1
+ {"file":"qds-select.js","mappings":";;;;;;;;;;AAAA,MAAM,SAAS,GAAG,kjLAAkjL;;ACApkL;AACA;AACA;;;;;;;;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AkB,EAAA;AAC9C,IAAA,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC;AAChE,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/select/select.css?tag=qds-select&encapsulation=shadow","src/components/select/select.tsx"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: © 2024 Schneider Electric\n *\n * SPDX-License-Identifier: Apache-2.0\n */\n\n@import url('../shared.css');\n\n:host {\n display: inline-block;\n}\n\nslot {\n display: none;\n}\n\n.qds-container {\n box-sizing: border-box;\n display: grid;\n grid-template-areas: 'select';\n}\n\n.qds-container,\n.qds-select {\n width: inherit;\n}\n\n.qds-icon,\n.qds-select {\n color: var(--qds-theme-form-input-text-placeholder);\n grid-area: select;\n}\n\n.qds-icon {\n place-self: center end;\n pointer-events: none;\n}\n\n.qds-select {\n appearance: none;\n background-color: var(--qds-theme-form-input-background-default);\n border-color: var(--qds-theme-form-input-border-default);\n border-radius: var(\n --qds-form-input-border-radius-top-left,\n var(--qds-form-input-border-radius)\n )\n var(\n --qds-form-input-border-radius-top-right,\n var(--qds-form-input-border-radius)\n )\n var(\n --qds-form-input-border-radius-bottom-right,\n var(--qds-form-input-border-radius)\n )\n var(\n --qds-form-input-border-radius-bottom-left,\n var(--qds-form-input-border-radius)\n );\n border-style: solid;\n border-width: var(--qds-form-input-border-width-default)\n var(\n --qds-form-input-border-width-inline-end,\n var(--qds-form-input-border-width-default)\n )\n var(\n --qds-form-input-border-width-block-end,\n var(--qds-form-input-border-width-default)\n )\n var(--qds-form-input-border-width-default);\n margin: 0;\n outline: 0;\n padding-block: 0;\n text-overflow: ellipsis;\n\n &:enabled:hover {\n background-color: var(--qds-theme-form-input-background-hover);\n border-color: var(--qds-theme-form-input-border-hover);\n }\n\n &:enabled:active {\n background-color: var(--qds-theme-form-input-background-active);\n color: var(--qds-theme-form-input-text-active);\n }\n\n &:not(:focus):user-invalid {\n border-color: var(--qds-theme-feedback-result-failure);\n }\n\n &[data-status] {\n border-width: var(--qds-form-input-border-width-status)\n var(\n --qds-form-input-border-width-inline-end,\n var(--qds-form-input-border-width-status)\n )\n var(\n --qds-form-input-border-width-block-end,\n var(--qds-form-input-border-width-status)\n )\n var(--qds-form-input-border-width-status);\n }\n\n &[data-status='success'] {\n border-color: var(--qds-theme-form-input-border-success);\n }\n\n &[data-status='warning'] {\n border-color: var(--qds-theme-form-input-border-warning);\n }\n\n &[data-status='error'],\n :not(:focus):user-invalid {\n border-color: var(--qds-theme-form-input-border-error);\n }\n}\n\n.qds-select:disabled,\n.qds-select:disabled + .qds-icon {\n opacity: var(--qds-theme-disabled);\n}\n\n:is(\n ::slotted(optgroup),\n ::slotted(optgroup:not(:disabled) > option),\n ::slotted(option)\n):disabled {\n opacity: var(--qds-theme-disabled);\n}\n\n::slotted(optgroup) {\n font: var(--qds-accessory-section-title);\n}\n\n::slotted(optgroup > option),\n::slotted(option) {\n font: var(--qds-list-item-label-main);\n}\n\n[data-size='small'] {\n &.qds-select {\n font: var(--qds-form-small-text);\n padding-inline: var(--qds-form-input-small-padding-start)\n var(--qds-form-input-small-padding-end);\n\n &:not([multiple]) {\n min-height: var(--qds-form-input-small-height);\n padding-inline-end: calc(\n var(--qds-control-small-icon-size) +\n var(--qds-form-input-small-gap-internal) +\n var(--qds-form-input-small-padding-end)\n );\n }\n }\n\n &.qds-icon {\n margin-inline-end: calc(\n var(--qds-form-input-small-padding-end) +\n var(--qds-form-input-border-width-default)\n );\n height: var(--qds-control-small-icon-size);\n width: var(--qds-control-small-icon-size);\n }\n}\n\n[data-size='standard'] {\n &.qds-select {\n font: var(--qds-form-standard-text);\n padding-inline: var(--qds-form-input-standard-padding-start)\n var(--qds-form-input-standard-padding-end);\n\n &:not([multiple]) {\n min-height: var(--qds-form-input-standard-height);\n padding-inline-end: calc(\n var(--qds-control-standard-icon-size) +\n var(--qds-form-input-standard-gap-internal) +\n var(--qds-form-input-standard-padding-end)\n );\n }\n }\n\n &.qds-icon {\n margin-inline-end: calc(\n var(--qds-form-input-standard-padding-end) +\n var(--qds-form-input-border-width-default)\n );\n height: var(--qds-control-standard-icon-size);\n width: var(--qds-control-standard-icon-size);\n }\n}\n\n[data-size='large'] {\n &.qds-select {\n font: var(--qds-form-large-text);\n padding-inline: var(--qds-form-input-large-padding-start)\n var(--qds-form-input-large-padding-end);\n\n &:not([multiple]) {\n min-height: var(--qds-form-input-large-height);\n padding-inline-end: calc(\n var(--qds-control-large-icon-size) +\n var(--qds-form-input-large-gap-internal) +\n var(--qds-form-input-large-padding-end)\n );\n }\n }\n\n &.qds-icon {\n margin-inline-end: calc(\n var(--qds-form-input-large-padding-end) +\n var(--qds-form-input-border-width-default)\n );\n height: var(--qds-control-large-icon-size);\n width: var(--qds-control-large-icon-size);\n }\n}\n\n.qds-focus-ring {\n border-radius: max(\n 1px,\n var(\n --qds-form-input-border-radius-top-left,\n var(--qds-form-input-border-radius)\n )\n )\n max(\n 1px,\n var(\n --qds-form-input-border-radius-top-right,\n var(--qds-form-input-border-radius)\n )\n )\n max(\n 1px,\n var(\n --qds-form-input-border-radius-bottom-right,\n var(--qds-form-input-border-radius)\n )\n )\n max(\n 1px,\n var(\n --qds-form-input-border-radius-bottom-left,\n var(--qds-form-input-border-radius)\n )\n );\n grid-area: select;\n isolation: isolate;\n\n /* inner ring */\n outline: var(--qds-theme-focus-border-contrast) solid\n var(--qds-focus-light-border-width);\n outline-offset: 0;\n\n /* outer ring */\n box-shadow: 0 0 0 var(--qds-focus-heavy-border-width)\n var(--qds-theme-focus-border);\n pointer-events: none;\n visibility: hidden;\n width: calc(\n 100% + var(--qds-form-input-border-width-default) -\n var(\n --qds-form-input-border-width-inline-end,\n var(--qds-form-input-border-width-default)\n )\n );\n height: calc(\n 100% + var(--qds-form-input-border-width-default) -\n var(\n --qds-form-input-border-width-block-end,\n var(--qds-form-input-border-width-default)\n )\n );\n}\n\n.qds-select:focus-visible ~ .qds-focus-ring {\n visibility: visible;\n}\n","// SPDX-FileCopyrightText: © 2024 Schneider Electric\n//\n// SPDX-License-Identifier: Apache-2.0\n\nimport type { ComponentInterface, EventEmitter } from '@stencil/core'\nimport {\n AttachInternals,\n Component,\n Element,\n Event,\n h,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core'\n\nimport type {\n Attributes,\n QdsFocusEventDetail,\n QdsInputEventDetail,\n} from '../../helpers'\nimport {\n inheritAriaAttributes,\n invariant,\n pickFocusEventAttributes,\n pickInputEventAttributes,\n} from '../../helpers'\nimport type { AutoComplete } from '../controls'\nimport { CUSTOM_ERROR_FLAGS, NO_ERROR_FLAGS, VALID_STATE } from '../controls'\nimport type { Size, Status } from '../shared'\n\nexport type SelectType = 'select-multiple' | 'select-one'\nexport type SelectStatus = Exclude<Status, 'info'>\n\nconst throwError = (): never => {\n invariant(false)\n}\nconst EMPTY_OPTIONS_COLLECTION: HTMLSelectElement['options'] = {\n length: 0,\n selectedIndex: -1,\n add: throwError,\n remove: throwError,\n item: throwError,\n namedItem: throwError,\n [Symbol.iterator]: throwError,\n}\n\n/**\n * The `<qds-select>` element represents a control that provides a menu of\n * options.\n *\n * @see https://quartz.se.com/build/components/select\n */\n@Component({\n tag: 'qds-select',\n formAssociated: true,\n shadow: { delegatesFocus: true },\n styleUrl: 'select.css',\n})\nexport class Select implements ComponentInterface {\n /**\n * The select's status.\n */\n @Prop() public readonly status?: SelectStatus\n\n /**\n * The select's size.\n *\n * > ***NOTE:*** The native [`size` HTML attribute] is not supported. CSS\n * `height` should be used instead if this functionality is needed.\n *\n * [`size` HTML attribute]: https://developer.mozilla.org/docs/Web/HTML/Attributes/size\n */\n @Prop() public readonly size?: Size = 'standard'\n\n /**\n * Provides a hint for a [user agent's][] autocomplete feature. See\n * [the HTML `autocomplete` attribute][] for a complete list of values and\n * details on how to use `autoComplete`.\n *\n * [user agent's]: https://developer.mozilla.org/docs/Glossary/User_agent\n * [the HTML `autocomplete` attribute]: https://developer.mozilla.org/docs/Web/HTML/Attributes/autocomplete\n *\n * @webnative\n */\n @Prop({ attribute: 'autocomplete' })\n public readonly autoComplete?: AutoComplete\n\n /**\n * Prevents the select from being interacted with: it cannot be pressed or\n * focused.\n *\n * @webnative\n */\n @Prop() public readonly disabled?: boolean\n\n /**\n * The [`<form>`][] element to associate the select with (its form owner).\n *\n * The value of this attribute must be the id of a `<form>` in the same\n * document. If this attribute is not set, the `<qds-select>` is associated\n * with its ancestor `<form>` element, if any.\n *\n * This attribute lets you associate `<qds-select>` elements to `<form>`s\n * anywhere in the document, not just inside a `<form>`. It can also override\n * an ancestor `<form>` element.\n *\n * [`<form>`]: https://developer.mozilla.org/docs/Web/HTML/Element/form\n *\n * @readonly\n * @webnative\n */\n // eslint-disable-next-line unicorn/no-null\n @Prop() public readonly form: ElementInternals['form'] | string = null\n\n /**\n * Returns the number of elements in the [`<option>`s collection][].\n *\n * [`<option>`s collection]: https://developer.mozilla.org/docs/Web/API/HTMLOptionsCollection\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly length: HTMLSelectElement['length'] = 0\n\n /**\n * Indicates that multiple options can be selected in the list. If it is not\n * specified, then only one option can be selected at a time. When `multiple`\n * is specified, most browsers will show a scrolling list box instead of a\n * single line dropdown.\n *\n * @webnative\n */\n @Prop() public multiple?: boolean\n\n /**\n * The name of the select, which is submitted with the form data.\n *\n * @webnative\n */\n @Prop() public readonly name?: string\n\n /**\n * An [`HTMLOptionsCollection`][] of the [`<option>`][] elements contained by\n * the `<qds-select>` element.\n *\n * [`HTMLOptionsCollection`]: https://developer.mozilla.org/docs/Web/API/HTMLOptionsCollection\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly options: HTMLSelectElement['options'] =\n EMPTY_OPTIONS_COLLECTION\n\n /**\n * An `<option>` with a non-empty string value must be selected before this\n * select can be submitted.\n *\n * See [Client-side validation] and the [HTML attribute: `required`] for more\n * information.\n *\n * [Client-side validation]: https://developer.mozilla.org/docs/Web/HTML/Element/input#client-side_validation\n * [HTML attribute: `required`]: https://developer.mozilla.org/docs/Web/HTML/Attributes/required\n *\n * @webnative\n */\n @Prop() public readonly required?: boolean\n\n /**\n * The index of the first or last selected [`<option>`][] element, depending\n * on the value of `multiple`. The value `-1` indicates that no element is\n * selected.\n *\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @webnative\n */\n @Prop({ mutable: true })\n public selectedIndex: HTMLSelectElement['selectedIndex'] = -1\n\n /**\n * Collection of the [`<option>`][] elements contained within the\n * `<qds-select>` element that are currently selected.\n *\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @readonly\n * @webnative\n */\n @Prop()\n public readonly selectedOptions: HTMLSelectElement['selectedOptions'] =\n EMPTY_OPTIONS_COLLECTION\n\n /**\n * Returns `select-multiple` if the `multiple` attribute is true;\n * `select-one` otherwise.\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly type: SelectType = 'select-one'\n\n /**\n * The error message that would be shown to the user if the `<qds-select>`\n * was to be checked for validity.\n *\n * @readonly\n * @webnative\n */\n @Prop()\n public readonly validationMessage: ElementInternals['validationMessage'] = ''\n\n /**\n * The [`ValidityState`][] object for this `<qds-select>`.\n *\n * [`ValidityState`]: https://developer.mozilla.org/docs/Web/API/ValidityState\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly validity: ElementInternals['validity'] = VALID_STATE\n\n /**\n * The `value` property of the first selected [`<option>`][] element, or the\n * empty string if no options are selected.\n *\n * [`<option>`]: https://developer.mozilla.org/docs/Web/HTML/Element/option\n *\n * @webnative\n */\n @Prop({ mutable: true }) public value? = ''\n\n /**\n * True if `<qds-select>` will be validated when the form is submitted;\n * false otherwise.\n *\n * @readonly\n * @webnative\n */\n @Prop() public readonly willValidate: ElementInternals['willValidate'] = false\n\n @AttachInternals() private readonly internals!: ElementInternals\n\n /**\n * Emitted when the select loses focus.\n */\n @Event({ eventName: 'qdsBlur', bubbles: false, cancelable: false })\n private readonly blurEmitter!: EventEmitter<QdsFocusEventDetail>\n\n /**\n * Emitted when an alteration to the select's value is committed by the\n * user.\n */\n @Event({ eventName: 'qdsChange', cancelable: false })\n private readonly changeEmitter!: EventEmitter<void>\n\n /**\n * Emitted when the select gains focus.\n */\n @Event({ eventName: 'qdsFocus', bubbles: false, cancelable: false })\n private readonly focusEmitter!: EventEmitter<QdsFocusEventDetail>\n\n /**\n * Emitted when the select's value changes.\n */\n @Event({ eventName: 'qdsInput', cancelable: false })\n private readonly inputEmitter!: EventEmitter<QdsInputEventDetail>\n\n @Element() private readonly host!: HTMLElement\n\n @State() private tabIndex?: number\n\n #inheritedAttributes: Attributes = {}\n\n #select?: HTMLSelectElement\n\n get #computedDisabled(): boolean {\n return (\n (this.host.matches(':disabled') || (this.disabled ?? false)) &&\n this.host.getAttribute('disabled') !== 'false'\n )\n }\n\n get #computedOptions(): HTMLSelectElement['options'] {\n invariant(this.#select)\n\n return this.#select.options\n }\n\n get #computedStatus(): SelectStatus | undefined {\n switch (this.status) {\n case 'error':\n case 'success':\n case 'warning': {\n return this.status\n }\n default: {\n return undefined\n }\n }\n }\n\n get #computedSize(): Size {\n switch (this.size) {\n case 'standard':\n case 'small':\n case 'large': {\n return this.size\n }\n default: {\n return 'standard'\n }\n }\n }\n\n get #computedType(): HTMLSelectElement['type'] {\n invariant(this.#select)\n\n return this.#select.type\n }\n\n get #computedValue(): string {\n return this.value ?? ''\n }\n\n get #computedSelectedOptions(): HTMLSelectElement['selectedOptions'] {\n invariant(this.#select)\n\n return this.#select.selectedOptions\n }\n\n @Listen('click')\n protected onClick(event: MouseEvent): void {\n if (this.#computedDisabled) event.stopImmediatePropagation()\n }\n\n @Watch('disabled')\n protected disabledChanged(): void {\n if (this.#computedDisabled)\n // eslint-disable-next-line unicorn/no-null\n this.internals.setFormValue(null)\n else this.internals.setFormValue(this.#computedValue)\n }\n\n @Watch('selectedIndex')\n protected selectedIndexChanged(): void {\n invariant(this.#select)\n\n this.#select.selectedIndex = this.selectedIndex\n }\n\n @Watch('tabindex')\n protected tabindexChanged(newValue: string): void {\n const parsedValue = Number.parseInt(newValue, 10)\n this.tabIndex =\n parsedValue === 0 || Number.isNaN(parsedValue) ? undefined : parsedValue\n }\n\n @Watch('required')\n @Watch('value')\n protected validationChanged(): void {\n invariant(this.#select)\n\n this.#select.value = this.#computedValue\n this.#select.required = this.required ?? false\n\n const { valid } = this.#select.validity\n if (valid)\n this.internals.setValidity(NO_ERROR_FLAGS, undefined, this.#select)\n else\n this.internals.setValidity(\n this.#select.validity,\n this.#select.validationMessage,\n this.#select,\n )\n }\n\n @Watch('status')\n protected statusChanged(): void {\n this.internals.ariaInvalid = (this.#computedStatus === 'error').toString()\n }\n\n public componentWillLoad(): void {\n this.#defineGetter('form', () => this.internals.form)\n this.#defineGetter('willValidate', () => this.internals.willValidate)\n this.#defineGetter('validity', () => this.internals.validity)\n this.#defineGetter(\n 'validationMessage',\n () => this.internals.validationMessage,\n )\n\n this.#defineGetter('type', () => this.#computedType)\n this.#defineGetter('options', () => this.#computedOptions)\n this.#defineGetter('length', () => this.#computedOptions.length)\n this.#defineGetter('selectedOptions', () => this.#computedSelectedOptions)\n\n this.#inheritedAttributes = inheritAriaAttributes(this.host)\n this.tabindexChanged(this.host.getAttribute('tabindex') ?? '0')\n this.statusChanged()\n }\n\n public componentDidLoad(): void {\n invariant(this.#select)\n\n this.validationChanged()\n this.selectedIndex = this.#select.selectedIndex\n }\n\n public render() {\n return (\n <div\n class={{\n 'qds-container': true,\n 'qds-multiple': this.multiple ?? false,\n }}\n data-size={this.#computedSize}\n >\n <select\n autoComplete={this.autoComplete}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={this.host.autofocus}\n class=\"qds-select\"\n data-size={this.#computedSize}\n data-status={this.#computedStatus}\n disabled={this.#computedDisabled}\n multiple={this.multiple}\n name={this.name}\n onBlur={this.#onBlur}\n onChange={this.#onChange}\n onFocus={this.#onFocus}\n onInput={this.#onInput}\n ref={this.#ref}\n required={this.required}\n tabIndex={this.#computedDisabled ? undefined : this.tabIndex}\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...this.#inheritedAttributes}\n />\n {this.multiple !== true && (\n <qds-icon\n class=\"qds-icon\"\n data-size={this.#computedSize}\n library=\"core\"\n name=\"dropdown\"\n />\n )}\n <slot onSlotchange={this.#onSlotchange} />\n <div class=\"qds-focus-ring\" />\n </div>\n )\n }\n\n public checkValidity: ElementInternals['checkValidity'] = () =>\n this.internals.checkValidity()\n\n public reportValidity: ElementInternals['reportValidity'] = () =>\n this.internals.reportValidity()\n\n public setCustomValidity: HTMLSelectElement['setCustomValidity'] = (\n error,\n ) => {\n invariant(this.#select)\n\n this.#select.setCustomValidity(error)\n if (error)\n this.internals.setValidity(CUSTOM_ERROR_FLAGS, error, this.#select)\n else this.internals.setValidity(NO_ERROR_FLAGS)\n }\n\n public addItem: HTMLSelectElement['add'] = (element, before) => {\n invariant(this.#select)\n\n this.#select.add(element, before)\n }\n\n public removeItem = (index: number): void => {\n invariant(this.#select)\n\n this.#select.remove(index)\n }\n\n public item: HTMLSelectElement['item'] = (index) => {\n invariant(this.#select)\n\n return this.#select.item(index)\n }\n\n public namedItem: HTMLSelectElement['namedItem'] = (name) => {\n invariant(this.#select)\n\n return this.#select.namedItem(name)\n }\n\n readonly #ref = (select?: HTMLSelectElement): void => {\n this.#select = select\n }\n\n readonly #onBlur = (event: FocusEvent): void => {\n this.blurEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onChange = (): void => {\n this.changeEmitter.emit()\n }\n\n readonly #onFocus = (event: FocusEvent): void => {\n this.focusEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onInput = (event: InputEvent): void => {\n invariant(this.#select)\n\n this.value = this.#select.value\n this.inputEmitter.emit(pickInputEventAttributes(event))\n }\n\n readonly #onSlotchange = (event: Event): void => {\n invariant(this.#select)\n const { currentTarget } = event\n invariant(currentTarget instanceof HTMLSlotElement)\n\n this.#select.replaceChildren(\n ...currentTarget.assignedNodes().map((node) => node.cloneNode(true)),\n )\n }\n\n #defineGetter(p: PropertyKey, get: () => unknown): void {\n Object.defineProperty(this.host, p, { enumerable: true, get })\n }\n}\n"],"version":3}
@@ -4,10 +4,10 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { p as proxyCustomElement, H, c as createEvent, h } from './p-D2489VzR.js';
7
- import { p as pickFocusEventAttributes, i as invariant, d as determineLinkIcon } from './p-CURs27Ur.js';
8
- import { d as defineCustomElement$2 } from './p-DtxwXYGb.js';
7
+ import { p as pickFocusEventAttributes, i as invariant, d as determineLinkIcon } from './p-BalM52S_.js';
8
+ import { d as defineCustomElement$2 } from './p-C9R8N06B.js';
9
9
 
10
- const standaloneLinkCss = ":host([hidden]){display:none!important}:host{display:inline-block}:host(:focus-visible){border-radius:var(--qds-control-border-radius);box-shadow:0 0 0 var(--qds-focus-heavy-border-width) var(--qds-theme-focus-border);outline:var(--qds-theme-focus-border-contrast) solid var(--qds-focus-light-border-width);outline-offset:0}.qds-icon-crop{align-items:center;display:flex;justify-content:center}.qds-icon{flex-shrink:0;transform:scaleX(var(--qds-direction-factor,1))}.qds-standalone-link{box-sizing:border-box;display:inline-flex;justify-content:center;-webkit-print-color-adjust:exact;print-color-adjust:exact;width:100%}.qds-text{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}[data-importance=subdued]{color:var(--qds-theme-link-subdued-default)}.qds-visitable[data-importance=subdued]:visited{color:var(--qds-theme-link-visited-default)}[data-importance=subdued]:hover{color:var(--qds-theme-link-subdued-hover)}[data-importance=subdued]:active{color:var(--qds-theme-link-subdued-pressed)}.qds-visitable[data-importance=subdued]:visited:hover{color:var(--qds-theme-link-visited-hover)}.qds-visitable[data-importance=subdued]:visited:active{color:var(--qds-theme-link-visited-pressed)}[data-importance=standard]{color:var(--qds-theme-link-standard-default)}.qds-visitable[data-importance=standard]:visited{color:var(--qds-theme-link-visited-default)}[data-importance=standard]:hover{color:var(--qds-theme-link-standard-hover)}[data-importance=standard]:active{color:var(--qds-theme-link-standard-pressed)}.qds-visitable[data-importance=standard]:visited:hover{color:var(--qds-theme-link-visited-hover)}.qds-visitable[data-importance=standard]:visited:active{color:var(--qds-theme-link-visited-pressed)}[data-importance=emphasized]{color:var(--qds-theme-link-emphasized-default)}.qds-visitable[data-importance=emphasized]:visited{color:var(--qds-theme-link-visited-default)}[data-importance=emphasized]:hover{color:var(--qds-theme-link-emphasized-hover)}[data-importance=emphasized]:active{color:var(--qds-theme-link-emphasized-pressed)}.qds-visitable[data-importance=emphasized]:visited:hover{color:var(--qds-theme-link-visited-hover)}.qds-visitable[data-importance=emphasized]:visited:active{color:var(--qds-theme-link-visited-pressed)}.qds-disabled{opacity:var(--qds-theme-disabled);pointer-events:none}.qds-standalone-link[data-size=small]{font:var(--qds-control-small-link);gap:var(--qds-control-small-gap-internal);min-height:var(--qds-control-small-height);padding-block:var(--qds-control-small-padding-auto-height)}[data-size=small][data-importance=subdued]{font:var(--qds-control-small-text)}.qds-icon-crop[data-size=small]{height:var(--qds-control-small-icon-crop-height)}.qds-icon[data-size=small]{height:var(--qds-control-small-icon-size);width:var(--qds-control-small-icon-size)}.qds-standalone-link[data-size=standard]{font:var(--qds-control-standard-link);gap:var(--qds-control-standard-gap-internal);min-height:var(--qds-control-standard-height);padding-block:var(--qds-control-standard-padding-auto-height)}[data-size=standard][data-importance=subdued]{font:var(--qds-control-standard-text)}.qds-icon-crop[data-size=standard]{height:var(--qds-control-standard-icon-crop-height)}.qds-icon[data-size=standard]{height:var(--qds-control-standard-icon-size);width:var(--qds-control-standard-icon-size)}.qds-standalone-link[data-size=large]{font:var(--qds-control-large-link);gap:var(--qds-control-large-gap-internal);min-height:var(--qds-control-large-height);padding-block:var(--qds-control-large-padding-auto-height)}[data-size=large][data-importance=subdued]{font:var(--qds-control-large-text)}.qds-icon-crop[data-size=large]{height:var(--qds-control-large-icon-crop-height)}.qds-icon[data-size=large]{height:var(--qds-control-large-icon-size);width:var(--qds-control-large-icon-size)}";
10
+ const standaloneLinkCss = ":host([hidden]){display:none!important}:host{display:inline-block}:host(:focus-visible){border-radius:var(--qds-control-border-radius);box-shadow:0 0 0 var(--qds-focus-heavy-border-width) var(--qds-theme-focus-border);outline:var(--qds-theme-focus-border-contrast) solid var(--qds-focus-light-border-width);outline-offset:0}.qds-icon-crop{align-items:center;display:flex;justify-content:center}.qds-icon{flex-shrink:0;transform:scaleX(var(--qds-direction-factor,1))}.qds-standalone-link{box-sizing:border-box;display:inline-flex;justify-content:center;-webkit-print-color-adjust:exact;print-color-adjust:exact;width:100%}.qds-text{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}[data-importance=emphasized],[data-importance=standard]{-webkit-text-decoration:none;text-decoration:none}.qds-visitable[data-importance=emphasized],.qds-visitable[data-importance=standard],[data-importance=emphasized]:active,[data-importance=emphasized]:hover,[data-importance=standard]:active,[data-importance=standard]:hover{-webkit-text-decoration:underline;text-decoration:underline}[data-importance=subdued]{color:var(--qds-theme-link-subdued-default)}.qds-visitable[data-importance=subdued]:visited{color:var(--qds-theme-link-visited-default)}[data-importance=subdued]:hover{color:var(--qds-theme-link-subdued-hover)}[data-importance=subdued]:active{color:var(--qds-theme-link-subdued-pressed)}.qds-visitable[data-importance=subdued]:visited:hover{color:var(--qds-theme-link-visited-hover)}.qds-visitable[data-importance=subdued]:visited:active{color:var(--qds-theme-link-visited-pressed)}[data-importance=standard]{color:var(--qds-theme-link-standard-default)}.qds-visitable[data-importance=standard]:visited{color:var(--qds-theme-link-visited-default)}[data-importance=standard]:hover{color:var(--qds-theme-link-standard-hover)}[data-importance=standard]:active{color:var(--qds-theme-link-standard-pressed)}.qds-visitable[data-importance=standard]:visited:hover{color:var(--qds-theme-link-visited-hover)}.qds-visitable[data-importance=standard]:visited:active{color:var(--qds-theme-link-visited-pressed)}[data-importance=emphasized]{color:var(--qds-theme-link-emphasized-default)}.qds-visitable[data-importance=emphasized]:visited{color:var(--qds-theme-link-visited-default)}[data-importance=emphasized]:hover{color:var(--qds-theme-link-emphasized-hover)}[data-importance=emphasized]:active{color:var(--qds-theme-link-emphasized-pressed)}.qds-visitable[data-importance=emphasized]:visited:hover{color:var(--qds-theme-link-visited-hover)}.qds-visitable[data-importance=emphasized]:visited:active{color:var(--qds-theme-link-visited-pressed)}.qds-disabled{opacity:var(--qds-theme-disabled);pointer-events:none}.qds-standalone-link[data-size=small]{font:var(--qds-control-small-text);gap:var(--qds-control-small-gap-internal);min-height:var(--qds-control-small-height);padding-block:var(--qds-control-small-padding-auto-height)}.qds-icon-crop[data-size=small]{height:var(--qds-control-small-icon-crop-height)}.qds-icon[data-size=small]{height:var(--qds-control-small-icon-size);width:var(--qds-control-small-icon-size)}.qds-standalone-link[data-size=standard]{font:var(--qds-control-standard-text);gap:var(--qds-control-standard-gap-internal);min-height:var(--qds-control-standard-height);padding-block:var(--qds-control-standard-padding-auto-height)}.qds-icon-crop[data-size=standard]{height:var(--qds-control-standard-icon-crop-height)}.qds-icon[data-size=standard]{height:var(--qds-control-standard-icon-size);width:var(--qds-control-standard-icon-size)}.qds-standalone-link[data-size=large]{font:var(--qds-control-large-text);gap:var(--qds-control-large-gap-internal);min-height:var(--qds-control-large-height);padding-block:var(--qds-control-large-padding-auto-height)}.qds-icon-crop[data-size=large]{height:var(--qds-control-large-icon-crop-height)}.qds-icon[data-size=large]{height:var(--qds-control-large-icon-size);width:var(--qds-control-large-icon-size)}";
11
11
 
12
12
  // SPDX-FileCopyrightText: © 2024 Schneider Electric
13
13
  //
@@ -122,11 +122,11 @@ const StandaloneLink = /*@__PURE__*/ proxyCustomElement(class StandaloneLink ext
122
122
  __classPrivateFieldGet(this, _StandaloneLink_updateAriaLabelElements, "f").call(this);
123
123
  }
124
124
  render() {
125
- return (h("a", { key: '91c07ea8152387f46020e1431858cd35bd126ced', "aria-hidden": "true", class: {
125
+ return (h("a", { key: '0e70d2f7b1d663435904b2f1fcc718b39946020d', "aria-hidden": "true", class: {
126
126
  'qds-standalone-link': true,
127
127
  'qds-disabled': this.disabled,
128
128
  'qds-visitable': this.visitable,
129
- }, "data-importance": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedImportance_get), "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), download: this.download, href: this.href?.toString(), hrefLang: this.hreflang, onBlur: __classPrivateFieldGet(this, _StandaloneLink_onBlur, "f"), onFocus: __classPrivateFieldGet(this, _StandaloneLink_onFocus, "f"), referrerPolicy: this.referrerPolicy, rel: this.rel, tabIndex: -1, target: this.target, ref: __classPrivateFieldGet(this, _StandaloneLink_linkRef, "f") }, this.iconName !== undefined && this.iconName !== '' && (h("span", { key: '11ef79b0704c1be48b7c96bf67d5395324a4da78', class: "qds-icon-crop", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get) }, h("qds-icon", { key: 'b13b23fb3cade4a2419435e1ee9199929e38caa7', "aria-hidden": "true", class: "qds-icon", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), library: this.iconLibrary, name: this.iconName }))), h("span", { key: '14dc1bd1fb86f9e910df3a752b5b21e9d6a32614', class: "qds-text" }, h("slot", { key: '3bec7502fd6a1d8ac80bce195e0aae082fbd6071', onSlotchange: __classPrivateFieldGet(this, _StandaloneLink_onSlotchange, "f") })), this.linkIcon && (h("span", { key: '2baed1edfde4437a36acd524ddcc80eff6ed3d6a', class: "qds-icon-crop", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get) }, h("qds-icon", { key: 'd4998672b43c3a94762823d0d0f7439df632b344', "aria-hidden": "true", class: "qds-icon", library: "core", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), name: this.linkIcon }))), this.importance === 'emphasized' && (h("span", { key: '20e1eccfa5db5faf5f704d9297502d908f5dd105', class: "qds-icon-crop", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get) }, h("qds-icon", { key: '82461b636037dd9bf41246a4d666ea9f6c17765a', class: "qds-icon", "aria-hidden": "true", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), library: "core", name: "next" })))));
129
+ }, "data-importance": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedImportance_get), "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), download: this.download, href: this.href?.toString(), hrefLang: this.hreflang, onBlur: __classPrivateFieldGet(this, _StandaloneLink_onBlur, "f"), onFocus: __classPrivateFieldGet(this, _StandaloneLink_onFocus, "f"), referrerPolicy: this.referrerPolicy, rel: this.rel, tabIndex: -1, target: this.target, ref: __classPrivateFieldGet(this, _StandaloneLink_linkRef, "f") }, this.iconName !== undefined && this.iconName !== '' && (h("span", { key: '952fb52d3129a1bd7e1bb901af8673439f434a1b', class: "qds-icon-crop", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get) }, h("qds-icon", { key: '9fc0f2d475b165e890546f6faad7d9e90ca31df9', class: "qds-icon", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), library: this.iconLibrary, name: this.iconName }))), h("span", { key: '0213f2cf7a42d5ca9ba4b8083a26966c49bd6eb3', class: "qds-text" }, h("slot", { key: 'f54a7b1f67e7114fa2eac1bd787c7b604c937630', onSlotchange: __classPrivateFieldGet(this, _StandaloneLink_onSlotchange, "f") })), this.linkIcon && (h("span", { key: 'eca6d9db29c904ff24ef63672f448ea9bf69e803', class: "qds-icon-crop", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get) }, h("qds-icon", { key: 'e2610d31880ed6fe83d59c06c437014a54284b26', class: "qds-icon", library: "core", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), name: this.linkIcon }))), this.importance === 'emphasized' && (h("span", { key: 'a242b2eabb9f7d1c2db2e2e531151e91c32d651e', class: "qds-icon-crop", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get) }, h("qds-icon", { key: '88dc23ac40898d3adfe236dad9fe44136db5efb3', class: "qds-icon", "data-size": __classPrivateFieldGet(this, _StandaloneLink_instances, "a", _StandaloneLink_computedSize_get), library: "core", name: "next" })))));
130
130
  }
131
131
  get host() { return this; }
132
132
  static get watchers() { return {
@@ -1 +1 @@
1
- {"file":"qds-standalone-link.js","mappings":";;;;;;;;;AAAA,MAAM,iBAAiB,GAAG,gwHAAgwH;;ACA1xH;AACA;AACA;;;;;;;;;;;;;;;;;;MAyCa,cAAc,iBAAAA,kBAAA,CAAA,MAAA,cAAA,SAAAC,CAAA,CAAA;AAL3B,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;;;;AAME;;;AAGG;AACqB,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AASjD;;AAEG;AACqB,QAAA,IAAW,CAAA,WAAA,GAAW,SAAS;AAEvD;;AAEG;AACqB,QAAA,IAAU,CAAA,UAAA,GAAgB,UAAU;AAE5D;;AAEG;AACqB,QAAA,IAAI,CAAA,IAAA,GAAU,UAAU;AAEhD;;AAEG;AACqB,QAAA,IAAS,CAAA,SAAA,GAAY,KAAK;AAoMlD,QAAA,6BAAA,CAAA,GAAA,CAAA,IAAA,EAAiB,CAAC,CAAA;QAElB,oBAAyB,CAAA,GAAA,CAAA,IAAA,EAAA,MAAA,CAAA;AA6IhB,QAAA,uCAAA,CAAA,GAAA,CAAA,IAAA,EAA2B,MAAW;AAC7C,YAAA,IAAI,CAAC,SAAS,CAAC,SAAS,GAAG,CAAG,EAAA,IAAI,CAAC,IAAI,CAAC,W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;;;;;;;;;;;;;;AAtIN,IAAA,QAAQ,IAAI,CAAC,UAAU;AACrB,QAAA,KAAK,SAAS;QACd,KAAK,YAAY,EAAE;YACjB,OAAO,IAAI,CAAC,UAAU;;QAExB,SAAS;AACP,YAAA,OAAO,UAAU;;;AAGvB,CAAC,EAAA,gCAAA,GAAA,SAAA,gCAAA,GAAA;AAGC,IAAA,QAAQ,IAAI,CAAC,IAAI;AACf,QAAA,KAAK,UAAU;AACf,QAAA,KAAK,OAAO;QACZ,KAAK,OAAO,EAAE;YACZ,OAAO,IAAI,CAAC,IAAI;;QAElB,SAAS;AACP,YAAA,OAAO,UAAU;;;AAGvB,CAAC,EAAA,gCAAA,GAAA,SAAA,gCAAA,GAAA;AAGC,IAAA,OAAO,IAAI,CAAC,MAAM,KAAK,QAAQ;AACjC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/standalone-link/standalone-link.css?tag=qds-standalone-link&encapsulation=shadow","src/components/standalone-link/standalone-link.tsx"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: © 2024 Schneider Electric\n *\n * SPDX-License-Identifier: Apache-2.0\n */\n\n@import url('../shared.css');\n\n:host {\n display: inline-block;\n}\n\n:host(:focus-visible) {\n /* inner ring */\n outline: var(--qds-theme-focus-border-contrast) solid\n var(--qds-focus-light-border-width);\n outline-offset: 0;\n\n /* outer ring */\n box-shadow: 0 0 0 var(--qds-focus-heavy-border-width)\n var(--qds-theme-focus-border);\n border-radius: var(--qds-control-border-radius);\n}\n\n.qds-icon-crop {\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.qds-icon {\n flex-shrink: 0;\n transform: scaleX(var(--qds-direction-factor, 1));\n}\n\n.qds-standalone-link {\n box-sizing: border-box;\n display: inline-flex;\n justify-content: center;\n print-color-adjust: exact;\n width: 100%;\n}\n\n.qds-text {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n overflow: hidden;\n}\n\n[data-importance='subdued'] {\n color: var(--qds-theme-link-subdued-default);\n\n &:visited.qds-visitable {\n color: var(--qds-theme-link-visited-default);\n }\n\n &:hover {\n color: var(--qds-theme-link-subdued-hover);\n }\n\n &:active {\n color: var(--qds-theme-link-subdued-pressed);\n }\n\n &:visited:hover.qds-visitable {\n color: var(--qds-theme-link-visited-hover);\n }\n\n &:visited:active.qds-visitable {\n color: var(--qds-theme-link-visited-pressed);\n }\n}\n\n[data-importance='standard'] {\n color: var(--qds-theme-link-standard-default);\n\n &:visited.qds-visitable {\n color: var(--qds-theme-link-visited-default);\n }\n\n &:hover {\n color: var(--qds-theme-link-standard-hover);\n }\n\n &:active {\n color: var(--qds-theme-link-standard-pressed);\n }\n\n &:visited:hover.qds-visitable {\n color: var(--qds-theme-link-visited-hover);\n }\n\n &:visited:active.qds-visitable {\n color: var(--qds-theme-link-visited-pressed);\n }\n}\n\n[data-importance='emphasized'] {\n color: var(--qds-theme-link-emphasized-default);\n\n &:visited.qds-visitable {\n color: var(--qds-theme-link-visited-default);\n }\n\n &:hover {\n color: var(--qds-theme-link-emphasized-hover);\n }\n\n &:active {\n color: var(--qds-theme-link-emphasized-pressed);\n }\n\n &:visited:hover.qds-visitable {\n color: var(--qds-theme-link-visited-hover);\n }\n\n &:visited:active.qds-visitable {\n color: var(--qds-theme-link-visited-pressed);\n }\n}\n\n.qds-disabled {\n opacity: var(--qds-theme-disabled);\n pointer-events: none;\n}\n\n[data-size='small'] {\n &.qds-standalone-link {\n font: var(--qds-control-small-link);\n gap: var(--qds-control-small-gap-internal);\n padding-block: var(--qds-control-small-padding-auto-height);\n min-height: var(--qds-control-small-height);\n }\n\n &[data-importance='subdued'] {\n font: var(--qds-control-small-text);\n }\n\n &.qds-icon-crop {\n height: var(--qds-control-small-icon-crop-height);\n }\n\n &.qds-icon {\n height: var(--qds-control-small-icon-size);\n width: var(--qds-control-small-icon-size);\n }\n}\n\n[data-size='standard'] {\n &.qds-standalone-link {\n font: var(--qds-control-standard-link);\n gap: var(--qds-control-standard-gap-internal);\n padding-block: var(--qds-control-standard-padding-auto-height);\n min-height: var(--qds-control-standard-height);\n }\n\n &[data-importance='subdued'] {\n font: var(--qds-control-standard-text);\n }\n\n &.qds-icon-crop {\n height: var(--qds-control-standard-icon-crop-height);\n }\n\n &.qds-icon {\n height: var(--qds-control-standard-icon-size);\n width: var(--qds-control-standard-icon-size);\n }\n}\n\n[data-size='large'] {\n &.qds-standalone-link {\n font: var(--qds-control-large-link);\n gap: var(--qds-control-large-gap-internal);\n padding-block: var(--qds-control-large-padding-auto-height);\n min-height: var(--qds-control-large-height);\n }\n\n &[data-importance='subdued'] {\n font: var(--qds-control-large-text);\n }\n\n &.qds-icon-crop {\n height: var(--qds-control-large-icon-crop-height);\n }\n\n &.qds-icon {\n height: var(--qds-control-large-icon-size);\n width: var(--qds-control-large-icon-size);\n }\n}\n","// SPDX-FileCopyrightText: © 2024 Schneider Electric\n//\n// SPDX-License-Identifier: Apache-2.0\n\nimport type { ComponentInterface, EventEmitter } from '@stencil/core'\nimport {\n AttachInternals,\n Component,\n Element,\n Event,\n h,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core'\nimport type { LiteralUnion } from 'type-fest'\n\nimport type { QdsFocusEventDetail } from '../../helpers'\nimport {\n determineLinkIcon,\n invariant,\n pickFocusEventAttributes,\n} from '../../helpers'\nimport type { Importance, LinkIcon, Size, Target } from '../shared'\n\n/**\n * `<qds-standalone-link>` elements, with their `href` property, create a hyperlink\n * to web pages, files, email addresses, locations in the same page, or\n * anything else a URL can address.\n *\n * Content within each `<qds-standalone-link>` *should* indicate the standalone link's\n * destination. If the `href` property is present, pressing the enter key while\n * focused on the `<qds-standalone-link>` element will activate it.\n *\n * @slot Content to display for the standalone link.\n * @see https://quartz.se.com/build/components/standalone-link\n */\n@Component({\n tag: 'qds-standalone-link',\n shadow: true,\n styleUrl: 'standalone-link.css',\n})\nexport class StandaloneLink implements ComponentInterface {\n /**\n * Prevents the standalone link from being interacted with: it cannot be pressed\n * or focused.\n */\n @Prop() public readonly disabled: boolean = false\n\n /**\n * The name of the icon to render.\n *\n * Available names depend on the icon library being used.\n */\n @Prop() public readonly iconName?: string\n\n /**\n * The name of a registered icon library.\n */\n @Prop() public readonly iconLibrary: string = 'default'\n\n /**\n * The standalone link's importance.\n */\n @Prop() public readonly importance?: Importance = 'standard'\n\n /**\n * The standalone link's size.\n */\n @Prop() public readonly size?: Size = 'standard'\n\n /**\n * Defines if the standalone link will display the visited state.\n */\n @Prop() public readonly visitable: boolean = false\n\n /**\n * Causes the browser to treat the linked URL as a download. Can be used with\n * or without a `filename` value:\n *\n * - Without a value, the browser will suggest a filename/extension,\n * generated from various sources:\n *\n * - The\n * [`Content-Disposition`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Content-Disposition)\n * HTTP header\n * - The final segment in the URL\n * [path](https://developer.mozilla.org/docs/Web/API/URL/pathname)\n * - The\n * [media type](https://developer.mozilla.org/docs/Glossary/MIME_type)\n * (from the\n * [`Content-Type`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Content-Type)\n * header, the start of a\n * [`data:` URL](https://developer.mozilla.org/docs/Web/HTTP/Basics_of_HTTP/Data_URLs),\n * or\n * [`Blob.type`](https://developer.mozilla.org/docs/Web/API/Blob/type)\n * for a\n * [`blob:` URL](https://developer.mozilla.org/docs/Web/API/URL/createObjectURL))\n * - `filename`: defining a value suggests it as the filename. `/` and `\\`\n * characters are converted to underscores (`_`). Filesystems may forbid\n * other characters in filenames, so browsers will adjust the suggested name\n * if necessary.\n *\n * @webnative\n */\n @Prop() public readonly download?: boolean | string\n\n /**\n * The URL that the standalone link points to. Standalone links are not restricted to\n * HTTP-based URLs — they can use any URL scheme supported by browsers:\n *\n * - Sections of a page with document fragments\n * - Specific text portions with\n * [text fragments](https://developer.mozilla.org/docs/Web/Text_fragments)\n * - Pieces of media files with media fragments\n * - Telephone numbers with `tel:` URLs\n * - Email addresses with `mailto:` URLs\n * - While web browsers may not support other URL schemes, websites can with\n * [`registerProtocolHandler()`](https://developer.mozilla.org/docs/Web/API/Navigator/registerProtocolHandler)\n *\n * @webnative\n */\n @Prop() public readonly href?: URL | string\n\n /**\n * Hints at the human language of the linked URL. No built-in functionality.\n * Allowed values are the same as\n * [the global `lang` attribute](https://developer.mozilla.org/docs/Web/HTML/Global_attributes/lang).\n *\n * @webnative\n */\n @Prop() public readonly hreflang?: string\n\n /**\n * How much of the\n * [referrer](https://developer.mozilla.org/docs/Web/HTTP/Headers/Referer)\n * to send when following the standalone link.\n *\n * - `no-referrer`: The\n * [`Referer`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Referer)\n * header will not be sent.\n * - `no-referrer-when-downgrade`: The\n * [`Referer`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Referer)\n * header will not be sent to\n * [origin](https://developer.mozilla.org/docs/Glossary/Origin)s\n * without [TLS](https://developer.mozilla.org/docs/Glossary/TLS)\n * ([HTTPS](https://developer.mozilla.org/docs/Glossary/HTTPS)).\n * - `origin`: The sent referrer will be limited to the origin of the\n * referring page: its\n * [scheme](https://developer.mozilla.org/docs/Learn/Common_questions/What_is_a_URL),\n * [host](https://developer.mozilla.org/docs/Glossary/Host), and\n * [port](https://developer.mozilla.org/docs/Glossary/Port).\n * - `origin-when-cross-origin`: The referrer sent to other origins will be\n * limited to the scheme, the host, and the port. Navigations on the same\n * origin will still include the path.\n * - `same-origin`: A referrer will be sent for\n * [same origin](https://developer.mozilla.org/docs/Glossary/Same-origin_policy),\n * but cross-origin requests will contain no referrer information.\n * - `strict-origin`: Only send the origin of the document as the referrer\n * when the protocol security level stays the same (HTTPS→HTTPS), but don't\n * send it to a less secure destination (HTTPS→HTTP).\n * - `strict-origin-when-cross-origin` (default): Send a full URL when\n * performing a same-origin request, only send the origin when the protocol\n * security level stays the same (HTTPS→HTTPS), and send no header to a less\n * secure destination (HTTPS→HTTP).\n * - `unsafe-url`: The referrer will include the origin and the path (but not the\n * [fragment](https://developer.mozilla.org/docs/Web/API/HTMLAnchorElement/hash),\n * [password](https://developer.mozilla.org/docs/Web/API/HTMLAnchorElement/password),\n * or [username](https://developer.mozilla.org/docs/Web/API/HTMLAnchorElement/username)).\n * **This value is unsafe** because it leaks origins and paths from\n * TLS-protected resources to insecure origins.\n *\n * @webnative\n */\n @Prop({ attribute: 'referrerpolicy' })\n public readonly referrerPolicy?: ReferrerPolicy\n\n /**\n * The relationship of the linked URL as space-separated\n * [link types](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel).\n *\n * The following list includes some of the most important existing keywords.\n * Every keyword within a space-separated value should be unique within that\n * value.\n *\n * - [`alternate`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-alternate):\n * Alternate representations of the current document.\n * - [`author`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-author):\n * Author of the current document or article.\n * - [`bookmark`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-bookmark):\n * Permalink for the nearest ancestor section.\n * - [`external`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-external):\n * The referenced document is not part of the same site as the current\n * document. An icon will be rendered next to the text if this value is\n * specified.\n * - [`help`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-help):\n * Link to context-sensitive help.\n * - [`license`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-license):\n * Indicates that the main content of the current document is covered by the\n * copyright license described by the referenced document.\n * - [`me`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel/me):\n * Indicates that the current document represents the person who owns the\n * linked content.\n * - [`next`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-next):\n * Indicates that the current document is a part of a series and that the\n * next document in the series is the referenced document.\n * - [`nofollow`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-nofollow):\n * Indicates that the current document's original author or publisher does\n * not endorse the referenced document.\n * - [`noopener`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel/noopener):\n * Creates a top-level browsing context that is not an auxiliary browsing\n * context if the hyperlink would create either of those, to begin with (i.e.,\n * has an appropriate `target` attribute value).\n * - [`noreferrer`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-noreferrer):\n * No `Referer` header will be included. Additionally, has the same effect as\n * `noopener`.\n * - [`opener`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-opener):\n * Creates an auxiliary browsing context if the hyperlink would otherwise\n * create a top-level browsing context that is not an auxiliary browsing\n * context (i.e., has \"`_blank`\" as `target` attribute value).\n * - [`prev`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-prev):\n * Indicates that the current document is a part of a series and that the\n * previous document in the series is the referenced document.\n * - [`search`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-search):\n * Gives a link to a resource that can be used to search through the current\n * document and its related pages.\n * - [`tag`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-tag):\n * Gives a tag (identified by the given address) that applies to the current\n * document.\n *\n * @webnative\n */\n @Prop() public readonly rel?: string\n\n /**\n * Where to display the linked URL, as the name for a browsing context (a\n * tab, window, or\n * [`<iframe>`](https://developer.mozilla.org/docs/Web/HTML/Element/iframe).\n * The following keywords have special meanings for where to load the URL:\n *\n * - `_blank`: usually a new tab, but users can configure browsers to open a new\n * window instead.\n * - `_parent`: the parent browsing context of the current one. If no parent,\n * behaves as `_self`.\n * - `_self`: the current browsing context.\n * - `_top`: the topmost browsing context (the \"highest\" context that's an\n * ancestor of the current one). If no ancestors, behaves as `_self`.\n *\n * @webnative\n */\n @Prop() public readonly target?: LiteralUnion<Target, string>\n\n /**\n * Emitted when the standalone link loses focus.\n */\n @Event({ eventName: 'qdsBlur', bubbles: false, cancelable: false })\n private readonly blurEmitter!: EventEmitter<QdsFocusEventDetail>\n\n /**\n * Emitted when the standalone link gains focus.\n */\n @Event({ eventName: 'qdsFocus', bubbles: false, cancelable: false })\n private readonly focusEmitter!: EventEmitter<QdsFocusEventDetail>\n\n @Element() private readonly host!: HTMLElement\n\n @State() private linkIcon?: LinkIcon\n\n @AttachInternals() private readonly internals!: ElementInternals\n\n #savedTabIndex = 0\n\n #link?: HTMLAnchorElement\n\n get #computedImportance(): Importance {\n switch (this.importance) {\n case 'subdued':\n case 'emphasized': {\n return this.importance\n }\n default: {\n return 'standard'\n }\n }\n }\n\n get #computedSize(): Size | undefined {\n switch (this.size) {\n case 'standard':\n case 'small':\n case 'large': {\n return this.size\n }\n default: {\n return 'standard'\n }\n }\n }\n\n get #openInNewTab(): boolean {\n return this.target === '_blank'\n }\n\n @Listen('click')\n protected onClick(event: MouseEvent): void {\n if (this.disabled) event.stopImmediatePropagation()\n }\n\n @Listen('keydown')\n protected onKeydown(event: KeyboardEvent): void {\n invariant(this.#link)\n if (this.disabled) return\n if (event.key === 'Enter') this.#link.click()\n }\n\n @Watch('disabled')\n protected disabledChanged(): void {\n this.internals.ariaDisabled = this.disabled.toString()\n if (this.disabled) this.host.removeAttribute('tabindex')\n else this.host.tabIndex = this.#savedTabIndex\n }\n\n @Watch('tabindex')\n protected tabindexChanged(newValue: string): void {\n const parsedValue = Number.parseInt(newValue, 10)\n // FIXME: `undefined` instead of `0` causes `qdsFocus/qdsBlur` E2E tests\n // to fail, but it's not clear why this is the case since it works for\n // other components.\n this.#savedTabIndex = Number.isNaN(parsedValue) ? 0 : parsedValue\n if (this.disabled) this.host.removeAttribute('tabindex')\n else this.host.tabIndex = this.#savedTabIndex\n }\n\n @Watch('rel')\n @Watch('target')\n protected hrefTargetChanged(): void {\n this.linkIcon = determineLinkIcon(this.target, this.rel)\n this.#updateAriaLabelElements()\n }\n\n public componentWillLoad(): void {\n this.internals.role = 'link'\n this.disabledChanged()\n this.hrefTargetChanged()\n this.tabindexChanged(this.host.getAttribute('tabindex') ?? '0')\n }\n\n public componentDidLoad(): void {\n this.#updateAriaLabelElements()\n }\n\n public render() {\n return (\n <a\n aria-hidden=\"true\"\n class={{\n 'qds-standalone-link': true,\n 'qds-disabled': this.disabled,\n 'qds-visitable': this.visitable,\n }}\n data-importance={this.#computedImportance}\n data-size={this.#computedSize}\n download={this.download}\n href={this.href?.toString()}\n hrefLang={this.hreflang}\n onBlur={this.#onBlur}\n onFocus={this.#onFocus}\n referrerPolicy={this.referrerPolicy}\n rel={this.rel}\n tabIndex={-1}\n target={this.target}\n ref={this.#linkRef}\n >\n {this.iconName !== undefined && this.iconName !== '' && (\n <span class=\"qds-icon-crop\" data-size={this.#computedSize}>\n <qds-icon\n aria-hidden=\"true\"\n class=\"qds-icon\"\n data-size={this.#computedSize}\n library={this.iconLibrary}\n name={this.iconName}\n />\n </span>\n )}\n <span class=\"qds-text\">\n <slot onSlotchange={this.#onSlotchange} />\n </span>\n {this.linkIcon && (\n <span class=\"qds-icon-crop\" data-size={this.#computedSize}>\n <qds-icon\n aria-hidden=\"true\"\n class=\"qds-icon\"\n library=\"core\"\n data-size={this.#computedSize}\n name={this.linkIcon}\n />\n </span>\n )}\n {this.importance === 'emphasized' && (\n <span class=\"qds-icon-crop\" data-size={this.#computedSize}>\n <qds-icon\n class=\"qds-icon\"\n aria-hidden=\"true\"\n data-size={this.#computedSize}\n library=\"core\"\n name=\"next\"\n />\n </span>\n )}\n </a>\n )\n }\n\n readonly #updateAriaLabelElements = (): void => {\n this.internals.ariaLabel = `${this.host.textContent} ${\n this.#openInNewTab ? 'Opens in a new tab' : ''\n }`.trim()\n }\n\n readonly #linkRef = (link?: HTMLAnchorElement): void => {\n this.#link = link\n }\n\n readonly #onBlur = (event: FocusEvent): void => {\n this.blurEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onFocus = (event: FocusEvent): void => {\n this.focusEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onSlotchange = (): void => {\n this.#updateAriaLabelElements()\n }\n}\n"],"version":3}
1
+ {"file":"qds-standalone-link.js","mappings":";;;;;;;;;AAAA,MAAM,iBAAiB,GAAG,o5HAAo5H;;ACA96H;AACA;AACA;;;;;;;;;;;;;;;;;;MAyCa,cAAc,iBAAAA,kBAA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BAAA,CAAA,IAAI,EAAc,yBAAA,EAAA,GAAA,EAAA,gCAAA,CAAA,EAC7B,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAA,CACnB,CACG,CACR,EACA,IAAI,CAAC,UAAU,KAAK,YAAY,KAC/B,CAAM,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAC,eAAe,EAAY,WAAA,EAAA,sBAAA,CAAA,IAAI,EAAc,yBAAA,EAAA,GAAA,EAAA,gCAAA,CAAA,EAAA,EACvD,CACE,CAAA,UAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAC,UAAU,EAAA,WAAA,EACL,uBAAA,IAAI,EAAA,yBAAA,EAAA,GAAA,EAAA,gCAAA,CAAc,EAC7B,OAAO,EAAC,MAAM,EACd,IAAI,EAAC,MAAM,EAAA,CACX,CACG,CACR,CACC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAnIN,IAAA,QAAQ,IAAI,CAAC,UAAU;AACrB,QAAA,KAAK,SAAS;QACd,KAAK,YAAY,EAAE;YACjB,OAAO,IAAI,CAAC,UAAU;;QAExB,SAAS;AACP,YAAA,OAAO,UAAU;;;AAGvB,CAAC,EAAA,gCAAA,GAAA,SAAA,gCAAA,GAAA;AAGC,IAAA,QAAQ,IAAI,CAAC,IAAI;AACf,QAAA,KAAK,UAAU;AACf,QAAA,KAAK,OAAO;QACZ,KAAK,OAAO,EAAE;YACZ,OAAO,IAAI,CAAC,IAAI;;QAElB,SAAS;AACP,YAAA,OAAO,UAAU;;;AAGvB,CAAC,EAAA,gCAAA,GAAA,SAAA,gCAAA,GAAA;AAGC,IAAA,OAAO,IAAI,CAAC,MAAM,KAAK,QAAQ;AACjC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/standalone-link/standalone-link.css?tag=qds-standalone-link&encapsulation=shadow","src/components/standalone-link/standalone-link.tsx"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: © 2024 Schneider Electric\n *\n * SPDX-License-Identifier: Apache-2.0\n */\n\n@import url('../shared.css');\n\n:host {\n display: inline-block;\n}\n\n:host(:focus-visible) {\n /* inner ring */\n outline: var(--qds-theme-focus-border-contrast) solid\n var(--qds-focus-light-border-width);\n outline-offset: 0;\n\n /* outer ring */\n box-shadow: 0 0 0 var(--qds-focus-heavy-border-width)\n var(--qds-theme-focus-border);\n border-radius: var(--qds-control-border-radius);\n}\n\n.qds-icon-crop {\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.qds-icon {\n flex-shrink: 0;\n transform: scaleX(var(--qds-direction-factor, 1));\n}\n\n.qds-standalone-link {\n box-sizing: border-box;\n display: inline-flex;\n justify-content: center;\n print-color-adjust: exact;\n width: 100%;\n}\n\n.qds-text {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n overflow: hidden;\n}\n\n[data-importance='emphasized'],\n[data-importance='standard'] {\n text-decoration: none;\n\n &:hover,\n &:active,\n &.qds-visitable {\n text-decoration: underline;\n }\n}\n\n[data-importance='subdued'] {\n color: var(--qds-theme-link-subdued-default);\n\n &:visited.qds-visitable {\n color: var(--qds-theme-link-visited-default);\n }\n\n &:hover {\n color: var(--qds-theme-link-subdued-hover);\n }\n\n &:active {\n color: var(--qds-theme-link-subdued-pressed);\n }\n\n &:visited:hover.qds-visitable {\n color: var(--qds-theme-link-visited-hover);\n }\n\n &:visited:active.qds-visitable {\n color: var(--qds-theme-link-visited-pressed);\n }\n}\n\n[data-importance='standard'] {\n color: var(--qds-theme-link-standard-default);\n\n &:visited.qds-visitable {\n color: var(--qds-theme-link-visited-default);\n }\n\n &:hover {\n color: var(--qds-theme-link-standard-hover);\n }\n\n &:active {\n color: var(--qds-theme-link-standard-pressed);\n }\n\n &:visited:hover.qds-visitable {\n color: var(--qds-theme-link-visited-hover);\n }\n\n &:visited:active.qds-visitable {\n color: var(--qds-theme-link-visited-pressed);\n }\n}\n\n[data-importance='emphasized'] {\n color: var(--qds-theme-link-emphasized-default);\n\n &:visited.qds-visitable {\n color: var(--qds-theme-link-visited-default);\n }\n\n &:hover {\n color: var(--qds-theme-link-emphasized-hover);\n }\n\n &:active {\n color: var(--qds-theme-link-emphasized-pressed);\n }\n\n &:visited:hover.qds-visitable {\n color: var(--qds-theme-link-visited-hover);\n }\n\n &:visited:active.qds-visitable {\n color: var(--qds-theme-link-visited-pressed);\n }\n}\n\n.qds-disabled {\n opacity: var(--qds-theme-disabled);\n pointer-events: none;\n}\n\n[data-size='small'] {\n &.qds-standalone-link {\n font: var(--qds-control-small-text);\n gap: var(--qds-control-small-gap-internal);\n padding-block: var(--qds-control-small-padding-auto-height);\n min-height: var(--qds-control-small-height);\n }\n\n &.qds-icon-crop {\n height: var(--qds-control-small-icon-crop-height);\n }\n\n &.qds-icon {\n height: var(--qds-control-small-icon-size);\n width: var(--qds-control-small-icon-size);\n }\n}\n\n[data-size='standard'] {\n &.qds-standalone-link {\n font: var(--qds-control-standard-text);\n gap: var(--qds-control-standard-gap-internal);\n padding-block: var(--qds-control-standard-padding-auto-height);\n min-height: var(--qds-control-standard-height);\n }\n\n &.qds-icon-crop {\n height: var(--qds-control-standard-icon-crop-height);\n }\n\n &.qds-icon {\n height: var(--qds-control-standard-icon-size);\n width: var(--qds-control-standard-icon-size);\n }\n}\n\n[data-size='large'] {\n &.qds-standalone-link {\n font: var(--qds-control-large-text);\n gap: var(--qds-control-large-gap-internal);\n padding-block: var(--qds-control-large-padding-auto-height);\n min-height: var(--qds-control-large-height);\n }\n\n &.qds-icon-crop {\n height: var(--qds-control-large-icon-crop-height);\n }\n\n &.qds-icon {\n height: var(--qds-control-large-icon-size);\n width: var(--qds-control-large-icon-size);\n }\n}\n","// SPDX-FileCopyrightText: © 2024 Schneider Electric\n//\n// SPDX-License-Identifier: Apache-2.0\n\nimport type { ComponentInterface, EventEmitter } from '@stencil/core'\nimport {\n AttachInternals,\n Component,\n Element,\n Event,\n h,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core'\nimport type { LiteralUnion } from 'type-fest'\n\nimport type { QdsFocusEventDetail } from '../../helpers'\nimport {\n determineLinkIcon,\n invariant,\n pickFocusEventAttributes,\n} from '../../helpers'\nimport type { Importance, LinkIcon, Size, Target } from '../shared'\n\n/**\n * `<qds-standalone-link>` elements, with their `href` property, create a hyperlink\n * to web pages, files, email addresses, locations in the same page, or\n * anything else a URL can address.\n *\n * Content within each `<qds-standalone-link>` *should* indicate the standalone link's\n * destination. If the `href` property is present, pressing the enter key while\n * focused on the `<qds-standalone-link>` element will activate it.\n *\n * @slot Content to display for the standalone link.\n * @see https://quartz.se.com/build/components/standalone-link\n */\n@Component({\n tag: 'qds-standalone-link',\n shadow: true,\n styleUrl: 'standalone-link.css',\n})\nexport class StandaloneLink implements ComponentInterface {\n /**\n * Prevents the standalone link from being interacted with: it cannot be pressed\n * or focused.\n */\n @Prop() public readonly disabled: boolean = false\n\n /**\n * The name of the icon to render.\n *\n * Available names depend on the icon library being used.\n */\n @Prop() public readonly iconName?: string\n\n /**\n * The name of a registered icon library.\n */\n @Prop() public readonly iconLibrary: string = 'default'\n\n /**\n * The standalone link's importance.\n */\n @Prop() public readonly importance?: Importance = 'standard'\n\n /**\n * The standalone link's size.\n */\n @Prop() public readonly size?: Size = 'standard'\n\n /**\n * Defines if the standalone link will display the visited state.\n */\n @Prop() public readonly visitable: boolean = false\n\n /**\n * Causes the browser to treat the linked URL as a download. Can be used with\n * or without a `filename` value:\n *\n * - Without a value, the browser will suggest a filename/extension,\n * generated from various sources:\n *\n * - The\n * [`Content-Disposition`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Content-Disposition)\n * HTTP header\n * - The final segment in the URL\n * [path](https://developer.mozilla.org/docs/Web/API/URL/pathname)\n * - The\n * [media type](https://developer.mozilla.org/docs/Glossary/MIME_type)\n * (from the\n * [`Content-Type`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Content-Type)\n * header, the start of a\n * [`data:` URL](https://developer.mozilla.org/docs/Web/HTTP/Basics_of_HTTP/Data_URLs),\n * or\n * [`Blob.type`](https://developer.mozilla.org/docs/Web/API/Blob/type)\n * for a\n * [`blob:` URL](https://developer.mozilla.org/docs/Web/API/URL/createObjectURL))\n * - `filename`: defining a value suggests it as the filename. `/` and `\\`\n * characters are converted to underscores (`_`). Filesystems may forbid\n * other characters in filenames, so browsers will adjust the suggested name\n * if necessary.\n *\n * @webnative\n */\n @Prop() public readonly download?: boolean | string\n\n /**\n * The URL that the standalone link points to. Standalone links are not restricted to\n * HTTP-based URLs — they can use any URL scheme supported by browsers:\n *\n * - Sections of a page with document fragments\n * - Specific text portions with\n * [text fragments](https://developer.mozilla.org/docs/Web/Text_fragments)\n * - Pieces of media files with media fragments\n * - Telephone numbers with `tel:` URLs\n * - Email addresses with `mailto:` URLs\n * - While web browsers may not support other URL schemes, websites can with\n * [`registerProtocolHandler()`](https://developer.mozilla.org/docs/Web/API/Navigator/registerProtocolHandler)\n *\n * @webnative\n */\n @Prop() public readonly href?: URL | string\n\n /**\n * Hints at the human language of the linked URL. No built-in functionality.\n * Allowed values are the same as\n * [the global `lang` attribute](https://developer.mozilla.org/docs/Web/HTML/Global_attributes/lang).\n *\n * @webnative\n */\n @Prop() public readonly hreflang?: string\n\n /**\n * How much of the\n * [referrer](https://developer.mozilla.org/docs/Web/HTTP/Headers/Referer)\n * to send when following the standalone link.\n *\n * - `no-referrer`: The\n * [`Referer`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Referer)\n * header will not be sent.\n * - `no-referrer-when-downgrade`: The\n * [`Referer`](https://developer.mozilla.org/docs/Web/HTTP/Headers/Referer)\n * header will not be sent to\n * [origin](https://developer.mozilla.org/docs/Glossary/Origin)s\n * without [TLS](https://developer.mozilla.org/docs/Glossary/TLS)\n * ([HTTPS](https://developer.mozilla.org/docs/Glossary/HTTPS)).\n * - `origin`: The sent referrer will be limited to the origin of the\n * referring page: its\n * [scheme](https://developer.mozilla.org/docs/Learn/Common_questions/What_is_a_URL),\n * [host](https://developer.mozilla.org/docs/Glossary/Host), and\n * [port](https://developer.mozilla.org/docs/Glossary/Port).\n * - `origin-when-cross-origin`: The referrer sent to other origins will be\n * limited to the scheme, the host, and the port. Navigations on the same\n * origin will still include the path.\n * - `same-origin`: A referrer will be sent for\n * [same origin](https://developer.mozilla.org/docs/Glossary/Same-origin_policy),\n * but cross-origin requests will contain no referrer information.\n * - `strict-origin`: Only send the origin of the document as the referrer\n * when the protocol security level stays the same (HTTPS→HTTPS), but don't\n * send it to a less secure destination (HTTPS→HTTP).\n * - `strict-origin-when-cross-origin` (default): Send a full URL when\n * performing a same-origin request, only send the origin when the protocol\n * security level stays the same (HTTPS→HTTPS), and send no header to a less\n * secure destination (HTTPS→HTTP).\n * - `unsafe-url`: The referrer will include the origin and the path (but not the\n * [fragment](https://developer.mozilla.org/docs/Web/API/HTMLAnchorElement/hash),\n * [password](https://developer.mozilla.org/docs/Web/API/HTMLAnchorElement/password),\n * or [username](https://developer.mozilla.org/docs/Web/API/HTMLAnchorElement/username)).\n * **This value is unsafe** because it leaks origins and paths from\n * TLS-protected resources to insecure origins.\n *\n * @webnative\n */\n @Prop({ attribute: 'referrerpolicy' })\n public readonly referrerPolicy?: ReferrerPolicy\n\n /**\n * The relationship of the linked URL as space-separated\n * [link types](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel).\n *\n * The following list includes some of the most important existing keywords.\n * Every keyword within a space-separated value should be unique within that\n * value.\n *\n * - [`alternate`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-alternate):\n * Alternate representations of the current document.\n * - [`author`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-author):\n * Author of the current document or article.\n * - [`bookmark`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-bookmark):\n * Permalink for the nearest ancestor section.\n * - [`external`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-external):\n * The referenced document is not part of the same site as the current\n * document. An icon will be rendered next to the text if this value is\n * specified.\n * - [`help`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-help):\n * Link to context-sensitive help.\n * - [`license`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-license):\n * Indicates that the main content of the current document is covered by the\n * copyright license described by the referenced document.\n * - [`me`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel/me):\n * Indicates that the current document represents the person who owns the\n * linked content.\n * - [`next`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-next):\n * Indicates that the current document is a part of a series and that the\n * next document in the series is the referenced document.\n * - [`nofollow`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-nofollow):\n * Indicates that the current document's original author or publisher does\n * not endorse the referenced document.\n * - [`noopener`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel/noopener):\n * Creates a top-level browsing context that is not an auxiliary browsing\n * context if the hyperlink would create either of those, to begin with (i.e.,\n * has an appropriate `target` attribute value).\n * - [`noreferrer`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-noreferrer):\n * No `Referer` header will be included. Additionally, has the same effect as\n * `noopener`.\n * - [`opener`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-opener):\n * Creates an auxiliary browsing context if the hyperlink would otherwise\n * create a top-level browsing context that is not an auxiliary browsing\n * context (i.e., has \"`_blank`\" as `target` attribute value).\n * - [`prev`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-prev):\n * Indicates that the current document is a part of a series and that the\n * previous document in the series is the referenced document.\n * - [`search`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-search):\n * Gives a link to a resource that can be used to search through the current\n * document and its related pages.\n * - [`tag`](https://developer.mozilla.org/docs/Web/HTML/Attributes/rel#attr-tag):\n * Gives a tag (identified by the given address) that applies to the current\n * document.\n *\n * @webnative\n */\n @Prop() public readonly rel?: string\n\n /**\n * Where to display the linked URL, as the name for a browsing context (a\n * tab, window, or\n * [`<iframe>`](https://developer.mozilla.org/docs/Web/HTML/Element/iframe).\n * The following keywords have special meanings for where to load the URL:\n *\n * - `_blank`: usually a new tab, but users can configure browsers to open a new\n * window instead.\n * - `_parent`: the parent browsing context of the current one. If no parent,\n * behaves as `_self`.\n * - `_self`: the current browsing context.\n * - `_top`: the topmost browsing context (the \"highest\" context that's an\n * ancestor of the current one). If no ancestors, behaves as `_self`.\n *\n * @webnative\n */\n @Prop() public readonly target?: LiteralUnion<Target, string>\n\n /**\n * Emitted when the standalone link loses focus.\n */\n @Event({ eventName: 'qdsBlur', bubbles: false, cancelable: false })\n private readonly blurEmitter!: EventEmitter<QdsFocusEventDetail>\n\n /**\n * Emitted when the standalone link gains focus.\n */\n @Event({ eventName: 'qdsFocus', bubbles: false, cancelable: false })\n private readonly focusEmitter!: EventEmitter<QdsFocusEventDetail>\n\n @Element() private readonly host!: HTMLElement\n\n @State() private linkIcon?: LinkIcon\n\n @AttachInternals() private readonly internals!: ElementInternals\n\n #savedTabIndex = 0\n\n #link?: HTMLAnchorElement\n\n get #computedImportance(): Importance {\n switch (this.importance) {\n case 'subdued':\n case 'emphasized': {\n return this.importance\n }\n default: {\n return 'standard'\n }\n }\n }\n\n get #computedSize(): Size | undefined {\n switch (this.size) {\n case 'standard':\n case 'small':\n case 'large': {\n return this.size\n }\n default: {\n return 'standard'\n }\n }\n }\n\n get #openInNewTab(): boolean {\n return this.target === '_blank'\n }\n\n @Listen('click')\n protected onClick(event: MouseEvent): void {\n if (this.disabled) event.stopImmediatePropagation()\n }\n\n @Listen('keydown')\n protected onKeydown(event: KeyboardEvent): void {\n invariant(this.#link)\n if (this.disabled) return\n if (event.key === 'Enter') this.#link.click()\n }\n\n @Watch('disabled')\n protected disabledChanged(): void {\n this.internals.ariaDisabled = this.disabled.toString()\n if (this.disabled) this.host.removeAttribute('tabindex')\n else this.host.tabIndex = this.#savedTabIndex\n }\n\n @Watch('tabindex')\n protected tabindexChanged(newValue: string): void {\n const parsedValue = Number.parseInt(newValue, 10)\n // FIXME: `undefined` instead of `0` causes `qdsFocus/qdsBlur` E2E tests\n // to fail, but it's not clear why this is the case since it works for\n // other components.\n this.#savedTabIndex = Number.isNaN(parsedValue) ? 0 : parsedValue\n if (this.disabled) this.host.removeAttribute('tabindex')\n else this.host.tabIndex = this.#savedTabIndex\n }\n\n @Watch('rel')\n @Watch('target')\n protected hrefTargetChanged(): void {\n this.linkIcon = determineLinkIcon(this.target, this.rel)\n this.#updateAriaLabelElements()\n }\n\n public componentWillLoad(): void {\n this.internals.role = 'link'\n this.disabledChanged()\n this.hrefTargetChanged()\n this.tabindexChanged(this.host.getAttribute('tabindex') ?? '0')\n }\n\n public componentDidLoad(): void {\n this.#updateAriaLabelElements()\n }\n\n public render() {\n return (\n <a\n aria-hidden=\"true\"\n class={{\n 'qds-standalone-link': true,\n 'qds-disabled': this.disabled,\n 'qds-visitable': this.visitable,\n }}\n data-importance={this.#computedImportance}\n data-size={this.#computedSize}\n download={this.download}\n href={this.href?.toString()}\n hrefLang={this.hreflang}\n onBlur={this.#onBlur}\n onFocus={this.#onFocus}\n referrerPolicy={this.referrerPolicy}\n rel={this.rel}\n tabIndex={-1}\n target={this.target}\n ref={this.#linkRef}\n >\n {this.iconName !== undefined && this.iconName !== '' && (\n <span class=\"qds-icon-crop\" data-size={this.#computedSize}>\n <qds-icon\n class=\"qds-icon\"\n data-size={this.#computedSize}\n library={this.iconLibrary}\n name={this.iconName}\n />\n </span>\n )}\n <span class=\"qds-text\">\n <slot onSlotchange={this.#onSlotchange} />\n </span>\n {this.linkIcon && (\n <span class=\"qds-icon-crop\" data-size={this.#computedSize}>\n <qds-icon\n class=\"qds-icon\"\n library=\"core\"\n data-size={this.#computedSize}\n name={this.linkIcon}\n />\n </span>\n )}\n {this.importance === 'emphasized' && (\n <span class=\"qds-icon-crop\" data-size={this.#computedSize}>\n <qds-icon\n class=\"qds-icon\"\n data-size={this.#computedSize}\n library=\"core\"\n name=\"next\"\n />\n </span>\n )}\n </a>\n )\n }\n\n readonly #updateAriaLabelElements = (): void => {\n this.internals.ariaLabel = `${this.host.textContent} ${\n this.#openInNewTab ? 'Opens in a new tab' : ''\n }`.trim()\n }\n\n readonly #linkRef = (link?: HTMLAnchorElement): void => {\n this.#link = link\n }\n\n readonly #onBlur = (event: FocusEvent): void => {\n this.blurEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onFocus = (event: FocusEvent): void => {\n this.focusEmitter.emit(pickFocusEventAttributes(event))\n }\n\n readonly #onSlotchange = (): void => {\n this.#updateAriaLabelElements()\n }\n}\n"],"version":3}
@@ -4,9 +4,9 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { p as proxyCustomElement, H, c as createEvent, h } from './p-D2489VzR.js';
7
- import { p as pickFocusEventAttributes } from './p-CURs27Ur.js';
7
+ import { p as pickFocusEventAttributes } from './p-BalM52S_.js';
8
8
  import { V as VALID_STATE, C as CUSTOM_ERROR_FLAGS, N as NO_ERROR_FLAGS } from './p-CZRW1LV_.js';
9
- import { d as defineCustomElement$2 } from './p-DtxwXYGb.js';
9
+ import { d as defineCustomElement$2 } from './p-C9R8N06B.js';
10
10
 
11
11
  const switchCss = ":host([hidden]){display:none!important}:host{display:inline-block;outline:none}.qds-knob,.qds-track{-webkit-print-color-adjust:exact;print-color-adjust:exact}.qds-track{align-items:center;background-color:var(--qds-theme-control-toggle-track-default);border-radius:var(--qds-control-rounded-border-radius);box-sizing:border-box;display:flex;flex-shrink:0;padding-inline:var(--qds-control-toggle-track-padding)}.qds-track:hover{background-color:var(--qds-theme-control-toggle-track-hover)}.qds-track:active{background-color:var(--qds-theme-control-toggle-track-pressed)}.qds-knob-container{align-items:center;align-self:stretch;display:flex;flex-direction:column;flex-shrink:0;justify-content:center;padding-block:var(--qds-control-toggle-track-padding)}.qds-knob{background-color:var(--qds-theme-control-input-background);border-radius:var(--qds-control-rounded-border-radius);box-sizing:border-box;height:100%;margin:0}.qds-indicator{color:var(--qds-theme-control-input-background);flex-grow:1;justify-content:center;padding-block:var(--qds-control-toggle-track-padding)}.qds-container,.qds-indicator{align-items:center;display:flex}.qds-container{box-sizing:border-box;cursor:pointer}.qds-switch{clip-path:inset(50%);height:1px;margin:0;position:absolute;white-space:nowrap;width:1px}.qds-switch:checked~.qds-track{background-color:var(--qds-theme-signature-color-default);justify-content:flex-end}.qds-switch:checked~.qds-track:hover{background-color:var(--qds-theme-signature-color-hover)}.qds-switch:checked~.qds-track:active{background-color:var(--qds-theme-signature-color-pressed)}:host(:focus-visible) .qds-switch~.qds-track{box-shadow:0 0 0 var(--qds-focus-heavy-border-width) var(--qds-theme-focus-border);outline:var(--qds-theme-focus-border-contrast) solid var(--qds-focus-light-border-width);outline-offset:0}.qds-disabled{opacity:var(--qds-theme-disabled);pointer-events:none}.qds-container[data-size=small]{min-height:var(--qds-control-toggle-small-height)}.qds-inline[data-size=small]{min-height:var(--qds-control-small-height);padding-block:var(--qds-control-small-padding-auto-height)}.qds-track[data-size=small]{height:var(--qds-control-toggle-small-track-height);width:var(--qds-control-toggle-small-track-width)}.qds-knob[data-size=small]{width:var(--qds-control-toggle-small-knob-width)}.qds-indicator[data-size=small]{height:var(--qds-control-small-icon-size);width:var(--qds-control-small-icon-size)}.qds-container[data-size=standard]{min-height:var(--qds-control-toggle-standard-height)}.qds-inline[data-size=standard]{min-height:var(--qds-control-standard-height);padding-block:var(--qds-control-standard-padding-auto-height)}.qds-track[data-size=standard]{height:var(--qds-control-toggle-standard-track-height);width:var(--qds-control-toggle-standard-track-width)}.qds-knob[data-size=standard]{width:var(--qds-control-toggle-standard-knob-width)}.qds-indicator[data-size=standard]{height:var(--qds-control-standard-icon-size);width:var(--qds-control-standard-icon-size)}.qds-container[data-size=large]{min-height:var(--qds-control-toggle-large-height)}.qds-inline[data-size=large]{min-height:var(--qds-control-large-height);padding-block:var(--qds-control-large-padding-auto-height)}.qds-track[data-size=large]{height:var(--qds-control-toggle-large-track-height);width:var(--qds-control-toggle-large-track-width)}.qds-knob[data-size=large]{width:var(--qds-control-toggle-large-knob-width)}.qds-indicator[data-size=large]{height:var(--qds-control-large-icon-size);width:var(--qds-control-large-icon-size)}";
12
12
 
@@ -180,13 +180,13 @@ const Switch = /*@__PURE__*/ proxyCustomElement(class Switch extends H {
180
180
  this.tabindexChanged(this.host.getAttribute('tabindex') ?? '0');
181
181
  }
182
182
  render() {
183
- return (h("div", { key: '069ad2361ec53753dea236d5385289bc5cf7c43b', class: {
183
+ return (h("div", { key: 'a994ca43fd0e0622278739d7e69b2091ae712b56', class: {
184
184
  'qds-container': true,
185
185
  'qds-disabled': __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedDisabled_get),
186
186
  'qds-inline': this.inline,
187
- }, "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get), "aria-hidden": "true" }, h("input", { key: 'edd519f0ca4bc0a5a9df50602d29822ac373bdc2', "aria-hidden": "true",
187
+ }, "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get), "aria-hidden": "true" }, h("input", { key: '4ad47ff4666f963608114fa23dfcdbea21768716', "aria-hidden": "true",
188
188
  // eslint-disable-next-line jsx-a11y/no-autofocus
189
- autoFocus: this.host.autofocus, checked: this.checked, class: "qds-switch", disabled: this.disabled, type: "checkbox", value: this.value ?? undefined, tabIndex: -1 }), h("div", { key: '5fe5cfe0155f73a9c50781e5f709b379518f68e1', class: "qds-track", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) }, !this.noIndicator && __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedChecked_get) && (h("div", { key: '03f01573be5637a269dd05d08f438a51d0a04222', class: "qds-indicator", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) }, h("qds-icon", { key: 'd31bbb6ae64160b68ad1cab4a4ab002c8083c7f5', class: "qds-icon", name: "toggle-on", library: "core" }))), h("div", { key: '3b94ef4a388da271cc3e17c9f4e7887e5753ded4', class: "qds-knob-container" }, h("div", { key: 'd0c1cff71474d8b33d757db4cd37bb4ea7d20d40', class: "qds-knob", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) })), !this.noIndicator && !__classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedChecked_get) && (h("div", { key: '9b999c6042687f8d7e1c0d5046419131cf287b84', class: "qds-indicator", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) }, h("qds-icon", { key: '8a47477f273f44e52f26184cf2d19fb0041ec775', class: "qds-icon", name: "toggle-off", library: "core" }))))));
189
+ autoFocus: this.host.autofocus, checked: this.checked, class: "qds-switch", disabled: this.disabled, type: "checkbox", value: this.value ?? undefined, tabIndex: -1 }), h("div", { key: '62ffdca674fecb443977b8a077f67e74b5be561c', class: "qds-track", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) }, !this.noIndicator && __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedChecked_get) && (h("div", { key: '35ace9f745581aa451ddf0618fdae0759cec0a0c', class: "qds-indicator", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) }, h("qds-icon", { key: '5c59c47b9a95721441956169344ed8aa7049a049', class: "qds-icon", name: "toggle-on", library: "core" }))), h("div", { key: '193c882652ace39275e13858d7a73e9993271b52', class: "qds-knob-container" }, h("div", { key: 'e0a80c43ed774d3e2a89a9b437f1b3ec0e647937', class: "qds-knob", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) })), !this.noIndicator && !__classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedChecked_get) && (h("div", { key: '14f8db236430628094cfd58dd794de83f559cd88', class: "qds-indicator", "data-size": __classPrivateFieldGet(this, _Switch_instances, "a", _Switch_computedSize_get) }, h("qds-icon", { key: 'c180a31164968b92edac3a9b48d53dbf7cf1cf75', class: "qds-icon", name: "toggle-off", library: "core" }))))));
190
190
  }
191
191
  static get formAssociated() { return true; }
192
192
  get host() { return this; }
@@ -4,14 +4,14 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { p as proxyCustomElement, H, c as createEvent, h } from './p-D2489VzR.js';
7
- import { p as pickFocusEventAttributes, r as resolveTarget } from './p-CURs27Ur.js';
8
- import { d as defineCustomElement$6 } from './p-CDRwHAIT.js';
7
+ import { p as pickFocusEventAttributes, r as resolveTarget } from './p-BalM52S_.js';
8
+ import { d as defineCustomElement$6 } from './p-XP2CY_fo.js';
9
9
  import { d as defineCustomElement$5 } from './p-U2Q0vF-d.js';
10
- import { d as defineCustomElement$4 } from './p-DtxwXYGb.js';
11
- import { d as defineCustomElement$3 } from './p-B2ZVUvk9.js';
12
- import { d as defineCustomElement$2 } from './p-DR79BVX5.js';
10
+ import { d as defineCustomElement$4 } from './p-C9R8N06B.js';
11
+ import { d as defineCustomElement$3 } from './p-DgYrfIr_.js';
12
+ import { d as defineCustomElement$2 } from './p-CKp062X8.js';
13
13
 
14
- const tabCss = ":host([hidden]){display:none!important}:host{display:inline-block;line-height:0}[aria-disabled=true]{opacity:var(--qds-theme-disabled);pointer-events:none}:host(:focus-visible){border-radius:var(--qds-focus-border-radius);outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width);outline-offset:calc(var(--qds-focus-border-width)*-1 - var(--qds-focus-border-offset))}.qds-target-icon{color:var(--qds-theme-control-text-standard)}.qds-icon,.qds-target-icon{flex-shrink:0}.qds-chevron{transform:rotate(180deg)}.qds-selected:hover{background-color:var(--qds-theme-interactive-background-selected-hover)}.qds-selected:active{background-color:var(--qds-theme-interactive-background-selected-pressed)}.qds-closable-tab,.qds-closable-wrapper,.qds-tab,.qds-texts{display:flex}.qds-texts{flex:1 0;flex-direction:column}.qds-icon,.qds-text{color:var(--qds-theme-title)}.qds-subtitle{color:var(--qds-theme-subtitle);font:var(--qds-nav-element-standard-subtitle)}.qds-closable-wrapper[data-size=small],.qds-tab[data-size=small]{gap:var(--qds-nav-element-small-gap-internal);min-height:var(--qds-nav-element-small-height);padding-inline:var(--qds-nav-element-small-padding-horizontal)}.qds-closable-tab[data-size=small]{gap:var(--qds-nav-element-small-gap-internal)}[data-size=small]>.qds-icon{height:var(--qds-nav-element-small-icon-size);width:var(--qds-nav-element-small-icon-size)}[data-size=small]>.qds-texts{gap:var(--qds-nav-element-small-titles-gap)}[data-size=small] .qds-text{font:var(--qds-nav-element-small-title)}[data-size=small] .qds-subtitle{font:var(--qds-nav-element-small-subtitle)}.qds-target-icon[data-size=small]{height:var(--qds-control-small-icon-size);width:var(--qds-control-small-icon-size)}.qds-closable-wrapper[data-size=standard],.qds-tab[data-size=standard]{gap:var(--qds-nav-element-standard-gap-internal);min-height:var(--qds-nav-element-standard-height);padding-inline:var(--qds-nav-element-standard-padding-horizontal)}.qds-closable-tab[data-size=standard]{gap:var(--qds-nav-element-standard-gap-internal)}[data-size=standard]>.qds-icon{height:var(--qds-nav-element-standard-icon-size);width:var(--qds-nav-element-standard-icon-size)}[data-size=standard]>.qds-texts{gap:var(--qds-nav-element-standard-titles-gap)}[data-size=standard] .qds-text{font:var(--qds-nav-element-standard-title)}[data-size=standard] .qds-subtitle{font:var(--qds-nav-element-standard-subtitle)}.qds-target-icon[data-size=standard]{height:var(--qds-control-standard-icon-size);width:var(--qds-control-standard-icon-size)}.qds-closable-wrapper[data-size=large],.qds-tab[data-size=large]{gap:var(--qds-nav-element-large-gap-internal);min-height:var(--qds-nav-element-large-height);padding-inline:var(--qds-nav-element-large-padding-horizontal)}.qds-closable-tab[data-size=large]{gap:var(--qds-nav-element-large-gap-internal)}[data-size=large]>.qds-icon{height:var(--qds-nav-element-large-icon-size);width:var(--qds-nav-element-large-icon-size)}[data-size=large]>.qds-texts{gap:var(--qds-nav-element-large-titles-gap)}[data-size=large] .qds-text{font:var(--qds-nav-element-large-title)}[data-size=large] .qds-subtext{font:var(--qds-nav-element-large-subtitle)}.qds-target-icon[data-size=large]{height:var(--qds-control-large-icon-size);width:var(--qds-control-large-icon-size)}:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{border-radius:var(--qds-signature-line-connection-cap-radius);content:\"\";display:block;position:absolute}.qds-indicator-inline-end:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after,.qds-indicator-inline-start:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{height:100%;width:var(--qds-signature-line-connection-width)}.qds-indicator-inline-end:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{inset-inline-end:0}.qds-indicator-inline-start:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{inset-inline-start:0}.qds-indicator-block-end:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after,.qds-indicator-block-start:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{height:var(--qds-signature-line-connection-width);width:100%}.qds-indicator-block-end:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{bottom:0}.qds-indicator-block-start:is(.qds-selected[data-importance=subdued],.qds-selected[data-importance=standard],.qds-closable-wrapper[data-importance=subdued],.qds-closable-wrapper[data-importance=standard],[data-importance=subdued] .qds-tab:hover,[data-importance=standard] .qds-tab:hover):after{top:0}.qds-selected[data-importance=standard][data-size=standard] .qds-text,.qds-selected[data-importance=subdued][data-size=standard] .qds-text{font:var(--qds-nav-element-standard-title-emphasized)}.qds-selected[data-importance=standard][data-size=small] .qds-text,.qds-selected[data-importance=subdued][data-size=small] .qds-text{font:var(--qds-nav-element-small-title-emphasized)}.qds-selected[data-importance=standard][data-size=large] .qds-text,.qds-selected[data-importance=subdued][data-size=large] .qds-text{font:var(--qds-nav-element-large-title-emphasized)}[data-importance=standard] .qds-selected .qds-icon{color:var(--qds-theme-title)}[data-importance=standard]:hover:after{background-color:var(--qds-theme-signature-color-hover)}[data-importance=standard]:active:after{background-color:var(--qds-theme-signature-color-pressed)}.qds-selected[data-importance=standard]:after{background-color:var(--qds-theme-signature-color-default)}.qds-selected[data-importance=subdued]:after,[data-importance=subdued] :active:after{background-color:var(--qds-theme-link-subdued-pressed)}[data-importance=subdued]:hover:after{background-color:var(--qds-theme-link-subdued-hover)}.qds-selected[data-importance=subdued]:after{background-color:var(\n --qds-theme-nav-element-selection-indicator-background-subdued\n )}.qds-tab:focus-visible{border-radius:var(--qds-focus-border-radius);outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width);outline-offset:calc(var(--qds-focus-border-width)*-1 - var(--qds-focus-border-offset))}.qds-closable-tab{width:100%}.qds-closable-tab:focus-visible{border-radius:var(--qds-focus-border-radius);outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width)}.qds-closable-tab,.qds-closable-wrapper,.qds-tab{align-items:center;justify-content:center}.qds-closable-tab,.qds-tab{background-color:initial;border:none;cursor:pointer;text-align:initial}.qds-closable-tab:any-link,.qds-tab:any-link{-webkit-text-decoration:none;text-decoration:none}.qds-closable-wrapper,.qds-tab{position:relative}.qds-closable-wrapper:not(.qds-selected):hover,.qds-tab:not(.qds-selected):hover{background-color:var(--qds-theme-interactive-background-hover)}.qds-closable-wrapper:not(.qds-selected):active,.qds-tab:not(.qds-selected):active{background-color:var(--qds-theme-interactive-background-pressed)}";
14
+ const tabCss = ":host([hidden]){display:none!important}:host{display:inline-block;line-height:0}[aria-disabled=true]{opacity:var(--qds-theme-disabled);pointer-events:none}:host(:focus-visible){border-radius:var(--qds-focus-border-radius);outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width);outline-offset:calc(var(--qds-focus-border-width)*-1 - var(--qds-focus-border-offset))}.qds-target-icon{color:var(--qds-theme-control-text-standard)}.qds-icon,.qds-target-icon{flex-shrink:0}.qds-chevron{transform:rotate(180deg)}.qds-selected:hover{background-color:var(--qds-theme-interactive-background-selected-hover)}.qds-selected:active{background-color:var(--qds-theme-interactive-background-selected-pressed)}.qds-closable-tab,.qds-closable-wrapper,.qds-tab,.qds-texts{display:flex}.qds-texts{flex:1 0;flex-direction:column}.qds-icon,.qds-text{color:var(--qds-theme-title)}.qds-subtitle{color:var(--qds-theme-subtitle);font:var(--qds-nav-element-standard-subtitle)}.qds-closable-wrapper[data-size=small],.qds-tab[data-size=small]{gap:var(--qds-nav-element-small-gap-internal);min-height:var(--qds-nav-element-small-height);padding-inline:var(--qds-nav-element-small-padding-horizontal)}.qds-closable-tab[data-size=small]{gap:var(--qds-nav-element-small-gap-internal)}[data-size=small]>.qds-icon{height:var(--qds-nav-element-small-icon-size);width:var(--qds-nav-element-small-icon-size)}[data-size=small]>.qds-texts{gap:var(--qds-nav-element-small-titles-gap)}[data-size=small] .qds-text{font:var(--qds-nav-element-small-title)}[data-size=small] .qds-subtitle{font:var(--qds-nav-element-small-subtitle)}.qds-target-icon[data-size=small]{height:var(--qds-control-small-icon-size);width:var(--qds-control-small-icon-size)}.qds-closable-wrapper[data-size=standard],.qds-tab[data-size=standard]{gap:var(--qds-nav-element-standard-gap-internal);min-height:var(--qds-nav-element-standard-height);padding-inline:var(--qds-nav-element-standard-padding-horizontal)}.qds-closable-tab[data-size=standard]{gap:var(--qds-nav-element-standard-gap-internal)}[data-size=standard]>.qds-icon{height:var(--qds-nav-element-standard-icon-size);width:var(--qds-nav-element-standard-icon-size)}[data-size=standard]>.qds-texts{gap:var(--qds-nav-element-standard-titles-gap)}[data-size=standard] .qds-text{font:var(--qds-nav-element-standard-title)}[data-size=standard] .qds-subtitle{font:var(--qds-nav-element-standard-subtitle)}.qds-target-icon[data-size=standard]{height:var(--qds-control-standard-icon-size);width:var(--qds-control-standard-icon-size)}.qds-closable-wrapper[data-size=large],.qds-tab[data-size=large]{gap:var(--qds-nav-element-large-gap-internal);min-height:var(--qds-nav-element-large-height);padding-inline:var(--qds-nav-element-large-padding-horizontal)}.qds-closable-tab[data-size=large]{gap:var(--qds-nav-element-large-gap-internal)}[data-size=large]>.qds-icon{height:var(--qds-nav-element-large-icon-size);width:var(--qds-nav-element-large-icon-size)}[data-size=large]>.qds-texts{gap:var(--qds-nav-element-large-titles-gap)}[data-size=large] .qds-text{font:var(--qds-nav-element-large-title)}[data-size=large] .qds-subtext{font:var(--qds-nav-element-large-subtitle)}.qds-target-icon[data-size=large]{height:var(--qds-control-large-icon-size);width:var(--qds-control-large-icon-size)}[data-importance=standard] .qds-selected .qds-icon{color:var(--qds-theme-title)}.qds-selected[data-importance=standard]:after{background-color:var(--qds-theme-signature-color-default)}.qds-selected[data-importance=subdued]:after{background-color:var(\n --qds-theme-nav-element-selection-indicator-background-subdued\n )}.qds-selected[data-importance=standard]:after,.qds-selected[data-importance=subdued]:after{border-radius:var(--qds-signature-line-connection-cap-radius);content:\"\";display:block;position:absolute}.qds-selected.qds-indicator-inline-end[data-importance=standard]:after,.qds-selected.qds-indicator-inline-end[data-importance=subdued]:after,.qds-selected.qds-indicator-inline-start[data-importance=standard]:after,.qds-selected.qds-indicator-inline-start[data-importance=subdued]:after{height:100%;width:var(--qds-signature-line-connection-width)}.qds-selected.qds-indicator-inline-end[data-importance=standard]:after,.qds-selected.qds-indicator-inline-end[data-importance=subdued]:after{inset-inline-end:0}.qds-selected.qds-indicator-inline-start[data-importance=standard]:after,.qds-selected.qds-indicator-inline-start[data-importance=subdued]:after{inset-inline-start:0}.qds-selected.qds-indicator-block-end[data-importance=standard]:after,.qds-selected.qds-indicator-block-end[data-importance=subdued]:after,.qds-selected.qds-indicator-block-start[data-importance=standard]:after,.qds-selected.qds-indicator-block-start[data-importance=subdued]:after{height:var(--qds-signature-line-connection-width);width:100%}.qds-selected.qds-indicator-block-end[data-importance=standard]:after,.qds-selected.qds-indicator-block-end[data-importance=subdued]:after{bottom:0}.qds-selected.qds-indicator-block-start[data-importance=standard]:after,.qds-selected.qds-indicator-block-start[data-importance=subdued]:after{top:0}.qds-selected[data-importance=standard][data-size=standard] .qds-text,.qds-selected[data-importance=subdued][data-size=standard] .qds-text{font:var(--qds-nav-element-standard-title-emphasized)}.qds-selected[data-importance=standard][data-size=small] .qds-text,.qds-selected[data-importance=subdued][data-size=small] .qds-text{font:var(--qds-nav-element-small-title-emphasized)}.qds-selected[data-importance=standard][data-size=large] .qds-text,.qds-selected[data-importance=subdued][data-size=large] .qds-text{font:var(--qds-nav-element-large-title-emphasized)}.qds-tab:focus-visible{border-radius:var(--qds-focus-border-radius);outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width);outline-offset:calc(var(--qds-focus-border-width)*-1 - var(--qds-focus-border-offset))}.qds-closable-tab{width:100%}.qds-closable-tab:focus-visible{border-radius:var(--qds-focus-border-radius);outline:var(--qds-theme-focus-border) solid var(--qds-focus-border-width)}.qds-closable-tab,.qds-closable-wrapper,.qds-tab{align-items:center;justify-content:center}.qds-closable-tab,.qds-tab{background-color:initial;border:none;cursor:pointer;text-align:initial}.qds-closable-tab:any-link,.qds-tab:any-link{-webkit-text-decoration:none;text-decoration:none}.qds-closable-wrapper,.qds-tab{position:relative}.qds-closable-wrapper:not(.qds-selected):hover,.qds-tab:not(.qds-selected):hover{background-color:var(--qds-theme-interactive-background-hover)}.qds-closable-wrapper:not(.qds-selected):active,.qds-tab:not(.qds-selected):active{background-color:var(--qds-theme-interactive-background-pressed)}";
15
15
 
16
16
  // SPDX-FileCopyrightText: © 2024 Schneider Electric
17
17
  //
@@ -32,7 +32,7 @@ var __classPrivateFieldSet = (undefined && undefined.__classPrivateFieldSet) ||
32
32
  throw new TypeError("Cannot write private member to an object whose class did not declare it");
33
33
  return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
34
34
  };
35
- var _Tab_instances, _Tab_panel, _Tab_tab, _Tab_computedAction_get, _Tab_computedSize_get, _Tab_computedImportance_get, _Tab_parentLayer_get, _Tab_parentLevel_get, _Tab_ariaLabel_get, _Tab_computedDisabled_get, _Tab_computeCloseButtonTabIndex_get, _Tab_renderText, _Tab_tabRef, _Tab_close, _Tab_onIconClick, _Tab_onBlur, _Tab_onFocus, _Tab_defineTab, _Tab_defineGetter;
35
+ var _Tab_instances, _Tab_panel, _Tab_tab, _Tab_computedAction_get, _Tab_computedSize_get, _Tab_computedImportance_get, _Tab_parentImportance_get, _Tab_parentSize_get, _Tab_parentLayer_get, _Tab_parentLevel_get, _Tab_ariaLabel_get, _Tab_computedDisabled_get, _Tab_computeCloseButtonTabIndex_get, _Tab_renderText, _Tab_tabRef, _Tab_close, _Tab_onIconClick, _Tab_onBlur, _Tab_onFocus, _Tab_defineTab, _Tab_defineGetter;
36
36
  const isCounter = (value) => typeof value === 'string'
37
37
  ? !Number.isNaN(Number.parseFloat(value))
38
38
  : typeof value === 'number';
@@ -69,7 +69,7 @@ const Tab = /*@__PURE__*/ proxyCustomElement(class Tab extends H {
69
69
  /**
70
70
  * The tab's indicator position.
71
71
  */
72
- this.indicatorPosition = 'block-end';
72
+ this.indicatorPosition = 'block-start';
73
73
  /**
74
74
  * The name of a registered icon library.
75
75
  */
@@ -180,19 +180,16 @@ const Tab = /*@__PURE__*/ proxyCustomElement(class Tab extends H {
180
180
  }
181
181
  render() {
182
182
  const isLink = this.href !== undefined && __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === undefined;
183
- const indicatorPosition = this.isIndicatorOnTop
184
- ? 'block-start'
185
- : this.indicatorPosition;
186
183
  const Tag = isLink
187
184
  ? 'a'
188
185
  : __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'expandable'
189
186
  ? 'button'
190
187
  : 'div';
191
- return (h("div", { key: 'a7e5f460e6bbcc0b16addb8390bd017d7f55c072', "aria-disabled": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedDisabled_get) ? 'true' : undefined, class: {
188
+ return (h("div", { key: '5315497861332b523d44189a04238cee49ccff3a', "aria-disabled": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedDisabled_get) ? 'true' : undefined, class: {
192
189
  'qds-closable-wrapper': __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'closable',
193
190
  'qds-selected': this.selected,
194
- [`qds-indicator-${indicatorPosition}`]: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'closable',
195
- }, "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), "data-importance": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedImportance_get) }, h(Tag, { key: '8f8acf408e6343208a8140bc67084898e14d3479', ref: __classPrivateFieldGet(this, _Tab_tabRef, "f"), "aria-disabled": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedDisabled_get) ? 'true' : undefined, disabled: isLink ? undefined : this.disabled, onBlur: __classPrivateFieldGet(this, _Tab_onBlur, "f"), onFocus: __classPrivateFieldGet(this, _Tab_onFocus, "f"), class: {
191
+ [`qds-indicator-${this.indicatorPosition}`]: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'closable',
192
+ }, "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), "data-importance": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedImportance_get) }, h(Tag, { key: '5d0ffe78945e31f890fd8bb382a2e2c70380c2e8', ref: __classPrivateFieldGet(this, _Tab_tabRef, "f"), "aria-disabled": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedDisabled_get) ? 'true' : undefined, disabled: isLink ? undefined : this.disabled, onBlur: __classPrivateFieldGet(this, _Tab_onBlur, "f"), onFocus: __classPrivateFieldGet(this, _Tab_onFocus, "f"), class: {
196
193
  'qds-tab': __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) !== 'closable',
197
194
  'qds-closable-tab': __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'closable',
198
195
  'qds-selected': this.selected,
@@ -202,7 +199,7 @@ const Tab = /*@__PURE__*/ proxyCustomElement(class Tab extends H {
202
199
  ? 'true'
203
200
  : 'false'
204
201
  : undefined, "data-importance": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedImportance_get), "data-action": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get), "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), href: isLink ? this.href : undefined }, ((this.tagText !== undefined && this.tagText !== '') ||
205
- (this.tagIconName !== undefined && this.tagIconName !== '')) && (h("qds-tag", { key: 'a69e2c407bedc1f3d710f3cbd2789eba292cc9c9', text: this.tagText, status: this.tagStatus, size: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), importance: this.tagImportance, "icon-library": this.tagIconLibrary, "icon-name": this.tagIconName, "icon-description": this.tagIconDescription })), this.iconName !== undefined && this.iconName !== '' && (h("qds-icon", { key: '12d6f3003c346f26c908b5b6f48ab1308593409f', "aria-hidden": "true", class: "qds-icon", library: this.iconLibrary, name: this.iconName })), this.text && __classPrivateFieldGet(this, _Tab_instances, "m", _Tab_renderText).call(this), isIndicator(this.badge) && (h("qds-badge-indicator", { key: 'bf8b256c2b13ff5db116946084c783ed90ba3bb5', status: this.badgeIndicatorStatus, description: this.badgeDescription, size: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), strokeRing: true })), isCounter(this.badge) && (h("qds-badge-counter", { key: 'a4c44307105e6112e5d4329e7079a6fdd697d19c', description: this.badgeDescription, importance: this.badgeCounterImportance, size: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), strokeRing: true, value: this.badge })), __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'expandable' && (h("qds-icon", { key: 'db78b4abbe81932fe0f1cca08b8fd78cb40504dc', "aria-hidden": "true", class: { 'qds-target-icon': true, 'qds-chevron': this.selected }, "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), library: "core", name: "dropdown" }))), __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'closable' && (h("qds-mini-button", { key: 'ee5b8a295493a839274523c736a438a299e8b02a', name: "close", library: "core", text: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_ariaLabel_get), "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), disabled: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedDisabled_get), onClick: __classPrivateFieldGet(this, _Tab_onIconClick, "f"), tabIndex: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computeCloseButtonTabIndex_get) }))));
202
+ (this.tagIconName !== undefined && this.tagIconName !== '')) && (h("qds-tag", { key: '3dc70a5b756995e7a8b27e207da5ae69c0f07966', text: this.tagText, status: this.tagStatus, size: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), importance: this.tagImportance, "icon-library": this.tagIconLibrary, "icon-name": this.tagIconName, "icon-description": this.tagIconDescription })), this.iconName !== undefined && this.iconName !== '' && (h("qds-icon", { key: 'ec984fdce7855e58b9981c2cbff4a1b6c664bce6', "aria-hidden": "true", class: "qds-icon", library: this.iconLibrary, name: this.iconName })), this.text && __classPrivateFieldGet(this, _Tab_instances, "m", _Tab_renderText).call(this), isIndicator(this.badge) && (h("qds-badge-indicator", { key: 'cb6ec00cd85a5858d608f9bfcbb80a6ac8b4767d', status: this.badgeIndicatorStatus, description: this.badgeDescription, size: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), strokeRing: true })), isCounter(this.badge) && (h("qds-badge-counter", { key: '007e24af5206a2ea0cc6205ab74086e5c9bc8d34', description: this.badgeDescription, importance: this.badgeCounterImportance, size: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), strokeRing: true, value: this.badge })), __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'expandable' && (h("qds-icon", { key: '2eacc81e4f8e952365d811e73f9ce1d56a2c1b42', class: { 'qds-target-icon': true, 'qds-chevron': this.selected }, "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), library: "core", name: "dropdown" }))), __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedAction_get) === 'closable' && (h("qds-mini-button", { key: '730c62133c50a8877994910154d75abc8074d2ad', name: "close", library: "core", text: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_ariaLabel_get), "data-size": __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedSize_get), disabled: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computedDisabled_get), onClick: __classPrivateFieldGet(this, _Tab_onIconClick, "f"), tabIndex: __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_computeCloseButtonTabIndex_get) }))));
206
203
  }
207
204
  get host() { return this; }
208
205
  static get watchers() { return {
@@ -253,6 +250,8 @@ _Tab_panel = new WeakMap(), _Tab_tab = new WeakMap(), _Tab_tabRef = new WeakMap(
253
250
  }
254
251
  }
255
252
  }, _Tab_computedSize_get = function _Tab_computedSize_get() {
253
+ if (__classPrivateFieldGet(this, _Tab_instances, "a", _Tab_parentSize_get) !== undefined)
254
+ return __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_parentSize_get);
256
255
  switch (this.size) {
257
256
  case 'standard':
258
257
  case 'small':
@@ -264,6 +263,8 @@ _Tab_panel = new WeakMap(), _Tab_tab = new WeakMap(), _Tab_tabRef = new WeakMap(
264
263
  }
265
264
  }
266
265
  }, _Tab_computedImportance_get = function _Tab_computedImportance_get() {
266
+ if (__classPrivateFieldGet(this, _Tab_instances, "a", _Tab_parentImportance_get) !== undefined)
267
+ return __classPrivateFieldGet(this, _Tab_instances, "a", _Tab_parentImportance_get);
267
268
  switch (this.importance) {
268
269
  case 'subdued':
269
270
  case 'standard': {
@@ -273,6 +274,10 @@ _Tab_panel = new WeakMap(), _Tab_tab = new WeakMap(), _Tab_tabRef = new WeakMap(
273
274
  return 'standard';
274
275
  }
275
276
  }
277
+ }, _Tab_parentImportance_get = function _Tab_parentImportance_get() {
278
+ return this.host.closest('qds-tabbar')?.importance ?? undefined;
279
+ }, _Tab_parentSize_get = function _Tab_parentSize_get() {
280
+ return this.host.closest('qds-tabbar')?.size ?? undefined;
276
281
  }, _Tab_parentLayer_get = function _Tab_parentLayer_get() {
277
282
  return this.host.closest('qds-tabbar')?.layer ?? 'main';
278
283
  }, _Tab_parentLevel_get = function _Tab_parentLevel_get() {