@lo-tek/interfaces 0.0.0 → 0.37.0

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 (456) hide show
  1. package/CHANGELOG.md +3254 -0
  2. package/LICENSE +21 -0
  3. package/README.md +128 -1
  4. package/agent/astro.md +400 -0
  5. package/agent/bundles.md +429 -0
  6. package/agent/datastar.md +409 -0
  7. package/agent/html.md +388 -0
  8. package/agent/react.md +440 -0
  9. package/agent/templates.md +472 -0
  10. package/core/lotek-core.wasm +0 -0
  11. package/core/lotek.wasm +0 -0
  12. package/dist/cli.d.ts +12 -0
  13. package/dist/cli.d.ts.map +1 -0
  14. package/dist/cli.js +14 -0
  15. package/dist/cli.js.map +1 -0
  16. package/dist/components/css/accordion/accordion.d.ts +37 -0
  17. package/dist/components/css/accordion/accordion.d.ts.map +1 -0
  18. package/dist/components/css/accordion/accordion.js +31 -0
  19. package/dist/components/css/accordion/accordion.js.map +1 -0
  20. package/dist/components/css/alert/alert.d.ts +35 -0
  21. package/dist/components/css/alert/alert.d.ts.map +1 -0
  22. package/dist/components/css/alert/alert.js +29 -0
  23. package/dist/components/css/alert/alert.js.map +1 -0
  24. package/dist/components/css/avatar/avatar.d.ts +40 -0
  25. package/dist/components/css/avatar/avatar.d.ts.map +1 -0
  26. package/dist/components/css/avatar/avatar.js +30 -0
  27. package/dist/components/css/avatar/avatar.js.map +1 -0
  28. package/dist/components/css/badge/badge.d.ts +24 -0
  29. package/dist/components/css/badge/badge.d.ts.map +1 -0
  30. package/dist/components/css/badge/badge.js +24 -0
  31. package/dist/components/css/badge/badge.js.map +1 -0
  32. package/dist/components/css/breadcrumbs/breadcrumbs.d.ts +26 -0
  33. package/dist/components/css/breadcrumbs/breadcrumbs.d.ts.map +1 -0
  34. package/dist/components/css/breadcrumbs/breadcrumbs.js +24 -0
  35. package/dist/components/css/breadcrumbs/breadcrumbs.js.map +1 -0
  36. package/dist/components/css/button/button.d.ts +26 -0
  37. package/dist/components/css/button/button.d.ts.map +1 -0
  38. package/dist/components/css/button/button.js +25 -0
  39. package/dist/components/css/button/button.js.map +1 -0
  40. package/dist/components/css/card/card.d.ts +36 -0
  41. package/dist/components/css/card/card.d.ts.map +1 -0
  42. package/dist/components/css/card/card.js +28 -0
  43. package/dist/components/css/card/card.js.map +1 -0
  44. package/dist/components/css/checkbox/checkbox.d.ts +32 -0
  45. package/dist/components/css/checkbox/checkbox.d.ts.map +1 -0
  46. package/dist/components/css/checkbox/checkbox.js +27 -0
  47. package/dist/components/css/checkbox/checkbox.js.map +1 -0
  48. package/dist/components/css/divider/divider.d.ts +29 -0
  49. package/dist/components/css/divider/divider.d.ts.map +1 -0
  50. package/dist/components/css/divider/divider.js +23 -0
  51. package/dist/components/css/divider/divider.js.map +1 -0
  52. package/dist/components/css/error-text/error-text.d.ts +24 -0
  53. package/dist/components/css/error-text/error-text.d.ts.map +1 -0
  54. package/dist/components/css/error-text/error-text.js +18 -0
  55. package/dist/components/css/error-text/error-text.js.map +1 -0
  56. package/dist/components/css/fieldset/fieldset.d.ts +55 -0
  57. package/dist/components/css/fieldset/fieldset.d.ts.map +1 -0
  58. package/dist/components/css/fieldset/fieldset.js +39 -0
  59. package/dist/components/css/fieldset/fieldset.js.map +1 -0
  60. package/dist/components/css/file-upload/file-upload.d.ts +41 -0
  61. package/dist/components/css/file-upload/file-upload.d.ts.map +1 -0
  62. package/dist/components/css/file-upload/file-upload.js +32 -0
  63. package/dist/components/css/file-upload/file-upload.js.map +1 -0
  64. package/dist/components/css/heading/heading.d.ts +29 -0
  65. package/dist/components/css/heading/heading.d.ts.map +1 -0
  66. package/dist/components/css/heading/heading.js +23 -0
  67. package/dist/components/css/heading/heading.js.map +1 -0
  68. package/dist/components/css/help-text/help-text.d.ts +24 -0
  69. package/dist/components/css/help-text/help-text.d.ts.map +1 -0
  70. package/dist/components/css/help-text/help-text.js +23 -0
  71. package/dist/components/css/help-text/help-text.js.map +1 -0
  72. package/dist/components/css/icon/icon.d.ts +34 -0
  73. package/dist/components/css/icon/icon.d.ts.map +1 -0
  74. package/dist/components/css/icon/icon.js +25 -0
  75. package/dist/components/css/icon/icon.js.map +1 -0
  76. package/dist/components/css/input/input.d.ts +40 -0
  77. package/dist/components/css/input/input.d.ts.map +1 -0
  78. package/dist/components/css/input/input.js +45 -0
  79. package/dist/components/css/input/input.js.map +1 -0
  80. package/dist/components/css/label/label.d.ts +33 -0
  81. package/dist/components/css/label/label.d.ts.map +1 -0
  82. package/dist/components/css/label/label.js +23 -0
  83. package/dist/components/css/label/label.js.map +1 -0
  84. package/dist/components/css/link/link.d.ts +28 -0
  85. package/dist/components/css/link/link.d.ts.map +1 -0
  86. package/dist/components/css/link/link.js +20 -0
  87. package/dist/components/css/link/link.js.map +1 -0
  88. package/dist/components/css/list/list.d.ts +31 -0
  89. package/dist/components/css/list/list.d.ts.map +1 -0
  90. package/dist/components/css/list/list.js +25 -0
  91. package/dist/components/css/list/list.js.map +1 -0
  92. package/dist/components/css/pagination/pagination.d.ts +27 -0
  93. package/dist/components/css/pagination/pagination.d.ts.map +1 -0
  94. package/dist/components/css/pagination/pagination.js +25 -0
  95. package/dist/components/css/pagination/pagination.js.map +1 -0
  96. package/dist/components/css/paragraph/paragraph.d.ts +36 -0
  97. package/dist/components/css/paragraph/paragraph.d.ts.map +1 -0
  98. package/dist/components/css/paragraph/paragraph.js +26 -0
  99. package/dist/components/css/paragraph/paragraph.js.map +1 -0
  100. package/dist/components/css/progress/progress.d.ts +53 -0
  101. package/dist/components/css/progress/progress.d.ts.map +1 -0
  102. package/dist/components/css/progress/progress.js +38 -0
  103. package/dist/components/css/progress/progress.js.map +1 -0
  104. package/dist/components/css/radio/radio.d.ts +32 -0
  105. package/dist/components/css/radio/radio.d.ts.map +1 -0
  106. package/dist/components/css/radio/radio.js +27 -0
  107. package/dist/components/css/radio/radio.js.map +1 -0
  108. package/dist/components/css/search/search.d.ts +34 -0
  109. package/dist/components/css/search/search.d.ts.map +1 -0
  110. package/dist/components/css/search/search.js +32 -0
  111. package/dist/components/css/search/search.js.map +1 -0
  112. package/dist/components/css/select/select.d.ts +40 -0
  113. package/dist/components/css/select/select.d.ts.map +1 -0
  114. package/dist/components/css/select/select.js +31 -0
  115. package/dist/components/css/select/select.js.map +1 -0
  116. package/dist/components/css/shared.d.ts +90 -0
  117. package/dist/components/css/shared.d.ts.map +1 -0
  118. package/dist/components/css/shared.js +167 -0
  119. package/dist/components/css/shared.js.map +1 -0
  120. package/dist/components/css/skeleton/skeleton.d.ts +29 -0
  121. package/dist/components/css/skeleton/skeleton.d.ts.map +1 -0
  122. package/dist/components/css/skeleton/skeleton.js +23 -0
  123. package/dist/components/css/skeleton/skeleton.js.map +1 -0
  124. package/dist/components/css/skip-link/skip-link.d.ts +18 -0
  125. package/dist/components/css/skip-link/skip-link.d.ts.map +1 -0
  126. package/dist/components/css/skip-link/skip-link.js +16 -0
  127. package/dist/components/css/skip-link/skip-link.js.map +1 -0
  128. package/dist/components/css/spinner/spinner.d.ts +33 -0
  129. package/dist/components/css/spinner/spinner.d.ts.map +1 -0
  130. package/dist/components/css/spinner/spinner.js +25 -0
  131. package/dist/components/css/spinner/spinner.js.map +1 -0
  132. package/dist/components/css/sr-only/sr-only.d.ts +17 -0
  133. package/dist/components/css/sr-only/sr-only.d.ts.map +1 -0
  134. package/dist/components/css/sr-only/sr-only.js +15 -0
  135. package/dist/components/css/sr-only/sr-only.js.map +1 -0
  136. package/dist/components/css/switch/switch.d.ts +37 -0
  137. package/dist/components/css/switch/switch.d.ts.map +1 -0
  138. package/dist/components/css/switch/switch.js +29 -0
  139. package/dist/components/css/switch/switch.js.map +1 -0
  140. package/dist/components/css/table/table.d.ts +76 -0
  141. package/dist/components/css/table/table.d.ts.map +1 -0
  142. package/dist/components/css/table/table.js +59 -0
  143. package/dist/components/css/table/table.js.map +1 -0
  144. package/dist/components/css/tag/tag.d.ts +35 -0
  145. package/dist/components/css/tag/tag.d.ts.map +1 -0
  146. package/dist/components/css/tag/tag.js +27 -0
  147. package/dist/components/css/tag/tag.js.map +1 -0
  148. package/dist/components/css/textarea/textarea.d.ts +23 -0
  149. package/dist/components/css/textarea/textarea.d.ts.map +1 -0
  150. package/dist/components/css/textarea/textarea.js +18 -0
  151. package/dist/components/css/textarea/textarea.js.map +1 -0
  152. package/dist/components/css/toggle-group/toggle-group.d.ts +31 -0
  153. package/dist/components/css/toggle-group/toggle-group.d.ts.map +1 -0
  154. package/dist/components/css/toggle-group/toggle-group.js +29 -0
  155. package/dist/components/css/toggle-group/toggle-group.js.map +1 -0
  156. package/dist/components/css/tooltip/tooltip.d.ts +31 -0
  157. package/dist/components/css/tooltip/tooltip.d.ts.map +1 -0
  158. package/dist/components/css/tooltip/tooltip.js +29 -0
  159. package/dist/components/css/tooltip/tooltip.js.map +1 -0
  160. package/dist/components/default-texts.d.ts +35 -0
  161. package/dist/components/default-texts.d.ts.map +1 -0
  162. package/dist/components/default-texts.js +35 -0
  163. package/dist/components/default-texts.js.map +1 -0
  164. package/dist/components/events.d.ts +77 -0
  165. package/dist/components/events.d.ts.map +1 -0
  166. package/dist/components/events.js +3 -0
  167. package/dist/components/events.js.map +1 -0
  168. package/dist/components/frame/dialog/dialog.d.ts +122 -0
  169. package/dist/components/frame/dialog/dialog.d.ts.map +1 -0
  170. package/dist/components/frame/dialog/dialog.js +112 -0
  171. package/dist/components/frame/dialog/dialog.js.map +1 -0
  172. package/dist/components/frame/dialog/lt-dialog.d.ts +104 -0
  173. package/dist/components/frame/dialog/lt-dialog.d.ts.map +1 -0
  174. package/dist/components/frame/dialog/lt-dialog.js +431 -0
  175. package/dist/components/frame/dialog/lt-dialog.js.map +1 -0
  176. package/dist/components/frame/error-summary/error-summary.d.ts +40 -0
  177. package/dist/components/frame/error-summary/error-summary.d.ts.map +1 -0
  178. package/dist/components/frame/error-summary/error-summary.js +32 -0
  179. package/dist/components/frame/error-summary/error-summary.js.map +1 -0
  180. package/dist/components/frame/error-summary/lt-error-summary.d.ts +82 -0
  181. package/dist/components/frame/error-summary/lt-error-summary.d.ts.map +1 -0
  182. package/dist/components/frame/error-summary/lt-error-summary.js +302 -0
  183. package/dist/components/frame/error-summary/lt-error-summary.js.map +1 -0
  184. package/dist/components/frame/field/field-core.d.ts +92 -0
  185. package/dist/components/frame/field/field-core.d.ts.map +1 -0
  186. package/dist/components/frame/field/field-core.js +63 -0
  187. package/dist/components/frame/field/field-core.js.map +1 -0
  188. package/dist/components/frame/field/lt-field.d.ts +173 -0
  189. package/dist/components/frame/field/lt-field.d.ts.map +1 -0
  190. package/dist/components/frame/field/lt-field.js +580 -0
  191. package/dist/components/frame/field/lt-field.js.map +1 -0
  192. package/dist/components/frame/popover/lt-popover.d.ts +132 -0
  193. package/dist/components/frame/popover/lt-popover.d.ts.map +1 -0
  194. package/dist/components/frame/popover/lt-popover.js +490 -0
  195. package/dist/components/frame/popover/lt-popover.js.map +1 -0
  196. package/dist/components/frame/popover/popover.d.ts +49 -0
  197. package/dist/components/frame/popover/popover.d.ts.map +1 -0
  198. package/dist/components/frame/popover/popover.js +64 -0
  199. package/dist/components/frame/popover/popover.js.map +1 -0
  200. package/dist/components/frame/session-timeout/lt-session-timeout.d.ts +198 -0
  201. package/dist/components/frame/session-timeout/lt-session-timeout.d.ts.map +1 -0
  202. package/dist/components/frame/session-timeout/lt-session-timeout.js +573 -0
  203. package/dist/components/frame/session-timeout/lt-session-timeout.js.map +1 -0
  204. package/dist/components/frame/session-timeout/session-timeout.d.ts +113 -0
  205. package/dist/components/frame/session-timeout/session-timeout.d.ts.map +1 -0
  206. package/dist/components/frame/session-timeout/session-timeout.js +101 -0
  207. package/dist/components/frame/session-timeout/session-timeout.js.map +1 -0
  208. package/dist/components/frame/suggestion/lt-suggestion.d.ts +361 -0
  209. package/dist/components/frame/suggestion/lt-suggestion.d.ts.map +1 -0
  210. package/dist/components/frame/suggestion/lt-suggestion.js +1152 -0
  211. package/dist/components/frame/suggestion/lt-suggestion.js.map +1 -0
  212. package/dist/components/frame/suggestion/suggestion.d.ts +143 -0
  213. package/dist/components/frame/suggestion/suggestion.d.ts.map +1 -0
  214. package/dist/components/frame/suggestion/suggestion.js +127 -0
  215. package/dist/components/frame/suggestion/suggestion.js.map +1 -0
  216. package/dist/components/frame/tabs/lt-tabs.d.ts +404 -0
  217. package/dist/components/frame/tabs/lt-tabs.d.ts.map +1 -0
  218. package/dist/components/frame/tabs/lt-tabs.js +1201 -0
  219. package/dist/components/frame/tabs/lt-tabs.js.map +1 -0
  220. package/dist/components/frame/tabs/tabs.d.ts +112 -0
  221. package/dist/components/frame/tabs/tabs.d.ts.map +1 -0
  222. package/dist/components/frame/tabs/tabs.js +107 -0
  223. package/dist/components/frame/tabs/tabs.js.map +1 -0
  224. package/dist/components/host-element.d.ts +135 -0
  225. package/dist/components/host-element.d.ts.map +1 -0
  226. package/dist/components/host-element.js +366 -0
  227. package/dist/components/host-element.js.map +1 -0
  228. package/dist/components/standalone/connection-status/connection-status.d.ts +28 -0
  229. package/dist/components/standalone/connection-status/connection-status.d.ts.map +1 -0
  230. package/dist/components/standalone/connection-status/connection-status.js +22 -0
  231. package/dist/components/standalone/connection-status/connection-status.js.map +1 -0
  232. package/dist/components/standalone/connection-status/lt-connection-status.d.ts +81 -0
  233. package/dist/components/standalone/connection-status/lt-connection-status.d.ts.map +1 -0
  234. package/dist/components/standalone/connection-status/lt-connection-status.js +216 -0
  235. package/dist/components/standalone/connection-status/lt-connection-status.js.map +1 -0
  236. package/dist/components/standalone/toast/lt-toast.d.ts +109 -0
  237. package/dist/components/standalone/toast/lt-toast.d.ts.map +1 -0
  238. package/dist/components/standalone/toast/lt-toast.js +256 -0
  239. package/dist/components/standalone/toast/lt-toast.js.map +1 -0
  240. package/dist/components/standalone/toast/toast.d.ts +52 -0
  241. package/dist/components/standalone/toast/toast.d.ts.map +1 -0
  242. package/dist/components/standalone/toast/toast.js +42 -0
  243. package/dist/components/standalone/toast/toast.js.map +1 -0
  244. package/dist/diagnostics/core.d.ts +137 -0
  245. package/dist/diagnostics/core.d.ts.map +1 -0
  246. package/dist/diagnostics/core.js +72 -0
  247. package/dist/diagnostics/core.js.map +1 -0
  248. package/dist/diagnostics/default-core.d.ts +10 -0
  249. package/dist/diagnostics/default-core.d.ts.map +1 -0
  250. package/dist/diagnostics/default-core.js +72 -0
  251. package/dist/diagnostics/default-core.js.map +1 -0
  252. package/dist/diagnostics/index.d.ts +84 -0
  253. package/dist/diagnostics/index.d.ts.map +1 -0
  254. package/dist/diagnostics/index.js +106 -0
  255. package/dist/diagnostics/index.js.map +1 -0
  256. package/dist/dom.d.ts +55 -0
  257. package/dist/dom.d.ts.map +1 -0
  258. package/dist/dom.js +162 -0
  259. package/dist/dom.js.map +1 -0
  260. package/dist/index.d.ts +97 -0
  261. package/dist/index.d.ts.map +1 -0
  262. package/dist/index.js +58 -0
  263. package/dist/index.js.map +1 -0
  264. package/dist/jsx/react.d.ts +180 -0
  265. package/dist/jsx/react.d.ts.map +1 -0
  266. package/dist/jsx/react.js +2 -0
  267. package/dist/jsx/react.js.map +1 -0
  268. package/dist/lotek.css +3617 -0
  269. package/dist/lt.d.ts +325 -0
  270. package/dist/lt.d.ts.map +1 -0
  271. package/dist/lt.js +183 -0
  272. package/dist/lt.js.map +1 -0
  273. package/dist/react.d.ts +492 -0
  274. package/dist/react.d.ts.map +1 -0
  275. package/dist/react.js +296 -0
  276. package/dist/react.js.map +1 -0
  277. package/dist/register.d.ts +17 -0
  278. package/dist/register.d.ts.map +1 -0
  279. package/dist/register.js +35 -0
  280. package/dist/register.js.map +1 -0
  281. package/dist/tokens/color.d.ts +43 -0
  282. package/dist/tokens/color.d.ts.map +1 -0
  283. package/dist/tokens/color.js +123 -0
  284. package/dist/tokens/color.js.map +1 -0
  285. package/dist/tokens/contract.d.ts +18 -0
  286. package/dist/tokens/contract.d.ts.map +1 -0
  287. package/dist/tokens/contract.js +18 -0
  288. package/dist/tokens/contract.js.map +1 -0
  289. package/dist/tokens/matrix-cells.d.ts +30 -0
  290. package/dist/tokens/matrix-cells.d.ts.map +1 -0
  291. package/dist/tokens/matrix-cells.js +273 -0
  292. package/dist/tokens/matrix-cells.js.map +1 -0
  293. package/dist/tokens/matrix.d.ts +18 -0
  294. package/dist/tokens/matrix.d.ts.map +1 -0
  295. package/dist/tokens/matrix.js +21 -0
  296. package/dist/tokens/matrix.js.map +1 -0
  297. package/dist/tokens/theme-check.d.ts +42 -0
  298. package/dist/tokens/theme-check.d.ts.map +1 -0
  299. package/dist/tokens/theme-check.js +10 -0
  300. package/dist/tokens/theme-check.js.map +1 -0
  301. package/dist/tokens/theme.d.ts +94 -0
  302. package/dist/tokens/theme.d.ts.map +1 -0
  303. package/dist/tokens/theme.js +14 -0
  304. package/dist/tokens/theme.js.map +1 -0
  305. package/dist/tokens/tokens.d.ts +122 -0
  306. package/dist/tokens/tokens.d.ts.map +1 -0
  307. package/dist/tokens/tokens.js +158 -0
  308. package/dist/tokens/tokens.js.map +1 -0
  309. package/dist/vocabulary/classes.d.ts +3 -0
  310. package/dist/vocabulary/classes.d.ts.map +1 -0
  311. package/dist/vocabulary/classes.js +1320 -0
  312. package/dist/vocabulary/classes.js.map +1 -0
  313. package/dist/vocabulary/elements.d.ts +3 -0
  314. package/dist/vocabulary/elements.d.ts.map +1 -0
  315. package/dist/vocabulary/elements.js +410 -0
  316. package/dist/vocabulary/elements.js.map +1 -0
  317. package/dist/vocabulary/types.d.ts +175 -0
  318. package/dist/vocabulary/types.d.ts.map +1 -0
  319. package/dist/vocabulary/types.js +11 -0
  320. package/dist/vocabulary/types.js.map +1 -0
  321. package/dist/wasi-host.d.ts +24 -0
  322. package/dist/wasi-host.d.ts.map +1 -0
  323. package/dist/wasi-host.js +140 -0
  324. package/dist/wasi-host.js.map +1 -0
  325. package/live-templates.xml +62 -0
  326. package/manifest/files.json +373 -0
  327. package/manifest/manifest.json +4965 -0
  328. package/manifest/manifest.schema.json +513 -0
  329. package/package.json +398 -5
  330. package/src/cli.ts +21 -0
  331. package/src/components/css/accordion/accordion.css +102 -0
  332. package/src/components/css/accordion/accordion.ts +50 -0
  333. package/src/components/css/alert/alert.css +53 -0
  334. package/src/components/css/alert/alert.ts +48 -0
  335. package/src/components/css/avatar/avatar.css +96 -0
  336. package/src/components/css/avatar/avatar.ts +57 -0
  337. package/src/components/css/badge/badge.css +42 -0
  338. package/src/components/css/badge/badge.ts +43 -0
  339. package/src/components/css/breadcrumbs/breadcrumbs.css +62 -0
  340. package/src/components/css/breadcrumbs/breadcrumbs.ts +30 -0
  341. package/src/components/css/button/button.css +128 -0
  342. package/src/components/css/button/button.ts +44 -0
  343. package/src/components/css/card/card.css +65 -0
  344. package/src/components/css/card/card.ts +50 -0
  345. package/src/components/css/checkbox/checkbox.css +114 -0
  346. package/src/components/css/checkbox/checkbox.ts +50 -0
  347. package/src/components/css/divider/divider.css +38 -0
  348. package/src/components/css/divider/divider.ts +42 -0
  349. package/src/components/css/error-text/error-text.css +21 -0
  350. package/src/components/css/error-text/error-text.ts +37 -0
  351. package/src/components/css/fieldset/fieldset.css +72 -0
  352. package/src/components/css/fieldset/fieldset.ts +87 -0
  353. package/src/components/css/file-upload/file-upload.css +102 -0
  354. package/src/components/css/file-upload/file-upload.ts +65 -0
  355. package/src/components/css/heading/heading.css +33 -0
  356. package/src/components/css/heading/heading.ts +42 -0
  357. package/src/components/css/help-text/help-text.css +24 -0
  358. package/src/components/css/help-text/help-text.ts +42 -0
  359. package/src/components/css/icon/icon.css +20 -0
  360. package/src/components/css/icon/icon.ts +44 -0
  361. package/src/components/css/input/input.css +145 -0
  362. package/src/components/css/input/input.ts +77 -0
  363. package/src/components/css/label/label.css +42 -0
  364. package/src/components/css/label/label.ts +51 -0
  365. package/src/components/css/link/link.css +38 -0
  366. package/src/components/css/link/link.ts +38 -0
  367. package/src/components/css/list/list.css +53 -0
  368. package/src/components/css/list/list.ts +44 -0
  369. package/src/components/css/pagination/pagination.css +95 -0
  370. package/src/components/css/pagination/pagination.ts +33 -0
  371. package/src/components/css/paragraph/paragraph.css +31 -0
  372. package/src/components/css/paragraph/paragraph.ts +53 -0
  373. package/src/components/css/progress/progress.css +161 -0
  374. package/src/components/css/progress/progress.ts +78 -0
  375. package/src/components/css/radio/radio.css +94 -0
  376. package/src/components/css/radio/radio.ts +50 -0
  377. package/src/components/css/search/search.css +50 -0
  378. package/src/components/css/search/search.ts +56 -0
  379. package/src/components/css/select/select.css +321 -0
  380. package/src/components/css/select/select.ts +63 -0
  381. package/src/components/css/shared.ts +199 -0
  382. package/src/components/css/skeleton/skeleton.css +62 -0
  383. package/src/components/css/skeleton/skeleton.ts +43 -0
  384. package/src/components/css/skip-link/skip-link.css +41 -0
  385. package/src/components/css/skip-link/skip-link.ts +22 -0
  386. package/src/components/css/spinner/spinner.css +48 -0
  387. package/src/components/css/spinner/spinner.ts +48 -0
  388. package/src/components/css/sr-only/sr-only.css +16 -0
  389. package/src/components/css/sr-only/sr-only.ts +21 -0
  390. package/src/components/css/switch/switch.css +105 -0
  391. package/src/components/css/switch/switch.ts +50 -0
  392. package/src/components/css/table/table.css +159 -0
  393. package/src/components/css/table/table.ts +107 -0
  394. package/src/components/css/tag/tag.css +58 -0
  395. package/src/components/css/tag/tag.ts +49 -0
  396. package/src/components/css/textarea/textarea.css +83 -0
  397. package/src/components/css/textarea/textarea.ts +40 -0
  398. package/src/components/css/toggle-group/toggle-group.css +92 -0
  399. package/src/components/css/toggle-group/toggle-group.ts +37 -0
  400. package/src/components/css/tooltip/tooltip.css +89 -0
  401. package/src/components/css/tooltip/tooltip.ts +37 -0
  402. package/src/components/default-texts.ts +34 -0
  403. package/src/components/events.ts +68 -0
  404. package/src/components/frame/dialog/dialog.css +306 -0
  405. package/src/components/frame/dialog/dialog.ts +166 -0
  406. package/src/components/frame/dialog/lt-dialog.ts +510 -0
  407. package/src/components/frame/error-summary/error-summary.css +47 -0
  408. package/src/components/frame/error-summary/error-summary.ts +56 -0
  409. package/src/components/frame/error-summary/lt-error-summary.ts +344 -0
  410. package/src/components/frame/field/field-core.ts +152 -0
  411. package/src/components/frame/field/field.css +17 -0
  412. package/src/components/frame/field/lt-field.ts +753 -0
  413. package/src/components/frame/popover/lt-popover.ts +555 -0
  414. package/src/components/frame/popover/popover.css +50 -0
  415. package/src/components/frame/popover/popover.ts +102 -0
  416. package/src/components/frame/session-timeout/lt-session-timeout.ts +681 -0
  417. package/src/components/frame/session-timeout/session-timeout.css +50 -0
  418. package/src/components/frame/session-timeout/session-timeout.ts +156 -0
  419. package/src/components/frame/suggestion/lt-suggestion.ts +1358 -0
  420. package/src/components/frame/suggestion/suggestion.css +132 -0
  421. package/src/components/frame/suggestion/suggestion.ts +172 -0
  422. package/src/components/frame/tabs/lt-tabs.ts +1319 -0
  423. package/src/components/frame/tabs/tabs.css +128 -0
  424. package/src/components/frame/tabs/tabs.ts +188 -0
  425. package/src/components/host-element.ts +400 -0
  426. package/src/components/standalone/connection-status/connection-status.css +41 -0
  427. package/src/components/standalone/connection-status/connection-status.ts +41 -0
  428. package/src/components/standalone/connection-status/lt-connection-status.ts +242 -0
  429. package/src/components/standalone/toast/lt-toast.ts +300 -0
  430. package/src/components/standalone/toast/toast.css +78 -0
  431. package/src/components/standalone/toast/toast.ts +70 -0
  432. package/src/diagnostics/core.ts +210 -0
  433. package/src/diagnostics/default-core.ts +81 -0
  434. package/src/diagnostics/index.ts +150 -0
  435. package/src/dom.ts +185 -0
  436. package/src/index.ts +218 -0
  437. package/src/jsx/react.ts +212 -0
  438. package/src/lt.ts +192 -0
  439. package/src/react.ts +411 -0
  440. package/src/register.ts +43 -0
  441. package/src/tailwind/tailwind.css +169 -0
  442. package/src/tokens/boundary.css +104 -0
  443. package/src/tokens/color-contract.json +231 -0
  444. package/src/tokens/color.ts +150 -0
  445. package/src/tokens/contract.ts +24 -0
  446. package/src/tokens/matrix-cells.ts +375 -0
  447. package/src/tokens/matrix.ts +32 -0
  448. package/src/tokens/theme-check.ts +51 -0
  449. package/src/tokens/theme.ts +104 -0
  450. package/src/tokens/tokens.css +569 -0
  451. package/src/tokens/tokens.ts +223 -0
  452. package/src/vocabulary/classes.ts +1322 -0
  453. package/src/vocabulary/elements.ts +412 -0
  454. package/src/vocabulary/types.ts +178 -0
  455. package/src/wasi-host.ts +155 -0
  456. package/web-types.json +800 -0
