@astryxdesign/cli 0.7.15-canary.gf890983 → 0.7.15

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 (115) hide show
  1. package/CHANGELOG.md +353 -3
  2. package/api/doctor/_adapter.d.mts +2 -1
  3. package/api/doctor/_adapter.mjs +6 -1
  4. package/api/doctor/doctor.mjs +2 -2
  5. package/api/doctor/theme-checks.mjs +56 -21
  6. package/api/integration/add-helpers.mjs +5 -0
  7. package/api/integration/add-theme.mjs +15 -110
  8. package/api/theme/_adapter.d.mts +37 -5
  9. package/api/theme/_adapter.mjs +363 -50
  10. package/api/theme/_fork.d.mts +90 -0
  11. package/api/theme/_fork.mjs +246 -0
  12. package/api/theme/build/build.d.mts +25 -1
  13. package/api/theme/build/build.mjs +352 -41
  14. package/api/theme/eject/eject.mjs +36 -15
  15. package/api/theme/list/list.mjs +3 -6
  16. package/api/theme/palette/generate/generator.d.mts +13 -0
  17. package/api/theme/palette/generate/generator.mjs +32 -2
  18. package/api/theme/targets/targets.mjs +10 -3
  19. package/api/theme/template/template.mjs +48 -2
  20. package/api/theme/theme.type.d.mts +8 -0
  21. package/api/theme/theme.type.mjs +5 -1
  22. package/api/theme/themeBuild.doc.mjs +2 -2
  23. package/api/theme/themeRemove.doc.mjs +5 -2
  24. package/api/theme/themeTemplate.doc.mjs +2 -2
  25. package/api/theme/themeUse.doc.mjs +8 -2
  26. package/api/theme-edit/_adapter.mjs +157 -36
  27. package/api/theme-edit/_catalog.d.mts +1 -6
  28. package/api/theme-edit/_catalog.mjs +5 -268
  29. package/api/theme-edit/_check.d.mts +3 -1
  30. package/api/theme-edit/_check.mjs +733 -308
  31. package/api/theme-edit/_color.d.mts +19 -0
  32. package/api/theme-edit/_color.mjs +277 -33
  33. package/api/theme-edit/_compiler.d.mts +1 -0
  34. package/api/theme-edit/_compiler.mjs +25 -0
  35. package/api/theme-edit/_context.d.mts +2 -0
  36. package/api/theme-edit/_context.mjs +83 -9
  37. package/api/theme-edit/_css.d.mts +84 -0
  38. package/api/theme-edit/_css.mjs +700 -0
  39. package/api/theme-edit/_edit.mjs +370 -85
  40. package/api/theme-edit/_how-commands.d.mts +5 -0
  41. package/api/theme-edit/_how-commands.mjs +20 -13
  42. package/api/theme-edit/_how-question.d.mts +29 -0
  43. package/api/theme-edit/_how-question.mjs +1573 -182
  44. package/api/theme-edit/_how.mjs +306 -22
  45. package/api/theme-edit/_overview.mjs +2 -7
  46. package/api/theme-edit/_palette.d.mts +27 -5
  47. package/api/theme-edit/_palette.mjs +231 -97
  48. package/api/theme-edit/_parts.d.mts +42 -10
  49. package/api/theme-edit/_parts.mjs +224 -69
  50. package/api/theme-edit/_preview-app.d.mts +8 -0
  51. package/api/theme-edit/_preview-app.mjs +549 -96
  52. package/api/theme-edit/_preview.d.mts +7 -16
  53. package/api/theme-edit/_preview.mjs +77 -84
  54. package/api/theme-edit/_project.d.mts +20 -1
  55. package/api/theme-edit/_project.mjs +43 -13
  56. package/api/theme-edit/_settings.d.mts +96 -20
  57. package/api/theme-edit/_settings.mjs +646 -141
  58. package/api/theme-edit/_tables.d.mts +18 -12
  59. package/api/theme-edit/_tables.mjs +144 -147
  60. package/api/theme-edit/theme-edit.type.d.mts +10 -1
  61. package/api/theme-edit/theme-edit.type.mjs +3 -1
  62. package/api/theme-edit/themeEditNew.doc.mjs +1 -1
  63. package/api/theme-edit/themeEditPreviewAdd.doc.mjs +1 -1
  64. package/api/theme-edit/themeEditPreviewApp.doc.mjs +1 -1
  65. package/api/theme-edit/themeEditPreviewList.doc.mjs +2 -2
  66. package/api/theme-edit/themeEditSet.doc.mjs +1 -1
  67. package/api/theme-edit/themeEditUndo.doc.mjs +1 -1
  68. package/assets/docs/tree/publishing.doc.mjs +1 -0
  69. package/assets/docs.generated.json +2 -2
  70. package/assets/self-audit.generated.json +1 -1
  71. package/clients/cli/build-id.generated.json +1 -1
  72. package/clients/cli/commands/experimental/index.mjs +10 -10
  73. package/clients/cli/commands/experimental/theme.mjs +22 -3
  74. package/clients/cli/commands/experimental-theme-compile.doc.mjs +2 -2
  75. package/clients/cli/commands/experimental-theme-editor-new.doc.mjs +3 -3
  76. package/clients/cli/commands/experimental-theme-preview-add.doc.mjs +1 -1
  77. package/clients/cli/commands/experimental-theme-preview-app.doc.mjs +1 -1
  78. package/clients/cli/commands/integration.mjs +8 -0
  79. package/clients/cli/commands/theme-build.doc.mjs +2 -2
  80. package/clients/cli/commands/theme-list.doc.mjs +1 -1
  81. package/clients/cli/commands/theme-template.doc.mjs +1 -1
  82. package/clients/cli/commands/theme.mjs +325 -48
  83. package/clients/cli/index.mjs +18 -3
  84. package/clients/cli/lib/cli-error.mjs +118 -3
  85. package/clients/cli/manifest.generated.json +1 -1
  86. package/foundation/config/project.mjs +34 -8
  87. package/foundation/config/theme-state.d.mts +16 -0
  88. package/foundation/config/theme-state.mjs +84 -13
  89. package/foundation/discovery/template-needs.d.mts +13 -0
  90. package/foundation/discovery/template-needs.mjs +30 -15
  91. package/foundation/discovery/theme-discovery.mjs +14 -2
  92. package/foundation/discovery/theme-imports.d.mts +16 -0
  93. package/foundation/discovery/theme-imports.mjs +30 -2
  94. package/foundation/doc-compiler/import.mjs +10 -4
  95. package/foundation/fs/gather-cache.mjs +82 -23
  96. package/foundation/fs/jiti-cache.d.mts +21 -0
  97. package/foundation/fs/jiti-cache.mjs +66 -0
  98. package/foundation/fs/module-loader.mjs +7 -2
  99. package/foundation/integrations/autolink.d.mts +1 -24
  100. package/foundation/integrations/autolink.mjs +7 -60
  101. package/foundation/integrations/declared-dependencies.d.mts +27 -0
  102. package/foundation/integrations/declared-dependencies.mjs +73 -0
  103. package/foundation/integrations/may-have-integrations.d.mts +8 -0
  104. package/foundation/integrations/may-have-integrations.mjs +47 -0
  105. package/foundation/release/cache.d.mts +21 -2
  106. package/foundation/release/cache.mjs +48 -8
  107. package/foundation/release/folder-lock.d.mts +7 -0
  108. package/foundation/release/folder-lock.mjs +60 -26
  109. package/foundation/release/lock-lease.d.mts +2 -1
  110. package/foundation/release/lock-lease.mjs +7 -2
  111. package/foundation/response/error-codes.doc.mjs +1 -1
  112. package/foundation/response/response-types.doc.mjs +4 -4
  113. package/package.json +6 -6
  114. package/api/theme-edit/_css-properties.d.mts +0 -10
  115. package/api/theme-edit/_css-properties.mjs +0 -556
