@astryxdesign/cli 0.6.4-canary.f0355e3 → 0.6.4

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 (331) hide show
  1. package/README.md +96 -99
  2. package/api/build/build.doc.mjs +1 -6
  3. package/api/build/build.test.mjs +0 -22
  4. package/api/build/kit/kit.mjs +5 -44
  5. package/api/component/_adapter.d.mts +0 -25
  6. package/api/component/_adapter.mjs +5 -59
  7. package/api/component/component.d.mts +3 -6
  8. package/api/component/component.doc.mjs +17 -37
  9. package/api/component/component.mjs +9 -249
  10. package/api/component/component.type.d.mts +0 -25
  11. package/api/component/component.type.mjs +0 -44
  12. package/api/discover/_adapter.d.mts +6 -114
  13. package/api/discover/_adapter.mjs +17 -372
  14. package/api/discover/detail/detail.d.mts +6 -18
  15. package/api/discover/detail/detail.mjs +13 -67
  16. package/api/discover/detail/detail.test.mjs +0 -85
  17. package/api/discover/discover.d.mts +9 -3
  18. package/api/discover/discover.doc.mjs +18 -61
  19. package/api/discover/discover.mjs +36 -220
  20. package/api/discover/discover.test.mjs +2 -11
  21. package/api/discover/discover.type.d.mts +8 -147
  22. package/api/discover/discover.type.mjs +12 -102
  23. package/api/discover/list/list.d.mts +6 -20
  24. package/api/discover/list/list.mjs +12 -45
  25. package/api/discover/list/list.test.mjs +0 -46
  26. package/api/discover/search/search.d.mts +16 -18
  27. package/api/discover/search/search.mjs +56 -102
  28. package/api/discover/search/search.test.mjs +10 -144
  29. package/api/docs/_adapter.d.mts +3 -8
  30. package/api/docs/_adapter.mjs +6 -14
  31. package/api/docs/docOverlays.test.mjs +1 -27
  32. package/api/docs/docs.doc.mjs +2 -2
  33. package/api/docs/docs.test.mjs +243 -0
  34. package/api/docs/integration-tree.test.mjs +555 -0
  35. package/api/docs/integrationDocs.test.mjs +314 -0
  36. package/api/doctor/doctor.d.mts +3 -8
  37. package/api/doctor/doctor.doc.mjs +8 -17
  38. package/api/doctor/doctor.mjs +9 -90
  39. package/api/doctor/doctor.test.mjs +10 -122
  40. package/api/doctor/doctor.type.d.mts +1 -1
  41. package/api/doctor/doctor.type.mjs +1 -1
  42. package/api/gap-report/gap-report.doc.mjs +10 -19
  43. package/api/hook/hook.doc.mjs +3 -6
  44. package/api/index.d.mts +2 -1
  45. package/api/index.mjs +5 -5
  46. package/api/init/init.doc.mjs +12 -17
  47. package/api/integration/add-helpers.d.mts +2 -5
  48. package/api/integration/add-helpers.mjs +9 -36
  49. package/api/integration/add-theme.mjs +1 -22
  50. package/api/integration/add-theme.test.mjs +0 -34
  51. package/api/integration/authoring-checks.mjs +2 -2
  52. package/api/integration/integrationPackCheck.doc.mjs +3 -3
  53. package/api/integration/pack-check.mjs +9 -82
  54. package/api/integration/pack-check.test.mjs +0 -90
  55. package/api/integration/pack-check.type.mjs +1 -1
  56. package/api/json/assertResponse.doc.mjs +1 -1
  57. package/api/json/index.ts +1 -0
  58. package/api/json/isError.doc.mjs +1 -1
  59. package/api/layout/_adapter.d.mts +34 -0
  60. package/api/layout/_adapter.mjs +148 -0
  61. package/api/layout/check/check.d.mts +16 -0
  62. package/api/layout/check/check.mjs +40 -0
  63. package/api/layout/expand/expand.d.mts +22 -0
  64. package/api/layout/expand/expand.mjs +155 -0
  65. package/api/layout/expand/expand.path-safety.test.mjs +53 -0
  66. package/api/layout/grammar/grammar.d.mts +13 -0
  67. package/api/layout/grammar/grammar.mjs +87 -0
  68. package/api/layout/layout.d.mts +6 -0
  69. package/api/layout/layout.mjs +17 -0
  70. package/api/layout/layout.test.mjs +297 -0
  71. package/api/layout/layout.type.d.mts +89 -0
  72. package/api/layout/layout.type.mjs +103 -0
  73. package/api/layout/layoutCheck.doc.d.mts +11 -0
  74. package/api/layout/layoutCheck.doc.mjs +85 -0
  75. package/api/layout/layoutExpand.doc.d.mts +11 -0
  76. package/api/layout/layoutExpand.doc.mjs +107 -0
  77. package/api/layout/layoutGrammar.doc.d.mts +11 -0
  78. package/api/layout/layoutGrammar.doc.mjs +57 -0
  79. package/api/search/search.d.mts +1 -27
  80. package/api/search/search.doc.mjs +2 -2
  81. package/api/search/search.mjs +16 -228
  82. package/api/search/search.test.mjs +512 -0
  83. package/api/swizzle/swizzle.doc.mjs +5 -7
  84. package/api/template/copy/copy.mjs +1 -1
  85. package/api/template/copy/copy.test.mjs +0 -9
  86. package/api/template/template-integration.test.mjs +65 -1
  87. package/api/template/template.doc.mjs +1 -2
  88. package/api/template/template.mjs +1 -1
  89. package/api/theme/add/add.mjs +25 -17
  90. package/api/theme/add/add.staging.test.mjs +23 -40
  91. package/api/theme/build/build.family.test.mjs +12 -7
  92. package/api/theme/build/build.mjs +18 -8
  93. package/api/theme/generateTonalPalette.doc.mjs +2 -1
  94. package/api/theme/listThemes.doc.mjs +1 -1
  95. package/api/theme/themeAdd.doc.mjs +10 -9
  96. package/api/theme/themeBuild.doc.mjs +13 -13
  97. package/api/theme/themeList.doc.mjs +1 -1
  98. package/api/theme/themeListAvailable.doc.mjs +1 -2
  99. package/api/theme/themePaletteGenerate.doc.mjs +8 -15
  100. package/api/theme/themeTargets.doc.mjs +2 -3
  101. package/api/theme/themeTemplate.doc.mjs +1 -2
  102. package/api/upgrade/run/run.mjs +4 -6
  103. package/api/upgrade/upgrade.doc.mjs +22 -24
  104. package/api/upgrade/upgrade.type.mjs +2 -2
  105. package/assets/codemods/__tests__/runner.test.mjs +1 -3
  106. package/assets/codemods/integration-runner.mjs +3 -3
  107. package/assets/codemods/runner.mjs +4 -5
  108. package/assets/docs/README.md +2 -4
  109. package/assets/docs/browser-support.doc.mjs +11 -11
  110. package/assets/docs/color.doc.mjs +2 -8
  111. package/assets/docs/elevation.doc.mjs +4 -6
  112. package/assets/docs/getting-started.doc.mjs +16 -5
  113. package/assets/docs/icons.doc.mjs +21 -2
  114. package/assets/docs/illustrations.doc.mjs +15 -7
  115. package/assets/docs/internationalization.doc.mjs +5 -7
  116. package/assets/docs/layout.doc.dense.mjs +82 -130
  117. package/assets/docs/layout.doc.mjs +77 -133
  118. package/assets/docs/migration.doc.mjs +21 -19
  119. package/assets/docs/motion.doc.mjs +3 -16
  120. package/assets/docs/principles.doc.dense.mjs +5 -5
  121. package/assets/docs/principles.doc.mjs +0 -8
  122. package/assets/docs/principles.doc.zh.mjs +6 -6
  123. package/assets/docs/shape.doc.mjs +3 -8
  124. package/assets/docs/spacing.doc.mjs +2 -7
  125. package/assets/docs/styling-libraries.doc.mjs +2 -6
  126. package/assets/docs/styling.doc.mjs +23 -19
  127. package/assets/docs/theme.doc.dense.mjs +18 -58
  128. package/assets/docs/theme.doc.mjs +46 -56
  129. package/assets/docs/theme.doc.zh.mjs +8 -9
  130. package/assets/docs/tokens.doc.dense.mjs +2 -2
  131. package/assets/docs/tokens.doc.mjs +8 -389
  132. package/assets/docs/tokens.doc.zh.mjs +2 -2
  133. package/assets/docs/tree/integrations.doc.mjs +451 -25
  134. package/assets/docs/tree/integrations.test.mjs +62 -0
  135. package/assets/docs/tree/writing-docs.doc.mjs +286 -0
  136. package/assets/docs/typography.doc.mjs +4 -24
  137. package/assets/docs/working-with-ai.doc.mjs +22 -30
  138. package/assets/templates/blocks/components/InternationalizationProvider/InternationalizationProvider01ShippedLocale.tsx +1 -1
  139. package/authoring/config/config.doc.mjs +2 -10
  140. package/authoring/config/parse.d.mts +0 -2
  141. package/authoring/config/parse.mjs +0 -19
  142. package/authoring/config/parse.test.mjs +0 -8
  143. package/authoring/config/type.ts +2 -13
  144. package/authoring/doctypes/_schema.d.mts +2 -3
  145. package/authoring/doctypes/_schema.mjs +0 -6
  146. package/authoring/doctypes/base/graph-fields.doc.mjs +3 -3
  147. package/authoring/doctypes/base/type.ts +2 -4
  148. package/authoring/doctypes/command/command.doc.mjs +1 -1
  149. package/authoring/doctypes/command/type.ts +1 -1
  150. package/authoring/doctypes/component/component.doc.mjs +0 -6
  151. package/authoring/doctypes/component/type.ts +0 -8
  152. package/authoring/doctypes/reference/reference.doc.mjs +0 -7
  153. package/authoring/doctypes/reference/type.ts +0 -5
  154. package/authoring/doctypes/schema/schema.doc.mjs +2 -2
  155. package/authoring/doctypes/template/template.doc.mjs +1 -1
  156. package/authoring/doctypes/template/type.ts +2 -2
  157. package/authoring/index.d.mts +0 -1
  158. package/authoring/index.d.ts +0 -10
  159. package/authoring/index.mjs +0 -1
  160. package/authoring/integration/integration.doc.mjs +10 -12
  161. package/clients/cli/command-result-coverage.test.mjs +7 -7
  162. package/clients/cli/commands/component/index.mjs +55 -152
  163. package/clients/cli/commands/component-ownership.test.mjs +0 -89
  164. package/clients/cli/commands/component.doc.mjs +9 -27
  165. package/clients/cli/commands/debug-result-summary.test.mjs +2 -2
  166. package/clients/cli/commands/discover.doc.mjs +9 -53
  167. package/clients/cli/commands/discover.mjs +118 -393
  168. package/clients/cli/commands/docs.doc.mjs +1 -1
  169. package/clients/cli/commands/docs.mjs +17 -60
  170. package/clients/cli/commands/docs.test.mjs +294 -0
  171. package/clients/cli/commands/doctor-integration-docs.doc.mjs +2 -3
  172. package/clients/cli/commands/doctor-integration.test.mjs +0 -53
  173. package/clients/cli/commands/doctor.doc.mjs +1 -3
  174. package/clients/cli/commands/doctor.mjs +5 -49
  175. package/clients/cli/commands/gap-report.doc.mjs +9 -10
  176. package/clients/cli/commands/init.doc.mjs +6 -9
  177. package/clients/cli/commands/integration-add.doc.mjs +9 -9
  178. package/clients/cli/commands/integration-authoring.test.mjs +10 -61
  179. package/clients/cli/commands/integration-pack.doc.mjs +9 -5
  180. package/clients/cli/commands/integration-real-world.test.mjs +1 -1
  181. package/clients/cli/commands/integration.doc.mjs +4 -4
  182. package/clients/cli/commands/integration.mjs +43 -74
  183. package/clients/cli/commands/layout-check.doc.mjs +65 -0
  184. package/clients/cli/commands/layout-expand.doc.mjs +83 -0
  185. package/clients/cli/commands/layout-grammar.doc.mjs +30 -0
  186. package/clients/cli/commands/layout.doc.mjs +34 -0
  187. package/clients/cli/commands/layout.error-codes.test.mjs +66 -0
  188. package/clients/cli/commands/layout.exit-parity.test.mjs +41 -0
  189. package/clients/cli/commands/layout.mjs +275 -0
  190. package/clients/cli/commands/layout.path-help.test.mjs +33 -0
  191. package/clients/cli/commands/layout.stdin-cap.test.mjs +47 -0
  192. package/clients/cli/commands/layout.text-fields.test.mjs +39 -0
  193. package/clients/cli/commands/manifest.doc.mjs +1 -1
  194. package/clients/cli/commands/search.doc.mjs +3 -10
  195. package/clients/cli/commands/search.mjs +2 -21
  196. package/clients/cli/commands/search.test.mjs +4 -21
  197. package/clients/cli/commands/swizzle.doc.mjs +1 -1
  198. package/clients/cli/commands/template.doc.mjs +1 -1
  199. package/clients/cli/commands/text-json-parity.test.mjs +16 -5
  200. package/clients/cli/commands/theme-add.doc.mjs +1 -1
  201. package/clients/cli/commands/theme-palette-generate.doc.mjs +2 -3
  202. package/clients/cli/commands/theme-palette.doc.mjs +2 -1
  203. package/clients/cli/commands/theme-targets.doc.mjs +2 -2
  204. package/clients/cli/commands/theme.doc.mjs +1 -2
  205. package/clients/cli/commands/upgrade.doc.mjs +3 -62
  206. package/clients/cli/index.mjs +10 -28
  207. package/clients/cli/lib/define-command.mjs +4 -28
  208. package/clients/cli/lib/define-command.test.mjs +0 -54
  209. package/clients/cli/lib/exit-codes.test.mjs +9 -18
  210. package/clients/cli/lib/json-shim.mjs +14 -24
  211. package/clients/cli/lib/json-shim.test.mjs +20 -6
  212. package/clients/cli/lib/manifest.mjs +13 -18
  213. package/clients/cli/lib/manifest.test.mjs +2 -5
  214. package/foundation/agent-docs/agent-docs.mjs +1 -1
  215. package/foundation/agent-docs/agent-docs.test.mjs +1159 -0
  216. package/foundation/discovery/authoring-self-docs.mjs +0 -1
  217. package/foundation/discovery/authoring-self-docs.test.mjs +2 -6
  218. package/foundation/discovery/cli-self-docs.mjs +2 -16
  219. package/foundation/discovery/cli-self-docs.test.mjs +0 -20
  220. package/foundation/discovery/docs-discovery.mjs +1 -5
  221. package/foundation/discovery/docs-discovery.test.mjs +0 -21
  222. package/foundation/discovery/docs-section-key.d.mts +1 -1
  223. package/foundation/discovery/docs-section-key.mjs +1 -1
  224. package/foundation/discovery/template-adapter.mjs +1 -1
  225. package/foundation/doc-compiler/doc-loads.test.mjs +14 -3
  226. package/foundation/doc-compiler/tree.d.mts +0 -4
  227. package/foundation/doc-compiler/tree.mjs +1 -6
  228. package/foundation/doc-compiler/tree.test.mjs +598 -0
  229. package/foundation/integrations/cli-requirement.d.mts +6 -26
  230. package/foundation/integrations/cli-requirement.mjs +11 -46
  231. package/foundation/integrations/cli-requirement.test.mjs +2 -7
  232. package/foundation/integrations/contribution-inventory.mjs +1 -1
  233. package/foundation/integrations/integrations.d.mts +1 -14
  234. package/foundation/integrations/integrations.mjs +1 -41
  235. package/foundation/integrations/integrations.test.mjs +0 -31
  236. package/foundation/response/error-codes.doc.mjs +8 -6
  237. package/foundation/response/error-codes.test.mjs +5 -30
  238. package/foundation/response/response-types.doc.d.mts +3 -4
  239. package/foundation/response/response-types.doc.mjs +27 -40
  240. package/foundation/response/response-types.doc.test.mjs +0 -23
  241. package/foundation/response/response.doc.mjs +10 -11
  242. package/foundation/xle/browser.d.mts +3 -3
  243. package/foundation/xle/browser.mjs +3 -3
  244. package/foundation/xle/expand.mjs +2 -2
  245. package/foundation/xle/parse.mjs +1 -1
  246. package/foundation/xle/print.mjs +2 -2
  247. package/foundation/xle/splice.mjs +1 -1
  248. package/package.json +9 -9
  249. package/api/discover/_adapter.test.mjs +0 -215
  250. package/api/discover/_catalog-view.d.mts +0 -115
  251. package/api/discover/_catalog-view.mjs +0 -203
  252. package/api/discover/_catalog-view.test.mjs +0 -128
  253. package/api/discover/detail/item/item.d.mts +0 -26
  254. package/api/discover/detail/item/item.mjs +0 -78
  255. package/api/discover/detail/item/item.test.mjs +0 -73
  256. package/api/integration/pack-check.lifecycle-output.test.mjs +0 -107
  257. package/api/theme/add/add.rollback.test.mjs +0 -158
  258. package/api/theme/build/build.rollback.test.mjs +0 -148
  259. package/api/upgrade/run/files-changed.test.mjs +0 -111
  260. package/assets/codemods/file-count.test.mjs +0 -163
  261. package/assets/docs/tree/add-a-component.doc.mjs +0 -75
  262. package/assets/docs/tree/add-a-theme.doc.mjs +0 -85
  263. package/assets/docs/tree/add-a-topic.doc.mjs +0 -144
  264. package/assets/docs/tree/agent-guidance.doc.mjs +0 -138
  265. package/assets/docs/tree/block-template.doc.mjs +0 -130
  266. package/assets/docs/tree/build-the-template.doc.mjs +0 -28
  267. package/assets/docs/tree/building-blocks.doc.mjs +0 -46
  268. package/assets/docs/tree/check-your-docs.doc.mjs +0 -137
  269. package/assets/docs/tree/checks.doc.mjs +0 -119
  270. package/assets/docs/tree/codemods.doc.mjs +0 -147
  271. package/assets/docs/tree/component-family.doc.mjs +0 -113
  272. package/assets/docs/tree/component-imports.doc.mjs +0 -69
  273. package/assets/docs/tree/component-lookups.doc.mjs +0 -149
  274. package/assets/docs/tree/components.doc.mjs +0 -23
  275. package/assets/docs/tree/configuration.doc.mjs +0 -23
  276. package/assets/docs/tree/debug-and-gap-reports.doc.mjs +0 -182
  277. package/assets/docs/tree/define-the-theme.doc.mjs +0 -118
  278. package/assets/docs/tree/describe-the-component.doc.mjs +0 -57
  279. package/assets/docs/tree/docs.doc.mjs +0 -21
  280. package/assets/docs/tree/document-the-template.doc.mjs +0 -28
  281. package/assets/docs/tree/document-the-theme.doc.mjs +0 -68
  282. package/assets/docs/tree/export-template-assets.doc.mjs +0 -147
  283. package/assets/docs/tree/extend-or-replace.doc.mjs +0 -103
  284. package/assets/docs/tree/fonts-and-assets.doc.mjs +0 -106
  285. package/assets/docs/tree/generate-a-palette.doc.mjs +0 -66
  286. package/assets/docs/tree/grade-template-with-agent.doc.mjs +0 -105
  287. package/assets/docs/tree/help.doc.mjs +0 -16
  288. package/assets/docs/tree/links.doc.mjs +0 -98
  289. package/assets/docs/tree/package-and-test.doc.mjs +0 -32
  290. package/assets/docs/tree/page-template.doc.mjs +0 -71
  291. package/assets/docs/tree/publishing.doc.mjs +0 -111
  292. package/assets/docs/tree/quick-start.doc.mjs +0 -272
  293. package/assets/docs/tree/replace-a-core-component.doc.mjs +0 -104
  294. package/assets/docs/tree/replace-a-core-template.doc.mjs +0 -172
  295. package/assets/docs/tree/sections-and-placement.doc.mjs +0 -108
  296. package/assets/docs/tree/see-it-in-an-app.doc.mjs +0 -59
  297. package/assets/docs/tree/ship.doc.mjs +0 -16
  298. package/assets/docs/tree/short-and-findable.doc.mjs +0 -108
  299. package/assets/docs/tree/single-component.doc.mjs +0 -165
  300. package/assets/docs/tree/start-a-template.doc.mjs +0 -143
  301. package/assets/docs/tree/subcomponent.doc.mjs +0 -115
  302. package/assets/docs/tree/template-assets.doc.mjs +0 -64
  303. package/assets/docs/tree/template-doc-overview.doc.mjs +0 -109
  304. package/assets/docs/tree/template-fonts.doc.mjs +0 -102
  305. package/assets/docs/tree/template-grading-rubric.doc.mjs +0 -452
  306. package/assets/docs/tree/template-icons.doc.mjs +0 -97
  307. package/assets/docs/tree/template-images-media.doc.mjs +0 -127
  308. package/assets/docs/tree/template-styles.doc.mjs +0 -93
  309. package/assets/docs/tree/templates.doc.mjs +0 -34
  310. package/assets/docs/tree/test-in-an-app.doc.mjs +0 -115
  311. package/assets/docs/tree/test-template-in-app.doc.mjs +0 -128
  312. package/assets/docs/tree/themes.doc.mjs +0 -39
  313. package/assets/docs/tree/troubleshooting.doc.mjs +0 -149
  314. package/assets/docs/tree/upgrading.doc.mjs +0 -103
  315. package/assets/docs/tree/use-a-theme-in-an-app.doc.mjs +0 -51
  316. package/assets/docs/tree/verify-packed-template.doc.mjs +0 -77
  317. package/assets/docs/tree/versioning.doc.mjs +0 -161
  318. package/assets/docs/tree/write-good-templates.doc.mjs +0 -64
  319. package/assets/docs/tree/write-the-template-file.doc.mjs +0 -154
  320. package/authoring/discover/discover.doc.d.mts +0 -13
  321. package/authoring/discover/discover.doc.mjs +0 -138
  322. package/authoring/discover/parse.d.mts +0 -24
  323. package/authoring/discover/parse.mjs +0 -128
  324. package/authoring/discover/parse.test.mjs +0 -124
  325. package/authoring/discover/type.ts +0 -87
  326. package/clients/cli/commands/component-batch.test.mjs +0 -341
  327. package/clients/cli/commands/discover.sources.test.mjs +0 -267
  328. package/clients/cli/commands/integration-verify.doc.mjs +0 -22
  329. package/clients/cli/lib/parse-error-format.test.mjs +0 -81
  330. package/foundation/response/batch.type.d.mts +0 -33
  331. package/foundation/response/batch.type.mjs +0 -34
