@tai42/studio-sdk 16.0.0 → 17.0.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 (486) hide show
  1. package/dist/components/code-block.js +1 -1
  2. package/dist/components/code-block.js.map +1 -1
  3. package/dist/components/confirm-dialog.js +1 -1
  4. package/dist/components/confirm-dialog.js.map +1 -1
  5. package/dist/components/copy-field.js +1 -1
  6. package/dist/components/copy-field.js.map +1 -1
  7. package/dist/components/date-range-picker.d.ts.map +1 -1
  8. package/dist/components/date-range-picker.js.map +1 -1
  9. package/dist/components/dialog.d.ts.map +1 -1
  10. package/dist/components/dialog.js.map +1 -1
  11. package/dist/components/dirty-guard.d.ts.map +1 -1
  12. package/dist/components/dirty-guard.js +1 -1
  13. package/dist/components/dirty-guard.js.map +1 -1
  14. package/dist/components/explorer-body.d.ts +49 -0
  15. package/dist/components/explorer-body.d.ts.map +1 -0
  16. package/dist/components/explorer-body.js +67 -0
  17. package/dist/components/explorer-body.js.map +1 -0
  18. package/dist/components/explorer-page-size.d.ts +4 -0
  19. package/dist/components/explorer-page-size.d.ts.map +1 -0
  20. package/dist/components/explorer-page-size.js +36 -0
  21. package/dist/components/explorer-page-size.js.map +1 -0
  22. package/dist/components/explorer-tag-filter.d.ts +17 -0
  23. package/dist/components/explorer-tag-filter.d.ts.map +1 -0
  24. package/dist/components/explorer-tag-filter.js +29 -0
  25. package/dist/components/explorer-tag-filter.js.map +1 -0
  26. package/dist/components/explorer-tags.d.ts +22 -0
  27. package/dist/components/explorer-tags.d.ts.map +1 -0
  28. package/dist/components/explorer-tags.js +51 -0
  29. package/dist/components/explorer-tags.js.map +1 -0
  30. package/dist/components/explorer-view.d.ts +3 -17
  31. package/dist/components/explorer-view.d.ts.map +1 -1
  32. package/dist/components/explorer-view.js +53 -170
  33. package/dist/components/explorer-view.js.map +1 -1
  34. package/dist/components/extension-combo-builder.d.ts +1 -6
  35. package/dist/components/extension-combo-builder.d.ts.map +1 -1
  36. package/dist/components/extension-combo-builder.js +4 -79
  37. package/dist/components/extension-combo-builder.js.map +1 -1
  38. package/dist/components/extension-combo-parts.d.ts +44 -0
  39. package/dist/components/extension-combo-parts.d.ts.map +1 -0
  40. package/dist/components/extension-combo-parts.js +52 -0
  41. package/dist/components/extension-combo-parts.js.map +1 -0
  42. package/dist/components/field.d.ts +8 -0
  43. package/dist/components/field.d.ts.map +1 -1
  44. package/dist/components/field.js +0 -8
  45. package/dist/components/field.js.map +1 -1
  46. package/dist/components/fleet-report.d.ts +1 -1
  47. package/dist/components/fleet-report.d.ts.map +1 -1
  48. package/dist/components/fleet-report.js +51 -37
  49. package/dist/components/fleet-report.js.map +1 -1
  50. package/dist/components/folder-nav.d.ts.map +1 -1
  51. package/dist/components/folder-nav.js +1 -1
  52. package/dist/components/folder-nav.js.map +1 -1
  53. package/dist/components/form-dialog.d.ts.map +1 -1
  54. package/dist/components/form-dialog.js +1 -1
  55. package/dist/components/form-dialog.js.map +1 -1
  56. package/dist/components/icons/chrome-marks.d.ts +50 -0
  57. package/dist/components/icons/chrome-marks.d.ts.map +1 -0
  58. package/dist/components/icons/chrome-marks.js +51 -0
  59. package/dist/components/icons/chrome-marks.js.map +1 -0
  60. package/dist/components/icons/icon-frame.d.ts +29 -0
  61. package/dist/components/icons/icon-frame.d.ts.map +1 -0
  62. package/dist/components/icons/icon-frame.js +19 -0
  63. package/dist/components/icons/icon-frame.js.map +1 -0
  64. package/dist/components/icons/index.d.ts +40 -0
  65. package/dist/components/icons/index.d.ts.map +1 -0
  66. package/dist/components/icons/index.js +39 -0
  67. package/dist/components/icons/index.js.map +1 -0
  68. package/dist/components/icons/nav-map.d.ts +14 -0
  69. package/dist/components/icons/nav-map.d.ts.map +1 -0
  70. package/dist/components/icons/nav-map.js +28 -0
  71. package/dist/components/icons/nav-map.js.map +1 -0
  72. package/dist/components/icons/nav-marks.d.ts +44 -0
  73. package/dist/components/icons/nav-marks.d.ts.map +1 -0
  74. package/dist/components/icons/nav-marks.js +45 -0
  75. package/dist/components/icons/nav-marks.js.map +1 -0
  76. package/dist/components/icons/status-marks.d.ts +21 -0
  77. package/dist/components/icons/status-marks.d.ts.map +1 -0
  78. package/dist/components/icons/status-marks.js +22 -0
  79. package/dist/components/icons/status-marks.js.map +1 -0
  80. package/dist/components/icons/theme-marks.d.ts +9 -0
  81. package/dist/components/icons/theme-marks.d.ts.map +1 -0
  82. package/dist/components/icons/theme-marks.js +10 -0
  83. package/dist/components/icons/theme-marks.js.map +1 -0
  84. package/dist/components/inputs.js.map +1 -1
  85. package/dist/components/json-diff.d.ts.map +1 -1
  86. package/dist/components/json-diff.js +1 -3
  87. package/dist/components/json-diff.js.map +1 -1
  88. package/dist/components/json-tree-context.d.ts +13 -0
  89. package/dist/components/json-tree-context.d.ts.map +1 -0
  90. package/dist/components/json-tree-context.js +15 -0
  91. package/dist/components/json-tree-context.js.map +1 -0
  92. package/dist/components/json-tree-model.d.ts +56 -0
  93. package/dist/components/json-tree-model.d.ts.map +1 -0
  94. package/dist/components/json-tree-model.js +125 -0
  95. package/dist/components/json-tree-model.js.map +1 -0
  96. package/dist/components/json-tree-nodes.d.ts +35 -0
  97. package/dist/components/json-tree-nodes.d.ts.map +1 -0
  98. package/dist/components/json-tree-nodes.js +113 -0
  99. package/dist/components/json-tree-nodes.js.map +1 -0
  100. package/dist/components/json-tree.d.ts +20 -0
  101. package/dist/components/json-tree.d.ts.map +1 -1
  102. package/dist/components/json-tree.js +7 -315
  103. package/dist/components/json-tree.js.map +1 -1
  104. package/dist/components/json-value-format.d.ts +20 -0
  105. package/dist/components/json-value-format.d.ts.map +1 -0
  106. package/dist/components/json-value-format.js +63 -0
  107. package/dist/components/json-value-format.js.map +1 -0
  108. package/dist/components/markdown-blocks.d.ts +38 -0
  109. package/dist/components/markdown-blocks.d.ts.map +1 -0
  110. package/dist/components/markdown-blocks.js +168 -0
  111. package/dist/components/markdown-blocks.js.map +1 -0
  112. package/dist/components/markdown-inline.d.ts +24 -0
  113. package/dist/components/markdown-inline.d.ts.map +1 -0
  114. package/dist/components/markdown-inline.js +257 -0
  115. package/dist/components/markdown-inline.js.map +1 -0
  116. package/dist/components/markdown.d.ts +3 -52
  117. package/dist/components/markdown.d.ts.map +1 -1
  118. package/dist/components/markdown.js +4 -376
  119. package/dist/components/markdown.js.map +1 -1
  120. package/dist/components/observer-registry.d.ts +38 -0
  121. package/dist/components/observer-registry.d.ts.map +1 -0
  122. package/dist/components/observer-registry.js +131 -0
  123. package/dist/components/observer-registry.js.map +1 -0
  124. package/dist/components/overflow-measure.d.ts +38 -0
  125. package/dist/components/overflow-measure.d.ts.map +1 -0
  126. package/dist/components/overflow-measure.js +54 -0
  127. package/dist/components/overflow-measure.js.map +1 -0
  128. package/dist/components/page-fill.d.ts.map +1 -1
  129. package/dist/components/page-fill.js.map +1 -1
  130. package/dist/components/prose-regions.d.ts +81 -0
  131. package/dist/components/prose-regions.d.ts.map +1 -0
  132. package/dist/components/prose-regions.js +128 -0
  133. package/dist/components/prose-regions.js.map +1 -0
  134. package/dist/components/radio-group.d.ts.map +1 -1
  135. package/dist/components/radio-group.js.map +1 -1
  136. package/dist/components/scroll-region.d.ts +24 -0
  137. package/dist/components/scroll-region.d.ts.map +1 -1
  138. package/dist/components/scroll-region.js +3 -322
  139. package/dist/components/scroll-region.js.map +1 -1
  140. package/dist/components/tab-stop-parse.d.ts +53 -0
  141. package/dist/components/tab-stop-parse.d.ts.map +1 -0
  142. package/dist/components/tab-stop-parse.js +202 -0
  143. package/dist/components/tab-stop-parse.js.map +1 -0
  144. package/dist/components/table.d.ts +1 -1
  145. package/dist/components/table.d.ts.map +1 -1
  146. package/dist/components/tags.d.ts.map +1 -1
  147. package/dist/components/tags.js +1 -1
  148. package/dist/components/tags.js.map +1 -1
  149. package/dist/components/templated-text-field.d.ts +1 -1
  150. package/dist/components/templated-text-field.d.ts.map +1 -1
  151. package/dist/components/templated-text-field.js +10 -174
  152. package/dist/components/templated-text-field.js.map +1 -1
  153. package/dist/components/templated-text-kwargs-editor.d.ts +24 -0
  154. package/dist/components/templated-text-kwargs-editor.d.ts.map +1 -0
  155. package/dist/components/templated-text-kwargs-editor.js +48 -0
  156. package/dist/components/templated-text-kwargs-editor.js.map +1 -0
  157. package/dist/components/templated-text-kwargs.d.ts +37 -0
  158. package/dist/components/templated-text-kwargs.d.ts.map +1 -0
  159. package/dist/components/templated-text-kwargs.js +66 -0
  160. package/dist/components/templated-text-kwargs.js.map +1 -0
  161. package/dist/components/templated-text-source.d.ts +33 -0
  162. package/dist/components/templated-text-source.d.ts.map +1 -0
  163. package/dist/components/templated-text-source.js +53 -0
  164. package/dist/components/templated-text-source.js.map +1 -0
  165. package/dist/components/tool-picker-parts.d.ts +39 -0
  166. package/dist/components/tool-picker-parts.d.ts.map +1 -0
  167. package/dist/components/tool-picker-parts.js +87 -0
  168. package/dist/components/tool-picker-parts.js.map +1 -0
  169. package/dist/components/tool-picker.d.ts +1 -2
  170. package/dist/components/tool-picker.d.ts.map +1 -1
  171. package/dist/components/tool-picker.js +4 -66
  172. package/dist/components/tool-picker.js.map +1 -1
  173. package/dist/components/version-history-panel.d.ts.map +1 -1
  174. package/dist/components/version-history-panel.js +7 -34
  175. package/dist/components/version-history-panel.js.map +1 -1
  176. package/dist/components/version-history-rows.d.ts +48 -0
  177. package/dist/components/version-history-rows.d.ts.map +1 -0
  178. package/dist/components/version-history-rows.js +51 -0
  179. package/dist/components/version-history-rows.js.map +1 -0
  180. package/dist/components/view-toggle.d.ts.map +1 -1
  181. package/dist/components/view-toggle.js.map +1 -1
  182. package/dist/element-slot.d.ts +11 -0
  183. package/dist/element-slot.d.ts.map +1 -1
  184. package/dist/element-slot.js +0 -11
  185. package/dist/element-slot.js.map +1 -1
  186. package/dist/guards.d.ts +6 -0
  187. package/dist/guards.d.ts.map +1 -0
  188. package/dist/guards.js +8 -0
  189. package/dist/guards.js.map +1 -0
  190. package/dist/hooks/interactions-connection.d.ts +43 -0
  191. package/dist/hooks/interactions-connection.d.ts.map +1 -0
  192. package/dist/hooks/interactions-connection.js +171 -0
  193. package/dist/hooks/interactions-connection.js.map +1 -0
  194. package/dist/hooks/interactions-stream.d.ts +80 -0
  195. package/dist/hooks/interactions-stream.d.ts.map +1 -0
  196. package/dist/hooks/interactions-stream.js +233 -0
  197. package/dist/hooks/interactions-stream.js.map +1 -0
  198. package/dist/hooks/useApi.d.ts +2259 -2189
  199. package/dist/hooks/useApi.d.ts.map +1 -1
  200. package/dist/hooks/useApi.js +0 -11
  201. package/dist/hooks/useApi.js.map +1 -1
  202. package/dist/hooks/useAuth.d.ts +6 -0
  203. package/dist/hooks/useAuth.d.ts.map +1 -1
  204. package/dist/hooks/useAuth.js +0 -6
  205. package/dist/hooks/useAuth.js.map +1 -1
  206. package/dist/hooks/useCapabilities.d.ts +18 -2
  207. package/dist/hooks/useCapabilities.d.ts.map +1 -1
  208. package/dist/hooks/useCapabilities.js +1 -17
  209. package/dist/hooks/useCapabilities.js.map +1 -1
  210. package/dist/hooks/useSse.d.ts +34 -6
  211. package/dist/hooks/useSse.d.ts.map +1 -1
  212. package/dist/hooks/useSse.js +27 -471
  213. package/dist/hooks/useSse.js.map +1 -1
  214. package/dist/hooks/useSystemKinds.d.ts +1 -1
  215. package/dist/hooks/useSystemKinds.d.ts.map +1 -1
  216. package/dist/hooks/useSystemKinds.js +0 -18
  217. package/dist/hooks/useSystemKinds.js.map +1 -1
  218. package/dist/hooks/useTheme.d.ts +15 -0
  219. package/dist/hooks/useTheme.d.ts.map +1 -1
  220. package/dist/hooks/useTheme.js +0 -15
  221. package/dist/hooks/useTheme.js.map +1 -1
  222. package/dist/hooks/useToolDisplayNames.d.ts +0 -14
  223. package/dist/hooks/useToolDisplayNames.d.ts.map +1 -1
  224. package/dist/hooks/useToolDisplayNames.js +0 -14
  225. package/dist/hooks/useToolDisplayNames.js.map +1 -1
  226. package/dist/host.d.ts +3 -3
  227. package/dist/host.d.ts.map +1 -1
  228. package/dist/host.js +2 -9
  229. package/dist/host.js.map +1 -1
  230. package/dist/index.d.ts +103 -103
  231. package/dist/index.d.ts.map +1 -1
  232. package/dist/index.js +49 -62
  233. package/dist/index.js.map +1 -1
  234. package/dist/navigation/app-link.d.ts +25 -0
  235. package/dist/navigation/app-link.d.ts.map +1 -0
  236. package/dist/navigation/app-link.js +33 -0
  237. package/dist/navigation/app-link.js.map +1 -0
  238. package/dist/navigation/context.d.ts +3 -20
  239. package/dist/navigation/context.d.ts.map +1 -1
  240. package/dist/navigation/context.js +7 -267
  241. package/dist/navigation/context.js.map +1 -1
  242. package/dist/navigation/entry-state.d.ts +23 -0
  243. package/dist/navigation/entry-state.d.ts.map +1 -0
  244. package/dist/navigation/entry-state.js +39 -0
  245. package/dist/navigation/entry-state.js.map +1 -0
  246. package/dist/navigation/guard-registry.d.ts +30 -0
  247. package/dist/navigation/guard-registry.d.ts.map +1 -0
  248. package/dist/navigation/guard-registry.js +46 -0
  249. package/dist/navigation/guard-registry.js.map +1 -0
  250. package/dist/navigation/guarded-navigation.d.ts +24 -0
  251. package/dist/navigation/guarded-navigation.d.ts.map +1 -0
  252. package/dist/navigation/guarded-navigation.js +102 -0
  253. package/dist/navigation/guarded-navigation.js.map +1 -0
  254. package/dist/navigation/index.d.ts +5 -4
  255. package/dist/navigation/index.d.ts.map +1 -1
  256. package/dist/navigation/index.js +2 -1
  257. package/dist/navigation/index.js.map +1 -1
  258. package/dist/navigation/types.d.ts +8 -11
  259. package/dist/navigation/types.d.ts.map +1 -1
  260. package/dist/navigation/use-back-forward-guard.d.ts +12 -0
  261. package/dist/navigation/use-back-forward-guard.d.ts.map +1 -0
  262. package/dist/navigation/use-back-forward-guard.js +75 -0
  263. package/dist/navigation/use-back-forward-guard.js.map +1 -0
  264. package/dist/navigation/use-search-commit.d.ts.map +1 -1
  265. package/dist/navigation/use-search-commit.js.map +1 -1
  266. package/dist/plugin/host-state.d.ts.map +1 -1
  267. package/dist/plugin/host-state.js.map +1 -1
  268. package/dist/plugin/registry.d.ts +6 -15
  269. package/dist/plugin/registry.d.ts.map +1 -1
  270. package/dist/plugin/registry.js +83 -75
  271. package/dist/plugin/registry.js.map +1 -1
  272. package/dist/schema-editor/SchemaEditor.d.ts.map +1 -1
  273. package/dist/schema-editor/SchemaEditor.js.map +1 -1
  274. package/dist/schema-editor/index.d.ts +3 -3
  275. package/dist/schema-editor/index.d.ts.map +1 -1
  276. package/dist/schema-editor/index.js +1 -6
  277. package/dist/schema-editor/index.js.map +1 -1
  278. package/dist/schema-form/SecretRefField.d.ts +18 -3
  279. package/dist/schema-form/SecretRefField.d.ts.map +1 -1
  280. package/dist/schema-form/SecretRefField.js +21 -26
  281. package/dist/schema-form/SecretRefField.js.map +1 -1
  282. package/dist/schema-form/classify.d.ts +1 -113
  283. package/dist/schema-form/classify.d.ts.map +1 -1
  284. package/dist/schema-form/classify.js +174 -246
  285. package/dist/schema-form/classify.js.map +1 -1
  286. package/dist/schema-form/context.d.ts +6 -0
  287. package/dist/schema-form/context.d.ts.map +1 -1
  288. package/dist/schema-form/context.js +0 -6
  289. package/dist/schema-form/context.js.map +1 -1
  290. package/dist/schema-form/default-value.d.ts.map +1 -1
  291. package/dist/schema-form/default-value.js +42 -19
  292. package/dist/schema-form/default-value.js.map +1 -1
  293. package/dist/schema-form/enum-field.d.ts +1 -1
  294. package/dist/schema-form/enum-field.d.ts.map +1 -1
  295. package/dist/schema-form/field-group.d.ts +6 -0
  296. package/dist/schema-form/field-group.d.ts.map +1 -1
  297. package/dist/schema-form/field-group.js +0 -6
  298. package/dist/schema-form/field-group.js.map +1 -1
  299. package/dist/schema-form/field-model.d.ts +121 -0
  300. package/dist/schema-form/field-model.d.ts.map +1 -0
  301. package/dist/schema-form/field-model.js +2 -0
  302. package/dist/schema-form/field-model.js.map +1 -0
  303. package/dist/schema-form/field-node.d.ts.map +1 -1
  304. package/dist/schema-form/field-node.js +25 -14
  305. package/dist/schema-form/field-node.js.map +1 -1
  306. package/dist/schema-form/index.d.ts +8 -8
  307. package/dist/schema-form/index.d.ts.map +1 -1
  308. package/dist/schema-form/index.js +3 -34
  309. package/dist/schema-form/index.js.map +1 -1
  310. package/dist/schema-form/json-field.d.ts +19 -0
  311. package/dist/schema-form/json-field.d.ts.map +1 -1
  312. package/dist/schema-form/json-field.js +0 -19
  313. package/dist/schema-form/json-field.js.map +1 -1
  314. package/dist/schema-form/media-field.d.ts +1 -1
  315. package/dist/schema-form/media-field.d.ts.map +1 -1
  316. package/dist/schema-form/media-field.js +49 -30
  317. package/dist/schema-form/media-field.js.map +1 -1
  318. package/dist/schema-form/record-field.d.ts +12 -0
  319. package/dist/schema-form/record-field.d.ts.map +1 -1
  320. package/dist/schema-form/record-field.js +1 -13
  321. package/dist/schema-form/record-field.js.map +1 -1
  322. package/dist/schema-form/string-annotations.d.ts +20 -0
  323. package/dist/schema-form/string-annotations.d.ts.map +1 -0
  324. package/dist/schema-form/string-annotations.js +105 -0
  325. package/dist/schema-form/string-annotations.js.map +1 -0
  326. package/dist/schema-form/string-field.d.ts +1 -1
  327. package/dist/schema-form/string-field.d.ts.map +1 -1
  328. package/dist/schema-form/string-field.js +1 -1
  329. package/dist/schema-form/string-field.js.map +1 -1
  330. package/dist/schema-form/union-field.d.ts +1 -1
  331. package/dist/schema-form/union-field.d.ts.map +1 -1
  332. package/dist/schema-form/union-field.js.map +1 -1
  333. package/dist/schema-form/union.d.ts +8 -1
  334. package/dist/schema-form/union.d.ts.map +1 -1
  335. package/dist/schema-form/union.js +0 -7
  336. package/dist/schema-form/union.js.map +1 -1
  337. package/dist/schema-form/validate.d.ts.map +1 -1
  338. package/dist/schema-form/validate.js +126 -105
  339. package/dist/schema-form/validate.js.map +1 -1
  340. package/dist/state-binding/AdapterMapping.d.ts.map +1 -1
  341. package/dist/state-binding/AdapterMapping.js +0 -0
  342. package/dist/state-binding/AdapterMapping.js.map +1 -1
  343. package/dist/state-binding/BindingJqField.d.ts.map +1 -1
  344. package/dist/state-binding/BindingJqField.js +2 -2
  345. package/dist/state-binding/BindingJqField.js.map +1 -1
  346. package/dist/state-binding/InputInjectionRow.d.ts.map +1 -1
  347. package/dist/state-binding/InputInjectionRow.js +3 -3
  348. package/dist/state-binding/InputInjectionRow.js.map +1 -1
  349. package/dist/state-binding/StateAttachRow.d.ts.map +1 -1
  350. package/dist/state-binding/StateAttachRow.js +57 -41
  351. package/dist/state-binding/StateAttachRow.js.map +1 -1
  352. package/dist/state-binding/StateBindingSection.d.ts.map +1 -1
  353. package/dist/state-binding/StateBindingSection.js.map +1 -1
  354. package/dist/state-binding/SubjectScopeFields.d.ts.map +1 -1
  355. package/dist/state-binding/SubjectScopeFields.js.map +1 -1
  356. package/dist/state-binding/UpdateRow.d.ts.map +1 -1
  357. package/dist/state-binding/UpdateRow.js +2 -2
  358. package/dist/state-binding/UpdateRow.js.map +1 -1
  359. package/dist/state-binding/adapter-mapping-row.d.ts +17 -0
  360. package/dist/state-binding/adapter-mapping-row.d.ts.map +1 -0
  361. package/dist/state-binding/adapter-mapping-row.js +87 -0
  362. package/dist/state-binding/adapter-mapping-row.js.map +1 -0
  363. package/dist/state-binding/index.d.ts +21 -21
  364. package/dist/state-binding/index.d.ts.map +1 -1
  365. package/dist/state-binding/index.js +9 -15
  366. package/dist/state-binding/index.js.map +1 -1
  367. package/dist/state-binding/templated-text-catalog.d.ts.map +1 -1
  368. package/dist/state-binding/templated-text-catalog.js.map +1 -1
  369. package/dist/state-binding/types.d.ts +2 -2
  370. package/dist/state-binding/types.d.ts.map +1 -1
  371. package/dist/structured-output/StructuredOutput.d.ts.map +1 -1
  372. package/dist/structured-output/StructuredOutput.js +1 -3
  373. package/dist/structured-output/StructuredOutput.js.map +1 -1
  374. package/package.json +2 -2
  375. package/src/components/code-block.tsx +1 -1
  376. package/src/components/confirm-dialog.tsx +1 -1
  377. package/src/components/copy-field.tsx +1 -1
  378. package/src/components/date-range-picker.tsx +1 -1
  379. package/src/components/dialog.tsx +1 -1
  380. package/src/components/dirty-guard.tsx +3 -3
  381. package/src/components/explorer-body.tsx +239 -0
  382. package/src/components/explorer-page-size.ts +39 -0
  383. package/src/components/explorer-tag-filter.tsx +80 -0
  384. package/src/components/explorer-tags.ts +64 -0
  385. package/src/components/explorer-view.tsx +115 -367
  386. package/src/components/extension-combo-builder.tsx +35 -153
  387. package/src/components/extension-combo-parts.tsx +236 -0
  388. package/src/components/field.tsx +1 -1
  389. package/src/components/fleet-report.tsx +98 -55
  390. package/src/components/folder-nav.tsx +2 -2
  391. package/src/components/form-dialog.tsx +2 -2
  392. package/src/components/icons/chrome-marks.tsx +195 -0
  393. package/src/components/icons/icon-frame.tsx +50 -0
  394. package/src/components/icons/index.ts +84 -0
  395. package/src/components/icons/nav-map.ts +55 -0
  396. package/src/components/icons/nav-marks.tsx +205 -0
  397. package/src/components/icons/status-marks.tsx +46 -0
  398. package/src/components/icons/theme-marks.tsx +33 -0
  399. package/src/components/inputs.tsx +1 -1
  400. package/src/components/json-diff.tsx +1 -4
  401. package/src/components/json-tree-context.ts +26 -0
  402. package/src/components/json-tree-model.ts +139 -0
  403. package/src/components/json-tree-nodes.tsx +224 -0
  404. package/src/components/json-tree.tsx +15 -434
  405. package/src/components/json-value-format.ts +64 -0
  406. package/src/components/markdown-blocks.ts +198 -0
  407. package/src/components/markdown-inline.tsx +365 -0
  408. package/src/components/markdown.tsx +6 -472
  409. package/src/components/observer-registry.ts +139 -0
  410. package/src/components/overflow-measure.ts +69 -0
  411. package/src/components/page-fill.tsx +1 -1
  412. package/src/components/prose-regions.ts +153 -0
  413. package/src/components/radio-group.tsx +1 -1
  414. package/src/components/scroll-region.tsx +22 -361
  415. package/src/components/tab-stop-parse.ts +217 -0
  416. package/src/components/table.tsx +1 -1
  417. package/src/components/tags.tsx +2 -2
  418. package/src/components/templated-text-field.tsx +39 -332
  419. package/src/components/templated-text-kwargs-editor.tsx +147 -0
  420. package/src/components/templated-text-kwargs.ts +92 -0
  421. package/src/components/templated-text-source.tsx +226 -0
  422. package/src/components/tool-picker-parts.tsx +184 -0
  423. package/src/components/tool-picker.tsx +22 -114
  424. package/src/components/version-history-panel.tsx +39 -143
  425. package/src/components/version-history-rows.tsx +220 -0
  426. package/src/components/view-toggle.tsx +1 -1
  427. package/src/element-slot.ts +1 -1
  428. package/src/guards.ts +7 -0
  429. package/src/hooks/interactions-connection.ts +227 -0
  430. package/src/hooks/interactions-stream.ts +274 -0
  431. package/src/hooks/useApi.ts +1 -1
  432. package/src/hooks/useAuth.ts +1 -1
  433. package/src/hooks/useCapabilities.ts +3 -3
  434. package/src/hooks/useSse.ts +51 -478
  435. package/src/hooks/useSystemKinds.tsx +2 -2
  436. package/src/hooks/useTheme.ts +1 -1
  437. package/src/hooks/useToolDisplayNames.tsx +2 -2
  438. package/src/host.ts +7 -7
  439. package/src/index.ts +292 -292
  440. package/src/navigation/app-link.tsx +70 -0
  441. package/src/navigation/context.tsx +12 -331
  442. package/src/navigation/entry-state.ts +42 -0
  443. package/src/navigation/guard-registry.ts +65 -0
  444. package/src/navigation/guarded-navigation.ts +147 -0
  445. package/src/navigation/index.ts +14 -14
  446. package/src/navigation/types.ts +8 -11
  447. package/src/navigation/use-back-forward-guard.ts +90 -0
  448. package/src/navigation/use-search-commit.ts +1 -1
  449. package/src/plugin/host-state.ts +1 -1
  450. package/src/plugin/registry.ts +111 -90
  451. package/src/schema-editor/SchemaEditor.tsx +1 -1
  452. package/src/schema-editor/index.ts +3 -3
  453. package/src/schema-form/SecretRefField.tsx +122 -72
  454. package/src/schema-form/classify.ts +245 -396
  455. package/src/schema-form/context.ts +1 -1
  456. package/src/schema-form/default-value.ts +48 -17
  457. package/src/schema-form/enum-field.tsx +1 -1
  458. package/src/schema-form/field-group.tsx +1 -1
  459. package/src/schema-form/field-model.ts +133 -0
  460. package/src/schema-form/field-node.tsx +95 -39
  461. package/src/schema-form/index.ts +10 -10
  462. package/src/schema-form/json-field.tsx +1 -1
  463. package/src/schema-form/media-field.tsx +136 -67
  464. package/src/schema-form/record-field.tsx +2 -2
  465. package/src/schema-form/string-annotations.ts +111 -0
  466. package/src/schema-form/string-field.tsx +2 -2
  467. package/src/schema-form/union-field.tsx +3 -2
  468. package/src/schema-form/union.ts +1 -1
  469. package/src/schema-form/validate.ts +185 -104
  470. package/src/state-binding/AdapterMapping.tsx +0 -0
  471. package/src/state-binding/BindingJqField.tsx +3 -3
  472. package/src/state-binding/InputInjectionRow.tsx +4 -4
  473. package/src/state-binding/StateAttachRow.tsx +229 -154
  474. package/src/state-binding/StateBindingSection.tsx +1 -1
  475. package/src/state-binding/SubjectScopeFields.tsx +1 -1
  476. package/src/state-binding/UpdateRow.tsx +3 -3
  477. package/src/state-binding/adapter-mapping-row.tsx +232 -0
  478. package/src/state-binding/index.ts +43 -43
  479. package/src/state-binding/templated-text-catalog.ts +0 -1
  480. package/src/state-binding/types.ts +2 -2
  481. package/src/structured-output/StructuredOutput.tsx +1 -4
  482. package/dist/components/icons.d.ts +0 -160
  483. package/dist/components/icons.d.ts.map +0 -1
  484. package/dist/components/icons.js +0 -160
  485. package/dist/components/icons.js.map +0 -1
  486. package/src/components/icons.tsx +0 -586