@@ -3,6 +3,11 @@
3
3
 
4
4
  /** The command prefix every suggested command starts with. */
5
5
  export const P: "astryx experimental theme editor";
6
+ /**
7
+ * Parts that take their color from a color prop, whose rule Core writes
8
+ * after part styles: a color set on them never shows.
9
+ */
10
+ export const COLOR_PROP_PARTS: string[];
6
11
  /** The lookup command: what a part reads, a setting, a question, a picture. */
7
12
  export const HOW: "astryx experimental theme editor how";
8
13
  /** The built-in themes a theme can build on (`new --like`, `set base`), neutral first. */
@@ -25,26 +30,27 @@ export const CORNERS: Array<[string, number]>;
25
30
  export const SPACING: Array<[string, number]>;
26
31
  /** @type {Array<[string, number]>} */
27
32
  export const TEXT_SIZE: Array<[string, number]>;
33
+ /** The type roles a font may be set for alone (`font <x> --on <role>`). */
34
+ export const FONT_ROLES: string[];
28
35
  /**
29
36
  * Font presets: the family, then its fallbacks.
30
37
  * @type {Record<string, [string, string]>}
31
38
  */
32
39
  export const FONTS: Record<string, [string, string]>;
33
- /**
34
- * Family names that need no font file: CSS generic families and fonts the
35
- * usual desktop systems ship. Lowercase.
36
- */
37
- export const SYSTEM_FAMILIES: Set<string>;
38
- /** CSS-wide keywords: never a family, and invalid inside a list. */
40
+ /** The CSS-wide keywords: valid in any declaration, never a value of their own. */
41
+ export const CSS_WIDE: string[];
42
+ /** CSS-wide keywords, and `default`, which font-family reserves: never a family, and invalid inside a list. */
39
43
  export const CSS_WIDE_KEYWORDS: string[];
40
- /** Presets every desktop system already has, so no font file is needed. */
41
- export const SYSTEM_FONTS: string[];
44
+ export function isSystemFamily(family: string): boolean;
45
+ export function oneSystemOf(family: string): string | null;
46
+ export function isDesktopFamily(family: string): boolean;
42
47
  /**
43
- * Open fonts with a package that loads them: preset -> family, fallbacks,
44
- * and the package. When the package is installed, previews show the font;
45
- * the app loads it by importing the package once.
46
- * @type {Record<string, {family: string, fallbacks: string, pkg: string}>}
48
+ * Presets that show a font every desktop has, so no font file is needed:
49
+ * the family itself, or (for one that ships on one system, such as Segoe
50
+ * UI) the first fallback.
47
51
  */
