@12ui/design 0.2.72 → 0.2.74
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 +242 -54
- package/SKILL.md +28 -33
- package/dist/cli-arguments.d.ts.map +1 -1
- package/dist/cli-arguments.js +3 -0
- package/dist/cli-arguments.js.map +1 -1
- package/dist/cli-branch-command.d.ts.map +1 -1
- package/dist/cli-branch-command.js +4 -0
- package/dist/cli-branch-command.js.map +1 -1
- package/dist/cli-capabilities.d.ts +26 -1
- package/dist/cli-capabilities.d.ts.map +1 -1
- package/dist/cli-capabilities.js +26 -1
- package/dist/cli-capabilities.js.map +1 -1
- package/dist/cli-corpus-command.d.ts +5 -4
- package/dist/cli-corpus-command.d.ts.map +1 -1
- package/dist/cli-corpus-command.js +17 -26
- package/dist/cli-corpus-command.js.map +1 -1
- package/dist/cli-corpus-run.js +1 -1
- package/dist/cli-corpus-run.js.map +1 -1
- package/dist/cli-draft-command.js +1 -1
- package/dist/cli-draft-command.js.map +1 -1
- package/dist/cli-help/design.d.ts +26 -6
- package/dist/cli-help/design.d.ts.map +1 -1
- package/dist/cli-help/design.js +39 -7
- package/dist/cli-help/design.js.map +1 -1
- package/dist/cli-help/index.d.ts +113 -7
- package/dist/cli-help/index.d.ts.map +1 -1
- package/dist/cli-help/index.js +2 -0
- package/dist/cli-help/index.js.map +1 -1
- package/dist/cli-help/meta.d.ts +1 -1
- package/dist/cli-help/meta.d.ts.map +1 -1
- package/dist/cli-help/meta.js +2 -1
- package/dist/cli-help/meta.js.map +1 -1
- package/dist/cli-help/workflow.d.ts +90 -0
- package/dist/cli-help/workflow.d.ts.map +1 -0
- package/dist/cli-help/workflow.js +89 -0
- package/dist/cli-help/workflow.js.map +1 -0
- package/dist/cli-open-browser.d.ts +7 -0
- package/dist/cli-open-browser.d.ts.map +1 -0
- package/dist/cli-open-browser.js +25 -0
- package/dist/cli-open-browser.js.map +1 -0
- package/dist/cli-prototype-command.d.ts +3 -1
- package/dist/cli-prototype-command.d.ts.map +1 -1
- package/dist/cli-prototype-command.js +33 -7
- package/dist/cli-prototype-command.js.map +1 -1
- package/dist/cli-review-command.d.ts.map +1 -1
- package/dist/cli-review-command.js +1 -16
- package/dist/cli-review-command.js.map +1 -1
- package/dist/cli-run.d.ts.map +1 -1
- package/dist/cli-run.js +35 -3
- package/dist/cli-run.js.map +1 -1
- package/dist/cli-usage.d.ts.map +1 -1
- package/dist/cli-usage.js +39 -5
- package/dist/cli-usage.js.map +1 -1
- package/dist/cli-workflow-command.d.ts +8 -0
- package/dist/cli-workflow-command.d.ts.map +1 -0
- package/dist/cli-workflow-command.js +97 -0
- package/dist/cli-workflow-command.js.map +1 -0
- package/dist/cli-workspace-command.d.ts +25 -0
- package/dist/cli-workspace-command.d.ts.map +1 -0
- package/dist/cli-workspace-command.js +95 -0
- package/dist/cli-workspace-command.js.map +1 -0
- package/dist/config.d.ts +6 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +12 -4
- package/dist/config.js.map +1 -1
- package/dist/corpus-access.d.ts +11 -0
- package/dist/corpus-access.d.ts.map +1 -0
- package/dist/corpus-access.js +18 -0
- package/dist/corpus-access.js.map +1 -0
- package/dist/corpus-client.d.ts +11 -11
- package/dist/corpus-client.d.ts.map +1 -1
- package/dist/corpus-client.js +17 -6
- package/dist/corpus-client.js.map +1 -1
- package/dist/corpus-inspiration-failure.d.ts +1 -1
- package/dist/corpus-inspiration-failure.js +2 -2
- package/dist/corpus-inspiration-failure.js.map +1 -1
- package/dist/corpus-reference-download-retry.d.ts.map +1 -1
- package/dist/corpus-reference-download-retry.js +11 -1
- package/dist/corpus-reference-download-retry.js.map +1 -1
- package/dist/corpus-request-error.d.ts +2 -0
- package/dist/corpus-request-error.d.ts.map +1 -1
- package/dist/corpus-request-error.js +2 -0
- package/dist/corpus-request-error.js.map +1 -1
- package/dist/corpus-retry-guidance.d.ts +5 -0
- package/dist/corpus-retry-guidance.d.ts.map +1 -0
- package/dist/corpus-retry-guidance.js +18 -0
- package/dist/corpus-retry-guidance.js.map +1 -0
- package/dist/improve-pricing-plan.d.ts.map +1 -1
- package/dist/improve-pricing-plan.js +2 -4
- package/dist/improve-pricing-plan.js.map +1 -1
- package/dist/index.d.ts +10 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -1
- package/dist/index.js.map +1 -1
- package/dist/legacy-skill-catalog.d.ts.map +1 -1
- package/dist/legacy-skill-catalog.js +41 -0
- package/dist/legacy-skill-catalog.js.map +1 -1
- package/dist/mcp-slate-command.d.ts +31 -0
- package/dist/mcp-slate-command.d.ts.map +1 -0
- package/dist/mcp-slate-command.js +123 -0
- package/dist/mcp-slate-command.js.map +1 -0
- package/dist/mcp-slate-image.d.ts +22 -0
- package/dist/mcp-slate-image.d.ts.map +1 -0
- package/dist/mcp-slate-image.js +28 -0
- package/dist/mcp-slate-image.js.map +1 -0
- package/dist/mcp-slate-latest.d.ts +13 -0
- package/dist/mcp-slate-latest.d.ts.map +1 -0
- package/dist/mcp-slate-latest.js +34 -0
- package/dist/mcp-slate-latest.js.map +1 -0
- package/dist/mcp-slate-names.d.ts +25 -0
- package/dist/mcp-slate-names.d.ts.map +1 -0
- package/dist/mcp-slate-names.js +49 -0
- package/dist/mcp-slate-names.js.map +1 -0
- package/dist/mcp-slate-resource.d.ts +5 -0
- package/dist/mcp-slate-resource.d.ts.map +1 -0
- package/dist/mcp-slate-resource.js +37 -0
- package/dist/mcp-slate-resource.js.map +1 -0
- package/dist/mcp-slate-run.d.ts +41 -0
- package/dist/mcp-slate-run.d.ts.map +1 -0
- package/dist/mcp-slate-run.js +88 -0
- package/dist/mcp-slate-run.js.map +1 -0
- package/dist/mcp-slate-tool-defs.d.ts +61 -0
- package/dist/mcp-slate-tool-defs.d.ts.map +1 -0
- package/dist/mcp-slate-tool-defs.js +247 -0
- package/dist/mcp-slate-tool-defs.js.map +1 -0
- package/dist/mcp-slate-tools.d.ts +8 -0
- package/dist/mcp-slate-tools.d.ts.map +1 -0
- package/dist/mcp-slate-tools.js +45 -0
- package/dist/mcp-slate-tools.js.map +1 -0
- package/dist/mcp-slate-ui-copy.d.ts +145 -0
- package/dist/mcp-slate-ui-copy.d.ts.map +1 -0
- package/dist/mcp-slate-ui-copy.js +164 -0
- package/dist/mcp-slate-ui-copy.js.map +1 -0
- package/dist/mcp-slate-ui-script-bridge.d.ts +18 -0
- package/dist/mcp-slate-ui-script-bridge.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-bridge.js +137 -0
- package/dist/mcp-slate-ui-script-bridge.js.map +1 -0
- package/dist/mcp-slate-ui-script-browser.d.ts +12 -0
- package/dist/mcp-slate-ui-script-browser.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-browser.js +19 -0
- package/dist/mcp-slate-ui-script-browser.js.map +1 -0
- package/dist/mcp-slate-ui-script-dialog.d.ts +21 -0
- package/dist/mcp-slate-ui-script-dialog.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-dialog.js +321 -0
- package/dist/mcp-slate-ui-script-dialog.js.map +1 -0
- package/dist/mcp-slate-ui-script-inline.d.ts +10 -0
- package/dist/mcp-slate-ui-script-inline.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-inline.js +224 -0
- package/dist/mcp-slate-ui-script-inline.js.map +1 -0
- package/dist/mcp-slate-ui-script-inspiration.d.ts +13 -0
- package/dist/mcp-slate-ui-script-inspiration.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-inspiration.js +236 -0
- package/dist/mcp-slate-ui-script-inspiration.js.map +1 -0
- package/dist/mcp-slate-ui-script-more.d.ts +32 -0
- package/dist/mcp-slate-ui-script-more.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-more.js +289 -0
- package/dist/mcp-slate-ui-script-more.js.map +1 -0
- package/dist/mcp-slate-ui-script-progress.d.ts +7 -0
- package/dist/mcp-slate-ui-script-progress.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-progress.js +9 -0
- package/dist/mcp-slate-ui-script-progress.js.map +1 -0
- package/dist/mcp-slate-ui-script-remote.d.ts +28 -0
- package/dist/mcp-slate-ui-script-remote.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-remote.js +147 -0
- package/dist/mcp-slate-ui-script-remote.js.map +1 -0
- package/dist/mcp-slate-ui-script-scribble.d.ts +19 -0
- package/dist/mcp-slate-ui-script-scribble.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-scribble.js +114 -0
- package/dist/mcp-slate-ui-script-scribble.js.map +1 -0
- package/dist/mcp-slate-ui-script-select.d.ts +16 -0
- package/dist/mcp-slate-ui-script-select.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-select.js +73 -0
- package/dist/mcp-slate-ui-script-select.js.map +1 -0
- package/dist/mcp-slate-ui-script-stage.d.ts +12 -0
- package/dist/mcp-slate-ui-script-stage.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-stage.js +180 -0
- package/dist/mcp-slate-ui-script-stage.js.map +1 -0
- package/dist/mcp-slate-ui-script-state.d.ts +13 -0
- package/dist/mcp-slate-ui-script-state.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script-state.js +306 -0
- package/dist/mcp-slate-ui-script-state.js.map +1 -0
- package/dist/mcp-slate-ui-script.d.ts +27 -0
- package/dist/mcp-slate-ui-script.d.ts.map +1 -0
- package/dist/mcp-slate-ui-script.js +60 -0
- package/dist/mcp-slate-ui-script.js.map +1 -0
- package/dist/mcp-slate-ui-styles-dialog.d.ts +20 -0
- package/dist/mcp-slate-ui-styles-dialog.d.ts.map +1 -0
- package/dist/mcp-slate-ui-styles-dialog.js +95 -0
- package/dist/mcp-slate-ui-styles-dialog.js.map +1 -0
- package/dist/mcp-slate-ui-styles-stage.d.ts +19 -0
- package/dist/mcp-slate-ui-styles-stage.d.ts.map +1 -0
- package/dist/mcp-slate-ui-styles-stage.js +67 -0
- package/dist/mcp-slate-ui-styles-stage.js.map +1 -0
- package/dist/mcp-slate-ui-styles.d.ts +18 -0
- package/dist/mcp-slate-ui-styles.d.ts.map +1 -0
- package/dist/mcp-slate-ui-styles.js +132 -0
- package/dist/mcp-slate-ui-styles.js.map +1 -0
- package/dist/mcp-slate-ui.d.ts +16 -0
- package/dist/mcp-slate-ui.d.ts.map +1 -0
- package/dist/mcp-slate-ui.js +59 -0
- package/dist/mcp-slate-ui.js.map +1 -0
- package/dist/mcp-slate-workspace-tools.d.ts +15 -0
- package/dist/mcp-slate-workspace-tools.d.ts.map +1 -0
- package/dist/mcp-slate-workspace-tools.js +155 -0
- package/dist/mcp-slate-workspace-tools.js.map +1 -0
- package/dist/mcp-tool-definitions.d.ts.map +1 -1
- package/dist/mcp-tool-definitions.js +9 -7
- package/dist/mcp-tool-definitions.js.map +1 -1
- package/dist/mcp-tool-handler.d.ts +8 -2
- package/dist/mcp-tool-handler.d.ts.map +1 -1
- package/dist/mcp-tool-handler.js +34 -13
- package/dist/mcp-tool-handler.js.map +1 -1
- package/dist/mcp-workflow-tools.d.ts +6 -0
- package/dist/mcp-workflow-tools.d.ts.map +1 -0
- package/dist/mcp-workflow-tools.js +108 -0
- package/dist/mcp-workflow-tools.js.map +1 -0
- package/dist/prototype-label-client.d.ts +5 -0
- package/dist/prototype-label-client.d.ts.map +1 -1
- package/dist/prototype-label-client.js.map +1 -1
- package/dist/prototype-poststep.d.ts +2 -2
- package/dist/prototype-poststep.d.ts.map +1 -1
- package/dist/prototype-poststep.js +3 -0
- package/dist/prototype-poststep.js.map +1 -1
- package/dist/prototype-run-record.d.ts +6 -2
- package/dist/prototype-run-record.d.ts.map +1 -1
- package/dist/prototype-run-record.js +6 -0
- package/dist/prototype-run-record.js.map +1 -1
- package/dist/prototype-runner.d.ts +2 -2
- package/dist/prototype-runner.d.ts.map +1 -1
- package/dist/prototype-runner.js +5 -2
- package/dist/prototype-runner.js.map +1 -1
- package/dist/prototype-workflow-contract.d.ts +13 -0
- package/dist/prototype-workflow-contract.d.ts.map +1 -0
- package/dist/prototype-workflow-contract.js +82 -0
- package/dist/prototype-workflow-contract.js.map +1 -0
- package/dist/prototype-workflow-labels.d.ts +29 -0
- package/dist/prototype-workflow-labels.d.ts.map +1 -0
- package/dist/prototype-workflow-labels.js +93 -0
- package/dist/prototype-workflow-labels.js.map +1 -0
- package/dist/run-journal-commands.d.ts.map +1 -1
- package/dist/run-journal-commands.js +18 -5
- package/dist/run-journal-commands.js.map +1 -1
- package/dist/server.d.ts +22 -2
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +44 -8
- package/dist/server.js.map +1 -1
- package/dist/slate-actions.d.ts +43 -0
- package/dist/slate-actions.d.ts.map +1 -0
- package/dist/slate-actions.js +108 -0
- package/dist/slate-actions.js.map +1 -0
- package/dist/slate-annotate.d.ts +36 -0
- package/dist/slate-annotate.d.ts.map +1 -0
- package/dist/slate-annotate.js +71 -0
- package/dist/slate-annotate.js.map +1 -0
- package/dist/slate-approvals.d.ts +61 -0
- package/dist/slate-approvals.d.ts.map +1 -0
- package/dist/slate-approvals.js +153 -0
- package/dist/slate-approvals.js.map +1 -0
- package/dist/slate-browser-decision.d.ts +30 -0
- package/dist/slate-browser-decision.d.ts.map +1 -0
- package/dist/slate-browser-decision.js +24 -0
- package/dist/slate-browser-decision.js.map +1 -0
- package/dist/slate-browser-host-script.d.ts +14 -0
- package/dist/slate-browser-host-script.d.ts.map +1 -0
- package/dist/slate-browser-host-script.js +125 -0
- package/dist/slate-browser-host-script.js.map +1 -0
- package/dist/slate-browser-host.d.ts +9 -0
- package/dist/slate-browser-host.d.ts.map +1 -0
- package/dist/slate-browser-host.js +37 -0
- package/dist/slate-browser-host.js.map +1 -0
- package/dist/slate-browser-server.d.ts +37 -0
- package/dist/slate-browser-server.d.ts.map +1 -0
- package/dist/slate-browser-server.js +186 -0
- package/dist/slate-browser-server.js.map +1 -0
- package/dist/slate-commit.d.ts +28 -0
- package/dist/slate-commit.d.ts.map +1 -0
- package/dist/slate-commit.js +218 -0
- package/dist/slate-commit.js.map +1 -0
- package/dist/slate-corpus.d.ts +14 -0
- package/dist/slate-corpus.d.ts.map +1 -0
- package/dist/slate-corpus.js +32 -0
- package/dist/slate-corpus.js.map +1 -0
- package/dist/slate-edit-prompt.d.ts +18 -0
- package/dist/slate-edit-prompt.d.ts.map +1 -0
- package/dist/slate-edit-prompt.js +41 -0
- package/dist/slate-edit-prompt.js.map +1 -0
- package/dist/slate-edit-runner.d.ts +4 -0
- package/dist/slate-edit-runner.d.ts.map +1 -0
- package/dist/slate-edit-runner.js +90 -0
- package/dist/slate-edit-runner.js.map +1 -0
- package/dist/slate-editability.d.ts +20 -0
- package/dist/slate-editability.d.ts.map +1 -0
- package/dist/slate-editability.js +19 -0
- package/dist/slate-editability.js.map +1 -0
- package/dist/slate-errors.d.ts +15 -0
- package/dist/slate-errors.d.ts.map +1 -0
- package/dist/slate-errors.js +21 -0
- package/dist/slate-errors.js.map +1 -0
- package/dist/slate-handoff-options.d.ts +40 -0
- package/dist/slate-handoff-options.d.ts.map +1 -0
- package/dist/slate-handoff-options.js +117 -0
- package/dist/slate-handoff-options.js.map +1 -0
- package/dist/slate-handoff.d.ts +11 -0
- package/dist/slate-handoff.d.ts.map +1 -0
- package/dist/slate-handoff.js +56 -0
- package/dist/slate-handoff.js.map +1 -0
- package/dist/slate-ids.d.ts +33 -0
- package/dist/slate-ids.d.ts.map +1 -0
- package/dist/slate-ids.js +47 -0
- package/dist/slate-ids.js.map +1 -0
- package/dist/slate-image-executor.d.ts +39 -0
- package/dist/slate-image-executor.d.ts.map +1 -0
- package/dist/slate-image-executor.js +52 -0
- package/dist/slate-image-executor.js.map +1 -0
- package/dist/slate-inspiration.d.ts +22 -0
- package/dist/slate-inspiration.d.ts.map +1 -0
- package/dist/slate-inspiration.js +112 -0
- package/dist/slate-inspiration.js.map +1 -0
- package/dist/slate-labels.d.ts +11 -0
- package/dist/slate-labels.d.ts.map +1 -0
- package/dist/slate-labels.js +32 -0
- package/dist/slate-labels.js.map +1 -0
- package/dist/slate-ledger.d.ts +29 -0
- package/dist/slate-ledger.d.ts.map +1 -0
- package/dist/slate-ledger.js +65 -0
- package/dist/slate-ledger.js.map +1 -0
- package/dist/slate-liveness.d.ts +26 -0
- package/dist/slate-liveness.d.ts.map +1 -0
- package/dist/slate-liveness.js +49 -0
- package/dist/slate-liveness.js.map +1 -0
- package/dist/slate-local-image.d.ts +19 -0
- package/dist/slate-local-image.d.ts.map +1 -0
- package/dist/slate-local-image.js +36 -0
- package/dist/slate-local-image.js.map +1 -0
- package/dist/slate-lock.d.ts +64 -0
- package/dist/slate-lock.d.ts.map +1 -0
- package/dist/slate-lock.js +178 -0
- package/dist/slate-lock.js.map +1 -0
- package/dist/slate-paths.d.ts +45 -0
- package/dist/slate-paths.d.ts.map +1 -0
- package/dist/slate-paths.js +132 -0
- package/dist/slate-paths.js.map +1 -0
- package/dist/slate-pick.d.ts +29 -0
- package/dist/slate-pick.d.ts.map +1 -0
- package/dist/slate-pick.js +55 -0
- package/dist/slate-pick.js.map +1 -0
- package/dist/slate-reference-ids.d.ts +6 -0
- package/dist/slate-reference-ids.d.ts.map +1 -0
- package/dist/slate-reference-ids.js +17 -0
- package/dist/slate-reference-ids.js.map +1 -0
- package/dist/slate-reference-store.d.ts +23 -0
- package/dist/slate-reference-store.d.ts.map +1 -0
- package/dist/slate-reference-store.js +46 -0
- package/dist/slate-reference-store.js.map +1 -0
- package/dist/slate-resume.d.ts +19 -0
- package/dist/slate-resume.d.ts.map +1 -0
- package/dist/slate-resume.js +94 -0
- package/dist/slate-resume.js.map +1 -0
- package/dist/slate-round-params.d.ts +20 -0
- package/dist/slate-round-params.d.ts.map +1 -0
- package/dist/slate-round-params.js +32 -0
- package/dist/slate-round-params.js.map +1 -0
- package/dist/slate-round-prompt.d.ts +18 -0
- package/dist/slate-round-prompt.d.ts.map +1 -0
- package/dist/slate-round-prompt.js +20 -0
- package/dist/slate-round-prompt.js.map +1 -0
- package/dist/slate-round-runner.d.ts +4 -0
- package/dist/slate-round-runner.d.ts.map +1 -0
- package/dist/slate-round-runner.js +125 -0
- package/dist/slate-round-runner.js.map +1 -0
- package/dist/slate-round-search.d.ts +7 -0
- package/dist/slate-round-search.d.ts.map +1 -0
- package/dist/slate-round-search.js +77 -0
- package/dist/slate-round-search.js.map +1 -0
- package/dist/slate-run-action.d.ts +14 -0
- package/dist/slate-run-action.d.ts.map +1 -0
- package/dist/slate-run-action.js +81 -0
- package/dist/slate-run-action.js.map +1 -0
- package/dist/slate-runner-context.d.ts +57 -0
- package/dist/slate-runner-context.d.ts.map +1 -0
- package/dist/slate-runner-context.js +79 -0
- package/dist/slate-runner-context.js.map +1 -0
- package/dist/slate-runner-failure.d.ts +8 -0
- package/dist/slate-runner-failure.d.ts.map +1 -0
- package/dist/slate-runner-failure.js +17 -0
- package/dist/slate-runner-failure.js.map +1 -0
- package/dist/slate-runner-flag.d.ts +3 -0
- package/dist/slate-runner-flag.d.ts.map +1 -0
- package/dist/slate-runner-flag.js +3 -0
- package/dist/slate-runner-flag.js.map +1 -0
- package/dist/slate-runner-main.d.ts +31 -0
- package/dist/slate-runner-main.d.ts.map +1 -0
- package/dist/slate-runner-main.js +132 -0
- package/dist/slate-runner-main.js.map +1 -0
- package/dist/slate-runner-spawn.d.ts +23 -0
- package/dist/slate-runner-spawn.d.ts.map +1 -0
- package/dist/slate-runner-spawn.js +27 -0
- package/dist/slate-runner-spawn.js.map +1 -0
- package/dist/slate-runtime.d.ts +38 -0
- package/dist/slate-runtime.d.ts.map +1 -0
- package/dist/slate-runtime.js +48 -0
- package/dist/slate-runtime.js.map +1 -0
- package/dist/slate-versions.d.ts +26 -0
- package/dist/slate-versions.d.ts.map +1 -0
- package/dist/slate-versions.js +110 -0
- package/dist/slate-versions.js.map +1 -0
- package/dist/slate-view-contract.d.ts +232 -0
- package/dist/slate-view-contract.d.ts.map +1 -0
- package/dist/slate-view-contract.js +17 -0
- package/dist/slate-view-contract.js.map +1 -0
- package/dist/slate-view-types.d.ts +2 -0
- package/dist/slate-view-types.d.ts.map +1 -0
- package/dist/slate-view-types.js +2 -0
- package/dist/slate-view-types.js.map +1 -0
- package/dist/slate-view.d.ts +19 -0
- package/dist/slate-view.d.ts.map +1 -0
- package/dist/slate-view.js +184 -0
- package/dist/slate-view.js.map +1 -0
- package/dist/slate-workspace-parse.d.ts +20 -0
- package/dist/slate-workspace-parse.d.ts.map +1 -0
- package/dist/slate-workspace-parse.js +442 -0
- package/dist/slate-workspace-parse.js.map +1 -0
- package/dist/slate-workspace-store.d.ts +44 -0
- package/dist/slate-workspace-store.d.ts.map +1 -0
- package/dist/slate-workspace-store.js +270 -0
- package/dist/slate-workspace-store.js.map +1 -0
- package/dist/slate-workspace-types.d.ts +176 -0
- package/dist/slate-workspace-types.d.ts.map +1 -0
- package/dist/slate-workspace-types.js +13 -0
- package/dist/slate-workspace-types.js.map +1 -0
- package/dist/workflow/adapter-12ui.d.ts +4 -0
- package/dist/workflow/adapter-12ui.d.ts.map +1 -0
- package/dist/workflow/adapter-12ui.js +147 -0
- package/dist/workflow/adapter-12ui.js.map +1 -0
- package/dist/workflow/adapter-layerdoc.d.ts +16 -0
- package/dist/workflow/adapter-layerdoc.d.ts.map +1 -0
- package/dist/workflow/adapter-layerdoc.js +116 -0
- package/dist/workflow/adapter-layerdoc.js.map +1 -0
- package/dist/workflow/adapter-openai.d.ts +4 -0
- package/dist/workflow/adapter-openai.d.ts.map +1 -0
- package/dist/workflow/adapter-openai.js +166 -0
- package/dist/workflow/adapter-openai.js.map +1 -0
- package/dist/workflow/adapter-process.d.ts +7 -0
- package/dist/workflow/adapter-process.d.ts.map +1 -0
- package/dist/workflow/adapter-process.js +174 -0
- package/dist/workflow/adapter-process.js.map +1 -0
- package/dist/workflow/adapter-prototype-labels.d.ts +15 -0
- package/dist/workflow/adapter-prototype-labels.d.ts.map +1 -0
- package/dist/workflow/adapter-prototype-labels.js +71 -0
- package/dist/workflow/adapter-prototype-labels.js.map +1 -0
- package/dist/workflow/adapter-types.d.ts +40 -0
- package/dist/workflow/adapter-types.d.ts.map +1 -0
- package/dist/workflow/adapter-types.js +2 -0
- package/dist/workflow/adapter-types.js.map +1 -0
- package/dist/workflow/adapter-utils.d.ts +11 -0
- package/dist/workflow/adapter-utils.d.ts.map +1 -0
- package/dist/workflow/adapter-utils.js +72 -0
- package/dist/workflow/adapter-utils.js.map +1 -0
- package/dist/workflow/adapters.d.ts +6 -0
- package/dist/workflow/adapters.d.ts.map +1 -0
- package/dist/workflow/adapters.js +25 -0
- package/dist/workflow/adapters.js.map +1 -0
- package/dist/workflow/artifact.d.ts +11 -0
- package/dist/workflow/artifact.d.ts.map +1 -0
- package/dist/workflow/artifact.js +94 -0
- package/dist/workflow/artifact.js.map +1 -0
- package/dist/workflow/bundle-collect.d.ts +8 -0
- package/dist/workflow/bundle-collect.d.ts.map +1 -0
- package/dist/workflow/bundle-collect.js +56 -0
- package/dist/workflow/bundle-collect.js.map +1 -0
- package/dist/workflow/bundle-export.d.ts +16 -0
- package/dist/workflow/bundle-export.d.ts.map +1 -0
- package/dist/workflow/bundle-export.js +174 -0
- package/dist/workflow/bundle-export.js.map +1 -0
- package/dist/workflow/bundle-paths.d.ts +7 -0
- package/dist/workflow/bundle-paths.d.ts.map +1 -0
- package/dist/workflow/bundle-paths.js +35 -0
- package/dist/workflow/bundle-paths.js.map +1 -0
- package/dist/workflow/bundle.d.ts +4 -0
- package/dist/workflow/bundle.d.ts.map +1 -0
- package/dist/workflow/bundle.js +4 -0
- package/dist/workflow/bundle.js.map +1 -0
- package/dist/workflow/capture.d.ts +36 -0
- package/dist/workflow/capture.d.ts.map +1 -0
- package/dist/workflow/capture.js +81 -0
- package/dist/workflow/capture.js.map +1 -0
- package/dist/workflow/continuation-branch.d.ts +15 -0
- package/dist/workflow/continuation-branch.d.ts.map +1 -0
- package/dist/workflow/continuation-branch.js +103 -0
- package/dist/workflow/continuation-branch.js.map +1 -0
- package/dist/workflow/continuation-plans.d.ts +38 -0
- package/dist/workflow/continuation-plans.d.ts.map +1 -0
- package/dist/workflow/continuation-plans.js +78 -0
- package/dist/workflow/continuation-plans.js.map +1 -0
- package/dist/workflow/continuation.d.ts +25 -0
- package/dist/workflow/continuation.d.ts.map +1 -0
- package/dist/workflow/continuation.js +89 -0
- package/dist/workflow/continuation.js.map +1 -0
- package/dist/workflow/layerdoc-reader.d.ts +27 -0
- package/dist/workflow/layerdoc-reader.d.ts.map +1 -0
- package/dist/workflow/layerdoc-reader.js +81 -0
- package/dist/workflow/layerdoc-reader.js.map +1 -0
- package/dist/workflow/project-evidence.d.ts +48 -0
- package/dist/workflow/project-evidence.d.ts.map +1 -0
- package/dist/workflow/project-evidence.js +200 -0
- package/dist/workflow/project-evidence.js.map +1 -0
- package/dist/workflow/providers.d.ts +35 -0
- package/dist/workflow/providers.d.ts.map +1 -0
- package/dist/workflow/providers.js +110 -0
- package/dist/workflow/providers.js.map +1 -0
- package/dist/workflow/recipes-layerdoc-validation.d.ts +4 -0
- package/dist/workflow/recipes-layerdoc-validation.d.ts.map +1 -0
- package/dist/workflow/recipes-layerdoc-validation.js +98 -0
- package/dist/workflow/recipes-layerdoc-validation.js.map +1 -0
- package/dist/workflow/recipes-result-validation.d.ts +6 -0
- package/dist/workflow/recipes-result-validation.d.ts.map +1 -0
- package/dist/workflow/recipes-result-validation.js +38 -0
- package/dist/workflow/recipes-result-validation.js.map +1 -0
- package/dist/workflow/recipes-schemas.d.ts +7 -0
- package/dist/workflow/recipes-schemas.d.ts.map +1 -0
- package/dist/workflow/recipes-schemas.js +67 -0
- package/dist/workflow/recipes-schemas.js.map +1 -0
- package/dist/workflow/recipes-validation.d.ts +14 -0
- package/dist/workflow/recipes-validation.d.ts.map +1 -0
- package/dist/workflow/recipes-validation.js +68 -0
- package/dist/workflow/recipes-validation.js.map +1 -0
- package/dist/workflow/recipes.d.ts +20 -0
- package/dist/workflow/recipes.d.ts.map +1 -0
- package/dist/workflow/recipes.js +167 -0
- package/dist/workflow/recipes.js.map +1 -0
- package/dist/workflow/routing.d.ts +4 -0
- package/dist/workflow/routing.d.ts.map +1 -0
- package/dist/workflow/routing.js +28 -0
- package/dist/workflow/routing.js.map +1 -0
- package/dist/workflow/schema.d.ts +5 -0
- package/dist/workflow/schema.d.ts.map +1 -0
- package/dist/workflow/schema.js +29 -0
- package/dist/workflow/schema.js.map +1 -0
- package/dist/workflow/service.d.ts +59 -0
- package/dist/workflow/service.d.ts.map +1 -0
- package/dist/workflow/service.js +170 -0
- package/dist/workflow/service.js.map +1 -0
- package/dist/workflow/store-json.d.ts +5 -0
- package/dist/workflow/store-json.d.ts.map +1 -0
- package/dist/workflow/store-json.js +35 -0
- package/dist/workflow/store-json.js.map +1 -0
- package/dist/workflow/store-lock.d.ts +3 -0
- package/dist/workflow/store-lock.d.ts.map +1 -0
- package/dist/workflow/store-lock.js +85 -0
- package/dist/workflow/store-lock.js.map +1 -0
- package/dist/workflow/store-paths.d.ts +17 -0
- package/dist/workflow/store-paths.d.ts.map +1 -0
- package/dist/workflow/store-paths.js +67 -0
- package/dist/workflow/store-paths.js.map +1 -0
- package/dist/workflow/store-validation.d.ts +7 -0
- package/dist/workflow/store-validation.d.ts.map +1 -0
- package/dist/workflow/store-validation.js +119 -0
- package/dist/workflow/store-validation.js.map +1 -0
- package/dist/workflow/store.d.ts +10 -0
- package/dist/workflow/store.d.ts.map +1 -0
- package/dist/workflow/store.js +193 -0
- package/dist/workflow/store.js.map +1 -0
- package/dist/workflow/types.d.ts +120 -0
- package/dist/workflow/types.d.ts.map +1 -0
- package/dist/workflow/types.js +15 -0
- package/dist/workflow/types.js.map +1 -0
- package/dist/workflow-transport.d.ts +28 -0
- package/dist/workflow-transport.d.ts.map +1 -0
- package/dist/workflow-transport.js +184 -0
- package/dist/workflow-transport.js.map +1 -0
- package/open-design.json +2 -2
- package/package.json +2 -1
- package/prototype-kit/tests/rules-check.mjs +9 -0
- package/runtime/codex-conversion/src/images/native-invoke.mjs +1 -1
- package/runtime/codex-conversion/src/images/native.mjs +8 -4
- package/runtime/layerdoc-validator.mjs +1860 -0
- package/skills/12ui-design/SKILL.md +17 -63
- package/skills/12ui-design/improve.md +5 -1
- package/skills/12ui-design/inspire.md +8 -5
- package/skills/12ui-design/outputs.md +23 -2
- package/skills/12ui-design/session.md +161 -0
|
@@ -0,0 +1,236 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The tabs (Designs and Inspiration, in the card and the workspace) and the
|
|
3
|
+
* Inspiration tab, which is the same in both places: a search row, the newest
|
|
4
|
+
* search's results, and one section per round with the references that
|
|
5
|
+
* produced its options. Every reference is a toggle. The selection lives in
|
|
6
|
+
* the view (`inspiration.selected`, at most eight, in click order) and is
|
|
7
|
+
* written whole through the inspiration tool, one write in flight at a time,
|
|
8
|
+
* last click wins locally; the next round reads it at commit. Nothing in this
|
|
9
|
+
* tab starts work. While a search runs the newest-search slot is skeleton
|
|
10
|
+
* tiles; a search with no results says so.
|
|
11
|
+
*/
|
|
12
|
+
export const SLATE_UI_INSPIRATION = String.raw `
|
|
13
|
+
var MAX_SELECTED = 8;
|
|
14
|
+
|
|
15
|
+
// A tab strip for the workspace header. The card's own strip is static markup; both carry data-tab.
|
|
16
|
+
function buildTabs() {
|
|
17
|
+
var tabs = el("div", "tabs");
|
|
18
|
+
tabs.setAttribute("role", "tablist");
|
|
19
|
+
tabs.setAttribute("aria-label", COPY.title);
|
|
20
|
+
[["designs", COPY.tabDesigns], ["inspiration", COPY.tabInspiration]].forEach(function (t) {
|
|
21
|
+
var b = button(t[1], "tab");
|
|
22
|
+
b.setAttribute("role", "tab");
|
|
23
|
+
b.setAttribute("data-tab", t[0]);
|
|
24
|
+
b.setAttribute("aria-selected", state.tab === t[0] ? "true" : "false");
|
|
25
|
+
bindTab(b);
|
|
26
|
+
tabs.appendChild(b);
|
|
27
|
+
});
|
|
28
|
+
return tabs;
|
|
29
|
+
}
|
|
30
|
+
function syncTabs() {
|
|
31
|
+
var tabs = document.querySelectorAll("[data-tab]");
|
|
32
|
+
for (var i = 0; i < tabs.length; i++) tabs[i].setAttribute("aria-selected", tabs[i].getAttribute("data-tab") === state.tab ? "true" : "false");
|
|
33
|
+
}
|
|
34
|
+
function setTab(tab) {
|
|
35
|
+
if ((tab !== "designs" && tab !== "inspiration") || state.tab === tab) return;
|
|
36
|
+
state.tab = tab;
|
|
37
|
+
syncTabs();
|
|
38
|
+
if (state.view) renderAll();
|
|
39
|
+
}
|
|
40
|
+
function bindTab(b) { b.addEventListener("click", function () { setTab(b.getAttribute("data-tab")); }); }
|
|
41
|
+
Array.prototype.forEach.call(document.querySelectorAll("[data-tab]"), bindTab);
|
|
42
|
+
|
|
43
|
+
// ---- what the view says about references ----
|
|
44
|
+
function currentSelected() {
|
|
45
|
+
return state.insp.local || (state.view && state.view.inspiration ? state.view.inspiration.selected : []);
|
|
46
|
+
}
|
|
47
|
+
function refMeta(id) { return (state.view.references && state.view.references[id]) || null; }
|
|
48
|
+
function refDescription(id) {
|
|
49
|
+
var m = refMeta(id);
|
|
50
|
+
return String((m && m.description) || id).slice(0, 40);
|
|
51
|
+
}
|
|
52
|
+
function refName(id) { return COPY.referencePrefix + refDescription(id); }
|
|
53
|
+
function newestSearch() {
|
|
54
|
+
var searches = (state.view.inspiration && state.view.inspiration.searches) || [];
|
|
55
|
+
var best = null;
|
|
56
|
+
// The hosted server sends no time, only the order: the last search is the newest.
|
|
57
|
+
if (TARGET === "remote") return searches.length ? searches[searches.length - 1] : null;
|
|
58
|
+
searches.forEach(function (s) { if (!best || Date.parse(s.at) >= Date.parse(best.at)) best = s; });
|
|
59
|
+
return best;
|
|
60
|
+
}
|
|
61
|
+
function roundTitle(round) {
|
|
62
|
+
if (round.kind === "new") return COPY.newOptionsTitle;
|
|
63
|
+
if (round.kind === "like") { var from = ver(round.fromVersionId); return COPY.likePrefix + (from ? from.label : ""); }
|
|
64
|
+
return "";
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// ---- the status line of this tab ----
|
|
68
|
+
function setInspStatus(text, kind) {
|
|
69
|
+
var nodes = document.querySelectorAll("[data-istatus]");
|
|
70
|
+
for (var i = 0; i < nodes.length; i++) { nodes[i].textContent = text || ""; nodes[i].className = "status" + (kind ? " " + kind : ""); }
|
|
71
|
+
state.inspMsg = { text: text || "", kind: kind || "" };
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
// ---- selection: optimistic, serialized, last write wins ----
|
|
75
|
+
function toggleRef(id) {
|
|
76
|
+
var cur = currentSelected().slice();
|
|
77
|
+
var at = cur.indexOf(id);
|
|
78
|
+
if (at >= 0) cur.splice(at, 1);
|
|
79
|
+
else {
|
|
80
|
+
if (cur.length >= MAX_SELECTED) { setInspStatus(COPY.eightAtMost, ""); return; }
|
|
81
|
+
cur.push(id);
|
|
82
|
+
}
|
|
83
|
+
setInspStatus("", "");
|
|
84
|
+
state.insp.local = cur;
|
|
85
|
+
renderAll();
|
|
86
|
+
writeSelection();
|
|
87
|
+
}
|
|
88
|
+
function writeSelection() {
|
|
89
|
+
var i = state.insp;
|
|
90
|
+
if (i.writing) { i.dirty = true; return; }
|
|
91
|
+
i.writing = true;
|
|
92
|
+
i.dirty = false;
|
|
93
|
+
callTool(TOOLS.inspiration, { runDir: state.view.runDir, referenceIds: i.local.slice() }).then(function (result) {
|
|
94
|
+
var sc = result.structuredContent || {};
|
|
95
|
+
if (!i.dirty) i.local = null;
|
|
96
|
+
if (sc.view) applyView(sc.view, true);
|
|
97
|
+
}, function (err) {
|
|
98
|
+
if (!i.dirty) i.local = null;
|
|
99
|
+
setInspStatus(errText(err), "err");
|
|
100
|
+
}).then(function () {
|
|
101
|
+
var again = i.dirty && !!i.local;
|
|
102
|
+
i.writing = false;
|
|
103
|
+
i.dirty = false;
|
|
104
|
+
if (again) { writeSelection(); return; }
|
|
105
|
+
var waiting = i.waiters.splice(0);
|
|
106
|
+
renderAll();
|
|
107
|
+
waiting.forEach(function (resolve) { resolve(); });
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
// Resolves when no selection write is in flight, so a round commits the selection the person sees.
|
|
111
|
+
function whenSelectionSettled() {
|
|
112
|
+
if (!state.insp.writing) return Promise.resolve();
|
|
113
|
+
return new Promise(function (resolve) { state.insp.waiters.push(resolve); });
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
// ---- search ----
|
|
117
|
+
function syncSearchButton(pane) {
|
|
118
|
+
if (pane.__search) pane.__search.disabled = !state.query.trim() || state.insp.searching;
|
|
119
|
+
}
|
|
120
|
+
function doSearch() {
|
|
121
|
+
var q = state.query.trim();
|
|
122
|
+
if (!q || state.insp.searching || !state.view) return;
|
|
123
|
+
state.insp.searching = true;
|
|
124
|
+
state.insp.noMatch = "";
|
|
125
|
+
setInspStatus(COPY.searching, "");
|
|
126
|
+
renderAll();
|
|
127
|
+
callTool(TOOLS.inspire, { runDir: state.view.runDir, query: q }).then(function (result) {
|
|
128
|
+
var sc = result.structuredContent || {};
|
|
129
|
+
if (sc.view) applyView(sc.view, true);
|
|
130
|
+
setInspStatus("", "");
|
|
131
|
+
var found = sc.search || newestSearch();
|
|
132
|
+
if (found && found.referenceIds.length === 0) state.insp.noMatch = found.searchId;
|
|
133
|
+
}, function (err) {
|
|
134
|
+
setInspStatus(err.code === "rate_limited" && err.retryAfterSeconds !== undefined ? tpl(COPY.tryAgain, { n: err.retryAfterSeconds }) : tpl(COPY.searchFailed, { message: errText(err) }), "err");
|
|
135
|
+
}).then(function () { state.insp.searching = false; renderAll(); });
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// ---- the tab ----
|
|
139
|
+
function refButton(id) {
|
|
140
|
+
var b = button("", "refbtn");
|
|
141
|
+
b.setAttribute("aria-label", refName(id));
|
|
142
|
+
b.setAttribute("data-ref", id);
|
|
143
|
+
// The picture's own skeleton shows until it lands, so a tile that has arrived never flashes a grey square.
|
|
144
|
+
var img = el("img", "thumb empty shimmer");
|
|
145
|
+
img.alt = "";
|
|
146
|
+
b.appendChild(img);
|
|
147
|
+
bindReference(img, id, "thumb");
|
|
148
|
+
var check = el("span", "check");
|
|
149
|
+
check.innerHTML = '<svg viewBox="0 0 24 24" width="14" height="14" fill="none" stroke="currentColor" stroke-width="3" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M5 12.5l4.5 4.5L19 7.5"/></svg>';
|
|
150
|
+
b.appendChild(check);
|
|
151
|
+
b.addEventListener("click", function () { toggleRef(id); });
|
|
152
|
+
return b;
|
|
153
|
+
}
|
|
154
|
+
function refSection(heading, title, ids) {
|
|
155
|
+
var sec = el("section", "refsec");
|
|
156
|
+
if (heading) {
|
|
157
|
+
var h = el("h2", "refhead", heading);
|
|
158
|
+
if (title) h.title = title;
|
|
159
|
+
sec.appendChild(h);
|
|
160
|
+
}
|
|
161
|
+
var grid = el("div", "refgrid");
|
|
162
|
+
ids.forEach(function (id) { grid.appendChild(refButton(id)); });
|
|
163
|
+
sec.appendChild(grid);
|
|
164
|
+
return sec;
|
|
165
|
+
}
|
|
166
|
+
// The same tiles as the results, at the same size, where the results will land.
|
|
167
|
+
var SKELETON_TILES = 12;
|
|
168
|
+
function skeletonSection() {
|
|
169
|
+
var sec = el("section", "refsec");
|
|
170
|
+
var grid = el("div", "refgrid");
|
|
171
|
+
for (var i = 0; i < SKELETON_TILES; i++) grid.appendChild(el("div", "skeleton shimmer"));
|
|
172
|
+
sec.appendChild(grid);
|
|
173
|
+
return sec;
|
|
174
|
+
}
|
|
175
|
+
function buildResults(box) {
|
|
176
|
+
var v = state.view;
|
|
177
|
+
var any = false;
|
|
178
|
+
var search = newestSearch();
|
|
179
|
+
// The newest search's slot: skeleton tiles while it runs, else its references, or the line that it found none.
|
|
180
|
+
if (state.insp.searching) { box.appendChild(skeletonSection()); any = true; }
|
|
181
|
+
else if (search && search.referenceIds.length === 0 && state.insp.noMatch === search.searchId) { box.appendChild(el("div", "placeholder", COPY.inspirationNoMatches)); any = true; }
|
|
182
|
+
else if (search && search.referenceIds.length > 0) { box.appendChild(refSection("", "", search.referenceIds)); any = true; }
|
|
183
|
+
v.rounds.slice().sort(function (a, b) { return b.index - a.index; }).forEach(function (round) {
|
|
184
|
+
if (round.referenceIds.length === 0) return;
|
|
185
|
+
box.appendChild(refSection(COPY.roundPrefix + round.index, roundTitle(round), round.referenceIds));
|
|
186
|
+
any = true;
|
|
187
|
+
});
|
|
188
|
+
if (!any) box.appendChild(el("div", "placeholder", COPY.inspirationEmpty));
|
|
189
|
+
}
|
|
190
|
+
function buildInspirationShell(pane, where) {
|
|
191
|
+
pane.__built = true;
|
|
192
|
+
pane.classList.add("insp", where);
|
|
193
|
+
var row = el("div", "searchrow");
|
|
194
|
+
var input = el("input");
|
|
195
|
+
input.type = "text";
|
|
196
|
+
input.className = "query";
|
|
197
|
+
input.autocomplete = "off";
|
|
198
|
+
input.placeholder = COPY.inspirationPlaceholder;
|
|
199
|
+
input.setAttribute("aria-label", COPY.inspirationLabel);
|
|
200
|
+
input.value = state.query;
|
|
201
|
+
input.addEventListener("input", function () {
|
|
202
|
+
state.query = input.value;
|
|
203
|
+
var panes = document.querySelectorAll(".insp");
|
|
204
|
+
for (var i = 0; i < panes.length; i++) syncSearchButton(panes[i]);
|
|
205
|
+
});
|
|
206
|
+
input.addEventListener("keydown", function (e) { if (e.key === "Enter") doSearch(); });
|
|
207
|
+
var search = button(COPY.search, "primary", doSearch);
|
|
208
|
+
row.appendChild(input);
|
|
209
|
+
row.appendChild(search);
|
|
210
|
+
var status = el("div", "status");
|
|
211
|
+
status.setAttribute("data-istatus", "");
|
|
212
|
+
status.setAttribute("role", "status");
|
|
213
|
+
status.setAttribute("aria-live", "polite");
|
|
214
|
+
if (state.inspMsg) { status.textContent = state.inspMsg.text; if (state.inspMsg.kind) status.className = "status " + state.inspMsg.kind; }
|
|
215
|
+
pane.__input = input;
|
|
216
|
+
pane.__search = search;
|
|
217
|
+
pane.__results = el("div", "results");
|
|
218
|
+
pane.appendChild(row);
|
|
219
|
+
pane.appendChild(status);
|
|
220
|
+
pane.appendChild(pane.__results);
|
|
221
|
+
}
|
|
222
|
+
function renderInspiration(pane, where) {
|
|
223
|
+
if (!state.view) return;
|
|
224
|
+
if (!pane.__built) buildInspirationShell(pane, where);
|
|
225
|
+
syncSearchButton(pane);
|
|
226
|
+
var v = state.view;
|
|
227
|
+
var search = newestSearch();
|
|
228
|
+
pane.__results.setAttribute("aria-busy", state.insp.searching ? "true" : "false");
|
|
229
|
+
var sig = JSON.stringify([state.insp.searching, state.insp.noMatch, search && [search.searchId, search.referenceIds], v.rounds.map(function (r) { return [r.index, r.kind, r.fromVersionId, r.referenceIds]; }), v.references]);
|
|
230
|
+
setIfChanged(pane.__results, sig, buildResults);
|
|
231
|
+
var chosen = currentSelected();
|
|
232
|
+
var buttons = pane.__results.querySelectorAll(".refbtn");
|
|
233
|
+
for (var i = 0; i < buttons.length; i++) buttons[i].setAttribute("aria-pressed", chosen.indexOf(buttons[i].getAttribute("data-ref")) >= 0 ? "true" : "false");
|
|
234
|
+
}
|
|
235
|
+
`;
|
|
236
|
+
//# sourceMappingURL=mcp-slate-ui-script-inspiration.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-slate-ui-script-inspiration.js","sourceRoot":"","sources":["../src/mcp-slate-ui-script-inspiration.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+N7C,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generate more: the last tile of the thumbnails (the card's strip, the
|
|
3
|
+
* workspace's selection) and the panel it opens directly below them. The tile
|
|
4
|
+
* is a dashed, thumbnail-sized box with a plus and the words Generate more, pinned outside any scroll so it is always in view; the
|
|
5
|
+
* panel is the only way to start a round, and it says what it will do:
|
|
6
|
+
*
|
|
7
|
+
* - a heading and one helper line that follows the state (fresh references,
|
|
8
|
+
* the selected inspiration, or close to the shown design);
|
|
9
|
+
* - a switch, with a picture of the design at its left, "Based on <code>", off by default: off draws new options, on
|
|
10
|
+
* draws options close to the design that is shown (mode "like" from the
|
|
11
|
+
* shown version at the moment of Generate);
|
|
12
|
+
* - the selected inspiration as small chips, each with a remove button that is
|
|
13
|
+
* the same selection write as the Inspiration tab's toggle (adding is done
|
|
14
|
+
* in that tab);
|
|
15
|
+
* - an optional note, how many (1, 2, 4, 8 or 12, default 4) and Cancel and
|
|
16
|
+
* Generate.
|
|
17
|
+
*
|
|
18
|
+
* Clicking the tile again, Cancel or Escape collapses it. While a round runs
|
|
19
|
+
* (or the request is in flight) the tile is off; the new round's pending
|
|
20
|
+
* options are already in the thumbnails, because the returned view carries
|
|
21
|
+
* them.
|
|
22
|
+
*
|
|
23
|
+
* In the card the panel takes its room from the large image rather than
|
|
24
|
+
* growing the frame. The host grows the frame downward and does not scroll
|
|
25
|
+
* the thread, so a panel added below the thumbnails lands under the host's
|
|
26
|
+
* composer, out of sight (the frame's own document has nothing to scroll).
|
|
27
|
+
* While the panel is open the image is shortened by the panel's height, and
|
|
28
|
+
* folded away when what would be left is too small to read, so the card keeps
|
|
29
|
+
* its height and the panel sits where the bottom of the card already was.
|
|
30
|
+
*/
|
|
31
|
+
export declare const SLATE_UI_MORE: string;
|
|
32
|
+
//# sourceMappingURL=mcp-slate-ui-script-more.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-slate-ui-script-more.d.ts","sourceRoot":"","sources":["../src/mcp-slate-ui-script-more.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,eAAO,MAAM,aAAa,QAiQzB,CAAC"}
|
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generate more: the last tile of the thumbnails (the card's strip, the
|
|
3
|
+
* workspace's selection) and the panel it opens directly below them. The tile
|
|
4
|
+
* is a dashed, thumbnail-sized box with a plus and the words Generate more, pinned outside any scroll so it is always in view; the
|
|
5
|
+
* panel is the only way to start a round, and it says what it will do:
|
|
6
|
+
*
|
|
7
|
+
* - a heading and one helper line that follows the state (fresh references,
|
|
8
|
+
* the selected inspiration, or close to the shown design);
|
|
9
|
+
* - a switch, with a picture of the design at its left, "Based on <code>", off by default: off draws new options, on
|
|
10
|
+
* draws options close to the design that is shown (mode "like" from the
|
|
11
|
+
* shown version at the moment of Generate);
|
|
12
|
+
* - the selected inspiration as small chips, each with a remove button that is
|
|
13
|
+
* the same selection write as the Inspiration tab's toggle (adding is done
|
|
14
|
+
* in that tab);
|
|
15
|
+
* - an optional note, how many (1, 2, 4, 8 or 12, default 4) and Cancel and
|
|
16
|
+
* Generate.
|
|
17
|
+
*
|
|
18
|
+
* Clicking the tile again, Cancel or Escape collapses it. While a round runs
|
|
19
|
+
* (or the request is in flight) the tile is off; the new round's pending
|
|
20
|
+
* options are already in the thumbnails, because the returned view carries
|
|
21
|
+
* them.
|
|
22
|
+
*
|
|
23
|
+
* In the card the panel takes its room from the large image rather than
|
|
24
|
+
* growing the frame. The host grows the frame downward and does not scroll
|
|
25
|
+
* the thread, so a panel added below the thumbnails lands under the host's
|
|
26
|
+
* composer, out of sight (the frame's own document has nothing to scroll).
|
|
27
|
+
* While the panel is open the image is shortened by the panel's height, and
|
|
28
|
+
* folded away when what would be left is too small to read, so the card keeps
|
|
29
|
+
* its height and the panel sits where the bottom of the card already was.
|
|
30
|
+
*/
|
|
31
|
+
export const SLATE_UI_MORE = String.raw `
|
|
32
|
+
var MORE = __MORE__;
|
|
33
|
+
var ICON_PLUS = "M12 5v14M5 12h14";
|
|
34
|
+
|
|
35
|
+
// A round that is running, or the panel's own request still in flight, keeps the tile off until it settles.
|
|
36
|
+
function moreBusy() {
|
|
37
|
+
return (!!state.view && runningOps().some(function (o) { return o.kind === "round"; })) || !!(state.more && state.more.committing);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// One tile per row of thumbnails; the strip and the selection each build their own.
|
|
41
|
+
function moreTile() {
|
|
42
|
+
var b = button("", "moretile", toggleMore);
|
|
43
|
+
b.setAttribute("aria-label", COPY.generateMore);
|
|
44
|
+
b.setAttribute("aria-expanded", "false");
|
|
45
|
+
b.setAttribute("aria-controls", "morepanel");
|
|
46
|
+
b.title = COPY.generateMore;
|
|
47
|
+
b.innerHTML = '<svg viewBox="0 0 24 24" width="28" height="28" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" aria-hidden="true"><path d="' + ICON_PLUS + '"/></svg>';
|
|
48
|
+
b.appendChild(el("span", "", COPY.generateMore));
|
|
49
|
+
return b;
|
|
50
|
+
}
|
|
51
|
+
function moreTiles() { return Array.prototype.slice.call(document.querySelectorAll(".moretile")); }
|
|
52
|
+
function moreHosts() { return [$("more"), stageEls && stageEls.more].filter(Boolean); }
|
|
53
|
+
|
|
54
|
+
function toggleMore() {
|
|
55
|
+
if (state.more) { closeMore(true); return; }
|
|
56
|
+
openMore();
|
|
57
|
+
}
|
|
58
|
+
function openMore() {
|
|
59
|
+
if (!state.view || state.view.candidates.length === 0 || moreBusy()) return;
|
|
60
|
+
if (state.more) resetMore();
|
|
61
|
+
state.more = { id: uuid4(), like: false, note: "", count: MORE.initial, committing: false, error: "", sig: "", els: {} };
|
|
62
|
+
buildMore();
|
|
63
|
+
syncMore();
|
|
64
|
+
state.more.els.note.focus();
|
|
65
|
+
}
|
|
66
|
+
// The shortest the card's image gets while the panel is open; below this it folds away, and the thumbnails stay.
|
|
67
|
+
var HERO_FLOOR_PX = 120;
|
|
68
|
+
function fitMore() {
|
|
69
|
+
var hero = $("hero");
|
|
70
|
+
if (!hero) return;
|
|
71
|
+
hero.style.removeProperty("--cap");
|
|
72
|
+
hero.classList.remove("folded");
|
|
73
|
+
var m = state.more;
|
|
74
|
+
if (!m || isFullscreen() || m.els.box.parentNode !== $("more")) return;
|
|
75
|
+
// The panel's host holds the panel and the gap above it, so its height is all the room the panel takes.
|
|
76
|
+
var natural = hero.getBoundingClientRect().height;
|
|
77
|
+
var need = $("more").getBoundingClientRect().height;
|
|
78
|
+
if (!(natural > 0) || !(need > 0)) return;
|
|
79
|
+
var left = Math.floor(natural - need);
|
|
80
|
+
if (left >= HERO_FLOOR_PX) hero.style.setProperty("--cap", left + "px");
|
|
81
|
+
else hero.classList.add("folded");
|
|
82
|
+
}
|
|
83
|
+
function closeMore(refocus) {
|
|
84
|
+
var m = state.more;
|
|
85
|
+
if (!m || m.committing) return;
|
|
86
|
+
state.more = null;
|
|
87
|
+
moreHosts().forEach(function (host) { host.textContent = ""; });
|
|
88
|
+
syncMore();
|
|
89
|
+
fitMore();
|
|
90
|
+
if (refocus) {
|
|
91
|
+
var back = moreTiles().filter(function (t) { return !t.disabled && !isHiddenNode(t); })[0];
|
|
92
|
+
if (back) back.focus();
|
|
93
|
+
}
|
|
94
|
+
reportSize();
|
|
95
|
+
}
|
|
96
|
+
// A different run replaces the workspace: whatever was typed belongs to the old one.
|
|
97
|
+
function resetMore() {
|
|
98
|
+
state.more = null;
|
|
99
|
+
moreHosts().forEach(function (host) { host.textContent = ""; });
|
|
100
|
+
fitMore();
|
|
101
|
+
}
|
|
102
|
+
function isHiddenNode(node) {
|
|
103
|
+
for (var n = node; n && n.classList; n = n.parentElement) if (n.classList.contains("hidden")) return true;
|
|
104
|
+
return false;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
// The design the switch is about: the one that is shown when Generate is clicked, so it follows the selection.
|
|
108
|
+
function moreBase() { var v = selectedVersion(); return pickable(v) ? v : null; }
|
|
109
|
+
|
|
110
|
+
function buildMore() {
|
|
111
|
+
var m = state.more;
|
|
112
|
+
var box = el("div", "morepanel");
|
|
113
|
+
box.id = "morepanel";
|
|
114
|
+
box.setAttribute("role", "group");
|
|
115
|
+
var title = el("h2", "morehead", COPY.generateMore);
|
|
116
|
+
title.id = "morehead";
|
|
117
|
+
box.setAttribute("aria-labelledby", "morehead");
|
|
118
|
+
box.appendChild(title);
|
|
119
|
+
m.els.help = el("p", "help");
|
|
120
|
+
box.appendChild(m.els.help);
|
|
121
|
+
|
|
122
|
+
// The switch: a native checkbox that reads as a switch, with a picture of the design it is about.
|
|
123
|
+
var label = el("label", "moreswitch");
|
|
124
|
+
m.els.toggle = el("input");
|
|
125
|
+
m.els.toggle.type = "checkbox";
|
|
126
|
+
m.els.toggle.setAttribute("role", "switch");
|
|
127
|
+
m.els.toggle.addEventListener("change", function () { m.like = m.els.toggle.checked; syncMore(); });
|
|
128
|
+
m.els.thumb = el("img", "morethumb empty");
|
|
129
|
+
m.els.thumb.alt = "";
|
|
130
|
+
m.els.switchText = el("span", "moreswitchtext");
|
|
131
|
+
label.appendChild(m.els.thumb);
|
|
132
|
+
label.appendChild(m.els.switchText);
|
|
133
|
+
label.appendChild(m.els.toggle);
|
|
134
|
+
box.appendChild(label);
|
|
135
|
+
|
|
136
|
+
// The inspiration that is selected, read back from the view; removing one is the tab's own selection write.
|
|
137
|
+
m.els.chipsWrap = el("div", "morechips hidden");
|
|
138
|
+
m.els.chipsWrap.appendChild(el("span", "lbl", COPY.moreInspirationLabel));
|
|
139
|
+
m.els.chips = el("div", "refchips");
|
|
140
|
+
m.els.chipsWrap.appendChild(m.els.chips);
|
|
141
|
+
box.appendChild(m.els.chipsWrap);
|
|
142
|
+
|
|
143
|
+
var note = el("textarea");
|
|
144
|
+
note.setAttribute("rows", "2");
|
|
145
|
+
note.setAttribute("maxlength", "600");
|
|
146
|
+
note.setAttribute("placeholder", COPY.moreNotePlaceholder);
|
|
147
|
+
note.setAttribute("aria-label", COPY.moreNotePlaceholder);
|
|
148
|
+
note.addEventListener("input", function () { m.note = note.value; });
|
|
149
|
+
box.appendChild(note);
|
|
150
|
+
var row = el("div", "morerow");
|
|
151
|
+
var seg = el("div", "seg");
|
|
152
|
+
seg.setAttribute("role", "radiogroup");
|
|
153
|
+
seg.setAttribute("aria-label", COPY.moreCountLabel);
|
|
154
|
+
MORE.choices.forEach(function (n) {
|
|
155
|
+
var option = el("label", "segopt");
|
|
156
|
+
var input = el("input");
|
|
157
|
+
input.type = "radio";
|
|
158
|
+
input.name = "morecount";
|
|
159
|
+
input.value = String(n);
|
|
160
|
+
input.checked = n === m.count;
|
|
161
|
+
input.addEventListener("change", function () { m.count = n; });
|
|
162
|
+
option.appendChild(input);
|
|
163
|
+
option.appendChild(el("span", "", String(n)));
|
|
164
|
+
seg.appendChild(option);
|
|
165
|
+
});
|
|
166
|
+
row.appendChild(seg);
|
|
167
|
+
// Cancel and Generate stay together: on a narrow card they drop to the next line as a pair, at the right.
|
|
168
|
+
var buttons = el("span", "morebtns");
|
|
169
|
+
buttons.appendChild(button(COPY.cancel, "", function () { closeMore(true); }));
|
|
170
|
+
m.els.primary = button(COPY.generate, "primary", commitMore);
|
|
171
|
+
buttons.appendChild(m.els.primary);
|
|
172
|
+
row.appendChild(buttons);
|
|
173
|
+
box.appendChild(row);
|
|
174
|
+
m.els.alert = el("p", "alert hidden");
|
|
175
|
+
m.els.alert.setAttribute("role", "alert");
|
|
176
|
+
box.appendChild(m.els.alert);
|
|
177
|
+
m.els.box = box;
|
|
178
|
+
m.els.note = note;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
// The chips follow the selection, the switch follows the shown design; each is rebuilt only when what it shows changed.
|
|
182
|
+
function syncMoreBody(m) {
|
|
183
|
+
var base = moreBase();
|
|
184
|
+
var likeOn = m.like && !!base;
|
|
185
|
+
var selected = currentSelected().slice(0, MAX_SELECTED);
|
|
186
|
+
m.els.toggle.checked = likeOn;
|
|
187
|
+
m.els.toggle.disabled = !base || m.committing;
|
|
188
|
+
m.els.switchText.textContent = tpl(COPY.moreBasedOn, { label: base ? base.label : (selectedVersion() ? selectedVersion().label : "") });
|
|
189
|
+
m.els.switchText.parentNode.title = base ? "" : COPY.moreLikeUnavailable;
|
|
190
|
+
m.els.help.textContent = likeOn ? tpl(COPY.moreHelpLike, { label: base.label }) : selected.length > 0 ? COPY.moreHelpSelected : COPY.moreHelpFresh;
|
|
191
|
+
var shown = base || selectedVersion();
|
|
192
|
+
var thumbSig = shown ? shown.versionId + ":" + shown.sha256 : "";
|
|
193
|
+
if (m.thumbSig !== thumbSig) {
|
|
194
|
+
m.thumbSig = thumbSig;
|
|
195
|
+
var fresh = el("img", "morethumb empty");
|
|
196
|
+
fresh.alt = "";
|
|
197
|
+
m.els.thumb.parentNode.replaceChild(fresh, m.els.thumb);
|
|
198
|
+
m.els.thumb = fresh;
|
|
199
|
+
if (shown) {
|
|
200
|
+
var cached = state.thumbs[imageKey(shown, "thumb")];
|
|
201
|
+
if (cached) { fresh.src = cached; fresh.classList.remove("empty"); }
|
|
202
|
+
else bindImage(fresh, shown, "thumb", false);
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
var chipSig = JSON.stringify(selected);
|
|
206
|
+
if (m.chipSig !== chipSig) {
|
|
207
|
+
m.chipSig = chipSig;
|
|
208
|
+
m.els.chips.textContent = "";
|
|
209
|
+
selected.forEach(function (id) {
|
|
210
|
+
var chip = el("span", "refchip");
|
|
211
|
+
var img = el("img", "refchipimg empty shimmer");
|
|
212
|
+
img.alt = "";
|
|
213
|
+
chip.appendChild(img);
|
|
214
|
+
bindReference(img, id, "thumb");
|
|
215
|
+
var remove = button("", "refchipx", function () { toggleRef(id); });
|
|
216
|
+
remove.setAttribute("aria-label", tpl(COPY.removeReference, { name: refDescription(id) }));
|
|
217
|
+
remove.title = tpl(COPY.removeReference, { name: refDescription(id) });
|
|
218
|
+
remove.innerHTML = '<svg viewBox="0 0 24 24" width="12" height="12" fill="none" stroke="currentColor" stroke-width="3" stroke-linecap="round" aria-hidden="true"><path d="M6 6l12 12M18 6L6 18"/></svg>';
|
|
219
|
+
chip.appendChild(remove);
|
|
220
|
+
m.els.chips.appendChild(chip);
|
|
221
|
+
});
|
|
222
|
+
}
|
|
223
|
+
m.els.chipsWrap.classList.toggle("hidden", selected.length === 0);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
// The one way a round starts: the selection is committed first, so the round uses the inspiration the person sees.
|
|
227
|
+
function roundAction(request) {
|
|
228
|
+
var action = { kind: "round", mode: request.mode, count: request.count };
|
|
229
|
+
var note = (request.note || "").trim();
|
|
230
|
+
if (note) action.note = note;
|
|
231
|
+
if (request.mode === "like") action.fromVersionId = request.fromVersionId;
|
|
232
|
+
return action;
|
|
233
|
+
}
|
|
234
|
+
function startRound(opId, request) {
|
|
235
|
+
return whenSelectionSettled().then(function () { return runAction(roundAction(request), opId); });
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
function commitMore() {
|
|
239
|
+
var m = state.more;
|
|
240
|
+
if (!m || m.committing || moreBusy() || !localImage().ready) return;
|
|
241
|
+
var base = m.like ? moreBase() : null;
|
|
242
|
+
m.committing = true;
|
|
243
|
+
m.error = "";
|
|
244
|
+
syncMore();
|
|
245
|
+
startRound(m.id, { mode: base ? "like" : "new", note: m.note, count: m.count, fromVersionId: base ? base.versionId : undefined }).then(function () {
|
|
246
|
+
m.committing = false;
|
|
247
|
+
if (state.more === m) closeMore(false);
|
|
248
|
+
syncMore();
|
|
249
|
+
}, function (err) {
|
|
250
|
+
m.committing = false;
|
|
251
|
+
if (state.more !== m) return;
|
|
252
|
+
m.error = errText(err);
|
|
253
|
+
syncMore();
|
|
254
|
+
});
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
// The tiles follow the view; the panel sits in the host of the current mode, and keeps what was typed across polls and modes.
|
|
258
|
+
function syncMore() {
|
|
259
|
+
if (!state.view) return;
|
|
260
|
+
var m = state.more;
|
|
261
|
+
if (m && state.view.candidates.length === 0) { m.committing = false; closeMore(false); m = state.more; }
|
|
262
|
+
var busy = moreBusy();
|
|
263
|
+
moreTiles().forEach(function (t) {
|
|
264
|
+
t.disabled = busy;
|
|
265
|
+
t.setAttribute("aria-expanded", m ? "true" : "false");
|
|
266
|
+
});
|
|
267
|
+
if (!m) return;
|
|
268
|
+
var host = isFullscreen() ? stageEls.more : $("more");
|
|
269
|
+
if (host && m.els.box.parentNode !== host) {
|
|
270
|
+
moreHosts().forEach(function (h) { if (h !== host) h.textContent = ""; });
|
|
271
|
+
host.appendChild(m.els.box);
|
|
272
|
+
}
|
|
273
|
+
syncMoreBody(m);
|
|
274
|
+
var local = localImage();
|
|
275
|
+
m.els.primary.disabled = m.committing || busy || !local.ready;
|
|
276
|
+
m.els.alert.textContent = m.error || (!local.ready && local.reason ? local.reason : "");
|
|
277
|
+
m.els.alert.classList.toggle("hidden", !m.els.alert.textContent);
|
|
278
|
+
// Fitted before the size report, so the host never sees the taller card.
|
|
279
|
+
fitMore();
|
|
280
|
+
reportSize();
|
|
281
|
+
}
|
|
282
|
+
window.addEventListener("resize", function () { if (state.more) { fitMore(); reportSize(); } });
|
|
283
|
+
|
|
284
|
+
document.addEventListener("keydown", function (e) {
|
|
285
|
+
if (e.key !== "Escape" || !state.more || state.dialog || state.more.committing) return;
|
|
286
|
+
closeMore(true);
|
|
287
|
+
});
|
|
288
|
+
`;
|
|
289
|
+
//# sourceMappingURL=mcp-slate-ui-script-more.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-slate-ui-script-more.js","sourceRoot":"","sources":["../src/mcp-slate-ui-script-more.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiQtC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The hairline that sits under the large image while work runs on its option.
|
|
3
|
+
* There is no measured duration, so it never estimates: it is indeterminate,
|
|
4
|
+
* and the words (the band, the status line) carry what is happening.
|
|
5
|
+
*/
|
|
6
|
+
export declare const SLATE_UI_PROGRESS: string;
|
|
7
|
+
//# sourceMappingURL=mcp-slate-ui-script-progress.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-slate-ui-script-progress.d.ts","sourceRoot":"","sources":["../src/mcp-slate-ui-script-progress.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,QAE7B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The hairline that sits under the large image while work runs on its option.
|
|
3
|
+
* There is no measured duration, so it never estimates: it is indeterminate,
|
|
4
|
+
* and the words (the band, the status line) carry what is happening.
|
|
5
|
+
*/
|
|
6
|
+
export const SLATE_UI_PROGRESS = String.raw `
|
|
7
|
+
function progressBar() { return el("span", "hair indeterminate"); }
|
|
8
|
+
`;
|
|
9
|
+
//# sourceMappingURL=mcp-slate-ui-script-progress.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-slate-ui-script-progress.js","sourceRoot":"","sources":["../src/mcp-slate-ui-script-progress.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAA;;CAE1C,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What only the hosted target does (TARGET is "remote"): the words it says to the
|
|
3
|
+
* agent, and the marked image an edit carries.
|
|
4
|
+
*
|
|
5
|
+
* The messages. The host wraps every app message as untrusted input, so each one
|
|
6
|
+
* names what happened and carries no command, flag, path, price or credit word;
|
|
7
|
+
* the agent confirms through the model-visible data tool, which returns the
|
|
8
|
+
* server's own trusted text. Six messages exist, one per click (spec v2 9.2):
|
|
9
|
+
* Generate more with new options, Generate more based on a design, Edit,
|
|
10
|
+
* Select, Branch and Convert. The user's own words (a steer note, an edit instruction, the Branch
|
|
11
|
+
* explanation) are never put in a message; the agent reads them from the data
|
|
12
|
+
* tool, quoted. `runDir` is named in each because the tools take it and a
|
|
13
|
+
* thread may hold several workspaces.
|
|
14
|
+
*
|
|
15
|
+
* The marked image. The hosted server does no image work, so the screen
|
|
16
|
+
* composites the strokes onto the parent itself and sends the result with the
|
|
17
|
+
* edit: the parent as shown (the display rendition), scaled so its long edge is
|
|
18
|
+
* at most 1280 px, the strokes in whichever of four colours is farthest from
|
|
19
|
+
* the image's mean colour (as the local server chooses), round caps, a width of
|
|
20
|
+
* 0.8 percent of the shorter side (at least 3 px), exported as a JPEG whose
|
|
21
|
+
* quality steps down until it fits in 300 KiB, and whose size steps down if no
|
|
22
|
+
* quality does. A canvas that cannot be read or exported is an error the dialog
|
|
23
|
+
* shows; the edit is not sent without the picture it asked for.
|
|
24
|
+
*
|
|
25
|
+
* Fragment of the view's script; String.raw, no backtick, no dollar-brace.
|
|
26
|
+
*/
|
|
27
|
+
export declare const SLATE_UI_REMOTE: string;
|
|
28
|
+
//# sourceMappingURL=mcp-slate-ui-script-remote.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-slate-ui-script-remote.d.ts","sourceRoot":"","sources":["../src/mcp-slate-ui-script-remote.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,eAAO,MAAM,eAAe,QAuH3B,CAAC"}
|