@@ -0,0 +1,82 @@
1
+ import { HostElement } from "../../host-element.js";
2
+ export declare const LT_ERROR_SUMMARY_TAG: "lt-error-summary";
3
+ /**
4
+ * The parts the error summary looks for, as selectors relative to the
5
+ * element. The component finds its parts with these, and the manifest
6
+ * describes them for whoever assembles the markup by hand, so the two cannot
7
+ * say different things.
8
+ */
9
+ export declare const LT_ERROR_SUMMARY_PARTS: {
10
+ readonly title: "h1, h2, h3, h4, h5, h6";
11
+ readonly link: "li a[href^='#']";
12
+ };
13
+ export declare class LtErrorSummary extends HostElement {
14
+ static observedAttributes: readonly ["data-autofocus", "hidden"];
15
+ private hasFocused;
16
+ /**
17
+ * Whether the component has tried to move focus since the box last became
18
+ * visible.
19
+ *
20
+ * The first attempt happens wherever focus is: a new submission has
21
+ * failed, and that is the message. If it did not land, because the box was
22
+ * in a hidden panel, the component tries again on the next change to the
23
+ * list, but only when nobody is in a field. Without that distinction the
24
+ * retry pulled focus out of the field the user was correcting, as soon as
25
+ * live validation patched the list.
26
+ */
27
+ private focusAttempted;
28
+ private observer?;
29
+ connectedCallback(): void;
30
+ attributeChangedCallback(): void;
31
+ disconnectedCallback(): void;
32
+ /**
33
+ * Whether the box takes focus when it becomes visible. Default: yes.
34
+ *
35
+ * The attribute is called `data-autofocus` and not `autofocus`, even
36
+ * though the latter reads better. `autofocus` is a boolean property on
37
+ * `HTMLElement`, and React 19 sets properties rather than attributes on web
38
+ * components. `autofocus="false"` then became `el.autofocus = "false"`,
39
+ * which is true, while the attribute never reached the markup, and the
40
+ * opt-out did not work. `data-*` is passed on as an attribute in every
41
+ * React version.
42
+ */
43
+ private get shouldFocus();
44
+ /**
45
+ * Fills in what a template without JavaScript did not write. Only what is
46
+ * missing: a role the server chose stays, and so does a `tabindex`.
47
+ */
48
+ private wire;
49
+ private sync;
50
+ /**
51
+ * Takes focus back once, if it went back to where it was.
52
+ *
53
+ * React gives focus back to the element that had it before a commit, right
54
+ * after the DOM has changed. The box moves focus as `hidden` is removed or
55
+ * as it is connected, that is inside the same commit, so focus ended up on
56
+ * the submit button again in Chromium and Firefox, and on the field in all
57
+ * three engines when the form was submitted with Enter. A microtask runs
58
+ * after the commit. If focus is then on the same element as before, the
59
+ * framework took it, and the box takes it again. If a script has moved
60
+ * focus somewhere else, it stays.
61
+ *
62
+ * Only when the box is directly in the document. React does not enter a
63
+ * shadow root when it restores focus, and there `document.activeElement`
64
+ * is the shadow host both before and after, so the comparison would take
65
+ * focus from a field in the same root. The condition is deliberately
66
+ * coarse: a box portalled into a shadow root from a React app in plain DOM
67
+ * does not take focus back.
68
+ */
69
+ private reclaimFocusFrom;
70
+ /**
71
+ * The element a link points to.
72
+ *
73
+ * The lookup goes to the root the component is in, not to `document`. If
74
+ * the form is in a shadow root, as in a preview or inside another
75
+ * component, `document.getElementById` finds nothing, and the link becomes
76
+ * a plain anchor link without moving focus.
77
+ */
78
+ private resolveTarget;
79
+ private handleLinkClick;
80
+ }
81
+ export declare function defineLtErrorSummary(tagName?: string): void;
82
+ //# sourceMappingURL=lt-error-summary.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lt-error-summary.d.ts","sourceRoot":"","sources":["../../../../src/components/frame/error-summary/lt-error-summary.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,WAAW,EAGZ,MAAM,uBAAuB,CAAA;AAK9B,eAAO,MAAM,oBAAoB,EAAG,kBAA2B,CAAA;AAE/D;;;;;GAKG;AACH,eAAO,MAAM,sBAAsB;;;CAGzB,CAAA;AA0CV,qBAAa,cAAe,SAAQ,WAAW;IAC7C,MAAM,CAAC,kBAAkB,wCAAwC;IAEjE,OAAO,CAAC,UAAU,CAAQ;IAC1B;;;;;;;;;;OAUG;IACH,OAAO,CAAC,cAAc,CAAQ;IAC9B,OAAO,CAAC,QAAQ,CAAC,CAAkB;IAEnC,iBAAiB,IAAI,IAAI;IAmBzB,wBAAwB,IAAI,IAAI;IAOhC,oBAAoB,IAAI,IAAI;IAM5B;;;;;;;;;;OAUG;IACH,OAAO,KAAK,WAAW,GAEtB;IAED;;;OAGG;IACH,OAAO,CAAC,IAAI;IAWZ,OAAO,CAAC,IAAI;IA2FZ;;;;;;;;;;;;;;;;;;OAkBG;IACH,OAAO,CAAC,gBAAgB;IAWxB;;;;;;;OAOG;IACH,OAAO,CAAC,aAAa;IAarB,OAAO,CAAC,eAAe,CAwCtB;CACF;AAYD,wBAAgB,oBAAoB,CAClC,OAAO,GAAE,MAA6B,GACrC,IAAI,CAEN"}
@@ -0,0 +1,302 @@
1
+ import { addClass, defineElement, HostElement, setAttr, warnAboutMarkup, } from "../../host-element.js";
2
+ import { ERROR_SUMMARY_CLASS, ERROR_SUMMARY_TITLE_CLASS, } from "./error-summary.js";
3
+ export const LT_ERROR_SUMMARY_TAG = "lt-error-summary";
4
+ /**
5
+ * The parts the error summary looks for, as selectors relative to the
6
+ * element. The component finds its parts with these, and the manifest
7
+ * describes them for whoever assembles the markup by hand, so the two cannot
8
+ * say different things.
9
+ */
10
+ export const LT_ERROR_SUMMARY_PARTS = {
11
+ title: "h1, h2, h3, h4, h5, h6",
12
+ link: "li a[href^='#']",
13
+ };
14
+ /**
15
+ * Takes the user from an error in the summary to the field that failed.
16
+ *
17
+ * The server writes the content: the heading and the list of links. When the
18
+ * markup is written with JavaScript, `lt.errorSummary()` also writes the
19
+ * class, `role="alert"` and `tabindex="-1"` on the box, and the component
20
+ * leaves them alone. When the markup comes from a template without
21
+ * JavaScript, the component fills in those three and the class on the
22
+ * heading, and sets them back when a patch removes them. The component
23
+ * creates no nodes: it used to, and then the heading disappeared on the
24
+ * first morph in Datastar and never came back.
25
+ *
26
+ * What is left are two things the browser does not do by itself:
27
+ *
28
+ * 1. Focus moves to the box when it becomes visible, so someone listening to
29
+ * the page learns that the submission stopped.
30
+ * 2. Focus goes to the control itself when a link is followed. A plain anchor
31
+ * link only gives focus to a target that can take it; if it points to a
32
+ * label or a heading, `document.activeElement` becomes `<body>`, and the
33
+ * screen reader is not told where the user is. Tab continues from the
34
+ * target either way.
35
+ *
36
+ * ```html
37
+ * <lt-error-summary>
38
+ * <h2>The form has two errors</h2>
39
+ * <ul class="lt-list">
40
+ * <li><a href="#email">Enter a valid email address</a></li>
41
+ * </ul>
42
+ * </lt-error-summary>
43
+ * ```
44
+ */
45
+ /** Decodes a fragment, and returns it untouched if it is not valid. */
46
+ function decodeFragment(fragment) {
47
+ try {
48
+ return decodeURIComponent(fragment);
49
+ }
50
+ catch {
51
+ return fragment;
52
+ }
53
+ }
54
+ export class LtErrorSummary extends HostElement {
55
+ constructor() {
56
+ super(...arguments);
57
+ this.hasFocused = false;
58
+ /**
59
+ * Whether the component has tried to move focus since the box last became
60
+ * visible.
61
+ *
62
+ * The first attempt happens wherever focus is: a new submission has
63
+ * failed, and that is the message. If it did not land, because the box was
64
+ * in a hidden panel, the component tries again on the next change to the
65
+ * list, but only when nobody is in a field. Without that distinction the
66
+ * retry pulled focus out of the field the user was correcting, as soon as
67
+ * live validation patched the list.
68
+ */
69
+ this.focusAttempted = false;
70
+ this.handleLinkClick = (event) => {
71
+ const link = event.target?.closest?.(LT_ERROR_SUMMARY_PARTS.link);
72
+ if (!link || !this.contains(link))
73
+ return;
74
+ const id = link.getAttribute("href")?.slice(1);
75
+ if (!id)
76
+ return;
77
+ // The guard stays for the race: the target may have disappeared in a
78
+ // patch between the sync and the click. `sync()` has already reported a
79
+ // link that never had a target.
80
+ const target = this.resolveTarget(id);
81
+ if (!target)
82
+ return;
83
+ event.preventDefault();
84
+ // If the link is to a label, focus goes to what the label belongs to,
85
+ // whether it points with `for` or wraps the control. `control` covers
86
+ // both for real controls; if `for` points to something else, such as a
87
+ // group, the id is followed there.
88
+ const focusable = target instanceof HTMLLabelElement
89
+ ? (target.control ??
90
+ (target.htmlFor ? this.resolveTarget(target.htmlFor) : null) ??
91
+ target)
92
+ : target;
93
+ // A target that cannot take focus, such as a heading, gets a `tabindex`
94
+ // for this one jump. It is a write on markup that comes from the server,
95
+ // and a patch may remove it again; by then the jump has happened.
96
+ if (!focusable.hasAttribute("tabindex") && !isFocusable(focusable)) {
97
+ setAttr(focusable, "tabindex", "-1");
98
+ }
99
+ focusable.focus();
100
+ // Without `behavior`: the page's own `scroll-behavior` decides. The
101
+ // browser does not turn off `smooth` by itself under
102
+ // `prefers-reduced-motion`, so that is up to the page, and "Accessibility"
103
+ // in the documentation says so.
104
+ focusable.scrollIntoView({ block: "center" });
105
+ };
106
+ }
107
+ connectedCallback() {
108
+ // One listener on the host, not one per link. The set of links was only
109
+ // emptied on disconnect, so every link a patch replaced stayed in
110
+ // memory.
111
+ this.addEventListener("click", this.handleLinkClick);
112
+ // The errors come and go while the user corrects them, and `slotchange`
113
+ // does not fire in plain DOM. The attributes are the ones the component
114
+ // fills in itself, so a patch that removes them gets them back. Every
115
+ // write compares first, or the observer would trigger itself.
116
+ this.observer = new MutationObserver(() => this.sync());
117
+ this.observer.observe(this, {
118
+ childList: true,
119
+ subtree: true,
120
+ attributes: true,
121
+ attributeFilter: ["class", "role", "tabindex"],
122
+ });
123
+ this.sync();
124
+ }
125
+ attributeChangedCallback() {
126
+ // The server can send the box hidden and later only remove `hidden` on
127
+ // the same node. Without this, a summary that just became visible never
128
+ // gets focus, and that is the whole reason the component exists.
129
+ if (this.isConnected)
130
+ this.sync();
131
+ }
132
+ disconnectedCallback() {
133
+ this.observer?.disconnect();
134
+ this.observer = undefined;
135
+ this.removeEventListener("click", this.handleLinkClick);
136
+ }
137
+ /**
138
+ * Whether the box takes focus when it becomes visible. Default: yes.
139
+ *
140
+ * The attribute is called `data-autofocus` and not `autofocus`, even
141
+ * though the latter reads better. `autofocus` is a boolean property on
142
+ * `HTMLElement`, and React 19 sets properties rather than attributes on web
143
+ * components. `autofocus="false"` then became `el.autofocus = "false"`,
144
+ * which is true, while the attribute never reached the markup, and the
145
+ * opt-out did not work. `data-*` is passed on as an attribute in every
146
+ * React version.
147
+ */
148
+ get shouldFocus() {
149
+ return this.dataset.autofocus !== "false";
150
+ }
151
+ /**
152
+ * Fills in what a template without JavaScript did not write. Only what is
153
+ * missing: a role the server chose stays, and so does a `tabindex`.
154
+ */
155
+ wire() {
156
+ addClass(this, ERROR_SUMMARY_CLASS);
157
+ if (!this.hasAttribute("role"))
158
+ setAttr(this, "role", "alert");
159
+ // Without `tabindex`, `focus()` does nothing, and the whole reason for
160
+ // the component silently disappears.
161
+ if (!this.hasAttribute("tabindex"))
162
+ setAttr(this, "tabindex", "-1");
163
+ const title = this.querySelector(LT_ERROR_SUMMARY_PARTS.title);
164
+ if (title)
165
+ addClass(title, ERROR_SUMMARY_TITLE_CLASS);
166
+ }
167
+ sync() {
168
+ this.wire();
169
+ const links = [
170
+ ...this.querySelectorAll(LT_ERROR_SUMMARY_PARTS.link),
171
+ ];
172
+ // If the server hides the box again, that submission is over. Without
173
+ // this reset the box only took focus the first time: the pattern in a
174
+ // Datastar app is that the list keeps the same links throughout and only
175
+ // `hidden` is toggled, so "have I moved focus here before" does not
176
+ // answer whether this is a new submission. It comes before the return
177
+ // for an empty list: React removes the items before it sets `hidden` on
178
+ // the host, so the list is already empty in the round where the box is
179
+ // hidden.
180
+ if (this.hidden) {
181
+ this.hasFocused = false;
182
+ this.focusAttempted = false;
183
+ }
184
+ if (links.length === 0) {
185
+ // The flags are not reset by an empty list, only by `hidden` above. A
186
+ // visible list that is emptied and filled while the user corrects
187
+ // would otherwise pull focus out of the field they were in.
188
+ warnAboutMarkup(this, "found no links to the fields. Each item needs an <a " +
189
+ 'href="#id"> pointing to the control or its label, or the user ' +
190
+ "cannot get from the error to the field.",
191
+ // An empty box is not an error: the pattern is that the server leaves
192
+ // it with `hidden` and fills it when the submission fails. A box with
193
+ // items but no links to the fields is something else.
194
+ () => this.querySelector("li") !== null &&
195
+ this.querySelector(LT_ERROR_SUMMARY_PARTS.link) === null);
196
+ return;
197
+ }
198
+ for (const link of links) {
199
+ /*
200
+ * A link that leads nowhere, reported here and not only on a click.
201
+ *
202
+ * The check used to be only in the click handler, and then a box with a
203
+ * link to a field that does not exist was completely silent until
204
+ * someone actually followed it. An error summary is read by someone who
205
+ * just failed with a form, and a link that does not work is exactly
206
+ * what makes the box worthless. The id is in the message, and each link
207
+ * has its own, so a box with two broken links reports both.
208
+ */
209
+ const id = link.getAttribute("href")?.slice(1);
210
+ if (id) {
211
+ warnAboutMarkup(this, `the link points to #${id}, but no element has that id. The link scrolls nowhere, and focus stays where it is.`, () => this.resolveTarget(id) === null);
212
+ }
213
+ }
214
+ if (this.hidden)
215
+ return;
216
+ // If the box is visible now and we have not moved focus here yet, it is
217
+ // this submission that failed. The flag is only set when focus actually
218
+ // landed: if the box is in a hidden panel or a closed dialog, `focus()`
219
+ // does nothing, and the next attempt is then allowed, as long as nobody
220
+ // is in a field.
221
+ if (this.shouldFocus && !this.hasFocused) {
222
+ // `document.activeElement` and not the root's: if the box is in a
223
+ // shadow root and the field in plain DOM, the root's `activeElement` is
224
+ // null, and the user would have counted as "nobody". The document's
225
+ // points to the shadow host when focus is in a shadow tree, and is
226
+ // never null for a field on the page.
227
+ const active = document.activeElement;
228
+ const nobodyTyping = !active || active === document.body;
229
+ if (this.focusAttempted && !nobodyTyping)
230
+ return;
231
+ const root = this.getRootNode();
232
+ this.focusAttempted = true;
233
+ this.focus();
234
+ this.hasFocused = root.activeElement === this;
235
+ if (this.hasFocused &&
236
+ root === document &&
237
+ active &&
238
+ active !== document.body)
239
+ this.reclaimFocusFrom(active);
240
+ }
241
+ }
242
+ /**
243
+ * Takes focus back once, if it went back to where it was.
244
+ *
245
+ * React gives focus back to the element that had it before a commit, right
246
+ * after the DOM has changed. The box moves focus as `hidden` is removed or
247
+ * as it is connected, that is inside the same commit, so focus ended up on
248
+ * the submit button again in Chromium and Firefox, and on the field in all
249
+ * three engines when the form was submitted with Enter. A microtask runs
250
+ * after the commit. If focus is then on the same element as before, the
251
+ * framework took it, and the box takes it again. If a script has moved
252
+ * focus somewhere else, it stays.
253
+ *
254
+ * Only when the box is directly in the document. React does not enter a
255
+ * shadow root when it restores focus, and there `document.activeElement`
256
+ * is the shadow host both before and after, so the comparison would take
257
+ * focus from a field in the same root. The condition is deliberately
258
+ * coarse: a box portalled into a shadow root from a React app in plain DOM
259
+ * does not take focus back.
260
+ */
261
+ reclaimFocusFrom(previous) {
262
+ queueMicrotask(() => {
263
+ if (this.isConnected &&
264
+ !this.hidden &&
265
+ document.activeElement === previous)
266
+ this.focus();
267
+ });
268
+ }
269
+ /**
270
+ * The element a link points to.
271
+ *
272
+ * The lookup goes to the root the component is in, not to `document`. If
273
+ * the form is in a shadow root, as in a preview or inside another
274
+ * component, `document.getElementById` finds nothing, and the link becomes
275
+ * a plain anchor link without moving focus.
276
+ */
277
+ resolveTarget(raw) {
278
+ const root = this.getRootNode();
279
+ // A link to a field with non-ASCII characters in its id is often
280
+ // percent-encoded, `#f%C3%B8dselsdato`. The browser decodes it when the
281
+ // link is followed, so the lookup must do the same, or a working link is
282
+ // reported.
283
+ for (const id of new Set([raw, decodeFragment(raw)])) {
284
+ const target = root.getElementById?.(id) ?? document.getElementById(id);
285
+ if (target)
286
+ return target;
287
+ }
288
+ return null;
289
+ }
290
+ }
291
+ LtErrorSummary.observedAttributes = ["data-autofocus", "hidden"];
292
+ function isFocusable(element) {
293
+ return (element instanceof HTMLInputElement ||
294
+ element instanceof HTMLSelectElement ||
295
+ element instanceof HTMLTextAreaElement ||
296
+ element instanceof HTMLButtonElement ||
297
+ element instanceof HTMLAnchorElement);
298
+ }
299
+ export function defineLtErrorSummary(tagName = LT_ERROR_SUMMARY_TAG) {
300
+ defineElement(tagName, LtErrorSummary);
301
+ }
302
+ //# sourceMappingURL=lt-error-summary.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lt-error-summary.js","sourceRoot":"","sources":["../../../../src/components/frame/error-summary/lt-error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,CAAC;QACD,OAAO,IAAI,CAAA;IACb,CAAC;;AA3NM,iCAAkB,GAAG,CAAC,gBAAgB,EAAE,QAAQ,CAAU,AAAxC,CAAwC;AAwQnE,SAAS,WAAW,CAAC,OAAgB;IACnC,OAAO,CACL,OAAO,YAAY,gBAAgB;QACnC,OAAO,YAAY,iBAAiB;QACpC,OAAO,YAAY,mBAAmB;QACtC,OAAO,YAAY,iBAAiB;QACpC,OAAO,YAAY,iBAAiB,CACrC,CAAA;AACH,CAAC;AAED,MAAM,UAAU,oBAAoB,CAClC,UAAkB,oBAAoB;IAEtC,aAAa,CAAC,OAAO,EAAE,cAAc,CAAC,CAAA;AACxC,CAAC"}
@@ -0,0 +1,92 @@
1
+ import type { FieldState, RequiredMarker } from "../../css/shared.js";
2
+ import { createFieldId } from "../../css/shared.js";
3
+ export { createFieldId };
4
+ /**
5
+ * Computes the wiring between label, field, help text and error text.
6
+ *
7
+ * This is the one implementation of the accessibility contract in the system.
8
+ * `<lt-field>` applies it to elements already in the DOM, and `lt.field()`
9
+ * returns the same result as data, for whoever writes the markup with
10
+ * JavaScript. Without sharing it, the contract would exist in two places and
11
+ * could drift apart.
12
+ */
13
+ export type FieldOptions = {
14
+ /**
15
+ * The id of the control. Required.
16
+ *
17
+ * In React it comes from `useId()`. Otherwise the field's name is usually
18
+ * the obvious choice. If you know for certain that the markup is rendered
19
+ * once, call `createFieldId()` yourself.
20
+ *
21
+ * It used to be optional, and the function created one when it was
22
+ * missing. That id is random, so two runs give two different ones, and if
23
+ * the same field is rendered on a server and then in the browser, `for`
24
+ * and `aria-describedby` point to something other than what is there.
25
+ * React reports a mismatch on hydration, and the warning itself says the
26
+ * mismatch is not repaired.
27
+ *
28
+ * The type requires it, and that is not enough on its own: a consumer
29
+ * without TypeScript sees no type. If the id is left out anyway, the
30
+ * function creates one and says so in the console. The field then works,
31
+ * and the developer learns why the id should be given anyway. Without the
32
+ * fallback they got `for=""`, `aria-describedby="undefined-help"` and no
33
+ * wiring at all, which is worse than the unstable id the requirement was
34
+ * meant to remove.
35
+ */
36
+ id: string;
37
+ /** The field has a help text to connect with `aria-describedby`. */
38
+ help?: boolean;
39
+ /** The field has an error text. It is hidden until the field is invalid. */
40
+ error?: boolean;
41
+ /** A separate id for the help text. Derived from `id` if left out. */
42
+ helpId?: string;
43
+ /** A separate id for the error text. Derived from `id` if left out. */
44
+ errorId?: string;
45
+ /** Marks the label as required. */
46
+ required?: RequiredMarker;
47
+ /** Marks the label as optional. */
48
+ optional?: boolean;
49
+ /** The field is invalid: shows the error text and sets `aria-invalid`. */
50
+ invalid?: boolean;
51
+ /** The control is disabled. */
52
+ disabled?: boolean;
53
+ /** Extra ids to include in `aria-describedby`. */
54
+ describedBy?: string[];
55
+ };
56
+ export type FieldAttributes = {
57
+ label: {
58
+ class: "lt-label";
59
+ for: string;
60
+ "data-required"?: RequiredMarker;
61
+ "data-optional"?: "";
62
+ "aria-disabled"?: "true";
63
+ };
64
+ control: {
65
+ id: string;
66
+ "aria-describedby"?: string;
67
+ "aria-invalid"?: "true";
68
+ "data-state"?: "invalid";
69
+ disabled?: true;
70
+ };
71
+ help: {
72
+ id: string;
73
+ };
74
+ error: {
75
+ id: string;
76
+ hidden?: true;
77
+ };
78
+ /** The state the control should have, for `input()`, `textarea()` and `select()`. */
79
+ state: FieldState;
80
+ };
81
+ /**
82
+ * Joins `aria-describedby` from the help text, the error text and whatever
83
+ * the caller added.
84
+ *
85
+ * The error text is only included when the field is actually invalid.
86
+ * Otherwise `aria-describedby` would point to a hidden element, and screen
87
+ * readers then announce either nothing or something that is not on the
88
+ * screen.
89
+ */
90
+ export declare function joinDescribedBy(ids: Array<string | undefined | false>): string | undefined;
91
+ export declare function computeFieldAttributes(options: FieldOptions): FieldAttributes;
92
+ //# sourceMappingURL=field-core.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"field-core.d.ts","sourceRoot":"","sources":["../../../../src/components/frame/field/field-core.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK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AK,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,IAAI,CAAA;KAAE,CAAA;IACpC,qFAAqF;IACrF,KAAK,EAAE,UAAU,CAAA;CAClB,CAAA;AAED;;;;;;;;GAQG;AACH,wBAAgB,eAAe,CAC7B,GAAG,EAAE,KAAK,CAAC,MAAM,GAAG,SAAS,GAAG,KAAK,CAAC,GACrC,MAAM,GAAG,SAAS,CASpB;AAED,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,YAAY,GAAG,eAAe,CA+C7E"}
@@ -0,0 +1,63 @@
1
+ import { attributes, createFieldId, idOrFallback } from "../../css/shared.js";
2
+ // Re-exported here, where it used to live, so consumers that import from
3
+ // `./field-core` do not notice the move.
4
+ export { createFieldId };
5
+ /**
6
+ * Joins `aria-describedby` from the help text, the error text and whatever
7
+ * the caller added.
8
+ *
9
+ * The error text is only included when the field is actually invalid.
10
+ * Otherwise `aria-describedby` would point to a hidden element, and screen
11
+ * readers then announce either nothing or something that is not on the
12
+ * screen.
13
+ */
14
+ export function joinDescribedBy(ids) {
15
+ const unique = new Set();
16
+ for (const id of ids) {
17
+ if (!id)
18
+ continue;
19
+ for (const part of id.split(/\s+/)) {
20
+ if (part)
21
+ unique.add(part);
22
+ }
23
+ }
24
+ return unique.size > 0 ? [...unique].join(" ") : undefined;
25
+ }
26
+ export function computeFieldAttributes(options) {
27
+ const { id: givenId, help = false, error = false, required, optional, invalid = false, disabled = false, describedBy = [], } = options;
28
+ // The fallback is only for callers without a type check. See `idOrFallback`.
29
+ const id = idOrFallback("lt.field()", givenId);
30
+ const helpId = options.helpId ?? `${id}-help`;
31
+ const errorId = options.errorId ?? `${id}-error`;
32
+ return {
33
+ label: attributes({
34
+ class: "lt-label",
35
+ for: id,
36
+ "data-required": required,
37
+ "data-optional": optional && !required ? "" : undefined,
38
+ "aria-disabled": disabled ? "true" : undefined,
39
+ }),
40
+ control: attributes({
41
+ id,
42
+ "aria-describedby": joinDescribedBy([
43
+ help && helpId,
44
+ invalid && error && errorId,
45
+ ...describedBy,
46
+ ]),
47
+ "aria-invalid": invalid ? "true" : undefined,
48
+ // The colour comes from here, not from input()/textarea()/select().
49
+ // Otherwise both would set aria-invalid, and in templates that write
50
+ // the attributes out literally, such as Astro and plain HTML, it
51
+ // appeared twice.
52
+ "data-state": invalid ? "invalid" : undefined,
53
+ disabled: disabled ? true : undefined,
54
+ }),
55
+ help: attributes({ id: helpId }),
56
+ error: attributes({
57
+ id: errorId,
58
+ hidden: invalid ? undefined : true,
59
+ }),
60
+ state: invalid ? "invalid" : "default",
61
+ };
62
+ }
63
+ //# sourceMappingURL=field-core.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"field-core.js","sourceRoot":"","sources":["../../../../src/components/frame/field/field-core.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAA;AAE7E,yEAAyE;AACzE,yCAAyC;AACzC,OAAO,EAAE,aAAa,EAAE,CAAA;AA6ExB;;;;;;;;GAQG;AACH,MAAM,UAAU,eAAe,CAC7B,GAAsC;IAEtC,MAAM,MAAM,GAAG,IAAI,GAAG,EAAU,CAAA;IAChC,KAAK,MAAM,EAAE,IAAI,GAAG,EAAE,CAAC;QACrB,IAAI,CAAC,EAAE;YAAE,SAAQ;QACjB,KAAK,MAAM,IAAI,IAAI,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC;YACnC,IAAI,IAAI;gBAAE,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,CAAA;QAC5B,CAAC;IACH,CAAC;IACD,OAAO,MAAM,CAAC,IAAI,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,CAAA;AAC5D,CAAC;AAED,MAAM,UAAU,sBAAsB,CAAC,OAAqB;IAC1D,MAAM,EACJ,EAAE,EA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