@atomic-ui/ui 0.10.1 → 0.12.1

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 (210) hide show
  1. package/custom-elements.json +9631 -6026
  2. package/dist/base/FieldElement.d.ts +10 -3
  3. package/dist/{chunk-YWP2Z3JN.js → chunk-2TNF7O43.js} +7 -5
  4. package/dist/{chunk-YWP2Z3JN.js.map → chunk-2TNF7O43.js.map} +1 -1
  5. package/dist/{chunk-FKUBEVCU.js → chunk-2WHOBIOY.js} +11 -9
  6. package/dist/{chunk-FKUBEVCU.js.map → chunk-2WHOBIOY.js.map} +1 -1
  7. package/dist/{chunk-26BO3W56.js → chunk-3BWCD5U5.js} +5 -3
  8. package/dist/{chunk-26BO3W56.js.map → chunk-3BWCD5U5.js.map} +1 -1
  9. package/dist/chunk-3GPGDERO.js +201 -0
  10. package/dist/chunk-3GPGDERO.js.map +1 -0
  11. package/dist/{chunk-3T7J66Z2.js → chunk-3KAFK24X.js} +13 -11
  12. package/dist/chunk-3KAFK24X.js.map +1 -0
  13. package/dist/chunk-4MMRBNW7.js +104 -0
  14. package/dist/chunk-4MMRBNW7.js.map +1 -0
  15. package/dist/{chunk-5OJAJA3U.js → chunk-5HCWL2YD.js} +6 -4
  16. package/dist/{chunk-5OJAJA3U.js.map → chunk-5HCWL2YD.js.map} +1 -1
  17. package/dist/{chunk-AG4EP3OY.js → chunk-5IGBH4GL.js} +8 -6
  18. package/dist/{chunk-AG4EP3OY.js.map → chunk-5IGBH4GL.js.map} +1 -1
  19. package/dist/{chunk-AL4IUSML.js → chunk-5OYQZWP2.js} +5 -3
  20. package/dist/{chunk-AL4IUSML.js.map → chunk-5OYQZWP2.js.map} +1 -1
  21. package/dist/chunk-5PRB7P7N.js +167 -0
  22. package/dist/chunk-5PRB7P7N.js.map +1 -0
  23. package/dist/chunk-6CDQSHVW.js +21 -0
  24. package/dist/chunk-6CDQSHVW.js.map +1 -0
  25. package/dist/{chunk-MLKNZL5J.js → chunk-6J22I7F6.js} +14 -12
  26. package/dist/chunk-6J22I7F6.js.map +1 -0
  27. package/dist/chunk-72WNCCDC.js +136 -0
  28. package/dist/chunk-72WNCCDC.js.map +1 -0
  29. package/dist/chunk-7UI3OBXL.js +104 -0
  30. package/dist/chunk-7UI3OBXL.js.map +1 -0
  31. package/dist/{chunk-D6NET2VB.js → chunk-ALFE35FS.js} +30 -3
  32. package/dist/chunk-ALFE35FS.js.map +1 -0
  33. package/dist/chunk-AYINRYNC.js +184 -0
  34. package/dist/chunk-AYINRYNC.js.map +1 -0
  35. package/dist/{chunk-2D2IMQII.js → chunk-BAYSDP44.js} +52 -30
  36. package/dist/chunk-BAYSDP44.js.map +1 -0
  37. package/dist/{chunk-2EP3IV3G.js → chunk-BGHAANTP.js} +22 -8
  38. package/dist/chunk-BGHAANTP.js.map +1 -0
  39. package/dist/{chunk-OJO62KRX.js → chunk-CFCFKLTN.js} +85 -10
  40. package/dist/chunk-CFCFKLTN.js.map +1 -0
  41. package/dist/{chunk-UFPI4I2Y.js → chunk-CQT3VPYK.js} +8 -29
  42. package/dist/chunk-CQT3VPYK.js.map +1 -0
  43. package/dist/{chunk-AURT72IC.js → chunk-DXLEYNID.js} +13 -7
  44. package/dist/chunk-DXLEYNID.js.map +1 -0
  45. package/dist/{chunk-L4CIBOGK.js → chunk-EKPTMRBG.js} +5 -3
  46. package/dist/{chunk-L4CIBOGK.js.map → chunk-EKPTMRBG.js.map} +1 -1
  47. package/dist/{chunk-Z2EWQMTR.js → chunk-F4IXELLK.js} +5 -3
  48. package/dist/{chunk-Z2EWQMTR.js.map → chunk-F4IXELLK.js.map} +1 -1
  49. package/dist/{chunk-APQEXM4I.js → chunk-FJHPGOGS.js} +5 -3
  50. package/dist/{chunk-APQEXM4I.js.map → chunk-FJHPGOGS.js.map} +1 -1
  51. package/dist/chunk-FLAUZU7Y.js +345 -0
  52. package/dist/chunk-FLAUZU7Y.js.map +1 -0
  53. package/dist/{chunk-3NEWOO2P.js → chunk-FZWUQC42.js} +7 -5
  54. package/dist/{chunk-3NEWOO2P.js.map → chunk-FZWUQC42.js.map} +1 -1
  55. package/dist/{chunk-ONED3PUB.js → chunk-HSXLSJVG.js} +54 -8
  56. package/dist/chunk-HSXLSJVG.js.map +1 -0
  57. package/dist/{chunk-V7EB7Q2M.js → chunk-JTCTQBAX.js} +2 -131
  58. package/dist/chunk-JTCTQBAX.js.map +1 -0
  59. package/dist/{chunk-ZL3JFUIE.js → chunk-K5QFVLCI.js} +7 -5
  60. package/dist/{chunk-ZL3JFUIE.js.map → chunk-K5QFVLCI.js.map} +1 -1
  61. package/dist/{chunk-DN5YZFSG.js → chunk-KE6WCXQP.js} +55 -9
  62. package/dist/chunk-KE6WCXQP.js.map +1 -0
  63. package/dist/chunk-LBHTXY7K.js +75 -0
  64. package/dist/chunk-LBHTXY7K.js.map +1 -0
  65. package/dist/{chunk-OZGKK3N5.js → chunk-LP4RTYTL.js} +88 -9
  66. package/dist/chunk-LP4RTYTL.js.map +1 -0
  67. package/dist/{chunk-MOO63SHZ.js → chunk-LXVPWTSY.js} +80 -23
  68. package/dist/chunk-LXVPWTSY.js.map +1 -0
  69. package/dist/{chunk-JNLKM3JT.js → chunk-N6EEW2GF.js} +6 -4
  70. package/dist/{chunk-JNLKM3JT.js.map → chunk-N6EEW2GF.js.map} +1 -1
  71. package/dist/chunk-NHEU5FT6.js +115 -0
  72. package/dist/chunk-NHEU5FT6.js.map +1 -0
  73. package/dist/chunk-QPOM7W3D.js +104 -0
  74. package/dist/chunk-QPOM7W3D.js.map +1 -0
  75. package/dist/{chunk-FU3CEHBS.js → chunk-R6PBY3YN.js} +6 -4
  76. package/dist/{chunk-FU3CEHBS.js.map → chunk-R6PBY3YN.js.map} +1 -1
  77. package/dist/{chunk-TJOYBDKS.js → chunk-R6YMSJR7.js} +65 -36
  78. package/dist/chunk-R6YMSJR7.js.map +1 -0
  79. package/dist/{chunk-ZEIV5X3U.js → chunk-SOYKSPPX.js} +73 -23
  80. package/dist/chunk-SOYKSPPX.js.map +1 -0
  81. package/dist/{chunk-NKMJMVZP.js → chunk-T52CUOCJ.js} +5 -3
  82. package/dist/{chunk-NKMJMVZP.js.map → chunk-T52CUOCJ.js.map} +1 -1
  83. package/dist/chunk-UBNCJROR.js +294 -0
  84. package/dist/chunk-UBNCJROR.js.map +1 -0
  85. package/dist/chunk-UFENSIWD.js +135 -0
  86. package/dist/chunk-UFENSIWD.js.map +1 -0
  87. package/dist/{chunk-A4M3A4SZ.js → chunk-UYTIJCCW.js} +10 -42
  88. package/dist/chunk-UYTIJCCW.js.map +1 -0
  89. package/dist/chunk-XX6JZW5N.js +36 -0
  90. package/dist/chunk-XX6JZW5N.js.map +1 -0
  91. package/dist/{chunk-2ZF3J7OO.js → chunk-XXSZL5CY.js} +17 -5
  92. package/dist/chunk-XXSZL5CY.js.map +1 -0
  93. package/dist/{chunk-6PMA6NHE.js → chunk-Y55FNQHS.js} +5 -3
  94. package/dist/{chunk-6PMA6NHE.js.map → chunk-Y55FNQHS.js.map} +1 -1
  95. package/dist/chunk-ZAWGJC4I.js +176 -0
  96. package/dist/chunk-ZAWGJC4I.js.map +1 -0
  97. package/dist/chunk-ZUQ3DOG2.js +110 -0
  98. package/dist/chunk-ZUQ3DOG2.js.map +1 -0
  99. package/dist/components/accordion.d.ts +22 -0
  100. package/dist/components/accordion.js +6 -2
  101. package/dist/components/alert.d.ts +22 -1
  102. package/dist/components/alert.js +3 -2
  103. package/dist/components/app-bar.d.ts +153 -0
  104. package/dist/components/app-bar.js +15 -0
  105. package/dist/components/app-bar.js.map +1 -0
  106. package/dist/components/app-ui.d.ts +29 -2
  107. package/dist/components/app-ui.js +5 -4
  108. package/dist/components/badge.d.ts +17 -1
  109. package/dist/components/badge.js +4 -3
  110. package/dist/components/blocks.js +5 -4
  111. package/dist/components/button.d.ts +18 -2
  112. package/dist/components/button.js +4 -3
  113. package/dist/components/checkbox-group.js +4 -3
  114. package/dist/components/checkbox.js +4 -3
  115. package/dist/components/checked.d.ts +77 -0
  116. package/dist/components/checked.js +10 -0
  117. package/dist/components/checked.js.map +1 -0
  118. package/dist/components/chip-group.d.ts +113 -0
  119. package/dist/components/chip-group.js +11 -0
  120. package/dist/components/chip-group.js.map +1 -0
  121. package/dist/components/chip.d.ts +11 -0
  122. package/dist/components/chip.js +3 -2
  123. package/dist/components/code-diff.d.ts +77 -0
  124. package/dist/components/code-diff.js +10 -0
  125. package/dist/components/code-diff.js.map +1 -0
  126. package/dist/components/date-input.js +4 -3
  127. package/dist/components/dialog.d.ts +15 -0
  128. package/dist/components/dialog.js +3 -2
  129. package/dist/components/fieldset.js +3 -2
  130. package/dist/components/grid.js +3 -2
  131. package/dist/components/help.js +3 -2
  132. package/dist/components/icon.js +3 -2
  133. package/dist/components/journey.js +4 -3
  134. package/dist/components/language-switch.d.ts +59 -0
  135. package/dist/components/language-switch.js +10 -0
  136. package/dist/components/language-switch.js.map +1 -0
  137. package/dist/components/layout.d.ts +8 -2
  138. package/dist/components/layout.js +3 -2
  139. package/dist/components/link.js +4 -3
  140. package/dist/components/list.js +3 -2
  141. package/dist/components/media.js +3 -2
  142. package/dist/components/meter.d.ts +112 -0
  143. package/dist/components/meter.js +13 -0
  144. package/dist/components/meter.js.map +1 -0
  145. package/dist/components/navigation.d.ts +52 -0
  146. package/dist/components/navigation.js +4 -3
  147. package/dist/components/page.d.ts +13 -8
  148. package/dist/components/page.js +3 -2
  149. package/dist/components/price.js +3 -2
  150. package/dist/components/progress.d.ts +16 -2
  151. package/dist/components/progress.js +3 -2
  152. package/dist/components/radio-group.js +4 -3
  153. package/dist/components/redaction.d.ts +51 -0
  154. package/dist/components/redaction.js +10 -0
  155. package/dist/components/redaction.js.map +1 -0
  156. package/dist/components/rows.d.ts +28 -0
  157. package/dist/components/rows.js +7 -3
  158. package/dist/components/select.d.ts +6 -0
  159. package/dist/components/select.js +4 -3
  160. package/dist/components/shell.js +4 -3
  161. package/dist/components/source.d.ts +68 -0
  162. package/dist/components/source.js +10 -0
  163. package/dist/components/source.js.map +1 -0
  164. package/dist/components/status-pill-style.d.ts +16 -0
  165. package/dist/components/status-pill-style.js +15 -0
  166. package/dist/components/status-pill-style.js.map +1 -0
  167. package/dist/components/status.d.ts +66 -0
  168. package/dist/components/status.js +10 -0
  169. package/dist/components/status.js.map +1 -0
  170. package/dist/components/summary-list.js +3 -2
  171. package/dist/components/switch.js +4 -3
  172. package/dist/components/table.d.ts +19 -0
  173. package/dist/components/table.js +4 -3
  174. package/dist/components/text-input.js +5 -4
  175. package/dist/components/textarea.d.ts +5 -0
  176. package/dist/components/textarea.js +4 -3
  177. package/dist/components/tool-card.d.ts +107 -0
  178. package/dist/components/tool-card.js +11 -0
  179. package/dist/components/tool-card.js.map +1 -0
  180. package/dist/components/tool-kit-tokens.d.ts +25 -0
  181. package/dist/components/tool-kit-tokens.js +8 -0
  182. package/dist/components/tool-kit-tokens.js.map +1 -0
  183. package/dist/index.d.ts +11 -0
  184. package/dist/index.js +116 -70
  185. package/dist/standalone/atomic-ui.js +2030 -692
  186. package/dist/standalone/atomic-ui.js.map +4 -4
  187. package/package.json +2 -2
  188. package/dist/chunk-2D2IMQII.js.map +0 -1
  189. package/dist/chunk-2EP3IV3G.js.map +0 -1
  190. package/dist/chunk-2ZF3J7OO.js.map +0 -1
  191. package/dist/chunk-3T7J66Z2.js.map +0 -1
  192. package/dist/chunk-7UWJXPR3.js +0 -97
  193. package/dist/chunk-7UWJXPR3.js.map +0 -1
  194. package/dist/chunk-A4M3A4SZ.js.map +0 -1
  195. package/dist/chunk-AURT72IC.js.map +0 -1
  196. package/dist/chunk-AYKYHZGQ.js +0 -108
  197. package/dist/chunk-AYKYHZGQ.js.map +0 -1
  198. package/dist/chunk-D6NET2VB.js.map +0 -1
  199. package/dist/chunk-DN5YZFSG.js.map +0 -1
  200. package/dist/chunk-MLKNZL5J.js.map +0 -1
  201. package/dist/chunk-MOO63SHZ.js.map +0 -1
  202. package/dist/chunk-OJO62KRX.js.map +0 -1
  203. package/dist/chunk-ONED3PUB.js.map +0 -1
  204. package/dist/chunk-OZGKK3N5.js.map +0 -1
  205. package/dist/chunk-QU3U2CS2.js +0 -144
  206. package/dist/chunk-QU3U2CS2.js.map +0 -1
  207. package/dist/chunk-TJOYBDKS.js.map +0 -1
  208. package/dist/chunk-UFPI4I2Y.js.map +0 -1
  209. package/dist/chunk-V7EB7Q2M.js.map +0 -1
  210. package/dist/chunk-ZEIV5X3U.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/components/icon.ts"],"sourcesContent":["import { css, html, nothing, svg, type SVGTemplateResult, type TemplateResult } from 'lit';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { t } from '../base/tokens';\n\n/**\n * The icons the library draws, each on a 24 by 24 grid in strokes of the\n * current text colour. Kept to a set the components need and editors reach\n * for, so an icon always matches the line weight of the ones beside it.\n */\nexport const ICONS = {\n 'arrow-right': svg`<path d=\"M5 12h14M13 6l6 6-6 6\"/>`,\n 'arrow-left': svg`<path d=\"M19 12H5M11 6l-6 6 6 6\"/>`,\n 'chevron-right': svg`<path d=\"M9 6l6 6-6 6\"/>`,\n 'chevron-down': svg`<path d=\"M6 9l6 6 6-6\"/>`,\n check: svg`<path d=\"M5 12.5l4.5 4.5L19 7\"/>`,\n close: svg`<path d=\"M6 6l12 12M18 6L6 18\"/>`,\n menu: svg`<path d=\"M4 7h16M4 12h16M4 17h16\"/>`,\n /** Two lines: a menu drawn quieter, as a round icon button. */\n 'menu-two': svg`<path d=\"M5 9.5h14M5 14.5h14\"/>`,\n plus: svg`<path d=\"M12 5v14M5 12h14\"/>`,\n minus: svg`<path d=\"M5 12h14\"/>`,\n search: svg`<circle cx=\"11\" cy=\"11\" r=\"6.5\"/><path d=\"M16 16l4 4\"/>`,\n external: svg`<path d=\"M14 4h6v6M20 4l-9 9M18 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h5\"/>`,\n download: svg`<path d=\"M12 4v11M7 10l5 5 5-5M5 20h14\"/>`,\n home: svg`<path d=\"M4 11l8-7 8 7M6 9.5V20h12V9.5\"/><path d=\"M10 20v-6h4v6\"/>`,\n phone: svg`<path d=\"M7 3.5h3l1.5 4-2 1.5a11 11 0 0 0 5.5 5.5l1.5-2 4 1.5v3a2 2 0 0 1-2 2A16 16 0 0 1 5 5.5a2 2 0 0 1 2-2z\"/>`,\n mail: svg`<rect x=\"3.5\" y=\"5.5\" width=\"17\" height=\"13\" rx=\"1.5\"/><path d=\"M4 7l8 6 8-6\"/>`,\n 'map-pin': svg`<path d=\"M12 21s-6.5-6-6.5-11a6.5 6.5 0 0 1 13 0c0 5-6.5 11-6.5 11z\"/><circle cx=\"12\" cy=\"10\" r=\"2.5\"/>`,\n calendar: svg`<rect x=\"4\" y=\"5.5\" width=\"16\" height=\"14.5\" rx=\"1.5\"/><path d=\"M4 10h16M8.5 3.5v4M15.5 3.5v4\"/>`,\n clock: svg`<circle cx=\"12\" cy=\"12\" r=\"8.5\"/><path d=\"M12 7.5V12l3 2\"/>`,\n user: svg`<circle cx=\"12\" cy=\"8.5\" r=\"3.5\"/><path d=\"M5 20a7 7 0 0 1 14 0\"/>`,\n star: svg`<path d=\"M12 4l2.4 5 5.4.6-4 3.7 1.1 5.4L12 16l-4.9 2.7 1.1-5.4-4-3.7 5.4-.6z\"/>`,\n heart: svg`<path d=\"M12 19.5s-7.5-4.6-7.5-10A4 4 0 0 1 12 7a4 4 0 0 1 7.5 2.5c0 5.4-7.5 10-7.5 10z\"/>`,\n shield: svg`<path d=\"M12 3.5l7 2.5v5.5c0 4.5-3 7.8-7 9-4-1.2-7-4.5-7-9V6z\"/><path d=\"M9 12l2 2 4-4\"/>`,\n leaf: svg`<path d=\"M5 19c0-8 5-13 14-14 0 9-5 14-13 14z\"/><path d=\"M5 19l7-7\"/>`,\n sun: svg`<circle cx=\"12\" cy=\"12\" r=\"3.5\"/><path d=\"M12 3v2M12 19v2M3 12h2M19 12h2M5.6 5.6L7 7M17 17l1.4 1.4M5.6 18.4L7 17M17 7l1.4-1.4\"/>`,\n bolt: svg`<path d=\"M13 3L5 13.5h6L10 21l8-10.5h-6z\"/>`,\n key: svg`<circle cx=\"8\" cy=\"15\" r=\"3.5\"/><path d=\"M10.5 12.5L19 4M16 7l2.5 2.5M14 9l2 2\"/>`,\n info: svg`<circle cx=\"12\" cy=\"12\" r=\"8.5\"/><path d=\"M12 11v5.5M12 7.5v.5\"/>`,\n warning: svg`<path d=\"M12 4l9 15.5H3z\"/><path d=\"M12 10v4M12 16.5v.5\"/>`,\n document: svg`<path d=\"M6 3.5h8l4 4V20a.5.5 0 0 1-.5.5h-11A.5.5 0 0 1 6 20z\"/><path d=\"M14 3.5V8h4M9 13h6M9 16.5h6\"/>`,\n pound: svg`<path d=\"M16 6.5a3.5 3.5 0 0 0-6.5 1.8V20M7 13h7M7 20h10\"/>`,\n chat: svg`<path d=\"M4.5 5.5h15v10h-9l-4 3.5v-3.5h-2z\"/>`,\n /** Product navigation and actions, drawn to Lucide's shapes so they sit beside its line weight. */\n grid: svg`<rect x=\"3\" y=\"3\" width=\"7\" height=\"7\" rx=\"1\"/><rect x=\"14\" y=\"3\" width=\"7\" height=\"7\" rx=\"1\"/><rect x=\"14\" y=\"14\" width=\"7\" height=\"7\" rx=\"1\"/><rect x=\"3\" y=\"14\" width=\"7\" height=\"7\" rx=\"1\"/>`,\n clipboard: svg`<rect x=\"8\" y=\"2\" width=\"8\" height=\"4\" rx=\"1\"/><path d=\"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2M12 11h4M12 16h4M8 11h.01M8 16h.01\"/>`,\n 'map-pinned': svg`<path d=\"M18 8c0 3.6-3.9 7.4-5.4 8.8a1 1 0 0 1-1.2 0C9.9 15.4 6 11.6 6 8a6 6 0 0 1 12 0\"/><circle cx=\"12\" cy=\"8\" r=\"2\"/><path d=\"M8.7 14H5a1 1 0 0 0-.9.7l-2 6A1 1 0 0 0 3 22h18a1 1 0 0 0 .9-1.3l-2-6a1 1 0 0 0-.9-.7h-3.7\"/>`,\n users: svg`<path d=\"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2\"/><circle cx=\"9\" cy=\"7\" r=\"4\"/><path d=\"M22 21v-2a4 4 0 0 0-3-3.9M16 3.1a4 4 0 0 1 0 7.8\"/>`,\n radio: svg`<path d=\"M4.9 19.1C1 15.2 1 8.8 4.9 4.9M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5M19.1 4.9C23 8.8 23 15.1 19.1 19\"/><circle cx=\"12\" cy=\"12\" r=\"2\"/>`,\n settings: svg`<path d=\"M12.2 2h-.4a2 2 0 0 0-2 2v.2a2 2 0 0 1-1 1.7l-.4.3a2 2 0 0 1-2 0l-.2-.1a2 2 0 0 0-2.7.7l-.2.4a2 2 0 0 0 .7 2.7l.2.1a2 2 0 0 1 1 1.7v.5a2 2 0 0 1-1 1.8l-.2.1a2 2 0 0 0-.7 2.7l.2.4a2 2 0 0 0 2.7.7l.2-.1a2 2 0 0 1 2 0l.4.3a2 2 0 0 1 1 1.7v.2a2 2 0 0 0 2 2h.4a2 2 0 0 0 2-2v-.2a2 2 0 0 1 1-1.7l.4-.3a2 2 0 0 1 2 0l.2.1a2 2 0 0 0 2.7-.7l.2-.4a2 2 0 0 0-.7-2.7l-.2-.1a2 2 0 0 1-1-1.8v-.5a2 2 0 0 1 1-1.7l.2-.1a2 2 0 0 0 .7-2.7l-.2-.4a2 2 0 0 0-2.7-.7l-.2.1a2 2 0 0 1-2 0l-.4-.3a2 2 0 0 1-1-1.7V4a2 2 0 0 0-2-2z\"/><circle cx=\"12\" cy=\"12\" r=\"3\"/>`,\n 'log-out': svg`<path d=\"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4M16 17l5-5-5-5M21 12H9\"/>`,\n 'arrow-up-right': svg`<path d=\"M7 7h10v10M7 17L17 7\"/>`,\n more: svg`<circle cx=\"5\" cy=\"12\" r=\"1\"/><circle cx=\"12\" cy=\"12\" r=\"1\"/><circle cx=\"19\" cy=\"12\" r=\"1\"/>`,\n upload: svg`<path d=\"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4M17 8l-5-5-5 5M12 3v12\"/>`,\n image: svg`<rect x=\"3\" y=\"3\" width=\"18\" height=\"18\" rx=\"2\"/><circle cx=\"9\" cy=\"9\" r=\"2\"/><path d=\"M21 15l-3.1-3.1a2 2 0 0 0-2.8 0L6 21\"/>`,\n lock: svg`<rect x=\"3\" y=\"11\" width=\"18\" height=\"11\" rx=\"2\"/><path d=\"M7 11V7a5 5 0 0 1 10 0v4\"/>`,\n eye: svg`<path d=\"M2.1 12.3a1 1 0 0 1 0-.7 10.8 10.8 0 0 1 19.8 0 1 1 0 0 1 0 .7 10.8 10.8 0 0 1-19.8 0\"/><circle cx=\"12\" cy=\"12\" r=\"3\"/>`,\n trash: svg`<path d=\"M3 6h18M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2M10 11v6M14 11v6\"/>`,\n pencil: svg`<path d=\"M21.2 6.8a1 1 0 0 0-4-4L3.8 16.2a2 2 0 0 0-.5.8L2 21.4a.5.5 0 0 0 .6.6l4.4-1.3a2 2 0 0 0 .8-.5zM15 5l4 4\"/>`,\n 'qr-code': svg`<rect x=\"3\" y=\"3\" width=\"5\" height=\"5\" rx=\"1\"/><rect x=\"16\" y=\"3\" width=\"5\" height=\"5\" rx=\"1\"/><rect x=\"3\" y=\"16\" width=\"5\" height=\"5\" rx=\"1\"/><path d=\"M21 16h-3a2 2 0 0 0-2 2v3M21 21v.01M12 7v3a2 2 0 0 1-2 2H7M3 12h.01M12 3h.01M12 16v.01M16 12h1M21 12v.01M12 21v-1\"/>`,\n battery: svg`<rect x=\"2\" y=\"7\" width=\"16\" height=\"10\" rx=\"2\"/><path d=\"M22 11v2M6 11v2M10 11v2\"/>`,\n} as const satisfies Record<string, SVGTemplateResult>;\n\nexport type IconName = keyof typeof ICONS;\nexport const ICON_NAMES = Object.keys(ICONS) as IconName[];\n\n/** An icon as markup, for components that draw one beside their own words. Always decorative. */\nexport function iconSvg(name: string | undefined, size = '1.25em'): TemplateResult | typeof nothing {\n const shape = name ? ICONS[name as IconName] : undefined;\n if (!shape) return nothing;\n return html`<svg class=\"icon\" viewBox=\"0 0 24 24\" width=${size} height=${size} fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.75\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\" focusable=\"false\">${shape}</svg>`;\n}\n\n/**\n * A small picture that stands for something: a phone beside a number, a tick\n * beside a benefit.\n *\n * **An icon is decorative unless it is labelled.** With no `label` it is\n * hidden from screen readers, because the words beside it already say what it\n * means. Give it a label only when it stands alone and carries meaning (1.1.1).\n *\n * @category media\n * @icon star\n */\nexport class ImpaktIcon extends ImpaktElement {\n static properties = {\n name: { type: String, reflect: true },\n label: { type: String },\n size: { type: String, reflect: true },\n tone: { type: String, reflect: true },\n };\n /** Which icon. */\n declare name:\n | 'arrow-right'\n | 'arrow-left'\n | 'chevron-right'\n | 'chevron-down'\n | 'check'\n | 'close'\n | 'menu'\n | 'plus'\n | 'minus'\n | 'search'\n | 'external'\n | 'download'\n | 'home'\n | 'phone'\n | 'mail'\n | 'map-pin'\n | 'calendar'\n | 'clock'\n | 'user'\n | 'star'\n | 'heart'\n | 'shield'\n | 'leaf'\n | 'sun'\n | 'bolt'\n | 'key'\n | 'info'\n | 'warning'\n | 'document'\n | 'pound'\n | 'chat'\n | 'grid'\n | 'clipboard'\n | 'map-pinned'\n | 'users'\n | 'radio'\n | 'settings'\n | 'log-out'\n | 'arrow-up-right'\n | 'more'\n | 'upload'\n | 'image'\n | 'lock'\n | 'eye'\n | 'trash'\n | 'pencil'\n | 'qr-code'\n | 'battery';\n /** What the icon means, when it stands alone. Leave empty when words beside it say the same. */\n declare label: string;\n declare size: 'sm' | 'md' | 'lg' | 'xl';\n /** The icon's colour. */\n declare tone: 'inherit' | 'brand' | 'muted';\n\n constructor() {\n super();\n this.name = 'star';\n this.label = '';\n this.size = 'md';\n this.tone = 'inherit';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n css`\n :host { display: inline-flex; vertical-align: middle; line-height: 0; }\n :host([tone='brand']) { color: ${t.brand}; }\n :host([tone='muted']) { color: ${t.textMuted}; }\n @media (forced-colors: active) { :host { color: CanvasText; } }\n `,\n ];\n\n render(): TemplateResult {\n const size = { sm: '16px', md: '24px', lg: '32px', xl: '48px' }[this.size] ?? '24px';\n const drawn = iconSvg(this.name, size);\n return this.label ? html`<span role=\"img\" aria-label=${this.label}>${drawn}</span>` : html`${drawn}`;\n }\n}\n\ncustomElements.define('impakt-icon', ImpaktIcon);\ndeclare global {\n interface HTMLElementTagNameMap {\n 'impakt-icon': ImpaktIcon;\n }\n}\n"],"mappings":";;;;;;AAAA,SAAS,KAAK,MAAM,SAAS,WAAwD;AAS9E,IAAM,QAAQ;AAAA,EACnB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,iBAAiB;AAAA,EACjB,gBAAgB;AAAA,EAChB,OAAO;AAAA,EACP,OAAO;AAAA,EACP,MAAM;AAAA;AAAA,EAEN,YAAY;AAAA,EACZ,MAAM;AAAA,EACN,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,UAAU;AAAA,EACV,UAAU;AAAA,EACV,MAAM;AAAA,EACN,OAAO;AAAA,EACP,MAAM;AAAA,EACN,WAAW;AAAA,EACX,UAAU;AAAA,EACV,OAAO;AAAA,EACP,MAAM;AAAA,EACN,MAAM;AAAA,EACN,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,KAAK;AAAA,EACL,MAAM;AAAA,EACN,KAAK;AAAA,EACL,MAAM;AAAA,EACN,SAAS;AAAA,EACT,UAAU;AAAA,EACV,OAAO;AAAA,E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,KAAK,QAAQ,mCAAmC,KAAK,KAAK,IAAI,KAAK,YAAY,OAAO,KAAK;AAAA,EACpG;AACF;AAEA,eAAe,OAAO,eAAe,UAAU;","names":[]}
