@contentful/experience-design-system-cli 2.35.0-alpha.0 → 2.35.1-dev-build-041b6e0a.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (301) hide show
  1. package/bin/cli.js +1 -57
  2. package/dist/app.d.ts +9 -0
  3. package/dist/app.js +997 -0
  4. package/dist/index.js +1216 -0
  5. package/dist/package.json +11 -15
  6. package/dist/program.d.ts +2 -0
  7. package/dist/src/legacy/legacy-cli-path.d.ts +1 -0
  8. package/dist/src/legacy/run-legacy.d.ts +1 -0
  9. package/dist/src/tui/debug-store.d.ts +14 -0
  10. package/dist/src/tui/help/PageContainer.d.ts +4 -0
  11. package/dist/src/tui/home/home.d.ts +5 -0
  12. package/dist/src/tui/home/home.theme.d.ts +14 -0
  13. package/dist/src/tui/import/PageContainer.d.ts +5 -0
  14. package/dist/src/tui/import/spawn-v1-import.d.ts +28 -0
  15. package/dist/src/tui/import/terminal-input.d.ts +2 -0
  16. package/dist/src/tui/package-root.d.ts +9 -0
  17. package/dist/src/tui/settings/PageContainer.d.ts +6 -0
  18. package/dist/src/tui/settings/contentful-configuration/ContentfulConfigScreen.d.ts +4 -0
  19. package/dist/src/tui/settings/contentful-configuration/config-store.d.ts +9 -0
  20. package/dist/src/tui/settings/debug-mode/debug-mode-store.d.ts +5 -0
  21. package/dist/src/tui/settings/debug-mode/screen.d.ts +4 -0
  22. package/dist/src/tui/settings/opt-in-analytics/analytics-store.d.ts +5 -0
  23. package/dist/src/tui/settings/opt-in-analytics/screen.d.ts +4 -0
  24. package/dist/src/tui/settings/utils/v1-store.d.ts +2 -0
  25. package/dist/src/tui/upgrade/PageContainer.d.ts +4 -0
  26. package/dist/src/tui/upgrade/version.d.ts +12 -0
  27. package/dist/src/tui/use-terminal-width.d.ts +1 -0
  28. package/legacy/bin/cli.js +58 -0
  29. package/legacy/dist/package.json +73 -0
  30. package/legacy/dist/src/analyze/composition/interchange-schema.d.ts +17 -0
  31. package/legacy/dist/src/analyze/composition/resolve-mapping-cli.d.ts +10 -0
  32. package/{dist → legacy/dist}/src/analyze/composition/resolve-mapping.d.ts +5 -7
  33. package/{dist → legacy/dist}/src/analyze/extract-command.d.ts +4 -0
  34. package/{dist → legacy/dist}/src/analyze/select/tui/components/FieldEditor.d.ts +3 -1
  35. package/{dist → legacy/dist}/src/analyze/select/tui/components/FinalizeDialog.d.ts +2 -2
  36. package/{dist → legacy/dist}/src/analyze/select/tui/components/GroupedSidebar.d.ts +3 -0
  37. package/{dist → legacy/dist}/src/analyze/select/tui/components/HelpOverlay.d.ts +2 -0
  38. package/{dist → legacy/dist}/src/analyze/select/tui/components/Sidebar.d.ts +2 -1
  39. package/{dist → legacy/dist}/src/analyze/select/tui/hooks/scroll-offset.d.ts +4 -3
  40. package/{dist → legacy/dist}/src/analyze/select/tui/hooks/useImmediateInput.d.ts +1 -1
  41. package/legacy/dist/src/credentials-store.d.ts +18 -0
  42. package/legacy/dist/src/doctor/checks.d.ts +5 -0
  43. package/legacy/dist/src/doctor/command.d.ts +2 -0
  44. package/legacy/dist/src/doctor/report.d.ts +7 -0
  45. package/{dist → legacy/dist}/src/import/agent-model-resolve.d.ts +8 -4
  46. package/{dist → legacy/dist}/src/import/composition-options.d.ts +0 -2
  47. package/{dist → legacy/dist}/src/import/tui/WizardApp.d.ts +21 -4
  48. package/legacy/dist/src/import/tui/components/CompactControlBar.d.ts +4 -0
  49. package/{dist → legacy/dist}/src/import/tui/components/ReviewStatus.d.ts +0 -5
  50. package/{dist → legacy/dist}/src/import/tui/hooks/review-input.d.ts +1 -1
  51. package/{dist → legacy/dist}/src/import/tui/lineage-layout.d.ts +18 -25
  52. package/legacy/dist/src/import/tui/run-selection-agent.d.ts +9 -0
  53. package/{dist → legacy/dist}/src/import/tui/scope-gate-columns.d.ts +14 -8
  54. package/{dist → legacy/dist}/src/import/tui/steps/CredentialsStep.d.ts +4 -1
  55. package/{dist → legacy/dist}/src/import/tui/steps/GateStep.d.ts +1 -1
  56. package/{dist → legacy/dist}/src/import/tui/steps/GenerateReviewStep.d.ts +14 -3
  57. package/legacy/dist/src/import/tui/steps/RunningStep.d.ts +24 -0
  58. package/{dist → legacy/dist}/src/import/tui/steps/ScopeGateStep.d.ts +1 -1
  59. package/{dist → legacy/dist}/src/import/tui/steps/WizardPreviewStep.d.ts +2 -2
  60. package/{dist → legacy/dist}/src/import/tui/wizard-state-transitions.d.ts +5 -7
  61. package/legacy/dist/src/index.d.ts +1 -0
  62. package/{dist → legacy/dist}/src/index.js +25284 -24282
  63. package/legacy/dist/src/lib/agent-definitions.d.ts +14 -0
  64. package/{dist → legacy/dist}/src/lib/agent-model-options.d.ts +4 -4
  65. package/{dist → legacy/dist}/src/lib/command-options.d.ts +0 -1
  66. package/{dist → legacy/dist}/src/lib/debug-logger.d.ts +1 -9
  67. package/legacy/dist/src/lib/debug-preamble.d.ts +7 -0
  68. package/{dist → legacy/dist}/src/program.d.ts +3 -3
  69. package/{dist → legacy/dist}/src/runs/store.d.ts +0 -5
  70. package/{dist → legacy/dist}/src/session/db.d.ts +32 -2
  71. package/legacy/dist/src/setup/SetupScreen.d.ts +28 -0
  72. package/legacy/dist/src/setup/SetupStepper.d.ts +7 -0
  73. package/legacy/dist/src/setup/command.d.ts +3 -0
  74. package/legacy/dist/src/setup/lib/checks.d.ts +57 -0
  75. package/legacy/dist/src/setup/lib/shell.d.ts +12 -0
  76. package/legacy/dist/src/setup/steps/CodingAgentScreen.d.ts +20 -0
  77. package/legacy/dist/src/setup/steps/ContentfulCredentialsScreen.d.ts +11 -0
  78. package/legacy/dist/src/setup/steps/StepLayout.d.ts +20 -0
  79. package/legacy/dist/src/setup/steps/preferences/AnalyticsScreen.d.ts +5 -0
  80. package/legacy/dist/src/setup/steps/preferences/BooleanInput.d.ts +21 -0
  81. package/legacy/dist/src/setup/steps/preferences/ColorPreferenceScreen.d.ts +5 -0
  82. package/legacy/dist/src/setup/steps/preferences/CustomPromptScreen.d.ts +14 -0
  83. package/legacy/dist/src/setup/steps/preferences/DebugLogsScreen.d.ts +5 -0
  84. package/legacy/dist/src/setup/steps/preferences/PreferencesMenu.d.ts +26 -0
  85. package/legacy/dist/src/setup/steps/prerequisites/PrerequisitesScreen.d.ts +16 -0
  86. package/legacy/dist/src/setup/steps/prerequisites/build.d.ts +2 -0
  87. package/legacy/dist/src/setup/steps/prerequisites/deps.d.ts +33 -0
  88. package/legacy/dist/src/setup/steps/prerequisites/index.d.ts +4 -0
  89. package/legacy/dist/src/setup/steps/prerequisites/node.d.ts +2 -0
  90. package/legacy/dist/src/setup/steps/prerequisites/pnpm.d.ts +2 -0
  91. package/legacy/dist/src/tui/render-with-goodbye.d.ts +7 -0
  92. package/legacy/dist/src/tui/use-terminal-size.d.ts +6 -0
  93. package/legacy/dist/src/tui/windowed-panel.d.ts +37 -0
  94. package/legacy/package.json +77 -0
  95. package/{skills → legacy/skills}/generate-components.md +99 -65
  96. package/package.json +13 -17
  97. package/README.md +0 -263
  98. package/dist/src/analyze/composition/interchange-schema.d.ts +0 -37
  99. package/dist/src/analyze/composition/resolve-mapping-cli.d.ts +0 -19
  100. package/dist/src/analyze/select/tui/components/LineagePanel.d.ts +0 -14
  101. package/dist/src/credentials-store.d.ts +0 -38
  102. package/dist/src/import/strip-allowed-components.d.ts +0 -18
  103. package/dist/src/import/tui/final-review-host.d.ts +0 -8
  104. package/dist/src/import/tui/hooks/useLineage.d.ts +0 -32
  105. package/dist/src/import/tui/lineage-input.d.ts +0 -18
  106. package/dist/src/import/tui/push-decision-gate-helpers.d.ts +0 -8
  107. package/dist/src/import/tui/review-step-props.d.ts +0 -13
  108. package/dist/src/import/tui/scope-gate-host.d.ts +0 -21
  109. package/dist/src/import/tui/steps/AtomicGenerateReviewStep.d.ts +0 -28
  110. package/dist/src/import/tui/steps/AtomicScopeGateStep.d.ts +0 -3
  111. package/dist/src/import/tui/steps/PushDecisionGateStep.d.ts +0 -12
  112. package/dist/src/import/tui/steps/RunningStep.d.ts +0 -13
  113. package/dist/src/import/tui/steps/useTerminalColumns.d.ts +0 -1
  114. package/dist/src/lib/composition-mode.d.ts +0 -21
  115. package/dist/src/lib/debug-preamble.d.ts +0 -14
  116. package/dist/src/runs/save-conflict.d.ts +0 -8
  117. package/dist/src/setup/analytics-prompt.d.ts +0 -13
  118. package/dist/src/setup/command.d.ts +0 -9
  119. package/dist/src/setup/composition-mode-prompt.d.ts +0 -14
  120. package/dist/src/setup/debug-mode-prompt.d.ts +0 -11
  121. package/dist/src/setup/prompt-helpers.d.ts +0 -1
  122. /package/dist/{src/index.d.ts → index.d.ts} +0 -0
  123. /package/{dist → legacy/dist}/src/analytics/apply.d.ts +0 -0
  124. /package/{dist → legacy/dist}/src/analytics/client.d.ts +0 -0
  125. /package/{dist → legacy/dist}/src/analytics/constants.d.ts +0 -0
  126. /package/{dist → legacy/dist}/src/analytics/exit.d.ts +0 -0
  127. /package/{dist → legacy/dist}/src/analytics/index.d.ts +0 -0
  128. /package/{dist → legacy/dist}/src/analytics/normalize.d.ts +0 -0
  129. /package/{dist → legacy/dist}/src/analytics/os.d.ts +0 -0
  130. /package/{dist → legacy/dist}/src/analytics/session.d.ts +0 -0
  131. /package/{dist → legacy/dist}/src/analytics/tracker.d.ts +0 -0
  132. /package/{dist → legacy/dist}/src/analytics/types.d.ts +0 -0
  133. /package/{dist → legacy/dist}/src/analyze/composite-closure.d.ts +0 -0
  134. /package/{dist → legacy/dist}/src/analyze/composition/apply-mapping.d.ts +0 -0
  135. /package/{dist → legacy/dist}/src/analyze/composition/candidate-files.d.ts +0 -0
  136. /package/{dist → legacy/dist}/src/analyze/composition/composition-cache-key.d.ts +0 -0
  137. /package/{dist → legacy/dist}/src/analyze/composition/manifest-doc-evidence.d.ts +0 -0
  138. /package/{dist → legacy/dist}/src/analyze/composition/merge-edges.d.ts +0 -0
  139. /package/{dist → legacy/dist}/src/analyze/composition/parse-map-edges.d.ts +0 -0
  140. /package/{dist → legacy/dist}/src/analyze/composition/prompt-loader.d.ts +0 -0
  141. /package/{dist → legacy/dist}/src/analyze/cycle-detection.d.ts +0 -0
  142. /package/{dist → legacy/dist}/src/analyze/cycle-view.d.ts +0 -0
  143. /package/{dist → legacy/dist}/src/analyze/fuzzy-search.d.ts +0 -0
  144. /package/{dist → legacy/dist}/src/analyze/issue-inheritance.d.ts +0 -0
  145. /package/{dist → legacy/dist}/src/analyze/lineage.d.ts +0 -0
  146. /package/{dist → legacy/dist}/src/analyze/scope-gate-cascade.d.ts +0 -0
  147. /package/{dist → legacy/dist}/src/analyze/search-neighborhood.d.ts +0 -0
  148. /package/{dist → legacy/dist}/src/analyze/select/command.d.ts +0 -0
  149. /package/{dist → legacy/dist}/src/analyze/select/parser.d.ts +0 -0
  150. /package/{dist → legacy/dist}/src/analyze/select/persistence.d.ts +0 -0
  151. /package/{dist → legacy/dist}/src/analyze/select/preview-annotations.d.ts +0 -0
  152. /package/{dist → legacy/dist}/src/analyze/select/tui/LegacySelectApp.d.ts +0 -0
  153. /package/{dist → legacy/dist}/src/analyze/select/tui/components/ComponentDetail.d.ts +0 -0
  154. /package/{dist → legacy/dist}/src/analyze/select/tui/components/ComponentRationalePanel.d.ts +0 -0
  155. /package/{dist → legacy/dist}/src/analyze/select/tui/components/GotoBanner.d.ts +0 -0
  156. /package/{dist → legacy/dist}/src/analyze/select/tui/components/HighlightedLine.d.ts +0 -0
  157. /package/{dist → legacy/dist}/src/analyze/select/tui/components/JsonEditor.d.ts +0 -0
  158. /package/{dist → legacy/dist}/src/analyze/select/tui/components/JsonPanel.d.ts +0 -0
  159. /package/{dist → legacy/dist}/src/analyze/select/tui/components/PreviewSummaryBar.d.ts +0 -0
  160. /package/{dist → legacy/dist}/src/analyze/select/tui/components/QuitDialog.d.ts +0 -0
  161. /package/{dist → legacy/dist}/src/analyze/select/tui/components/RationaleLine.d.ts +0 -0
  162. /package/{dist → legacy/dist}/src/analyze/select/tui/components/RationalePanel.d.ts +0 -0
  163. /package/{dist → legacy/dist}/src/analyze/select/tui/components/ScrollablePanel.d.ts +0 -0
  164. /package/{dist → legacy/dist}/src/analyze/select/tui/components/SourcePanel.d.ts +0 -0
  165. /package/{dist → legacy/dist}/src/analyze/select/tui/components/StatusBar.d.ts +0 -0
  166. /package/{dist → legacy/dist}/src/analyze/select/tui/components/TokenReviewPanel.d.ts +0 -0
  167. /package/{dist → legacy/dist}/src/analyze/select/tui/components/TopBar.d.ts +0 -0
  168. /package/{dist → legacy/dist}/src/analyze/select/tui/components/removed-components-text.d.ts +0 -0
  169. /package/{dist → legacy/dist}/src/analyze/select/tui/components/wrap-text.d.ts +0 -0
  170. /package/{dist → legacy/dist}/src/analyze/select/tui/hooks/list-scroll-input.d.ts +0 -0
  171. /package/{dist → legacy/dist}/src/analyze/select/tui/hooks/useKeymap.d.ts +0 -0
  172. /package/{dist → legacy/dist}/src/analyze/select/tui/hooks/useSession.d.ts +0 -0
  173. /package/{dist → legacy/dist}/src/analyze/select/tui/hooks/useUndo.d.ts +0 -0
  174. /package/{dist → legacy/dist}/src/analyze/select/tui/theme.d.ts +0 -0
  175. /package/{dist → legacy/dist}/src/analyze/select/types.d.ts +0 -0
  176. /package/{dist → legacy/dist}/src/analyze/selection-cascade.d.ts +0 -0
  177. /package/{dist → legacy/dist}/src/analyze/slot-graph.d.ts +0 -0
  178. /package/{dist → legacy/dist}/src/apply/api-client.d.ts +0 -0
  179. /package/{dist → legacy/dist}/src/apply/command.d.ts +0 -0
  180. /package/{dist → legacy/dist}/src/apply/preview-utils.d.ts +0 -0
  181. /package/{dist → legacy/dist}/src/apply/tokens.d.ts +0 -0
  182. /package/{dist → legacy/dist}/src/apply/tui/ServerApplyView.d.ts +0 -0
  183. /package/{dist → legacy/dist}/src/apply/tui/ServerPreviewView.d.ts +0 -0
  184. /package/{dist → legacy/dist}/src/generate/command.d.ts +0 -0
  185. /package/{dist → legacy/dist}/src/generate/tui/GenerateView.d.ts +0 -0
  186. /package/{dist → legacy/dist}/src/helpers/build-contentful-management-client.d.ts +0 -0
  187. /package/{dist → legacy/dist}/src/helpers/fetch-and-persist-existing-contentful-entities.d.ts +0 -0
  188. /package/{dist → legacy/dist}/src/helpers/fetch-existing-contentful-entities.d.ts +0 -0
  189. /package/{dist → legacy/dist}/src/helpers/find-nearly-matching-component.d.ts +0 -0
  190. /package/{dist → legacy/dist}/src/helpers/read-existing-contentful-entities-from-session.d.ts +0 -0
  191. /package/{dist → legacy/dist}/src/helpers/summarize-existing-contentful-entities.d.ts +0 -0
  192. /package/{dist → legacy/dist}/src/host-utils.d.ts +0 -0
  193. /package/{dist → legacy/dist}/src/import/command.d.ts +0 -0
  194. /package/{dist → legacy/dist}/src/import/cycle-auto-reject.d.ts +0 -0
  195. /package/{dist → legacy/dist}/src/import/path-utils.d.ts +0 -0
  196. /package/{dist → legacy/dist}/src/import/tui/CustomPromptBanner.d.ts +0 -0
  197. /package/{dist → legacy/dist}/src/import/tui/ai-flag.d.ts +0 -0
  198. /package/{dist → legacy/dist}/src/import/tui/autocomplete.d.ts +0 -0
  199. /package/{dist → legacy/dist}/src/import/tui/components/CounterStrip.d.ts +0 -0
  200. /package/{dist → legacy/dist}/src/import/tui/components/LegendEntry.d.ts +0 -0
  201. /package/{dist → legacy/dist}/src/import/tui/components/LivePreviewSummary.d.ts +0 -0
  202. /package/{dist → legacy/dist}/src/import/tui/components/ReviewComponentPanel.d.ts +0 -0
  203. /package/{dist → legacy/dist}/src/import/tui/components/ReviewDetailsEditor.d.ts +0 -0
  204. /package/{dist → legacy/dist}/src/import/tui/components/ReviewDialogs.d.ts +0 -0
  205. /package/{dist → legacy/dist}/src/import/tui/components/SearchMatchSummary.d.ts +0 -0
  206. /package/{dist → legacy/dist}/src/import/tui/components/SpaceEnvironment.d.ts +0 -0
  207. /package/{dist → legacy/dist}/src/import/tui/components/StepHeader.d.ts +0 -0
  208. /package/{dist → legacy/dist}/src/import/tui/cycle-panel-scroll.d.ts +0 -0
  209. /package/{dist → legacy/dist}/src/import/tui/group-collapse.d.ts +0 -0
  210. /package/{dist → legacy/dist}/src/import/tui/history.d.ts +0 -0
  211. /package/{dist → legacy/dist}/src/import/tui/hooks/sidebar-search-state.d.ts +0 -0
  212. /package/{dist → legacy/dist}/src/import/tui/hooks/useOverlayPanel.d.ts +0 -0
  213. /package/{dist → legacy/dist}/src/import/tui/hooks/useReviewEditor.d.ts +0 -0
  214. /package/{dist → legacy/dist}/src/import/tui/hooks/useReviewPreview.d.ts +0 -0
  215. /package/{dist → legacy/dist}/src/import/tui/hooks/useReviewSession.d.ts +0 -0
  216. /package/{dist → legacy/dist}/src/import/tui/hooks/useReviewSurfaceState.d.ts +0 -0
  217. /package/{dist → legacy/dist}/src/import/tui/preview-confirmation-input.d.ts +0 -0
  218. /package/{dist → legacy/dist}/src/import/tui/push-progress.d.ts +0 -0
  219. /package/{dist → legacy/dist}/src/import/tui/run-print-files-helpers.d.ts +0 -0
  220. /package/{dist → legacy/dist}/src/import/tui/run-teaser.d.ts +0 -0
  221. /package/{dist → legacy/dist}/src/import/tui/runLivePreview.d.ts +0 -0
  222. /package/{dist → legacy/dist}/src/import/tui/runScopeGate.d.ts +0 -0
  223. /package/{dist → legacy/dist}/src/import/tui/sidebar-help.d.ts +0 -0
  224. /package/{dist → legacy/dist}/src/import/tui/sidebar-input.d.ts +0 -0
  225. /package/{dist → legacy/dist}/src/import/tui/sidebar-navigation.d.ts +0 -0
  226. /package/{dist → legacy/dist}/src/import/tui/sidebar-width.d.ts +0 -0
  227. /package/{dist → legacy/dist}/src/import/tui/spawn-generate.d.ts +0 -0
  228. /package/{dist → legacy/dist}/src/import/tui/step-filters.d.ts +0 -0
  229. /package/{dist → legacy/dist}/src/import/tui/steps/DoneStep.d.ts +0 -0
  230. /package/{dist → legacy/dist}/src/import/tui/steps/ErrorStep.d.ts +0 -0
  231. /package/{dist → legacy/dist}/src/import/tui/steps/PathValidationStep.d.ts +0 -0
  232. /package/{dist → legacy/dist}/src/import/tui/steps/PreviewValidationErrorStep.d.ts +0 -0
  233. /package/{dist → legacy/dist}/src/import/tui/steps/PushingStep.d.ts +0 -0
  234. /package/{dist → legacy/dist}/src/import/tui/steps/TokenInputStep.d.ts +0 -0
  235. /package/{dist → legacy/dist}/src/import/tui/steps/WelcomeStep.d.ts +0 -0
  236. /package/{dist → legacy/dist}/src/import/tui/steps/auto-reject-decision.d.ts +0 -0
  237. /package/{dist → legacy/dist}/src/import/tui/steps/breaking-change-format.d.ts +0 -0
  238. /package/{dist → legacy/dist}/src/import/tui/steps/enumerate-cycle-breaks.d.ts +0 -0
  239. /package/{dist → legacy/dist}/src/import/tui/steps/preview-diff.d.ts +0 -0
  240. /package/{dist → legacy/dist}/src/import/tui/steps/review-details-panel.d.ts +0 -0
  241. /package/{dist → legacy/dist}/src/import/tui/steps/review-json-panel.d.ts +0 -0
  242. /package/{dist → legacy/dist}/src/import/tui/useFinalizePreview.d.ts +0 -0
  243. /package/{dist → legacy/dist}/src/import/tui/useLivePreview.d.ts +0 -0
  244. /package/{dist → legacy/dist}/src/import/tui/wizard-422-helpers.d.ts +0 -0
  245. /package/{dist → legacy/dist}/src/import/tui/wizard-generate-progress.d.ts +0 -0
  246. /package/{dist → legacy/dist}/src/lib/agent-output.d.ts +0 -0
  247. /package/{dist → legacy/dist}/src/lib/cli-errors.d.ts +0 -0
  248. /package/{dist → legacy/dist}/src/lib/cli-path.d.ts +0 -0
  249. /package/{dist → legacy/dist}/src/lib/component-patch.d.ts +0 -0
  250. /package/{dist → legacy/dist}/src/lib/contentful-urls.d.ts +0 -0
  251. /package/{dist → legacy/dist}/src/lib/error-parser.d.ts +0 -0
  252. /package/{dist → legacy/dist}/src/lib/path-exists.d.ts +0 -0
  253. /package/{dist → legacy/dist}/src/lib/prompt-overrides.d.ts +0 -0
  254. /package/{dist → legacy/dist}/src/lib/terminal-capabilities.d.ts +0 -0
  255. /package/{dist → legacy/dist}/src/lib/user-agent.d.ts +0 -0
  256. /package/{dist → legacy/dist}/src/map-tokens/apply.d.ts +0 -0
  257. /package/{dist → legacy/dist}/src/map-tokens/command.d.ts +0 -0
  258. /package/{dist → legacy/dist}/src/map-tokens/resolve-defaults.d.ts +0 -0
  259. /package/{dist → legacy/dist}/src/map-tokens/tui/MapTokensView.d.ts +0 -0
  260. /package/{dist → legacy/dist}/src/output/format.d.ts +0 -0
  261. /package/{dist → legacy/dist}/src/print/command.d.ts +0 -0
  262. /package/{dist → legacy/dist}/src/print/validate/tui/ValidateView.d.ts +0 -0
  263. /package/{dist → legacy/dist}/src/print/validate/validators/cdf-validator.d.ts +0 -0
  264. /package/{dist → legacy/dist}/src/print/validate/validators/dtcg-validator.d.ts +0 -0
  265. /package/{dist → legacy/dist}/src/print/validate/validators/format-errors.d.ts +0 -0
  266. /package/{dist → legacy/dist}/src/print/validate/validators/read-json-file.d.ts +0 -0
  267. /package/{dist → legacy/dist}/src/runs/fingerprint.d.ts +0 -0
  268. /package/{dist → legacy/dist}/src/runs/path-prompt.d.ts +0 -0
  269. /package/{dist → legacy/dist}/src/runs/save-path-resolver.d.ts +0 -0
  270. /package/{dist → legacy/dist}/src/session/cache-keys.d.ts +0 -0
  271. /package/{dist → legacy/dist}/src/session/core/cdf/cdf-mappers.d.ts +0 -0
  272. /package/{dist → legacy/dist}/src/session/core/components/derive-component-id.d.ts +0 -0
  273. /package/{dist → legacy/dist}/src/session/core/components/hash-component-shape.d.ts +0 -0
  274. /package/{dist → legacy/dist}/src/session/core/shared/index-rows-by-key.d.ts +0 -0
  275. /package/{dist → legacy/dist}/src/session/core/tokens/build-dtcg-groups.d.ts +0 -0
  276. /package/{dist → legacy/dist}/src/session/core/tokens/build-dtcg-tokens.d.ts +0 -0
  277. /package/{dist → legacy/dist}/src/session/core/tokens/hash-token-content.d.ts +0 -0
  278. /package/{dist → legacy/dist}/src/session/migration.d.ts +0 -0
  279. /package/{dist → legacy/dist}/src/session/repositories/sessions/read.d.ts +0 -0
  280. /package/{dist → legacy/dist}/src/session/repositories/sessions/write.d.ts +0 -0
  281. /package/{dist → legacy/dist}/src/session/repositories/shared/with-transaction.d.ts +0 -0
  282. /package/{dist → legacy/dist}/src/session/repositories/steps/read.d.ts +0 -0
  283. /package/{dist → legacy/dist}/src/session/repositories/steps/write.d.ts +0 -0
  284. /package/{dist → legacy/dist}/src/session/repositories/tokens/read.d.ts +0 -0
  285. /package/{dist → legacy/dist}/src/session/repositories/tokens/write.d.ts +0 -0
  286. /package/{dist → legacy/dist}/src/session/resolve-session-id.d.ts +0 -0
  287. /package/{dist → legacy/dist}/src/session/services/session-resolver.d.ts +0 -0
  288. /package/{dist → legacy/dist}/src/session/services/tokens/apply-tool-calls.d.ts +0 -0
  289. /package/{dist → legacy/dist}/src/session/services/tokens/replace-raw-prop-token-paths.d.ts +0 -0
  290. /package/{dist → legacy/dist}/src/session/services/tokens/replace-raw-token-name-paths.d.ts +0 -0
  291. /package/{dist → legacy/dist}/src/session/services/tokens/store-dtcg-tokens.d.ts +0 -0
  292. /package/{dist → legacy/dist}/src/session/session-id.d.ts +0 -0
  293. /package/{dist → legacy/dist}/src/session/source-excerpt.d.ts +0 -0
  294. /package/{dist → legacy/dist}/src/tui/CommandCompletionView.d.ts +0 -0
  295. /package/{dist → legacy/dist}/src/tui/use-blinking-cursor.d.ts +0 -0
  296. /package/{dist → legacy/dist}/src/tui/use-timed-spinner.d.ts +0 -0
  297. /package/{dist → legacy/dist}/src/types.d.ts +0 -0
  298. /package/{prompts → legacy/prompts}/composition-edges.md +0 -0
  299. /package/{skills → legacy/skills}/generate-tokens.md +0 -0
  300. /package/{skills → legacy/skills}/map-tokens.md +0 -0
  301. /package/{skills → legacy/skills}/select-components.md +0 -0
