@dexhq/canvas 0.15.0 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +34 -0
- package/app/canvas/activity-parts.tsx +50 -6
- package/app/canvas/activity.tsx +2 -3
- package/app/canvas/agent-changes.ts +18 -8
- package/app/canvas/anchoring.ts +13 -3
- package/app/canvas/canvas-context.tsx +6 -2
- package/app/canvas/canvas-input.ts +35 -0
- package/app/canvas/canvas-model.ts +2 -2
- package/app/canvas/canvas-scene.ts +243 -24
- package/app/canvas/canvas-ui.ts +11 -2
- package/app/canvas/canvas.css +86 -3
- package/app/canvas/comments.tsx +66 -29
- package/app/canvas/element-link.ts +135 -0
- package/app/canvas/element-picker.ts +23 -0
- package/app/canvas/export-dialog.tsx +265 -0
- package/app/canvas/flow-canvas.tsx +65 -14
- package/app/canvas/frame-context-menu.tsx +61 -7
- package/app/canvas/frame-node.tsx +10 -11
- package/app/canvas/layout.ts +41 -22
- package/app/canvas/linked-element.tsx +196 -0
- package/app/canvas/live-page.ts +14 -0
- package/app/canvas/mentions.tsx +209 -0
- package/app/canvas/picked-box.tsx +21 -0
- package/app/canvas/removed-views-panel.tsx +4 -4
- package/app/canvas/request-node.tsx +151 -0
- package/app/canvas/review-panel.tsx +8 -3
- package/app/canvas/section-node.tsx +4 -133
- package/app/canvas/spec-margin.tsx +4 -1
- package/app/canvas/teammates-layer.tsx +205 -0
- package/app/canvas/text-layer.tsx +103 -17
- package/app/canvas/tool-cursors.ts +7 -6
- package/app/canvas/tool-icons.tsx +24 -56
- package/app/canvas/typing.ts +12 -0
- package/app/canvas/use-agent-changes.tsx +6 -2
- package/app/canvas/use-canvas-editor.ts +4 -2
- package/app/export/player-model.ts +159 -0
- package/app/export/player.tsx +198 -0
- package/app/export.html +31 -0
- package/app/export.tsx +9 -0
- package/app/frame/announce-refreshes.ts +21 -0
- package/app/frame/start-frame.tsx +50 -0
- package/app/frame/view-loads.ts +161 -0
- package/app/frame/views.ts +13 -49
- package/app/frame.tsx +2 -38
- package/app/i18n/locales/en/messages.po +145 -6
- package/app/i18n/locales/en/messages.ts +1 -1
- package/app/i18n/locales/pseudo/messages.po +144 -5
- package/app/i18n/locales/pseudo/messages.ts +1 -1
- package/app/icons/dex-glyphs.tsx +219 -0
- package/app/icons/glyphs.tsx +76 -80
- package/app/kit/use-flow.ts +2 -1
- package/app/live/canvas-teammates.ts +90 -0
- package/app/live/studio-api.ts +30 -20
- package/app/pages/canvas.tsx +18 -6
- package/app/pages/commands-settings.tsx +1 -1
- package/app/pages/render.tsx +39 -11
- package/app/shell/bell.tsx +15 -5
- package/app/shell/presence.tsx +123 -26
- package/app/shell/thread-list.tsx +25 -8
- package/app/shell/working-on.tsx +35 -3
- package/app/ui/prompt-editor.tsx +39 -11
- package/app/ui/reference.tsx +21 -8
- package/bin/sudio.mjs +1 -1
- package/dist/cli/commands/create.d.mts +5 -5
- package/dist/cli/commands/create.mjs +4 -4
- package/dist/cli/commands/export.d.mts +40 -0
- package/dist/cli/commands/export.mjs +66 -0
- package/dist/cli/commands/init.d.mts +2 -2
- package/dist/cli/commands/upgrade.mjs +1 -1
- package/dist/cli/help.d.mts +1 -1
- package/dist/cli/help.mjs +13 -7
- package/dist/cli/main.d.mts +42 -5
- package/dist/cli/main.mjs +1 -0
- package/dist/config/load.mjs +14 -2
- package/dist/config/project-files.d.mts +5 -0
- package/dist/config/project-files.mjs +10 -1
- package/dist/config/renamed.d.mts +7 -0
- package/dist/config/renamed.mjs +13 -1
- package/dist/content/commands.d.mts +11 -9
- package/dist/content/commands.mjs +22 -16
- package/dist/content/comments-log.mjs +2 -1
- package/dist/content/content.d.mts +11 -3
- package/dist/content/content.mjs +49 -15
- package/dist/content/element-words.d.mts +42 -0
- package/dist/content/element-words.mjs +112 -0
- package/dist/content/hosted-person.d.mts +31 -0
- package/dist/content/hosted-person.mjs +68 -0
- package/dist/content/merge-rules.d.mts +5 -0
- package/dist/content/merge-rules.mjs +17 -1
- package/dist/content/screenshot.mjs +9 -0
- package/dist/content/text-edit.d.mts +24 -14
- package/dist/content/text-edit.mjs +92 -81
- package/dist/content/text-replace.mjs +2 -26
- package/dist/content/thread-module.d.mts +2 -4
- package/dist/content/thread-module.mjs +4 -5
- package/dist/server/agents.d.mts +10 -0
- package/dist/server/agents.mjs +21 -6
- package/dist/server/canvas-presence.d.mts +22 -0
- package/dist/server/canvas-presence.mjs +160 -0
- package/dist/server/command-settings.mjs +1 -1
- package/dist/server/comments/actions.d.mts +0 -8
- package/dist/server/comments/actions.mjs +1 -9
- package/dist/server/comments/routes.mjs +10 -31
- package/dist/server/dev-server.mjs +35 -13
- package/dist/server/export/build.d.mts +15 -0
- package/dist/server/export/build.mjs +220 -0
- package/dist/server/export/page.d.mts +25 -0
- package/dist/server/export/page.mjs +40 -0
- package/dist/server/export/plugin.d.mts +31 -0
- package/dist/server/export/plugin.mjs +69 -0
- package/dist/server/export/run.d.mts +9 -0
- package/dist/server/export/run.mjs +61 -0
- package/dist/server/export/save.d.mts +7 -0
- package/dist/server/export/save.mjs +29 -0
- package/dist/server/hosted.d.mts +8 -0
- package/dist/server/hosted.mjs +78 -0
- package/dist/server/live-mirror.mjs +66 -10
- package/dist/server/live.mjs +28 -1
- package/dist/server/mcp.mjs +2 -0
- package/dist/server/me.d.mts +2 -0
- package/dist/server/me.mjs +8 -2
- package/dist/server/notices.d.mts +1 -1
- package/dist/server/notices.mjs +1 -1
- package/dist/server/own-copies.mjs +1 -1
- package/dist/server/people.d.mts +7 -2
- package/dist/server/people.mjs +6 -2
- package/dist/server/pictures.d.mts +1 -1
- package/dist/server/pictures.mjs +2 -2
- package/dist/server/prebundle.d.mts +32 -0
- package/dist/server/prebundle.mjs +115 -0
- package/dist/server/problems.d.mts +8 -0
- package/dist/server/problems.mjs +13 -0
- package/dist/server/requests.mjs +43 -30
- package/dist/server/source-stamp.d.mts +4 -3
- package/dist/server/source-stamp.mjs +60 -31
- package/dist/server/state.d.mts +19 -10
- package/dist/server/state.mjs +27 -18
- package/dist/server/thread-source.d.mts +8 -0
- package/dist/server/thread-source.mjs +24 -5
- package/dist/server/tools/export.d.mts +5 -0
- package/dist/server/tools/export.mjs +35 -0
- package/dist/server/tools/place-frame.mjs +16 -16
- package/dist/server/tools/thread-list.mjs +1 -1
- package/dist/server/vite.d.mts +9 -4
- package/dist/server/vite.mjs +63 -61
- package/dist/server/welcome.mjs +2 -1
- package/dist/setup/apply.d.mts +4 -0
- package/dist/setup/apply.mjs +5 -4
- package/dist/setup/create.mjs +5 -5
- package/dist/setup/design-system-checks.mjs +1 -6
- package/dist/setup/detect/workspace.d.mts +10 -10
- package/dist/setup/detect/workspace.mjs +10 -12
- package/dist/setup/doctor.d.mts +4 -1
- package/dist/setup/doctor.mjs +7 -5
- package/dist/setup/migrate/dex-folder.d.mts +61 -0
- package/dist/setup/migrate/dex-folder.mjs +544 -0
- package/dist/setup/migrate/files-folder.mjs +1 -1
- package/dist/setup/migrate/guides.mjs +1 -1
- package/dist/setup/migrate/migrations.mjs +4 -0
- package/dist/setup/migrate/setup-files.d.mts +5 -0
- package/dist/setup/migrate/setup-files.mjs +115 -0
- package/dist/setup/migrate/studio-state.d.mts +2 -2
- package/dist/setup/migrate/studio-state.mjs +4 -4
- package/dist/setup/placement.d.mts +1 -1
- package/dist/setup/placement.mjs +5 -4
- package/dist/setup/plan.d.mts +5 -5
- package/dist/setup/plan.mjs +8 -12
- package/dist/setup/project.mjs +1 -1
- package/dist/setup/prompts.d.mts +2 -1
- package/dist/setup/prompts.mjs +4 -3
- package/dist/setup/questions.mjs +3 -2
- package/dist/setup/starters.d.mts +1 -1
- package/dist/setup/starters.mjs +2 -2
- package/dist/setup/write.d.mts +15 -3
- package/dist/setup/write.mjs +23 -3
- package/dist/shared/canvas-core.d.mts +22 -7
- package/dist/shared/canvas-core.mjs +38 -10
- package/dist/shared/comments/routes.d.mts +3 -1
- package/dist/shared/comments/routes.mjs +4 -2
- package/dist/shared/export-core.d.mts +62 -0
- package/dist/shared/export-core.mjs +101 -0
- package/dist/shared/live-core.d.mts +2 -0
- package/dist/shared/live-core.mjs +6 -1
- package/dist/shared/live-presence.d.mts +57 -2
- package/dist/shared/live-presence.mjs +90 -4
- package/dist/shared/page-messages.d.mts +14 -1
- package/dist/shared/page-messages.mjs +30 -3
- package/dist/shared/people-core.d.mts +28 -0
- package/dist/shared/people-core.mjs +27 -1
- package/dist/shared/presence-core.d.mts +2 -0
- package/dist/shared/references-core.d.mts +4 -0
- package/dist/shared/references-core.mjs +12 -4
- package/dist/shared/studio-files.d.mts +9 -0
- package/dist/shared/studio-files.mjs +11 -2
- package/dist/shared/studio-routes.d.mts +13 -1
- package/dist/shared/threads-core.d.mts +27 -4
- package/dist/shared/threads-core.mjs +67 -12
- package/extension/dist/feedback.js +104 -294
- package/extension/dist/manifest.json +1 -1
- package/extension/dist/picker.js +104 -294
- package/package.json +2 -2
- package/src/cli/commands/create.ts +4 -4
- package/src/cli/commands/export.ts +78 -0
- package/src/cli/commands/upgrade.ts +1 -1
- package/src/cli/help.ts +13 -7
- package/src/cli/main.ts +1 -0
- package/src/config/load.ts +26 -2
- package/src/config/project-files.ts +15 -0
- package/src/config/renamed.ts +19 -1
- package/src/content/commands.ts +30 -18
- package/src/content/comments-log.ts +4 -1
- package/src/content/content.ts +64 -16
- package/src/content/element-words.ts +175 -0
- package/src/content/hosted-person.ts +107 -0
- package/src/content/merge-rules.ts +29 -0
- package/src/content/screenshot.ts +14 -0
- package/src/content/text-edit.ts +172 -105
- package/src/content/text-replace.ts +3 -32
- package/src/content/thread-module.ts +2 -4
- package/src/content/trash.ts +1 -1
- package/src/server/agents.ts +48 -17
- package/src/server/canvas-presence.ts +237 -0
- package/src/server/channel.ts +1 -1
- package/src/server/command-settings.ts +1 -1
- package/src/server/comments/actions.ts +0 -19
- package/src/server/comments/routes.ts +9 -54
- package/src/server/dev-server.ts +66 -26
- package/src/server/export/build.ts +310 -0
- package/src/server/export/page.ts +85 -0
- package/src/server/export/plugin.ts +138 -0
- package/src/server/export/run.ts +79 -0
- package/src/server/export/save.ts +38 -0
- package/src/server/hosted.ts +113 -0
- package/src/server/live-mirror.ts +93 -8
- package/src/server/live.ts +46 -1
- package/src/server/machine-update.ts +3 -3
- package/src/server/mcp.ts +2 -0
- package/src/server/me.ts +10 -1
- package/src/server/notices.ts +2 -2
- package/src/server/people.ts +11 -2
- package/src/server/pictures.ts +2 -2
- package/src/server/prebundle.ts +230 -0
- package/src/server/presence.ts +1 -1
- package/src/server/problems.ts +11 -0
- package/src/server/requests.ts +55 -40
- package/src/server/roster.ts +1 -1
- package/src/server/saved.ts +1 -1
- package/src/server/source-stamp.ts +118 -37
- package/src/server/state.ts +53 -31
- package/src/server/thread-source.ts +35 -3
- package/src/server/tools/export.ts +56 -0
- package/src/server/tools/place-frame.ts +23 -15
- package/src/server/tools/thread-list.ts +1 -1
- package/src/server/updates.ts +2 -2
- package/src/server/vite.ts +106 -110
- package/src/server/welcome.ts +3 -1
- package/src/setup/apply.ts +8 -5
- package/src/setup/create.ts +10 -10
- package/src/setup/design-system-checks.ts +1 -6
- package/src/setup/detect/workspace.ts +20 -21
- package/src/setup/doctor.ts +13 -6
- package/src/setup/migrate/dex-folder.ts +842 -0
- package/src/setup/migrate/files-folder.ts +1 -1
- package/src/setup/migrate/guides.ts +3 -1
- package/src/setup/migrate/migrations.ts +8 -2
- package/src/setup/migrate/setup-files.ts +198 -0
- package/src/setup/migrate/studio-state.ts +12 -10
- package/src/setup/own-app.ts +1 -1
- package/src/setup/placement.ts +7 -6
- package/src/setup/plan.ts +13 -18
- package/src/setup/project.ts +2 -2
- package/src/setup/prompts.ts +5 -4
- package/src/setup/questions.ts +6 -3
- package/src/setup/starters.ts +3 -3
- package/src/setup/write.ts +34 -3
- package/src/shared/canvas-core.ts +48 -9
- package/src/shared/comments/routes.ts +3 -1
- package/src/shared/export-core.ts +198 -0
- package/src/shared/live-core.ts +8 -0
- package/src/shared/live-presence.ts +171 -2
- package/src/shared/page-messages.ts +38 -2
- package/src/shared/people-core.ts +44 -0
- package/src/shared/presence-core.ts +2 -0
- package/src/shared/references-core.ts +22 -3
- package/src/shared/studio-files.ts +15 -1
- package/src/shared/studio-routes.ts +11 -1
- package/src/shared/threads-core.ts +132 -10
- package/templates/methods/explore.md +1 -1
- package/templates/methods/handoff.md +1 -1
- package/templates/methods/review.md +2 -1
- package/templates/rules/canvas-frames.md +6 -3
- package/templates/rules/commands.md +1 -0
- package/templates/rules/prototypes.md +1 -1
- package/templates/rules/studio.md +17 -11
- package/templates/skills/comprehend/SKILL.md +56 -0
- package/templates/skills/distill/SKILL.md +172 -0
- package/templates/skills/export-prototype/SKILL.md +35 -0
- package/templates/skills/riff/SKILL.md +21 -0
- package/templates/skills/riff-deep/SKILL.md +40 -0
- package/templates/skills/riff-max/SKILL.md +46 -0
- package/templates/skills/riff-state/SKILL.md +45 -0
- package/templates/skills/riff-up/SKILL.md +38 -0
- package/templates/skills/riff-wide/SKILL.md +40 -0
- package/templates/starters/standalone/README.md +1 -1
- package/templates/starters/turborepo/README.md +2 -2
- package/templates/starters/turborepo/apps/web/src/app.tsx +2 -2
- package/templates/starters/vite/README.md +1 -1
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
isClosed,
|
|
11
11
|
threadState,
|
|
12
12
|
} from "../../src/shared/threads-core.ts";
|
|
13
|
+
import { MessageWords, mentionsMe } from "../canvas/mentions";
|
|
13
14
|
import { ReviewMarker, useReviewNumber } from "../canvas/review-marker";
|
|
14
15
|
import { isGuestThread } from "../live/guest-review";
|
|
15
16
|
import { CAN_WRITE } from "../live/studio-api";
|
|
@@ -23,14 +24,18 @@ import { shortTimeAgo } from "./time-ago";
|
|
|
23
24
|
// who, how long ago, what they said; the bell adds which file it is in.
|
|
24
25
|
|
|
25
26
|
/**
|
|
26
|
-
* Whose threads a list shows: everyone's, people's or agents'
|
|
27
|
-
* studio, also only yours (the threads
|
|
27
|
+
* Whose threads a list shows: everyone's, people's or agents', or those
|
|
28
|
+
* that mention you; on a deployed studio, also only yours (the threads
|
|
29
|
+
* this browser started).
|
|
28
30
|
*/
|
|
29
|
-
export type ThreadFilter = "all" | "people" | "agents" | "yours";
|
|
31
|
+
export type ThreadFilter = "all" | "people" | "agents" | "mentions" | "yours";
|
|
30
32
|
|
|
31
|
-
/**
|
|
33
|
+
/**
|
|
34
|
+
* Whether a thread is one `filter` shows: by who it is for, yours, or one
|
|
35
|
+
* that mentions `me`.
|
|
36
|
+
*/
|
|
32
37
|
export const byFilter =
|
|
33
|
-
(filter: ThreadFilter) =>
|
|
38
|
+
(filter: ThreadFilter, me?: string) =>
|
|
34
39
|
(thread: Thread): boolean => {
|
|
35
40
|
if (filter === "all") {
|
|
36
41
|
return true;
|
|
@@ -38,6 +43,9 @@ export const byFilter =
|
|
|
38
43
|
if (filter === "yours") {
|
|
39
44
|
return isGuestThread(thread);
|
|
40
45
|
}
|
|
46
|
+
if (filter === "mentions") {
|
|
47
|
+
return mentionsMe(me)(thread);
|
|
48
|
+
}
|
|
41
49
|
return audienceOf(thread) === (filter === "agents" ? "agent" : "people");
|
|
42
50
|
};
|
|
43
51
|
|
|
@@ -45,13 +53,20 @@ const FILTERS = [
|
|
|
45
53
|
{ id: "all", label: msg`All` },
|
|
46
54
|
{ id: "people", label: msg`People` },
|
|
47
55
|
{ id: "agents", label: msg`Agents` },
|
|
56
|
+
{ id: "mentions", label: msg`Mentions` },
|
|
48
57
|
] as const;
|
|
49
58
|
|
|
50
|
-
/**
|
|
59
|
+
/**
|
|
60
|
+
* All, People or Agents, as segmented tabs; and Mentions, with
|
|
61
|
+
* `canBeMentioned`
|
|
62
|
+
* (where you are someone who can be mentioned).
|
|
63
|
+
*/
|
|
51
64
|
export const ThreadFilterTabs = ({
|
|
65
|
+
canBeMentioned = false,
|
|
52
66
|
onChange,
|
|
53
67
|
value,
|
|
54
68
|
}: {
|
|
69
|
+
canBeMentioned?: boolean;
|
|
55
70
|
onChange: (filter: ThreadFilter) => void;
|
|
56
71
|
value: ThreadFilter;
|
|
57
72
|
}) => {
|
|
@@ -60,7 +75,9 @@ export const ThreadFilterTabs = ({
|
|
|
60
75
|
<Segmented
|
|
61
76
|
label={_(msg`Show comments from`)}
|
|
62
77
|
onChange={onChange}
|
|
63
|
-
segments={FILTERS.
|
|
78
|
+
segments={FILTERS.filter(
|
|
79
|
+
({ id }) => canBeMentioned || id !== "mentions"
|
|
80
|
+
).map(({ id, label }) => ({ id, label: _(label) }))}
|
|
64
81
|
value={value}
|
|
65
82
|
/>
|
|
66
83
|
);
|
|
@@ -183,7 +200,7 @@ export const ThreadRow = ({
|
|
|
183
200
|
action && "pr-6"
|
|
184
201
|
)}
|
|
185
202
|
>
|
|
186
|
-
{post?.body}
|
|
203
|
+
<MessageWords still text={post?.body ?? ""} />
|
|
187
204
|
</span>
|
|
188
205
|
<span className="sr-only">{_(STATE_LABELS[state])}</span>
|
|
189
206
|
</span>
|
package/app/shell/working-on.tsx
CHANGED
|
@@ -1,8 +1,31 @@
|
|
|
1
1
|
import { useLingui } from "@lingui/react/macro";
|
|
2
|
+
import { fromRoom } from "../../src/shared/live-presence.ts";
|
|
2
3
|
import { Tip } from "../canvas/tip";
|
|
3
4
|
import { agentNames, type PresenceEntry } from "../live/studio-live";
|
|
4
5
|
import { Avatar } from "./avatar";
|
|
5
6
|
|
|
7
|
+
/** Room sessions: "live:<client>", and "live:<client>:<agent>" for agents. */
|
|
8
|
+
const SESSION_SEPARATOR = ":";
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* How one entry shows. Our agents, and teammates' agents (`dex cloud live`
|
|
12
|
+
* names them "Sam's Codex"), by their agent's mark; a teammate in the
|
|
13
|
+
* browser, by their own initials, so people are told apart from agents and
|
|
14
|
+
* from each other.
|
|
15
|
+
*/
|
|
16
|
+
const avatarOf = (entry: PresenceEntry) => {
|
|
17
|
+
if (!fromRoom(entry)) {
|
|
18
|
+
return { agent: true, key: entry.agent, name: entry.agent };
|
|
19
|
+
}
|
|
20
|
+
const agent = String(entry.session)
|
|
21
|
+
.split(SESSION_SEPARATOR)
|
|
22
|
+
.slice(2)
|
|
23
|
+
.join(SESSION_SEPARATOR);
|
|
24
|
+
return agent
|
|
25
|
+
? { agent: true, key: entry.agent, name: agent }
|
|
26
|
+
: { agent: false, key: entry.agent, name: entry.agent };
|
|
27
|
+
};
|
|
28
|
+
|
|
6
29
|
/**
|
|
7
30
|
* An agent at work, as its avatar alone: no line says what it does. Its tip
|
|
8
31
|
* and its name for screen readers do ("Claude is editing").
|
|
@@ -21,13 +44,22 @@ export const WorkingOn = ({
|
|
|
21
44
|
const names = agentNames(entries, i18n);
|
|
22
45
|
const label =
|
|
23
46
|
verb === "working" ? t`${names} is working` : t`${names} is editing`;
|
|
24
|
-
const
|
|
47
|
+
const avatars = [
|
|
48
|
+
...new Map(
|
|
49
|
+
entries.map((entry) => [entry.agent, avatarOf(entry)] as const)
|
|
50
|
+
).values(),
|
|
51
|
+
];
|
|
25
52
|
return (
|
|
26
53
|
<Tip label={label}>
|
|
27
54
|
<span className="flex items-center -space-x-1" role="status">
|
|
28
55
|
<span className="sr-only">{label}</span>
|
|
29
|
-
{
|
|
30
|
-
<Avatar
|
|
56
|
+
{avatars.map((avatar) => (
|
|
57
|
+
<Avatar
|
|
58
|
+
agent={avatar.agent}
|
|
59
|
+
key={avatar.key}
|
|
60
|
+
name={avatar.name}
|
|
61
|
+
size={20}
|
|
62
|
+
/>
|
|
31
63
|
))}
|
|
32
64
|
</span>
|
|
33
65
|
</Tip>
|
package/app/ui/prompt-editor.tsx
CHANGED
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
// A message box that holds references as chips in its words: type a
|
|
32
32
|
// trigger ("/" for a command, "@" for a person) for a menu of what it can
|
|
33
33
|
// name, and the one chosen sits in the text as a chip, removed with one
|
|
34
|
-
// Backspace. Its value is plain text, "/break german", so what holds it
|
|
34
|
+
// Backspace. Its value is plain text, "/break german, @ana", so what holds it
|
|
35
35
|
// stores and sends words; the chips are only how it is drawn. A drop-in for
|
|
36
36
|
// shadcn's InputGroupTextarea: it takes the same slot in an InputGroup.
|
|
37
37
|
// Built on TipTap, as documents are (editor/extensions.ts), and its menu
|
|
@@ -41,8 +41,13 @@ import {
|
|
|
41
41
|
export interface PromptChoice {
|
|
42
42
|
/** One line on what it is, under its name in the menu. */
|
|
43
43
|
description?: string;
|
|
44
|
-
/** Its name, as written after the trigger: "break". */
|
|
44
|
+
/** Its name, as written after the trigger: "break", "ana". */
|
|
45
45
|
id: string;
|
|
46
|
+
/**
|
|
47
|
+
* What it is called, where that is not its id (a person's name): the menu
|
|
48
|
+
* shows it and finds it by it, and its chip shows it after the trigger.
|
|
49
|
+
*/
|
|
50
|
+
name?: string;
|
|
46
51
|
/**
|
|
47
52
|
* Whether the menu offers it; false still draws it as a chip where the
|
|
48
53
|
* text names it (one taken out of the menu since, say).
|
|
@@ -108,7 +113,13 @@ export const detailsOf =
|
|
|
108
113
|
const choice = triggers
|
|
109
114
|
.find((trigger) => trigger.char === char)
|
|
110
115
|
?.choices.find((each) => each.id === id);
|
|
111
|
-
return
|
|
116
|
+
return (
|
|
117
|
+
choice && {
|
|
118
|
+
title: choice.name ?? choice.id,
|
|
119
|
+
description: choice.description,
|
|
120
|
+
...(choice.name ? { chip: `${char}${choice.name}` } : {}),
|
|
121
|
+
}
|
|
122
|
+
);
|
|
112
123
|
};
|
|
113
124
|
|
|
114
125
|
/** The triggers' names, by character, for finding references in text. */
|
|
@@ -185,13 +196,30 @@ const typedTrigger = (editor: Editor, chars: readonly string[]) => {
|
|
|
185
196
|
);
|
|
186
197
|
};
|
|
187
198
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
199
|
+
const SPACES_RE = /\s+/;
|
|
200
|
+
|
|
201
|
+
/** A choice's words to find it by: its id, and its name's, in lower case. */
|
|
202
|
+
const wordsOf = (choice: PromptChoice) =>
|
|
203
|
+
[choice.id, ...(choice.name?.toLowerCase().split(SPACES_RE) ?? [])].filter(
|
|
204
|
+
Boolean
|
|
205
|
+
);
|
|
206
|
+
|
|
207
|
+
/** Those with a word starting with the query first, then those containing it. */
|
|
208
|
+
const matching = (choices: readonly PromptChoice[], typed: string) => {
|
|
209
|
+
const query = typed.toLowerCase();
|
|
210
|
+
const starts = (choice: PromptChoice) =>
|
|
211
|
+
wordsOf(choice).some((word) => word.startsWith(query));
|
|
212
|
+
return [
|
|
213
|
+
...choices.filter(starts),
|
|
214
|
+
...choices.filter(
|
|
215
|
+
(choice) =>
|
|
216
|
+
!starts(choice) &&
|
|
217
|
+
[choice.id, choice.name?.toLowerCase() ?? ""].some((word) =>
|
|
218
|
+
word.includes(query)
|
|
219
|
+
)
|
|
220
|
+
),
|
|
221
|
+
];
|
|
222
|
+
};
|
|
195
223
|
|
|
196
224
|
/** Below the caret, the menu's gap. */
|
|
197
225
|
const MENU_GAP = 6;
|
|
@@ -324,7 +352,7 @@ const TriggerMenu = ({
|
|
|
324
352
|
role="option"
|
|
325
353
|
tabIndex={-1}
|
|
326
354
|
>
|
|
327
|
-
<span className="font-medium">{choice.id}</span>
|
|
355
|
+
<span className="font-medium">{choice.name ?? choice.id}</span>
|
|
328
356
|
{choice.description ? (
|
|
329
357
|
// A skill's description can run long: its chip shows it whole.
|
|
330
358
|
<span className="studio-small line-clamp-2 text-muted-foreground">
|
package/app/ui/reference.tsx
CHANGED
|
@@ -14,8 +14,8 @@ import {
|
|
|
14
14
|
referenceText,
|
|
15
15
|
} from "../../src/shared/references-core.ts";
|
|
16
16
|
|
|
17
|
-
// A reference as a chip: a command ("/break") or
|
|
18
|
-
//
|
|
17
|
+
// A reference as a chip: a command ("/break", drawn "break") or a person
|
|
18
|
+
// ("@ana", drawn "@Ana Lima"). The same chip in the comment box (PromptEditor draws it as a
|
|
19
19
|
// node view) and in a posted message (ReferenceText). Pointing at it, or a
|
|
20
20
|
// click, shows what it is: its name and description, from ReferenceDetails.
|
|
21
21
|
|
|
@@ -25,6 +25,8 @@ export const REFERENCE_CLASS =
|
|
|
25
25
|
|
|
26
26
|
/** What a chip shows when it is pointed at or clicked. */
|
|
27
27
|
export interface ReferenceDetail {
|
|
28
|
+
/** What its chip says, where not its id: "@Ana Lima" for "@ana". */
|
|
29
|
+
chip?: string;
|
|
28
30
|
description?: string;
|
|
29
31
|
title: string;
|
|
30
32
|
}
|
|
@@ -47,14 +49,22 @@ export const ReferenceDetails = ({
|
|
|
47
49
|
/** How long the pointer rests on a chip before its details show. */
|
|
48
50
|
const HOVER_DELAY = 300;
|
|
49
51
|
|
|
50
|
-
/**
|
|
51
|
-
|
|
52
|
+
/**
|
|
53
|
+
* One reference's chip; its details on hover or click, when known, unless
|
|
54
|
+
* `still` (inside what is itself a button, such as a list's row).
|
|
55
|
+
*/
|
|
56
|
+
export const Reference = ({
|
|
57
|
+
char,
|
|
58
|
+
id,
|
|
59
|
+
still = false,
|
|
60
|
+
}: ReferenceValue & { still?: boolean }) => {
|
|
52
61
|
const detail = useContext(DetailsContext)({ char, id });
|
|
53
62
|
const chip = REFERENCE_CLASS;
|
|
54
|
-
|
|
63
|
+
const words = detail?.chip ?? id;
|
|
64
|
+
if (!detail || still) {
|
|
55
65
|
return (
|
|
56
66
|
<span className={chip} data-char={char}>
|
|
57
|
-
{
|
|
67
|
+
{words}
|
|
58
68
|
</span>
|
|
59
69
|
);
|
|
60
70
|
}
|
|
@@ -71,7 +81,7 @@ export const Reference = ({ char, id }: ReferenceValue) => {
|
|
|
71
81
|
<span className={cn(chip, "cursor-default")} data-char={char} />
|
|
72
82
|
}
|
|
73
83
|
>
|
|
74
|
-
{
|
|
84
|
+
{words}
|
|
75
85
|
</PopoverTrigger>
|
|
76
86
|
<PopoverContent align="start" className="w-64 gap-1 p-3" side="top">
|
|
77
87
|
<PopoverHeader>
|
|
@@ -90,9 +100,12 @@ export const Reference = ({ char, id }: ReferenceValue) => {
|
|
|
90
100
|
* ReferenceDetails knows, so "/tmp" in a sentence stays a word.
|
|
91
101
|
*/
|
|
92
102
|
export const ReferenceText = ({
|
|
103
|
+
still = false,
|
|
93
104
|
text,
|
|
94
105
|
triggers,
|
|
95
106
|
}: {
|
|
107
|
+
/** Chips without their details, inside what is itself a button. */
|
|
108
|
+
still?: boolean;
|
|
96
109
|
text: string;
|
|
97
110
|
/** The characters references start with: "/", "@". */
|
|
98
111
|
triggers: readonly string[];
|
|
@@ -106,7 +119,7 @@ export const ReferenceText = ({
|
|
|
106
119
|
const { char, id } = part.reference;
|
|
107
120
|
return describe(part.reference) ? (
|
|
108
121
|
// biome-ignore lint/suspicious/noArrayIndexKey: parts have no other identity, and keep their order
|
|
109
|
-
<Reference char={char} id={id} key={index} />
|
|
122
|
+
<Reference char={char} id={id} key={index} still={still} />
|
|
110
123
|
) : (
|
|
111
124
|
referenceText(part.reference)
|
|
112
125
|
);
|
package/bin/sudio.mjs
CHANGED
|
@@ -4,6 +4,6 @@
|
|
|
4
4
|
// once what to change, on stderr (stdout may be an MCP channel), and runs
|
|
5
5
|
// `dex` with the same arguments.
|
|
6
6
|
process.stderr.write(
|
|
7
|
-
"Sudio is now Dex: run `dex` instead of `sudio` (in package.json scripts and agents' configs too). `npx dex
|
|
7
|
+
"Sudio is now Dex: run `dex` instead of `sudio` (in package.json scripts and agents' configs too). `npx dex upgrade` does it.\n"
|
|
8
8
|
);
|
|
9
9
|
await import("./dex.mjs");
|
|
@@ -9,12 +9,12 @@ export declare const SETUP_ARGS: {
|
|
|
9
9
|
readonly in: {
|
|
10
10
|
readonly type: "string";
|
|
11
11
|
readonly valueHint: "package";
|
|
12
|
-
readonly description: "In a workspace: the studio inside this package, in its
|
|
12
|
+
readonly description: "In a workspace: the studio inside this package, in its Dex folder (dex/), e.g. --in apps/web";
|
|
13
13
|
};
|
|
14
14
|
readonly dir: {
|
|
15
15
|
readonly type: "string";
|
|
16
16
|
readonly valueHint: "folder";
|
|
17
|
-
readonly description: "The
|
|
17
|
+
readonly description: "The Dex folder in the project (default: dex)";
|
|
18
18
|
};
|
|
19
19
|
readonly components: {
|
|
20
20
|
readonly type: "string";
|
|
@@ -143,12 +143,12 @@ declare const _default: import("citty").CommandDef<{
|
|
|
143
143
|
readonly in: {
|
|
144
144
|
readonly type: "string";
|
|
145
145
|
readonly valueHint: "package";
|
|
146
|
-
readonly description: "In a workspace: the studio inside this package, in its
|
|
146
|
+
readonly description: "In a workspace: the studio inside this package, in its Dex folder (dex/), e.g. --in apps/web";
|
|
147
147
|
};
|
|
148
148
|
readonly dir: {
|
|
149
149
|
readonly type: "string";
|
|
150
150
|
readonly valueHint: "folder";
|
|
151
|
-
readonly description: "The
|
|
151
|
+
readonly description: "The Dex folder in the project (default: dex)";
|
|
152
152
|
};
|
|
153
153
|
readonly components: {
|
|
154
154
|
readonly type: "string";
|
|
@@ -238,7 +238,7 @@ declare const _default: import("citty").CommandDef<{
|
|
|
238
238
|
readonly template: {
|
|
239
239
|
readonly type: "string";
|
|
240
240
|
readonly valueHint: "name";
|
|
241
|
-
readonly description: "In an empty folder, the new project: vite (a Vite + React app, also called shadcn), standalone (the studio on its own) or turborepo (apps/web, a shared packages/ui and the studio in apps/
|
|
241
|
+
readonly description: "In an empty folder, the new project: vite (a Vite + React app, also called shadcn), standalone (the studio on its own) or turborepo (apps/web, a shared packages/ui and the studio in apps/dex); all shadcn on Base UI (default: vite)";
|
|
242
242
|
};
|
|
243
243
|
}>;
|
|
244
244
|
//#endregion
|
|
@@ -11,12 +11,12 @@ const SETUP_ARGS = {
|
|
|
11
11
|
in: {
|
|
12
12
|
type: "string",
|
|
13
13
|
valueHint: "package",
|
|
14
|
-
description: "In a workspace: the studio inside this package, in its
|
|
14
|
+
description: "In a workspace: the studio inside this package, in its Dex folder (dex/), e.g. --in apps/web"
|
|
15
15
|
},
|
|
16
16
|
dir: {
|
|
17
17
|
type: "string",
|
|
18
18
|
valueHint: "folder",
|
|
19
|
-
description: "The
|
|
19
|
+
description: "The Dex folder in the project (default: dex)"
|
|
20
20
|
},
|
|
21
21
|
components: {
|
|
22
22
|
type: "string",
|
|
@@ -119,7 +119,7 @@ const setupFlags = (args) => ({
|
|
|
119
119
|
var create_default = defineCommand({
|
|
120
120
|
meta: {
|
|
121
121
|
name: "create",
|
|
122
|
-
description: "Set up a studio, saying what it does at each step: in a project (where its package.json is) it adds one in
|
|
122
|
+
description: "Set up a studio, saying what it does at each step: in a project (where its package.json is) it adds one in its Dex folder, dex/; in a workspace it gives the studio its own app (apps/dex) or puts it inside an app, by where your components are; in an empty folder it starts a new project (--template: a Vite + React app, a standalone studio or a Turborepo, all shadcn on Base UI) with one. It asks you to confirm what it finds and shows the plan first; without a terminal, or with --yes, it takes what it finds."
|
|
123
123
|
},
|
|
124
124
|
args: {
|
|
125
125
|
folder: {
|
|
@@ -135,7 +135,7 @@ var create_default = defineCommand({
|
|
|
135
135
|
template: {
|
|
136
136
|
type: "string",
|
|
137
137
|
valueHint: "name",
|
|
138
|
-
description: "In an empty folder, the new project: vite (a Vite + React app, also called shadcn), standalone (the studio on its own) or turborepo (apps/web, a shared packages/ui and the studio in apps/
|
|
138
|
+
description: "In an empty folder, the new project: vite (a Vite + React app, also called shadcn), standalone (the studio on its own) or turborepo (apps/web, a shared packages/ui and the studio in apps/dex); all shadcn on Base UI (default: vite)"
|
|
139
139
|
},
|
|
140
140
|
...SETUP_ARGS
|
|
141
141
|
},
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
//#region src/cli/commands/export.d.ts
|
|
2
|
+
declare const _default: import("citty").CommandDef<{
|
|
3
|
+
readonly slug: {
|
|
4
|
+
readonly required: true;
|
|
5
|
+
readonly type: "string";
|
|
6
|
+
readonly valueHint: "file";
|
|
7
|
+
readonly description: "The file's folder";
|
|
8
|
+
};
|
|
9
|
+
readonly frames: {
|
|
10
|
+
readonly type: "string";
|
|
11
|
+
readonly valueHint: "keys";
|
|
12
|
+
readonly description: "Frame keys (section/row/frame), comma-separated";
|
|
13
|
+
};
|
|
14
|
+
readonly sections: {
|
|
15
|
+
readonly type: "string";
|
|
16
|
+
readonly valueHint: "ids";
|
|
17
|
+
readonly description: "Whole sections, comma-separated (default: every section)";
|
|
18
|
+
};
|
|
19
|
+
readonly kind: {
|
|
20
|
+
readonly type: "string";
|
|
21
|
+
readonly valueHint: "kind";
|
|
22
|
+
readonly description: "clickable, pages, content or source";
|
|
23
|
+
readonly default: "clickable";
|
|
24
|
+
};
|
|
25
|
+
readonly flows: {
|
|
26
|
+
readonly type: "boolean";
|
|
27
|
+
readonly description: "Let people switch between the exported flows";
|
|
28
|
+
};
|
|
29
|
+
readonly out: {
|
|
30
|
+
readonly type: "string";
|
|
31
|
+
readonly valueHint: "folder";
|
|
32
|
+
readonly description: "Where to save the zip (default: Downloads)";
|
|
33
|
+
};
|
|
34
|
+
readonly json: {
|
|
35
|
+
readonly type: "boolean";
|
|
36
|
+
readonly description: "Print { path } as JSON";
|
|
37
|
+
};
|
|
38
|
+
}>;
|
|
39
|
+
//#endregion
|
|
40
|
+
export { _default as default };
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { loadProject, print } from "../command.mjs";
|
|
2
|
+
import { isText } from "../../shared/checks.mjs";
|
|
3
|
+
import { slug } from "./work/args.mjs";
|
|
4
|
+
import { defineCommand } from "citty";
|
|
5
|
+
//#region src/cli/commands/export.ts
|
|
6
|
+
const list = (value) => isText(value) ? value.split(",").map((part) => part.trim()).filter(Boolean) : void 0;
|
|
7
|
+
var export_default = defineCommand({
|
|
8
|
+
meta: {
|
|
9
|
+
name: "export",
|
|
10
|
+
description: "Export a file's frames as a prototype that opens by double-click, offline: a zip of index.html, app.js and app.css, in Downloads."
|
|
11
|
+
},
|
|
12
|
+
args: {
|
|
13
|
+
slug: {
|
|
14
|
+
...slug,
|
|
15
|
+
required: true
|
|
16
|
+
},
|
|
17
|
+
frames: {
|
|
18
|
+
type: "string",
|
|
19
|
+
valueHint: "keys",
|
|
20
|
+
description: "Frame keys (section/row/frame), comma-separated"
|
|
21
|
+
},
|
|
22
|
+
sections: {
|
|
23
|
+
type: "string",
|
|
24
|
+
valueHint: "ids",
|
|
25
|
+
description: "Whole sections, comma-separated (default: every section)"
|
|
26
|
+
},
|
|
27
|
+
kind: {
|
|
28
|
+
type: "string",
|
|
29
|
+
valueHint: "kind",
|
|
30
|
+
description: "clickable, pages, content or source",
|
|
31
|
+
default: "clickable"
|
|
32
|
+
},
|
|
33
|
+
flows: {
|
|
34
|
+
type: "boolean",
|
|
35
|
+
description: "Let people switch between the exported flows"
|
|
36
|
+
},
|
|
37
|
+
out: {
|
|
38
|
+
type: "string",
|
|
39
|
+
valueHint: "folder",
|
|
40
|
+
description: "Where to save the zip (default: Downloads)"
|
|
41
|
+
},
|
|
42
|
+
json: {
|
|
43
|
+
type: "boolean",
|
|
44
|
+
description: "Print { path } as JSON"
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
async run({ args }) {
|
|
48
|
+
const [{ exportChoiceProblems }, { exportPrototype }, { saveExport }] = await Promise.all([
|
|
49
|
+
import("../../shared/export-core.mjs"),
|
|
50
|
+
import("../../server/export/build.mjs"),
|
|
51
|
+
import("../../server/export/save.mjs")
|
|
52
|
+
]);
|
|
53
|
+
const choice = {
|
|
54
|
+
kind: args.kind,
|
|
55
|
+
frames: list(args.frames),
|
|
56
|
+
sections: list(args.sections),
|
|
57
|
+
flows: Boolean(args.flows)
|
|
58
|
+
};
|
|
59
|
+
const problems = exportChoiceProblems(choice);
|
|
60
|
+
if (problems.length > 0) throw new Error(problems.join(" "));
|
|
61
|
+
const path = await saveExport(await exportPrototype(await loadProject(process.cwd(), "build"), args.slug, choice), args.out);
|
|
62
|
+
print(args.json ? JSON.stringify({ path }) : `Exported to ${path}`);
|
|
63
|
+
}
|
|
64
|
+
});
|
|
65
|
+
//#endregion
|
|
66
|
+
export { export_default as default };
|
|
@@ -12,12 +12,12 @@ declare const _default: import("citty").CommandDef<{
|
|
|
12
12
|
readonly in: {
|
|
13
13
|
readonly type: "string";
|
|
14
14
|
readonly valueHint: "package";
|
|
15
|
-
readonly description: "In a workspace: the studio inside this package, in its
|
|
15
|
+
readonly description: "In a workspace: the studio inside this package, in its Dex folder (dex/), e.g. --in apps/web";
|
|
16
16
|
};
|
|
17
17
|
readonly dir: {
|
|
18
18
|
readonly type: "string";
|
|
19
19
|
readonly valueHint: "folder";
|
|
20
|
-
readonly description: "The
|
|
20
|
+
readonly description: "The Dex folder in the project (default: dex)";
|
|
21
21
|
};
|
|
22
22
|
readonly components: {
|
|
23
23
|
readonly type: "string";
|
|
@@ -33,7 +33,7 @@ async function upgrade({ dryRun = false, cwd = process.cwd() } = {}) {
|
|
|
33
33
|
var upgrade_default = defineCommand({
|
|
34
34
|
meta: {
|
|
35
35
|
name: "upgrade",
|
|
36
|
-
description: "Bring a studio set up by an older version up to date: studio.config.ts renamed to dex.config.ts, the design system into it, its state
|
|
36
|
+
description: "Bring a studio set up by an older version up to date: studio.config.ts renamed to dex.config.ts, the design system into it, studio/ moved to the Dex folder, dex/, with its state (.local/) and the team's skills (skills/) in it, each file's owner's work into people/, every file into files/, and the installed rules."
|
|
37
37
|
},
|
|
38
38
|
args: { "dry-run": {
|
|
39
39
|
type: "boolean",
|
package/dist/cli/help.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Described } from "./command.mjs";
|
|
2
2
|
//#region src/cli/help.d.ts
|
|
3
3
|
/** `dex --help`. Every command and flag in it is tested to exist. */
|
|
4
|
-
export declare const ROOT_HELP = "Dex\n\nUsage: dex <command> [options]\n dex <command> --help that command's options\n\nSet up and maintain\n create [folder] [--yes] [--dry-run] [--json]\n [--template vite|standalone|turborepo]\n [--components <folder>|none] [--import <specifier>]\n [--shadcn] [--preset <code>] [--base base|radix|aria]\n [--styles <file>|none] [--primitives]\n [--agent <ids>|none] [--dir
|
|
4
|
+
export declare const ROOT_HELP = "Dex\n\nUsage: dex <command> [options]\n dex <command> --help that command's options\n\nSet up and maintain\n create [folder] [--yes] [--dry-run] [--json]\n [--template vite|standalone|turborepo]\n [--components <folder>|none] [--import <specifier>]\n [--shadcn] [--preset <code>] [--base base|radix|aria]\n [--styles <file>|none] [--primitives]\n [--agent <ids>|none] [--dir dex] [--pm <manager>]\n [--provider <module>|none] [--design-md draft|none|<path>|<url>]\n [--app <name> | --in <package>]\n [--studio <spec>] [--skip-install]\n Set up a studio: in a project it adds its Dex folder,\n dex/, in a workspace its own app (--app) or inside an app\n (--in), in an empty folder a new project from a\n starter (--template). It confirms what it finds,\n shows the plan, then says what it does. Without a\n terminal, or with --yes, it takes what it finds;\n --dry-run only shows the plan\n agents add <agent> Add the studio to claude, codex, cursor, copilot or\n opencode, as the studio's \"Add MCP config\" does\n doctor [--json] Check the setup and say how to fix it; --json prints\n one JSON object per check\n components [--json] [--components <folder>]\n List the design system's components and how to\n import them; --components scans another folder and\n prints the config that points at it\n upgrade [--dry-run] Bring a studio set up by an older version up to date:\n rename studio.config.ts to dex.config.ts, move\n design-system/index.ts into it (its prose into\n DESIGN.md), move studio/ to the Dex folder, dex/,\n with its state (.local/) and the team's skills\n (skills/) in it, use the installed rules and delete\n old explorations/ folders. --dry-run says what would\n change and writes nothing\n\nRun\n dev [--live] Start the studio; --live also keeps it in step with\n the linked cloud workspace (see cloud live)\n stop Stop this checkout's studio, and no other\n build Check, then build a static site\n export --slug <file> [--frames <keys>] [--sections <ids>] [--kind <kind>] [--flows] [--out <folder>]\n Export frames as a prototype that opens by\n double-click, offline: a zip in Downloads. --kind is\n clickable, pages (a page per frame), content\n (editable content.js) or source\n preview Serve the built site\n extension Install the Chrome extension that copies elements from\n any page to paste on a canvas\n app install On a Mac, make ~/Applications/Dex.app: it starts\n the studio when it isn't running and opens it in its\n own window\n app remove Remove that app\n app start What that app runs when it opens: starts the studio\n unless this project's Dex already holds its port\n\nWork (usually run by your agent)\n whoami Who you are, from GitHub or git: added the first time\n new [--person <slug>] --title \"<title>\"\n contributor --name \"<name>\" --git \"<git user>\" --discipline <product|brand|engineering> [--github <username>]\n threads [--slug <file>] [--all]\n Comments and requests waiting for an agent\n thread --id <id> [--note \"<message, or what changed>\"] [--acknowledge | --resolve | --dismiss]\n Answer one\n check Validate files, canvases and references\n scope --person <slug>\n Changes outside that contributor's folders\n presence --slug <file> --view <view> [--agent <name>] [--clear]\n snapshot --slug <file> [--view <view>]\n\nCloud workspaces (Team)\n cloud login --token <token> [--url <service url>]\n cloud link --workspace <slug> [--url <service url>]\n Keep comments in the workspace, shared by the team\n cloud live [--workspace <slug>] [--url <service url>] [--token <token>]\n Work live with the team: this studio's files stay\n in step with the workspace, both ways, while it runs.\n Your own agents work on them as usual\n cloud status What this studio is linked to\n cloud push Copy comment threads into the workspace\n cloud publish Build and publish the studio; prints a share link\n cloud unlink\n\nAgents\n claude [...] Claude Code, with feedback from the studio arriving in\n the session as it is left (a channel; no watching)\n mcp [--agent \"<name>\"] The studio's MCP server (stdio): guidelines and feedback\n hook Claude Code hook: presence and guidelines\n";
|
|
5
5
|
/** `dex --help`, with its headings in bold in a terminal. */
|
|
6
6
|
export declare const rootHelp: () => string;
|
|
7
7
|
/** `dex <command> --help`: what it does, and its arguments and options. */
|
package/dist/cli/help.mjs
CHANGED
|
@@ -14,12 +14,12 @@ Set up and maintain
|
|
|
14
14
|
[--components <folder>|none] [--import <specifier>]
|
|
15
15
|
[--shadcn] [--preset <code>] [--base base|radix|aria]
|
|
16
16
|
[--styles <file>|none] [--primitives]
|
|
17
|
-
[--agent <ids>|none] [--dir
|
|
17
|
+
[--agent <ids>|none] [--dir dex] [--pm <manager>]
|
|
18
18
|
[--provider <module>|none] [--design-md draft|none|<path>|<url>]
|
|
19
19
|
[--app <name> | --in <package>]
|
|
20
20
|
[--studio <spec>] [--skip-install]
|
|
21
|
-
Set up a studio: in a project it adds
|
|
22
|
-
in a workspace its own app (--app) or inside an app
|
|
21
|
+
Set up a studio: in a project it adds its Dex folder,
|
|
22
|
+
dex/, in a workspace its own app (--app) or inside an app
|
|
23
23
|
(--in), in an empty folder a new project from a
|
|
24
24
|
starter (--template). It confirms what it finds,
|
|
25
25
|
shows the plan, then says what it does. Without a
|
|
@@ -36,16 +36,22 @@ Set up and maintain
|
|
|
36
36
|
upgrade [--dry-run] Bring a studio set up by an older version up to date:
|
|
37
37
|
rename studio.config.ts to dex.config.ts, move
|
|
38
38
|
design-system/index.ts into it (its prose into
|
|
39
|
-
DESIGN.md),
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
39
|
+
DESIGN.md), move studio/ to the Dex folder, dex/,
|
|
40
|
+
with its state (.local/) and the team's skills
|
|
41
|
+
(skills/) in it, use the installed rules and delete
|
|
42
|
+
old explorations/ folders. --dry-run says what would
|
|
43
|
+
change and writes nothing
|
|
43
44
|
|
|
44
45
|
Run
|
|
45
46
|
dev [--live] Start the studio; --live also keeps it in step with
|
|
46
47
|
the linked cloud workspace (see cloud live)
|
|
47
48
|
stop Stop this checkout's studio, and no other
|
|
48
49
|
build Check, then build a static site
|
|
50
|
+
export --slug <file> [--frames <keys>] [--sections <ids>] [--kind <kind>] [--flows] [--out <folder>]
|
|
51
|
+
Export frames as a prototype that opens by
|
|
52
|
+
double-click, offline: a zip in Downloads. --kind is
|
|
53
|
+
clickable, pages (a page per frame), content
|
|
54
|
+
(editable content.js) or source
|
|
49
55
|
preview Serve the built site
|
|
50
56
|
extension Install the Chrome extension that copies elements from
|
|
51
57
|
any page to paste on a canvas
|