@@ -13,16 +13,19 @@ export const doc = {
13
13
  name: 'upgrade',
14
14
  namespace: 'cli/api',
15
15
  displayName: 'upgrade()',
16
- summary:
17
- 'After bumping @astryxdesign/core, migrate project source with codemods and update copied compositions.',
16
+ summary: 'Run version migrations and reconcile copied compositions.',
18
17
  description:
19
- 'Runs the codemods between `from` and the installed Core version, then refreshes the ' +
20
- 'managed agent-docs block. Dry-run by default; `apply` writes changes only after the ' +
21
- 'selected codemods and hooks succeed. Config codemods run before astryx.config is ' +
22
- 'loaded, so they can repair an invalid config. Also updates copied compositions from ' +
23
- 'their install receipts: unchanged files are updated, non-overlapping edits are merged, ' +
24
- 'and conflicts are left untouched. `list` only lists codemods; `registry` only updates ' +
25
- 'copied compositions.',
18
+ 'Migrates project source from a previous Astryx version to the currently ' +
19
+ 'installed one by running the registered codemods, and compares the fully ' +
20
+ 'rendered managed agent-docs block on every migration path, including ' +
21
+ 'same-Core integration guidance changes; list and registry-only modes do not ' +
22
+ 'run migration reconciliation. Dry-run previews without writing; `apply` ' +
23
+ 'writes the prepared block only after selected codemods and hooks succeed. ' +
24
+ 'Core codemods run before ' +
25
+ 'the config is loaded so a config codemod can repair an otherwise-invalid ' +
26
+ 'astryx.config. Copied compositions carry adjacent receipts with exact canonical and format-specific install bases; upgrade ' +
27
+ 'compares those installed bases with the matching registry release, updates pristine ' +
28
+ 'files, merges non-overlapping edits, and leaves conflicting originals untouched.',
26
29
  importPath: '@astryxdesign/cli/api',
27
30
  signature:
28
31
  'upgrade(options?: UpgradeOptions, ctx?: {cwd?: string}): Promise<UpgradeListResponse | UpgradeRegistryResponse | UpgradeStatusResponse | UpgradeRunResponse>',
@@ -39,7 +42,7 @@ export const doc = {
39
42
  name: 'options.from',
40
43
  type: 'string',
41
44
  description:
42
- 'Version before the dependency bump; the target is the installed @astryxdesign/core (or legacy @xds/core). Required unless `list` or `registry` is set.',
45
+ 'Version before the dependency bump. Required unless `list` or `registry` is set.',
43
46
  },
44
47
  {
45
48
  name: 'options.apply',
@@ -52,13 +55,11 @@ export const doc = {
52
55
  type: 'boolean',
53
56
  description:
54
57
  'Run codemods even when `from` is at/after the installed version.',
55
- default: 'false',
56
58
  },
57
59
  {
58
60
  name: 'options.codemod',
59
61
  type: 'string',
60
- description:
61
- 'Run only this codemod. Optional codemods run only when named here. Setting it also skips copied-composition reconciliation.',
62
+ description: 'Run a single named transform instead of the full set.',
62
63
  },
63
64
  {
64
65
  name: 'options.skipCodemod',
@@ -82,26 +83,23 @@ export const doc = {
82
83
  type: 'boolean',
83
84
  description:
84
85
  'Install jscodeshift when it is missing; otherwise a missing jscodeshift throws ERR_DEP_MISSING.',
85
- default: 'false',
86
86
  },
87
87
  {
88
88
  name: 'options.registry',
89
89
  type: 'boolean',
90
90
  description:
91
- 'Only reconcile copied compositions from their install receipts; `from` is not required. Cannot be combined with `list`, `from`, `force`, `codemod`, `skipCodemod`, `integration` or `installDeps`.',
91
+ 'Reconcile copied compositions from their install receipts without requiring `from`.',
92
92
  default: 'false',
93
93
  },
94
94
  {
95
95
  name: 'options.list',
96
96
  type: 'boolean',
97
97
  description: 'Return the available codemods instead of running any.',
98
- default: 'false',
99
98
  },
100
99
  {
101
100
  name: 'ctx.cwd',
102
101
  type: 'string',
103
102
  description: 'Directory to run the upgrade in.',
104
- default: 'process.cwd()',
105
103
  },
106
104
  ],
107
105
  returns: [
@@ -118,36 +116,36 @@ export const doc = {
118
116
  {
119
117
  type: 'upgrade.status',
120
118
  description:
121
- 'A short-circuit outcome (no codemods executed): `up_to_date` (`from` is at/after the installed target and no `force`), `no_codemods` (none apply to the range), or `config_fixable` (dry-run preview that a pending config codemod would repair an invalid astryx.config). up_to_date and no_codemods carry the agent-docs summary and, when receipts are found, the copied-composition summary; config_fixable carries configError, configCodemods, suggestedCommand, message, note, and the agent-docs summary.',
119
+ 'A short-circuit outcome (no codemods executed): `up_to_date` (`from` is at/after the installed target and no `force`), `no_codemods` (none apply to the range), or `config_fixable` (dry-run preview that a pending config codemod would repair an invalid astryx.config). Each carries the agent-docs summary and, when found, the copied-composition registry summary.',
122
120
  },
123
121
  {
124
122
  type: 'upgrade.run',
125
123
  description:
126
- 'The terminal run receipt: from, to, codemods (count), integrations, agentDocs, agentDocsRefreshed, registryCompositions (when receipts are found), filesChanged, transformsApplied, modifiedFiles, protectedFiles, declinedCandidates, errors, and complete. When a protected file still requires a change, complete is false and errorCode is ERR_CODEMOD_PROTECTED; the CLI exits nonzero while preserving the structured receipt.',
124
+ 'The terminal run receipt: from/to versions, codemod count, integrations processed, agent-docs and registry summaries, modifiedFiles, protectedFiles, declinedCandidates, and completion state. A protected required change returns complete: false with ERR_CODEMOD_PROTECTED; the CLI exits nonzero while preserving the structured receipt.',
127
125
  },
128
126
  ],
129
127
  throws: [
130
128
  {
131
129
  code: 'ERR_INVALID_ARGUMENT',
132
- when: '`from` is missing (and neither `list` nor `registry` is set); `list` and `registry` are both set; `registry` is combined with `from`, `force`, `codemod`, `skipCodemod`, `integration` or `installDeps`; an `integration` specifier is invalid or not installed; or astryx.config fails to load or validate and no pending config codemod repairs it',
130
+ when: '`from` is missing (and neither `list` nor `registry` is set), or the project config fails strict validation and no pending config codemod can repair it',
133
131
  },
134
132
  {code: 'ERR_INVALID_VERSION', when: '`from` is not a valid semver string'},
135
133
  {code: 'ERR_PATH_TRAVERSAL', when: '`path` resolves outside cwd'},
136
134
  {
137
135
  code: 'ERR_VERSION_DETECT',
138
- when: 'neither @astryxdesign/core nor legacy @xds/core is installed in cwd; with `registry`, only when copied-composition receipts exist and @astryxdesign/core is not installed',
136
+ when: 'the installed @astryxdesign/core version cannot be detected',
139
137
  },
140
138
  {
141
139
  code: 'ERR_DEP_MISSING',
142
- when: 'jscodeshift is missing and `installDeps` is not set, or installing it failed',
140
+ when: 'jscodeshift is required but could not be installed',
143
141
  },
144
142
  {
145
143
  code: 'ERR_UNKNOWN_CODEMOD',
146
- when: 'the version range has codemods but none remain selected: `codemod` names no codemod in the range, or `skipCodemod` excludes all of them',
144
+ when: 'a `codemod` name matches no registered codemod',
147
145
  },
148
146
  {
149
147
  code: 'ERR_CODEMOD_FAILED',
150
- when: 'one or more codemods failed, or a post-codemod hook failed, and no protected file still needs a change (otherwise an upgrade.run receipt with complete: false is returned)',
148
+ when: 'one or more codemods failed, or a post-codemod hook failed',
151
149
  },
152
150
  {
153
151
  code: 'ERR_CODEMOD_PROTECTION_SOURCE',
@@ -119,11 +119,11 @@
119
119
  * @property {RegistryCompositionSummary} [data.registryCompositions]
120
120
  * @property {boolean} [data.complete] False when protected required changes remain.
121
121
  * @property {'ERR_CODEMOD_PROTECTED'} [data.errorCode] Stable incomplete-result code when complete is false.
122
- * @property {number} [data.filesChanged] Distinct files changed across core + integration codemods (apply mode). One file that four codemods each changed counts once.
122
+ * @property {number} [data.filesChanged] Total files changed across core + integration codemods (apply mode).
123
123
  * @property {string[]} [data.modifiedFiles] Project-relative files changed or previewed.
124
124
  * @property {ProtectedCodemodFile[]} [data.protectedFiles] Protected files that still require a codemod change after regeneration.
125
125
  * @property {Array<{file: string, location?: string, reason: string}>} [data.declinedCandidates] Candidates left unchanged because proof was insufficient.
126
- * @property {number} [data.transformsApplied] Total codemod changes. A code or config codemod counts once for each file it changed, so one file changed by four of them counts four times; a project codemod counts once, however many files it writes.
126
+ * @property {number} [data.transformsApplied] Total transforms that reported a change.
127
127
  * @property {Array<{file: string, codemod: string, error: string}>} [data.errors] Per-codemod errors, when any codemod failed.
128
128
  */
129
129
 
@@ -46,9 +46,7 @@ describe('runCodemods — ordered dry-run state', () => {
46
46
  silent: true,
47
47
  });
48
48
 
49
- // One file that two transforms changed is one file and two changes.
50
- expect(preview.totalFilesChanged).toBe(1);
51
- expect(preview.totalTransformsApplied).toBe(2);
49
+ expect(preview.totalFilesChanged).toBe(2);
52
50
  expect(preview.changedFiles).toEqual([
53
51
  path.join(srcDir, 'a.ts'),
54
52
  path.join(srcDir, 'a.ts'),
@@ -67,6 +67,7 @@ export function runIntegrationCodemods(
67
67
  /** In-memory pipeline state keeps ordered dry-runs equivalent to apply. */
68
68
  const virtualContents = new Map(providedContents ?? []);
69
69
 
70
+ let totalFilesChanged = 0;
70
71
  let totalTransformsApplied = 0;
71
72
  /** @type {string[]} */
72
73
  const changedFiles = [];
@@ -114,6 +115,7 @@ export function runIntegrationCodemods(
114
115
  protection,
115
116
  contents: virtualContents,
116
117
  });
118
+ totalFilesChanged += r.filesChanged;
117
119
  totalTransformsApplied += r.filesChanged;
118
120
  changedFiles.push(...r.changedFiles);
119
121
  writtenFiles.push(...r.writtenFiles);
@@ -143,6 +145,7 @@ export function runIntegrationCodemods(
143
145
  protection,
144
146
  contents: virtualContents,
145
147
  });
148
+ totalFilesChanged += r.filesChanged;
146
149
  totalTransformsApplied += r.filesChanged;
147
150
  changedFiles.push(...r.changedFiles);
148
151
  writtenFiles.push(...r.writtenFiles);
@@ -151,9 +154,6 @@ export function runIntegrationCodemods(
151
154
  }
152
155
  }
153
156
 
154
- // A file several codemods changed is one file; transforms count each change.
155
- const totalFilesChanged = new Set(changedFiles).size;
156
-
157
157
  return {
158
158
  totalFilesChanged,
159
159
  totalTransformsApplied,
@@ -486,6 +486,7 @@ export async function runCodemods(
486
486
  (await import('jscodeshift')).default
487
487
  );
488
488
 
489
+ let totalFilesChanged = 0;
489
490
  let totalTransformsApplied = 0;
490
491
  let totalValidationBlocked = 0;
491
492
  /** @type {Array<{file: string, codemod: string, error: string}>} */
@@ -553,6 +554,7 @@ export async function runCodemods(
553
554
  protectionWriteCount = writtenFiles.length;
554
555
  }
555
556
  if (result.filesChanged > 0) {
557
+ totalFilesChanged += result.filesChanged;
556
558
  totalTransformsApplied += 1;
557
559
  }
558
560
  continue;
@@ -575,6 +577,7 @@ export async function runCodemods(
575
577
  changedFiles.push(...result.changedFiles);
576
578
  writtenFiles.push(...result.writtenFiles);
577
579
  if (result.filesChanged > 0) {
580
+ totalFilesChanged += result.filesChanged;
578
581
  totalTransformsApplied += result.filesChanged;
579
582
  }
580
583
  continue;
@@ -589,6 +592,7 @@ export async function runCodemods(
589
592
  protectedFiles.push(...result.protectedFiles);
590
593
  changedFiles.push(...result.changedFiles);
591
594
  writtenFiles.push(...result.writtenFiles);
595
+ totalFilesChanged += result.filesChanged;
592
596
  totalTransformsApplied += result.filesChanged;
593
597
  totalValidationBlocked += result.errors.filter(
594
598
  error =>
@@ -626,11 +630,6 @@ export async function runCodemods(
626
630
  );
627
631
  }
628
632
 
629
- // A file several codemods changed is one file. `totalTransformsApplied` is
630
- // unchanged: a code or config codemod counts each file it changed, and a
631
- // project codemod counts once. The two answer different questions.
632
- const totalFilesChanged = new Set(changedFiles).size;
633
-
634
633
  if (protectedFiles.length > 0) {
635
634
  const files = [...new Set(protectedFiles.map(item => item.file))];
636
635
  log.warn(
@@ -21,15 +21,13 @@ Someone building a product with Astryx. Their questions:
21
21
  ## Tells that you are writing for us instead
22
22
 
23
23
  - second person aimed at the wrong reader — "reviewers should…", "before promoting a component…", "attach evidence for…"
24
- - an internal rubric, readiness gate, audit checklist, or sign-off that the reader must satisfy for Astryx maintainers
24
+ - **rubric, readiness, gate, audit, checklist, sign-off, promotion, evidence** as things the reader must produce
25
25
  - a table of things to verify rather than things to use
26
26
  - anything about lab → core, which is our lifecycle, not theirs
27
27
  - Storybook, Playwright, CI or the Simulator named as tools the reader runs
28
28
 
29
29
  One subtlety: a statement about the **system's behavior** is caller-facing even when it sounds like process. "A component's theme targets are stable once published" tells a caller what they can rely on; "reviewers must check that theme targets are stable" is ours. Same fact, different reader — **rewrite it rather than move it**.
30
30
 
31
- A public authoring-quality rubric is also caller-facing when it helps someone evaluate an artifact they create through Astryx. It must be complete and actionable from public inputs. It must not include Astryx's internal approval, promotion, evidence-publication, or CI process. A current system spec must assign the shipped guide as the rubric's owner.
32
-
33
31
  ## Where the rest goes
34
32
 
35
33
  The material is usually good; the finding is placement, not quality. It goes in the [wiki](https://github.com/facebook/astryx/wiki) — **as a section on the page that already covers it, not a new page.** The wiki is at nearly 60 pages, several of them overlapping, because every stray section got its own.
@@ -57,5 +55,5 @@ Worked example: a responsive-and-interaction readiness rubric is grading criteri
57
55
  one section by its key. A section's key is its `id`, or a key derived from its
58
56
  title when it has none. Give a section an `id` when its title may change, since
59
57
  readers and extensions link to the key. Two sections in one topic cannot share
60
- a key. Keep each section small enough to read on its own: `astryx doctor` warns on
58
+ a key. Keep each section small enough to read on its own: `astryx doctor` fails
61
59
  any section over 32 KB.
@@ -73,7 +73,7 @@ export const docs = {
73
73
  'Baseline 2026: the tightest requirement.',
74
74
  ],
75
75
  [
76
- '`Popover` API',
76
+ '[`Popover`](https://developer.mozilla.org/en-US/docs/Web/API/Popover_API) API',
77
77
  'Opens, stacks, and light-dismisses layered surfaces via the top layer.',
78
78
  'Baseline 2025.',
79
79
  ],
@@ -86,7 +86,7 @@ export const docs = {
86
86
  },
87
87
  {
88
88
  type: 'prose',
89
- text: 'The gap that matters is between Tier 1 and Tier 2: the `Popover` API and `light-dark()` reached wide availability well before anchor positioning. So in Tier 2 browsers, layered surfaces open and dismiss correctly; they just are not positioned. This is the one feature most consumers will need to reason about.',
89
+ text: 'The gap that matters is between Tier 1 and Tier 2: the [`Popover`](https://developer.mozilla.org/en-US/docs/Web/API/Popover_API) API and `light-dark()` reached wide availability well before anchor positioning. So in Tier 2 browsers, layered surfaces open and dismiss correctly; they just are not positioned. This is the one feature most consumers will need to reason about.',
90
90
  },
91
91
  ],
92
92
  },
@@ -95,24 +95,24 @@ export const docs = {
95
95
  content: [
96
96
  {
97
97
  type: 'prose',
98
- text: 'Any component that opens a menu, popover, tooltip, or dropdown carries the browser requirement: it renders that surface in an overlay positioned against its trigger. That includes:',
98
+ text: 'The browser requirement is concentrated in the layered-surface components: anything that renders content in an overlay positioned against a trigger:',
99
99
  },
100
100
  {
101
101
  type: 'list',
102
102
  style: 'unordered',
103
103
  items: [
104
- 'Tooltip, HoverCard, and Popover, and any prop that shows one (such as the Button `tooltip`)',
105
- 'DropdownMenu, MoreMenu, and ContextMenu',
106
- 'Selector, MultiSelector, ComplexSelector, Typeahead, and PowerSearch (dropdown surfaces)',
107
- 'DateInput, DateRangeInput, and DateTimeInput (calendar popovers)',
104
+ 'Tooltip',
105
+ 'HoverCard',
106
+ 'Popover',
107
+ 'ContextMenu',
108
+ 'Selector and MultiSelector (dropdown surfaces)',
108
109
  'Tokenizer (suggestion menu)',
109
- 'The overflow and flyout menus in Breadcrumbs, TabList, TopNav, and SideNav',
110
110
  'Carousel (anchored controls)',
111
111
  ],
112
112
  },
113
113
  {
114
114
  type: 'prose',
115
- text: 'If your product opens no menus, popovers, tooltips, or dropdowns, it has no anchor-positioning requirement; it needs only `light-dark()` (Tier 2 and up) for correct theme colors. Page layout, typography, forms, buttons, cards, and tables work down to Tier 2 with no special handling.',
115
+ text: 'If your product does not use any of these, it has no anchor-positioning requirement at all; it needs only `light-dark()` (Tier 2 and up) for correct theme colors. Page layout, typography, forms, buttons, cards, tables, and navigation all work down to Tier 2 with no special handling.',
116
116
  },
117
117
  ],
118
118
  },
@@ -123,7 +123,7 @@ export const docs = {
123
123
  type: 'list',
124
124
  style: 'do',
125
125
  items: [
126
- 'Components never throw on missing platform APIs. Where a browser lacks the `Popover` API, layers fall back to plain visibility instead of crashing.',
126
+ 'Components never throw on missing platform APIs. Where a browser lacks the [`Popover`](https://developer.mozilla.org/en-US/docs/Web/API/Popover_API) API, layers fall back to plain visibility instead of crashing.',
127
127
  'Tier 1 and Tier 2 are officially supported and tested.',
128
128
  'Non-layered components render correctly down to Tier 2.',
129
129
  ],
@@ -192,7 +192,7 @@ const hasLightDark = CSS.supports('color', 'light-dark(#000, #fff)');`,
192
192
  },
193
193
  {
194
194
  type: 'prose',
195
- text: 'This is not an arbitrary window: Baseline − 2 is close to where anchor positioning stops being available while the `Popover` API and `light-dark()` still are, so the tier boundary tracks a real capability edge, not a guessed date. The version floors above are reviewed and advanced roughly once a year as new Baseline years land. Always feature-detect rather than hardcoding version numbers, so your app adapts automatically as the platform moves.',
195
+ text: 'This is not an arbitrary window: Baseline − 2 is close to where anchor positioning stops being available while the [`Popover`](https://developer.mozilla.org/en-US/docs/Web/API/Popover_API) API and `light-dark()` still are, so the tier boundary tracks a real capability edge, not a guessed date. The version floors above are reviewed and advanced roughly once a year as new Baseline years land. Always feature-detect rather than hardcoding version numbers, so your app adapts automatically as the platform moves.',
196
196
  },
197
197
  ],
198
198
  },
@@ -22,8 +22,7 @@ export const docs = {
22
22
  ],
23
23
  },
24
24
  {
25
- id: 'surface-colors',
26
- title: 'Color Tokens',
25
+ title: 'Surface Colors',
27
26
  category: 'foundations',
28
27
  content: [
29
28
  {
@@ -38,14 +37,9 @@ export const docs = {
38
37
  ],
39
38
  },
40
39
  {
41
- id: 'usage',
42
- title: 'Use color tokens in StyleX',
40
+ title: 'Usage',
43
41
  category: 'foundations',
44
42
  content: [
45
- {
46
- type: 'prose',
47
- text: 'Import the typed color tokens and use them in `stylex.create()`; they resolve to the active theme and color mode.',
48
- },
49
43
  {
50
44
  type: 'code',
51
45
  lang: 'tsx',
@@ -82,7 +82,7 @@ export const docs = {
82
82
  content: [
83
83
  {
84
84
  type: 'prose',
85
- text: 'Configurable surfaces expose a single `elevation` prop instead of asking consumers to hand-write a box-shadow. It takes the graded enum `none | low | med | high`, narrowed per component to the steps that surface needs: Card, ClickableCard, SelectableCard, Button, IconButton, ButtonGroup, ToggleButton, and Banner expose the full scale, while ChatComposer exposes only `none | low`. `none` is a flat literal (`box-shadow: none`); the other levels map to the `--shadow-*` tokens above, so a surface stays theme-agnostic.',
85
+ text: 'Configurable surfaces expose a single `elevation` prop instead of asking consumers to hand-write a box-shadow. It takes the graded enum `none | low | med | high`, narrowed per component to the steps that surface needs: Card, ClickableCard, SelectableCard, Button, IconButton, ButtonGroup, and Banner expose the full scale, while ChatComposer exposes only `none | low`. `none` is a flat literal (`box-shadow: none`); the other levels map to the `--shadow-*` tokens above, so a surface stays theme-agnostic.',
86
86
  },
87
87
  {
88
88
  type: 'prose',
@@ -92,13 +92,11 @@ export const docs = {
92
92
  type: 'code',
93
93
  lang: 'tsx',
94
94
  label: 'Raising a surface with the elevation prop',
95
- code: `import {Plus} from 'lucide-react';
96
-
97
- // Flat by default; raise only when the surface needs to float.
95
+ code: `// Flat by default; raise only when the surface needs to float.
98
96
  <Card elevation="low">Raised card</Card>
99
97
 
100
98
  // A floating action button.
101
- <IconButton icon={<Icon icon={Plus} />} label="New" variant="primary" elevation="med" />
99
+ <IconButton icon={<Icon icon="add" />} label="New" variant="primary" elevation="med" />
102
100
 
103
101
  // Flatten the composer (defaults to 'low').
104
102
  <ChatComposer elevation="none" onSubmit={handleSubmit} />`,
@@ -121,7 +119,7 @@ export const docs = {
121
119
  type: 'code',
122
120
  lang: 'tsx',
123
121
  label: 'Applying elevation',
124
- code: `import {shadowVars} from '@astryxdesign/core/theme/tokens.stylex';
122
+ code: `import {shadowVars} from '@astryxdesign/core';
125
123
 
126
124
  const styles = stylex.create({
127
125
  dropdown: {
@@ -8,7 +8,6 @@ export const docs = {
8
8
  category: 'guide',
9
9
  description:
10
10
  'Add the design system to your project and start building.',
11
- keywords: ['quick start', 'setup', 'install'],
12
11
 
13
12
  sections: [
14
13
  {
@@ -82,11 +81,24 @@ export const docs = {
82
81
  },
83
82
  {
84
83
  type: 'prose',
85
- text: 'Run `astryx theme list` to see every theme.',
84
+ text: 'Available themes:',
85
+ },
86
+ {
87
+ type: 'list',
88
+ style: 'unordered',
89
+ items: [
90
+ '`@astryxdesign/theme-neutral`: muted and minimal; a good starting point',
91
+ '`@astryxdesign/theme-butter`: warm, golden tones with blue accents',
92
+ '`@astryxdesign/theme-chocolate`: rich chocolate and caramel tones',
93
+ '`@astryxdesign/theme-gothic`: dark-only theme with ink and noir influences',
94
+ '`@astryxdesign/theme-matcha`: earthy greens and botanical tones',
95
+ '`@astryxdesign/theme-stone`: warm neutrals inspired by sandstone',
96
+ '`@astryxdesign/theme-y2k`: playful early-2000s pop aesthetic',
97
+ ],
86
98
  },
87
99
  {
88
100
  type: 'prose',
89
- text: 'These stylesheets are cascade-layered: the reset loads in @layer reset and component styles in @layer astryx-base. If your project has existing global CSS, a legacy reset, or Tailwind, declare the layer order explicitly and assign every stylesheet to a layer deliberately: unlayered styles and later layers both override astryx-base regardless of specificity. Before building screens, read the two cascade layer sections of {@link generic:migration}.',
101
+ text: 'These stylesheets are cascade-layered: the reset loads in @layer reset and component styles in @layer astryx-base. If your project has existing global CSS, a legacy reset, or Tailwind, declare the layer order explicitly and assign every stylesheet to a layer deliberately: unlayered styles and later layers both override astryx-base regardless of specificity. See the Cascade Layer Safety section in {@link generic:migration} before building screens.',
90
102
  },
91
103
  {
92
104
  type: 'prose',
@@ -123,7 +135,7 @@ export default function Page() {
123
135
  content: [
124
136
  {
125
137
  type: 'prose',
126
- text: 'Astryx components support various styling solutions, from plain CSS and `className` to Tailwind and CSS-in-JS. See {@link generic:styling} for the full guide. Astryx also has a deep integration with [StyleX](https://stylexjs.com/), an atomic CSS-in-JS library: create styles with `stylex.create()` and pass them to components with the `xstyle` prop.',
138
+ text: 'Astryx components support various styling solutions, from plain CSS and `className` to Tailwind and CSS-in-JS. See the [styling docs](/docs/styling) for the full guide. Astryx also has a deep integration with [StyleX](https://stylexjs.com/), an atomic CSS-in-JS library: create styles with `stylex.create()` and pass them to components with the `xstyle` prop.',
127
139
  },
128
140
  {
129
141
  type: 'code',
@@ -155,7 +167,6 @@ const overrides = stylex.create({
155
167
  ['Next.js + Tailwind', 'Next.js + Tailwind bridge', '[apps/example-nextjs-tailwind](https://github.com/facebook/astryx/tree/main/apps/example-nextjs-tailwind)'],
156
168
  ['Next.js Source', 'Next.js importing from source', '[apps/example-nextjs-source](https://github.com/facebook/astryx/tree/main/apps/example-nextjs-source)'],
157
169
  ['Vite', 'Vite', '[apps/example-vite](https://github.com/facebook/astryx/tree/main/apps/example-vite)'],
158
- ['Vite + Tailwind', 'Vite + Tailwind bridge', '[apps/example-vite-tailwind](https://github.com/facebook/astryx/tree/main/apps/example-vite-tailwind)'],
159
170
  ],
160
171
  },
161
172
  {
@@ -73,7 +73,7 @@ export const docs = {
73
73
  import { HeartIcon } from 'lucide-react';
74
74
 
75
75
  <Icon icon={PhotoIcon} size="lg" />
76
- <Icon icon={HeartIcon} color="error" />`,
76
+ <Icon icon={HeartIcon} color="negative" />`,
77
77
  },
78
78
  ],
79
79
  },
@@ -128,7 +128,26 @@ export const brandTheme = defineTheme({
128
128
  },
129
129
  {
130
130
  type: 'prose',
131
- text: 'Outside core, pass a fallback to `getExtendedIcon(key, fallback)` so the glyph renders with no theme.',
131
+ text: 'Ship the fallback in `defaultIcons` under the same key so the glyph still renders with no theme, or pass one to `getExtendedIcon(key, fallback)` when the icon lives outside core.',
132
+ },
133
+ ],
134
+ },
135
+ {
136
+ title: 'Adding New Icons',
137
+ category: 'foundations',
138
+ content: [
139
+ {
140
+ type: 'prose',
141
+ text: 'To add a new semantic icon name to the design system, only for a glyph the whole system shares; a component-owned one takes a namespaced key instead:',
142
+ },
143
+ {
144
+ type: 'list',
145
+ style: 'ordered',
146
+ items: [
147
+ 'Add the name to IconName type in `packages/core/src/Icon/globalIconRegistry.tsx`',
148
+ 'Add the default SVG to `packages/core/src/Icon/defaultIcons.tsx`',
149
+ 'Add a row to the Available Names table in `packages/cli/assets/docs/icons.doc.mjs`',
150
+ ],
132
151
  },
133
152
  ],
134
153
  },
@@ -7,7 +7,6 @@ export const docs = {
7
7
  category: 'foundations',
8
8
  description:
9
9
  'Illustration guidelines for empty states, onboarding flows, and feature highlights.',
10
- keywords: ['empty state'],
11
10
 
12
11
  sections: [
13
12
  {
@@ -60,17 +59,26 @@ export const docs = {
60
59
  content: [
61
60
  {
62
61
  type: 'prose',
63
- text: 'For an empty state, pass the illustration to the `icon` slot of `EmptyState`, which centers it above the title and description. Typical illustration sizes range from 120px for inline empty states to 240px for full-page onboarding screens. Always pair the illustration with a title and a description that says what to do next.',
62
+ text: 'Place illustrations inside Center with supporting text stacked below. Typical illustration sizes range from 120px for inline empty states to 240px for full-page onboarding screens. Always pair the illustration with a heading and optional body text to explain what the user should do next.',
64
63
  },
65
64
  {
66
65
  type: 'code',
67
66
  lang: 'tsx',
68
67
  label: 'Empty state with illustration',
69
- code: `<EmptyState
70
- icon={<img src="/illustrations/empty-search.svg" alt="" width={200} height={200} />}
71
- title="No results found"
72
- description="Try adjusting your search or filters."
73
- />`,
68
+ code: `<Center>
69
+ <Stack direction="vertical" gap={3} hAlign="center">
70
+ <img
71
+ src="/illustrations/empty-search.svg"
72
+ alt="No results"
73
+ style={{ width: 200, height: 200 }}
74
+ />
75
+ <Heading level={3}>No results found</Heading>
76
+ <Text type="body" color="secondary">
77
+ Try adjusting your search or filters to find what you\u2019re
78
+ looking for.
79
+ </Text>
80
+ </Stack>
81
+ </Center>`,
74
82
  },
75
83
  ],
76
84
  },
@@ -41,17 +41,15 @@ function App() {
41
41
  lang: 'tsx',
42
42
  label: 'Load an astryx locale catalog',
43
43
  code: `import {InternationalizationProvider} from '@astryxdesign/core/i18n';
44
- import frFR from '@astryxdesign/core/locales/fr-FR.generated.js';
44
+ import fr from '@astryxdesign/core/locales/fr.json';
45
45
 
46
- <InternationalizationProvider
47
- locale="fr-FR"
48
- messages={{'fr-FR': frFR}}>
46
+ <InternationalizationProvider locale="fr" messages={{fr}}>
49
47
  <App />
50
48
  </InternationalizationProvider>;`,
51
49
  },
52
50
  {
53
51
  type: 'prose',
54
- text: 'Astryx ships English and first-party translations for supported locales. Compact runtime modules from `@astryxdesign/core/locales/*.generated.js` contain only the messages apps need; the existing `@astryxdesign/core/locales/*.json` files retain translator context. Until a locale is available, apps can pass a local catalog in either shape. Missing keys fall back through the locale chain to English (for example, `pt-BR` walks to `pt`, then to shipped `en`).',
52
+ text: 'Astryx ships English today, with first-party translations for other locales on the roadmap. Until a locale is available from `@astryxdesign/core/locales/*`, apps can pass a local catalog with the same shape. See `@astryxdesign/core/locales/en.json` for the current key inventory. Missing keys fall back through the locale chain to English (for example, `pt-BR` walks to `pt`, then to shipped `en`).',
55
53
  },
56
54
  {
57
55
  type: 'prose',
@@ -292,7 +290,7 @@ export default function App() {
292
290
  },
293
291
  {
294
292
  type: 'prose',
295
- text: '`Catalog` types the rich `{defaultMessage, description?}` authoring shape. `RuntimeCatalog` types the generated key-to-message string map. `ProviderMessagesByLocale` accepts either shape for the provider, while `MessagesByLocale` keeps the original rich-only context shape.',
293
+ text: '`Catalog` types a single locale file; `MessagesByLocale` types the map passed to `messages`. A catalog entry uses the same `{defaultMessage, description?}` shape as `@astryxdesign/core/locales/en.json`.',
296
294
  },
297
295
  ],
298
296
  },
@@ -309,7 +307,7 @@ export default function App() {
309
307
  lang: 'tsx',
310
308
  label: 'Turn on pseudo-localization',
311
309
  code: `import {InternationalizationProvider} from '@astryxdesign/core/i18n';
312
- import pseudo from '@astryxdesign/core/locales/pseudo.generated.js';
310
+ import pseudo from '@astryxdesign/core/locales/pseudo.json';
313
311
 
314
312
  <InternationalizationProvider locale="pseudo" messages={{pseudo}}>
315
313
  <App />