@@ -1,75 +1,8 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
- /**
3
- * `ScrollRegion` — a horizontally scrollable container that becomes a keyboard
4
- * target ONLY while it actually overflows.
5
- *
6
- * A pane that scrolls must be reachable without a pointer (WCAG 2.1.1), which
7
- * needs `tabIndex`, `role="region"` and a name. Applying those unconditionally
8
- * would litter every screen with phantom landmarks and dead tab stops for tables
9
- * that happen to fit, so the attributes are driven by a live measurement:
10
- * `scrollWidth > clientWidth`, re-taken whenever the container or its content
11
- * resizes and whenever the content is replaced.
12
- *
13
- * `useOverflowRegion` is the same measurement for a component that IS its own
14
- * scrolling box (a `<pre>`, a JSON pane) and therefore cannot be wrapped in a
15
- * `<div>` without gaining a second scroller. `useProseScrollRegions` applies the
16
- * rules to the surfaces React never renders — the tables and code blocks inside
17
- * `dangerouslySetInnerHTML` (rendered README/markdown), which cannot be wrapped
18
- * in a component and are therefore instrumented imperatively.
19
- *
20
- * Both hooks hand back a CALLBACK REF for the element they measure, rather than
21
- * reading one the caller holds: a ref object tells a hook nothing about WHEN it
22
- * is filled, so a hook that read one would never instrument an element that
23
- * mounts later than the hook (a README that arrives with the second render) and
24
- * would never notice one being swapped for another.
25
- */
26
2
  import { useCallback, useState } from 'react';