@@ -12,11 +12,12 @@ Contentful Experience Orchestration is a Contentful product that enables **marke
12
12
 
13
13
  A Component Type has two kinds of configurable properties:
14
14
 
15
- - **Design Properties** — values that control *how the component looks*: color scheme, visual variant (primary/secondary/ghost), size (sm/md/lg), spacing, layout orientation, background color, font style, border style, any visual toggle that changes appearance. These are the values a designer sets once and a marketer may override. Think: "what would a designer put in a design token or a style guide?"
16
- - **Content Properties** — values that are *data the component displays*: labels, headings, body text, rich text, images, media, URLs, counts, IDs used for CMS lookups, locales. These are filled by editors with real CMS content. Think: "what does a copywriter or content editor fill in?"
15
+ - **Design Properties** — values that control _how the component looks_: color scheme, visual variant (primary/secondary/ghost), size (sm/md/lg), spacing, layout orientation, background color, font style, border style, any visual toggle that changes appearance. These are the values a designer sets once and a marketer may override. Think: "what would a designer put in a design token or a style guide?"
16
+ - **Content Properties** — values that are _data the component displays_: labels, headings, body text, rich text, images, media, URLs, counts, IDs used for CMS lookups, locales. These are filled by editors with real CMS content. Think: "what does a copywriter or content editor fill in?"
17
17
 