52
+ export const SYSTEM_FONTS: string[];
53
+ /** @type {Record<string, {family: string, fallbacks: string, pkg: string}>} */
48
54
  export const OPEN_FONTS: Record<string, {
49
55
  family: string;
50
56
  fallbacks: string;
@@ -10,10 +10,17 @@
10
10
  */
11
11
 
12
12
  import {discoverBundledThemes} from '../../foundation/discovery/theme-discovery.mjs';
13
+ import {collectUnloadedFonts} from '../theme/build/font-warning.mjs';
13
14
 
14
15
  /** The command prefix every suggested command starts with. */
15
16
  export const P = 'astryx experimental theme editor';
16
17
 
18
+ /**
19
+ * Parts that take their color from a color prop, whose rule Core writes
20
+ * after part styles: a color set on them never shows.
21
+ */
22
+ export const COLOR_PROP_PARTS = ['text', 'heading', 'link'];
23
+
17
24
  /** The lookup command: what a part reads, a setting, a question, a picture. */
18
25
  export const HOW = `${P} how`;
19
26
 
@@ -99,6 +106,9 @@ export const TEXT_SIZE = [
99
106
  ['larger', 16],
100
107
  ];
101
108
 
109
+ /** The type roles a font may be set for alone (`font <x> --on <role>`). */
110
+ export const FONT_ROLES = ['body', 'heading', 'code'];
111
+
102
112
  /**
103
113
  * Font presets: the family, then its fallbacks.
104
114
  * @type {Record<string, [string, string]>}
@@ -116,163 +126,150 @@ export const FONTS = {
116
126
  rounded: ['Nunito', '"Varela Round", system-ui, sans-serif'],
117
127
  comic: ['Comic Sans MS', '"Comic Neue", cursive'],
118
128
  };
119
- /**
120
- * Family names that need no font file: CSS generic families and fonts the
121
- * usual desktop systems ship. Lowercase.
122
- */
123
- export const SYSTEM_FAMILIES = new Set([
124
- 'serif',
125
- 'sans-serif',
126
- 'monospace',
127
- 'cursive',
128
- 'fantasy',
129
- 'math',
130
- 'emoji',
131
- 'fangsong',
132
- 'system-ui',
133
- 'ui-serif',
134
- 'ui-sans-serif',
135
- 'ui-monospace',
136
- 'ui-rounded',
137
- '-apple-system',
138
- 'blinkmacsystemfont',
139
- 'arial',
140
- 'arial black',
141
- 'helvetica',
142
- 'helvetica neue',
143
- 'segoe ui',
144
- 'tahoma',
145
- 'verdana',
146
- 'trebuchet ms',
147
- 'georgia',
148
- 'times',
149
- 'times new roman',
150
- 'palatino',
151
- 'garamond',
152
- 'courier',
153
- 'courier new',
154
- 'consolas',
155
- 'menlo',
156
- 'monaco',
157
- 'sf mono',
158
- 'sf pro',
159
- 'sf pro text',
160
- 'sf pro display',
161
- 'ubuntu',
162
- 'cantarell',
163
- 'noto sans',
164
- 'liberation sans',
165
- 'dejavu sans',
166
- 'comic sans ms',
167
- 'impact',
168
- ]);
169
-
170
- /** CSS-wide keywords: never a family, and invalid inside a list. */
171
- export const CSS_WIDE_KEYWORDS = [
129
+ /** The CSS-wide keywords: valid in any declaration, never a value of their own. */
130
+ export const CSS_WIDE = [
172
131
  'inherit',
173
132
  'initial',
174
133
  'unset',
175
134
  'revert',
176
135
  'revert-layer',
177
- 'default',
178
136
  ];
179
137
 
180
- /** Presets every desktop system already has, so no font file is needed. */
181
- export const SYSTEM_FONTS = [
182
- 'system',
183
- 'tahoma',
184
- 'verdana',
185
- 'segoe',
186
- 'helvetica',
187
- 'georgia',
188
- 'serif',
189
- 'mono',
190
- 'courier',
191
- ];
138
+ /** CSS-wide keywords, and `default`, which font-family reserves: never a family, and invalid inside a list. */
139
+ export const CSS_WIDE_KEYWORDS = [...CSS_WIDE, 'default'];
192
140
 
193
141
  /**
194
- * Open fonts with a package that loads them: preset -> family, fallbacks,
195
- * and the package. When the package is installed, previews show the font;
196
- * the app loads it by importing the package once.
197
- * @type {Record<string, {family: string, fallbacks: string, pkg: string}>}
142
+ * Whether a family needs no font file somewhere: a CSS generic family, or a
143
+ * family on the theme build's own list of system fonts (the one list; the
144
+ * build's font warning reads it).
145
+ * @param {string} family without quotes
198
146
  */
199
- export const OPEN_FONTS = {
200
- inter: {
201
- family: 'Inter',
202
- fallbacks: 'system-ui, sans-serif',
203
- pkg: '@fontsource/inter',
204
- },
205
- roboto: {
206
- family: 'Roboto',
207
- fallbacks: 'system-ui, sans-serif',
208
- pkg: '@fontsource/roboto',
209
- },
210
- poppins: {
211
- family: 'Poppins',
212
- fallbacks: 'system-ui, sans-serif',
213
- pkg: '@fontsource/poppins',
214
- },
215
- figtree: {
216
- family: 'Figtree',
217
- fallbacks: 'system-ui, sans-serif',
218
- pkg: '@fontsource/figtree',
219
- },
220
- 'dm-sans': {
221
- family: 'DM Sans',
222
- fallbacks: 'system-ui, sans-serif',
223
- pkg: '@fontsource/dm-sans',
224
- },
225
- manrope: {
226
- family: 'Manrope',
227
- fallbacks: 'system-ui, sans-serif',
228
- pkg: '@fontsource/manrope',
229
- },
230
- 'space-grotesk': {
231
- family: 'Space Grotesk',
232
- fallbacks: 'system-ui, sans-serif',
233
- pkg: '@fontsource/space-grotesk',
234
- },
235
- 'ibm-plex-sans': {
236
- family: 'IBM Plex Sans',
237
- fallbacks: 'system-ui, sans-serif',
238
- pkg: '@fontsource/ibm-plex-sans',
239
- },
240
- 'ibm-plex-mono': {
241
- family: 'IBM Plex Mono',
242
- fallbacks: 'ui-monospace, monospace',
243
- pkg: '@fontsource/ibm-plex-mono',
244
- },
245
- 'jetbrains-mono': {
246
- family: 'JetBrains Mono',
247
- fallbacks: 'ui-monospace, monospace',
248
- pkg: '@fontsource/jetbrains-mono',
249
- },
250
- nunito: {
251
- family: 'Nunito',
252
- fallbacks: 'system-ui, sans-serif',
253
- pkg: '@fontsource/nunito',
254
- },
255
- 'source-serif': {
256
- family: 'Source Serif 4',
257
- fallbacks: 'Georgia, serif',
258
- pkg: '@fontsource/source-serif-4',
259
- },
260
- 'mona-sans': {
261
- family: 'Mona Sans',
262
- fallbacks: 'system-ui, sans-serif',
263
- pkg: '@fontsource/mona-sans',
264
- },
265
- geist: {
266
- family: 'Geist Sans',
267
- fallbacks: 'system-ui, sans-serif',
268
- pkg: '@fontsource/geist-sans',
269
- },
270
- 'geist-mono': {
271
- family: 'Geist Mono',
272
- fallbacks: 'ui-monospace, monospace',
273
- pkg: '@fontsource/geist-mono',
274
- },
147
+ export const isSystemFamily = family =>
148
+ family.trim() !== '' &&
149
+ collectUnloadedFonts({
150
+ tokens: {'--font-family-body': JSON.stringify(family.trim())},
151
+ }).length === 0;
152
+
153
+ /**
154
+ * The families on that list that only one system ships, with that system:
155
+ * fallback stacks name them on purpose, but as a theme's own font they do
156
+ * not load everywhere.
157
+ */
158
+ const ONE_SYSTEM_FAMILIES = new Map(
159
+ Object.entries({
160
+ macOS: [
161
+ '-apple-system',
162
+ 'blinkmacsystemfont',
163
+ 'helvetica neue',
164
+ 'sf mono',
165
+ 'sf pro',
166
+ 'sf pro text',
167
+ 'sf pro display',
168
+ 'monaco',
169
+ 'menlo',
170
+ 'palatino',
171
+ 'lucida grande',
172
+ 'gill sans',
173
+ 'snell roundhand',
174
+ ],
175
+ Windows: [
176
+ 'segoe ui',
177
+ 'segoe ui emoji',
178
+ 'segoe ui symbol',
179
+ 'consolas',
180
+ 'cambria',
181
+ 'calibri',
182
+ 'lucida console',
183
+ 'brush script mt',
184
+ 'old english text mt',
185
+ ],
186
+ 'Android and ChromeOS': ['roboto'],
187
+ Linux: [
188
+ 'liberation mono',
189
+ 'liberation sans',
190
+ 'liberation serif',
191
+ 'dejavu sans',
192
+ 'dejavu sans mono',
193
+ ],
194
+ }).flatMap(([system, names]) => names.map(n => [n, system])),
195
+ );
196
+
197
+ /** @param {string} family */
198
+ const familyKey = family => family.trim().replace(/\s+/g, ' ').toLowerCase();
199
+
200
+ /**
201
+ * The one system that ships a family on the theme build's list, or null for
202
+ * a family every desktop has (or none does).
203
+ * @param {string} family without quotes
204
+ */
205
+ export const oneSystemOf = family =>
206
+ isSystemFamily(family)
207
+ ? (ONE_SYSTEM_FAMILIES.get(familyKey(family)) ?? null)
208
+ : null;
209
+
210
+ /**
211
+ * Whether a family loads with no font file on every usual desktop: a CSS
212
+ * generic, or a system family macOS and Windows both ship.
213
+ * @param {string} family without quotes
214
+ */
215
+ export const isDesktopFamily = family =>
216
+ isSystemFamily(family) && !ONE_SYSTEM_FAMILIES.has(familyKey(family));
217
+
218
+ /**
219
+ * Presets that show a font every desktop has, so no font file is needed:
220
+ * the family itself, or (for one that ships on one system, such as Segoe
221
+ * UI) the first fallback.
222
+ */
223
+ export const SYSTEM_FONTS = Object.keys(FONTS).filter(k =>
224
+ [FONTS[k][0], FONTS[k][1].split(',')[0].replace(/["']/g, '')].some(
225
+ isDesktopFamily,
226
+ ),
227
+ );
228
+
229
+ /**
230
+ * Open fonts with a package that loads them: preset -> family. The package
231
+ * is `@fontsource/<preset>` and the fallbacks follow the kind of font
232
+ * (`-mono`, serif, sans), except where OPEN_FONT_PACKAGES says otherwise.
233
+ * When the package is installed, previews show the font; the app loads it
234
+ * by importing the package once.
235
+ */
236
+ const OPEN_FONT_FAMILIES = {
237
+ inter: 'Inter',
238
+ roboto: 'Roboto',
239
+ poppins: 'Poppins',
240
+ figtree: 'Figtree',
241
+ 'dm-sans': 'DM Sans',
242
+ manrope: 'Manrope',
243
+ 'space-grotesk': 'Space Grotesk',
244
+ 'ibm-plex-sans': 'IBM Plex Sans',
245
+ 'ibm-plex-mono': 'IBM Plex Mono',
246
+ 'jetbrains-mono': 'JetBrains Mono',
247
+ nunito: 'Nunito',
248
+ 'source-serif': 'Source Serif 4',
249
+ 'mona-sans': 'Mona Sans',
250
+ geist: 'Geist Sans',
251
+ 'geist-mono': 'Geist Mono',
275
252
  };
253
+ /** Presets whose package is not named after them. */
254
+ const OPEN_FONT_PACKAGES = /** @type {Record<string, string>} */ ({
255
+ 'source-serif': 'source-serif-4',
256
+ geist: 'geist-sans',
257
+ });
258
+ /** @type {Record<string, {family: string, fallbacks: string, pkg: string}>} */
259
+ export const OPEN_FONTS = Object.fromEntries(
260
+ Object.entries(OPEN_FONT_FAMILIES).map(([key, family]) => [
261
+ key,
262
+ {
263
+ family,
264
+ fallbacks: key.endsWith('-mono')
265
+ ? 'ui-monospace, monospace'
266
+ : /serif/i.test(family)
267
+ ? 'Georgia, serif'
268
+ : 'system-ui, sans-serif',
269
+ pkg: `@fontsource/${OPEN_FONT_PACKAGES[key] ?? key}`,
270
+ },
271
+ ]),
272
+ );
276
273
 
277
274
  /**
278
275
  * Brand fonts no package loads, and the closest open font, for the warning
@@ -382,7 +379,7 @@ export const DIALS = {
382
379
  CORNERS.map(
383
380
  ([n, v]) => `${n} (${v === 9999 ? 'fully round' : `${v}px`})`,
384
381
  ).join(', ') +
385
- ", or a size like 6px. Whole theme: sets the 4 corner tokens in fixed ratios. With --on <part or group>: that part's border-radius. Corners are a size, so they are the same in light and dark.",
382
+ ", or a size like 6px. Whole theme: sets the 4 corner tokens in the base theme's proportions (containers and pages at most as round as at pill; inner corners at most as round as at round). With --on <part or group>: that part's border-radius. Corners are a size, so they are the same in light and dark.",
386
383
  values: 'square|small|medium|large|round|pill|more|less|<size like 6px>',
387
384
  examples: [
388
385
  'set my corners pill',
@@ -114,6 +114,10 @@ export type ThemeEditPreviewFields = {
114
114
  code: string;
115
115
  cause: string;
116
116
  } | null;
117
+ /**
118
+ * - Set when sheet.html (the sheet of every component, made by `show`) shows the theme as it was before this change: it says so at its top until `show` makes it again.
119
+ */
120
+ sheetStale?: string | undefined;
117
121
  /**
118
122
  * - Files of the in-app theme preview that were not written again and still show the theme as it was: changed by hand, or a preview folder where a stopped preview change waits for the next preview command.
119
123
  */
@@ -226,6 +230,10 @@ export type ThemeEditChangeData = {
226
230
  * - In-app preview files changed by hand: see ThemeEditPreviewFields.
227
231
  */
228
232
  previewStale?: string[] | undefined;
233
+ /**
234
+ * - Set when sheet.html shows the theme as it was before this change: see ThemeEditPreviewFields.
235
+ */
236
+ sheetStale?: string | undefined;
229
237
  };
230
238
  export type ThemeEditShowOptions = {
231
239
  /**
@@ -433,11 +441,12 @@ export type ThemeEditPreviewListOptions = {
433
441
  export type ThemeEditPreviewListResponse = {
434
442
  type: "themeEdit.previewList";
435
443
  /**
436
- * - `notes`: what else to know, such as a theme the preview wears that is gone.
444
+ * - `themeMissing`: the theme the preview wears is gone, so its route does not build; `notes`: what else to know, such as the command that switches it.
437
445
  */
438
446
  data: {
439
447
  folder: string | null;
440
448
  theme: string | null;
449
+ themeMissing: boolean;
441
450
  pages: Array<{
442
451
  id: string;
443
452
  label: string;
@@ -51,6 +51,7 @@
51
51
  * @property {string[]} pictures - PNG pictures taken (only with `png`).
52
52
  * @property {string | null} pictureProblem - Why no picture was taken, and how to get a browser for it.
53
53
  * @property {{code: string, cause: string} | null} notChecked - Set when the change is saved but the components could not be rendered, so it was not checked and has no preview: the cause, such as two copies of React.
54
+ * @property {string} [sheetStale] - Set when sheet.html (the sheet of every component, made by `show`) shows the theme as it was before this change: it says so at its top until `show` makes it again.
54
55
  * @property {string[]} [previewStale] - Files of the in-app theme preview that were not written again and still show the theme as it was: changed by hand, or a preview folder where a stopped preview change waits for the next preview command.
55
56
  */
56
57
 
@@ -95,6 +96,7 @@
95
96
  * @property {string | null} pictureProblem
96
97
  * @property {{code: string, cause: string} | null} notChecked - Saved but not checked: see ThemeEditPreviewFields.
97
98
  * @property {string[]} [previewStale] - In-app preview files changed by hand: see ThemeEditPreviewFields.
99
+ * @property {string} [sheetStale] - Set when sheet.html shows the theme as it was before this change: see ThemeEditPreviewFields.
98
100
  */
99
101
 
100
102
  /**
@@ -225,7 +227,7 @@
225
227
  * @experimental May change or be removed in a patch release.
226
228
  * @typedef {object} ThemeEditPreviewListResponse
227
229
  * @property {'themeEdit.previewList'} type
228
- * @property {{folder: string | null, theme: string | null, pages: Array<{id: string, label: string}>, notes: string[]}} data - `notes`: what else to know, such as a theme the preview wears that is gone.
230
+ * @property {{folder: string | null, theme: string | null, themeMissing: boolean, pages: Array<{id: string, label: string}>, notes: string[]}} data - `themeMissing`: the theme the preview wears is gone, so its route does not build; `notes`: what else to know, such as the command that switches it.
229
231
  */
230
232
 
231
233
  /**
@@ -27,7 +27,7 @@ export const doc = {
27
27
  name: 'theme',
28
28
  type: 'string',
29
29
  description:
30
- 'The theme name: lowercase letters, digits and dashes, starting with a letter, 64 characters at most.',
30
+ 'The theme name: lowercase letters, digits and dashes, starting with a letter, 64 characters at most, not a name Windows reserves (con, prn, aux, nul, com1-com9, lpt1-lpt9).',
31
31
  required: true,
32
32
  },
33
33
  {
@@ -13,7 +13,7 @@ export const doc = {
13
13
  summary:
14
14
  'Add pages to the theme preview in the app: the default pages, the best template pages for a description, or one template.',
15
15
  description:
16
- "Writes the theme preview into the app: one route, a normal page of the app that keeps its layout, global CSS and providers, in an app shell with a side nav item per preview page and a top bar with the theme name and, when it wears a theme made by `editor`, a light, dark and system switch. A description (\"a sales dashboard\") asks the same page ranking `build` uses for the template pages that fit it best (`top` of them, default 1), and adds each as a page, saying in `matched` what it picked and why (the words of the description it covers). App frames (the Shell templates) are left out, since the preview is an app shell already. When no page is exactly the one described, the closest is added and `matched` says the rest of the description is not on it; only a description no page relates to is refused, writing nothing and naming the closest pages to add with `template`, with the other options repeated. A page the app cannot show (a missing package, or StyleX without a compiler) is skipped and the next match is taken (from the ranking, then the template search), and the result says so. A page's nav label is its template's display name, however it was added; `template` names one page template instead; with neither, it adds the default pages: Overview (the theme at a glance, built to show what themes most often break: long and short text, every text level on every surface, every button variant and size with disabled and loading, inputs in their states, selected navigation, status colors, a table, open layers), Components (every component grouped, each with the command that changes it most) and, when the theme sets a color, Colors (each color's shades in light and dark, with the shade number, the hex and the tokens that use each; it reads the theme's generated colors, so it changes with every `editor set`). The route goes in theme-preview/ in the app's routes folder (app/ or src/app/), or in `path`; the first add records the pages and the files it wrote in theme-preview.json beside the route, so later calls find it. With no routes folder and no `path`, it refuses and names both ways on: `path`, or `themeEditPreviewApp`, which makes a new starter app with the preview in it. The route fills the whole window with the theme, shell and edges included. Every check (the theme, the template, the ranking and every file it writes) runs before the first write, so a refusal changes nothing. A template page that imports a package the app lacks, or that uses StyleX in an app with no StyleX compiler, is not added: the result lists it in `skipped`, with the command that installs what it needs. A file the preview did not write is never replaced. The pages wear `theme` (default: the only theme under themes/; with none or several, the app's own theme). The pages go in _pages/ beside the route, a folder Next never serves as a route; a preview an older release wrote into pages/ is moved there. theme-preview.json records a hash of each file the preview writes: a file changed by hand since is never replaced (the refusal names it), and a page file that already holds exactly the planned text is taken over. The files are staged and renamed into place together; when a write fails, every file is put back as it was. A damaged theme-preview.json is refused with `ERR_THEME_INVALID`, naming the file. The folder is refused when it is a file, in themes/ or node_modules/, in a Pages Router folder (pages/ or src/pages/), in a folder Next does not route (_private, @slot, [param]), or written with Windows separators, a leading ~ or white space at either end. With no `path` and no preview in the default place, a preview recorded for a theme is used; with several, the refusal names each. A theme the preview wore that is gone is replaced by the app's own theme, with a note; a changed theme writes the default pages again. A template page whose package the app's package.json names but nobody installed is skipped like a missing one. Only the first 40 different words of a long description go to the ranking, with a note. The project root, src/ and the routes folder itself are refused too: they hold the app. An older preview found there is named, with the remove that clears it. A recorded page whose file is gone is written again (a default page, or the template its id names), or else left out of the nav, with a note. A formatter run (white space, quotes, semicolons, commas) does not count as a change by hand. Refusals never suggest deleting files: they say what to move or rename. Preview commands in one project run one after another. The folder is also refused when it holds a package.json, when another page of the app already serves its URL (a route group or the Pages Router), when next.config sets pageExtensions without tsx, when it is in src/app/ while app/ is what Next serves, and when no root layout is above it (an app with its root layout in [locale]/ gets its preview there, opened at /<locale>/theme-preview; an app with a root layout in each route group takes the preview under any of them). A template's needs come from its real import statements, never words in comments or strings; a package the app does not name gets the command that adds it. A theme with no build is built only after every check passed, holding that theme's lock, with a note. An edit inside a string counts as a change by hand; a formatter run does not. Experimental: it may change or be removed in a patch release.",
16
+ "Writes the theme preview into the app: one route, a normal page of the app that keeps its layout, global CSS and providers, in an app shell with a side nav item per preview page and a top bar with the theme name and, when it wears a theme made by `editor`, a light, dark and system switch. A description (\"a sales dashboard\") asks the same page ranking `build` uses for the template pages that fit it best (`top` of them, default 1), and adds each as a page, saying in `matched` what it picked and why (the words of the description it covers). App frames (the Shell templates) are left out, since the preview is an app shell already. When no page is exactly the one described, the closest is added and `matched` says the rest of the description is not on it; only a description no page relates to is refused, writing nothing and naming the closest pages to add with `template`, with the other options repeated. A page the app cannot show (a missing package, or StyleX without a compiler) is skipped and the next match is taken (from the ranking, then the template search), and the result says so. A page's nav label is its template's display name, however it was added; `template` names one page template instead; with neither, it adds the default pages: Overview (the theme at a glance, built to show what themes most often break: long and short text, every text level on every surface, every button variant and size with disabled and loading, inputs in their states, selected navigation, status colors, a table, open layers), Components (every component grouped, each with the command that changes it most) and, when the theme sets a color, Colors (each color's shades in light and dark, with the shade number, the hex and the tokens that use each; it reads the theme's generated colors, so it changes with every `editor set`). The route goes in theme-preview/ in the app's routes folder (app/ or src/app/), or in `path`; the first add records the pages and the files it wrote in theme-preview.json beside the route, so later calls find it. With no routes folder and no `path`, it refuses and names both ways on: `path`, or `themeEditPreviewApp`, which makes a new starter app with the preview in it. The route fills the whole window with the theme, shell and edges included. Every check (the theme, the template, the ranking and every file it writes) runs before the first write, so a refusal changes nothing. A template page that imports a package the app lacks, or that uses StyleX in an app with no StyleX compiler, is not added: the result lists it in `skipped`, with the command that installs what it needs. A file the preview did not write is never replaced. The pages wear `theme` (default: the only theme under themes/; with none or several, the app's own theme). The pages go in _pages/ beside the route, a folder Next never serves as a route; a preview an older release wrote into pages/ is moved there. theme-preview.json records a hash of each file the preview writes: a file changed by hand since is never replaced (the refusal names it), and a page file that already holds exactly the planned text is taken over. The files are staged and renamed into place together; when a write fails, every file is put back as it was. A damaged theme-preview.json is refused with `ERR_THEME_INVALID`, naming the file. The folder is refused when it is a file, in themes/, node_modules/ or Next's build folder (.next/, out/ or the distDir next.config names), in a Pages Router folder (pages/ or src/pages/), in a folder Next does not route (_private, @slot, [param]), or written with Windows separators, a leading ~ or white space at either end. With no `path` and no preview in the default place, a preview recorded for a theme is used; with several, the refusal names each. A theme the preview wore that is gone is replaced by the app's own theme, with a note; a changed theme writes the default pages again. A template page whose package the app's package.json names but nobody installed is skipped like a missing one. Only the first 40 different words of a long description go to the ranking, with a note. The project root, src/ and the routes folder itself are refused too: they hold the app. An older preview found there is named, with the remove that clears it. A recorded page whose file is gone is written again (a default page, or the template its id names), or else left out of the nav, with a note. A formatter run (white space, quotes, semicolons, commas) does not count as a change by hand. Refusals never suggest deleting files: they say what to move or rename. Preview commands in one project run one after another. The folder is also refused when it holds a package.json, when another page or route handler of the app already serves its URL (in the folder itself, a route group or the Pages Router), when next.config sets pageExtensions without tsx, when it is in src/app/ while app/ is what Next serves, and when no root layout is above it (an app with its root layout in [locale]/ gets its preview there, opened at /<locale>/theme-preview; an app with a root layout in each route group takes the preview under any of them). A template's needs come from its real import statements, never words in comments or strings; a package the app does not name gets the command that adds it. A theme with no build is built only after every check passed, holding that theme's lock, with a note. An edit inside a string counts as a change by hand; a formatter run does not. Experimental: it may change or be removed in a patch release.",
17
17
  importPath: '@astryxdesign/cli/api/experimental',
18
18
  signature:
19
19
  'themeEditPreviewAdd(description?: string, options?: object): Promise<object>',
@@ -12,7 +12,7 @@ export const doc = {
12
12
  displayName: 'themeEditPreviewApp()',
13
13
  summary: 'Make a new starter app with the theme preview inside.',
14
14
  description:
15
- "Writes a new starter app into `dir` (Next.js app router, Core and the neutral theme, with the Astryx packages pinned to this CLI's release), with the theme preview route and its default pages (the sample app page and every component grouped) in src/app/theme-preview/. With `theme`, the theme folder is copied into the app's themes/ and the pages wear it; a base theme or font package it needs is added to package.json. No install runs: the result says how to install, run and open it. `dir` must be new or empty, inside the current folder; a folder that is not empty is refused, with a free folder name to use instead. Every check runs before the first write, so a refusal changes nothing. Every open font the theme names is added to package.json, at the version this project has or a pinned range, and the route imports it; a theme with generated colors gets the Colors page too, and a one-mode theme starts the route in its mode. The app is written into a temp folder beside the folder and moved into place, so a failure leaves nothing behind. A folder holding only .git, .DS_Store or Thumbs.db counts as empty. The folder is refused when it is a file, a dangling link, inside this app's routes folder, themes/ or node_modules/, or written with Windows separators, white space at either end or a name too long. A theme whose build is missing or older than its settings is built first, with a note. The app's home page links to the preview, and its .gitignore leaves out node_modules, next-env.d.ts and *.tsbuildinfo. Inside a project with a tsconfig.json, a note says to exclude the new folder. With a theme, it holds that theme's lock while it builds and copies it, so an `editor set` on the same theme waits for it. A folder given from a subfolder of the project is taken from where it was given. An app is refused in public/ (served as files at the site root) and under a name Windows does not allow; a base theme passed to --theme is named as a package theme, installed or not, with the command that adds it. Experimental: it may change or be removed in a patch release.",
15
+ "Writes a new starter app into `dir` (Next.js app router, Core and the neutral theme, with the Astryx packages pinned to this CLI's release), with the theme preview route and its default pages (the sample app page and every component grouped) in src/app/theme-preview/. With `theme`, the theme folder is copied into the app's themes/ and the pages wear it; a base theme or font package it needs is added to package.json. No install runs: the result says how to install, run and open it. `dir` must be new or empty, inside the current folder; a folder that is not empty is refused, with a free folder name to use instead. Every check runs before the first write, so a refusal changes nothing. Every open font the theme names is added to package.json, at the version this project has or a pinned range, and the route imports it; a theme with generated colors gets the Colors page too, and a one-mode theme starts the route in its mode. The app is written into a temp folder beside the folder and moved into place, so a failure leaves nothing behind. A folder holding only .git, .DS_Store or Thumbs.db counts as empty. The folder is refused when it is a file, a dangling link, inside this app's routes folder, themes/, node_modules/ or Next's build folder (.next/, out/ or the distDir next.config names), or written with Windows separators, white space at either end or a name too long. A theme whose build is missing or older than its settings is built first, with a note. The app's home page links to the preview, and its .gitignore leaves out node_modules, next-env.d.ts and *.tsbuildinfo. Inside a project with a tsconfig.json, a note says to exclude the new folder. With a theme, it holds that theme's lock while it builds and copies it, so an `editor set` on the same theme waits for it. A folder given from a subfolder of the project is taken from where it was given. An app is refused in public/ (served as files at the site root) and under a name Windows does not allow; a base theme passed to --theme is named as a package theme, installed or not, with the command that adds it. Experimental: it may change or be removed in a patch release.",
16
16
  importPath: '@astryxdesign/cli/api/experimental',
17
17
  signature:
18
18
  'themeEditPreviewApp(dir: string, options?: object): Promise<object>',
@@ -12,7 +12,7 @@ export const doc = {
12
12
  displayName: 'themeEditPreviewList()',
13
13
  summary: 'The pages of the theme preview in the app.',
14
14
  description:
15
- 'Lists the pages of the theme preview, in nav order, with the theme they wear and the route folder. With no preview, and with no routes folder (app/ or src/app/) for one, the list is empty. A damaged theme-preview.json is refused with `ERR_THEME_INVALID`, naming the file. With no folder given and no preview in the default place, a preview recorded for a theme is listed; with several, the refusal names each. `notes` says when the theme the preview wears is gone. Experimental: it may change or be removed in a patch release.',
15
+ 'Lists the pages of the theme preview, in nav order, with the theme they wear and the route folder. With no preview, and with no routes folder (app/ or src/app/) for one, the list is empty. A damaged theme-preview.json is refused with `ERR_THEME_INVALID`, naming the file. With no folder given and no preview in the default place, a preview recorded for a theme is listed; with several, the refusal names each. When the theme the preview wears is gone, `themeMissing` is true and `notes` names the command that switches it. Experimental: it may change or be removed in a patch release.',
16
16
  importPath: '@astryxdesign/cli/api/experimental',
17
17
  signature: 'themeEditPreviewList(options?: object): Promise<object>',
18
18
  keywords: ['theme', 'experimental theme', 'preview', 'theme preview'],
@@ -34,7 +34,7 @@ export const doc = {
34
34
  {
35
35
  type: 'themeEdit.previewList',
36
36
  description:
37
- 'The route folder (null with no preview), the theme, and the pages.',
37
+ 'The route folder (null with no preview), the theme, whether that theme is gone (`themeMissing`), the pages and notes.',
38
38
  },
39
39
  ],
40
40
  throws: [
@@ -13,7 +13,7 @@ export const doc = {
13
13
  summary:
14
14
  'Change one thing in a theme: checked against what the components read, built, previewed.',
15
15
  description:
16
- "Changes one thing. The thing is a dial (corners, spacing, accent, neutral, success, warning, danger, info, vibrancy, font, headings, surfaces, buttons, type, text-size, base, mode: big moves with named rungs; `more`/`less` step a rung), a design token by name (--color-background-body; `how --list tokens`), or a CSS property on a part (background --on card; needs --on). Every change is CHECKED first against the installed Core: the part, the --when variant and value, the --state, the token's type (color, size, number, font, shadow; only colors may differ by mode; a shadow is one value for both), and whether the part, or a part inside it, actually reads the token for what you mean. A change that cannot take effect is REFUSED: exit 1, an error code, nothing written, and the suggestions lead with the command that works (the token the part really reads, or the property that sets it directly). Groups: --on <group> (inputs, checks, containers, menus) styles every member; styling one member of an always-alike group (inputs, checks) styles the whole group unless --only. A setting on a part beats a whole-theme dial, and a dial never overwrites one. After building, a plain part setting that a more specific base-theme rule would beat (such as a heading level) is repeated on those variant keys, and the result says so. The result lists resolved token changes, part styles written, contrast problems this theme caused versus its base (text below 4.5:1), notes (the shade a color's main token uses, any shade moved so text reads, and the generated color files; font loading: the exact install line when the font package is missing), and writes themes/<theme>/preview.html. Values with spaces go in quotes: gradients, several shadows, font stacks. Dials: corners square|small|medium|large|round|pill|more|less|<size>; spacing tight|compact|medium|roomy|spacious|more|less; accent, neutral, success, warning, danger, info <color> (a color: the editor generates its light and dark shades from the one color, with the same generator as `theme palette generate`, and points the color tokens at them; a token moves to a nearby shade when it must read: text at 4.5:1, the focus ring at 3:1; the whole theme only, no --on or --mode; `how colors` explains it and the Colors preview page shows every shade); vibrancy 0-100|more|less (how saturated the generated colors are; 50 is the default; needs a color); font <preset, open font, family or stack>; headings light|regular|medium|semibold|bold|heavy or tight|tighter|normal|wide; surfaces flat|outlined|raised|glass; buttons solid|outline|soft|caps; type compact|standard|editorial|display; text-size small|medium|large|larger|more|less|<number of pixels, 10 to 32>; base <built-in theme>|none; mode both|light-only|dark-only. `astryx experimental theme editor how --list dials` explains each. An exact token always wins over the generated colors: `set <theme> --color-accent <color>` (with --on or --mode if you need them) is the escape hatch, whatever order the settings were made in. Experimental: it may change or be removed in a patch release.",
16
+ "Changes one thing. The thing is a dial (corners, spacing, accent, neutral, success, warning, danger, info, vibrancy, font, headings, surfaces, buttons, type, text-size, base, mode: big moves with named rungs; `more`/`less` step a rung), a design token by name (--color-background-body; `how --list tokens`), or a CSS property on a part (background --on card; needs --on). Every change is CHECKED first against the installed Core: the part, the --when variant and value, the --state, the token's type (color, size, number, font, shadow; only colors may differ by mode; a shadow is one value for both), and whether the part, or a part inside it, actually reads the token for what you mean. A change that cannot take effect is REFUSED: exit 1, an error code, nothing written, and the suggestions lead with the command that works (the token the part really reads, or the property that sets it directly). Groups: --on <group> (inputs, checks, containers, menus) styles every member; styling one member of an always-alike group (inputs, checks) styles the whole group unless --only. A setting on a part beats a whole-theme dial, and a dial never overwrites one. After building, a plain part setting that a more specific base-theme rule would beat (such as a heading level) is repeated on those variant keys, and the result says so. The result lists resolved token changes, part styles written, contrast problems this theme caused versus its base (text below 4.5:1), notes (the shade a color's main token uses, any shade moved so text reads, and the generated color files; font loading: the exact install line when the font package is missing), and writes themes/<theme>/preview.html; when sheet.html (made by `show`) now shows the theme as it was, it says so at its top and the result's sheetStale says so. Values with spaces go in quotes: gradients, several shadows, font stacks. Dials: corners square|small|medium|large|round|pill|more|less|<size>; spacing tight|compact|medium|roomy|spacious|more|less; accent, neutral, success, warning, danger, info <color> (a color: the editor generates its light and dark shades from the one color, with the same generator as `theme palette generate`, and points the color tokens at them; a token moves to a nearby shade when it must read: text at 4.5:1, the focus ring at 3:1; the whole theme only, no --on or --mode; `how colors` explains it and the Colors preview page shows every shade); vibrancy 0-100|more|less (how saturated the generated colors are; 50 is the default; needs a color); font <preset, open font, family or stack>; headings light|regular|medium|semibold|bold|heavy or tight|tighter|normal|wide; surfaces flat|outlined|raised|glass; buttons solid|outline|soft|caps; type compact|standard|editorial|display; text-size small|medium|large|larger|more|less|<number of pixels, 10 to 32>; base <built-in theme>|none; mode both|light-only|dark-only. `astryx experimental theme editor how --list dials` explains each. An exact token always wins over the generated colors: `set <theme> --color-accent <color>` (with --on or --mode if you need them) is the escape hatch, whatever order the settings were made in. Experimental: it may change or be removed in a patch release.",
17
17
  importPath: '@astryxdesign/cli/api/experimental',
18
18
  signature:
19
19
  'themeEditSet(theme: string, thing: string, value: string, options?: object): Promise<object>',
@@ -13,7 +13,7 @@ export const doc = {
13
13
  summary:
14
14
  'Put the theme back as it was before its last change, or remove one setting.',
15
15
  description:
16
- 'With only the theme, it steps back one change: the settings, the generated settings module and the build go back to how they were before the last change (your <theme>.theme.ts is not touched), and the preview is rewritten; the result names what was undone and how many earlier steps are left. When the settings file is damaged (not valid JSON), the step back restores the settings from before the last change without reading it. With `thing`, it removes that one setting instead, wherever it is in the settings, and the `now` field of the result says what applies instead (a dial that still writes it, a whole-theme setting of the same thing, or the value of the base theme); name it the way it was set, with the same `on`, `when`, `state`, `mode` and `only`. Removing a color (accent, neutral, success, warning, danger, info) stops generating it, and the tokens it fed go back to the base theme; with no color left, the generated color files the editor wrote are deleted; a palette.config.json you made, or one that holds a color of your own, stays. Removing vibrancy makes the colors again at the default, 50; removing the last color removes vibrancy too, as it needs a color. `undo <theme> base` and `undo <theme> mode` go back to the base and mode the theme was made with; when they never changed, that is refused. The history keeps the last 80 steps (in <theme>.history.json); older steps are dropped. Experimental: it may change or be removed in a patch release.',
16
+ 'With only the theme, it steps back one change: the settings, the generated settings module and the build go back to how they were before the last change (your <theme>.theme.ts is not touched), and the preview is rewritten; the result names what was undone and how many earlier steps are left. When the settings file is damaged (not valid JSON), the step back restores the settings from before the last change without reading it. With `thing`, it removes that one setting instead, wherever it is in the settings, and the `now` field of the result says what applies instead (a dial that still writes it, a whole-theme setting of the same thing, or the value of the base theme); name it the way it was set, with the same `on`, `when`, `state`, `mode` and `only`. Removing a color (accent, neutral, success, warning, danger, info) stops generating it, and the tokens it fed go back to the base theme; with no color left, the generated color files the editor wrote are deleted; a palette.config.json you made, or one that holds a color of your own, stays. Removing vibrancy makes the colors again at the default, 50; removing the last color removes vibrancy too, as it needs a color. `undo <theme> base` and `undo <theme> mode` go back to the base and mode the theme was made with; when they never changed, that is refused. The history keeps the last 80 steps (in <theme>.history.json); older steps are dropped. Each step also restores the corner radii it was built with. Like `set`, sheetStale in the result says when sheet.html shows the theme as it was. Experimental: it may change or be removed in a patch release.',
17
17
  importPath: '@astryxdesign/cli/api/experimental',
18
18
  signature: 'themeEditUndo(theme: string, options?: object): Promise<object>',
19
19
  keywords: [
@@ -59,6 +59,7 @@ export const docs = {
59
59
  items: [
60
60
  'List only the roots you ship, and always `astryx.integration.mjs`. npm adds package.json, and a README and LICENSE when you have them.',
61
61
  'Each later `integration add` appends its root to the list.',
62
+ 'Ship `astryx.integration.mjs`, not `.ts`: the CLI transpiles each `.ts` file it loads on first read per machine, so `.mjs` starts faster. Ship one manifest only; two fail to load. The same holds for doc files and codemods: ship `.mjs`.',
62
63
  '`integration verify` fails when a root is missing from the list, and names the root to add to `files` (the message is in {@link generic:troubleshooting}).',
63
64
  ],
64
65
  },