1
+ {"version":3,"sources":["../src/components/icon.ts"],"sourcesContent":["import { css, html, nothing, svg, type SVGTemplateResult, type TemplateResult } from 'lit';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { t } from '../base/tokens';\n\n/**\n * The icons the library draws, each on a 24 by 24 grid in strokes of the\n * current text colour. Kept to a set the components need and editors reach\n * for, so an icon always matches the line weight of the ones beside it.\n */\nexport const ICONS = {\n 'arrow-right': svg`<path d=\"M5 12h14M13 6l6 6-6 6\"/>`,\n 'arrow-left': svg`<path d=\"M19 12H5M11 6l-6 6 6 6\"/>`,\n 'chevron-right': svg`<path d=\"M9 6l6 6-6 6\"/>`,\n 'chevron-down': svg`<path d=\"M6 9l6 6 6-6\"/>`,\n check: svg`<path d=\"M5 12.5l4.5 4.5L19 7\"/>`,\n close: svg`<path d=\"M6 6l12 12M18 6L6 18\"/>`,\n menu: svg`<path d=\"M4 7h16M4 12h16M4 17h16\"/>`,\n /** Two lines: a menu drawn quieter, as a round icon button. */\n 'menu-two': svg`<path d=\"M5 9.5h14M5 14.5h14\"/>`,\n plus: svg`<path d=\"M12 5v14M5 12h14\"/>`,\n minus: svg`<path d=\"M5 12h14\"/>`,\n search: svg`<circle cx=\"11\" cy=\"11\" r=\"6.5\"/><path d=\"M16 16l4 4\"/>`,\n external: svg`<path d=\"M14 4h6v6M20 4l-9 9M18 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h5\"/>`,\n download: svg`<path d=\"M12 4v11M7 10l5 5 5-5M5 20h14\"/>`,\n home: svg`<path d=\"M4 11l8-7 8 7M6 9.5V20h12V9.5\"/><path d=\"M10 20v-6h4v6\"/>`,\n phone: svg`<path d=\"M7 3.5h3l1.5 4-2 1.5a11 11 0 0 0 5.5 5.5l1.5-2 4 1.5v3a2 2 0 0 1-2 2A16 16 0 0 1 5 5.5a2 2 0 0 1 2-2z\"/>`,\n mail: svg`<rect x=\"3.5\" y=\"5.5\" width=\"17\" height=\"13\" rx=\"1.5\"/><path d=\"M4 7l8 6 8-6\"/>`,\n 'map-pin': svg`<path d=\"M12 21s-6.5-6-6.5-11a6.5 6.5 0 0 1 13 0c0 5-6.5 11-6.5 11z\"/><circle cx=\"12\" cy=\"10\" r=\"2.5\"/>`,\n calendar: svg`<rect x=\"4\" y=\"5.5\" width=\"16\" height=\"14.5\" rx=\"1.5\"/><path d=\"M4 10h16M8.5 3.5v4M15.5 3.5v4\"/>`,\n clock: svg`<circle cx=\"12\" cy=\"12\" r=\"8.5\"/><path d=\"M12 7.5V12l3 2\"/>`,\n user: svg`<circle cx=\"12\" cy=\"8.5\" r=\"3.5\"/><path d=\"M5 20a7 7 0 0 1 14 0\"/>`,\n star: svg`<path d=\"M12 4l2.4 5 5.4.6-4 3.7 1.1 5.4L12 16l-4.9 2.7 1.1-5.4-4-3.7 5.4-.6z\"/>`,\n heart: svg`<path d=\"M12 19.5s-7.5-4.6-7.5-10A4 4 0 0 1 12 7a4 4 0 0 1 7.5 2.5c0 5.4-7.5 10-7.5 10z\"/>`,\n shield: svg`<path d=\"M12 3.5l7 2.5v5.5c0 4.5-3 7.8-7 9-4-1.2-7-4.5-7-9V6z\"/><path d=\"M9 12l2 2 4-4\"/>`,\n leaf: svg`<path d=\"M5 19c0-8 5-13 14-14 0 9-5 14-13 14z\"/><path d=\"M5 19l7-7\"/>`,\n sun: svg`<circle cx=\"12\" cy=\"12\" r=\"3.5\"/><path d=\"M12 3v2M12 19v2M3 12h2M19 12h2M5.6 5.6L7 7M17 17l1.4 1.4M5.6 18.4L7 17M17 7l1.4-1.4\"/>`,\n bolt: svg`<path d=\"M13 3L5 13.5h6L10 21l8-10.5h-6z\"/>`,\n key: svg`<circle cx=\"8\" cy=\"15\" r=\"3.5\"/><path d=\"M10.5 12.5L19 4M16 7l2.5 2.5M14 9l2 2\"/>`,\n info: svg`<circle cx=\"12\" cy=\"12\" r=\"8.5\"/><path d=\"M12 11v5.5M12 7.5v.5\"/>`,\n warning: svg`<path d=\"M12 4l9 15.5H3z\"/><path d=\"M12 10v4M12 16.5v.5\"/>`,\n document: svg`<path d=\"M6 3.5h8l4 4V20a.5.5 0 0 1-.5.5h-11A.5.5 0 0 1 6 20z\"/><path d=\"M14 3.5V8h4M9 13h6M9 16.5h6\"/>`,\n pound: svg`<path d=\"M16 6.5a3.5 3.5 0 0 0-6.5 1.8V20M7 13h7M7 20h10\"/>`,\n chat: svg`<path d=\"M4.5 5.5h15v10h-9l-4 3.5v-3.5h-2z\"/>`,\n /** Product navigation and actions, drawn to Lucide's shapes so they sit beside its line weight. */\n grid: svg`<rect x=\"3\" y=\"3\" width=\"7\" height=\"7\" rx=\"1\"/><rect x=\"14\" y=\"3\" width=\"7\" height=\"7\" rx=\"1\"/><rect x=\"14\" y=\"14\" width=\"7\" height=\"7\" rx=\"1\"/><rect x=\"3\" y=\"14\" width=\"7\" height=\"7\" rx=\"1\"/>`,\n clipboard: svg`<rect x=\"8\" y=\"2\" width=\"8\" height=\"4\" rx=\"1\"/><path d=\"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2M12 11h4M12 16h4M8 11h.01M8 16h.01\"/>`,\n 'map-pinned': svg`<path d=\"M18 8c0 3.6-3.9 7.4-5.4 8.8a1 1 0 0 1-1.2 0C9.9 15.4 6 11.6 6 8a6 6 0 0 1 12 0\"/><circle cx=\"12\" cy=\"8\" r=\"2\"/><path d=\"M8.7 14H5a1 1 0 0 0-.9.7l-2 6A1 1 0 0 0 3 22h18a1 1 0 0 0 .9-1.3l-2-6a1 1 0 0 0-.9-.7h-3.7\"/>`,\n users: svg`<path d=\"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2\"/><circle cx=\"9\" cy=\"7\" r=\"4\"/><path d=\"M22 21v-2a4 4 0 0 0-3-3.9M16 3.1a4 4 0 0 1 0 7.8\"/>`,\n radio: svg`<path d=\"M4.9 19.1C1 15.2 1 8.8 4.9 4.9M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5M19.1 4.9C23 8.8 23 15.1 19.1 19\"/><circle cx=\"12\" cy=\"12\" r=\"2\"/>`,\n settings: svg`<path d=\"M12.2 2h-.4a2 2 0 0 0-2 2v.2a2 2 0 0 1-1 1.7l-.4.3a2 2 0 0 1-2 0l-.2-.1a2 2 0 0 0-2.7.7l-.2.4a2 2 0 0 0 .7 2.7l.2.1a2 2 0 0 1 1 1.7v.5a2 2 0 0 1-1 1.8l-.2.1a2 2 0 0 0-.7 2.7l.2.4a2 2 0 0 0 2.7.7l.2-.1a2 2 0 0 1 2 0l.4.3a2 2 0 0 1 1 1.7v.2a2 2 0 0 0 2 2h.4a2 2 0 0 0 2-2v-.2a2 2 0 0 1 1-1.7l.4-.3a2 2 0 0 1 2 0l.2.1a2 2 0 0 0 2.7-.7l.2-.4a2 2 0 0 0-.7-2.7l-.2-.1a2 2 0 0 1-1-1.8v-.5a2 2 0 0 1 1-1.7l.2-.1a2 2 0 0 0 .7-2.7l-.2-.4a2 2 0 0 0-2.7-.7l-.2.1a2 2 0 0 1-2 0l-.4-.3a2 2 0 0 1-1-1.7V4a2 2 0 0 0-2-2z\"/><circle cx=\"12\" cy=\"12\" r=\"3\"/>`,\n 'log-out': svg`<path d=\"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4M16 17l5-5-5-5M21 12H9\"/>`,\n 'arrow-up-right': svg`<path d=\"M7 7h10v10M7 17L17 7\"/>`,\n more: svg`<circle cx=\"5\" cy=\"12\" r=\"1\"/><circle cx=\"12\" cy=\"12\" r=\"1\"/><circle cx=\"19\" cy=\"12\" r=\"1\"/>`,\n upload: svg`<path d=\"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4M17 8l-5-5-5 5M12 3v12\"/>`,\n image: svg`<rect x=\"3\" y=\"3\" width=\"18\" height=\"18\" rx=\"2\"/><circle cx=\"9\" cy=\"9\" r=\"2\"/><path d=\"M21 15l-3.1-3.1a2 2 0 0 0-2.8 0L6 21\"/>`,\n lock: svg`<rect x=\"3\" y=\"11\" width=\"18\" height=\"11\" rx=\"2\"/><path d=\"M7 11V7a5 5 0 0 1 10 0v4\"/>`,\n eye: svg`<path d=\"M2.1 12.3a1 1 0 0 1 0-.7 10.8 10.8 0 0 1 19.8 0 1 1 0 0 1 0 .7 10.8 10.8 0 0 1-19.8 0\"/><circle cx=\"12\" cy=\"12\" r=\"3\"/>`,\n trash: svg`<path d=\"M3 6h18M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2M10 11v6M14 11v6\"/>`,\n pencil: svg`<path d=\"M21.2 6.8a1 1 0 0 0-4-4L3.8 16.2a2 2 0 0 0-.5.8L2 21.4a.5.5 0 0 0 .6.6l4.4-1.3a2 2 0 0 0 .8-.5zM15 5l4 4\"/>`,\n 'qr-code': svg`<rect x=\"3\" y=\"3\" width=\"5\" height=\"5\" rx=\"1\"/><rect x=\"16\" y=\"3\" width=\"5\" height=\"5\" rx=\"1\"/><rect x=\"3\" y=\"16\" width=\"5\" height=\"5\" rx=\"1\"/><path d=\"M21 16h-3a2 2 0 0 0-2 2v3M21 21v.01M12 7v3a2 2 0 0 1-2 2H7M3 12h.01M12 3h.01M12 16v.01M16 12h1M21 12v.01M12 21v-1\"/>`,\n battery: svg`<rect x=\"2\" y=\"7\" width=\"16\" height=\"10\" rx=\"2\"/><path d=\"M22 11v2M6 11v2M10 11v2\"/>`,\n} as const satisfies Record<string, SVGTemplateResult>;\n\nexport type IconName = keyof typeof ICONS;\nexport const ICON_NAMES = Object.keys(ICONS) as IconName[];\n\n/** An icon as markup, for components that draw one beside their own words. Always decorative. */\nexport function iconSvg(name: string | undefined, size = '1.25em'): TemplateResult | typeof nothing {\n const shape = name ? ICONS[name as IconName] : undefined;\n if (!shape) return nothing;\n return html`<svg class=\"icon\" viewBox=\"0 0 24 24\" width=${size} height=${size} fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.75\" stroke-linecap=\"round\" stroke-linejoin=\"round\" aria-hidden=\"true\" focusable=\"false\">${shape}</svg>`;\n}\n\n/**\n * A small picture that stands for something: a phone beside a number, a tick\n * beside a benefit.\n *\n * **An icon is decorative unless it is labelled.** With no `label` it is\n * hidden from screen readers, because the words beside it already say what it\n * means. Give it a label only when it stands alone and carries meaning (1.1.1).\n *\n * @category media\n * @icon star\n */\nexport class ImpaktIcon extends ImpaktElement {\n static properties = {\n name: { type: String, reflect: true },\n label: { type: String },\n size: { type: String, reflect: true },\n tone: { type: String, reflect: true },\n };\n /** Which icon. */\n declare name:\n | 'arrow-right'\n | 'arrow-left'\n | 'chevron-right'\n | 'chevron-down'\n | 'check'\n | 'close'\n | 'menu'\n | 'plus'\n | 'minus'\n | 'search'\n | 'external'\n | 'download'\n | 'home'\n | 'phone'\n | 'mail'\n | 'map-pin'\n | 'calendar'\n | 'clock'\n | 'user'\n | 'star'\n | 'heart'\n | 'shield'\n | 'leaf'\n | 'sun'\n | 'bolt'\n | 'key'\n | 'info'\n | 'warning'\n | 'document'\n | 'pound'\n | 'chat'\n | 'grid'\n | 'clipboard'\n | 'map-pinned'\n | 'users'\n | 'radio'\n | 'settings'\n | 'log-out'\n | 'arrow-up-right'\n | 'more'\n | 'upload'\n | 'image'\n | 'lock'\n | 'eye'\n | 'trash'\n | 'pencil'\n | 'qr-code'\n | 'battery';\n /** What the icon means, when it stands alone. Leave empty when words beside it say the same. */\n declare label: string;\n declare size: 'sm' | 'md' | 'lg' | 'xl';\n /** The icon's colour. */\n declare tone: 'inherit' | 'brand' | 'muted';\n\n constructor() {\n super();\n this.name = 'star';\n this.label = '';\n this.size = 'md';\n this.tone = 'inherit';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n css`\n :host { display: inline-flex; vertical-align: middle; line-height: 0; }\n :host([tone='brand']) { color: ${t.brand}; }\n :host([tone='muted']) { color: ${t.textMuted}; }\n @media (forced-colors: active) { :host { color: CanvasText; } }\n `,\n ];\n\n render(): TemplateResult {\n const size = { sm: '16px', md: '24px', lg: '32px', xl: '48px' }[this.size] ?? '24px';\n const drawn = iconSvg(this.name, size);\n return this.label ? html`<span role=\"img\" aria-label=${this.label}>${drawn}</span>` : html`${drawn}`;\n }\n}\n\ncustomElements.define('impakt-icon', ImpaktIcon);\ndeclare global {\n interface HTMLElementTagNameMap {\n 'impakt-icon': ImpaktIcon;\n }\n}\n"],"mappings":";;;;;;;;AAAA,SAAS,KAAK,MAAM,SAAS,WAAwD;AAS9E,IAAM,QAAQ;AAAA,EACnB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,iBAAiB;AAAA,EACjB,gBAAgB;AAAA,EAChB,OAAO;AAAA,EACP,OAAO;AAAA,EACP,MAAM;AAAA;AAAA,EAEN,YAAY;AAAA,EACZ,MAAM;AAAA,EACN,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,UAAU;AAAA,EACV,UAAU;AAAA,EACV,MAAM;AAAA,EACN,OAAO;AAAA,EACP,MAAM;AAAA,EACN,WAAW;AAAA,EACX,UAAU;AAAA,EACV,OAAO;AAAA,EACP,MAAM;AAAA,EACN,MAAM;AAAA,EACN,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,KAAK;AAAA,EACL,MAAM;AAAA,EACN,KAAK;AAAA,EACL,MAAM;AAAA,EACN,SAAS;AAAA,EACT,UAAU;AAAA,EACV,OAAO;AAAA,EACP,MAAM;AAAA;AAAA,EAEN,MAAM;AAAA,EACN,WAAW;AAAA,EACX,cAAc;AAAA,EACd,OAAO;AAAA,EACP,OAAO;AAAA,EACP,UAAU;AAAA,EACV,WAAW;AAAA,EACX,kBAAkB;AAAA,EAClB,MAAM;AAAA,EACN,QAAQ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+ import {
5
+ ImpaktElement,
6
+ focusRing
7
+ } from "./chunk-72WNCCDC.js";
8
+ import {
9
+ space,
10
+ t,
11
+ token
12
+ } from "./chunk-JTCTQBAX.js";
13
+
14
+ // packages/ui/src/components/tool-card.ts
15
+ import { css, html, nothing } from "lit";
16
+ var ImpaktToolCard = class extends ImpaktElement {
17
+ static {
18
+ this.properties = {
19
+ name: { type: String },
20
+ description: { type: String },
21
+ status: { type: String },
22
+ statusTone: { type: String, attribute: "status-tone" },
23
+ note: { type: String },
24
+ href: { type: String },
25
+ actionLabel: { type: String, attribute: "action-label" },
26
+ owned: { type: Boolean, reflect: true },
27
+ state: { type: String, reflect: true },
28
+ headingLevel: { type: Number, attribute: "heading-level" },
29
+ comingSoonText: { type: String, attribute: "coming-soon-text" },
30
+ notOpenText: { type: String, attribute: "not-open-text" }
31
+ };
32
+ }
33
+ constructor() {
34
+ super();
35
+ this.name = "";
36
+ this.description = "";
37
+ this.status = "";
38
+ this.statusTone = "ok";
39
+ this.note = "";
40
+ this.href = "";
41
+ this.actionLabel = "";
42
+ this.owned = false;
43
+ this.state = "open";
44
+ this.headingLevel = 3;
45
+ this.comingSoonText = "Coming soon";
46
+ this.notOpenText = "Not open yet.";
47
+ }
48
+ static {
49
+ this.styles = [
50
+ ...ImpaktElement.styles,
51
+ focusRing,
52
+ css`
53
+ :host {
54
+ display: block;
55
+ }
56
+ .card {
57
+ display: flex;
58
+ flex-direction: column;
59
+ gap: ${space(4)};
60
+ block-size: 100%;
61
+ padding: ${space(6)};
62
+ background: ${t.surfaceCard};
63
+ border: 1px solid ${t.text};
64
+ border-radius: 0;
65
+ }
66
+ :host([state='coming-soon']) .card {
67
+ background: ${t.surfaceSubtle};
68
+ }
69
+ .name {
70
+ margin: 0;
71
+ font-family: ${t.fontHeading};
72
+ font-size: 2rem;
73
+ font-weight: ${kit.medium};
74
+ line-height: 1.1;
75
+ letter-spacing: ${t.trackingTight};
76
+ color: ${t.text};
77
+ overflow-wrap: anywhere;
78
+ }
79
+ :host([state='coming-soon']) .name {
80
+ color: ${t.textMuted};
81
+ }
82
+ .description {
83
+ margin: 0;
84
+ color: ${t.textMuted};
85
+ }
86
+ .status {
87
+ display: flex;
88
+ flex-wrap: wrap;
89
+ align-items: center;
90
+ gap: ${space(2)} ${space(2.5)};
91
+ }
92
+ .note {
93
+ font-family: ${t.fontMono};
94
+ font-size: ${kit.small};
95
+ color: ${t.textMuted};
96
+ }
97
+ .muted {
98
+ margin: 0;
99
+ font-size: ${kit.small};
100
+ color: ${t.textMuted};
101
+ }
102
+ .action {
103
+ display: flex;
104
+ align-items: center;
105
+ justify-content: space-between;
106
+ gap: ${space(3)};
107
+ min-block-size: 46px;
108
+ margin-block-start: auto;
109
+ padding: ${space(2.5)} ${space(5)};
110
+ font-family: ${t.fontBody};
111
+ font-size: ${token("font.size.md", "1rem")};
112
+ color: ${t.text};
113
+ background: ${t.surfaceCard};
114
+ border: 1px solid ${t.text};
115
+ border-radius: 0;
116
+ text-decoration: none;
117
+ }
118
+ .action:hover {
119
+ background: ${t.surfaceSubtle};
120
+ }
121
+ :host([owned]) .action {
122
+ color: ${kit.onInverse};
123
+ background: ${kit.inverse};
124
+ }
125
+ :host([owned]) .action:hover {
126
+ background: color-mix(in srgb, ${kit.inverse} 88%, ${kit.onInverse});
127
+ }
128
+ .arrow {
129
+ font-size: 1.25em;
130
+ line-height: 1;
131
+ }
132
+ @media (forced-colors: active) {
133
+ .card,
134
+ .action {
135
+ border-color: CanvasText;
136
+ }
137
+ }
138
+ `
139
+ ];
140
+ }
141
+ renderStatus() {
142
+ if (this.state === "coming-soon")
143
+ return html`<div class="status"><impakt-status tone="neutral">${this.comingSoonText}</impakt-status></div>
144
+ <p class="muted">${this.notOpenText}</p>`;
145
+ if (!this.status && !this.note) return nothing;
146
+ return html`<div class="status">
147
+ ${this.status ? html`<impakt-status tone=${this.statusTone}>${this.status}</impakt-status>` : nothing}
148
+ ${this.note ? html`<span class="note">${this.note}</span>` : nothing}
149
+ </div>`;
150
+ }
151
+ render() {
152
+ const level = Math.min(6, Math.max(2, Number(this.headingLevel) || 3));
153
+ const action = this.actionLabel || `Open ${this.name}`;
154
+ return html`<article class="card" part="card" aria-labelledby=${this.id_("name")}>
155
+ <div class="name" role="heading" aria-level=${level} id=${this.id_("name")}>${this.name}</div>
156
+ ${this.description ? html`<p class="description">${this.description}</p>` : nothing}
157
+ ${this.renderStatus()}
158
+ ${this.state !== "coming-soon" && this.href ? html`<a class="action" part="action" href=${this.href}><span>${action}</span><span class="arrow" aria-hidden="true">→</span></a>` : nothing}
159
+ </article>`;
160
+ }
161
+ };
162
+ customElements.define("impakt-tool-card", ImpaktToolCard);
163
+
164
+ export {
165
+ ImpaktToolCard
166
+ };
167
+ //# sourceMappingURL=chunk-5PRB7P7N.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/tool-card.ts"],"sourcesContent":["/**\n * A tool on the account home: its name, what it does, where it stands, and the way in.\n */\nimport { css, html, nothing, type TemplateResult } from 'lit';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { focusRing } from '../base/styles';\nimport { space, t, token } from '../base/tokens';\nimport { kit } from './tool-kit-tokens';\nimport type { StatusTone } from './status';\nimport './status';\n\n/**\n * One tool on the account home: a large name, one line on what it does, a\n * status pill, and a full-width button into it.\n *\n * A tool the organisation has bought (`owned`) has the primary ink button and\n * a status such as \"Monitoring · 1 site\". One it has not bought has the\n * outline button, a neutral \"Nothing bought yet\" pill and a price line such as\n * \"From £59 a dispute\". A tool that is not open yet (`state=\"coming-soon\"`) is\n * drawn on the soft surface with a muted name, a \"Coming soon\" pill and \"Not\n * open yet.\", and has no link at all, so there is nothing to press that leads\n * nowhere.\n *\n * The name is a heading; set `heading-level` to fit the page round it.\n *\n * Figma: Account home `53:708`.\n *\n * @category content\n * @icon card\n * @csspart card - The card.\n * @csspart action - The button into the tool.\n */\nexport class ImpaktToolCard extends ImpaktElement {\n static properties = {\n name: { type: String },\n description: { type: String },\n status: { type: String },\n statusTone: { type: String, attribute: 'status-tone' },\n note: { type: String },\n href: { type: String },\n actionLabel: { type: String, attribute: 'action-label' },\n owned: { type: Boolean, reflect: true },\n state: { type: String, reflect: true },\n headingLevel: { type: Number, attribute: 'heading-level' },\n comingSoonText: { type: String, attribute: 'coming-soon-text' },\n notOpenText: { type: String, attribute: 'not-open-text' },\n };\n\n /** The tool's name, such as \"Accessibility\". */\n declare name: string;\n /** One line on what it does. */\n declare description: string;\n /** The words of the status pill: \"Monitoring · 1 site\", \"Nothing bought yet\". */\n declare status: string;\n /** The pill's tone. `ok` for a tool in use, `neutral` for one not bought. */\n declare statusTone: StatusTone;\n /** A mono line after the pill, such as a price: \"From £59 a dispute\". */\n declare note: string;\n /** Where the tool opens. */\n declare href: string;\n /** The button's words. \"Open\" and the tool's name when empty. */\n declare actionLabel: string;\n /** The organisation has this tool: the button is the primary ink one. */\n declare owned: boolean;\n /** `open`, or `coming-soon` for a tool with no way in yet. */\n declare state: 'open' | 'coming-soon';\n declare headingLevel: 2 | 3 | 4 | 5 | 6;\n /** The pill on a tool that is not open yet. */\n declare comingSoonText: string;\n /** The line under that pill. */\n declare notOpenText: string;\n\n constructor() {\n super();\n this.name = '';\n this.description = '';\n this.status = '';\n this.statusTone = 'ok';\n this.note = '';\n this.href = '';\n this.actionLabel = '';\n this.owned = false;\n this.state = 'open';\n this.headingLevel = 3;\n this.comingSoonText = 'Coming soon';\n this.notOpenText = 'Not open yet.';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n css`\n :host {\n display: block;\n }\n .card {\n display: flex;\n flex-direction: column;\n gap: ${space(4)};\n block-size: 100%;\n padding: ${space(6)};\n background: ${t.surfaceCard};\n border: 1px solid ${t.text};\n border-radius: 0;\n }\n :host([state='coming-soon']) .card {\n background: ${t.surfaceSubtle};\n }\n .name {\n margin: 0;\n font-family: ${t.fontHeading};\n font-size: 2rem;\n font-weight: ${kit.medium};\n line-height: 1.1;\n letter-spacing: ${t.trackingTight};\n color: ${t.text};\n overflow-wrap: anywhere;\n }\n :host([state='coming-soon']) .name {\n color: ${t.textMuted};\n }\n .description {\n margin: 0;\n color: ${t.textMuted};\n }\n .status {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: ${space(2)} ${space(2.5)};\n }\n .note {\n font-family: ${t.fontMono};\n font-size: ${kit.small};\n color: ${t.textMuted};\n }\n .muted {\n margin: 0;\n font-size: ${kit.small};\n color: ${t.textMuted};\n }\n .action {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: ${space(3)};\n min-block-size: 46px;\n margin-block-start: auto;\n padding: ${space(2.5)} ${space(5)};\n font-family: ${t.fontBody};\n font-size: ${token('font.size.md', '1rem')};\n color: ${t.text};\n background: ${t.surfaceCard};\n border: 1px solid ${t.text};\n border-radius: 0;\n text-decoration: none;\n }\n .action:hover {\n background: ${t.surfaceSubtle};\n }\n :host([owned]) .action {\n color: ${kit.onInverse};\n background: ${kit.inverse};\n }\n :host([owned]) .action:hover {\n background: color-mix(in srgb, ${kit.inverse} 88%, ${kit.onInverse});\n }\n .arrow {\n font-size: 1.25em;\n line-height: 1;\n }\n @media (forced-colors: active) {\n .card,\n .action {\n border-color: CanvasText;\n }\n }\n `,\n ];\n\n private renderStatus(): TemplateResult | typeof nothing {\n if (this.state === 'coming-soon')\n return html`<div class=\"status\"><impakt-status tone=\"neutral\">${this.comingSoonText}</impakt-status></div>\n <p class=\"muted\">${this.notOpenText}</p>`;\n if (!this.status && !this.note) return nothing;\n return html`<div class=\"status\">\n ${this.status ? html`<impakt-status tone=${this.statusTone}>${this.status}</impakt-status>` : nothing}\n ${this.note ? html`<span class=\"note\">${this.note}</span>` : nothing}\n </div>`;\n }\n\n render(): TemplateResult {\n const level = Math.min(6, Math.max(2, Number(this.headingLevel) || 3));\n const action = this.actionLabel || `Open ${this.name}`;\n return html`<article class=\"card\" part=\"card\" aria-labelledby=${this.id_('name')}>\n <div class=\"name\" role=\"heading\" aria-level=${level} id=${this.id_('name')}>${this.name}</div>\n ${this.description ? html`<p class=\"description\">${this.description}</p>` : nothing}\n ${this.renderStatus()}\n ${\n this.state !== 'coming-soon' && this.href\n ? html`<a class=\"action\" part=\"action\" href=${this.href}><span>${action}</span><span class=\"arrow\" aria-hidden=\"true\">→</span></a>`\n : nothing\n }\n </article>`;\n }\n}\n\ncustomElements.define('impakt-tool-card', ImpaktToolCard);\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'impakt-tool-card': ImpaktToolCard;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AAGA,SAAS,KAAK,MAAM,eAAoC;AA6BjD,IAAM,iBAAN,cAA6B,cAAc;AAAA,EAChD;AAAA,SAAO,aAAa;AAAA,MAClB,MAAM,EAAE,MAAM,OAAO;AAAA,MACrB,aAAa,EAAE,MAAM,OAAO;AAAA,MAC5B,QAAQ,EAAE,MAAM,OAAO;AAAA,MACvB,YAAY,EAAE,MAAM,QAAQ,WAAW,cAAc;AAAA,MACrD,MAAM,EAAE,MAAM,OAAO;AAAA,MACrB,MAAM,EAAE,MAAM,OAAO;AAAA,MACrB,aAAa,EAAE,MAAM,QAAQ,WAAW,eAAe;AAAA,MACvD,OAAO,EAAE,MAAM,SAAS,SAAS,KAAK;AAAA,MACtC,OAAO,EAAE,MAAM,QAAQ,SAAS,KAAK;AAAA,MACrC,cAAc,EAAE,MAAM,QAAQ,WAAW,gBAAgB;AAAA,MACzD,gBAAgB,EAAE,MAAM,QAAQ,WAAW,mBAAmB;AAAA,MAC9D,aAAa,EAAE,MAAM,QAAQ,WAAW,gBAAgB;AAAA,IAC1D;AAAA;AAAA,EA0BA,cAAc;AACZ,UAAM;AACN,SAAK,OAAO;AACZ,SAAK,cAAc;AACnB,SAAK,SAAS;AACd,SAAK,aAAa;AAClB,SAAK,OAAO;AACZ,SAAK,OAAO;AACZ,SAAK,cAAc;AACnB,SAAK,QAAQ;AACb,SAAK,QAAQ;AACb,SAAK,eAAe;AACpB,SAAK,iBAAiB;AACtB,SAAK,cAAc;A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AAAA;AAAA;AAAA;AAAA,IAaxE;AAAA;AAAA,EAEQ,eAAgD;AACtD,QAAI,KAAK,UAAU;AACjB,aAAO,yDAAyD,KAAK,cAAc;AAAA,2BAC9D,KAAK,WAAW;AACvC,QAAI,CAAC,KAAK,UAAU,CAAC,KAAK,KAAM,QAAO;AACvC,WAAO;AAAA,QACH,KAAK,SAAS,2BAA2B,KAAK,UAAU,IAAI,KAAK,MAAM,qBAAqB,OAAO;AAAA,QACnG,KAAK,OAAO,0BAA0B,KAAK,IAAI,YAAY,OAAO;AAAA;AAAA,EAExE;AAAA,EAEA,SAAyB;AACvB,UAAM,QAAQ,KAAK,IAAI,GAAG,KAAK,IAAI,GAAG,OAAO,KAAK,YAAY,KAAK,CAAC,CAAC;AACrE,UAAM,SAAS,KAAK,eAAe,QAAQ,KAAK,IAAI;AACpD,WAAO,yDAAyD,KAAK,IAAI,MAAM,CAAC;AAAA,oDAChC,KAAK,OAAO,KAAK,IAAI,MAAM,CAAC,IAAI,KAAK,IAAI;AAAA,QACrF,KAAK,cAAc,8BAA8B,KAAK,WAAW,SAAS,OAAO;AAAA,QACjF,KAAK,aAAa,CAAC;AAAA,QAEnB,KAAK,UAAU,iBAAiB,KAAK,OACjC,4CAA4C,KAAK,IAAI,UAAU,MAAM,+DACrE,OACN;AAAA;AAAA,EAEJ;AACF;AAEA,eAAe,OAAO,oBAAoB,cAAc;","names":[]}
@@ -0,0 +1,21 @@
1
+ // packages/ui/src/components/status-pill-style.ts
2
+ import { css, html, nothing } from "lit";
3
+ var STATUS_TONES = ["ok", "bad", "warn", "info", "neutral", "solid"];
4
+ var statusPillStyles = css`
5
+ .status-pill {
6
+ flex: none;
7
+ inline-size: fit-content;
8
+ }
9
+ `;
10
+ var statusPill = (text, tone, part = "status") => {
11
+ if (!text) return nothing;
12
+ const known = STATUS_TONES.includes(tone) ? tone : "neutral";
13
+ return html`<impakt-status class="status-pill" part=${part} tone=${known} label=${text}></impakt-status>`;
14
+ };
15
+
16
+ export {
17
+ STATUS_TONES,
18
+ statusPillStyles,
19
+ statusPill
20
+ };
21
+ //# sourceMappingURL=chunk-6CDQSHVW.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/status-pill-style.ts"],"sourcesContent":["/**\n * The G2 status pill inside another element's shadow root: the summary tile\n * and the accordion draw one with `statusPill(text, tone)`.\n *\n * The pill itself is `impakt-status`, so there is one drawing of it. This only\n * places it, and says nothing when there are no words. The word carries the\n * status, so it never rests on the dot's colour alone (1.4.1).\n */\nimport { css, html, nothing, type TemplateResult } from 'lit';\nimport './status';\nimport type { StatusTone } from './status';\n\nexport type { StatusTone };\nexport const STATUS_TONES: StatusTone[] = ['ok', 'bad', 'warn', 'info', 'neutral', 'solid'];\n\nexport const statusPillStyles = css`\n .status-pill {\n flex: none;\n inline-size: fit-content;\n }\n`;\n\n/** A status pill, or nothing when there are no words. */\nexport const statusPill = (text: string | undefined, tone: StatusTone | string | undefined, part = 'status'): TemplateResult | typeof nothing => {\n if (!text) return nothing;\n const known = STATUS_TONES.includes(tone as StatusTone) ? (tone as StatusTone) : 'neutral';\n return html`<impakt-status class=\"status-pill\" part=${part} tone=${known} label=${text}></impakt-status>`;\n};\n"],"mappings":";AAQA,SAAS,KAAK,MAAM,eAAoC;AAKjD,IAAM,eAA6B,CAAC,MAAM,OAAO,QAAQ,QAAQ,WAAW,OAAO;AAEnF,IAAM,mBAAmB;AAAA;AAAA;AAAA;AAAA;AAAA;AAQzB,IAAM,aAAa,CAAC,MAA0B,MAAuC,OAAO,aAA8C;AAC/I,MAAI,CAAC,KAAM,QAAO;AAClB,QAAM,QAAQ,aAAa,SAAS,IAAkB,IAAK,OAAsB;AACjF,SAAO,+CAA+C,IAAI,SAAS,KAAK,UAAU,IAAI;AACxF;","names":[]}
@@ -1,17 +1,19 @@
1
1
  import {
2
2
  announceNavigate
3
- } from "./chunk-JNLKM3JT.js";
3
+ } from "./chunk-N6EEW2GF.js";
4
4
  import {
5
5
  ImpaktElement,
6
6
  focusRing,
7
- fontWeight,
8
- lineHeight,
9
- space,
10
- t,
11
7
  targetSize,
12
8
  touchTarget,
13
9
  visuallyHidden
14
- } from "./chunk-V7EB7Q2M.js";
10
+ } from "./chunk-72WNCCDC.js";
11
+ import {
12
+ fontWeight,
13
+ lineHeight,
14
+ space,
15
+ t
16
+ } from "./chunk-JTCTQBAX.js";
15
17
 