18
18
  The third category:
19
- - **State Properties** — values that control *interactive or behavioral state*: disabled, loading, expanded, isOpen, isSearchVisible. These are runtime behavioral flags, not visual design nor content.
19
+
20
+ - **State Properties** — values that control _interactive or behavioral state_: disabled, loading, expanded, isOpen, isSearchVisible. These are runtime behavioral flags, not visual design nor content.
20
21
 
21
22
  Getting this right matters: Contentful uses the category to decide where a property appears in the editor UI. Design properties appear in the design panel, content properties appear in the content panel.
22
23
 
@@ -35,13 +36,13 @@ All input is embedded inline in the prompt before this file:
35
36
  ```typescript
36
37
  interface RawPropDefinition {
37
38
  name: string;
38
- type: string; // raw TypeScript type, e.g. "'primary' | 'secondary'"
39
+ type: string; // raw TypeScript type, e.g. "'primary' | 'secondary'"
39
40
  required: boolean;
40
- category?: 'content' | 'design' | 'state'; // pre-classified — verify, do not blindly trust
41
+ category?: 'content' | 'design' | 'state'; // pre-classified — verify, do not blindly trust
41
42
  allowedValues?: string[];
42
43
  defaultValue?: string;
43
44
  description?: string;
44
- tokenReference?: string; // raw token name — shape varies by design system, e.g. "--brand-primary" (CSS custom property) or "tokens.blue500" (flat/dotted JS reference)
45
+ tokenReference?: string; // raw token name — shape varies by design system, e.g. "--brand-primary" (CSS custom property) or "tokens.blue500" (flat/dotted JS reference)
45
46
  }
46
47
 
47
48
  interface RawSlotDefinition {
@@ -60,6 +61,7 @@ interface RawComponentDefinition {
60
61
 
61
62
  The `category` field on each prop is a pre-classification hint from static analysis heuristics.
62
63
  It is correct approximately 80% of the time for simple props. You should:
64
+
63
65
  - Trust it for obvious cases (event handlers excluded, text labels as content)
64
66
  - Override it when your domain knowledge indicates otherwise
65
67
  - NEVER produce zero output — if you disagree with all hints, explain why in descriptions
@@ -87,12 +89,13 @@ Emit one JSON object per line. The CLI parses lines starting with `{`. Lines not
87
89
  ```
88
90
 
89
91
  **Rules:**
92
+
90
93
  - Emit exactly one JSON object per line. No multi-line JSON.
91
94
  - Every prop in the input must produce exactly one call: `classify_prop` OR `exclude_prop`.
92
95
  - Every slot must produce exactly one `classify_slot` call.
93
96
  - Emit `classify_component` once at the start (required). The `description` field is **required** — always provide a brief description of the component's purpose.
94
97
  - `values` is required for `cdf_type: "enum"` — must be a non-empty string array of the variant names the prop accepts. **There is no legal `enum` with a guessed list.** If the value set is shown to you anywhere in the material below — the type's own declaration, an `allowedValues` list on the raw prop, a variant/lookup map, a default, a sibling excerpt — copy it and emit `enum`. If it is shown nowhere, emit `cdf_type: "string"` and leave `values` off. `string` is an unrestricted enum: the author can still pass the real value. A guessed list silently rejects it.
95
- - **Do NOT include `values` for `cdf_type: "token"`.** The two property types carry different kinds of list. An `enum` prop's list holds *variant names* the component accepts (`"primary"`, `"secondary"`). A `token` prop's list holds *design token paths* (`"color.brand.primary"`), produced by the separate token-mapping step (`$token.allowed`) — never by you. Emitting `values` on a token prop makes the definition invalid.
98
+ - **Do NOT include `values` for `cdf_type: "token"`.** The two property types carry different kinds of list. An `enum` prop's list holds _variant names_ the component accepts (`"primary"`, `"secondary"`). A `token` prop's list holds _design token paths_ (`"color.brand.primary"`), produced by the separate token-mapping step (`$token.allowed`) — never by you. Emitting `values` on a token prop makes the definition invalid.
96
99
  - `token_kind` is required for `cdf_type: "token"` — must be a DTCG `$type` string, e.g. `"color"`.
97
100
  - `required` must be a JSON boolean (`true`/`false`), not a string.
98
101
  - `description` on `classify_prop` is customer-facing — keep it short and subject to the description content rules below.
@@ -117,14 +120,14 @@ Emit one JSON object per line. The CLI parses lines starting with `{`. Lines not
117
120
 
118
121
  Exactly **6** valid types:
119
122
 
120
- | cdf_type | Use case |
121
- |---|---|
122
- | `string` | Plain text, URLs, href props, numbers (as string), any string-shaped value |
123
- | `richtext` | Formatted text, HTML, ReactNode used as markup |
124
- | `media` | Images, videos, media assets |
125
- | `enum` | Fixed set of string choices — requires `values` |
126
- | `token` | Design-token-linked prop — requires `token_kind` |
127
- | `boolean` | Boolean toggle props (visible, disabled, enabled, etc.) |
123
+ | cdf_type | Use case |
124
+ | ---------- | -------------------------------------------------------------------------- |
125
+ | `string` | Plain text, URLs, href props, numbers (as string), any string-shaped value |
126
+ | `richtext` | Formatted text, HTML, ReactNode used as markup |
127
+ | `media` | Images, videos, media assets |
128
+ | `enum` | Fixed set of string choices — requires `values` |
129
+ | `token` | Design-token-linked prop — requires `token_kind` |
130
+ | `boolean` | Boolean toggle props (visible, disabled, enabled, etc.) |
128
131
 
129
132
  > **IMPORTANT: No `number` type.** The design-systems API only supports the `String` design property variant for numeric values. All numeric props must use `cdf_type: "string"` with the number as a string default (e.g. `"0"`, `"100"`). Boolean props can now use `cdf_type: "boolean"` directly.
130
133
 
@@ -134,11 +137,11 @@ Exactly **6** valid types:
134
137
 
135
138
  ### `enum` versus `token`
136
139
 
137
- Both describe a closed set of choices, but the *contents* differ, and that is the whole distinction:
140
+ Both describe a closed set of choices, but the _contents_ differ, and that is the whole distinction:
138
141
 
139
- | | What the list holds | Example |
140
- |---|---|---|
141
- | `enum` | Variant names the component accepts | `["primary", "secondary", "ghost"]` |
142
+ | | What the list holds | Example |
143
+ | ------- | --------------------------------------- | ------------------------------------------------ |
144
+ | `enum` | Variant names the component accepts | `["primary", "secondary", "ghost"]` |
142
145
  | `token` | Design token paths the prop may bind to | `["color.brand.primary", "color.brand.neutral"]` |
143
146
 
144
147
  The distinction is **what the component does with the value it receives**. That
@@ -147,7 +150,7 @@ component's role, or from the property's TypeScript type.
147
150
 
148
151
  An `enum` design property is delivered as a plain string, so the component
149
152
  receives `variant="primary"` — the value its own code branches on. A `token`
150
- property is resolved to the token's value *before* it reaches the component, so
153
+ property is resolved to the token's value _before_ it reaches the component, so
151
154
  that same component would receive `variant="#0059c8"` and match no branch.
152
155
 
153
156
  #### The three-question procedure (closed, ordered)
@@ -160,7 +163,7 @@ that decides. There is no fourth question.
160
163
  An indexed access (`tokens[fontColor]`, `SPACING[padding]`, a `Record<Variant, Token>`),
161
164
  a `switch (variant)` / `if (variant === 'x')` chain, a `styles[variant]` class lookup,
162
165
  or a vocabulary of its own (`allowedValues`, a literal union) — any of these means
163
- the component needs the *name*. A presence check (`if (width)`) or arithmetic on
166
+ the component needs the _name_. A presence check (`if (width)`) or arithmetic on
164
167
  the value is not a lookup.
165
168
  **Yes → `enum`, names in `values`, stop.** No → Q2.
166
169
  - **Q2 — Is the value written straight into a style or attribute?**
@@ -170,7 +173,7 @@ that decides. There is no fourth question.
170
173
  - **Q3 — Is there a design-token reference at that use?** Any one of:
171
174
  the parameter default is a token (`radius = tokens.borderRadiusSmall`), the raw prop
172
175
  carries a `tokenReference`, or an inline `tokens.*` / `var(--*)` sits in the same
173
- expression. The reference must belong to *this* prop — a `tokens.*` on some other
176
+ expression. The reference must belong to _this_ prop — a `tokens.*` on some other
174
177
  line of the file, or in a sibling's style object, is not one.
175
178
  **Yes → `token`, stop; resolve `token_kind` from that reference. No → `string`, stop.**
176
179
 
@@ -178,7 +181,7 @@ that decides. There is no fourth question.
178
181
  `string | number`, `stringOrNumber` — none of these answers any question above;
179
182
  they say what the compiler accepts, not what the component does with the value.
180
183
  "The type accepts any value, the default just happens to be a token reference" is
181
- a Q3-yes described as a no: a token parameter default *is* the design-token
184
+ a Q3-yes described as a no: a token parameter default _is_ the design-token
182
185
  reference Q3 asks for, and the prop is `token`. Equally, a prop named `color` with
183
186
  no lookup and no token reference is `string`, however token-like the name.
184
187
 
@@ -216,7 +219,7 @@ the source is truncated at the point of use (the "uses not shown" line). In thos
216
219
  cases emit `enum` if a value set is citable from the source shown, else `cdf_type:
217
220
  "string"` per "no legal `enum` with a guessed list" — either way, record the
218
221
  ambiguity in `reason`. When the three
219
- questions *can* be answered from the source shown, they are answered and the
222
+ questions _can_ be answered from the source shown, they are answered and the
220
223
  tie-break does not apply: a clear Q1-yes is `enum`, a clear Q2-yes + Q3-yes is
221
224
  `token`, and a type annotation does not create ambiguity. An `enum` is delivered
222
225
  as the plain string the component was written to receive and remains reachable
@@ -229,11 +232,11 @@ reason to call a decided case a tie.
229
232
 
230
233
  ## Valid cdf_category values
231
234
 
232
- | cdf_category | Use case |
233
- |---|---|
234
- | `content` | Data the component *displays* — what a copywriter or editor fills in: text, labels, headings, body copy, rich text, images, media, URLs, link targets, counts, locale |
235
- | `design` | Values that control *how the component looks* — what a designer sets: color, size (sm/md/lg), variant (primary/secondary/ghost), layout orientation, alignment, background, visual toggles (imageOnLeft, enableEffect), design tokens |
236
- | `state` | Runtime behavioral or interactive flags — not visible in the editor's design or content panel: disabled, loading, expanded, isOpen, isSearchVisible, preview, identifiers used for analytics/tracking (componentId, sectionKey, componentName) |
235
+ | cdf_category | Use case |
236
+ | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
237
+ | `content` | Data the component _displays_ — what a copywriter or editor fills in: text, labels, headings, body copy, rich text, images, media, URLs, link targets, counts, locale |
238
+ | `design` | Values that control _how the component looks_ — what a designer sets: color, size (sm/md/lg), variant (primary/secondary/ghost), layout orientation, alignment, background, visual toggles (imageOnLeft, enableEffect), design tokens |
239
+ | `state` | Runtime behavioral or interactive flags — not visible in the editor's design or content panel: disabled, loading, expanded, isOpen, isSearchVisible, preview, identifiers used for analytics/tracking (componentId, sectionKey, componentName) |
237
240
 
238
241
  The pre-classified `category` in the raw input is a starting point — correct it when it is wrong. Contentful uses this category to decide where the property appears in the editor UI, so accuracy matters.
239
242
 
@@ -254,7 +257,8 @@ For each `RawPropDefinition`, apply in order:
254
257
  - Data attributes: any `data-*` prop
255
258
  - **Polymorphic component props**: `as`, `element`, `component` (when typed as an HTML tag string or component reference) — these change rendered HTML, not marketer-visible behavior
256
259
  - **Framework theming / pass-through escape hatches**: PrimeVue's `dt` / `pt` / `ptOptions` / `unstyled`, MUI/Chakra-style `sx`, anything explicitly typed as a developer "override" / "passthrough" object
257
- - **Important caveat**: only exclude when the prop is inherited/universal *and unredeclared*. Compound names like `fileName`, `displayName`, `dataset`, `dataSource`, `roleDescription`, `idLabel` are not pass-through — classify them normally. Likewise, a `title` (or any other inherited-attribute name) that the component redeclares with its own type or doc comment is component-specific content, not pass-through — classify it per rule 2 onward, do not exclude it and do not route it through the `title` → `content` correction below.
260
+ - **Important caveat**: only exclude when the prop is inherited/universal _and unredeclared_. Compound names like `fileName`, `displayName`, `dataset`, `dataSource`, `roleDescription`, `idLabel` are not pass-through — classify them normally. Likewise, a `title` (or any other inherited-attribute name) that the component redeclares with its own type or doc comment is component-specific content, not pass-through — classify it per rule 2 onward, do not exclude it and do not route it through the `title` → `content` correction below.
261
+
258
262
  2. **Common semantic props — DO classify, do not exclude.** The LLM has been over-excluding these because they sound like framework internals; they are not. Classify each per the rest of this tree:
259
263
  - `icon` / `leftIcon` / `rightIcon` / `prefixIcon` / `suffixIcon` — slot or `string` (icon name); see slot guidance below
260
264
  - `items` / `options` / `actions` / `links` — usually array content; if the element shape is simple, classify as `string` (comma-separated names/IDs) and note in `description`. Only exclude when elements are deep nested objects with no flat representation.
@@ -266,21 +270,21 @@ For each `RawPropDefinition`, apply in order:
266
270
  - `eventDetails` / similar telemetry props — `cdf_category: "state"`.
267
271
  3. **Positional/geometric design prop?** (`top`, `bottom`, `left`, `right`, `rotation`, `offset`, `zIndex`) → `classify_prop`, `cdf_type: "string"`, `cdf_category: "design"`.
268
272
  4. **`enum` or `token`? — run the three-question procedure first.** Before any type-based rule, for every design prop that carries a value, answer Q1–Q3 from "`enum` versus `token`" above, in order, from the source shown:
273
+ - **Q1** looked up / switched on / compared / has its own vocabulary → `cdf_type: "enum"`, names in `values`, no `token_kind`. This holds even when every name maps 1:1 to a design token; the map is the component resolving a name it was given.
274
+ - **Q2** not written straight into a style or attribute → not `token`; continue to rules 5–7.
275
+ - **Q3** written straight into a style or attribute **and** a token reference at that use (a `tokens.*` parameter default, a `tokenReference`, an inline `tokens.*` / `var(--*)`) → `cdf_type: "token"`, `token_kind` from that reference via the sidecar, no `values`. Interpolated with no token reference at that use → `cdf_type: "string"`.
276
+ - Q1–Q3 **cannot be answered** from the source shown (unread, truncated, in a file you cannot see, evidence pointing both ways) → `cdf_type: "enum"` (or `string`). See "Ambiguity resolves to `enum`" above.
269
277
 
270
- * **Q1** looked up / switched on / compared / has its own vocabulary → `cdf_type: "enum"`, names in `values`, no `token_kind`. This holds even when every name maps 1:1 to a design token; the map is the component resolving a name it was given.
271
- * **Q2** not written straight into a style or attribute → not `token`; continue to rules 5–7.
272
- * **Q3** written straight into a style or attribute **and** a token reference at that use (a `tokens.*` parameter default, a `tokenReference`, an inline `tokens.*` / `var(--*)`) → `cdf_type: "token"`, `token_kind` from that reference via the sidecar, no `values`. Interpolated with no token reference at that use → `cdf_type: "string"`.
273
- * Q1–Q3 **cannot be answered** from the source shown (unread, truncated, in a file you cannot see, evidence pointing both ways) → `cdf_type: "enum"` (or `string`). See "Ambiguity resolves to `enum`" above.
274
-
275
- **Do not classify on the component's role.** A layout primitive is not automatically a token consumer. Design systems routinely key their primitives on token *names*, and those props are `enum` — the component needs the name to perform its own lookup:
278
+ **Do not classify on the component's role.** A layout primitive is not automatically a token consumer. Design systems routinely key their primitives on token _names_, and those props are `enum` — the component needs the name to perform its own lookup:
276
279
 
277
280
  ```ts
278
281
  // Box.tsx — padding is an enum, despite Box being a layout primitive
279
- const { padding } = props; // "spacingXs"
280
- getSpacingStyles({ padding }); // → SpacingTable["spacingXs"] → "0.5rem"
282
+ const { padding } = props; // "spacingXs"
283
+ getSpacingStyles({ padding }); // → SpacingTable["spacingXs"] → "0.5rem"
281
284
  ```
282
285
 
283
286
  Classify that `padding` as `token` and the platform delivers `"0.5rem"`, so `SpacingTable["0.5rem"]` is `undefined` and the spacing silently disappears. A value that is spelled like a token name is still a lookup key (Q1 yes). Curated components with named variant APIs (`Button`, `Tag`, `Badge`, `Avatar`, `Notification`) are `enum` for the same reason. A design system may legitimately produce **zero** token-typed props.
287
+
284
288
  5. **Union of string literals** (e.g. `'a' | 'b' | 'c'`)? → `cdf_type: "enum"`, extract literals into `values`. (Rule 4's Q1 will normally have decided this already — a literal union is the prop's own vocabulary.) This applies even when Component source references show each literal resolving to a design token internally — a resolved token map is evidence about the component's internals, not its interface.
285
289
  6. **Raw type is `string`** and prop name is `href`, `url`, or clearly a URL? → `cdf_type: "string"`, `cdf_category: "content"`.
286
290
  7. **Raw type is `string` / `number` / `boolean`?** → For `boolean`, use `cdf_type: "boolean"` with `default: true` or `false` (native boolean). For `number`, use `cdf_type: "string"` with `default` as the numeric value as a string (e.g. `"0"`). For `string`, use `cdf_type: "string"`. **A design prop reaches this rule only after leaving rule 4 at Q2 (not written into a style) or Q3 (written into a style with no token reference at that use).** A prop that answered Q3 yes is already `token` and never arrives here — a `string`, `number`, or `string | number` annotation on it does not bring it back to this rule.
@@ -292,27 +296,28 @@ For each `RawPropDefinition`, apply in order:
292
296
 
293
297
  ## Resolving complex types — do not exclude without reasoning
294
298
 
295
- A prop with a complex TypeScript type is **not automatically excluded**. Many props that appear complex carry real marketer-configurable information. Before excluding, ask: *"Could a marketer set this value in Contentful?"* If yes, classify it.
299
+ A prop with a complex TypeScript type is **not automatically excluded**. Many props that appear complex carry real marketer-configurable information. Before excluding, ask: _"Could a marketer set this value in Contentful?"_ If yes, classify it.
296
300
 
297
301
  **Common resolvable patterns:**
298
302
 
299
- | Raw type pattern | How to resolve |
300
- |---|---|
301
- | `'primary' \| 'secondary' \| 'ghost'` (union of literals) | → `enum`, extract `values` |
303
+ | Raw type pattern | How to resolve |
304
+ | ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
305
+ | `'primary' \| 'secondary' \| 'ghost'` (union of literals) | → `enum`, extract `values` |
302
306
  | `HeadingSize` / `ButtonVariant` / any named type that is clearly a finite set of visual options | → `enum` if you can cite its values from the source shown (the type's own declaration, a lookup table, a default) — copy them, never invent them. If the source shown does not enumerate the values, this is not the Q1–Q3 ambiguity tie-break — it is the "no legal `enum` with a guessed list" rule: emit `cdf_type: "string"` instead, with the missing evidence noted in `reason`. Do not default to a generic guess like `['sm', 'md', 'lg']` or `['primary', 'secondary']` — those are one design system's vocabulary, not a fallback for missing evidence. |
303
- | `Variant` / `variant` prop | Usually a visual design variant. → `enum`, `cdf_category: "design"`. Same evidence rule as above — cite values from the source shown; do not invent them. |
304
- | `Section[]` / array of custom items where the structure is unclear | → `exclude_prop` only if the array elements are complex objects with no obvious flat representation. If items are simple (title, label, id), consider representing as `string` (a comma-separated IDs or keys) or note in `description` why. |
305
- | `ExperienceConfiguration<Variant>` / deep generic | Personalization config — → `exclude_prop`, reason: `"personalization configuration — framework internal"` |
306
- | `React.Dispatch<...>` / setter | State setter — → `exclude_prop`, reason: `"React state setter — framework internal"` |
307
- | `React.RefObject<...>` / `ref` | → `exclude_prop`, reason: `"ref — framework internal"` |
308
- | `() => void` / callback | → `exclude_prop`, reason: `"callback function — framework internal"` |
309
- | `ReactNode` used as a slot-like prop (children, `icon`, `footer`) | → classify as a `slot` if it represents an injectable area, or `richtext` if it is inline markup content |
310
- | `boolean` with a name like `hideChevron`, `imageOnLeft`, `enableBackgroundColorEffect` | → `boolean`, `cdf_category: "design"`, `default: true` or `false` — these control visual appearance |
311
- | `boolean` with a name like `preview`, `hideContentForPersonalization` | → `boolean`, `cdf_category: "state"`, `default: false` — these control behavior |
312
- | `string` used as a `componentId`, `sectionKey`, `componentName` | → `string`, `cdf_category: "state"` — these are identifiers for tracking/lookup |
313
- | `string` locale (e.g. `locale: string`) | → `string`, `cdf_category: "state"` — locale is a behavioral/routing value |
307
+ | `Variant` / `variant` prop | Usually a visual design variant. → `enum`, `cdf_category: "design"`. Same evidence rule as above — cite values from the source shown; do not invent them. |
308
+ | `Section[]` / array of custom items where the structure is unclear | → `exclude_prop` only if the array elements are complex objects with no obvious flat representation. If items are simple (title, label, id), consider representing as `string` (a comma-separated IDs or keys) or note in `description` why. |
309
+ | `ExperienceConfiguration<Variant>` / deep generic | Personalization config — → `exclude_prop`, reason: `"personalization configuration — framework internal"` |
310
+ | `React.Dispatch<...>` / setter | State setter — → `exclude_prop`, reason: `"React state setter — framework internal"` |
311
+ | `React.RefObject<...>` / `ref` | → `exclude_prop`, reason: `"ref — framework internal"` |
312
+ | `() => void` / callback | → `exclude_prop`, reason: `"callback function — framework internal"` |
313
+ | `ReactNode` used as a slot-like prop (children, `icon`, `footer`) | → classify as a `slot` if it represents an injectable area, or `richtext` if it is inline markup content |
314
+ | `boolean` with a name like `hideChevron`, `imageOnLeft`, `enableBackgroundColorEffect` | → `boolean`, `cdf_category: "design"`, `default: true` or `false` — these control visual appearance |
315
+ | `boolean` with a name like `preview`, `hideContentForPersonalization` | → `boolean`, `cdf_category: "state"`, `default: false` — these control behavior |
316
+ | `string` used as a `componentId`, `sectionKey`, `componentName` | → `string`, `cdf_category: "state"` — these are identifiers for tracking/lookup |
317
+ | `string` locale (e.g. `locale: string`) | → `string`, `cdf_category: "state"` — locale is a behavioral/routing value |
314
318
 
315
319
  **When to finally exclude:**
320
+
316
321
  - The type is a callback signature or event handler
317
322
  - The type is a React ref
318
323
  - The type is a React state setter (`Dispatch`)
@@ -342,6 +347,7 @@ function splits on `.` and takes only the last segment, producing poor display n
342
347
  produces display names like "Item Url", "Item Alt" which are more readable in the ExO editor.
343
348
 
344
349
  Rules for nested objects:
350
+
345
351
  - Flatten to max depth 2 (e.g., `item_nested_deep` is acceptable, deeper is not)
346
352
  - Each leaf field gets its own classify_prop call with underscore-joined name
347
353
  - Apply the same classification rules as top-level props
@@ -384,9 +390,11 @@ The pre-classified `category` is wrong in predictable ways. Correct silently (do
384
390
  The `classify_slot` tool call maps to CDF's `$slots` object. Each slot you classify becomes a `$slots` entry; the `allowed_components` field maps to `$allowedComponents` in the output CDF.
385
391
 
386
392
  For each `RawSlotDefinition`:
393
+
387
394
  - `name` → `slot` field
388
395
  - `description` → `description` field
389
396
  - `allowedComponents` → `allowed_components` (pass through)
397
+ - `allowed_components` must contain only exact names from the hard allowlist supplied in the prompt; never invent a child from an import, JSX element, type name, icon name, or implementation helper, and omit any child that is not listed.
390
398
  - `required`:
391
399
  - `true` if the component does not render correctly without content in this slot (primary content area of a Card, Dialog body, etc.)
392
400
  - `false` if clearly optional (icon slot, footer slot with a default, decorative slot)
@@ -401,21 +409,33 @@ For each `RawSlotDefinition`:
401
409
  ### Simple component
402
410
 
403
411
  Input:
412
+
404
413
  ```json
405
414
  {
406
415
  "name": "Button",
407
416
  "props": [
408
- {"name":"label","type":"string","category":"content","required":true},
409
- {"name":"variant","type":"'primary'|'secondary'|'ghost'","category":"design","defaultValue":"'primary'"},
410
- {"name":"disabled","type":"boolean","category":"design"},
411
- {"name":"onClick","type":"()=>void","category":"state"},
412
- {"name":"className","type":"string"}
417
+ {
418
+ "name": "label",
419
+ "type": "string",
420
+ "category": "content",
421
+ "required": true
422
+ },
423
+ {
424
+ "name": "variant",
425
+ "type": "'primary'|'secondary'|'ghost'",
426
+ "category": "design",
427
+ "defaultValue": "'primary'"
428
+ },
429
+ { "name": "disabled", "type": "boolean", "category": "design" },
430
+ { "name": "onClick", "type": "()=>void", "category": "state" },
431
+ { "name": "className", "type": "string" }
413
432
  ],
414
- "slots": [{"name":"icon","description":"Optional leading icon"}]
433
+ "slots": [{ "name": "icon", "description": "Optional leading icon" }]
415
434
  }
416
435
  ```
417
436
 
418
437
  Output:
438
+
419
439
  ```
420
440
  Starting Button classification — 5 props, 1 slot
421
441
  {"tool":"classify_component","description":"Primary action button with variant and state support","rationale":{"description":"Button is an atom — a single interactive control that triggers an action. It carries a label, a small set of visual variants, and a disabled flag, which is the minimal surface a marketer needs to configure a call-to-action.","props":"Kept label (content), variant (enum, design), disabled (boolean, state), and className (string, design escape hatch). Excluded onClick because it is an event handler — framework-internal and not configurable in Contentful.","slots":"Kept the icon slot as optional because the button renders correctly without it and the icon is purely decorative."}}
@@ -436,21 +456,33 @@ icon slot is clearly optional (decorative leading icon)
436
456
  ### Component with multiple slots (Card)
437
457
 
438
458
  Input:
459
+
439
460
  ```json
440
461
  {
441
462
  "name": "Card",
442
463
  "props": [
443
- {"name":"title","type":"string","category":"content","required":true},
444
- {"name":"elevation","type":"'flat'|'raised'|'floating'","category":"design","defaultValue":"'raised'"}
464
+ {
465
+ "name": "title",
466
+ "type": "string",
467
+ "category": "content",
468
+ "required": true
469
+ },
470
+ {
471
+ "name": "elevation",
472
+ "type": "'flat'|'raised'|'floating'",
473
+ "category": "design",
474
+ "defaultValue": "'raised'"
475
+ }
445
476
  ],
446
477
  "slots": [
447
- {"name":"body","description":"Main card body"},
448
- {"name":"footer","description":"Optional footer area"}
478
+ { "name": "body", "description": "Main card body" },
479
+ { "name": "footer", "description": "Optional footer area" }
449
480
  ]
450
481
  }
451
482
  ```
452
483
 
453
484
  Output:
485
+
454
486
  ```
455
487
  Starting Card classification — 2 props, 2 slots
456
488
  {"tool":"classify_component","description":"Container that groups related content with a title, body, and optional footer","rationale":{"description":"Card is a molecule — it composes a title with body and footer slots into a single visual container. Useful as a building block for lists and grids of related content.","props":"Kept title (string, content) as the customer-facing label and elevation (enum, design) for the three visual depth variants. Nothing was excluded — both raw props map cleanly to CDF.","slots":"Kept both body (required, primary content area) and footer (optional, supplementary area). Body is required because a card with no body renders empty; footer is optional because many cards do not need one."}}
@@ -467,7 +499,7 @@ footer is supplementary and optional
467
499
  ### Named type (HeadingSize, ButtonVariant, etc.) — do NOT infer the values
468
500
 
469
501
  When a prop has a named TypeScript type that is not inlined as a union literal,
470
- the value set is whatever that type's declaration says. A type *name* is not
502
+ the value set is whatever that type's declaration says. A type _name_ is not
471
503
  evidence of its members: `HeadingSize` could be `h1`–`h6`, `sm|md|lg`, or
472
504
  `s|m|l|xl`. Guessing picks one design system's vocabulary and is wrong more
473
505
  often than it is right, and a wrong name matches no style rule — the author's
@@ -478,12 +510,14 @@ is not, **emit `string`** — `string` is an unrestricted enum, so the author st
478
510
  unrestricted but correct.
479
511
 
480
512
  Members visible in the source shown — copy them, do not paraphrase:
513
+
481
514
  ```
482
515
  titleSize has type HeadingSize; HeadingSize is declared in the excerpt as 'sm' | 'md' | 'lg'
483
516
  {"tool":"classify_prop","prop":"titleSize","cdf_type":"enum","cdf_category":"design","required":false,"values":["sm","md","lg"],"description":"Heading size","reason":"Copied from the HeadingSize declaration shown in the excerpt."}
484
517
  ```
485
518
 
486
519
  Members NOT visible in the source shown — degrade to `string`:
520
+
487
521
  ```
488
522
  titleSize has type HeadingSize; HeadingSize is not declared anywhere in the source shown
489
523
  no evidence for its members, so no values list — string, not a guess
@@ -517,7 +551,7 @@ Before emitting any tool calls, verify:
517
551
  5. Every `cdf_type: "token"` has `token_kind` (or a warning in `description` if lookup failed) and does **not** have `values` set
518
552
  6. No `cdf_type: "link"` — all href/url props use `string`
519
553
  7. `required` values are JSON booleans, not strings
520
- 8. Framework, DOM, accessibility, and data-* pass-through props are excluded per the inheritance principle (rule 1) — any prop inherited from an HTML-attributes base interface and not redeclared by the component, plus `aria-*` (and bare `aria`), `data-*`, polymorphic `as`/`element`/`component`, framework theming `dt`/`pt`/`ptOptions`/`unstyled`/`sx`. A prop matching an inherited-attribute name (including `title`) that the component redeclares with its own type or meaning is NOT excluded. Discrete positional/geometric props (`top`, `bottom`, `left`, `right`, `rotation`, etc.) ARE classified as `string` design props. Common semantic props (`icon`, `items`, `actions`, `options`, `value`, `name`, `form`, `inputId`, `componentId`) are NOT excluded — classify them per their content/design/state nature.
554
+ 8. Framework, DOM, accessibility, and data-_ pass-through props are excluded per the inheritance principle (rule 1) — any prop inherited from an HTML-attributes base interface and not redeclared by the component, plus `aria-_`(and bare`aria`), `data-\*`, polymorphic `as`/`element`/`component`, framework theming `dt`/`pt`/`ptOptions`/`unstyled`/`sx`. A prop matching an inherited-attribute name (including `title`) that the component redeclares with its own type or meaning is NOT excluded. Discrete positional/geometric props (`top`, `bottom`, `left`, `right`, `rotation`, etc.) ARE classified as `string` design props. Common semantic props (`icon`, `items`, `actions`, `options`, `value`, `name`, `form`, `inputId`, `componentId`) are NOT excluded — classify them per their content/design/state nature.
521
555
  9. No `cdf_type: "link"` used — `link` is reserved and rejected by the CLI parser
522
556
  10. No `cdf_type: "number"` used — this is not a supported type; use `"string"` with numeric defaults. `cdf_type: "boolean"` IS valid — use it for boolean toggle props.
523
557
  11. `classify_component` includes a `rationale` object with all three sub-fields (`rationale.description`, `rationale.props`, `rationale.slots`) populated as non-empty strings.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentful/experience-design-system-cli",
3
- "version": "2.35.0-alpha.0",
3
+ "version": "2.35.1-dev-build-041b6e0a.0",
4
4
  "description": "Contentful Experiences design system import CLI",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -9,13 +9,13 @@
9
9
  "experiences": "./bin/cli.js",
10
10
  "exo": "./bin/cli.js"
11
11
  },
12
- "main": "./dist/src/index.js",
13
- "types": "./dist/src/index.d.ts",
12
+ "main": "./dist/index.js",
14
13
  "exports": {
15
- ".": {
16
- "types": "./dist/src/index.d.ts",
17
- "import": "./dist/src/index.js",
18
- "node": "./dist/src/index.js"
14
+ ".": "./dist/index.js",
15
+ "./app": {
16
+ "types": "./dist/app.d.ts",
17
+ "import": "./dist/app.js",
18
+ "node": "./dist/app.js"
19
19
  }
20
20
  },
21
21
  "publishConfig": {
@@ -25,10 +25,10 @@
25
25
  "files": [
26
26
  "bin/",
27
27
  "dist/",
28
- "prompts/",
29
- "skills/"
28
+ "legacy/"
30
29
  ],
31
30
  "dependencies": {
31
+ "@inkjs/ui": "^2.0.0",
32
32
  "@segment/analytics-node": "^3.0.0",
33
33
  "@vue/compiler-sfc": "^3.5.31",
34
34
  "commander": "^13.1.0",
@@ -37,25 +37,22 @@
37
37
  "ink": "^5.2.1",
38
38
  "react": "^18.3.1",
39
39
  "react-devtools-core": "^4.19.1",
40
+ "semver": "^7.7.2",
40
41
  "svelte": "^5.56.4",
41
42
  "ts-morph": "^27.0.2",
42
43
  "typescript": "^5.9.3",
43
- "@contentful/experience-design-system-types": "2.35.0-alpha.0",
44
- "@contentful/experience-design-system-cli-v2": "2.35.0-alpha.0"
44
+ "@contentful/experience-design-system-types": "2.35.1-dev-build-041b6e0a.0"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@tsconfig/node24": "^24.0.4",
48
48
  "@types/node": "^24.0.3",
49
49
  "@types/react": "^18.3.24",
50
+ "@types/semver": "^7.7.1",
50
51
  "eslint": "^9.39.5",
51
52
  "eslint-config-prettier": "^10.1.8",
52
53
  "eslint-plugin-prettier": "^5.5.6",
53
- "ink-testing-library": "^4.0.0",
54
54
  "typescript-eslint": "^8.67.0",
55
- "vitest": "^4.0.16",
56
- "@contentful/experience-design-system-extraction": "2.35.0-alpha.0",
57
- "@contentful/experience-design-system-client": "2.35.0-alpha.0",
58
- "@contentful/experience-design-system-generation": "2.35.0-alpha.0"
55
+ "vitest": "^4.0.16"
59
56
  },
60
57
  "repository": {
61
58
  "type": "git",
@@ -74,7 +71,6 @@
74
71
  "typecheck": "nx typecheck experience-design-system-cli",
75
72
  "clean": "nx clean experience-design-system-cli",
76
73
  "test": "nx test experience-design-system-cli",
77
- "test:watch": "nx test:watch experience-design-system-cli",
78
74
  "lint": "nx lint experience-design-system-cli",
79
75
  "lint:fix": "nx lint:fix experience-design-system-cli"
80
76
  }