27
- /**
28
- * The names for a prose surface that has no heading above it.
29
- *
30
- * They say what the surface IS and nothing about which document it came from,
31
- * because this hook cannot know: it instruments whatever markup the caller
32
- * injected. A default that named one document put that document's name on every
33
- * caller's regions, and a region a reader hears the wrong name for is worse than
34
- * a plain one. A caller that CAN say which document it is showing passes its own
35
- * `labels`; a surface with a heading above it takes that heading instead, which
36
- * is the usual case.
37
- */
38
- const DEFAULT_PROSE_LABELS = { table: 'Table', pre: 'Code block' };
39
- const HEADING_SELECTOR = 'h1, h2, h3, h4, h5, h6';
40
- /**
41
- * Headings AND the surfaces they name, in one selector: a single query returns
42
- * both interleaved in document order, which is what lets one walk name every
43
- * surface (see `labelledProseSurfaces`).
44
- */
45
- const PROSE_SURFACE_SELECTOR = `${HEADING_SELECTOR}, table, pre`;
46
- const SCROLL_REGION_CLASS = 'tai-scroll-region';
47
- /**
48
- * The most surfaces one rendered document is given regions for.
49
- *
50
- * The prose is publisher-authored and unbounded in length, and every region is
51
- * an entry in the landmark list a screen-reader user navigates the page by: a
52
- * README with more surfaces than this turns that list into the very thing the
53
- * regions exist to spare a reader. Past the cap a table still gets its scrolling
54
- * wrapper — the wrapper is what keeps it inside the column — but no name and no
55
- * tab stop, so the landmark list stays a list a person can read.
56
- */
57
- const MAX_PROSE_REGIONS = 200;
58
- function overflows(element) {
59
- return element.scrollWidth > element.clientWidth;
60
- }
61
- /**
62
- * Whether the element should carry the region attributes right now.
63
- *
64
- * A region that stops overflowing keeps its tab stop for as long as it holds
65
- * focus: taking `tabindex` off the focused element drops the reader onto the
66
- * document body, and a window resize is not their doing. Only an element that
67
- * already has the stop can be the active element, so this can hold a stop open
68
- * but never invent one.
69
- */
70
- function needsRegion(element) {
71
- return overflows(element) || element.ownerDocument.activeElement === element;
72
- }
3
+ import { holdContentTarget, holdResizeTarget, releaseContentTarget, releaseResizeTarget, } from './observer-registry';
4
+ import { clearScrollRegionAttributes, needsRegion, refreshRegions, SCROLL_REGION_CLASS, } from './overflow-measure';
5
+ import { DEFAULT_PROSE_LABELS, ensureScrollWrapper, labelledProseSurfaces, MAX_PROSE_REGIONS, uniquelyNamed, } from './prose-regions';
73
6
  /**
74
7
  * Attaches `element` to a consumer ref of either form, and returns the detach
75
8
  * for it. A callback ref that answers with its own cleanup gets that cleanup
@@ -92,135 +25,6 @@ function attachRef(ref, element) {
92
25
  ref(null);
93
26
  };
94
27
  }
95
- /**
96
- * The handlers waiting on each observed element. A SET, not a single handler:
97
- * one element can be both a box and another box's child — a `<pre>` inside a
98
- * `ScrollRegion` is exactly that — and both owners must still hear its resize.
99
- */
100
- const resizeHandlers = new WeakMap();
101
- let sharedResize;
102
- function sharedResizeObserver() {
103
- sharedResize ??= new ResizeObserver((entries) => {
104
- // A box and its children are observed separately, so one frame can deliver
105
- // several entries owned by the same handler; measuring once is enough.
106
- const fired = new Set();
107
- for (const entry of entries) {
108
- for (const handler of resizeHandlers.get(entry.target) ?? [])
109
- fired.add(handler);
110
- }
111
- for (const handler of fired)
112
- handler();
113
- });
114
- return sharedResize;
115
- }
116
- /**
117
- * Registers `handler` for `target`'s resizes, observing the element only the
118
- * first time anyone asks for it: re-observing an element already under a
119
- * `ResizeObserver` re-arms its initial notification, which spends a forced
120
- * layout on a measurement nobody asked for.
121
- */
122
- function holdResizeTarget(target, handler) {
123
- const handlers = resizeHandlers.get(target);
124
- if (handlers !== undefined) {
125
- handlers.add(handler);
126
- return;
127
- }
128
- // Registered before the element is observed, so the initial notification the
129
- // observation arms reaches the handler that asked for it.
130
- resizeHandlers.set(target, new Set([handler]));
131
- sharedResizeObserver().observe(target);
132
- }
133
- /** Stops observing `target` for `handler`, and entirely once nobody wants it. */
134
- function releaseResizeTarget(target, handler) {
135
- const handlers = resizeHandlers.get(target);
136
- if (handlers === undefined)
137
- return;
138
- handlers.delete(handler);
139
- if (handlers.size > 0)
140
- return;
141
- resizeHandlers.delete(target);
142
- sharedResizeObserver().unobserve(target);
143
- }
144
- /** What a box wants to hear about: its content replaced, appended or edited. */
145
- const CONTENT_OBSERVER_INIT = {
146
- childList: true,
147
- subtree: true,
148
- characterData: true,
149
- };
150
- /**
151
- * The handlers waiting on each observed box, and the boxes the shared observer
152
- * currently holds. Keyed by `Node` because a `characterData` record names the
153
- * TEXT node that changed, and the walk to the box that owns it goes through
154
- * whatever nodes lie between.
155
- */
156
- const contentHandlers = new WeakMap();
157
- const contentTargets = new Set();
158
- let sharedContent;
159
- /** Registrations the shared observer still holds for released boxes. */
160
- let staleContentTargets = 0;
161
- function deliverContentRecords(records) {
162
- const fired = new Set();
163
- for (const record of records) {
164
- // A `childList` record names the changed parent and a `characterData` record
165
- // the text node itself, either of them at any depth under a box. Every box
166
- // on the ancestor chain therefore owns the change, exactly as a separate
167
- // observer on each of them would have seen it — a `<pre>` inside a
168
- // `ScrollRegion` measures both.
169
- for (let node = record.target; node !== null; node = node.parentNode) {
170
- for (const handler of contentHandlers.get(node) ?? [])
171
- fired.add(handler);
172
- }
173
- }
174
- for (const handler of fired)
175
- handler();
176
- }
177
- function sharedContentObserver() {
178
- sharedContent ??= new MutationObserver(deliverContentRecords);
179
- return sharedContent;
180
- }
181
- function holdContentTarget(target, handler) {
182
- let handlers = contentHandlers.get(target);
183
- if (handlers === undefined) {
184
- handlers = new Set();
185
- contentHandlers.set(target, handlers);
186
- contentTargets.add(target);
187
- sharedContentObserver().observe(target, CONTENT_OBSERVER_INIT);
188
- }
189
- handlers.add(handler);
190
- }
191
- /**
192
- * Stops watching `target`'s content for `handler`.
193
- *
194
- * `MutationObserver` has no `unobserve`: the only way to drop one registration
195
- * is to disconnect the observer and re-observe everything else, which would cost
196
- * one registration per surviving box every time a box unmounts. A released box
197
- * is therefore dropped from the handler map at once — its records find no
198
- * handler and are ignored — and the observer is rebuilt only once the dead
199
- * registrations outnumber the live ones, which keeps the total registration work
200
- * proportional to the number of mounts. Records already queued survive the
201
- * rebuild: they are taken off the observer and delivered by hand.
202
- */
203
- function releaseContentTarget(target, handler) {
204
- const handlers = contentHandlers.get(target);
205
- if (handlers === undefined)
206
- return;
207
- handlers.delete(handler);
208
- if (handlers.size > 0)
209
- return;
210
- contentHandlers.delete(target);
211
- contentTargets.delete(target);
212
- staleContentTargets += 1;
213
- if (staleContentTargets <= contentTargets.size)
214
- return;
215
- const observer = sharedContentObserver();
216
- const queued = observer.takeRecords();
217
- observer.disconnect();
218
- staleContentTargets = 0;
219
- for (const live of contentTargets)
220
- observer.observe(live, CONTENT_OBSERVER_INIT);
221
- if (queued.length > 0)
222
- deliverContentRecords(queued);
223
- }
224
28
  /**
225
29
  * The conditional region attributes for a scrolling box, alongside the ref that
226
30
  * names it. The ref must go on the scrolling box ITSELF — a `<pre>`, a JSON
@@ -299,129 +103,6 @@ export function ScrollRegion({ label, children, className, style, 'data-testid':
299
103
  const region = useOverflowRegion(ref, label);
300
104
  return (_jsx("div", { className: className === undefined ? SCROLL_REGION_CLASS : `${SCROLL_REGION_CLASS} ${className}`, style: style, "data-testid": testId, ...region, children: children }));
301
105
  }
302
- /**
303
- * The wrapper a prose table sits inside, creating it on first pass. Idempotent:
304
- * a table already inside a `.tai-scroll-region` keeps the wrapper it has.
305
- */
306
- function ensureScrollWrapper(table) {
307
- const parent = table.parentElement;
308
- if (parent?.classList.contains(SCROLL_REGION_CLASS) === true)
309
- return parent;
310
- const wrapper = table.ownerDocument.createElement('div');
311
- wrapper.className = SCROLL_REGION_CLASS;
312
- table.replaceWith(wrapper);
313
- wrapper.append(table);
314
- return wrapper;
315
- }
316
- /**
317
- * The text of the last heading in `headings` that does not ENCLOSE `surface`.
318
- *
319
- * A heading wrapping the surface does precede it in document order, but it is
320
- * not a section the surface sits UNDER, so it is stepped over in favour of the
321
- * heading before it — which is the answer an outward walk from the surface
322
- * reaches. In well-formed prose no heading contains a table or a code block, so
323
- * this returns the last heading on the first look.
324
- */
325
- function namingHeadingText(headings, surface) {
326
- for (let index = headings.length - 1; index >= 0; index -= 1) {
327
- const heading = headings[index];
328
- if (heading !== undefined && !heading.element.contains(surface))
329
- return heading.text;
330
- }
331
- return undefined;
332
- }
333
- /**
334
- * Every scrollable prose surface under `root` — each `<table>` and each `<pre>`
335
- * — paired with the text of the nearest heading PRECEDING it, or `undefined`
336
- * when no heading does.
337
- *
338
- * One query returns the headings and the surfaces interleaved in document order,
339
- * so a single walk over that list names all of them: the heading a surface
340
- * belongs to is the last one seen before reaching it. Naming each surface by
341
- * searching backwards from it instead would re-read the same prose once per
342
- * surface, at a cost that grows with the product of the two.
343
- *
344
- * Blank headings never enter the list, so a decorative empty heading names
345
- * nothing and the section above it is used instead. A heading INSIDE a surface
346
- * (a `<pre>` or a table cell holding one) comes AFTER that surface in document
347
- * order and so can never name it, though it does name later surfaces — exactly
348
- * as being the last heading before them implies.
349
- *
350
- * Read in full before the pass wraps anything, and safely so: a name depends
351
- * only on what PRECEDES its surface, and `ensureScrollWrapper` puts the wrapper
352
- * in the table's own place, moving nothing else and leaving every heading where
353
- * it was — so a name stays true whether its table is wrapped yet or not.
354
- */
355
- function labelledProseSurfaces(root) {
356
- const headings = [];
357
- const surfaces = [];
358
- for (const node of root.querySelectorAll(PROSE_SURFACE_SELECTOR)) {
359
- if (node.matches(HEADING_SELECTOR)) {
360
- // textContent is nullable under strict DOM typings; the local eslint
361
- // profile assumes non-null, so the necessary guard trips its rule.
362
- // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
363
- const text = (node.textContent ?? '').trim();
364
- if (text !== '')
365
- headings.push({ element: node, text });
366
- continue;
367
- }
368
- surfaces.push({ element: node, heading: namingHeadingText(headings, node) });
369
- }
370
- return surfaces;
371
- }
372
- /**
373
- * The same surfaces, each given a name no other one in the list carries.
374
- *
375
- * A name is only as useful as it is distinguishing, and one heading names every
376
- * surface under it: two wide tables in one section, or two code blocks under no
377
- * heading at all, would otherwise be two landmarks a reader hears identically
378
- * and cannot choose between. A name more than one surface claims is therefore
379
- * numbered, in document order, and a name only one surface claims is left alone.
380
- */
381
- function uniquelyNamed(boxes) {
382
- const claims = new Map();
383
- for (const { name } of boxes)
384
- claims.set(name, (claims.get(name) ?? 0) + 1);
385
- const taken = new Map();
386
- return boxes.map(({ surface, name }) => {
387
- if (claims.get(name) === 1)
388
- return { surface, label: name };
389
- const ordinal = (taken.get(name) ?? 0) + 1;
390
- taken.set(name, ordinal);
391
- return { surface, label: `${name} (${String(ordinal)})` };
392
- });
393
- }
394
- /** Strips the region attributes from a surface that is not a region now. */
395
- function clearScrollRegionAttributes(wrapper) {
396
- wrapper.removeAttribute('tabindex');
397
- wrapper.removeAttribute('role');
398
- wrapper.removeAttribute('aria-label');
399
- }
400
- /** Applies the same conditional attribute set `ScrollRegion` renders. */
401
- function applyScrollRegionAttributes(wrapper, label, scrolling) {
402
- if (!scrolling) {
403
- clearScrollRegionAttributes(wrapper);
404
- return;
405
- }
406
- wrapper.setAttribute('tabindex', '0');
407
- wrapper.setAttribute('role', 'region');
408
- wrapper.setAttribute('aria-label', label);
409
- }
410
- /**
411
- * Re-applies the region attributes to `tracked`, reading ALL of them before
412
- * writing any.
413
- *
414
- * `needsRegion` reads `scrollWidth`, which forces layout if anything has been
415
- * written since the last one — so measuring and writing surface by surface makes
416
- * the browser re-lay-out the prose once per surface, every time. Two phases cost
417
- * one layout for the whole batch however many surfaces it holds.
418
- */
419
- function refreshRegions(tracked) {
420
- const scrolling = tracked.map((entry) => needsRegion(entry.surface));
421
- for (const [index, entry] of tracked.entries()) {
422
- applyScrollRegionAttributes(entry.surface, entry.label, scrolling[index] === true);
423
- }
424
- }
425
106
  /**
426
107
  * Instruments the scrollable surfaces under the element the returned ref is
427
108
  * attached to — every `<table>` and every `<pre>` — as scroll regions. React
@@ -1 +1 @@
1
- {"version":3,"file":"scroll-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AAC,KAAK,QAAQ,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,UAAU,CAAC;gBAAE,OAAO;YACrF,uEAAuE;YACvE,wEAAwE;YACxE,qCAAqC;YACrC,MAAM,OAAO,GAAG,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;YACpC,IAAI,OAAO,KAAK,SAAS;gBAAE,cAAc,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;QACvD,CAAC,CAAC;QACF,IAAI,CAAC,gBAAgB,CAAC,UAAU,EAAE,eAAe,CAAC,CAAC;QAEnD,UAAU,EAAE,CAAC;QAEb,OAAO,GAAG,EAAE;YACV,cAAc,CAAC,UAAU,EAAE,CAAC;YAC5B,gBAAgB,CAAC,UAAU,EAAE,CAAC;YAC9B,IAAI,CAAC,mBAAmB,CAAC,UAAU,EAAE,eAAe,CAAC,CAAC;QACxD,CAAC,CAAC;IACJ,CAAC,EACD,CAAC,UAAU,EAAE,QAAQ,CAAC,CACvB,CAAC;AACJ,CAAC"}
@@ -0,0 +1,53 @@
1
+ /**
2
+ * The low-level parsing behind `tabStopsIn`: balanced-bracket and value scanning,
3
+ * a tag's attribute value, the binding/import RESOLVER (name → its home file and
4
+ * definition, expanded across hops), and the two per-tag predicates —
5
+ * `tagDeclaresTab` (is this a tab stop?) and `taiClassesOf` (which `tai-*` classes
6
+ * does it wear?).
7
+ */
8
+ /**
9
+ * The text from `start` to the character closing the bracket it opens, quotes
10
+ * respected so a brace inside a string neither opens nor closes anything.
11
+ */
12
+ export declare function balancedFrom(source: string, start: number, open: string, close: string): string;
13
+ export declare function readAssignmentValue(source: string, start: number): string;
14
+ /**
15
+ * The index of the `>` closing an opening tag whose attribute run starts at
16
+ * `from`, quotes and brace depth tracked so a `>` inside a `className` expression
17
+ * (`{x > 0 ? a : b}`) is not mistaken for it.
18
+ */
19
+ export declare function scanToTagClose(source: string, from: number): number;
20
+ /** One opening JSX tag: its element name and everything between that and the `>`. */
21
+ export interface OpeningTag {
22
+ readonly name: string;
23
+ readonly attributes: string;
24
+ }
25
+ /**
26
+ * The value written for `attribute`, unquoted or unbraced; `undefined` when the
27
+ * tag does not write it at all, which is the difference between "no `tabIndex`"
28
+ * and "`tabIndex={-1}`".
29
+ */
30
+ export declare function attributeValue(attributes: string, attribute: string): string | undefined;
31
+ /** Resolves a referenced name to the file it is bound in and its definition text. */
32
+ export interface TabStopResolver {
33
+ /** Where a name is bound: the file itself, or the file it is imported from. */
34
+ homeOf(file: string, name: string): string | undefined;
35
+ /** The definition text of `name` bound in `home`, if any. */
36
+ definitionOf(home: string, name: string): string | undefined;
37
+ /**
38
+ * `text` with the definition of every name it references appended, to `depth`
39
+ * hops — a class reaches its element through as many as three (the tag names a
40
+ * helper, the helper names a table, the table holds the literal).
41
+ */
42
+ expand(text: string, file: string, depth: number, seen: Set<string>): string;
43
+ }
44
+ /** A resolver over pre-scanned per-file binding and import maps. */
45
+ export declare function createTabStopResolver(bindings: ReadonlyMap<string, Map<string, string>>, imports: ReadonlyMap<string, Map<string, string>>): TabStopResolver;
46
+ /**
47
+ * Whether the tag is a keyboard tab stop: a natively focusable element, an element
48
+ * with a non-negative `tabIndex`, or one spreading a props object that declares one.
49
+ */
50
+ export declare function tagDeclaresTab(tag: OpeningTag, file: string, resolver: TabStopResolver): boolean;
51
+ /** The `tai-*` classes the tag wears, expanded through its bindings to `depth` 3. */
52
+ export declare function taiClassesOf(tag: OpeningTag, file: string, resolver: TabStopResolver): string[];
53
+ //# sourceMappingURL=tab-stop-parse.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tab-stop-parse.d.ts","sourceRoot":"","sources":["../../src/components/tab-stop-parse.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH;;;GAGG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,CAwB/F;AAWD,wBAAgB,mBAAm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AG,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,eAAe,GAAG,MAAM,EAAE,CAc/F"}
@@ -0,0 +1,202 @@
1
+ /**
2
+ * The low-level parsing behind `tabStopsIn`: balanced-bracket and value scanning,
3
+ * a tag's attribute value, the binding/import RESOLVER (name → its home file and
4
+ * definition, expanded across hops), and the two per-tag predicates —
5
+ * `tagDeclaresTab` (is this a tab stop?) and `taiClassesOf` (which `tai-*` classes
6
+ * does it wear?).
7
+ */
8
+ /**
9
+ * The text from `start` to the character closing the bracket it opens, quotes
10
+ * respected so a brace inside a string neither opens nor closes anything.
11
+ */
12
+ export function balancedFrom(source, start, open, close) {
13
+ let depth = 0;
14
+ let quote;
15
+ for (let index = start; index < source.length; index += 1) {
16
+ const character = source[index];
17
+ if (quote !== undefined) {
18
+ if (character === '\\') {
19
+ index += 1;
20
+ continue;
21
+ }
22
+ if (character === quote)
23
+ quote = undefined;
24
+ continue;
25
+ }
26
+ if (character === '"' || character === "'" || character === '`') {
27
+ quote = character;
28
+ continue;
29
+ }
30
+ if (character === open)
31
+ depth += 1;
32
+ else if (character === close) {
33
+ depth -= 1;
34
+ if (depth === 0)
35
+ return source.slice(start, index + 1);
36
+ }
37
+ }
38
+ return source.slice(start);
39
+ }
40
+ /**
41
+ * The RHS of a `const`/`let` assignment beginning at `start`: text up to the
42
+ * top-level `;`, with brackets and quotes tracked so a `;` inside either does not
43
+ * end it.
44
+ */
45
+ const QUOTE_CHARS = '"\'`';
46
+ const OPEN_BRACKETS = '{([';
47
+ const CLOSE_BRACKETS = '})]';
48
+ export function readAssignmentValue(source, start) {
49
+ let end = start;
50
+ let depth = 0;
51
+ let quote;
52
+ for (; end < source.length; end += 1) {
53
+ const character = source[end] ?? '';
54
+ if (quote !== undefined) {
55
+ if (character === '\\')
56
+ end += 1;
57
+ else if (character === quote)
58
+ quote = undefined;
59
+ continue;
60
+ }
61
+ if (QUOTE_CHARS.includes(character))
62
+ quote = character;
63
+ else if (OPEN_BRACKETS.includes(character))
64
+ depth += 1;
65
+ else if (CLOSE_BRACKETS.includes(character))
66
+ depth -= 1;
67
+ else if (character === ';' && depth === 0)
68
+ break;
69
+ }
70
+ return source.slice(start, end);
71
+ }
72
+ /**
73
+ * The index of the `>` closing an opening tag whose attribute run starts at
74
+ * `from`, quotes and brace depth tracked so a `>` inside a `className` expression
75
+ * (`{x > 0 ? a : b}`) is not mistaken for it.
76
+ */
77
+ export function scanToTagClose(source, from) {
78
+ let end = from;
79
+ let depth = 0;
80
+ let quote;
81
+ for (; end < source.length; end += 1) {
82
+ const character = source[end];
83
+ if (quote !== undefined) {
84
+ if (character === '\\')
85
+ end += 1;
86
+ else if (character === quote)
87
+ quote = undefined;
88
+ continue;
89
+ }
90
+ if (character === '"' || character === "'" || character === '`')
91
+ quote = character;
92
+ else if (character === '{')
93
+ depth += 1;
94
+ else if (character === '}')
95
+ depth -= 1;
96
+ else if (character === '>' && depth === 0)
97
+ break;
98
+ }
99
+ return end;
100
+ }
101
+ /**
102
+ * The value written for `attribute`, unquoted or unbraced; `undefined` when the
103
+ * tag does not write it at all, which is the difference between "no `tabIndex`"
104
+ * and "`tabIndex={-1}`".
105
+ */
106
+ export function attributeValue(attributes, attribute) {
107
+ const written = new RegExp(String.raw `(?<![\w-])${attribute}\s*=`).exec(attributes);
108
+ if (written === null)
109
+ return undefined;
110
+ let index = written.index + written[0].length;
111
+ while (/\s/.test(attributes[index] ?? ''))
112
+ index += 1;
113
+ const opener = attributes[index];
114
+ if (opener === '"' || opener === "'") {
115
+ const close = attributes.indexOf(opener, index + 1);
116
+ return attributes.slice(index + 1, close === -1 ? attributes.length : close);
117
+ }
118
+ if (opener === '{')
119
+ return balancedFrom(attributes, index, '{', '}').slice(1, -1);
120
+ return '';
121
+ }
122
+ /** The elements that are in the tab order with no `tabIndex` of their own. */
123
+ const NATIVELY_FOCUSABLE = new Set(['button', 'a', 'input', 'textarea', 'select', 'summary']);
124
+ /** A `tabIndex` that takes the element OUT of the tab order. */
125
+ const NEGATIVE_TAB_INDEX = /^\s*-/;
126
+ /** A props object that puts its target in the tab order. */
127
+ const SPREADS_TAB_INDEX = /tabIndex\s*:\s*(?!\s*-)/;
128
+ /** A resolver over pre-scanned per-file binding and import maps. */
129
+ export function createTabStopResolver(bindings, imports) {
130
+ function homeOf(file, name) {
131
+ if (bindings.get(file)?.has(name) === true)
132
+ return file;
133
+ return imports.get(file)?.get(name);
134
+ }
135
+ function definitionOf(home, name) {
136
+ return bindings.get(home)?.get(name);
137
+ }
138
+ function expand(text, file, depth, seen) {
139
+ if (depth === 0)
140
+ return text;
141
+ let out = text;
142
+ for (const match of text.matchAll(/(?<![\w.$])([A-Za-z_$][\w$]*)/g)) {
143
+ const name = match[1] ?? '';
144
+ const home = homeOf(file, name);
145
+ if (home === undefined)
146
+ continue;
147
+ const key = `${home}#${name}`;
148
+ if (seen.has(key))
149
+ continue;
150
+ seen.add(key);
151
+ const definition = definitionOf(home, name);
152
+ if (definition !== undefined)
153
+ out += `\n${expand(definition, home, depth - 1, seen)}`;
154
+ }
155
+ return out;
156
+ }
157
+ return { homeOf, definitionOf, expand };
158
+ }
159
+ /** Whether a spread props object on the tag declares a non-negative `tabIndex`. */
160
+ function spreadDeclaresTab(tag, file, resolver) {
161
+ for (const spread of tag.attributes.matchAll(/\{\s*\.\.\.\s*([A-Za-z_$][\w$]*)/g)) {
162
+ const home = resolver.homeOf(file, spread[1] ?? '');
163
+ if (home === undefined)
164
+ continue;
165
+ const definition = resolver.definitionOf(home, spread[1] ?? '');
166
+ if (definition !== undefined &&
167
+ SPREADS_TAB_INDEX.test(resolver.expand(definition, home, 2, new Set()))) {
168
+ return true;
169
+ }
170
+ }
171
+ return false;
172
+ }
173
+ /**
174
+ * Whether the tag is a keyboard tab stop: a natively focusable element, an element
175
+ * with a non-negative `tabIndex`, or one spreading a props object that declares one.
176
+ */
177
+ export function tagDeclaresTab(tag, file, resolver) {
178
+ const native = NATIVELY_FOCUSABLE.has(tag.name) &&
179
+ (tag.name !== 'a' || /(?<![\w-])href\s*=/.test(tag.attributes));
180
+ if (native)
181
+ return true;
182
+ const written = attributeValue(tag.attributes, 'tabIndex');
183
+ if (written !== undefined && !NEGATIVE_TAB_INDEX.test(written))
184
+ return true;
185
+ return spreadDeclaresTab(tag, file, resolver);
186
+ }
187
+ /** The `tai-*` classes the tag wears, expanded through its bindings to `depth` 3. */
188
+ export function taiClassesOf(tag, file, resolver) {
189
+ const className = attributeValue(tag.attributes, 'className');
190
+ if (className === undefined)
191
+ return [];
192
+ return [
193
+ ...new Set([
194
+ ...resolver
195
+ .expand(className, file, 3, new Set())
196
+ .matchAll(/(?<![\w-])(tai-[a-z][\w-]*)(?![\w])/g),
197
+ ]
198
+ .map((match) => `.${match[1] ?? ''}`)
199
+ .filter((name) => !name.endsWith('-'))),
200
+ ];
201
+ }
202
+ //# sourceMappingURL=tab-stop-parse.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tab-stop-parse.js","sourceRoot":"","sources":["../../src/components/tab-stop-parse.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH;;;GAGG;AACH,MAAM,UAAU,YAAY,CAAC,MAAc,EAAE,KAAa,EAAE,IAAY,EAAE,KAAa;IACrF,IAAI,KAAK,GAAG,CAAC,CAAC;IACd,IAAI,KAAyB,CAAC;IAC9B,KAAK,IAAI,KAAK,GAAG,KAAK,EAAE,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,IAAI,CAAC,EAAE,CAAC;QAC1D,MAAM,SAAS,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;QAChC,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;YACxB,IAAI,SAAS,KAAK,IAAI,EAAE,CAAC;gBACvB,KAAK,IAAI,CAAC,CAAC;gBACX,SAAS;YACX,CAAC;YACD,IAAI,SAAS,KAAK,KAAK;gBAAE,KAAK,GAAG,SAAS,CAAC;YAC3C,SAAS;QACX,CAAC;QACD,IAAI,SAAS,K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