16
18
  // packages/ui/src/components/blocks.ts
17
19
  import { css, html, nothing } from "lit";
@@ -120,7 +122,7 @@ var ImpaktTabs = class extends ImpaktElement {
120
122
  :host([two-rows]) .many [role='tab'][aria-selected='true'] { border-block-end-color: currentColor; background: ${t.brandSubtle}; }
121
123
  }
122
124
  @media (forced-colors: active) { [role='tab'][aria-selected='true'] { border-block-end-color: Highlight; } }
123
- .count { display: inline-flex; align-items: center; justify-content: center; min-inline-size: 20px; block-size: 20px; margin-inline-start: ${space(2)}; padding: 0 ${space(1.5)}; border-radius: 999px; font-size: 12px; font-weight: ${fontWeight("semibold")}; background: ${t.brand}; color: ${t.onBrand}; font-variant-numeric: tabular-nums; }
125
+ .count { display: inline-flex; align-items: center; justify-content: center; min-inline-size: 20px; block-size: 20px; margin-inline-start: ${space(2)}; padding: 0 ${space(1.5)}; border-radius: var(--impakt-radius-pill, calc(${t.radius} * 9999)); font-size: 12px; font-weight: ${fontWeight("semibold")}; background: ${t.brand}; color: ${t.onBrand}; font-variant-numeric: tabular-nums; }
124
126
  .sr-only { ${visuallyHidden} }
