@astryxdesign/cli 0.7.17-canary.g49a475f → 0.7.17-canary.g5a3fd39
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.
- package/README.md +14 -9
- package/api/build/_adapter.d.mts +33 -4
- package/api/build/_adapter.mjs +43 -8
- package/api/build/blocks/blocks.d.mts +1 -0
- package/api/build/blocks/blocks.mjs +2 -1
- package/api/build/blocks/blocks.weights.json +1 -1
- package/api/build/build.doc.mjs +2 -2
- package/api/build/build.type.d.mts +13 -1
- package/api/build/build.type.mjs +6 -3
- package/api/build/kit/kind.d.mts +6 -0
- package/api/build/kit/kind.mjs +1 -1
- package/api/build/kit/kit.mjs +3 -3
- package/api/build/kit/rank.d.mts +9 -3
- package/api/build/kit/rank.mjs +21 -8
- package/api/build/kit/signals.d.mts +7 -1
- package/api/build/kit/signals.mjs +124 -41
- package/api/build/kit/start.d.mts +20 -5
- package/api/build/kit/start.mjs +103 -23
- package/api/build/kit/weights.d.mts +20 -4
- package/api/build/kit/weights.json +1 -1
- package/api/build/kit/weights.mjs +68 -18
- package/api/build/kit/words.d.mts +44 -2
- package/api/build/kit/words.mjs +159 -4
- package/api/build/tree.mjs +1 -1
- package/api/component/__fixtures__/resolutions/modules.txt +4 -4
- package/api/component/_adapter.d.mts +51 -20
- package/api/component/_adapter.mjs +198 -29
- package/api/component/component.mjs +18 -5
- package/api/component/component.type.d.mts +4 -0
- package/api/component/component.type.mjs +1 -0
- package/api/component/detail/blocks/blocks.mjs +1 -0
- package/api/component/detail/detail.d.mts +2 -2
- package/api/component/detail/detail.mjs +1 -1
- package/api/component/list/list.d.mts +2 -2
- package/api/component/list/list.mjs +4 -4
- package/api/discover/_adapter.d.mts +10 -0
- package/api/discover/_adapter.mjs +110 -16
- package/api/discover/detail/item/item.mjs +5 -0
- package/api/discover/discover.mjs +12 -3
- package/api/discover/discover.type.d.mts +16 -3
- package/api/discover/discover.type.mjs +13 -3
- package/api/docs/_adapter.d.mts +74 -30
- package/api/docs/_adapter.mjs +488 -234
- package/api/docs/_entry-names-lazily.d.mts +22 -0
- package/api/docs/_entry-names-lazily.mjs +25 -0
- package/api/docs/_entry-names.d.mts +23 -0
- package/api/docs/_entry-names.mjs +105 -0
- package/api/doctor/_adapter.d.mts +63 -2
- package/api/doctor/_adapter.mjs +141 -5
- package/api/doctor/doctor.d.mts +11 -0
- package/api/doctor/doctor.doc.mjs +1 -1
- package/api/doctor/doctor.mjs +81 -30
- package/api/doctor/theme-checks.d.mts +35 -3
- package/api/doctor/theme-checks.mjs +449 -99
- package/api/error.d.mts +4 -3
- package/api/error.mjs +3 -2
- package/api/hook/_adapter.d.mts +14 -7
- package/api/hook/_adapter.mjs +46 -9
- package/api/hook/detail/detail.mjs +5 -2
- package/api/hook/detail/params/params.mjs +10 -3
- package/api/icon/_options.d.mts +17 -0
- package/api/icon/_options.mjs +54 -0
- package/api/icon/exportIconIndex.doc.d.mts +10 -0
- package/api/icon/exportIconIndex.doc.mjs +59 -0
- package/api/icon/icon.mjs +11 -34
- package/api/icon/icon.type.d.mts +49 -0
- package/api/icon/icon.type.mjs +24 -0
- package/api/icon/rankIconIndex.doc.d.mts +10 -0
- package/api/icon/rankIconIndex.doc.mjs +79 -0
- package/api/icon/search/icon-index.d.mts +41 -0
- package/api/icon/search/icon-index.mjs +139 -0
- package/api/icon/search/search.d.mts +18 -0
- package/api/icon/search/search.mjs +13 -0
- package/api/index.d.mts +1 -0
- package/api/index.mjs +1 -0
- package/api/integration/add-helpers.mjs +10 -0
- package/api/integration/authoring-checks.mjs +5 -2
- package/api/integration/check/check.mjs +6 -1
- package/api/integration/pack-check.mjs +50 -3
- package/api/integration/validate-integration.d.mts +18 -6
- package/api/integration/validate-integration.mjs +110 -14
- package/api/integration/validate-integration.type.d.mts +13 -0
- package/api/integration/validate-integration.type.mjs +2 -1
- package/api/integration/validateIntegration.doc.mjs +1 -1
- package/api/render/render.type.d.mts +1 -1
- package/api/render/render.type.mjs +1 -1
- package/api/search/ORDERING.md +1 -1
- package/api/search/_adapter.d.mts +8 -5
- package/api/search/_adapter.mjs +14 -10
- package/api/search/_candidate-score.d.mts +9 -4
- package/api/search/_candidate-score.mjs +82 -14
- package/api/search/_gather-components.d.mts +4 -4
- package/api/search/_gather-components.mjs +4 -3
- package/api/search/_gather-hooks.d.mts +2 -2
- package/api/search/_gather-hooks.mjs +1 -1
- package/api/search/_gather-templates.mjs +1 -0
- package/api/search/_lexical.d.mts +16 -0
- package/api/search/_lexical.mjs +98 -10
- package/api/search/_priority.d.mts +10 -2
- package/api/search/_priority.mjs +37 -7
- package/api/search/_result.d.mts +1 -0
- package/api/search/_result.mjs +1 -0
- package/api/search/_score.d.mts +12 -3
- package/api/search/_score.mjs +6 -3
- package/api/search/_words.mjs +12 -3
- package/api/search/search.d.mts +7 -1
- package/api/search/search.doc.mjs +1 -1
- package/api/search/search.mjs +37 -4
- package/api/search/search.type.d.mts +4 -0
- package/api/search/search.type.mjs +1 -0
- package/api/swizzle/_adapter.d.mts +7 -5
- package/api/swizzle/_adapter.mjs +22 -6
- package/api/swizzle/copy/copy.mjs +5 -4
- package/api/template/_adapter.d.mts +16 -0
- package/api/template/_adapter.mjs +39 -2
- package/api/template/cdn/cdn.mjs +37 -8
- package/api/template/copy/copy.d.mts +6 -3
- package/api/template/copy/copy.mjs +83 -8
- package/api/template/show/show.mjs +1 -0
- package/api/template/skeleton/skeleton.mjs +1 -0
- package/api/template/template.doc.mjs +5 -5
- package/api/template/template.mjs +63 -11
- package/api/template/template.type.d.mts +4 -0
- package/api/template/template.type.mjs +5 -1
- package/api/theme/_adapter.d.mts +20 -1
- package/api/theme/_adapter.mjs +149 -12
- package/api/theme/_app-provider.d.mts +31 -0
- package/api/theme/_app-provider.mjs +135 -0
- package/api/theme/add/add.mjs +3 -1
- package/api/theme/build/build.d.mts +127 -11
- package/api/theme/build/build.mjs +2047 -352
- package/api/theme/build/core-interception.d.mts +10 -0
- package/api/theme/build/core-interception.mjs +10 -0
- package/api/theme/build/family.mjs +61 -21
- package/api/theme/build/font-warning.d.mts +99 -5
- package/api/theme/build/font-warning.mjs +379 -61
- package/api/theme/build/icon-imports.mjs +83 -15
- package/api/theme/build/input-fields.d.mts +110 -0
- package/api/theme/build/input-fields.mjs +667 -0
- package/api/theme/build/null-values.d.mts +42 -0
- package/api/theme/build/null-values.mjs +283 -0
- package/api/theme/build/self-contained.d.mts +90 -0
- package/api/theme/build/self-contained.mjs +380 -0
- package/api/theme/build/source-syntax.d.mts +11 -0
- package/api/theme/build/source-syntax.mjs +28 -0
- package/api/theme/build/style-keys.d.mts +72 -0
- package/api/theme/build/style-keys.mjs +589 -0
- package/api/theme/build/typography-values.d.mts +61 -0
- package/api/theme/build/typography-values.mjs +408 -0
- package/api/theme/build/written-values.d.mts +78 -0
- package/api/theme/build/written-values.mjs +482 -0
- package/api/theme/generateTonalPalette.doc.mjs +1 -1
- package/api/theme/list/list.mjs +17 -1
- package/api/theme/palette/generate/generator.d.mts +14 -2
- package/api/theme/palette/generate/generator.mjs +94 -8
- package/api/theme/remove/remove.d.mts +2 -1
- package/api/theme/remove/remove.mjs +7 -3
- package/api/theme/theme.type.d.mts +89 -5
- package/api/theme/theme.type.mjs +46 -7
- package/api/theme/themeAdd.doc.mjs +1 -1
- package/api/theme/themeBuild.doc.mjs +1 -1
- package/api/theme/themeListAvailable.doc.mjs +1 -1
- package/api/theme/themePaletteGenerate.doc.mjs +1 -1
- package/api/theme/themeRemove.doc.mjs +8 -5
- package/api/theme/themeTemplate.doc.mjs +18 -3
- package/api/theme-edit/_adapter.d.mts +57 -4
- package/api/theme-edit/_adapter.mjs +380 -73
- package/api/theme-edit/_catalog.d.mts +82 -4
- package/api/theme-edit/_catalog.mjs +397 -24
- package/api/theme-edit/_check.d.mts +153 -2
- package/api/theme-edit/_check.mjs +3028 -563
- package/api/theme-edit/_color.d.mts +27 -2
- package/api/theme-edit/_color.mjs +66 -8
- package/api/theme-edit/_compiler.d.mts +7 -2
- package/api/theme-edit/_compiler.mjs +335 -21
- package/api/theme-edit/_context.d.mts +192 -7
- package/api/theme-edit/_context.mjs +750 -70
- package/api/theme-edit/_css.d.mts +32 -0
- package/api/theme-edit/_css.mjs +121 -34
- package/api/theme-edit/_edit.d.mts +68 -5
- package/api/theme-edit/_edit.mjs +5119 -667
- package/api/theme-edit/_how-commands.d.mts +28 -1
- package/api/theme-edit/_how-commands.mjs +621 -17
- package/api/theme-edit/_how-question.d.mts +101 -9
- package/api/theme-edit/_how-question.mjs +13901 -1282
- package/api/theme-edit/_how.d.mts +13 -2
- package/api/theme-edit/_how.mjs +389 -32
- package/api/theme-edit/_importers.d.mts +38 -0
- package/api/theme-edit/_importers.mjs +188 -0
- package/api/theme-edit/_missed.d.mts +54 -0
- package/api/theme-edit/_missed.mjs +917 -0
- package/api/theme-edit/_normal.d.mts +110 -21
- package/api/theme-edit/_normal.mjs +700 -105
- package/api/theme-edit/_palette.d.mts +77 -0
- package/api/theme-edit/_palette.mjs +364 -73
- package/api/theme-edit/_part-words.d.mts +39 -0
- package/api/theme-edit/_part-words.mjs +191 -0
- package/api/theme-edit/_parts.d.mts +74 -4
- package/api/theme-edit/_parts.mjs +677 -73
- package/api/theme-edit/_preview-app.d.mts +8 -13
- package/api/theme-edit/_preview-app.mjs +1189 -559
- package/api/theme-edit/_preview.d.mts +151 -10
- package/api/theme-edit/_preview.mjs +785 -98
- package/api/theme-edit/_project.d.mts +38 -3
- package/api/theme-edit/_project.mjs +135 -8
- package/api/theme-edit/_settings.d.mts +678 -83
- package/api/theme-edit/_settings.mjs +6037 -1051
- package/api/theme-edit/_tables.d.mts +43 -3
- package/api/theme-edit/_tables.mjs +244 -59
- package/api/theme-edit/_vet.d.mts +14 -1
- package/api/theme-edit/_vet.mjs +86 -12
- package/api/theme-edit/theme-edit.type.d.mts +53 -3
- package/api/theme-edit/theme-edit.type.mjs +23 -5
- package/api/theme-edit/themeEditPreviewApp.doc.mjs +1 -1
- package/api/upgrade/_adapter.mjs +13 -2
- package/api/upgrade/upgrade.mjs +16 -1
- package/assets/codemods/integration-runner.mjs +1 -1
- package/assets/codemods/jscodeshift.d.ts +1 -1
- package/assets/codemods/parse.mjs +2 -2
- package/assets/codemods/run-codemod.mjs +71 -18
- package/assets/codemods/runner.mjs +1 -4
- package/assets/component-list.generated.json +1 -1
- package/assets/docs/author-a-theme.doc.mjs +1 -0
- package/assets/docs/theme.doc.dense.mjs +86 -7
- package/assets/docs/theme.doc.mjs +76 -2
- package/assets/docs/theme.doc.zh.mjs +61 -1
- package/assets/docs/tree/authoring.doc.mjs +1 -0
- package/assets/docs/tree/checks.doc.mjs +2 -2
- package/assets/docs/tree/cli.doc.mjs +1 -0
- package/assets/docs/tree/computer-agent-guide.doc.mjs +1 -1
- package/assets/docs/tree/document-the-theme.doc.mjs +1 -1
- package/assets/docs/tree/font-setup.doc.mjs +1 -1
- package/assets/docs/tree/fonts-and-assets.doc.mjs +1 -1
- package/assets/docs/tree/generate-a-palette.doc.mjs +2 -2
- package/assets/docs/tree/global.doc.mjs +1 -0
- package/assets/docs/tree/install-once.doc.mjs +1 -1
- package/assets/docs/tree/problems.doc.mjs +1 -1
- package/assets/docs/tree/render-pages.doc.mjs +2 -2
- package/assets/docs/tree/share-a-page.doc.mjs +162 -0
- package/assets/docs/tree/single-component.doc.mjs +40 -2
- package/assets/docs/tree/updates.doc.mjs +1 -1
- package/assets/docs/tree/who-answers.doc.mjs +3 -3
- package/assets/docs/tree/write-good-templates.doc.mjs +1 -1
- package/assets/docs/use-a-theme.doc.mjs +1 -1
- package/assets/docs-routes.generated.json +1 -0
- package/assets/docs.generated.json +2 -2
- package/assets/search-catalog.generated.json +2 -2
- package/assets/self-audit.generated.json +1 -1
- package/assets/templates/blocks/components/Blockquote/BlockquoteShowcase.tsx +1 -1
- package/assets/templates/blocks/components/BreadcrumbItem/BreadcrumbItemShowcase.tsx +4 -4
- package/assets/templates/blocks/components/Breadcrumbs/BreadcrumbsCustomSeparator.tsx +1 -0
- package/assets/templates/blocks/components/Breadcrumbs/BreadcrumbsSupportingVariant.tsx +2 -2
- package/assets/templates/blocks/components/Card/CardElevations.tsx +1 -1
- package/assets/templates/blocks/components/Card/CardWithInnerLayout.tsx +19 -3
- package/assets/templates/blocks/components/Card/ClickableCardWithNestedButton.tsx +11 -1
- package/assets/templates/blocks/components/Card/SelectableCardElevated.tsx +1 -1
- package/assets/templates/blocks/components/Card/SelectableCardMulti.tsx +1 -1
- package/assets/templates/blocks/components/Center/CenterHorizontal.tsx +1 -1
- package/assets/templates/blocks/components/Center/CenterInsideACard.tsx +1 -1
- package/assets/templates/blocks/components/ChatComposer/ChatComposerFullFeatured.tsx +8 -0
- package/assets/templates/blocks/components/ChatComposerDrawer/ChatComposerDrawerWithProgress.tsx +8 -2
- package/assets/templates/blocks/components/ChatComposerInput/useChatPasteAsTokenHookUsage.doc.mjs +14 -0
- package/assets/templates/blocks/components/ChatComposerInput/useChatPasteAsTokenHookUsage.tsx +32 -0
- package/assets/templates/blocks/components/ChatComposerInput/useSpeechRecognitionHookUsage.doc.mjs +14 -0
- package/assets/templates/blocks/components/ChatComposerInput/useSpeechRecognitionHookUsage.tsx +43 -0
- package/assets/templates/blocks/components/ChatLayout/ChatLayoutPanelChat.tsx +1 -0
- package/assets/templates/blocks/components/ChatLayout/ChatLayoutShowcase.tsx +1 -1
- package/assets/templates/blocks/components/ChatMessageBubble/ChatMessageBubbleCustomContent.tsx +9 -1
- package/assets/templates/blocks/components/ChatMessageBubble/ChatMessageBubbleMetadata.tsx +12 -2
- package/assets/templates/blocks/components/ChatMessageMetadata/ChatMessageMetadataFooter.tsx +28 -7
- package/assets/templates/blocks/components/ChatMessageMetadata/ChatMessageMetadataShowcase.tsx +35 -7
- package/assets/templates/blocks/components/Collapsible/CollapsibleShowcase.tsx +1 -1
- package/assets/templates/blocks/components/CommandPaletteGroup/CommandPaletteGroupBasic.tsx +20 -4
- package/assets/templates/blocks/components/CommandPaletteList/CommandPaletteListBasic.tsx +15 -3
- package/assets/templates/blocks/components/CommandPaletteList/CommandPaletteListShowcase.tsx +29 -6
- package/assets/templates/blocks/components/ContextMenu/ContextMenuBasic.tsx +2 -2
- package/assets/templates/blocks/components/ContextMenu/ContextMenuBottomSheet.tsx +1 -1
- package/assets/templates/blocks/components/ContextMenu/ContextMenuShowcase.tsx +2 -2
- package/assets/templates/blocks/components/Divider/DividerFullBleed.tsx +1 -1
- package/assets/templates/blocks/components/Divider/DividerShowcase.tsx +1 -1
- package/assets/templates/blocks/components/Divider/DividerVariants.tsx +1 -1
- package/assets/templates/blocks/components/DropdownMenuGroup/DropdownMenuGroupShowcase.tsx +23 -4
- package/assets/templates/blocks/components/EmptyState/EmptyStateActions.tsx +18 -2
- package/assets/templates/blocks/components/EmptyState/EmptyStateCompact.tsx +20 -2
- package/assets/templates/blocks/components/EmptyState/EmptyStateContainer.tsx +16 -2
- package/assets/templates/blocks/components/EmptyState/EmptyStateShowcase.tsx +11 -1
- package/assets/templates/blocks/components/Heading/HeadingTruncation.tsx +12 -2
- package/assets/templates/blocks/components/InternationalizationProvider/useDirectionHookUsage.tsx +1 -1
- package/assets/templates/blocks/components/LayoutContent/LayoutContentBasic.tsx +1 -1
- package/assets/templates/blocks/components/LayoutContent/LayoutContentShowcase.tsx +1 -1
- package/assets/templates/blocks/components/LayoutFooter/LayoutFooterActions.tsx +17 -3
- package/assets/templates/blocks/components/LayoutFooter/LayoutFooterShowcase.tsx +17 -3
- package/assets/templates/blocks/components/LayoutHeader/LayoutHeaderShowcase.tsx +15 -3
- package/assets/templates/blocks/components/LayoutHeader/LayoutHeaderWithActions.tsx +9 -2
- package/assets/templates/blocks/components/LayoutPanel/LayoutPanelNavigation.tsx +1 -1
- package/assets/templates/blocks/components/LayoutPanel/LayoutPanelShowcase.tsx +1 -1
- package/assets/templates/blocks/components/MoreMenu/MoreMenuBottomSheet.tsx +1 -1
- package/assets/templates/blocks/components/MultiSelector/MultiSelectorGhostToolbar.tsx +14 -2
- package/assets/templates/blocks/components/Outline/OutlineDensity.tsx +2 -0
- package/assets/templates/blocks/components/OverflowList/OverflowListShowcase.tsx +6 -1
- package/assets/templates/blocks/components/Pagination/PaginationVariants.tsx +4 -0
- package/assets/templates/blocks/components/Popover/PopoverHookUsage.tsx +17 -2
- package/assets/templates/blocks/components/SegmentedControl/SegmentedControlFillLayout.tsx +1 -1
- package/assets/templates/blocks/components/Selector/SelectorGhostToolbar.tsx +14 -2
- package/assets/templates/blocks/components/Selector/SelectorOptionDescriptions.tsx +8 -1
- package/assets/templates/blocks/components/SideNav/SideNavWithHeaderMenu.tsx +2 -2
- package/assets/templates/blocks/components/SideNavHeading/SideNavHeadingShowcase.tsx +2 -0
- package/assets/templates/blocks/components/Switch/SwitchWithStatus.tsx +1 -1
- package/assets/templates/blocks/components/TabList/TabListTabsFillLayout.tsx +1 -1
- package/assets/templates/blocks/components/TabList/TabListTabsWithActions.tsx +12 -1
- package/assets/templates/blocks/components/Table/TableBulkActionsTable.tsx +11 -1
- package/assets/templates/blocks/components/Table/TableInCard.tsx +2 -2
- package/assets/templates/blocks/components/Text/TextTruncation.tsx +1 -1
- package/assets/templates/blocks/components/Text/TextWordBreak.tsx +12 -2
- package/assets/templates/blocks/components/Text/TextWrap.tsx +19 -4
- package/assets/templates/blocks/components/TextArea/TextAreaCharacterCount.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaShowcase.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaStates.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaValidation.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaWithIcon.tsx +1 -1
- package/assets/templates/blocks/components/TextInput/TextInputStatusVariant.tsx +2 -2
- package/assets/templates/blocks/components/Timestamp/TimestampAutoFormat.tsx +15 -1
- package/assets/templates/blocks/components/Timestamp/TimestampRelativeFormat.tsx +15 -1
- package/assets/templates/blocks/components/Toolbar/ToolbarCardHeader.tsx +8 -0
- package/assets/templates/blocks/components/Toolbar/ToolbarSizes.tsx +12 -1
- package/assets/templates/blocks/components/Toolbar/ToolbarThreeSlot.tsx +18 -3
- package/assets/templates/blocks/components/TopNav/TopNavCenteredNavigation.tsx +6 -0
- package/assets/templates/blocks/components/TopNav/TopNavEnterpriseDashboard.tsx +7 -1
- package/assets/templates/blocks/components/TopNav/TopNavMegaMenu.tsx +2 -2
- package/assets/templates/blocks/components/TopNav/TopNavShowcase.tsx +9 -0
- package/assets/templates/components.generated.json +1 -1
- package/assets/templates/pages/ai-chat/page.tsx +102 -6
- package/assets/templates/pages/ai-chat-landing/page.tsx +31 -4
- package/assets/templates/pages/ai-chat-landing/template.doc.mjs +3 -0
- package/assets/templates/pages/canvas-editor/page.tsx +73 -2
- package/assets/templates/pages/centered-hero/page.tsx +10 -4
- package/assets/templates/pages/course-detail/page.tsx +46 -2
- package/assets/templates/pages/dashboard/page.tsx +45 -16
- package/assets/templates/pages/dashboard-alert-rail/page.tsx +1 -1
- package/assets/templates/pages/dashboard-cohort-funnel/page.tsx +32 -21
- package/assets/templates/pages/dashboard-comparison/page.tsx +11 -2
- package/assets/templates/pages/dashboard-composition/page.tsx +22 -9
- package/assets/templates/pages/dashboard-progress/page.tsx +28 -16
- package/assets/templates/pages/dashboard-scorecard/page.tsx +9 -0
- package/assets/templates/pages/detail-page/page.tsx +157 -76
- package/assets/templates/pages/documentation/page.tsx +15 -2
- package/assets/templates/pages/documentation-design/page.tsx +7 -34
- package/assets/templates/pages/documentation-technical/page.tsx +122 -65
- package/assets/templates/pages/editor/page.tsx +41 -24
- package/assets/templates/pages/file-explorer/page.tsx +44 -1
- package/assets/templates/pages/form-two-column/page.tsx +2 -3
- package/assets/templates/pages/form-wizard/page.tsx +31 -3
- package/assets/templates/pages/form-wizard-vertical/page.tsx +55 -6
- package/assets/templates/pages/gallery-hero/page.tsx +2 -1
- package/assets/templates/pages/ide/page.tsx +23 -0
- package/assets/templates/pages/ide/template.doc.mjs +1 -1
- package/assets/templates/pages/incident-console/page.tsx +130 -30
- package/assets/templates/pages/incident-console/template.doc.mjs +2 -2
- package/assets/templates/pages/kanban-board/page.tsx +50 -3
- package/assets/templates/pages/login-card/page.tsx +16 -0
- package/assets/templates/pages/login-split/page.tsx +19 -6
- package/assets/templates/pages/messaging-shell/page.tsx +409 -419
- package/assets/templates/pages/messaging-shell/template.doc.mjs +6 -6
- package/assets/templates/pages/payment-form/page.tsx +107 -43
- package/assets/templates/pages/product-detail/page.tsx +26 -2
- package/assets/templates/pages/product-gallery/page.tsx +16 -14
- package/assets/templates/pages/settings/page.tsx +35 -3
- package/assets/templates/pages/settings-dialog/page.tsx +196 -17
- package/assets/templates/pages/settings-sidebar/page.tsx +23 -3
- package/assets/templates/pages/shell-nav/page.tsx +28 -12
- package/assets/templates/pages/shell-side-nav/page.tsx +27 -4
- package/assets/templates/pages/shell-top-nav/page.tsx +27 -1
- package/assets/templates/pages/side-gallery/page.tsx +1 -1
- package/assets/templates/pages/table/page.tsx +575 -61
- package/assets/templates/pages/table/template.doc.mjs +11 -1
- package/assets/templates/pages/table-collapsible/page.tsx +1 -1
- package/assets/templates/pages/table-comparison/page.tsx +1 -1
- package/assets/templates/pages/table-filter/page.tsx +17 -1
- package/assets/templates/pages/table-grouped/page.tsx +171 -133
- package/assets/templates/pages/table-inbox/page.tsx +60 -1
- package/assets/templates/pages/table-page/page.tsx +23 -2
- package/assets/templates/pages/table-tree/page.tsx +95 -13
- package/assets/templates/pages/theme-showcase/page.tsx +107 -11
- package/assets/templates/pages/work-item-detail/page.tsx +134 -80
- package/assets/templates/pages/work-item-detail/template.doc.mjs +0 -1
- package/assets/templates/themes/gothic/gothicPaletteRefs.generated.ts +1 -1
- package/assets/templates/themes/gothic/gothicTheme.ts +5 -0
- package/assets/templates/themes/neutral/neutralTheme.ts +1 -1
- package/assets/templates/themes/y2k/y2kPaletteRefs.generated.ts +1 -1
- package/assets/templates/themes/y2k/y2kTheme.ts +1 -1
- package/assets/theme.template.ts +3 -2
- package/authoring/debug/parse.d.mts +1 -1
- package/authoring/doctypes/_schema.d.mts +28 -14
- package/authoring/doctypes/_schema.mjs +31 -0
- package/authoring/doctypes/command/command.doc.mjs +24 -0
- package/authoring/doctypes/command/type.ts +31 -0
- package/authoring/doctypes/component/component.doc.mjs +1 -1
- package/authoring/doctypes/component/type.ts +8 -5
- package/authoring/doctypes/namespace/namespace.doc.mjs +6 -0
- package/authoring/doctypes/namespace/type.ts +4 -0
- package/authoring/doctypes/template/template.doc.mjs +1 -1
- package/authoring/doctypes/template/type.ts +1 -1
- package/authoring/index.d.ts +6 -1
- package/authoring/integration/integration.doc.mjs +15 -0
- package/authoring/integration/schema.d.mts +30 -1
- package/authoring/integration/schema.mjs +129 -4
- package/authoring/integration/type.ts +48 -0
- package/clients/cli/bin/astryx.mjs +9 -3
- package/clients/cli/build-id.generated.json +1 -1
- package/clients/cli/commands/build.mjs +17 -5
- package/clients/cli/commands/component.doc.mjs +1 -0
- package/clients/cli/commands/component.mjs +107 -42
- package/clients/cli/commands/discover.mjs +70 -3
- package/clients/cli/commands/docs.doc.mjs +1 -1
- package/clients/cli/commands/docs.mjs +41 -5
- package/clients/cli/commands/doctor.mjs +52 -2
- package/clients/cli/commands/experimental/index.mjs +4 -1
- package/clients/cli/commands/experimental/theme.mjs +1504 -186
- package/clients/cli/commands/experimental-render.doc.mjs +18 -5
- package/clients/cli/commands/experimental-theme-add.doc.mjs +2 -0
- package/clients/cli/commands/experimental-theme-compile.doc.mjs +3 -2
- package/clients/cli/commands/experimental-theme-editor-how.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-editor-new.doc.mjs +3 -1
- package/clients/cli/commands/experimental-theme-editor-set.doc.mjs +4 -3
- package/clients/cli/commands/experimental-theme-editor-show.doc.mjs +3 -2
- package/clients/cli/commands/experimental-theme-editor-undo.doc.mjs +5 -4
- package/clients/cli/commands/experimental-theme-eject.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-preview-add.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-preview-app.doc.mjs +3 -2
- package/clients/cli/commands/experimental-theme-remove.doc.mjs +6 -4
- package/clients/cli/commands/experimental-theme-targets.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-template.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-use.doc.mjs +2 -0
- package/clients/cli/commands/gap-report.doc.mjs +1 -0
- package/clients/cli/commands/hook.doc.mjs +1 -1
- package/clients/cli/commands/init.doc.mjs +1 -1
- package/clients/cli/commands/init.mjs +14 -6
- package/clients/cli/commands/integration-add.doc.mjs +1 -0
- package/clients/cli/commands/manifest.mjs +10 -3
- package/clients/cli/commands/search.mjs +13 -1
- package/clients/cli/commands/swizzle.doc.mjs +9 -2
- package/clients/cli/commands/swizzle.mjs +13 -6
- package/clients/cli/commands/template.doc.mjs +4 -1
- package/clients/cli/commands/template.mjs +34 -7
- package/clients/cli/commands/theme-add.doc.mjs +3 -2
- package/clients/cli/commands/theme-build.doc.mjs +11 -2
- package/clients/cli/commands/theme-eject.doc.mjs +1 -1
- package/clients/cli/commands/theme-list.doc.mjs +1 -1
- package/clients/cli/commands/theme-palette-generate.doc.mjs +3 -2
- package/clients/cli/commands/theme-remove.doc.mjs +15 -6
- package/clients/cli/commands/theme-targets.doc.mjs +1 -0
- package/clients/cli/commands/theme-template.doc.mjs +1 -0
- package/clients/cli/commands/theme-use.doc.mjs +2 -1
- package/clients/cli/commands/theme.doc.mjs +7 -2
- package/clients/cli/commands/theme.mjs +824 -576
- package/clients/cli/commands/upgrade.mjs +7 -3
- package/clients/cli/index.mjs +177 -78
- package/clients/cli/lib/base-gate.mjs +522 -0
- package/clients/cli/lib/cli-error.mjs +21 -0
- package/clients/cli/lib/command-path.mjs +26 -0
- package/clients/cli/lib/define-command.mjs +161 -12
- package/clients/cli/lib/json-shim.mjs +679 -40
- package/clients/cli/lib/manifest.d.ts +14 -0
- package/clients/cli/lib/manifest.mjs +78 -22
- package/clients/cli/lib/not-ready.mjs +22 -0
- package/clients/cli/lib/root-args.mjs +79 -0
- package/clients/cli/lib/stray-option.mjs +491 -0
- package/clients/cli/lib/unknown-command.mjs +374 -0
- package/clients/cli/manifest.generated.json +1 -1
- package/clients/cli/run.mjs +39 -3
- package/foundation/agent-docs/agent-docs.mjs +1 -1
- package/foundation/agent-docs/computer-agent-text.mjs +1 -1
- package/foundation/bases/core-docs.d.mts +10 -0
- package/foundation/bases/core-docs.mjs +42 -0
- package/foundation/bases/core.d.mts +11 -0
- package/foundation/bases/core.mjs +32 -0
- package/foundation/bases/requirements.d.mts +128 -0
- package/foundation/bases/requirements.mjs +193 -0
- package/foundation/bases/resolve.d.mts +134 -0
- package/foundation/bases/resolve.mjs +295 -0
- package/foundation/bases/state.d.mts +24 -0
- package/foundation/bases/state.mjs +46 -0
- package/foundation/bases/steps.d.mts +49 -0
- package/foundation/bases/steps.mjs +88 -0
- package/foundation/config/project.d.mts +22 -0
- package/foundation/config/project.mjs +94 -30
- package/foundation/config/theme-build-header.d.mts +14 -0
- package/foundation/config/theme-build-header.mjs +14 -0
- package/foundation/config/theme-private-vars.d.mts +26 -2
- package/foundation/config/theme-private-vars.mjs +65 -5
- package/foundation/config/theme-state.d.mts +19 -2
- package/foundation/config/theme-state.mjs +93 -1
- package/foundation/debug/event.d.mts +8 -2
- package/foundation/debug/event.mjs +6 -7
- package/foundation/debug/recorder.d.mts +8 -1
- package/foundation/debug/recorder.mjs +8 -2
- package/foundation/discovery/cli-self-doc-names.d.mts +13 -0
- package/foundation/discovery/cli-self-doc-names.mjs +51 -0
- package/foundation/discovery/cli-self-docs.d.mts +0 -2
- package/foundation/discovery/cli-self-docs.mjs +11 -16
- package/foundation/discovery/command-pointers.d.mts +28 -0
- package/foundation/discovery/command-pointers.mjs +31 -0
- package/foundation/discovery/component-discovery.d.mts +9 -8
- package/foundation/discovery/component-discovery.mjs +12 -6
- package/foundation/discovery/core-component-docs.d.mts +29 -0
- package/foundation/discovery/core-component-docs.mjs +83 -0
- package/foundation/discovery/core-theme-facts.d.mts +70 -0
- package/foundation/discovery/core-theme-facts.mjs +384 -0
- package/foundation/discovery/docs-discovery.d.mts +84 -9
- package/foundation/discovery/docs-discovery.mjs +151 -60
- package/foundation/discovery/entry-name-files.d.mts +72 -9
- package/foundation/discovery/entry-name-files.mjs +193 -103
- package/foundation/discovery/hook-discovery.d.mts +16 -6
- package/foundation/discovery/hook-discovery.mjs +82 -43
- package/foundation/discovery/integration-component-views.d.mts +15 -0
- package/foundation/discovery/integration-component-views.mjs +91 -0
- package/foundation/discovery/module-exports.d.mts +26 -1
- package/foundation/discovery/module-exports.mjs +114 -40
- package/foundation/discovery/name-roots.d.mts +38 -0
- package/foundation/discovery/name-roots.mjs +108 -0
- package/foundation/discovery/next-routes.d.mts +48 -0
- package/foundation/discovery/next-routes.mjs +197 -0
- package/foundation/discovery/stored-self-audit.mjs +2 -0
- package/foundation/discovery/template-adapter.d.mts +31 -63
- package/foundation/discovery/template-adapter.mjs +38 -207
- package/foundation/discovery/template-destination.d.mts +28 -0
- package/foundation/discovery/template-destination.mjs +106 -0
- package/foundation/discovery/template-ids.d.mts +69 -0
- package/foundation/discovery/template-ids.mjs +203 -0
- package/foundation/discovery/template-needs.mjs +3 -1
- package/foundation/discovery/theme-discovery.d.mts +12 -0
- package/foundation/discovery/theme-discovery.mjs +34 -2
- package/foundation/discovery/theme-imports.d.mts +10 -0
- package/foundation/discovery/theme-imports.mjs +37 -4
- package/foundation/discovery/theming-targets.d.mts +13 -5
- package/foundation/discovery/theming-targets.mjs +38 -45
- package/foundation/doc-compiler/generated-levels.d.mts +43 -0
- package/foundation/doc-compiler/generated-levels.mjs +72 -0
- package/foundation/doc-compiler/literal-doc.d.mts +12 -0
- package/foundation/doc-compiler/literal-doc.mjs +322 -0
- package/foundation/doc-compiler/stored-docs.d.mts +7 -0
- package/foundation/doc-compiler/stored-docs.mjs +14 -1
- package/foundation/doc-compiler/tree.d.mts +18 -87
- package/foundation/doc-compiler/tree.mjs +57 -64
- package/foundation/env/intl-defaults.d.mts +39 -0
- package/foundation/env/intl-defaults.mjs +150 -0
- package/foundation/env/intl-now.d.mts +21 -0
- package/foundation/env/intl-now.mjs +25 -0
- package/foundation/env/package-manager.d.mts +11 -2
- package/foundation/env/package-manager.mjs +28 -4
- package/foundation/fonts/font-stylesheet.d.mts +38 -0
- package/foundation/fonts/font-stylesheet.mjs +128 -12
- package/foundation/fs/cache-eviction.d.mts +3 -1
- package/foundation/fs/cache-eviction.mjs +7 -1
- package/foundation/fs/exact-codec.d.mts +12 -2
- package/foundation/fs/exact-codec.mjs +23 -6
- package/foundation/fs/file-protection.mjs +12 -2
- package/foundation/fs/gather-cache.d.mts +81 -2
- package/foundation/fs/gather-cache.mjs +615 -97
- package/foundation/fs/glob.d.mts +16 -0
- package/foundation/fs/glob.mjs +105 -0
- package/foundation/fs/jiti-cache.mjs +14 -6
- package/foundation/fs/kept-tree.d.mts +39 -15
- package/foundation/fs/kept-tree.mjs +155 -46
- package/foundation/fs/loaded-files.d.mts +30 -0
- package/foundation/fs/loaded-files.mjs +148 -0
- package/foundation/fs/module-loader.d.mts +53 -8
- package/foundation/fs/module-loader.mjs +559 -39
- package/foundation/fs/own-modules.d.mts +29 -0
- package/foundation/fs/own-modules.mjs +57 -0
- package/foundation/fs/path-safety.d.mts +34 -2
- package/foundation/fs/path-safety.mjs +170 -18
- package/foundation/fs/paths.d.mts +41 -2
- package/foundation/fs/paths.mjs +95 -5
- package/foundation/fs/read-record.d.mts +84 -7
- package/foundation/fs/read-record.mjs +333 -56
- package/foundation/fs/regular-file.d.mts +29 -0
- package/foundation/fs/regular-file.mjs +77 -0
- package/foundation/fs/stop-cleanup.d.mts +12 -0
- package/foundation/fs/stop-cleanup.mjs +66 -0
- package/foundation/fs/stylesheet-file.d.mts +37 -0
- package/foundation/fs/stylesheet-file.mjs +48 -0
- package/foundation/fs/theme-module-rejections.d.mts +32 -0
- package/foundation/fs/theme-module-rejections.mjs +82 -0
- package/foundation/integrations/integrations.d.mts +27 -1
- package/foundation/integrations/integrations.mjs +24 -2
- package/foundation/integrations/pack-state.d.mts +85 -0
- package/foundation/integrations/pack-state.mjs +509 -0
- package/foundation/integrations/shipped-imports.d.mts +125 -0
- package/foundation/integrations/shipped-imports.mjs +530 -0
- package/foundation/integrations/validate-contributions.d.mts +0 -17
- package/foundation/integrations/validate-contributions.mjs +81 -290
- package/foundation/release/choose.d.mts +7 -0
- package/foundation/release/choose.mjs +16 -2
- package/foundation/release/handoff.mjs +68 -13
- package/foundation/release/notices.d.mts +46 -9
- package/foundation/release/notices.mjs +78 -20
- package/foundation/release/pnp-runtime.d.mts +66 -0
- package/foundation/release/pnp-runtime.mjs +139 -0
- package/foundation/release/project.d.mts +11 -0
- package/foundation/release/project.mjs +23 -7
- package/foundation/release/run-context.d.mts +7 -2
- package/foundation/release/run-context.mjs +6 -2
- package/foundation/render/assets.mjs +52 -7
- package/foundation/render/charts.d.mts +78 -27
- package/foundation/render/charts.mjs +319 -90
- package/foundation/render/css-cut.d.mts +14 -1
- package/foundation/render/css-cut.mjs +117 -4
- package/foundation/render/cut-short.d.mts +35 -0
- package/foundation/render/cut-short.mjs +124 -0
- package/foundation/render/embedded-imports.d.mts +31 -0
- package/foundation/render/embedded-imports.mjs +169 -39
- package/foundation/render/font-probe.d.mts +27 -0
- package/foundation/render/font-probe.mjs +77 -0
- package/foundation/render/layers.d.mts +49 -0
- package/foundation/render/layers.mjs +347 -0
- package/foundation/render/offline.d.mts +32 -0
- package/foundation/render/offline.mjs +56 -0
- package/foundation/render/page-worker.mjs +374 -15
- package/foundation/render/picture-chrome.mjs +46 -4
- package/foundation/render/picture-playwright.mjs +41 -5
- package/foundation/render/picture-window.d.mts +32 -0
- package/foundation/render/picture-window.mjs +146 -0
- package/foundation/render/render-page.d.mts +46 -4
- package/foundation/render/render-page.mjs +453 -98
- package/foundation/response/base.d.ts +25 -0
- package/foundation/response/error-codes.d.mts +4 -1
- package/foundation/response/error-codes.d.ts +4 -1
- package/foundation/response/error-codes.doc.mjs +17 -0
- package/foundation/response/error-codes.mjs +21 -0
- package/foundation/response/json.d.mts +3 -1
- package/foundation/response/json.mjs +7 -2
- package/foundation/response/response-types.doc.mjs +12 -12
- package/foundation/runtime/css-tree.d.mts +24 -0
- package/foundation/runtime/css-tree.mjs +103 -0
- package/foundation/runtime/lazy-dependencies.d.mts +3 -1
- package/foundation/runtime/lazy-dependencies.mjs +20 -5
- package/foundation/suggest/name-index.d.mts +149 -0
- package/foundation/suggest/name-index.mjs +317 -0
- package/foundation/suggest/other-command.d.mts +146 -0
- package/foundation/suggest/other-command.mjs +783 -0
- package/foundation/text/css-escape.d.mts +18 -0
- package/foundation/text/css-escape.mjs +35 -0
- package/foundation/text/entry-names.d.mts +14 -0
- package/foundation/text/entry-names.mjs +14 -0
- package/foundation/text/string-utils.d.mts +49 -5
- package/foundation/text/string-utils.mjs +124 -26
- package/foundation/text/suggest-order.d.mts +75 -4
- package/foundation/text/suggest-order.mjs +285 -9
- package/foundation/text/written-string.d.mts +17 -0
- package/foundation/text/written-string.mjs +22 -0
- package/foundation/xle/browser.d.mts +2 -2
- package/package.json +8 -7
|
@@ -16,7 +16,7 @@ export const doc = {
|
|
|
16
16
|
summary:
|
|
17
17
|
'Render a page to one self-contained HTML file, or turn one back into a page',
|
|
18
18
|
description:
|
|
19
|
-
"Renders the page's default export with the project's own Astryx components and writes ONE static HTML file that needs nothing beside it: no script runs and nothing loads from the network, so it opens anywhere, including a sandboxed frame with a strict content security policy, and follows the viewer's light or dark scheme. The page's own StyleX compiles, only the Core CSS rules the page uses are inlined, local images become data: URIs, and the page's source is embedded. Warnings name anything that may not look as meant, such as a component that did not render the text it was given (ListItem takes label=, not children). The file opens with a plain note for whoever opens it next: the CLI version and render format that made it, the page's path, the files it carries, the packages it rendered with, and the exact commands that give the page back and render it again. --reverse (the way back, or unrender) writes the embedded source back byte for byte and names any text someone changed in the HTML after the render, with the file and line that hold the old text; a file with Astryx markup but no embedded source is rebuilt from its components (text and layout only, as a starting point); any other HTML is refused. Experimental: it may change or be removed in a patch release.",
|
|
19
|
+
"Renders the page's default export with the project's own Astryx components and writes ONE static HTML file that needs nothing beside it: no script runs and nothing loads from the network, so it opens anywhere, including a sandboxed frame with a strict content security policy, and follows the viewer's light or dark scheme. The page's own StyleX compiles, only the Core CSS rules the page uses are inlined, local images become data: URIs, and the page's source is embedded. Warnings name anything that may not look as meant, such as a component that did not render the text it was given (ListItem takes label=, not children). The file opens with a plain note for whoever opens it next: the CLI version and render format that made it, the page's path, the files it carries, the packages it rendered with, and the exact commands that give the page back and render it again. To make a page to share, follow `astryx docs cli/experimental/share-a-page` first: it lists the layouts that go wrong on a phone in a file that runs no script. --reverse (the way back, or unrender) writes the embedded source back byte for byte and names any text someone changed in the HTML after the render, with the file and line that hold the old text; a file with Astryx markup but no embedded source is rebuilt from its components (text and layout only, as a starting point); any other HTML is refused. Experimental: it may change or be removed in a patch release.",
|
|
20
20
|
fn: 'render',
|
|
21
21
|
args: [{name: 'file', param: 'file', required: false}],
|
|
22
22
|
options: [
|
|
@@ -24,10 +24,11 @@ export const doc = {
|
|
|
24
24
|
flag: '--out <file>',
|
|
25
25
|
param: 'options.out',
|
|
26
26
|
description:
|
|
27
|
-
|
|
27
|
+
'Where to write: an .html file, or with --reverse a page module (default: page.tsx gives page.html beside it; with --reverse, page.html comes back into a new folder page-restored/)',
|
|
28
28
|
},
|
|
29
29
|
{
|
|
30
30
|
flag: '--reverse',
|
|
31
|
+
requires: ['render.reverse'],
|
|
31
32
|
param: 'options.reverse',
|
|
32
33
|
description: 'Turn a rendered HTML file back into a page module',
|
|
33
34
|
},
|
|
@@ -40,15 +41,27 @@ export const doc = {
|
|
|
40
41
|
{
|
|
41
42
|
flag: '--overwrite',
|
|
42
43
|
param: 'options.overwrite',
|
|
43
|
-
description:
|
|
44
|
+
description:
|
|
45
|
+
'With --reverse, replace the page module if it already exists (never a protected file; the files it imports always go into a new folder)',
|
|
44
46
|
},
|
|
45
47
|
],
|
|
46
48
|
examples: [
|
|
47
|
-
{
|
|
48
|
-
|
|
49
|
+
{
|
|
50
|
+
label: 'Before you make a page to share, read what goes wrong on a phone',
|
|
51
|
+
cli: 'astryx docs cli/experimental/share-a-page',
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
label: 'Render a page',
|
|
55
|
+
cli: 'astryx experimental render src/app/page.tsx --out page.html',
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
label: 'Give it back',
|
|
59
|
+
cli: 'astryx experimental render --reverse page.html --out page.tsx',
|
|
60
|
+
},
|
|
49
61
|
{label: 'As JSON', cli: 'astryx --json experimental render page.tsx'},
|
|
50
62
|
],
|
|
51
63
|
outsideProject: 'same',
|
|
64
|
+
requires: ['render.page'],
|
|
52
65
|
exitCodes: [
|
|
53
66
|
{code: 0, when: 'the file was written (warnings included)'},
|
|
54
67
|
{
|
|
@@ -22,6 +22,7 @@ export const doc = {
|
|
|
22
22
|
name: 'slug',
|
|
23
23
|
param: 'slug',
|
|
24
24
|
required: false,
|
|
25
|
+
names: 'theme',
|
|
25
26
|
},
|
|
26
27
|
],
|
|
27
28
|
options: [
|
|
@@ -52,6 +53,7 @@ export const doc = {
|
|
|
52
53
|
},
|
|
53
54
|
],
|
|
54
55
|
outsideProject: 'own',
|
|
56
|
+
requires: ['themes.appModule'],
|
|
55
57
|
exitCodes: [
|
|
56
58
|
{
|
|
57
59
|
code: 0,
|
|
@@ -14,7 +14,7 @@ export const doc = {
|
|
|
14
14
|
stability: 'experimental',
|
|
15
15
|
summary: 'Compile standalone themes or one keyed theme family',
|
|
16
16
|
description:
|
|
17
|
-
"Compiles defineTheme() sources through the same theme pipeline into scoped CSS, standard ESM, and type declarations. Compiling a theme made by experimental theme editor (themes/<theme>/<theme>.theme.ts) takes that theme's lock and also writes its app copy in src/themes/<theme>/ again; --check fails while that copy is behind or gone. The app copy's own files (src/themes/<theme>/<theme>Theme.ts and the rest) are not compiled: compile the theme itself. With --out somewhere else, compile builds and --check checks only the files --out names: themes/<theme>/ and the app copy are not written or checked, and the result says so (appCopySkipped). An --out in the theme's own folder, other than its default stylesheet, is refused, as one in the app copy is. Ordinary mode writes one complete set per theme. --family combines one selected extension tree into the three files named by the required --family-key, ready for one CSS load and identity-only switching. With --check it writes nothing and reports source drift. --icons-specifier keeps its existing generated-module behavior. It prints one line per built theme and one line naming fonts the themes do not load; --detail full adds the install example and the font recipe, once for a batch.",
|
|
17
|
+
"Compiles defineTheme() sources through the same theme pipeline into scoped CSS, standard ESM, and type declarations. Compiling a theme made by experimental theme editor (themes/<theme>/<theme>.theme.ts) takes that theme's lock and also writes its app copy in src/themes/<theme>/ again; --check fails while that copy is behind or gone. The app copy's own files (src/themes/<theme>/<theme>Theme.ts and the rest) are not compiled: compile the theme itself. With --out somewhere else, compile builds and --check checks only the files --out names: themes/<theme>/ and the app copy are not written or checked, and the result says so (appCopySkipped). The result also says what the copy write did: appCopy names the files of its first write, and appCopyStale says what kept it back. An --out in the theme's own folder, other than its default stylesheet, is refused, as one in the app copy is. Ordinary mode writes one complete set per theme. --family combines one selected extension tree into the three files named by the required --family-key, ready for one CSS load and identity-only switching. With --check it writes nothing and reports source drift. --icons-specifier keeps its existing generated-module behavior. It prints one line per built theme and one line naming fonts the themes do not load; --detail full adds the install example and the font recipe, once for a batch.",
|
|
18
18
|
fn: 'themeBuild',
|
|
19
19
|
args: [
|
|
20
20
|
{
|
|
@@ -39,7 +39,7 @@ export const doc = {
|
|
|
39
39
|
flag: '-o, --out <path>',
|
|
40
40
|
param: 'options.out',
|
|
41
41
|
description:
|
|
42
|
-
"Output CSS file path, relative or absolute; the .js and .d.ts are written beside it (default: <theme name>.css next to the source). A folder, or a path ending in /, writes <theme name>.css into it. The path should end in .css;
|
|
42
|
+
"Output CSS file path, relative or absolute; the .js and .d.ts are written beside it (default: <theme name>.css next to the source). A folder, or a path ending in /, writes <theme name>.css into it. The path should end in .css: a TypeScript declaration file (.d.ts) or a stylesheet source map (.css.map) is refused with the .css path to give (ERR_INVALID_ARGUMENT), and nothing is written; any other name still builds, with a warning naming the .css path meant. A build never replaces the theme source (ERR_THEME_INVALID). At a path --out names, it replaces its own earlier outputs, and the output of another theme source with a warning that names both sources; any other existing file fails with ERR_FILE_EXISTS and nothing is written. Into a folder the theme editor made (folder <slug>/ holds <slug>.settings.json), a source outside that folder builds there too, with a warning; to keep the editor folder to its own theme, build beside the source, or pass an --out outside it. A build writes only inside the working directory, the defaults beside the source too (ERR_PATH_TRAVERSAL); --check writes nothing, so it compares outputs anywhere and refuses only a relative path that escapes the working directory. Single theme only: refused with more than one file or with --family (ERR_THEME_INVALID) An --out in an editor theme's app copy folder (src/themes/<theme>/, the folder itself too) is refused (ERR_INVALID_ARGUMENT): the editor writes that folder after every build",
|
|
43
43
|
},
|
|
44
44
|
{
|
|
45
45
|
flag: '--icons-specifier <specifier>',
|
|
@@ -82,6 +82,7 @@ export const doc = {
|
|
|
82
82
|
},
|
|
83
83
|
],
|
|
84
84
|
outsideProject: 'same',
|
|
85
|
+
requires: ['themes.compile'],
|
|
85
86
|
exitCodes: [
|
|
86
87
|
{
|
|
87
88
|
code: 0,
|
|
@@ -28,6 +28,7 @@ export const doc = {
|
|
|
28
28
|
{
|
|
29
29
|
flag: '--like <theme>',
|
|
30
30
|
param: 'options.like',
|
|
31
|
+
names: 'theme',
|
|
31
32
|
description:
|
|
32
33
|
'A built-in theme to build on: neutral, stone, matcha, y2k, gothic, chocolate, or butter; or none, for Astryx defaults (the same as leaving it out)',
|
|
33
34
|
},
|
|
@@ -35,7 +36,7 @@ export const doc = {
|
|
|
35
36
|
flag: '--png',
|
|
36
37
|
param: 'options.png',
|
|
37
38
|
description:
|
|
38
|
-
'Also take PNG pictures of the previews (light and dark), with no dev server running: it needs a Playwright installed in the project or a Chrome or Chromium found on the machine, and adds a few seconds while the browser starts (a browser that takes longer than 60 seconds is stopped, and the result says so); without one, the result says how to get it. Each picture carries the editor stamp and is recorded, by name and content, in themes/<theme>/<theme>.pictures.json; a file of yours named like a picture (preview.png, sheet.png) is never written over: no picture is taken, and the result names the file',
|
|
39
|
+
'Also take PNG pictures of the previews (light and dark): preview.png, the sample page, and sheet-overlays.png, each control at rest, hovered, focused and pressed at its top, then every menu, tooltip, popover and list drawn open (from sheet-overlays.html, which it writes too; a file of yours by that name is left alone and the picture not taken) (show adds a picture of each family of components the theme sets a part of, or of the buttons when it sets none, and show --section <family> --png takes any other family; sheet.html, every component, is not pictured), with no dev server running: it needs a Playwright installed in the project or a Chrome or Chromium found on the machine, and adds a few seconds while the browser starts (a browser that takes longer than 60 seconds is stopped, and the result says so); without one, the result says how to get it. Each picture carries the editor stamp and is recorded, by name and content, in themes/<theme>/<theme>.pictures.json; a file of yours named like a picture (preview.png, sheet-overlays.png) is never written over: no picture is taken, and the result names the file',
|
|
39
40
|
},
|
|
40
41
|
{
|
|
41
42
|
flag: '--corners <rung>',
|
|
@@ -149,6 +150,7 @@ export const doc = {
|
|
|
149
150
|
},
|
|
150
151
|
],
|
|
151
152
|
outsideProject: 'refuse',
|
|
153
|
+
requires: ['themes.targets', 'themes.compile'],
|
|
152
154
|
notes: [
|
|
153
155
|
{
|
|
154
156
|
type: 'prose',
|
|
@@ -43,7 +43,7 @@ export const doc = {
|
|
|
43
43
|
flag: '--when <prop:value>',
|
|
44
44
|
param: 'options.when',
|
|
45
45
|
description:
|
|
46
|
-
'Only that variant of the part, such as variant:primary or status:error (how <part> lists them); needs --on',
|
|
46
|
+
'Only that variant of the part, such as variant:primary or status:error (how <part> lists them); give it once per prop for several at once (--when variant:ghost --when size:sm, or variant:ghost+size:sm); needs --on',
|
|
47
47
|
},
|
|
48
48
|
{
|
|
49
49
|
flag: '--state <state>',
|
|
@@ -55,7 +55,7 @@ export const doc = {
|
|
|
55
55
|
flag: '--mode <mode>',
|
|
56
56
|
param: 'options.mode',
|
|
57
57
|
description:
|
|
58
|
-
'light or dark: only that color mode. Colors only; sizes, numbers, fonts and shadows are the same in both modes
|
|
58
|
+
'light or dark: only that color mode. Colors only; sizes, numbers, fonts and shadows are the same in both modes. A light-only or dark-only theme takes --mode for the other mode only, which applies where Core draws that mode (a toast, a lightbox); its own mode needs no --mode',
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
61
|
flag: '--only',
|
|
@@ -67,7 +67,7 @@ export const doc = {
|
|
|
67
67
|
flag: '--png',
|
|
68
68
|
param: 'options.png',
|
|
69
69
|
description:
|
|
70
|
-
|
|
70
|
+
"Also take PNG pictures of the previews (light and dark): preview.png, the sample page, and sheet-overlays.png, each control at rest, hovered, focused and pressed at its top, then every menu, tooltip, popover and list drawn open (from sheet-overlays.html, which it writes too; a file of yours by that name is left alone and the picture not taken) (show adds a picture of each family of components the theme sets a part of, or of the buttons when it sets none, and show --section <family> --png takes any other family; sheet.html, every component, is not pictured), with no dev server running: it needs a Playwright installed in the project or a Chrome or Chromium found on the machine, and adds a few seconds while the browser starts (a browser that takes longer than 60 seconds is stopped, and the result says so); without one, the result says how to get it. Each picture carries the editor stamp and is recorded, by name and content, in themes/<theme>/<theme>.pictures.json; a file of yours named like a picture (preview.png, sheet-overlays.png) is never written over: no picture is taken, and the result names the file. A change removes the pictures --png took of the look before it (the preview, the sheet and each section sheet, in each mode) and the result names them; a section sheet's page stays, marked as out of date",
|
|
71
71
|
},
|
|
72
72
|
],
|
|
73
73
|
examples: [
|
|
@@ -113,6 +113,7 @@ export const doc = {
|
|
|
113
113
|
},
|
|
114
114
|
],
|
|
115
115
|
outsideProject: 'refuse',
|
|
116
|
+
requires: ['themes.targets', 'themes.compile'],
|
|
116
117
|
notes: [
|
|
117
118
|
{
|
|
118
119
|
type: 'prose',
|
|
@@ -12,7 +12,7 @@ export const doc = {
|
|
|
12
12
|
summary:
|
|
13
13
|
'Every setting, key values, problems the theme caused, and the theme-building page with every component',
|
|
14
14
|
description:
|
|
15
|
-
|
|
15
|
+
"Lists every setting with where it applies and its source (dial, token or property), the resolved value of key tokens in each mode, the colors (the vibrancy; each color with its seed and the shade each token uses in light and dark, marked when an exact token setting wins; any shade moved so text reads), contrast problems this theme caused versus its base, font notes, and last the generated color files. Writes two self-contained HTML files: preview.html (the sample app page) and sheet.html (the theme-building page: every component grouped, each variant side by side, overlays open, and real template pages, with an auto/light/dark switch); a file of yours at a page's name (one without the editor's stamp, a link, a folder) is left alone, and the result names it. A theme with no build is built first, and an in-app preview (`preview add`) of the theme has its route and Colors page rewritten. --section limits the sheet to one section. An own change to <theme>.theme.ts since the last build is built first, and the colors mark where it wins over a generated shade; a theme source that no longer builds, or a token in it that is not text, is refused (ERR_THEME_INVALID, exit 1) and the folder stays as it was. Experimental: it may change or be removed in a patch release. The result ends with `wiring`: `astryx theme add <theme>` for the app copy of the theme (src/themes/<theme>/, a standard local theme every build writes), the `mode` of a one-mode theme for the `<Theme>`, and what builds it; only when a folder of yours holds src/themes/<theme>/ does it give the imports in the root file and the `<Theme>` by hand. When show builds the theme again (its build does not match the settings, say after a hand edit), the pictures --png took of the theme as it was are removed, and the result names them.",
|
|
16
16
|
fn: 'themeEditShow',
|
|
17
17
|
args: [
|
|
18
18
|
{
|
|
@@ -32,7 +32,7 @@ export const doc = {
|
|
|
32
32
|
flag: '--png',
|
|
33
33
|
param: 'options.png',
|
|
34
34
|
description:
|
|
35
|
-
|
|
35
|
+
"Also take PNG pictures of the previews (light and dark): preview.png, the sample page, and sheet-overlays.png, each control at rest, hovered, focused and pressed at its top, then every menu, tooltip, popover and list drawn open (from sheet-overlays.html, which it writes too; a file of yours by that name is left alone and the picture not taken) (show adds a picture of each family of components the theme sets a part of with --on, or of the buttons when it sets none: sheet-<family>.png, from the sheet-<family>.html it writes beside the full sheet; the families are actions, inputs, selection, navigation, feedback, data and containers. With --section, that section's picture is taken in their place, so --section <family> --png pictures any other family. sheet.html, every component, is written but not pictured; the open states are taken with a section too), with no dev server running: it needs a Playwright installed in the project or a Chrome or Chromium found on the machine, and adds a few seconds while the browser starts (a browser that takes longer than 60 seconds is stopped, and the result says so); without one, the result says how to get it. Each picture carries the editor stamp and is recorded, by name and content, in themes/<theme>/<theme>.pictures.json; a file of yours named like a picture (preview.png, sheet-overlays.png) is never written over: no picture is taken, and the result names the file. Taking pictures changes nothing in the app, except that show first brings the app copy (src/themes/<theme>/) and an in-app preview up to date after a hand edit to <theme>.theme.ts",
|
|
36
36
|
},
|
|
37
37
|
],
|
|
38
38
|
examples: [
|
|
@@ -46,6 +46,7 @@ export const doc = {
|
|
|
46
46
|
},
|
|
47
47
|
],
|
|
48
48
|
outsideProject: 'refuse',
|
|
49
|
+
requires: ['themes.compile'],
|
|
49
50
|
notes: [
|
|
50
51
|
{
|
|
51
52
|
type: 'prose',
|
|
@@ -12,7 +12,7 @@ export const doc = {
|
|
|
12
12
|
summary:
|
|
13
13
|
'Step back one change, or remove one setting; the result says what applies instead',
|
|
14
14
|
description:
|
|
15
|
-
"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 a thing, it removes that one setting wherever it is in the settings, and the result says what applies now (`now`): the whole-theme setting for a part setting removed, or the base theme's value; the theme is rebuilt and previewed. Name the setting the way it was set: the same thing and the same --on, --when, --state, --mode and --only (`show` lists every setting that way). For the headings dial, name which half: weight or tracking; with no half named it removes the weight half, or the tracking half when that is the only one set. 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. A setting the theme does not have is refused and the error lists the settings it has for that thing. `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.",
|
|
15
|
+
"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 a thing, it removes that one setting wherever it is in the settings, and the result says what applies now (`now`): the whole-theme setting for a part setting removed, or the base theme's value; the theme is rebuilt and previewed. Name the setting the way it was set: the same thing and the same --on, --when, --state, --mode and --only (`show` lists every setting that way). A value after the thing removes the setting only when that is its value; a value of several words may be typed unquoted, as set takes it. For the headings dial, name which half: weight or tracking; with no half named it removes the weight half, or the tracking half when that is the only one set. 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. A setting the theme does not have is refused and the error lists the settings it has for that thing. `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
16
|
fn: 'themeEditUndo',
|
|
17
17
|
args: [
|
|
18
18
|
{
|
|
@@ -42,7 +42,7 @@ export const doc = {
|
|
|
42
42
|
flag: '--when <prop:value>',
|
|
43
43
|
param: 'options.when',
|
|
44
44
|
description:
|
|
45
|
-
'Only that variant of the part, such as variant:primary or status:error (how <part> lists them); needs --on',
|
|
45
|
+
'Only that variant of the part, such as variant:primary or status:error (how <part> lists them); give it once per prop for several at once (--when variant:ghost --when size:sm, or variant:ghost+size:sm); needs --on',
|
|
46
46
|
},
|
|
47
47
|
{
|
|
48
48
|
flag: '--state <state>',
|
|
@@ -54,7 +54,7 @@ export const doc = {
|
|
|
54
54
|
flag: '--mode <mode>',
|
|
55
55
|
param: 'options.mode',
|
|
56
56
|
description:
|
|
57
|
-
'light or dark: only that color mode. Colors only; sizes, numbers, fonts and shadows are the same in both modes. In a light-only or dark-only theme, it removes a setting saved for
|
|
57
|
+
'light or dark: only that color mode. Colors only; sizes, numbers, fonts and shadows are the same in both modes. In a light-only or dark-only theme, it removes a setting saved for the other mode (which applies where Core draws that mode)',
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
60
|
flag: '--only',
|
|
@@ -66,7 +66,7 @@ export const doc = {
|
|
|
66
66
|
flag: '--png',
|
|
67
67
|
param: 'options.png',
|
|
68
68
|
description:
|
|
69
|
-
|
|
69
|
+
"Also take PNG pictures of the previews (light and dark): preview.png, the sample page, and sheet-overlays.png, each control at rest, hovered, focused and pressed at its top, then every menu, tooltip, popover and list drawn open (from sheet-overlays.html, which it writes too; a file of yours by that name is left alone and the picture not taken) (show adds a picture of each family of components the theme sets a part of, or of the buttons when it sets none, and show --section <family> --png takes any other family; sheet.html, every component, is not pictured), with no dev server running: it needs a Playwright installed in the project or a Chrome or Chromium found on the machine, and adds a few seconds while the browser starts (a browser that takes longer than 60 seconds is stopped, and the result says so); without one, the result says how to get it. Each picture carries the editor stamp and is recorded, by name and content, in themes/<theme>/<theme>.pictures.json; a file of yours named like a picture (preview.png, sheet-overlays.png) is never written over: no picture is taken, and the result names the file. A change removes the pictures --png took of the look before it (the preview, the sheet and each section sheet, in each mode) and the result names them; a section sheet's page stays, marked as out of date",
|
|
70
70
|
},
|
|
71
71
|
],
|
|
72
72
|
examples: [
|
|
@@ -84,6 +84,7 @@ export const doc = {
|
|
|
84
84
|
},
|
|
85
85
|
],
|
|
86
86
|
outsideProject: 'refuse',
|
|
87
|
+
requires: ['themes.compile'],
|
|
87
88
|
notes: [
|
|
88
89
|
{
|
|
89
90
|
type: 'prose',
|
|
@@ -12,7 +12,7 @@ export const doc = {
|
|
|
12
12
|
summary:
|
|
13
13
|
'Make a new starter app with the theme preview inside, ready to install and run',
|
|
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 --theme, Core and the base theme are pinned to the versions this project has, the ones the copied build was made on, with a note), 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: it prints the install and dev commands and the page to open. <dir> must be new or empty, inside the project folder (from a subfolder too); 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. Later pages go in with `experimental theme preview add`, run in the new app. 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. It takes one folder; more arguments are refused. 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 --theme, Core and the base theme are pinned to the versions this project has, the ones the copied build was made on, with a note), 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: it prints the install and dev commands and the page to open. <dir> must be new or empty, inside the project folder (from a subfolder too); 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. Later pages go in with `experimental theme preview add`, run in the new app. 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 family the CLI does not know to be open, with no package of it in this project, is named in the result instead, with the package that would load 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. It takes one folder; more arguments are refused. 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
|
fn: 'themeEditPreviewApp',
|
|
17
17
|
args: [
|
|
18
18
|
{
|
|
@@ -40,10 +40,11 @@ export const doc = {
|
|
|
40
40
|
},
|
|
41
41
|
],
|
|
42
42
|
outsideProject: 'own',
|
|
43
|
+
requires: ['setup.guide', 'themes.appModule'],
|
|
43
44
|
notes: [
|
|
44
45
|
{
|
|
45
46
|
type: 'prose',
|
|
46
|
-
text: "In global mode: outside a project, with no package.json in the folder or above it, experimental theme preview app
|
|
47
|
+
text: "In global mode: outside a project, with no package.json in the folder or above it, experimental theme preview app makes the new app, with its pages from this CLI's own Core; with `--theme` it writes nothing and stops with `ERR_PROJECT_REQUIRED`, because the theme comes from a project. In a project, the project's version of Astryx runs it, whichever astryx command you start. See {@link namespace:global} and {@link generic:problems}.",
|
|
47
48
|
},
|
|
48
49
|
],
|
|
49
50
|
exitCodes: [
|
|
@@ -12,15 +12,16 @@ export const doc = {
|
|
|
12
12
|
displayName: 'astryx experimental theme remove',
|
|
13
13
|
namespace: 'cli/commands',
|
|
14
14
|
stability: 'experimental',
|
|
15
|
-
summary: 'Remove a
|
|
15
|
+
summary: 'Remove a theme from the app',
|
|
16
16
|
description:
|
|
17
|
-
'Removes one added theme from the generated module and regenerates the whole module.
|
|
17
|
+
'Removes one added theme from the generated module and regenerates the whole module. While other themes are added, choose another default with `astryx experimental theme use` before removing the current default. Removing the only added theme removes the module file and prints the lines the app root must drop.',
|
|
18
18
|
fn: 'themeRemove',
|
|
19
19
|
args: [
|
|
20
20
|
{
|
|
21
21
|
name: 'slug',
|
|
22
22
|
param: 'slug',
|
|
23
23
|
required: true,
|
|
24
|
+
names: 'theme',
|
|
24
25
|
},
|
|
25
26
|
],
|
|
26
27
|
examples: [
|
|
@@ -30,14 +31,15 @@ export const doc = {
|
|
|
30
31
|
},
|
|
31
32
|
],
|
|
32
33
|
outsideProject: 'refuse',
|
|
34
|
+
requires: ['themes.appModule'],
|
|
33
35
|
exitCodes: [
|
|
34
36
|
{
|
|
35
37
|
code: 0,
|
|
36
|
-
when: 'the module is regenerated without the theme',
|
|
38
|
+
when: 'the module is regenerated without the theme; or, for the only added theme, the module is removed and the lines the app root must drop are printed',
|
|
37
39
|
},
|
|
38
40
|
{
|
|
39
41
|
code: 1,
|
|
40
|
-
when: 'the theme is not added
|
|
42
|
+
when: 'the theme is not added; it is the default and other themes are still added (choose another default with theme use first); it is the only added theme and its module has changes the CLI did not write; or state is invalid',
|
|
41
43
|
},
|
|
42
44
|
],
|
|
43
45
|
related: [
|
|
@@ -21,6 +21,7 @@ export const doc = {
|
|
|
21
21
|
name: 'slug',
|
|
22
22
|
param: 'slug',
|
|
23
23
|
required: true,
|
|
24
|
+
names: 'theme',
|
|
24
25
|
},
|
|
25
26
|
],
|
|
26
27
|
examples: [
|
|
@@ -30,6 +31,7 @@ export const doc = {
|
|
|
30
31
|
},
|
|
31
32
|
],
|
|
32
33
|
outsideProject: 'refuse',
|
|
34
|
+
requires: ['themes.appModule'],
|
|
33
35
|
exitCodes: [
|
|
34
36
|
{
|
|
35
37
|
code: 0,
|
|
@@ -18,7 +18,7 @@ export const doc = {
|
|
|
18
18
|
'Resolves a hook by name and prints its authored doc, or lists the catalog grouped ' +
|
|
19
19
|
'by category. The --params flag narrows a single hook to just its parameters table.',
|
|
20
20
|
fn: 'hook',
|
|
21
|
-
args: [{name: 'name', param: 'name', required: false}],
|
|
21
|
+
args: [{name: 'name', param: 'name', required: false, names: 'hook'}],
|
|
22
22
|
options: [
|
|
23
23
|
{
|
|
24
24
|
flag: '--list',
|
|
@@ -70,7 +70,7 @@ export const doc = {
|
|
|
70
70
|
description:
|
|
71
71
|
'Write or refresh the computer-level agent text instead of setting up the folder: one skill file, ~/.agents/skills/astryx/SKILL.md, which most coding agents read, ' +
|
|
72
72
|
'linked into the skill folders of agents that read only their own (~/.claude/skills always; Kiro, Windsurf, Letta, Xcode\'s coding assistant, and ~/.config/agents/skills when that folder exists): a folder symlink with a relative target, a junction on Windows, or a copy where neither can be made. Continue, whose scanner skips links, gets a managed copy, refreshed with the file. ' +
|
|
73
|
-
"It tells agents anywhere on the computer that Astryx is there, when it is relevant,
|
|
73
|
+
"It tells agents anywhere on the computer that Astryx is there, when it is relevant, to start a page with `astryx build` and anything else with `astryx search`. " +
|
|
74
74
|
'Records the links it made in astryx/settings.json in the per-user configuration folder, so removal removes exactly those; the CLI installed for the computer refreshes the file in the background after each upgrade. ' +
|
|
75
75
|
'Works in any folder. A file without the Astryx markers, one edited since Astryx wrote it, or a symlink, is kept as it is, and so is anything at a link target that Astryx did not create. ' +
|
|
76
76
|
'Warns, and still writes, when no `astryx` command on the computer runs the Astryx CLI. ' +
|
|
@@ -17,7 +17,8 @@
|
|
|
17
17
|
import {init} from '../../../api/init/init.mjs';
|
|
18
18
|
import {logger} from '../../../api/logger.mjs';
|
|
19
19
|
import {jsonOut} from '../../../foundation/response/json.mjs';
|
|
20
|
-
import {cliError} from '../lib/cli-error.mjs';
|
|
20
|
+
import {cliError, failAfterOutput} from '../lib/cli-error.mjs';
|
|
21
|
+
import {ERROR_CODES} from '../../../foundation/response/error-codes.mjs';
|
|
21
22
|
import {defineCommand} from '../lib/define-command.mjs';
|
|
22
23
|
import {NO_RESULT_SET} from '../../../foundation/debug/index.mjs';
|
|
23
24
|
import {doc as initCommand} from './init.doc.mjs';
|
|
@@ -29,7 +30,9 @@ import {doc as initFn} from '../../../api/init/init.doc.mjs';
|
|
|
29
30
|
export function registerInit(program) {
|
|
30
31
|
defineCommand(program, initCommand, {
|
|
31
32
|
fn: initFn,
|
|
32
|
-
action: async (
|
|
33
|
+
action: async (
|
|
34
|
+
/** @type {import('../../../api/init/init.mjs').InitOptions} */ options,
|
|
35
|
+
) => {
|
|
33
36
|
const json = program.opts().json || false;
|
|
34
37
|
// Silence the progress logger under --json so stdout carries only the
|
|
35
38
|
// envelope. In human mode it writes log → stdout via humanLog and
|
|
@@ -37,15 +40,20 @@ export function registerInit(program) {
|
|
|
37
40
|
logger.setSilent(json);
|
|
38
41
|
try {
|
|
39
42
|
const receipt = await init(options, {cwd: process.cwd()});
|
|
43
|
+
if (json) jsonOut(receipt);
|
|
40
44
|
// A path-safety failure already printed its error but the run
|
|
41
45
|
// continued; reflect it in the exit code (historical soft-error policy).
|
|
42
46
|
// The receipt still reports it as `data.docsError` either way.
|
|
43
|
-
if (
|
|
44
|
-
|
|
47
|
+
if (
|
|
48
|
+
receipt.type === 'init.run' &&
|
|
49
|
+
receipt.data.docsError?.kind === 'path-safety'
|
|
50
|
+
) {
|
|
51
|
+
failAfterOutput(ERROR_CODES.ERR_PATH_TRAVERSAL);
|
|
45
52
|
}
|
|
46
|
-
if (json) jsonOut(receipt);
|
|
47
53
|
} catch (err) {
|
|
48
|
-
const e = /** @type {import('../../../api/error.mjs').AstryxError} */ (
|
|
54
|
+
const e = /** @type {import('../../../api/error.mjs').AstryxError} */ (
|
|
55
|
+
err
|
|
56
|
+
);
|
|
49
57
|
return cliError(e.message, {suggestions: e.suggestions, code: e.code});
|
|
50
58
|
}
|
|
51
59
|
// Setup writes files; there is nothing to look up. The receipt says what
|
|
@@ -19,7 +19,12 @@
|
|
|
19
19
|
import {getCliInvocation} from '../../../foundation/env/package-manager.mjs';
|
|
20
20
|
import {jsonOut} from '../../../foundation/response/json.mjs';
|
|
21
21
|
import {emit, section, text, records} from '../formatters/index.mjs';
|
|
22
|
-
import {
|
|
22
|
+
import {
|
|
23
|
+
buildManifest,
|
|
24
|
+
rebaseManifest,
|
|
25
|
+
storedManifest,
|
|
26
|
+
} from '../lib/manifest.mjs';
|
|
27
|
+
import {helpBase} from '../lib/base-gate.mjs';
|
|
23
28
|
import {defineCommand} from '../lib/define-command.mjs';
|
|
24
29
|
import {resultSet} from '../../../foundation/debug/index.mjs';
|
|
25
30
|
import {doc as manifestCommand} from './manifest.doc.mjs';
|
|
@@ -34,8 +39,10 @@ export function registerManifest(program, {jsonSupported, version}) {
|
|
|
34
39
|
action: () => {
|
|
35
40
|
// The published package reads the manifest it stored: only this
|
|
36
41
|
// command is loaded then (see commandsForArgs).
|
|
37
|
-
const
|
|
38
|
-
|
|
42
|
+
const stored = storedManifest();
|
|
43
|
+
const manifest = stored
|
|
44
|
+
? rebaseManifest(stored, helpBase())
|
|
45
|
+
: buildManifest(program, {jsonSupported, version});
|
|
39
46
|
// The manifest IS a result set: one entry per command the CLI ships.
|
|
40
47
|
const answered = resultSet({
|
|
41
48
|
count: manifest.commands.length,
|
|
@@ -29,6 +29,7 @@ import {jsonOut} from '../../../foundation/response/json.mjs';
|
|
|
29
29
|
import {resultSetOf} from '../../../foundation/debug/index.mjs';
|
|
30
30
|
import {emit, formatDeprecation, section, text, records} from '../formatters/index.mjs';
|
|
31
31
|
import {cliError} from '../lib/cli-error.mjs';
|
|
32
|
+
import {markNotReady} from '../lib/not-ready.mjs';
|
|
32
33
|
import {defineCommand} from '../lib/define-command.mjs';
|
|
33
34
|
import {search as searchApi} from '../../../api/search/search.mjs';
|
|
34
35
|
import {Project} from '../../../foundation/config/project.mjs';
|
|
@@ -178,7 +179,7 @@ export function registerSearch(program) {
|
|
|
178
179
|
? `Results for "${q}" (${results.length} of ${matchCount})`
|
|
179
180
|
: `Results for "${q}" (${results.length})`,
|
|
180
181
|
),
|
|
181
|
-
records(results, {
|
|
182
|
+
records(results.map(withNotReadyKind), {
|
|
182
183
|
fields,
|
|
183
184
|
format: {
|
|
184
185
|
command: formatCliCommand,
|
|
@@ -198,6 +199,17 @@ export function registerSearch(program) {
|
|
|
198
199
|
});
|
|
199
200
|
}
|
|
200
201
|
|
|
202
|
+
/**
|
|
203
|
+
* The text view of a result: an unready template's kind reads
|
|
204
|
+
* `page (not ready)`. The JSON carries the same fact as `isReady: false`.
|
|
205
|
+
* @param {import('../../../api/search/search.type.mjs').SearchResultEntry} result
|
|
206
|
+
*/
|
|
207
|
+
function withNotReadyKind(result) {
|
|
208
|
+
return result.isReady === false
|
|
209
|
+
? {...result, kind: markNotReady(String(result.kind), false)}
|
|
210
|
+
: result;
|
|
211
|
+
}
|
|
212
|
+
|
|
201
213
|
/**
|
|
202
214
|
* Search reads only what is installed. Point at `discover` for the packages
|
|
203
215
|
* that could add more, except for hooks, which no integration adds.
|
|
@@ -31,7 +31,14 @@ export const doc = {
|
|
|
31
31
|
'copies; --package @astryxdesign/core copies the original. --list lists Core ' +
|
|
32
32
|
'components, including one an integration replaces.',
|
|
33
33
|
fn: 'swizzle',
|
|
34
|
-
args: [
|
|
34
|
+
args: [
|
|
35
|
+
{
|
|
36
|
+
name: 'component',
|
|
37
|
+
param: 'component',
|
|
38
|
+
required: false,
|
|
39
|
+
names: 'component',
|
|
40
|
+
},
|
|
41
|
+
],
|
|
35
42
|
options: [
|
|
36
43
|
{
|
|
37
44
|
flag: '--output <dir>',
|
|
@@ -78,7 +85,7 @@ export const doc = {
|
|
|
78
85
|
notes: [
|
|
79
86
|
{
|
|
80
87
|
type: 'prose',
|
|
81
|
-
text: 'In global mode: outside a project, swizzle writes nothing and stops with `ERR_CORE_NOT_FOUND`: "Could not find @astryxdesign/core
|
|
88
|
+
text: 'In global mode: outside a project, swizzle writes nothing and stops with `ERR_CORE_NOT_FOUND`: "Could not find @astryxdesign/core. This folder is outside a project; swizzle copies a component\'s source into an app project that installs @astryxdesign/core." In a project, the project\'s version of Astryx runs it, whichever astryx command you start. See {@link namespace:global} and {@link generic:problems}.',
|
|
82
89
|
},
|
|
83
90
|
],
|
|
84
91
|
};
|
|
@@ -18,6 +18,7 @@ import {defineCommand} from '../lib/define-command.mjs';
|
|
|
18
18
|
import {doc as swizzleCommand} from './swizzle.doc.mjs';
|
|
19
19
|
import {doc as swizzleFn} from '../../../api/swizzle/swizzle.doc.mjs';
|
|
20
20
|
import {NO_RESULT_SET, resultSet} from '../../../foundation/debug/index.mjs';
|
|
21
|
+
import {currentNonCoreBase} from '../../../foundation/bases/state.mjs';
|
|
21
22
|
|
|
22
23
|
/**
|
|
23
24
|
* @param {import('commander').Command} program
|
|
@@ -66,12 +67,18 @@ export function registerSwizzle(program) {
|
|
|
66
67
|
section('Available components'),
|
|
67
68
|
list(components),
|
|
68
69
|
text(`Usage: ${run} swizzle <component>`),
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
70
|
+
// The examples name Core components, so a run on another base
|
|
71
|
+
// leaves them out.
|
|
72
|
+
...(currentNonCoreBase()
|
|
73
|
+
? []
|
|
74
|
+
: [
|
|
75
|
+
text(
|
|
76
|
+
[
|
|
77
|
+
`Example: ${run} swizzle Button`,
|
|
78
|
+
` ${run} swizzle XDSButton (XDS prefix also works)`,
|
|
79
|
+
].join('\n'),
|
|
80
|
+
),
|
|
81
|
+
]),
|
|
75
82
|
);
|
|
76
83
|
return answered;
|
|
77
84
|
}
|