@astryxdesign/cli 0.7.17-canary.g5a3fd39 → 0.7.17-canary.g5cf5d69
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 +64 -63
- package/api/build/_adapter.d.mts +51 -0
- package/api/build/_adapter.mjs +122 -6
- package/api/build/build.doc.mjs +1 -1
- package/api/build/build.mjs +23 -14
- package/api/build/build.type.d.mts +1 -1
- package/api/build/build.type.mjs +3 -3
- package/api/build/help/help.d.mts +15 -14
- package/api/build/help/help.mjs +62 -3
- package/api/build/kit/answer.mjs +2 -3
- package/api/build/kit/signals.d.mts +10 -0
- package/api/build/kit/signals.mjs +15 -2
- package/api/component/detail/blocks/blocks.mjs +2 -1
- package/api/discover/_adapter.d.mts +57 -6
- package/api/discover/_adapter.mjs +278 -49
- package/api/discover/_catalog-view.d.mts +7 -0
- package/api/discover/_catalog-view.mjs +10 -1
- package/api/discover/detail/detail.d.mts +3 -2
- package/api/discover/detail/detail.mjs +3 -2
- package/api/discover/detail/doc/doc.mjs +1 -1
- package/api/discover/discover.d.mts +24 -0
- package/api/discover/discover.doc.mjs +1 -1
- package/api/discover/discover.mjs +146 -25
- package/api/discover/discover.type.d.mts +6 -4
- package/api/discover/discover.type.mjs +6 -4
- package/api/discover/search/search.d.mts +22 -0
- package/api/discover/search/search.mjs +290 -70
- package/api/docs/_entry-names.mjs +4 -3
- package/api/doctor/_adapter.d.mts +43 -3
- package/api/doctor/_adapter.mjs +142 -18
- package/api/doctor/built-checks.d.mts +30 -3
- package/api/doctor/built-checks.mjs +132 -5
- package/api/doctor/doctor.d.mts +93 -6
- package/api/doctor/doctor.doc.mjs +2 -2
- package/api/doctor/doctor.mjs +524 -33
- package/api/doctor/doctor.type.d.mts +2 -1
- package/api/doctor/doctor.type.mjs +2 -1
- package/api/doctor/theme-checks.d.mts +19 -0
- package/api/doctor/theme-checks.mjs +74 -6
- package/api/hook/hook.type.d.mts +1 -1
- package/api/hook/hook.type.mjs +1 -1
- package/api/hook/list/list.mjs +11 -7
- package/api/icon/_adapter.d.mts +2 -1
- package/api/icon/_adapter.mjs +10 -15
- package/api/icon/_records.d.mts +3 -1
- package/api/icon/_records.mjs +30 -3
- package/api/icon/exportIconIndex.doc.mjs +1 -1
- package/api/icon/icon.doc.mjs +3 -3
- package/api/icon/icon.type.d.mts +32 -1
- package/api/icon/icon.type.mjs +19 -3
- package/api/icon/list/list.mjs +4 -1
- package/api/icon/rankIconIndex.doc.mjs +1 -1
- package/api/icon/search/icon-index.mjs +18 -8
- package/api/icon/search/search.d.mts +26 -3
- package/api/icon/search/search.mjs +155 -9
- package/api/init/_adapter.d.mts +14 -0
- package/api/init/_adapter.mjs +26 -4
- package/api/init/init.d.mts +1 -1
- package/api/init/init.doc.mjs +2 -2
- package/api/init/init.mjs +1 -1
- package/api/init/init.type.d.mts +29 -1
- package/api/init/init.type.mjs +14 -1
- package/api/init/run/run.d.mts +11 -1
- package/api/init/run/run.mjs +84 -5
- package/api/integration/_adapter.d.mts +5 -4
- package/api/integration/_adapter.mjs +7 -5
- package/api/integration/integrationCheck.doc.mjs +1 -1
- package/api/integration/pack-check.mjs +8 -9
- package/api/integration/validate-integration.d.mts +1 -1
- package/api/integration/validate-integration.mjs +26 -24
- package/api/integration/validate-integration.type.d.mts +5 -2
- package/api/integration/validate-integration.type.mjs +5 -2
- package/api/integration/validateIntegration.doc.mjs +1 -1
- package/api/render/_adapter.d.mts +4 -2
- package/api/render/_adapter.mjs +62 -21
- package/api/render/render.doc.mjs +8 -5
- package/api/render/render.mjs +1 -1
- package/api/render/render.type.d.mts +2 -0
- package/api/render/render.type.mjs +2 -0
- package/api/search/ORDERING.md +2 -2
- package/api/search/_candidate-score.d.mts +3 -0
- package/api/search/_candidate-score.mjs +36 -3
- package/api/search/_gather-docs.mjs +29 -2
- package/api/search/_gather-templates.mjs +2 -1
- package/api/search/_main-searcher.mjs +13 -0
- package/api/search/_named-keywords.d.mts +2 -1
- package/api/search/_named-keywords.mjs +48 -6
- package/api/search/_order.d.mts +36 -1
- package/api/search/_order.mjs +141 -3
- package/api/swizzle/list/list.mjs +8 -1
- package/api/swizzle/swizzle.type.d.mts +1 -1
- package/api/swizzle/swizzle.type.mjs +1 -1
- package/api/template/copy/copy.mjs +3 -4
- package/api/template/list/list.mjs +2 -1
- package/api/template/show/show.mjs +2 -1
- package/api/template/skeleton/skeleton.mjs +2 -1
- package/api/template/template.doc.mjs +1 -1
- package/api/template/template.mjs +19 -1
- package/api/template/template.type.d.mts +1 -0
- package/api/template/template.type.mjs +2 -1
- package/api/theme/_adapter.d.mts +1 -0
- package/api/theme/_adapter.mjs +3 -5
- package/api/theme/_app-provider.d.mts +42 -0
- package/api/theme/_app-provider.mjs +61 -27
- package/api/theme/build/build.d.mts +4 -10
- package/api/theme/build/build.mjs +165 -116
- package/api/theme/build/input-fields.d.mts +9 -0
- package/api/theme/build/input-fields.mjs +155 -16
- package/api/theme/build/radius-values.d.mts +18 -0
- package/api/theme/build/radius-values.mjs +76 -0
- package/api/theme/build/typography-values.mjs +7 -23
- package/api/theme/build/written-values.d.mts +18 -0
- package/api/theme/build/written-values.mjs +107 -31
- package/api/theme/eject/eject.mjs +6 -1
- package/api/theme/palette/generate/generator.mjs +24 -0
- package/api/theme/theme.type.d.mts +4 -2
- package/api/theme/theme.type.mjs +3 -2
- package/api/theme/themeBuild.doc.mjs +2 -2
- package/api/theme/themeEject.doc.mjs +1 -1
- package/api/theme-edit/_catalog.d.mts +40 -0
- package/api/theme-edit/_catalog.mjs +100 -22
- package/api/theme-edit/_check.mjs +213 -43
- package/api/theme-edit/_color.d.mts +14 -0
- package/api/theme-edit/_color.mjs +22 -0
- package/api/theme-edit/_compiler.mjs +52 -0
- package/api/theme-edit/_context.d.mts +20 -2
- package/api/theme-edit/_context.mjs +157 -29
- package/api/theme-edit/_edit.mjs +426 -58
- package/api/theme-edit/_how-question.d.mts +14 -0
- package/api/theme-edit/_how-question.mjs +1541 -127
- package/api/theme-edit/_how.mjs +43 -0
- package/api/theme-edit/_missed.mjs +107 -27
- package/api/theme-edit/_normal.d.mts +18 -4
- package/api/theme-edit/_normal.mjs +84 -3
- package/api/theme-edit/_palette.d.mts +9 -0
- package/api/theme-edit/_palette.mjs +158 -33
- package/api/theme-edit/_part-words.mjs +16 -3
- package/api/theme-edit/_parts.d.mts +8 -0
- package/api/theme-edit/_parts.mjs +120 -36
- package/api/theme-edit/_png.d.mts +24 -0
- package/api/theme-edit/_png.mjs +99 -0
- package/api/theme-edit/_preview-app.d.mts +16 -0
- package/api/theme-edit/_preview-app.mjs +52 -18
- package/api/theme-edit/_preview.d.mts +44 -26
- package/api/theme-edit/_preview.mjs +255 -67
- package/api/theme-edit/_project.d.mts +12 -1
- package/api/theme-edit/_project.mjs +16 -1
- package/api/theme-edit/_settings.d.mts +116 -0
- package/api/theme-edit/_settings.mjs +1197 -58
- package/api/theme-edit/_tables.d.mts +16 -0
- package/api/theme-edit/_tables.mjs +34 -4
- package/api/theme-edit/theme-edit.type.d.mts +15 -2
- package/api/theme-edit/theme-edit.type.mjs +8 -6
- package/api/upgrade/_adapter.d.mts +46 -7
- package/api/upgrade/_adapter.mjs +110 -15
- package/api/upgrade/registry/registry.d.mts +6 -3
- package/api/upgrade/registry/registry.mjs +21 -6
- package/api/upgrade/run/run.mjs +23 -11
- package/api/upgrade/upgrade.doc.mjs +4 -3
- package/assets/component-list.generated.json +1 -1
- package/assets/docs/tree/agent-guidance.doc.mjs +3 -2
- package/assets/docs/tree/checks.doc.mjs +2 -2
- package/assets/docs/tree/host-entry.doc.mjs +4 -0
- package/assets/docs/tree/icon-definitions.doc.mjs +3 -3
- package/assets/docs/tree/icon-sets.doc.mjs +6 -6
- package/assets/docs/tree/problems.doc.mjs +3 -3
- package/assets/docs/tree/render-pages.doc.mjs +17 -3
- package/assets/docs/tree/share-a-page.doc.mjs +5 -5
- package/assets/docs/tree/short-and-findable.doc.mjs +3 -3
- package/assets/docs/tree/troubleshooting.doc.mjs +8 -0
- package/assets/docs/tree/updates.doc.mjs +1 -1
- package/assets/docs/tree/versioning.doc.mjs +1 -1
- package/assets/docs/working-with-ai.doc.mjs +40 -5
- package/assets/docs-routes.generated.json +1 -1
- package/assets/docs.generated.json +2 -2
- package/assets/icons/installed-icon-set.doc.mjs +30 -0
- package/assets/search-catalog.generated.json +2 -2
- package/assets/self-audit.generated.json +1 -1
- package/assets/templates/blocks/components/Avatar/AvatarInteractive.tsx +6 -1
- package/assets/templates/blocks/components/CodeBlock/CodeBlockTerminal.tsx +1 -1
- package/assets/templates/blocks/components/LinkProvider/LinkProviderCustomLink.tsx +3 -1
- package/assets/templates/components.generated.json +1 -1
- package/assets/templates/pages/ai-chat/page.tsx +6 -2
- package/assets/templates/pages/ai-chat-landing/page.tsx +1 -1
- package/assets/templates/pages/blank/page.tsx +4 -2
- package/assets/templates/pages/canvas-editor/page.tsx +3 -1
- package/assets/templates/pages/centered-hero/page.tsx +1 -1
- package/assets/templates/pages/checkout-wizard/page.tsx +1 -1
- package/assets/templates/pages/classic-gallery/page.tsx +1 -1
- package/assets/templates/pages/contact-form/page.tsx +2 -2
- package/assets/templates/pages/course-detail/page.tsx +1 -1
- package/assets/templates/pages/dashboard/page.tsx +24 -8
- package/assets/templates/pages/dashboard-alert-rail/page.tsx +4 -2
- package/assets/templates/pages/dashboard-cohort-funnel/page.tsx +7 -3
- package/assets/templates/pages/dashboard-comparison/page.tsx +5 -2
- package/assets/templates/pages/dashboard-composition/page.tsx +10 -4
- package/assets/templates/pages/dashboard-progress/page.tsx +6 -3
- package/assets/templates/pages/dashboard-scorecard/page.tsx +17 -8
- package/assets/templates/pages/detail-page/page.tsx +22 -5
- package/assets/templates/pages/documentation/page.tsx +4 -2
- package/assets/templates/pages/documentation-design/page.tsx +5 -2
- package/assets/templates/pages/documentation-technical/page.tsx +4 -2
- package/assets/templates/pages/editor/page.tsx +28 -9
- package/assets/templates/pages/file-explorer/page.tsx +3 -1
- package/assets/templates/pages/form-two-column/page.tsx +1 -1
- package/assets/templates/pages/form-wizard/page.tsx +1 -1
- package/assets/templates/pages/form-wizard-dialog/page.tsx +3 -1
- package/assets/templates/pages/form-wizard-inline/page.tsx +1 -1
- package/assets/templates/pages/form-wizard-vertical/page.tsx +1 -1
- package/assets/templates/pages/gallery-hero/page.tsx +1 -1
- package/assets/templates/pages/ide/page.tsx +7 -2
- package/assets/templates/pages/kanban-board/page.tsx +10 -4
- package/assets/templates/pages/library/page.tsx +31 -61
- package/assets/templates/pages/login/page.tsx +4 -2
- package/assets/templates/pages/login-card/page.tsx +4 -2
- package/assets/templates/pages/login-split/page.tsx +3 -2
- package/assets/templates/pages/login-sso/page.tsx +4 -4
- package/assets/templates/pages/mixed-gallery/page.tsx +1 -1
- package/assets/templates/pages/payment-form/page.tsx +1 -1
- package/assets/templates/pages/product-detail/page.tsx +16 -4
- package/assets/templates/pages/product-gallery/page.tsx +1 -1
- package/assets/templates/pages/settings/page.tsx +10 -4
- package/assets/templates/pages/settings-dialog/page.tsx +5 -6
- package/assets/templates/pages/settings-sidebar/page.tsx +39 -13
- package/assets/templates/pages/side-gallery/page.tsx +1 -1
- package/assets/templates/pages/table/page.tsx +2 -2
- package/assets/templates/pages/table-filter/page.tsx +21 -6
- package/assets/templates/pages/table-grouped/page.tsx +23 -2
- package/assets/templates/pages/table-inbox/page.tsx +82 -32
- package/assets/templates/pages/theme-showcase/page.tsx +3 -2
- package/assets/templates/themes/butter/butterPaletteRefs.generated.ts +12 -12
- package/assets/templates/themes/butter/butterTheme.ts +197 -4
- package/assets/templates/themes/chocolate/chocolateTheme.ts +72 -8
- package/assets/templates/themes/gothic/gothicPaletteRefs.generated.ts +3 -3
- package/assets/templates/themes/gothic/gothicTheme.ts +114 -4
- package/assets/templates/themes/matcha/matchaPaletteRefs.generated.ts +8 -8
- package/assets/templates/themes/matcha/matchaTheme.ts +48 -12
- package/assets/templates/themes/neutral/neutralTheme.ts +29 -0
- package/assets/templates/themes/stone/stonePaletteRefs.generated.ts +2 -2
- package/assets/templates/themes/stone/stoneTheme.ts +69 -0
- package/assets/templates/themes/y2k/y2kPaletteRefs.generated.ts +9 -9
- package/assets/templates/themes/y2k/y2kTheme.ts +249 -14
- package/authoring/codemod/parse.d.mts +0 -36
- package/authoring/codemod/parse.mjs +62 -41
- package/authoring/config/config.doc.mjs +1 -1
- package/authoring/config/parse.d.mts +0 -47
- package/authoring/config/parse.mjs +128 -103
- package/authoring/config/type.ts +4 -3
- package/authoring/debug/parse.d.mts +2 -2
- package/authoring/discover/parse.d.mts +2 -2
- package/authoring/discover/parse.mjs +52 -38
- package/authoring/discover/type.ts +2 -1
- package/authoring/doctypes/_schema.d.mts +834 -950
- package/authoring/doctypes/_schema.mjs +863 -825
- package/authoring/doctypes/command/parse.mjs +2 -2
- package/authoring/doctypes/component/parse.mjs +2 -2
- package/authoring/doctypes/enum/parse.mjs +2 -2
- package/authoring/doctypes/hook/parse.mjs +2 -2
- package/authoring/doctypes/icon-definition/icon-definition.doc.mjs +1 -1
- package/authoring/doctypes/icon-definition/parse.d.mts +0 -24
- package/authoring/doctypes/icon-definition/parse.mjs +59 -43
- package/authoring/doctypes/icon-set/parse.d.mts +0 -75
- package/authoring/doctypes/icon-set/parse.mjs +239 -210
- package/authoring/doctypes/legacy.mjs +3 -3
- package/authoring/doctypes/namespace/parse.mjs +2 -2
- package/authoring/doctypes/reference/parse.mjs +2 -2
- package/authoring/doctypes/schema/parse.mjs +2 -2
- package/authoring/doctypes/template/parse.d.mts +0 -101
- package/authoring/doctypes/template/parse.mjs +131 -106
- package/authoring/doctypes/theme/parse.d.mts +0 -23
- package/authoring/doctypes/theme/parse.mjs +52 -36
- package/authoring/gap-report/parse.d.mts +1 -1
- package/authoring/integration/integration.doc.mjs +8 -0
- package/authoring/integration/schema.d.mts +14 -3
- package/authoring/integration/schema.mjs +20 -2
- package/authoring/integration/type.ts +14 -0
- package/clients/cli/build-id.generated.json +1 -1
- package/clients/cli/commands/build.mjs +27 -13
- package/clients/cli/commands/component.mjs +14 -3
- package/clients/cli/commands/discover.doc.mjs +2 -2
- package/clients/cli/commands/discover.mjs +20 -3
- package/clients/cli/commands/docs.doc.mjs +11 -9
- package/clients/cli/commands/docs.mjs +50 -21
- package/clients/cli/commands/experimental/icon.mjs +330 -227
- package/clients/cli/commands/experimental/render.mjs +16 -1
- package/clients/cli/commands/experimental/theme.mjs +42 -17
- package/clients/cli/commands/experimental-icon-add.doc.mjs +1 -1
- package/clients/cli/commands/experimental-icon-map.doc.mjs +4 -1
- package/clients/cli/commands/experimental-icon-new-definition.doc.mjs +4 -1
- package/clients/cli/commands/experimental-icon-new-set.doc.mjs +4 -1
- package/clients/cli/commands/experimental-icon-use.doc.mjs +1 -1
- package/clients/cli/commands/experimental-icon.doc.mjs +1 -1
- package/clients/cli/commands/experimental-render.doc.mjs +3 -3
- package/clients/cli/commands/experimental-theme-compile.doc.mjs +1 -1
- package/clients/cli/commands/experimental-theme-editor-new.doc.mjs +1 -1
- package/clients/cli/commands/experimental-theme-editor-set.doc.mjs +1 -1
- package/clients/cli/commands/experimental-theme-editor-show.doc.mjs +1 -1
- package/clients/cli/commands/experimental-theme-editor-undo.doc.mjs +1 -1
- package/clients/cli/commands/init.doc.mjs +36 -24
- package/clients/cli/commands/integration-check.doc.mjs +1 -1
- package/clients/cli/commands/mcp.doc.mjs +53 -0
- package/clients/cli/commands/mcp.mjs +51 -0
- package/clients/cli/commands/search.mjs +46 -9
- package/clients/cli/commands/template.mjs +3 -2
- package/clients/cli/commands/theme-build.doc.mjs +1 -1
- package/clients/cli/commands/theme.mjs +12 -2
- package/clients/cli/commands/upgrade.doc.mjs +3 -2
- package/clients/cli/commands.generated.json +1 -1
- package/clients/cli/formatters/index.mjs +52 -6
- package/clients/cli/index.mjs +23 -17
- package/clients/cli/lib/base-gate.mjs +37 -5
- package/clients/cli/lib/define-command.mjs +82 -4
- package/clients/cli/lib/json-shim.mjs +61 -4
- package/clients/cli/lib/manifest.mjs +9 -1
- package/clients/cli/lib/mcp-server.mjs +286 -0
- package/clients/cli/lib/mcp-tools.mjs +405 -0
- package/clients/cli/lib/other-cli-words.mjs +99 -0
- package/clients/cli/lib/stray-option.mjs +27 -1
- package/clients/cli/lib/unknown-command.mjs +326 -11
- package/clients/cli/manifest.generated.json +1 -1
- package/clients/cli/run.mjs +1 -1
- package/foundation/agent-docs/agent-docs.d.mts +49 -1
- package/foundation/agent-docs/agent-docs.mjs +108 -7
- package/foundation/agent-docs/computer-agent-text.mjs +1 -1
- package/foundation/bases/core.d.mts +1 -1
- package/foundation/bases/core.mjs +3 -3
- package/foundation/bases/resolve.d.mts +4 -8
- package/foundation/bases/resolve.mjs +15 -21
- package/foundation/bases/state.d.mts +15 -9
- package/foundation/bases/state.mjs +33 -6
- package/foundation/config/project.d.mts +5 -4
- package/foundation/config/project.mjs +33 -17
- package/foundation/discovery/component-discovery.mjs +15 -28
- package/foundation/discovery/icon-imports.d.mts +66 -0
- package/foundation/discovery/icon-imports.mjs +225 -0
- package/foundation/discovery/icon-ranking.d.mts +12 -2
- package/foundation/discovery/icon-ranking.mjs +197 -10
- package/foundation/discovery/icon-set-checks.mjs +2 -1
- package/foundation/discovery/icon-set-discovery.d.mts +28 -0
- package/foundation/discovery/icon-set-discovery.mjs +42 -0
- package/foundation/discovery/icon-set-writer.d.mts +2 -11
- package/foundation/discovery/icon-set-writer.mjs +3 -29
- package/foundation/discovery/module-exports.d.mts +1 -1
- package/foundation/discovery/module-exports.mjs +136 -33
- package/foundation/discovery/name-roots.d.mts +5 -0
- package/foundation/discovery/name-roots.mjs +11 -0
- package/foundation/discovery/runner-allowlist.d.mts +1 -0
- package/foundation/discovery/runner-allowlist.mjs +2 -0
- package/foundation/discovery/runner-commands.mjs +1 -0
- package/foundation/discovery/template-adapter.d.mts +1 -1
- package/foundation/discovery/template-destination.d.mts +14 -6
- package/foundation/discovery/template-destination.mjs +42 -8
- package/foundation/discovery/template-icons.d.mts +45 -2
- package/foundation/discovery/template-icons.mjs +26 -54
- package/foundation/discovery/template-needs.d.mts +28 -2
- package/foundation/discovery/template-needs.mjs +92 -11
- package/foundation/discovery/theme-discovery.d.mts +8 -0
- package/foundation/discovery/theme-discovery.mjs +23 -6
- package/foundation/discovery/theme-imports.mjs +2 -4
- package/foundation/doc-compiler/parse-readable.mjs +4 -3
- package/foundation/doc-compiler/stored-docs.d.mts +13 -0
- package/foundation/doc-compiler/stored-docs.mjs +74 -3
- package/foundation/env/cli-command.d.mts +68 -10
- package/foundation/env/cli-command.mjs +116 -22
- package/foundation/env/project-scope.d.mts +9 -0
- package/foundation/env/project-scope.mjs +28 -2
- package/foundation/fs/gather-cache.d.mts +23 -0
- package/foundation/fs/gather-cache.mjs +94 -2
- package/foundation/fs/module-loader.d.mts +3 -1
- package/foundation/fs/module-loader.mjs +85 -5
- package/foundation/fs/read-record.mjs +9 -5
- package/foundation/identity/package-names.d.mts +18 -0
- package/foundation/identity/package-names.mjs +19 -0
- package/foundation/identity/providers.mjs +3 -2
- package/foundation/integrations/icon-features.d.mts +63 -0
- package/foundation/integrations/icon-features.mjs +54 -0
- package/foundation/integrations/integrations.d.mts +13 -1
- package/foundation/integrations/integrations.mjs +47 -6
- package/foundation/integrations/pack-state.d.mts +21 -0
- package/foundation/integrations/pack-state.mjs +42 -19
- package/foundation/integrations/validate-contributions.d.mts +11 -3
- package/foundation/integrations/validate-contributions.mjs +51 -13
- package/foundation/release/cache.d.mts +13 -1
- package/foundation/release/cache.mjs +94 -14
- package/foundation/release/notices.d.mts +15 -0
- package/foundation/release/notices.mjs +111 -7
- package/foundation/release/project.d.mts +3 -4
- package/foundation/release/project.mjs +5 -6
- package/foundation/render/client-bundle.d.mts +126 -0
- package/foundation/render/client-bundle.mjs +565 -0
- package/foundation/render/cut-short.d.mts +7 -1
- package/foundation/render/cut-short.mjs +46 -6
- package/foundation/render/embedded-imports.d.mts +4 -3
- package/foundation/render/embedded-imports.mjs +13 -8
- package/foundation/render/esbuild-dependency.d.mts +14 -0
- package/foundation/render/esbuild-dependency.mjs +41 -0
- package/foundation/render/file-header.mjs +5 -4
- package/foundation/render/page-worker.mjs +562 -86
- package/foundation/render/picture-chrome.mjs +54 -29
- package/foundation/render/picture-playwright.mjs +78 -42
- package/foundation/render/picture-window.d.mts +33 -0
- package/foundation/render/picture-window.mjs +78 -0
- package/foundation/render/render-page.d.mts +55 -4
- package/foundation/render/render-page.mjs +199 -28
- package/foundation/render/restore-folder.d.mts +13 -0
- package/foundation/render/restore-folder.mjs +30 -0
- package/foundation/render/served-packages.d.mts +2 -1
- package/foundation/render/served-packages.mjs +5 -3
- package/foundation/render/ts-paths.d.mts +11 -0
- package/foundation/render/ts-paths.mjs +27 -2
- package/foundation/render/value-uses.d.mts +43 -0
- package/foundation/render/value-uses.mjs +110 -0
- package/foundation/response/error-codes.d.mts +2 -1
- package/foundation/response/error-codes.doc.mjs +7 -1
- package/foundation/response/error-codes.mjs +10 -2
- package/foundation/response/response-types.doc.mjs +12 -12
- package/foundation/runtime/package-root.d.mts +8 -0
- package/foundation/runtime/package-root.mjs +20 -0
- package/foundation/suggest/other-command.d.mts +11 -0
- package/foundation/suggest/other-command.mjs +1 -1
- package/foundation/text/icon-id.d.mts +20 -0
- package/foundation/text/icon-id.mjs +40 -0
- package/foundation/text/icon-set-next.d.mts +25 -0
- package/foundation/text/icon-set-next.mjs +29 -0
- package/foundation/xle/browser.d.mts +2 -2
- package/package.json +7 -6
package/api/theme-edit/_png.mjs
CHANGED
|
@@ -378,3 +378,102 @@ export function withPngText(bytes, keyword, text) {
|
|
|
378
378
|
}
|
|
379
379
|
return Buffer.concat([PNG_SIGNATURE, ...chunks]);
|
|
380
380
|
}
|
|
381
|
+
|
|
382
|
+
/**
|
|
383
|
+
* The bytes of a PNG holding a picture's RGBA pixels, 8 bits a channel, each
|
|
384
|
+
* row unfiltered.
|
|
385
|
+
* @param {Picture} pic
|
|
386
|
+
* @returns {Buffer}
|
|
387
|
+
*/
|
|
388
|
+
export function encodePng({width, height, rgba}) {
|
|
389
|
+
/** @param {string} type @param {Buffer} data */
|
|
390
|
+
const chunk = (type, data) => {
|
|
391
|
+
const body = Buffer.concat([Buffer.from(type, 'latin1'), data]);
|
|
392
|
+
const head = Buffer.alloc(4);
|
|
393
|
+
head.writeUInt32BE(data.length);
|
|
394
|
+
const crc = Buffer.alloc(4);
|
|
395
|
+
crc.writeUInt32BE(zlib.crc32(body) >>> 0);
|
|
396
|
+
return Buffer.concat([head, body, crc]);
|
|
397
|
+
};
|
|
398
|
+
const ihdr = Buffer.alloc(13);
|
|
399
|
+
ihdr.writeUInt32BE(width, 0);
|
|
400
|
+
ihdr.writeUInt32BE(height, 4);
|
|
401
|
+
ihdr[8] = 8;
|
|
402
|
+
ihdr[9] = 6;
|
|
403
|
+
const stride = width * 4;
|
|
404
|
+
const rows = Buffer.alloc((stride + 1) * height);
|
|
405
|
+
for (let y = 0; y < height; y++)
|
|
406
|
+
rows.set(rgba.subarray(y * stride, (y + 1) * stride), y * (stride + 1) + 1);
|
|
407
|
+
return Buffer.concat([
|
|
408
|
+
PNG_SIGNATURE,
|
|
409
|
+
chunk('IHDR', ihdr),
|
|
410
|
+
chunk('IDAT', zlib.deflateSync(rows)),
|
|
411
|
+
chunk('IEND', Buffer.alloc(0)),
|
|
412
|
+
]);
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
/**
|
|
416
|
+
* A tall picture cut into pictures, in order, each cut only at the top of a
|
|
417
|
+
* row of parts: the end of a run of at least `gap` rows of one color (the
|
|
418
|
+
* page between two rows of cells; a cell's dashed edge breaks every run
|
|
419
|
+
* inside it). A piece ends at the lowest row top within `most` pixels; a
|
|
420
|
+
* row taller than that is a piece of its own, never cut through. A last
|
|
421
|
+
* piece shorter than `least` joins the one before it. A picture no taller
|
|
422
|
+
* than `most` is itself alone.
|
|
423
|
+
* @param {Picture} pic
|
|
424
|
+
* @param {number} most
|
|
425
|
+
* @param {{gap?: number, least?: number}} [options]
|
|
426
|
+
* @returns {Picture[]}
|
|
427
|
+
*/
|
|
428
|
+
export function cutTall(pic, most, {gap = 10, least = 300} = {}) {
|
|
429
|
+
const {width, height, rgba} = pic;
|
|
430
|
+
if (height <= most) return [pic];
|
|
431
|
+
const stride = width * 4;
|
|
432
|
+
/** @param {number} y */
|
|
433
|
+
const plain = y => {
|
|
434
|
+
const row = new Uint32Array(
|
|
435
|
+
rgba.buffer,
|
|
436
|
+
rgba.byteOffset + y * stride,
|
|
437
|
+
width,
|
|
438
|
+
);
|
|
439
|
+
const first = row[0];
|
|
440
|
+
for (let x = 1; x < width; x++) if (row[x] !== first) return false;
|
|
441
|
+
return true;
|
|
442
|
+
};
|
|
443
|
+
// Where a row of parts starts: the end of each run of `gap` plain rows.
|
|
444
|
+
/** @type {number[]} */
|
|
445
|
+
const rowTops = [];
|
|
446
|
+
for (let y = 0, run = 0; y < height; y++) {
|
|
447
|
+
if (plain(y)) run++;
|
|
448
|
+
else {
|
|
449
|
+
if (run >= gap && y - run > 0) rowTops.push(y);
|
|
450
|
+
run = 0;
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
/** Where each piece ends. @type {number[]} */
|
|
454
|
+
const ends = [];
|
|
455
|
+
for (let top = 0; top < height;) {
|
|
456
|
+
const limit = top + most;
|
|
457
|
+
let end = height;
|
|
458
|
+
if (limit < height) {
|
|
459
|
+
// The lowest row top the piece reaches; a row taller than `most`
|
|
460
|
+
// is a piece of its own, never cut.
|
|
461
|
+
const within = rowTops.filter(y => y > top && y <= limit);
|
|
462
|
+
end = within.length
|
|
463
|
+
? within[within.length - 1]
|
|
464
|
+
: (rowTops.find(y => y > limit) ?? height);
|
|
465
|
+
}
|
|
466
|
+
ends.push(end);
|
|
467
|
+
top = end;
|
|
468
|
+
}
|
|
469
|
+
if (ends.length > 1 && height - ends[ends.length - 2] < least)
|
|
470
|
+
ends.splice(ends.length - 2, 1);
|
|
471
|
+
return ends.map((end, i) => {
|
|
472
|
+
const top = i ? ends[i - 1] : 0;
|
|
473
|
+
return {
|
|
474
|
+
width,
|
|
475
|
+
height: end - top,
|
|
476
|
+
rgba: rgba.slice(top * stride, end * stride),
|
|
477
|
+
};
|
|
478
|
+
});
|
|
479
|
+
}
|
|
@@ -75,6 +75,22 @@ export function seeLine(cwd: string, slug: string, focus: "colors" | "components
|
|
|
75
75
|
stale?: string[];
|
|
76
76
|
pictures?: string[];
|
|
77
77
|
}): string;
|
|
78
|
+
/**
|
|
79
|
+
* What a template page needs that the app lacks, from its real imports:
|
|
80
|
+
* packages the app's package.json does not name (with the command that
|
|
81
|
+
* adds them), packages it names that are not installed (with the install
|
|
82
|
+
* command), and a StyleX compiler.
|
|
83
|
+
* @param {string} cwd
|
|
84
|
+
* @param {string} source
|
|
85
|
+
*/
|
|
86
|
+
export function pageNeeds(cwd: string, source: string): {
|
|
87
|
+
noCommand: boolean;
|
|
88
|
+
stylexCompiler: boolean;
|
|
89
|
+
installGuidance?: string | undefined;
|
|
90
|
+
missingPackages: string[];
|
|
91
|
+
notInstalled: string[];
|
|
92
|
+
installCommand: string | null;
|
|
93
|
+
};
|
|
78
94
|
/**
|
|
79
95
|
* Add pages to the in-app theme preview, and write the preview route the
|
|
80
96
|
* first time. With a description, the build ranking picks the template
|
|
@@ -35,7 +35,12 @@ import {
|
|
|
35
35
|
assertWithin,
|
|
36
36
|
PathSafetyError,
|
|
37
37
|
} from '../../foundation/fs/path-safety.mjs';
|
|
38
|
-
import {
|
|
38
|
+
import {
|
|
39
|
+
baseResolved,
|
|
40
|
+
installLine,
|
|
41
|
+
openProject,
|
|
42
|
+
packageManagerAddLine,
|
|
43
|
+
} from './_project.mjs';
|
|
39
44
|
import {P, wordTable} from './_tables.mjs';
|
|
40
45
|
import {
|
|
41
46
|
buildTheme,
|
|
@@ -90,6 +95,7 @@ import {
|
|
|
90
95
|
analyzeTemplateNeeds,
|
|
91
96
|
extractImportedPackages,
|
|
92
97
|
parsedSpecifiers,
|
|
98
|
+
referencedPaths,
|
|
93
99
|
} from '../../foundation/discovery/template-needs.mjs';
|
|
94
100
|
import {detectStylingSystem} from '../../foundation/agent-docs/agent-docs.mjs';
|
|
95
101
|
import {
|
|
@@ -101,8 +107,10 @@ import {
|
|
|
101
107
|
} from './_context.mjs';
|
|
102
108
|
import {ERROR_CODES} from '../../foundation/response/error-codes.mjs';
|
|
103
109
|
import {AstryxError} from '../error.mjs';
|
|
110
|
+
import {installGuidanceFor} from '../../foundation/env/cli-command.mjs';
|
|
104
111
|
import {
|
|
105
112
|
formatCliCommand,
|
|
113
|
+
installDependenciesCommand,
|
|
106
114
|
quoteCommandArgument,
|
|
107
115
|
} from '../../foundation/env/package-manager.mjs';
|
|
108
116
|
import {sha256} from '../../foundation/render/source-block.mjs';
|
|
@@ -251,8 +259,8 @@ function layoutImportsSheet(cwd, app, sheet, dir = app) {
|
|
|
251
259
|
/**
|
|
252
260
|
* The modules a file imports, from its import statements: a script's
|
|
253
261
|
* through the shared reader of import statements (its syntax tree, so a
|
|
254
|
-
* comment or a string says nothing)
|
|
255
|
-
* (comments left out).
|
|
262
|
+
* comment or a string says nothing) with the files its leading reference
|
|
263
|
+
* comments name, or the `@import` rules of a stylesheet (comments left out).
|
|
256
264
|
* @param {string} file
|
|
257
265
|
* @param {string} text
|
|
258
266
|
* @returns {string[]}
|
|
@@ -264,7 +272,8 @@ function importSpecifiers(file, text) {
|
|
|
264
272
|
.replace(/\/\*[\s\S]*?\*\//g, '')
|
|
265
273
|
.matchAll(/@import\s+(?:url\()?\s*['"]([^'"]+)['"]/g),
|
|
266
274
|
].map(m => m[1]);
|
|
267
|
-
|
|
275
|
+
// The new app's type check reads a referenced file as it reads an import.
|
|
276
|
+
return [...parsedSpecifiers(text), ...referencedPaths(text)];
|
|
268
277
|
}
|
|
269
278
|
|
|
270
279
|
/**
|
|
@@ -714,7 +723,7 @@ function typeScriptNotes(cwd, dir, added) {
|
|
|
714
723
|
return hasTs
|
|
715
724
|
? []
|
|
716
725
|
: [
|
|
717
|
-
`the app has no TypeScript, and the preview's files are .tsx, so the next build sets it up; to do it now: ${
|
|
726
|
+
`the app has no TypeScript, and the preview's files are .tsx, so the next build sets it up; to do it now: ${typescriptInstallLine(cwd)}`,
|
|
718
727
|
];
|
|
719
728
|
}
|
|
720
729
|
const templates = added.filter(id => !DEFAULT_PAGE_IDS.includes(id));
|
|
@@ -4023,6 +4032,20 @@ function appRootOf(cwd, dir) {
|
|
|
4023
4032
|
return cwd;
|
|
4024
4033
|
}
|
|
4025
4034
|
|
|
4035
|
+
/**
|
|
4036
|
+
* The step that adds TypeScript and React's and Node's types to the app: the
|
|
4037
|
+
* integration's install guidance when one is given, else the package
|
|
4038
|
+
* manager's add command, as a dev dependency.
|
|
4039
|
+
* @param {string} cwd
|
|
4040
|
+
*/
|
|
4041
|
+
function typescriptInstallLine(cwd) {
|
|
4042
|
+
const packages = ['typescript', '@types/react', '@types/node'];
|
|
4043
|
+
return (
|
|
4044
|
+
installGuidanceFor(packages, cwd) ??
|
|
4045
|
+
installLine(cwd, packages).replace(/ (add|install) /, ' $1 -D ')
|
|
4046
|
+
);
|
|
4047
|
+
}
|
|
4048
|
+
|
|
4026
4049
|
/**
|
|
4027
4050
|
* What a template page needs that the app lacks, from its real imports:
|
|
4028
4051
|
* packages the app's package.json does not name (with the command that
|
|
@@ -4031,7 +4054,7 @@ function appRootOf(cwd, dir) {
|
|
|
4031
4054
|
* @param {string} cwd
|
|
4032
4055
|
* @param {string} source
|
|
4033
4056
|
*/
|
|
4034
|
-
function pageNeeds(cwd, source) {
|
|
4057
|
+
export function pageNeeds(cwd, source) {
|
|
4035
4058
|
const pkgs = [...extractImportedPackages(source)];
|
|
4036
4059
|
const needs = analyzeTemplateNeeds(source, cwd);
|
|
4037
4060
|
/** @type {Record<string, string>} */
|
|
@@ -4059,31 +4082,39 @@ function pageNeeds(cwd, source) {
|
|
|
4059
4082
|
const notInstalled = absent.filter(p => p in declared);
|
|
4060
4083
|
const undeclared = absent.filter(p => !(p in declared));
|
|
4061
4084
|
const missingPackages = [...needs.missingPackages, ...undeclared];
|
|
4085
|
+
const installDeps = notInstalled.length
|
|
4086
|
+
? [installDependenciesCommand(cwd)]
|
|
4087
|
+
: [];
|
|
4062
4088
|
const commands = [
|
|
4063
4089
|
...(needs.installCommand
|
|
4064
4090
|
? [[needs.installCommand, ...undeclared].join(' ')]
|
|
4065
4091
|
: undeclared.length
|
|
4066
|
-
? [
|
|
4092
|
+
? [packageManagerAddLine(cwd, undeclared)]
|
|
4067
4093
|
: []),
|
|
4068
|
-
...
|
|
4094
|
+
...installDeps,
|
|
4069
4095
|
];
|
|
4096
|
+
const guidance = missingPackages.length
|
|
4097
|
+
? installGuidanceFor(missingPackages, cwd)
|
|
4098
|
+
: undefined;
|
|
4070
4099
|
return {
|
|
4071
4100
|
missingPackages,
|
|
4072
4101
|
notInstalled,
|
|
4073
4102
|
installCommand: commands.length ? commands.join(' && ') : null,
|
|
4074
|
-
|
|
4103
|
+
// The integration's line for adding them, followed by the install of
|
|
4104
|
+
// what the package.json already names.
|
|
4105
|
+
...(guidance
|
|
4106
|
+
? {installGuidance: [guidance, ...installDeps].join('; then ')}
|
|
4107
|
+
: {}),
|
|
4108
|
+
noCommand:
|
|
4109
|
+
needs.missingPackages.length > 0 &&
|
|
4110
|
+
!needs.installCommand &&
|
|
4111
|
+
!needs.installGuidance,
|
|
4075
4112
|
stylexCompiler:
|
|
4076
4113
|
pkgs.includes('@stylexjs/stylex') &&
|
|
4077
4114
|
detectStylingSystem(cwd) !== 'stylex',
|
|
4078
4115
|
};
|
|
4079
4116
|
}
|
|
4080
4117
|
|
|
4081
|
-
/** The command that installs what the package.json names. @param {string} cwd */
|
|
4082
|
-
function installCommandOf(cwd) {
|
|
4083
|
-
// The package manager `installLine` names, with its install verb.
|
|
4084
|
-
return installLine(cwd, []).trim().replace(/ add$/, ' install');
|
|
4085
|
-
}
|
|
4086
|
-
|
|
4087
4118
|
/**
|
|
4088
4119
|
* The settings of the theme a preview wears, or a refusal that names the
|
|
4089
4120
|
* themes there are: the closest editor theme by name, or for a package
|
|
@@ -4619,7 +4650,7 @@ async function addPreview(description, options, box) {
|
|
|
4619
4650
|
};
|
|
4620
4651
|
/** @type {Array<{id: string, label: string, text: string}>} */
|
|
4621
4652
|
const add = [];
|
|
4622
|
-
/** @type {Array<{page: string, reason: string, installCommand: string | null}>} */
|
|
4653
|
+
/** @type {Array<{page: string, reason: string, installCommand: string | null, installGuidance?: string}>} */
|
|
4623
4654
|
const skipped = [];
|
|
4624
4655
|
/** @type {Array<{page: string, why: string}>} */
|
|
4625
4656
|
const matched = [];
|
|
@@ -4723,6 +4754,7 @@ async function addPreview(description, options, box) {
|
|
|
4723
4754
|
needsCompiler
|
|
4724
4755
|
) {
|
|
4725
4756
|
const installCommand = needs.installCommand;
|
|
4757
|
+
const installGuidance = needs.installGuidance;
|
|
4726
4758
|
skipped.push({
|
|
4727
4759
|
page: pick.name,
|
|
4728
4760
|
reason: `${skipReason({
|
|
@@ -4731,8 +4763,10 @@ async function addPreview(description, options, box) {
|
|
|
4731
4763
|
stylexCompiler: needsCompiler,
|
|
4732
4764
|
})}${needs.noCommand ? ' (the app has more than one lockfile, so install it with the package manager you use)' : ''}`,
|
|
4733
4765
|
installCommand,
|
|
4766
|
+
...(installGuidance ? {installGuidance} : {}),
|
|
4734
4767
|
});
|
|
4735
|
-
|
|
4768
|
+
const run = installGuidance ?? installCommand;
|
|
4769
|
+
if (run) runs.push(run);
|
|
4736
4770
|
if (needsCompiler) stylexSkipped = true;
|
|
4737
4771
|
if (i === 0) firstSkipped = true;
|
|
4738
4772
|
continue;
|
|
@@ -4743,7 +4777,7 @@ async function addPreview(description, options, box) {
|
|
|
4743
4777
|
}
|
|
4744
4778
|
for (const s of skipped)
|
|
4745
4779
|
notes.push(
|
|
4746
|
-
`the ${s.page} page was not added: it ${s.reason}${s.installCommand ? `; ${s.installCommand}, then add it again` : ''}`,
|
|
4780
|
+
`the ${s.page} page was not added: it ${s.reason}${(s.installGuidance ?? s.installCommand) ? `; ${s.installGuidance ?? s.installCommand}, then add it again` : ''}`,
|
|
4747
4781
|
);
|
|
4748
4782
|
if (firstSkipped && add.length && !explicit)
|
|
4749
4783
|
notes.push(`added ${add.map(a => a.id).join(', ')} in its place`);
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
export function familyOf(project: import("./_project.mjs").ThemeProject, name: string): string | null;
|
|
12
12
|
/**
|
|
13
13
|
* The sections of the theme-building page whose parts the theme's settings
|
|
14
|
-
* set on their own (`--on badge
|
|
15
|
-
* of, each in its section. A setting for the whole theme (a color, the
|
|
14
|
+
* set on their own (`--on badge`, or a group of parts such as `--on
|
|
15
|
+
* inputs`): the components each part names a class of, each in its section. A setting for the whole theme (a color, the
|
|
16
16
|
* corners) sets no section here: the sample page and the open states show
|
|
17
17
|
* it.
|
|
18
18
|
* @param {import('./_project.mjs').ThemeProject} project
|
|
@@ -253,37 +253,40 @@ export function previewRouteSource({ pages, theme, by, }: {
|
|
|
253
253
|
/** A new picture run. @returns {PictureRun} */
|
|
254
254
|
export function newPictureRun(): PictureRun;
|
|
255
255
|
/**
|
|
256
|
-
* A whole-page PNG of an HTML file
|
|
257
|
-
* installed, else a Chrome or Chromium found on the machine. Each browser
|
|
258
|
-
* gets its own time bound, and the next one its turn when one fails or
|
|
259
|
-
* hangs. Not ok with a reason when none is there or every one failed: the
|
|
260
|
-
* reason then names each one's real error. When a later browser took the
|
|
261
|
-
* picture, `note` says why an earlier one did not. `cutShort` is the text
|
|
262
|
-
* the page draws cut short, measured in it by the browser that took the
|
|
263
|
-
* picture, each with whether its part keeping its width draws it whole;
|
|
264
|
-
* absent when that browser's script measured nothing.
|
|
256
|
+
* A whole-page PNG of an HTML file: {@link screenshots} with one picture.
|
|
265
257
|
* @param {import('./_project.mjs').ThemeProject} project
|
|
266
258
|
* @param {string} html absolute
|
|
267
259
|
* @param {string} png absolute
|
|
268
260
|
* @param {'light' | 'dark'} mode
|
|
261
|
+
* @param {PictureRun} [run]
|
|
262
|
+
* @returns {Promise<PictureResult>}
|
|
263
|
+
*/
|
|
264
|
+
export function screenshot(project: import("./_project.mjs").ThemeProject, html: string, png: string, mode: "light" | "dark", run?: PictureRun): Promise<PictureResult>;
|
|
265
|
+
/**
|
|
266
|
+
* Whole-page PNGs of HTML files, all with one browser: a Playwright the
|
|
267
|
+
* project has installed, else a Chrome or Chromium found on the machine.
|
|
268
|
+
* One browser start for the whole batch, a few pages drawn at once, so a
|
|
269
|
+
* run of many pictures costs about one start. Each browser gets its own
|
|
270
|
+
* time bound, and the next one the pictures still to take when one fails
|
|
271
|
+
* or hangs. A result for each picture, in order, up to the first that was
|
|
272
|
+
* not taken: that one not ok with a reason (naming each browser's real
|
|
273
|
+
* error, or that none is there), and none after it. When a later browser
|
|
274
|
+
* took a picture, its `notes` say why an earlier one did not. `cutShort` is
|
|
275
|
+
* the text the page draws cut short, measured in it by the browser that
|
|
276
|
+
* took the picture, each with whether its part keeping its width draws it
|
|
277
|
+
* whole; absent when that browser's script measured nothing.
|
|
278
|
+
* @param {import('./_project.mjs').ThemeProject} project
|
|
279
|
+
* @param {Array<{html: string, png: string, mode: 'light' | 'dark'}>} jobs
|
|
280
|
+
* absolute paths
|
|
269
281
|
* @param {PictureRun} [run] what earlier pictures of the same run learned:
|
|
270
282
|
* a browser that failed or hung there is not tried again
|
|
271
|
-
* @returns {Promise<
|
|
283
|
+
* @returns {Promise<PictureResult[]>}
|
|
272
284
|
*/
|
|
273
|
-
export function
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
part: string | null;
|
|
279
|
-
text: string;
|
|
280
|
-
whole: boolean;
|
|
281
|
-
}>;
|
|
282
|
-
} | {
|
|
283
|
-
ok: false;
|
|
284
|
-
reason: string;
|
|
285
|
-
stopped?: string;
|
|
286
|
-
}>;
|
|
285
|
+
export function screenshots(project: import("./_project.mjs").ThemeProject, jobs: Array<{
|
|
286
|
+
html: string;
|
|
287
|
+
png: string;
|
|
288
|
+
mode: "light" | "dark";
|
|
289
|
+
}>, run?: PictureRun): Promise<PictureResult[]>;
|
|
287
290
|
/**
|
|
288
291
|
* What a picture shows in place of a font stack: a role whose stack ends in
|
|
289
292
|
* a generic of a kind (serif, monospace, cursive) and none of whose named
|
|
@@ -437,4 +440,19 @@ export { APP_COPY_MARK } from "./_marks.mjs";
|
|
|
437
440
|
export type PictureRun = {
|
|
438
441
|
failed: Map<string, string>;
|
|
439
442
|
};
|
|
443
|
+
export type PictureResult = {
|
|
444
|
+
ok: true;
|
|
445
|
+
file: string;
|
|
446
|
+
notes?: string[];
|
|
447
|
+
cutShort?: Array<{
|
|
448
|
+
part: string | null;
|
|
449
|
+
text: string;
|
|
450
|
+
whole: boolean;
|
|
451
|
+
broken?: boolean;
|
|
452
|
+
}>;
|
|
453
|
+
} | {
|
|
454
|
+
ok: false;
|
|
455
|
+
reason: string;
|
|
456
|
+
stopped?: string;
|
|
457
|
+
};
|
|
440
458
|
import { SHOWCASE_GROUPS } from './_tables.mjs';
|