125
127
  /* Links drawn as tabs. */
126
128
  nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: ${space(1)}; overflow-x: auto; scrollbar-width: thin; border-block-end: ${t.borderThin} solid ${t.border}; }
@@ -128,11 +130,11 @@ var ImpaktTabs = class extends ImpaktElement {
128
130
  nav a:hover { color: ${t.text}; background: ${t.surfaceInset}; }
129
131
  nav a[aria-current='page'] { color: ${t.link}; border-block-end-color: currentColor; }
130
132
  nav a:focus-visible { box-shadow: inset 0 0 0 2px ${t.text}, inset 0 0 0 4px ${t.surfaceCard}; outline: none; }
131
- /* The pill look, for either kind. */
132
- :host([look='pill']) :is([role='tablist'], nav ul) { padding: ${space(1)}; border: 0; border-radius: 999px; background: ${t.surfaceCard}; gap: ${space(0.5)}; }
133
- :host([look='pill']) :is([role='tab'], nav a) { padding: ${space(2)} ${space(4)}; margin: 0; border: 0; border-radius: 999px; font-weight: ${fontWeight("medium")}; color: ${t.text}; }
133
+ /* The pill look, for either kind. Its corners come from the brand's radius, so it is square under Noire. */
134
+ :host([look='pill']) :is([role='tablist'], nav ul) { padding: ${space(1)}; border: 0; border-radius: var(--impakt-radius-pill, calc(${t.radius} * 9999)); background: ${t.surfaceCard}; gap: ${space(0.5)}; }
135
+ :host([look='pill']) :is([role='tab'], nav a) { padding: ${space(2)} ${space(4)}; margin: 0; border: 0; border-radius: var(--impakt-radius-pill, calc(${t.radius} * 9999)); font-weight: ${fontWeight("medium")}; color: ${t.text}; }
134
136
  :host([look='pill']) :is([role='tab'], nav a):hover { background: ${t.surfaceInset}; }
135
- :host([look='pill']) :is([role='tab'][aria-selected='true'], nav a[aria-current='page']) { background: ${t.text}; color: ${t.surfaceCard}; }
137
+ :host([look='pill']) :is([role='tab'][aria-selected='true'], nav a[aria-current='page']) { background: ${t.text}; color: var(--impakt-color-text-inverse, var(--impakt-solid-card, ${t.surfaceCard})); }
136
138
  @media (forced-colors: active) { :host([look='pill']) :is([role='tab'][aria-selected='true'], nav a[aria-current='page']) { border: 2px solid Highlight; } }
137
139
  `
138
140
  ];
@@ -206,4 +208,4 @@ export {
206
208
  ImpaktVisuallyHidden,
207
209
  ImpaktTabs
208
210
  };
209
- //# sourceMappingURL=chunk-MLKNZL5J.js.map
211
+ //# sourceMappingURL=chunk-6J22I7F6.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/blocks.ts"],"sourcesContent":["import { css, html, nothing, type TemplateResult } from 'lit';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { focusRing, targetSize, touchTarget, visuallyHidden } from '../base/styles';\nimport { fontWeight, lineHeight, space, t } from '../base/tokens';\nimport { announceNavigate } from './shell';\n\n/**\n * A line between two parts of a page.\n *\n * It is decoration, so a screen reader passes over it. Where the change of\n * subject matters, a heading says so better.\n *\n * @category layout\n * @icon divider\n */\nexport class ImpaktDivider extends ImpaktElement {\n static properties = {\n spacing: { type: String, reflect: true },\n tone: { type: String, reflect: true },\n };\n /** Space above and below the line. */\n declare spacing: 'sm' | 'md' | 'lg' | 'xl';\n declare tone: 'subtle' | 'strong';\n\n constructor() {\n super();\n this.spacing = 'md';\n this.tone = 'subtle';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n css`\n :host { display: block; }\n hr { margin: ${space(4)} 0; border: 0; border-block-start: ${t.borderThin} solid ${t.border}; opacity: 0.5; }\n :host([tone='strong']) hr { opacity: 1; border-block-start-width: ${t.borderThick}; }\n :host([spacing='sm']) hr { margin-block: ${space(2)}; }\n :host([spacing='lg']) hr { margin-block: ${space(8)}; }\n :host([spacing='xl']) hr { margin-block: ${space(12)}; }\n `,\n ];\n\n render(): TemplateResult {\n return html`<hr aria-hidden=\"true\" part=\"line\" />`;\n }\n}\n\n/**\n * Empty space, from the spacing scale, for the rare place where the gaps of the\n * containers around it are not enough.\n *\n * @category layout\n * @icon spacer\n */\nexport class ImpaktSpacer extends ImpaktElement {\n static properties = { size: { type: String, reflect: true } };\n declare size: 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n\n constructor() {\n super();\n this.size = 'md';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n css`\n :host { display: block; block-size: ${space(4)}; }\n :host([size='sm']) { block-size: ${space(2)}; }\n :host([size='lg']) { block-size: ${space(8)}; }\n :host([size='xl']) { block-size: ${space(12)}; }\n :host([size='2xl']) { block-size: ${space(16)}; }\n `,\n ];\n\n render(): TemplateResult {\n return html``;\n }\n}\n\n/**\n * Words a screen reader says that are not shown: \"(opens a map)\" after a link\n * whose purpose is clear on screen from where it sits.\n *\n * @category typography\n * @icon hidden\n * @slot - The words to say.\n */\nexport class ImpaktVisuallyHidden extends ImpaktElement {\n static styles = [...ImpaktElement.styles, css`:host { ${visuallyHidden} }`];\n render(): TemplateResult {\n return html`<slot></slot>`;\n }\n}\n\n/** One tab and what it shows. */\nexport interface TabItem {\n id: string;\n label: string;\n /** The panel's words. A child with `slot` set to the tab's id is shown instead, for anything richer. */\n body?: string;\n /** A number shown on the tab, such as the open tasks behind it. */\n count?: number;\n /** The count in words for a screen reader, such as \"2 overdue tasks\". The number alone when empty. */\n countLabel?: string;\n /** Where the tab goes. When every tab has one, the tabs are links to pages, not panels. */\n href?: string;\n}\n\n/**\n * Panels of content behind a row of tabs, one shown at a time: the floor plans\n * of three house types, or a case's summary, tasks and files.\n *\n * It follows the ARIA tabs pattern. The tabs are one stop in the tab order,\n * the arrow keys, Home and End move between them, and each panel is labelled\n * by its tab. Use an accordion instead when someone may want to compare panels.\n *\n * **The tabs stay on one row** and scroll sideways when they do not fit, as the\n * design guide sets, and the chosen tab is scrolled into view, so on a phone it\n * is never hidden off the edge. With `two-rows`, a set of more than four tabs is\n * laid out in two rows on a narrow screen instead, so every tab can be seen.\n *\n * **The chosen tab is kept** when the tabs are given again, as a React or Vue app\n * does on every render, so long as a tab with that id is still there.\n *\n * A panel shows its item's `body`, or a child whose `slot` is the item's id.\n *\n * **Tabs that go to pages are links.** When every item has an `href`, such as\n * a job's Overview, Money and Notes, each of which has its own address, the\n * tabs are drawn the same but are a `nav` of links, the current one marked\n * `aria-current=\"page\"`, with no panels. A row of links is not the ARIA tabs\n * pattern, and announcing it as one would promise arrow keys and panels that\n * are not there. They send `impakt-navigate` like the side navigation, so an\n * app can route without a reload.\n *\n * `look=\"pill\"` draws the tabs as pills in a rounded bar, with the chosen one\n * filled, as a product's workspace tabs are.\n *\n * @category content\n * @icon tabs\n * @slot - A child with `slot` set to a tab's id is that tab's panel.\n * @fires {CustomEvent<{ value: string }>} impakt-change - When another tab is chosen.\n * @fires {CustomEvent<{ href: string; id: string }>} impakt-navigate - When a tab that is a link is followed. Cancel it to route in the app.\n */\nexport class ImpaktTabs extends ImpaktElement {\n static properties = {\n items: { type: Array },\n selected: { type: String, reflect: true },\n label: { type: String },\n twoRows: { type: Boolean, reflect: true, attribute: 'two-rows' },\n look: { type: String, reflect: true },\n };\n declare items: TabItem[];\n /** The id of the tab shown first. The first tab when it is empty. */\n declare selected: string;\n /** What the set of tabs is about, for a screen reader. */\n declare label: string;\n /** On a narrow screen, lay more than four tabs out in two rows rather than scroll them. */\n declare twoRows: boolean;\n /** `line` underlines the chosen tab; `pill` fills it, in a rounded bar. */\n declare look: 'line' | 'pill';\n\n constructor() {\n super();\n this.items = [];\n this.selected = '';\n this.label = '';\n this.twoRows = false;\n this.look = 'line';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n touchTarget(\"[role='tab']\"),\n css`\n /* Only the two-row layout needs a size container. Making every tab set one\n would take its width from its parent alone, so in a flex row, with no\n width given, it would shrink to nothing. In a row it may still shrink\n below its tabs, which then scroll, rather than widen the page. */\n :host { display: block; min-inline-size: 0; }\n :host([two-rows]) { container-type: inline-size; }\n [role='tablist'] { display: flex; gap: ${space(1)}; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: thin; border-block-end: ${t.borderThin} solid ${t.border}; }\n [role='tab'] { ${targetSize} position: relative; flex: none; padding: ${space(3)} ${space(4)}; font: inherit; font-weight: ${fontWeight('semibold')}; white-space: nowrap; color: ${t.textMuted}; background: transparent; border: 0; border-block-end: 3px solid transparent; margin-block-end: -1px; cursor: pointer; border-radius: ${t.radius} ${t.radius} 0 0; }\n /* Inside a box that scrolls the ring would be clipped, so it is drawn inside the tab. */\n [role='tab']:focus-visible { box-shadow: inset 0 0 0 2px ${t.text}, inset 0 0 0 4px ${t.surfaceCard}; }\n [role='tab']:hover { color: ${t.text}; background: ${t.surfaceInset}; }\n [role='tab'][aria-selected='true'] { color: ${t.link}; border-block-end-color: currentColor; }\n [role='tabpanel'] { padding-block: ${space(5)}; line-height: ${lineHeight('normal')}; }\n .body { white-space: pre-line; }\n @container (max-width: 40rem) {\n :host([two-rows]) [role='tablist'].many { display: grid; grid-template-columns: repeat(var(--columns), minmax(0, 1fr)); overflow: visible; border-block-end: 0; gap: ${space(1)}; }\n :host([two-rows]) .many [role='tab'] { white-space: normal; padding-inline: ${space(2)}; margin: 0; border-block-end-width: 3px; border-block-end-color: ${t.rule}; border-radius: ${t.radius}; }\n :host([two-rows]) .many [role='tab'][aria-selected='true'] { border-block-end-color: currentColor; background: ${t.brandSubtle}; }\n }\n @media (forced-colors: active) { [role='tab'][aria-selected='true'] { border-block-end-color: Highlight; } }\n .count { display: inline-flex; align-items: center; justify-content: center; min-inline-size: 20px; block-size: 20px; margin-inline-start: ${space(2)}; padding: 0 ${space(1.5)}; border-radius: var(--impakt-radius-pill, calc(${t.radius} * 9999)); font-size: 12px; font-weight: ${fontWeight('semibold')}; background: ${t.brand}; color: ${t.onBrand}; font-variant-numeric: tabular-nums; }\n .sr-only { ${visuallyHidden} }\n /* Links drawn as tabs. */\n nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: ${space(1)}; overflow-x: auto; scrollbar-width: thin; border-block-end: ${t.borderThin} solid ${t.border}; }\n nav a { ${targetSize} position: relative; display: inline-flex; align-items: center; flex: none; padding: ${space(3)} ${space(4)}; font-weight: ${fontWeight('semibold')}; white-space: nowrap; color: ${t.textMuted}; text-decoration: none; border-block-end: 3px solid transparent; margin-block-end: -1px; border-radius: ${t.radius} ${t.radius} 0 0; }\n nav a:hover { color: ${t.text}; background: ${t.surfaceInset}; }\n nav a[aria-current='page'] { color: ${t.link}; border-block-end-color: currentColor; }\n nav a:focus-visible { box-shadow: inset 0 0 0 2px ${t.text}, inset 0 0 0 4px ${t.surfaceCard}; outline: none; }\n /* The pill look, for either kind. Its corners come from the brand's radius, so it is square under Noire. */\n :host([look='pill']) :is([role='tablist'], nav ul) { padding: ${space(1)}; border: 0; border-radius: var(--impakt-radius-pill, calc(${t.radius} * 9999)); background: ${t.surfaceCard}; gap: ${space(0.5)}; }\n :host([look='pill']) :is([role='tab'], nav a) { padding: ${space(2)} ${space(4)}; margin: 0; border: 0; border-radius: var(--impakt-radius-pill, calc(${t.radius} * 9999)); font-weight: ${fontWeight('medium')}; color: ${t.text}; }\n :host([look='pill']) :is([role='tab'], nav a):hover { background: ${t.surfaceInset}; }\n :host([look='pill']) :is([role='tab'][aria-selected='true'], nav a[aria-current='page']) { background: ${t.text}; color: var(--impakt-color-text-inverse, var(--impakt-solid-card, ${t.surfaceCard})); }\n @media (forced-colors: active) { :host([look='pill']) :is([role='tab'][aria-selected='true'], nav a[aria-current='page']) { border: 2px solid Highlight; } }\n `,\n ];\n\n private countOf(item: TabItem): TemplateResult | typeof nothing {\n if (typeof item.count !== 'number') return nothing;\n return item.countLabel\n ? html`<span class=\"count\" aria-hidden=\"true\">${item.count}</span><span class=\"sr-only\">, ${item.countLabel}</span>`\n : html`<span class=\"count\">${item.count}</span>`;\n }\n\n private get linked(): boolean {\n const items = this.items ?? [];\n return items.length > 0 && items.every((i) => Boolean(i.href));\n }\n\n private current(): string {\n const items = this.items ?? [];\n return items.some((i) => i.id === this.selected) ? this.selected : (items[0]?.id ?? '');\n }\n\n private choose(id: string, focus: boolean): void {\n if (id === this.current()) return;\n this.selected = id;\n this.dispatchEvent(new CustomEvent('impakt-change', { detail: { value: id }, bubbles: true, composed: true }));\n if (focus) void this.updateComplete.then(() => this.renderRoot.querySelector<HTMLElement>(`#${this.id_(`tab-${id}`)}`)?.focus({ preventScroll: true }));\n }\n\n private onKey(event: KeyboardEvent): void {\n const items = this.items ?? [];\n const at = items.findIndex((i) => i.id === this.current());\n const to = { ArrowRight: at + 1, ArrowLeft: at - 1, Home: 0, End: items.length - 1 }[event.key];\n if (to === undefined || !items.length) return;\n event.preventDefault();\n this.choose(items[(to + items.length) % items.length]!.id, true);\n }\n\n /**\n * Bring the chosen tab into view inside the row of tabs. Only the row scrolls:\n * `scrollIntoView` would scroll the page too, and move someone who is reading\n * further down.\n */\n private reveal(): void {\n const list = this.renderRoot.querySelector<HTMLElement>(\"[role='tablist']\");\n const tab = this.renderRoot.querySelector<HTMLElement>(\"[role='tab'][aria-selected='true']\");\n if (!list || !tab || list.scrollWidth <= list.clientWidth) return;\n const start = tab.offsetLeft - list.offsetLeft;\n const end = start + tab.offsetWidth;\n if (start < list.scrollLeft) list.scrollLeft = start - 16;\n else if (end > list.scrollLeft + list.clientWidth) list.scrollLeft = end - list.clientWidth + 16;\n }\n\n updated(changed: Map<string, unknown>): void {\n if (changed.has('selected') || changed.has('items')) this.reveal();\n }\n\n render(): TemplateResult {\n const items = this.items ?? [];\n const current = this.current();\n if (this.linked) {\n return html`<nav aria-label=${this.label || nothing} part=\"tabs\"><ul>\n ${items.map((item) => html`<li><a href=${item.href!} part=\"tab\" aria-current=${item.id === current ? 'page' : nothing} @click=${(e: MouseEvent) => announceNavigate(this, e, { href: item.href!, id: item.id })}>${item.label}${this.countOf(item)}</a></li>`)}\n </ul></nav>`;\n }\n const many = items.length > 4;\n return html`<div role=\"tablist\" aria-label=${this.label || nothing} part=\"tabs\" class=${many ? 'many' : ''} style=${many ? `--columns:${Math.ceil(items.length / 2)}` : nothing} @keydown=${this.onKey}>\n ${items.map((item) => html`<button role=\"tab\" type=\"button\" id=${this.id_(`tab-${item.id}`)} aria-selected=${item.id === current ? 'true' : 'false'} aria-controls=${this.id_(`panel-${item.id}`)} tabindex=${item.id === current ? '0' : '-1'} @click=${() => this.choose(item.id, false)}>${item.label}${this.countOf(item)}</button>`)}\n </div>\n ${items.map((item) => html`<div role=\"tabpanel\" id=${this.id_(`panel-${item.id}`)} aria-labelledby=${this.id_(`tab-${item.id}`)} tabindex=\"0\" ?hidden=${item.id !== current} part=\"panel\"><slot name=${item.id}><span class=\"body\">${item.body ?? ''}</span></slot></div>`)}`;\n }\n}\n\ncustomElements.define('impakt-divider', ImpaktDivider);\ncustomElements.define('impakt-spacer', ImpaktSpacer);\ncustomElements.define('impakt-visually-hidden', ImpaktVisuallyHidden);\ncustomElements.define('impakt-tabs', ImpaktTabs);\ndeclare global {\n interface HTMLElementTagNameMap {\n 'impakt-divider': ImpaktDivider;\n 'impakt-spacer': ImpaktSpacer;\n 'impakt-visually-hidden': ImpaktVisuallyHidden;\n 'impakt-tabs': ImpaktTabs;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA,SAAS,KAAK,MAAM,eAAoC;AAejD,IAAM,gBAAN,cAA4B,cAAc;AAAA,EAC/C;AAAA,SAAO,aAAa;AAAA,MAClB,SAAS,EAAE,MAAM,QAAQ,SAAS,KAAK;AAAA,MACvC,MAAM,EAAE,MAAM,QAAQ,SAAS,KAAK;AAAA,IACtC;AAAA;AAAA,EAKA,cAAc;AACZ,UAAM;AACN,SAAK,UAAU;AACf,SAAK,OAAO;AAAA,EACd;AAAA,EAEA;AAAA,SAAO,SAAS;AAAA,MACd,GAAG,cAAc;AAAA,MACjB;AAAA;AAAA,mBAEe,MAAM,CAAC,CAAC,sCAAsC,EAAE,UAAU,UAAU,EAAE,MAAM;AAAA,wEACvB,EAAE,WAAW;AAAA,+CACtC,MAAM,CAAC,CAAC;AAAA,+CACR,MAAM,CAAC,CAAC;AAAA,+CACR,MAAM,EAAE,CAAC;AAAA;AAAA,IAEtD;AAAA;AAAA,EAEA,SAAyB;AACvB,WAAO;AAAA,EACT;AACF;AASO,IAAM,eAAN,cAA2B,cAAc;AAAA,EAC9C;AAAA,SAAO,aAAa,EAAE,MAAM,EAAE,MAAM,QAAQ,SAAS,KAAK,EAAE;AAAA;AAAA,EAG5D,cAAc;AACZ,UAAM;AACN,SAAK,OAAO;AAAA,EACd;AAAA,EAEA;AAAA,SAAO,SAAS;AAAA,MACd,GAAG,cAAc;AAAA,MACjB;AAAA,0CACsC,MAAM,CAAC,CAAC;AAAA,uCACX,MAAM,CAAC,CAAC;AAAA,uCACR,MAAM,CAAC,CAAC;AAAA,uCACR,MAAM,EAAE,CAAC;AAAA,w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AAK,GAAG,KAAK,QAAQ,IAAI,CAAC,WAAW,CAAC;AAAA;AAAA,MAEzU,MAAM,IAAI,CAAC,SAAS,+BAA+B,KAAK,IAAI,SAAS,KAAK,EAAE,EAAE,CAAC,oBAAoB,KAAK,IAAI,OAAO,KAAK,EAAE,EAAE,CAAC,yBAAyB,KAAK,OAAO,OAAO,4BAA4B,KAAK,EAAE,uBAAuB,KAAK,QAAQ,EAAE,sBAAsB,CAAC;AAAA,EAC7Q;AACF;AAEA,eAAe,OAAO,kBAAkB,aAAa;AACrD,eAAe,OAAO,iBAAiB,YAAY;AACnD,eAAe,OAAO,0BAA0B,oBAAoB;AACpE,eAAe,OAAO,eAAe,UAAU;","names":[]}
@@ -0,0 +1,136 @@
1
+ import {
2
+ t
3
+ } from "./chunk-JTCTQBAX.js";
4
+
5
+ // packages/ui/src/base/styles.ts
6
+ import { css, unsafeCSS } from "lit";
7
+ var focusRing = css`
8
+ :host(:focus-visible),
9
+ :host(:not([disabled])) :focus-visible {
10
+ outline: 2px solid transparent;
11
+ outline-offset: ${t.focusOffset};
12
+ box-shadow: ${t.focusShadow};
13
+ }
14
+ `;
15
+ var targetSize = css`
16
+ min-block-size: ${t.targetMin};
17
+ min-inline-size: ${t.targetMin};
18
+ `;
19
+ var visuallyHidden = css`
20
+ position: absolute;
21
+ inline-size: 1px;
22
+ block-size: 1px;
23
+ margin: -1px;
24
+ padding: 0;
25
+ overflow: hidden;
26
+ clip-path: inset(50%);
27
+ white-space: nowrap;
28
+ border: 0;
29
+ `;
30
+ var reducedMotion = css`
31
+ @media (prefers-reduced-motion: reduce) {
32
+ :host,
33
+ :host *,
34
+ :host *::before,
35
+ :host *::after {
36
+ animation-duration: 0.01ms !important;
37
+ animation-iteration-count: 1 !important;
38
+ transition-duration: 0.01ms !important;
39
+ scroll-behavior: auto !important;
40
+ }
41
+ }
42
+ `;
43
+ var base = css`
44
+ :host {
45
+ box-sizing: border-box;
46
+ font-family: ${t.fontBody};
47
+ color: ${t.text};
48
+ }
49
+ :host([hidden]) {
50
+ display: none !important;
51
+ }
52
+ *,
53
+ *::before,
54
+ *::after {
55
+ box-sizing: inherit;
56
+ }
57
+ `;
58
+ var touchTarget = (selector) => (
59
+ // Under :host, so it outweighs the component's own rule for the same control whatever the order.
60
+ unsafeCSS(`@media (pointer: coarse) { :host :is(${selector}) { min-block-size: 44px; min-inline-size: 44px; } }`)
61
+ );
62
+ var hideOn = css`
63
+ @media (max-width: 40rem) { :host([hide-on='phone']) { display: none !important; } }
64
+ @media (min-width: 40.0625rem) { :host([hide-on='wide']) { display: none !important; } }
65
+ `;
66
+
67
+ // packages/ui/src/base/say.ts
68
+ var WORDING = Symbol.for("strata.wording");
69
+ function say(english, values) {
70
+ const words = globalThis[WORDING]?.words;
71
+ const chosen = words?.[english];
72
+ const text = typeof chosen === "string" && chosen.trim() ? chosen : english;
73
+ return values ? text.replace(/\{(\w+)\}/g, (whole, name) => name in values ? String(values[name]) : whole) : text;
74
+ }
75
+
76
+ // packages/ui/src/base/ImpaktElement.ts
77
+ import { LitElement, css as css2 } from "lit";
78
+ var counter = 0;
79
+ var ImpaktElement = class extends LitElement {
80
+ constructor() {
81
+ super(...arguments);
82
+ /**
83
+ * A unique id for this instance, for `aria-describedby` and friends.
84
+ *
85
+ * Generated once in the constructor rather than in `render`, because an id
86
+ * that changes between renders breaks the relationship it exists to express
87
+ * — and it breaks it silently, since the markup still looks correct.
88
+ */
89
+ this.uid = `impakt-${counter += 1}`;
90
+ }
91
+ static {
92
+ this.styles = [base, reducedMotion, css2``];
93
+ }
94
+ id_(part) {
95
+ return `${this.uid}-${part}`;
96
+ }
97
+ /** @ignore */
98
+ connectedCallback() {
99
+ super.connectedCallback();
100
+ this.sayDefaults();
101
+ }
102
+ /**
103
+ * The words a component ships with, in the page's language (ADR 0026).
104
+ *
105
+ * Defaults stay plain English in the constructor, so the component manifest
106
+ * still sees them (a prop with no default is read as required). When the
107
+ * element joins the page, each word it holds is looked up in the site's
108
+ * wording; anything that is not one of Strata's own words, such as a page's
109
+ * own text or a variant name, is left exactly as it is.
110
+ *
111
+ * @ignore
112
+ */
113
+ sayDefaults() {
114
+ const props = this.constructor.elementProperties;
115
+ const self = this;
116
+ for (const name of props.keys()) {
117
+ const value = self[name];
118
+ if (typeof value !== "string" || !value) continue;
119
+ const said = say(value);
120
+ if (said !== value) self[name] = said;
121
+ }
122
+ }
123
+ };
124
+
125
+ export {
126
+ focusRing,
127
+ targetSize,
128
+ visuallyHidden,
129
+ reducedMotion,
130
+ base,
131
+ touchTarget,
132
+ hideOn,
133
+ say,
134
+ ImpaktElement
135
+ };
136
+ //# sourceMappingURL=chunk-72WNCCDC.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/base/styles.ts","../src/base/say.ts","../src/base/ImpaktElement.ts"],"sourcesContent":["/**\n * Shared style fragments.\n *\n * Three of these carry an accessibility guarantee and are therefore not\n * negotiable per component: the focus ring, the minimum target size and the\n * reduced-motion rule. A component that wants its own focus treatment is a\n * component that will get it subtly wrong on one brand, so there is one.\n */\nimport { css, unsafeCSS, type CSSResult } from 'lit';\nimport { t } from './tokens';\n\n/**\n * The focus ring.\n *\n * `:focus-visible` rather than `:focus`, so a mouse click on a button does not\n * draw a ring the user did not ask for while keyboard focus still does.\n *\n * The ring is two-tone — a light inner band inside a dark outer one — drawn\n * with `box-shadow` and a transparent `outline` behind it. The outline is not\n * decoration: it is what survives Windows High Contrast Mode, where box-shadow\n * is dropped entirely and a shadow-only ring disappears for exactly the users\n * who most need it.\n *\n * The colours come from locked tokens a brand cannot reach\n * ([ADR 0010](https://github.com/matthill8286/strata/blob/main/docs/decisions/0010-what-a-brand-may-set.md)).\n */\nexport const focusRing = css`\n :host(:focus-visible),\n :host(:not([disabled])) :focus-visible {\n outline: 2px solid transparent;\n outline-offset: ${t.focusOffset};\n box-shadow: ${t.focusShadow};\n }\n`;\n\n/**\n * WCAG 2.2, 2.5.8 Target Size (Minimum): 24 by 24 CSS pixels.\n *\n * Applied as a minimum rather than a fixed size so a control grows with its\n * content and never shrinks below the floor. It reads the locked token, which\n * is deliberately outside the spacing scale — otherwise a brand tightening its\n * spacing unit would shrink every tap target with it.\n */\nexport const targetSize = css`\n min-block-size: ${t.targetMin};\n min-inline-size: ${t.targetMin};\n`;\n\n/**\n * Visible to a screen reader, invisible on screen.\n *\n * `clip-path` with a 1px box rather than `display: none` or `visibility:\n * hidden`, both of which remove the text from the accessibility tree — which\n * is the one thing this must not do.\n */\nexport const visuallyHidden = css`\n position: absolute;\n inline-size: 1px;\n block-size: 1px;\n margin: -1px;\n padding: 0;\n overflow: hidden;\n clip-path: inset(50%);\n white-space: nowrap;\n border: 0;\n`;\n\n/**\n * 2.3.3 Animation from Interactions, and plain decency.\n *\n * `0.01ms` rather than `0` because a zero-duration transition does not fire a\n * `transitionend` event in every engine, and components that wait for one hang.\n */\nexport const reducedMotion = css`\n @media (prefers-reduced-motion: reduce) {\n :host,\n :host *,\n :host *::before,\n :host *::after {\n animation-duration: 0.01ms !important;\n animation-iteration-count: 1 !important;\n transition-duration: 0.01ms !important;\n scroll-behavior: auto !important;\n }\n }\n`;\n\n/** The base every component starts from. */\nexport const base = css`\n :host {\n box-sizing: border-box;\n font-family: ${t.fontBody};\n color: ${t.text};\n }\n :host([hidden]) {\n display: none !important;\n }\n *,\n *::before,\n *::after {\n box-sizing: inherit;\n }\n`;\n\n/**\n * On a touch screen a control is at least 44 by 44 CSS pixels.\n *\n * The 24px floor above is WCAG 2.2's minimum, and it is right for a mouse. A finger\n * is broader, and the design guide sets 44px on a touch screen, which is also\n * 2.5.5's enhanced size. It is applied by pointer rather than by width, because a\n * small laptop window is still driven by a mouse and a large tablet by a finger.\n * Pass the selectors that are the controls, inside the component's shadow root.\n */\nexport const touchTarget = (selector: string): CSSResult =>\n // Under :host, so it outweighs the component's own rule for the same control whatever the order.\n unsafeCSS(`@media (pointer: coarse) { :host :is(${selector}) { min-block-size: 44px; min-inline-size: 44px; } }`);\n\n/**\n * `hide-on`: an element left out on a phone, or on anything wider, so a phone's\n * header is built from the same pieces as a wide one. The width is the one the\n * nav folds at. A component that offers `hideOn` reflects it as `hide-on` and\n * adds this to its styles.\n */\nexport const hideOn = css`\n @media (max-width: 40rem) { :host([hide-on='phone']) { display: none !important; } }\n @media (min-width: 40.0625rem) { :host([hide-on='wide']) { display: none !important; } }\n`;\n","/**\n * The library's own words, in the page's language (ADR 0026).\n *\n * Every word a component shows that a page did not give it, such as \"Skip to\n * content\", \"Next slide\" or \"There is a problem\", goes through `say`. The\n * renderer puts the site's wording in place before it draws a page\n * (`applySiteLanguage` in `@atomic-ui/renderer-core`), translated into the page's\n * language and with any of the site's own rewording. Without it, the English\n * here is shown, which is what every site did before it had languages.\n *\n * The English is the key, with `{name}` for a value put in, so the list of\n * words to translate (`SITE_WORDING` in `@atomic-ui/content-schemas`) can be\n * checked against this library by a test.\n */\nconst WORDING = Symbol.for('strata.wording');\n\ntype Store = { words?: Record<string, string> };\n\nexport function say(english: string, values?: Record<string, string | number>): string {\n const words = (globalThis as Record<symbol, Store | undefined>)[WORDING]?.words;\n const chosen = words?.[english];\n const text = typeof chosen === 'string' && chosen.trim() ? chosen : english;\n return values ? text.replace(/\\{(\\w+)\\}/g, (whole, name: string) => (name in values ? String(values[name]) : whole)) : text;\n}\n","import { LitElement, css } from 'lit';\nimport { base, reducedMotion } from './styles';\nimport { say } from './say';\n\nlet counter = 0;\n\n/**\n * The base every Impakt component extends.\n *\n * It carries the two style fragments that are not a per-component choice — the\n * reset and the reduced-motion rule — and a stable id generator for the ARIA\n * wiring. It deliberately carries nothing else: a base class that grows\n * behaviour becomes the place every component's exceptions are negotiated.\n */\nexport class ImpaktElement extends LitElement {\n static styles = [base, reducedMotion, css``];\n\n /**\n * A unique id for this instance, for `aria-describedby` and friends.\n *\n * Generated once in the constructor rather than in `render`, because an id\n * that changes between renders breaks the relationship it exists to express\n * — and it breaks it silently, since the markup still looks correct.\n */\n protected readonly uid = `impakt-${(counter += 1)}`;\n\n protected id_(part: string): string {\n return `${this.uid}-${part}`;\n }\n\n /** @ignore */\n connectedCallback(): void {\n super.connectedCallback();\n this.sayDefaults();\n }\n\n /**\n * The words a component ships with, in the page's language (ADR 0026).\n *\n * Defaults stay plain English in the constructor, so the component manifest\n * still sees them (a prop with no default is read as required). When the\n * element joins the page, each word it holds is looked up in the site's\n * wording; anything that is not one of Strata's own words, such as a page's\n * own text or a variant name, is left exactly as it is.\n *\n * @ignore\n */\n private sayDefaults(): void {\n const props = (this.constructor as typeof LitElement).elementProperties;\n const self = this as unknown as Record<string, unknown>;\n for (const name of props.keys()) {\n const value = self[name as string];\n if (typeof value !== 'string' || !value) continue;\n const said = say(value);\n if (said !== value) self[name as string] = said;\n }\n }\n}\n"],"mappings":";;;;;AAQA,SAAS,KAAK,iBAAiC;AAkBxC,IAAM,YAAY;AAAA;AAAA;AAAA;AAAA,sBAIH,EAAE,WAAW;AAAA,kBACjB,EAAE,WAAW;AAAA;AAAA;AAYxB,IAAM,aAAa;AAAA,oBACN,EAAE,SAAS;AAAA,qBACV,EAAE,SAAS;AAAA;AAUzB,IAAM,iBAAiB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAkBvB,IAAM,gBAAgB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAetB,IAAM,OAAO;AAAA;AAAA;AAAA,mBAGD,EAAE,QAAQ;AAAA,aAChB,EAAE,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAqBZ,IAAM,cAAc,CAAC;AAAA;AAAA,EAE1B,UAAU,wCAAwC,QAAQ,sDAAsD;AAAA;AAQ3G,IAAM,SAAS;AAAA;AAAA;AAAA;;;AC7GtB,IAAM,UAAU,OAAO,IAAI,gBAAgB;AAIpC,SAAS,IAAI,SAAiB,QAAkD;AACrF,QAAM,QAAS,WAAiD,OAAO,GAAG;AAC1E,QA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