wizards 0.7.0 → 0.7.1
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/apps/runtime/dist/cli/connect.js +6 -2
- package/apps/runtime/dist/cli/machine.js +7 -3
- package/apps/runtime/dist/cli/main.js +1 -1
- package/apps/runtime/dist/cli/menu.js +25 -6
- package/apps/runtime/dist/cli/setup.js +17 -22
- package/apps/runtime/dist/docs/user/command-line.md +1 -1
- package/apps/web/dist/assets/{AboutDialog-CUVmdhzk.js → AboutDialog-BJALish1.js} +1 -1
- package/apps/web/dist/assets/{ChangelogDialog-DcQqFbiW.js → ChangelogDialog-CxmHNvq1.js} +1 -1
- package/apps/web/dist/assets/{ChatView-DTPWjzWF.js → ChatView-C9ASPVJj.js} +1 -1
- package/apps/web/dist/assets/{EditorPage-SJHtft7P.js → EditorPage-BHhNEiKa.js} +1 -1
- package/apps/web/dist/assets/{Harness-D6fezoWO.js → Harness-Duq0wpfg.js} +1 -1
- package/apps/web/dist/assets/{NewWizardChannels-BHeutZ7V.js → NewWizardChannels-CGFy67jk.js} +1 -1
- package/apps/web/dist/assets/{NewWizardPage-CzBxaPhH.js → NewWizardPage-DwBcRWJj.js} +1 -1
- package/apps/web/dist/assets/{OnboardingPage-DbR4N2Ms.js → OnboardingPage-YwKzupPI.js} +1 -1
- package/apps/web/dist/assets/{ProjectPage-DG6_E7kA.js → ProjectPage-DP1xMjbe.js} +1 -1
- package/apps/web/dist/assets/{PublicRunner-19tV_8TR.js → PublicRunner-CECAuP0g.js} +1 -1
- package/apps/web/dist/assets/{ReadOnly-BMXFtKs0.js → ReadOnly-BnnGcLWU.js} +1 -1
- package/apps/web/dist/assets/{RunDrawer-DqwLjFJb.js → RunDrawer-C0vf8QAc.js} +1 -1
- package/apps/web/dist/assets/{RunnerView-DRc4J-rg.js → RunnerView-CBrZpjt5.js} +1 -1
- package/apps/web/dist/assets/{SettingsPage-CCypPS9L.js → SettingsPage-C0-mVcs5.js} +1 -1
- package/apps/web/dist/assets/{SetupPage-D2Y2rev4.js → SetupPage-BGlYQREU.js} +1 -1
- package/apps/web/dist/assets/{SharePage-DB5n6Oug.js → SharePage-IwxlV6WC.js} +1 -1
- package/apps/web/dist/assets/changelog-CPNPseoQ.js +1 -0
- package/apps/web/dist/assets/{index-mBRI7ZQp.js → index-DU-Onx-c.js} +3 -3
- package/apps/web/dist/index.html +1 -1
- package/apps/web/dist/install.sh +1 -1
- package/package.json +1 -1
- package/apps/web/dist/assets/changelog-BDhd7tjO.js +0 -1
|
@@ -4,7 +4,7 @@ import { homedir } from "node:os";
|
|
|
4
4
|
import { delimiter, dirname, join } from "node:path";
|
|
5
5
|
import { promisify } from "node:util";
|
|
6
6
|
import { installedByScript, packageRoot } from "./home.js";
|
|
7
|
-
import { findOnPath } from "./machine.js";
|
|
7
|
+
import { findOnPath, macAppPresent } from "./machine.js";
|
|
8
8
|
import { bad, cmd, dim, ok, tilde } from "./ui.js";
|
|
9
9
|
const run = promisify(execFile);
|
|
10
10
|
/**
|
|
@@ -225,7 +225,8 @@ function jsonApp(def) {
|
|
|
225
225
|
name: def.name,
|
|
226
226
|
widgets: def.widgets,
|
|
227
227
|
where: def.file,
|
|
228
|
-
installed: () => existsSync(def.marker)
|
|
228
|
+
installed: () => existsSync(def.marker) &&
|
|
229
|
+
(process.platform !== "darwin" || !def.macApp || macAppPresent(def.macApp)),
|
|
229
230
|
connected: async () => jsonHasServer(read(def.file) ?? "", def.at),
|
|
230
231
|
async connect(server) {
|
|
231
232
|
const busy = running();
|
|
@@ -423,6 +424,7 @@ export function apps(paths) {
|
|
|
423
424
|
widgets: true,
|
|
424
425
|
file: join(appSupport("Claude"), "claude_desktop_config.json"),
|
|
425
426
|
marker: appSupport("Claude"),
|
|
427
|
+
macApp: "Claude",
|
|
426
428
|
at: ["mcpServers"],
|
|
427
429
|
entry: stdioEntry,
|
|
428
430
|
ownsFileWhileRunning: () => processRunning(CLAUDE_DESKTOP_PROCESS),
|
|
@@ -444,6 +446,7 @@ export function apps(paths) {
|
|
|
444
446
|
widgets: true,
|
|
445
447
|
file: join(vscodeUser, "mcp.json"),
|
|
446
448
|
marker: vscodeUser,
|
|
449
|
+
macApp: "Visual Studio Code",
|
|
447
450
|
at: ["servers"],
|
|
448
451
|
entry: (server) => ({ type: "stdio", ...stdioEntry(server) }),
|
|
449
452
|
}),
|
|
@@ -453,6 +456,7 @@ export function apps(paths) {
|
|
|
453
456
|
widgets: false,
|
|
454
457
|
file: join(home, ".codeium", "windsurf", "mcp_config.json"),
|
|
455
458
|
marker: join(home, ".codeium", "windsurf"),
|
|
459
|
+
macApp: "Windsurf",
|
|
456
460
|
at: ["mcpServers"],
|
|
457
461
|
entry: stdioEntry,
|
|
458
462
|
}),
|
|
@@ -42,13 +42,17 @@ export const CLIENTS = [
|
|
|
42
42
|
app: "Cursor",
|
|
43
43
|
},
|
|
44
44
|
];
|
|
45
|
+
const APP_ROOTS = ["/Applications", join(homedir(), "Applications")];
|
|
46
|
+
/** Whether `<name>.app` is in one of the Mac's Applications folders. */
|
|
47
|
+
export function macAppPresent(name, roots = APP_ROOTS) {
|
|
48
|
+
return roots.some((root) => existsSync(join(root, `${name}.app`)));
|
|
49
|
+
}
|
|
45
50
|
/** The client's desktop app, when it is on this Mac: its name, e.g. "Claude". */
|
|
46
|
-
export function vendorApp(client, roots =
|
|
51
|
+
export function vendorApp(client, roots = APP_ROOTS) {
|
|
47
52
|
if (process.platform !== "darwin" || !client.app) {
|
|
48
53
|
return null;
|
|
49
54
|
}
|
|
50
|
-
|
|
51
|
-
return roots.some((root) => existsSync(join(root, `${app}.app`))) ? app : null;
|
|
55
|
+
return macAppPresent(client.app, roots) ? client.app : null;
|
|
52
56
|
}
|
|
53
57
|
/**
|
|
54
58
|
* The client the setup suggests among those not installed: the one whose app is on this Mac —
|
|
@@ -40,7 +40,7 @@ ${line(`${command()} restart`, "restart it, e.g. to switch to a newly installed
|
|
|
40
40
|
${line(`${command()} update`, "install the latest version")}
|
|
41
41
|
${line(`${command()} autoupdate`, "updates by themselves: add on or off (WIZARDS_DISABLE_AUTOUPDATE=1 is off too)")}
|
|
42
42
|
${more("(downloaded in the background, used from the next start; never during a run)")}
|
|
43
|
-
${line(`${command()} autostart`, "start it when you log in: add on or off")}
|
|
43
|
+
${line(`${command()} autostart`, "start it when you log in to this computer: add on or off")}
|
|
44
44
|
${more("(macOS: a LaunchAgent; Linux: a systemd user service)")}
|
|
45
45
|
${line(`${command()} connect`, "add your wizards to your AI apps: every app found, or the ones you name:")}
|
|
46
46
|
${more(apps(layout())
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
+
import { spawnSync } from "node:child_process";
|
|
2
|
+
import { join } from "node:path";
|
|
1
3
|
import * as p from "@clack/prompts";
|
|
2
4
|
import { updateStatus } from "../update.js";
|
|
3
5
|
import { accountMenu, accountState, describeAccount } from "./account.js";
|
|
4
6
|
import { autostartForStatus, setAutostart } from "./autostart.js";
|
|
5
7
|
import { connectCommand } from "./connect.js";
|
|
6
|
-
import { command, packageVersion, readInstallNote } from "./home.js";
|
|
8
|
+
import { command, packageRoot, packageVersion, readInstallNote } from "./home.js";
|
|
7
9
|
import { setup } from "./setup.js";
|
|
8
10
|
import { open, runningRuntime, settings, start } from "./start.js";
|
|
9
11
|
import { restart, status, stop } from "./status.js";
|
|
@@ -45,7 +47,7 @@ function choices({ running, atLogin, release, account }) {
|
|
|
45
47
|
]
|
|
46
48
|
: [
|
|
47
49
|
{ value: "start", label: "Start in the background", hint: "and open the studio" },
|
|
48
|
-
{ value: "foreground", label: "Start
|
|
50
|
+
{ value: "foreground", label: "Start in this terminal", hint: "Ctrl-C stops it" },
|
|
49
51
|
];
|
|
50
52
|
options.push({
|
|
51
53
|
value: "update",
|
|
@@ -62,14 +64,18 @@ function choices({ running, atLogin, release, account }) {
|
|
|
62
64
|
options.push({
|
|
63
65
|
value: "connect",
|
|
64
66
|
label: "Connect AI apps",
|
|
65
|
-
hint: "
|
|
67
|
+
hint: "add your wizards as an MCP server in Claude, Cursor, Codex…",
|
|
66
68
|
}, {
|
|
67
69
|
value: "account",
|
|
68
70
|
label: "Account",
|
|
69
71
|
hint: account.kind === "linked"
|
|
70
72
|
? `signed in as ${describeAccount(account)}`
|
|
71
73
|
: describeAccount(account),
|
|
72
|
-
}, { value: "status", label: "Status", hint: "what’s installed, and any problems" }, { value: "setup", label: "Setup", hint: "account, AI client, ffmpeg, start at login" }, {
|
|
74
|
+
}, { value: "status", label: "Status", hint: "what’s installed, and any problems" }, { value: "setup", label: "Setup", hint: "account, AI client, ffmpeg, start at login" }, {
|
|
75
|
+
value: "uninstall",
|
|
76
|
+
label: "Uninstall",
|
|
77
|
+
hint: "remove it from this computer; asks about your data first",
|
|
78
|
+
}, { value: "help", label: "Help", hint: "every command" }, { value: "quit", label: "Quit", hint: running ? "engenty wizards keeps running" : undefined });
|
|
73
79
|
return options;
|
|
74
80
|
}
|
|
75
81
|
/** Whether it starts at login. Esc goes back to the menu. */
|
|
@@ -81,7 +87,11 @@ async function serviceSettings(paths, atLogin) {
|
|
|
81
87
|
message: "Start at login?",
|
|
82
88
|
initialValue: atLogin.on,
|
|
83
89
|
options: [
|
|
84
|
-
{
|
|
90
|
+
{
|
|
91
|
+
value: true,
|
|
92
|
+
label: "Yes",
|
|
93
|
+
hint: "runs in the background whenever you log in to this computer",
|
|
94
|
+
},
|
|
85
95
|
{ value: false, label: "No", hint: "only when you start it" },
|
|
86
96
|
],
|
|
87
97
|
});
|
|
@@ -112,7 +122,7 @@ function commands() {
|
|
|
112
122
|
}
|
|
113
123
|
/**
|
|
114
124
|
* `wizards` on a terminal: what runs, and a menu of what the commands do. The first time, the
|
|
115
|
-
* setup runs first. Returns the exit code; "Start
|
|
125
|
+
* setup runs first. Returns the exit code; "Start in this terminal" ends it with the runtime in the
|
|
116
126
|
* foreground.
|
|
117
127
|
*/
|
|
118
128
|
export async function menu(paths, setupOptions, help) {
|
|
@@ -175,6 +185,15 @@ export async function menu(paths, setupOptions, help) {
|
|
|
175
185
|
case "setup":
|
|
176
186
|
await setup(paths, setupOptions);
|
|
177
187
|
break;
|
|
188
|
+
case "uninstall": {
|
|
189
|
+
// Its own process, as `wizards uninstall` is: this one's modules write to the install.
|
|
190
|
+
const { status: code } = spawnSync(process.execPath, [join(packageRoot, "bin", "wizards.mjs"), "uninstall"], { stdio: "inherit" });
|
|
191
|
+
// 130: the person said no, so the menu goes on.
|
|
192
|
+
if (code !== 130) {
|
|
193
|
+
return code ?? 1;
|
|
194
|
+
}
|
|
195
|
+
break;
|
|
196
|
+
}
|
|
178
197
|
case "help":
|
|
179
198
|
console.log(help);
|
|
180
199
|
break;
|
|
@@ -41,17 +41,16 @@ async function clientsStep(paths, options, interactive) {
|
|
|
41
41
|
? `Found AI clients: ${installed.map((s) => `${s.client.name} ${s.version}`).join(", ")}.`
|
|
42
42
|
: "No AI client on this computer yet.");
|
|
43
43
|
if (!installed.length) {
|
|
44
|
-
p.log.message(dim("engenty wizards
|
|
44
|
+
p.log.message(dim("engenty wizards runs its AI through an AI client, like Claude Code or Codex, on a subscription you already have."));
|
|
45
45
|
}
|
|
46
46
|
let wanted = missing.filter((s) => options.clients.includes(s.client.id));
|
|
47
|
-
|
|
47
|
+
// With a client already here, setup asks nothing more; another one is a `--client` away.
|
|
48
|
+
if (interactive && !installed.length && missing.length && !wanted.length) {
|
|
48
49
|
const suggested = suggestedClient(missing);
|
|
49
50
|
// A client whose app is on this Mac comes first: its subscription is most likely paid for.
|
|
50
51
|
const offered = [...missing].sort((a, b) => Number(!vendorApp(a.client)) - Number(!vendorApp(b.client)));
|
|
51
52
|
const answer = await p.multiselect({
|
|
52
|
-
message: installed
|
|
53
|
-
? "Install another AI client? (space to choose, enter to continue)"
|
|
54
|
-
: "Which AI client should be installed?",
|
|
53
|
+
message: "Which AI client should be installed? (space to choose, enter to continue)",
|
|
55
54
|
options: offered.map(({ client }) => {
|
|
56
55
|
const app = vendorApp(client);
|
|
57
56
|
return {
|
|
@@ -60,13 +59,13 @@ async function clientsStep(paths, options, interactive) {
|
|
|
60
59
|
hint: [
|
|
61
60
|
`${client.account} subscription`,
|
|
62
61
|
app ? `the ${app} app is on this Mac` : "",
|
|
63
|
-
|
|
62
|
+
client.id === suggested?.client.id ? "recommended" : "",
|
|
64
63
|
]
|
|
65
64
|
.filter(Boolean)
|
|
66
65
|
.join(", "),
|
|
67
66
|
};
|
|
68
67
|
}),
|
|
69
|
-
initialValues:
|
|
68
|
+
initialValues: suggested ? [suggested.client.id] : [],
|
|
70
69
|
required: false,
|
|
71
70
|
});
|
|
72
71
|
if (cancelled(answer)) {
|
|
@@ -89,7 +88,7 @@ async function clientsStep(paths, options, interactive) {
|
|
|
89
88
|
async function toolsStep(interactive) {
|
|
90
89
|
const chrome = findChrome();
|
|
91
90
|
if (chrome) {
|
|
92
|
-
p.log.success(`Browser for PDF and PNG: ${dim(tilde(chrome))}`);
|
|
91
|
+
p.log.success(`Browser for PDF and PNG exports: ${dim(tilde(chrome))}`);
|
|
93
92
|
}
|
|
94
93
|
else {
|
|
95
94
|
p.log.warn("No Chrome, Edge or Chromium found. PDF and PNG exports and browser steps need one.\nhttps://www.google.com/chrome");
|
|
@@ -134,15 +133,15 @@ async function autostartStep(paths, interactive) {
|
|
|
134
133
|
return;
|
|
135
134
|
}
|
|
136
135
|
if (state.on) {
|
|
137
|
-
p.log.success(`Starts
|
|
136
|
+
p.log.success(`Starts when you log in to this computer: ${dim(state.how)}`);
|
|
138
137
|
return;
|
|
139
138
|
}
|
|
140
139
|
if (!interactive) {
|
|
141
|
-
p.log.info(dim(`To start it when you log in: ${cmd("autostart on")}`));
|
|
140
|
+
p.log.info(dim(`To start it when you log in to this computer: ${cmd("autostart on")}`));
|
|
142
141
|
return;
|
|
143
142
|
}
|
|
144
143
|
const answer = await p.confirm({
|
|
145
|
-
message: "Start engenty wizards when you log in? It
|
|
144
|
+
message: "Start engenty wizards when you log in to this computer? It runs as a background process, without a terminal window, so links and your AI apps can always reach it.",
|
|
146
145
|
initialValue: true,
|
|
147
146
|
});
|
|
148
147
|
if (cancelled(answer)) {
|
|
@@ -155,14 +154,14 @@ async function autostartStep(paths, interactive) {
|
|
|
155
154
|
try {
|
|
156
155
|
const after = await setAutostart(paths, true);
|
|
157
156
|
if ("on" in after && after.on) {
|
|
158
|
-
p.log.success(`Starts
|
|
157
|
+
p.log.success(`Starts when you log in to this computer: ${dim(after.how)}`);
|
|
159
158
|
}
|
|
160
159
|
else {
|
|
161
|
-
p.log.warn("Couldn’t
|
|
160
|
+
p.log.warn("Couldn’t set it to start when you log in.");
|
|
162
161
|
}
|
|
163
162
|
}
|
|
164
163
|
catch (error) {
|
|
165
|
-
p.log.warn(`Couldn’t
|
|
164
|
+
p.log.warn(`Couldn’t set it to start when you log in. ${error.message}`);
|
|
166
165
|
}
|
|
167
166
|
}
|
|
168
167
|
/**
|
|
@@ -174,7 +173,7 @@ async function appsStep(paths, interactive) {
|
|
|
174
173
|
const connected = states.filter((s) => s.connected);
|
|
175
174
|
const offered = states.filter((s) => s.installed && !s.connected);
|
|
176
175
|
if (connected.length) {
|
|
177
|
-
p.log.success(`
|
|
176
|
+
p.log.success(`Already in your AI apps: ${connected.map((s) => s.name).join(", ")}`);
|
|
178
177
|
}
|
|
179
178
|
if (!offered.length) {
|
|
180
179
|
return;
|
|
@@ -184,12 +183,8 @@ async function appsStep(paths, interactive) {
|
|
|
184
183
|
return;
|
|
185
184
|
}
|
|
186
185
|
const answer = await p.multiselect({
|
|
187
|
-
message: "
|
|
188
|
-
options: offered.map((s) => ({
|
|
189
|
-
value: s.id,
|
|
190
|
-
label: s.name,
|
|
191
|
-
hint: s.widgets ? "shows runs as a widget" : "shows runs as text",
|
|
192
|
-
})),
|
|
186
|
+
message: "Add your wizards to these AI apps, as an MCP server in each app’s settings? (space to choose, enter to continue)",
|
|
187
|
+
options: offered.map((s) => ({ value: s.id, label: s.name })),
|
|
193
188
|
initialValues: offered.map((s) => s.id),
|
|
194
189
|
required: false,
|
|
195
190
|
});
|
|
@@ -271,7 +266,7 @@ async function howToUse(paths) {
|
|
|
271
266
|
: "engenty wizards isn’t running yet.",
|
|
272
267
|
"unavailable" in atLogin || !atLogin.on
|
|
273
268
|
? ""
|
|
274
|
-
: dim("It starts automatically when you log in."),
|
|
269
|
+
: dim("It starts automatically when you log in to this computer."),
|
|
275
270
|
]
|
|
276
271
|
.filter(Boolean)
|
|
277
272
|
.join("\n"));
|
|
@@ -8,7 +8,7 @@ version: 0.5.0
|
|
|
8
8
|
|
|
9
9
|
| Command | What it does |
|
|
10
10
|
|---|---|
|
|
11
|
-
| `wizards` | Shows what is running, and a menu. While it runs, you can open the studio, restart or stop it; while it doesn’t, “Start in the background” or “Start
|
|
11
|
+
| `wizards` | Shows what is running, and a menu. While it runs, you can open the studio, restart or stop it; while it doesn’t, “Start in the background” or “Start in this terminal”. Then “Update”, which restarts it into the new version, “Start at login”, “Connect AI apps”, “Account”, “Status”, “Setup”, “Uninstall” and “Help”. The first time, the setup runs first. It needs a terminal |
|
|
12
12
|
| `wizards start` | Starts it and opens the studio. It runs in that terminal, and Ctrl-C stops it. The first time, the setup runs first |
|
|
13
13
|
| `wizards studio` | Opens the studio in your browser. If it isn’t running, it starts in the background first |
|
|
14
14
|
| `wizards setup` | Runs the guided setup again: your account, an AI client, the browser and ffmpeg, start at login, your AI apps. `--local` leaves the account out ([Local only](./local-only.md)) |
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t,t as n}from"./jsx-runtime-BNakU3Ej.js";import{$t as r,Ft as i,Hn as a,It as o,Kt as s,Nt as c,Pt as l,Vt as u,Wt as d,fr as f,vr as p}from"./ui-Brg2qM1A.js";import{t as m}from"./preload-helper-CNEI7N0N.js";import{G as h,U as g,W as _,xt as v}from"./index-
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t,t as n}from"./jsx-runtime-BNakU3Ej.js";import{$t as r,Ft as i,Hn as a,It as o,Kt as s,Nt as c,Pt as l,Vt as u,Wt as d,fr as f,vr as p}from"./ui-Brg2qM1A.js";import{t as m}from"./preload-helper-CNEI7N0N.js";import{G as h,U as g,W as _,xt as v}from"./index-DU-Onx-c.js";import{c as y,f as b}from"./settings-menu-BMMkIVP1.js";import{ReleaseNotes as x,loadReleases as S,releaseDate as C,releaseLabel as w}from"./ChangelogDialog-CxmHNvq1.js";var T=e(t(),1),E=[{name:`engenty wizards`,description:`credit.engenty-wizards`,homepage:`https://github.com/engenty/wizards`,license:`FSL-1.1-MIT`},{name:`engenty`,description:`credit.engenty`,homepage:`https://github.com/engenty/engenty`,license:`FSL-1.1-MIT`}],D=[{name:`Mastra`,description:`credit.mastra`,homepage:`https://github.com/mastra-ai/mastra`,license:`Apache-2.0`},{name:`AI SDK`,description:`credit.ai-sdk`,homepage:`https://github.com/vercel/ai`,license:`Apache-2.0`},{name:`Model Context Protocol`,description:`credit.model-context-protocol`,homepage:`https://github.com/modelcontextprotocol/typescript-sdk`,license:`MIT`},{name:`Hono`,description:`credit.hono`,homepage:`https://github.com/honojs/hono`,license:`MIT`},{name:`Drizzle ORM`,description:`credit.drizzle-orm`,homepage:`https://github.com/drizzle-team/drizzle-orm`,license:`Apache-2.0`},{name:`libSQL`,description:`credit.libsql`,homepage:`https://github.com/tursodatabase/libsql`,license:`MIT`},{name:`Playwright`,description:`credit.playwright`,homepage:`https://github.com/microsoft/playwright`,license:`Apache-2.0`},{name:`React`,description:`credit.react`,homepage:`https://github.com/facebook/react`,license:`MIT`},{name:`Vite`,description:`credit.vite`,homepage:`https://github.com/vitejs/vite`,license:`MIT`},{name:`Tailwind CSS`,description:`credit.tailwind-css`,homepage:`https://github.com/tailwindlabs/tailwindcss`,license:`MIT`},{name:`React Flow`,description:`credit.react-flow`,homepage:`https://github.com/xyflow/xyflow`,license:`MIT`},{name:`TanStack Query`,description:`credit.tanstack-query`,homepage:`https://github.com/TanStack/query`,license:`MIT`},{name:`xterm.js`,description:`credit.xterm-js`,homepage:`https://github.com/xtermjs/xterm.js`,license:`MIT`},{name:`Lucide`,description:`credit.lucide`,homepage:`https://github.com/lucide-icons/lucide`,license:`ISC`},{name:`Geist & Geist Mono`,description:`credit.geist-geist-mono`,homepage:`https://github.com/vercel/geist-font`,license:`OFL-1.1`},{name:`Space Grotesk`,description:`credit.space-grotesk`,homepage:`https://github.com/floriankarsten/space-grotesk`,license:`OFL-1.1`},{name:`git-cliff`,description:`credit.git-cliff`,homepage:`https://github.com/orhun/git-cliff`,license:`MIT OR Apache-2.0`}],O=e(n(),1),k=(e,...t)=>t.some(t=>t?.toLowerCase().includes(e));function A({name:e,homepage:t,version:n,license:r,description:i}){return(0,O.jsxs)(`li`,{className:`py-2.5`,children:[(0,O.jsxs)(`div`,{className:`flex flex-wrap items-baseline gap-x-2.5 gap-y-0.5`,children:[t?(0,O.jsxs)(`a`,{href:t,target:`_blank`,rel:`noreferrer`,className:`inline-flex items-center gap-1 font-medium text-[0.875rem] text-ink underline-offset-4 hover:underline`,children:[e,(0,O.jsx)(f,{"aria-hidden":!0,className:`size-3 text-ink-4`})]}):(0,O.jsx)(`span`,{className:`font-medium text-[0.875rem] text-ink`,children:e}),n?(0,O.jsx)(`span`,{className:`text-[0.75rem] text-ink-3 tabular-nums`,children:n}):null,(0,O.jsx)(`span`,{className:`text-[0.75rem] text-ink-3`,children:r})]}),i?(0,O.jsx)(`p`,{className:`mt-0.5 text-[0.8125rem] text-ink-3`,children:i}):null]})}function j({title:e,hint:t,children:n}){return(0,O.jsxs)(`section`,{className:`mt-6`,children:[(0,O.jsx)(`h3`,{className:`border-border-soft border-b pb-2 font-display font-semibold text-[1rem]`,children:e}),t?(0,O.jsx)(`p`,{className:`mt-2 text-[0.8125rem] text-ink-3`,children:t}):null,n]})}function M({credits:e}){return(0,O.jsx)(`ul`,{className:`divide-y divide-border-soft`,children:e.map(e=>(0,O.jsx)(A,{name:e.name,homepage:e.homepage,license:e.license,description:r(e.description)},e.name))})}function N({label:e,packages:t}){return(0,O.jsxs)(`div`,{className:`mt-4`,children:[(0,O.jsx)(`h4`,{className:`font-medium text-[0.75rem] text-ink-3 tracking-wide`,children:e}),(0,O.jsx)(`ul`,{className:`divide-y divide-border-soft`,children:t.map(e=>(0,O.jsx)(A,{...e},e.name))})]})}function P({active:e}){let[t,n]=(0,T.useState)(null),[i,a]=(0,T.useState)(``);(0,T.useEffect)(()=>{if(!e||t)return;let r=!1;return m(()=>import(`./oss-credits-BJrR7BR1.js`).then(e=>{r||n(e.default)}),[]),()=>{r=!0}},[e,t]),(0,T.useEffect)(()=>{e||a(``)},[e]);let s=i.trim().toLowerCase(),c=e=>s?e.filter(e=>k(s,e.name,e.license,r(e.description))):e,d=e=>s?e.filter(e=>k(s,e.name,e.license,e.version)):e,f=c(E),p=c(D),h=t?[{id:`shared`,label:r(`about.creditsShared`),packages:d(t.shared)},...t.groups.map(e=>({id:e.id,label:e.label,packages:d(e.packages)}))].filter(e=>e.packages.length>0):[],g=f.length===0&&p.length===0&&h.length===0;return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)(`p`,{className:`mb-4 text-[0.875rem] text-ink-3`,children:r(`about.creditsHint`)}),(0,O.jsx)(o,{type:`search`,value:i,placeholder:r(`about.search`),onChange:e=>a(e.target.value)}),f.length>0?(0,O.jsx)(j,{title:r(`about.creditsProduct`),children:(0,O.jsx)(M,{credits:f})}):null,p.length>0?(0,O.jsx)(j,{title:r(`about.creditsBuiltWith`),children:(0,O.jsx)(M,{credits:p})}):null,t===null?(0,O.jsx)(`div`,{className:`flex justify-center py-10 text-ink-3`,children:(0,O.jsx)(u,{})}):h.length>0?(0,O.jsx)(j,{title:r(`about.creditsDeps`),hint:s?void 0:r(`about.creditsDepsHint`),children:h.map(e=>(0,O.jsx)(N,{label:e.label,packages:e.packages},e.id))}):null,t!==null&&g?(0,O.jsx)(l,{children:r(`about.noMatches`)}):null]})}var F=[`new`,`earlier`,`credits`],I=e=>r(e===`new`?`about.tab.new`:e===`earlier`?`about.tab.earlier`:`about.credits`),L=e=>e===1?r(`about.change`):r(`about.changes`,{n:e});function R({open:e,onClose:t,me:n}){let o=n?.mode===`local`,{data:l,latest:f}=h(o&&e),[m,E]=(0,T.useState)(null),[D,k]=(0,T.useState)(`new`),A=b(F.indexOf(D)),j=l?.newer&&f?f:_;(0,T.useEffect)(()=>{if(!e)return;let t=!1;return E(null),S(j===`0.7.1`?void 0:j).then(e=>{t||E(e)}),()=>{t=!0}},[e,j]);let M=m?.find(e=>e.version===`v${j}`)??m?.[0]??null,N=m?.filter(e=>e!==M)??[],R=o?l?.kind??null:`cloud`;return(0,O.jsxs)(c,{open:e,onClose:t,wide:!0,height:`tall`,children:[(0,O.jsx)(`div`,{className:`-mt-2 -mr-2 sticky top-0 z-10 flex h-0 justify-end`,children:(0,O.jsx)(i,{label:r(`common.close`),onClick:t,children:(0,O.jsx)(a,{className:`size-4`})})}),(0,O.jsxs)(`div`,{className:`flex flex-col items-center pt-4 text-center`,children:[(0,O.jsx)(v,{size:96}),(0,O.jsxs)(`div`,{className:`mt-4 font-display font-semibold text-[1.5rem] tracking-tight`,children:[`engenty`,(0,O.jsx)(`span`,{className:`text-ember`,children:`.`}),(0,O.jsx)(`span`,{className:`ml-1.5 font-normal text-ink-3`,children:`wizards`})]}),(0,O.jsxs)(`div`,{className:`mt-1 text-[0.9375rem] text-ink-3 tabular-nums`,children:[r(`about.version`,{v:_}),R?` · ${r(`about.kind.${R}`)}`:``]})]}),o?(0,O.jsx)(`div`,{className:`mt-5`,children:(0,O.jsx)(g,{enabled:e})}):null,(0,O.jsx)(`div`,{className:`mt-6 flex justify-center`,children:(0,O.jsx)(d,{value:D,onChange:k,options:F.map(e=>({id:e,label:I(e)})),label:r(`about.title`)})}),(0,O.jsxs)(`div`,{className:s(`mt-5`,y(A)),children:[D===`new`?m===null?(0,O.jsx)(`div`,{className:`flex justify-center py-6 text-ink-3`,children:(0,O.jsx)(u,{})}):M?(0,O.jsxs)(O.Fragment,{children:[(0,O.jsxs)(`h3`,{className:`flex items-baseline gap-3 border-border-soft border-b pb-2 font-display font-semibold text-[1rem]`,children:[w(M),(0,O.jsx)(`span`,{className:`font-normal font-sans text-[0.8125rem] text-ink-3 tabular-nums`,children:C(M)})]}),(0,O.jsx)(`div`,{className:`mt-3`,children:(0,O.jsx)(x,{release:M})})]}):(0,O.jsx)(`p`,{className:`text-[0.875rem] text-ink-3`,children:r(`about.changelogEmpty`)}):null,D===`earlier`?(0,O.jsx)(`div`,{className:`flex flex-col divide-y divide-border-soft`,children:N.map(e=>(0,O.jsxs)(`details`,{className:`group/r py-2`,children:[(0,O.jsxs)(`summary`,{className:`flex cursor-pointer list-none items-baseline gap-3 text-[0.875rem] [&::-webkit-details-marker]:hidden`,children:[(0,O.jsx)(p,{className:`size-3.5 shrink-0 self-center text-ink-4 transition group-open/r:rotate-90`}),(0,O.jsx)(`span`,{className:`font-medium text-ink tabular-nums`,children:w(e)}),(0,O.jsx)(`span`,{className:`text-[0.8125rem] text-ink-3 tabular-nums`,children:C(e)}),(0,O.jsx)(`span`,{className:`ml-auto text-[0.8125rem] text-ink-4`,children:L(e.commits.length)})]}),(0,O.jsx)(`div`,{className:`mt-2 pl-6`,children:(0,O.jsx)(x,{release:e})})]},e.version??`unreleased`))}):null,D===`credits`?(0,O.jsx)(P,{active:!0}):null]},D)]})}export{R as AboutDialog};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t,t as n}from"./jsx-runtime-BNakU3Ej.js";import{$t as r,It as i,Kt as a,Nt as o,Pt as s,Vt as c}from"./ui-Brg2qM1A.js";import{t as l}from"./preload-helper-CNEI7N0N.js";var u=e(t(),1),d=e(n(),1);function f(e){switch(e.group){case`Added`:return{label:`NEW`,dot:`bg-moss`};case`Fixed`:return{label:`FIXED`,dot:`bg-amber`};case`Changed`:return{label:`CHANGED`,dot:`bg-cobalt`};case`Performance`:return{label:`PERFORMANCE`,dot:`bg-ember`};case`Deploy`:return{label:`DEPLOY`,dot:`bg-ink-4`};case`Docs`:return{label:`DOCS`,dot:`bg-ink-4`};default:return{label:`OTHER`,dot:`bg-ink-4`}}}var p=e=>e.version?e.version.replace(/^v/,``):r(`about.unreleased`),m=e=>e.timestamp?new Date(e.timestamp*1e3).toISOString().slice(0,10):``,h=e=>e.charAt(0).toUpperCase()+e.slice(1);function g(e,t){let n=t.trim().toLowerCase();if(!n)return e;let r=[];for(let t of e){if(`${p(t)} ${m(t)}`.toLowerCase().includes(n)){r.push(t);continue}let e=t.commits.filter(e=>`${f(e).label} ${e.scope??``} ${e.message}`.toLowerCase().includes(n));e.length>0&&r.push({...t,commits:e})}return r}async function _(e){if(e)try{let t=await fetch(`https://raw.githubusercontent.com/engenty/engenty-wizards/v${e}/apps/web/src/about/changelog.json`,{signal:AbortSignal.timeout(5e3)});if(t.ok)return await t.json()}catch{}return(await l(async()=>{let{default:e}=await import(`./changelog-
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t,t as n}from"./jsx-runtime-BNakU3Ej.js";import{$t as r,It as i,Kt as a,Nt as o,Pt as s,Vt as c}from"./ui-Brg2qM1A.js";import{t as l}from"./preload-helper-CNEI7N0N.js";var u=e(t(),1),d=e(n(),1);function f(e){switch(e.group){case`Added`:return{label:`NEW`,dot:`bg-moss`};case`Fixed`:return{label:`FIXED`,dot:`bg-amber`};case`Changed`:return{label:`CHANGED`,dot:`bg-cobalt`};case`Performance`:return{label:`PERFORMANCE`,dot:`bg-ember`};case`Deploy`:return{label:`DEPLOY`,dot:`bg-ink-4`};case`Docs`:return{label:`DOCS`,dot:`bg-ink-4`};default:return{label:`OTHER`,dot:`bg-ink-4`}}}var p=e=>e.version?e.version.replace(/^v/,``):r(`about.unreleased`),m=e=>e.timestamp?new Date(e.timestamp*1e3).toISOString().slice(0,10):``,h=e=>e.charAt(0).toUpperCase()+e.slice(1);function g(e,t){let n=t.trim().toLowerCase();if(!n)return e;let r=[];for(let t of e){if(`${p(t)} ${m(t)}`.toLowerCase().includes(n)){r.push(t);continue}let e=t.commits.filter(e=>`${f(e).label} ${e.scope??``} ${e.message}`.toLowerCase().includes(n));e.length>0&&r.push({...t,commits:e})}return r}async function _(e){if(e)try{let t=await fetch(`https://raw.githubusercontent.com/engenty/engenty-wizards/v${e}/apps/web/src/about/changelog.json`,{signal:AbortSignal.timeout(5e3)});if(t.ok)return await t.json()}catch{}return(await l(async()=>{let{default:e}=await import(`./changelog-CPNPseoQ.js`);return{default:e}},[])).default}function v({release:e}){return(0,d.jsx)(`ul`,{className:`flex flex-col gap-2`,children:e.commits.map(e=>{let t=f(e);return(0,d.jsxs)(`li`,{className:`flex items-start gap-2.5 text-[0.875rem]`,children:[(0,d.jsx)(`span`,{className:a(`mt-[7px] size-1.5 shrink-0 rounded-full`,t.dot)}),(0,d.jsxs)(`span`,{className:`min-w-0 text-ink-2`,children:[(0,d.jsxs)(`span`,{className:`font-semibold text-[0.75rem] text-ink tracking-wide`,children:[t.label,e.scope?` [${e.scope}]`:``]}),` `,h(e.message),e.breaking?(0,d.jsx)(`span`,{className:`ml-1.5 rounded-full bg-rose-tint px-1.5 py-0.5 font-medium text-[0.75rem] text-rose`,children:r(`about.breaking`)}):null]})]},e.id)})})}function y({open:e,onClose:t,version:n}){let[a,l]=(0,u.useState)(null),[f,h]=(0,u.useState)(``);(0,u.useEffect)(()=>{if(!e||a)return;let t=!1;return _(n).then(e=>{t||l(e)}),()=>{t=!0}},[e,a,n]),(0,u.useEffect)(()=>{e||h(``)},[e]);let y=a?g(a,f):[];return(0,d.jsxs)(o,{open:e,onClose:t,title:r(`about.changelog`),wide:!0,height:`tall`,children:[(0,d.jsx)(`p`,{className:`-mt-3 mb-4 text-[0.875rem] text-ink-3`,children:r(`about.changelogHint`)}),a===null?(0,d.jsx)(`div`,{className:`flex justify-center py-10 text-ink-3`,children:(0,d.jsx)(c,{})}):a.length===0?(0,d.jsx)(s,{children:r(`about.changelogEmpty`)}):(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(i,{type:`search`,value:f,placeholder:r(`about.search`),onChange:e=>h(e.target.value)}),y.length===0?(0,d.jsx)(s,{children:r(`about.noMatches`)}):null,y.map(e=>(0,d.jsxs)(`section`,{className:`mt-6`,children:[(0,d.jsxs)(`h3`,{className:`flex items-baseline gap-3 border-border-soft border-b pb-2 font-display font-semibold text-[1rem]`,children:[p(e),(0,d.jsx)(`span`,{className:`font-normal font-sans text-[0.8125rem] text-ink-3 tabular-nums`,children:m(e)})]}),(0,d.jsx)(`div`,{className:`mt-3`,children:(0,d.jsx)(v,{release:e})})]},e.version??`unreleased`))]})]})}export{y as ChangelogDialog,v as ReleaseNotes,_ as loadReleases,m as releaseDate,p as releaseLabel};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t,t as n}from"./jsx-runtime-BNakU3Ej.js";import{$ as r,$t as i,Fn as a,Ft as o,Gn as s,Gt as c,Jt as l,Kn as u,Kt as d,Or as f,Rt as p,Tn as m,Un as h,Vn as g,Vt as _,W as v,Xn as y,ar as b,bt as x,dt as S,er as C,ft as w,lt as T,m as E,mt as D,nn as O,nt as k,pt as A,qn as j,qt as M,rr as N,rt as P,st as F,tt as I,un as L,ut as ee,vt as R,wr as z,xr as B,xt as te,yt as ne,zr as re}from"./ui-Brg2qM1A.js";import{t as ie}from"./phone-DsxbIcWi.js";import{$ as ae,Ct as oe,Ft as se,Mt as ce,Q as le,Z as ue,gt as de,t as fe}from"./index-
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{n as t,t as n}from"./jsx-runtime-BNakU3Ej.js";import{$ as r,$t as i,Fn as a,Ft as o,Gn as s,Gt as c,Jt as l,Kn as u,Kt as d,Or as f,Rt as p,Tn as m,Un as h,Vn as g,Vt as _,W as v,Xn as y,ar as b,bt as x,dt as S,er as C,ft as w,lt as T,m as E,mt as D,nn as O,nt as k,pt as A,qn as j,qt as M,rr as N,rt as P,st as F,tt as I,un as L,ut as ee,vt as R,wr as z,xr as B,xt as te,yt as ne,zr as re}from"./ui-Brg2qM1A.js";import{t as ie}from"./phone-DsxbIcWi.js";import{$ as ae,Ct as oe,Ft as se,Mt as ce,Q as le,Z as ue,gt as de,t as fe}from"./index-DU-Onx-c.js";import{n as pe}from"./RunnerView-CBrZpjt5.js";var me={name:`hand`,size:24,node:[[`path`,{d:`M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2`,key:`1fvzgz`}],[`path`,{d:`M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2`,key:`1kc0my`}],[`path`,{d:`M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8`,key:`10h0bg`}],[`path`,{d:`M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15`,key:`1s1gnw`}]]};me.node;var he=f(me),ge={name:`undo-2`,size:24,node:[[`path`,{d:`M9 14 4 9l5-5`,key:`102s5s`}],[`path`,{d:`M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11`,key:`f3b9sd`}]]};ge.node;var _e=f(ge),ve={name:`video-off`,size:24,node:[[`path`,{d:`M10.66 6H14a2 2 0 0 1 2 2v2.5l5.248-3.062A.5.5 0 0 1 22 7.87v8.196`,key:`w8jjjt`}],[`path`,{d:`M16 16a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h2`,key:`1xawa7`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]};ve.node;var V=f(ve),ye={name:`volume-x`,size:24,node:[[`path`,{d:`M11 4.702a.7.7 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.7.7 0 0 0 11 19.298z`,key:`1p7khw`}],[`path`,{d:`m16.5 14.5 5-5`,key:`cul3yw`}],[`path`,{d:`m16.5 9.5 5 5`,key:`1akey5`}]]};ye.node;var be=f(ye),xe=re(),H=e(t(),1),U=e(n(),1),Se=typeof window<`u`&&window.matchMedia(`(pointer: coarse)`).matches;function Ce({since:e}){let[t,n]=(0,H.useState)(Date.now());if((0,H.useEffect)(()=>{if(!e)return;let t=setInterval(()=>n(Date.now()),1e3);return()=>clearInterval(t)},[e]),!e)return null;let r=Math.max(0,Math.floor((t-e)/1e3)),i=String(Math.floor(r/60)).padStart(2,`0`),a=String(r%60).padStart(2,`0`);return(0,U.jsxs)(`span`,{className:`font-mono text-[0.8125rem] text-white/60 tabular-nums`,children:[i,`:`,a]})}function W({label:e,on:t,danger:n,busy:r,onClick:i,children:a}){return(0,U.jsx)(`button`,{type:`button`,"aria-label":e,title:e,"aria-pressed":t,disabled:r,onClick:i,className:d(`flex size-12 items-center justify-center rounded-full transition disabled:opacity-50`,n?`bg-rose text-white hover:brightness-110`:t===!1?`bg-white text-neutral-900 hover:bg-white/90`:`bg-white/15 text-white hover:bg-white/25`),children:r?(0,U.jsx)(_,{className:`size-5`}):a})}function we({voice:e}){let t=(0,H.useRef)(null),{captions:n}=e;return(0,H.useEffect)(()=>{n.length&&t.current?.scrollIntoView({block:`end`})},[n]),n.length?(0,U.jsx)(`div`,{className:`min-h-0 flex-1 overflow-y-auto px-4 sm:px-5`,children:(0,U.jsxs)(`ol`,{className:`mx-auto flex max-w-[720px] flex-col gap-2 py-2`,children:[n.map(e=>(0,U.jsx)(`li`,{className:d(`text-[0.9375rem] leading-snug`,e.who===`bot`?`text-white/95`:`text-right text-white/50`),children:e.text},e.id)),(0,U.jsx)(`div`,{ref:t})]})}):null}function Te({voice:e,view:t,video:n,className:r}){let a=e.state===`live`,o=e.state===`connecting`,[c,l]=(0,H.useState)(null),[u,f]=(0,H.useState)(!1);(0,H.useEffect)(()=>{l(a?Date.now():null)},[a]);let p=async()=>{f(!1),await e.start(),n&&await e.startCamera()},m=()=>{e.stop(),f(!0)},g=n||e.camera,v=[...e.captions].reverse().find(e=>e.who===`bot`),y=[...e.captions].reverse().find(e=>e.who===`me`),x=e.speaking?i(`talk.speaking`):e.listening?i(`talk.listening`):a?i(`talk.live`):o?i(`talk.connecting`):u?i(`video.ended`):``;return(0,U.jsxs)(`section`,{className:d(`relative flex min-h-0 flex-col bg-neutral-950 text-white`,`safe-top`,r),children:[(0,U.jsxs)(`div`,{className:`flex h-14 shrink-0 items-center gap-3 px-4 sm:px-5`,children:[(0,U.jsx)(`div`,{className:`min-w-0 flex-1 truncate font-display font-semibold text-[1rem] tracking-tight`,children:t?.wizard.title??``}),x?(0,U.jsxs)(`span`,{className:`flex items-center gap-1.5 text-[0.8125rem] text-white/70`,children:[a?(0,U.jsx)(`span`,{className:d(`size-2 rounded-full`,e.speaking?`animate-pulse-dot bg-emerald-400`:`bg-rose`)}):null,x]}):null,(0,U.jsx)(Ce,{since:c})]}),(0,U.jsxs)(`div`,{className:d(`grid min-h-0 gap-2 px-3 pb-2 sm:px-4`,g?`flex-1 grid-cols-1 sm:grid-cols-2`:`shrink-0 grid-cols-1`,!g&&a&&e.captions.length?`h-[38%]`:g?``:`flex-1`),children:[(0,U.jsxs)(`div`,{className:d(`relative min-h-0 overflow-hidden rounded-2xl bg-neutral-900`,!g&&`hidden`),children:[(0,U.jsx)(`video`,{ref:e.video,muted:!0,playsInline:!0,autoPlay:!0,className:d(`absolute inset-0 h-full w-full object-cover`,e.facing===`user`&&`-scale-x-100`,e.camera?`block`:`hidden`)}),e.camera?null:(0,U.jsxs)(`div`,{className:`absolute inset-0 flex flex-col items-center justify-center gap-2 text-white/50`,children:[(0,U.jsx)(V,{className:`size-8`}),(0,U.jsx)(`span`,{className:`text-[0.8125rem]`,children:i(`video.cameraOff`)})]}),(0,U.jsxs)(`span`,{className:`absolute bottom-2 left-3 rounded-md bg-black/50 px-2 py-0.5 text-[0.75rem]`,children:[i(`video.you`),e.muted?(0,U.jsx)(se,{className:`ml-1.5 inline size-3`}):null]})]}),(0,U.jsxs)(`div`,{className:d(`relative flex min-h-0 items-center justify-center overflow-hidden rounded-2xl transition-shadow`,g?`bg-neutral-900`:`bg-transparent`,g&&e.speaking&&`ring-2 ring-emerald-400/70`),children:[(0,U.jsx)(`div`,{className:d(`rounded-full transition-shadow duration-500`,!g&&e.listening&&`shadow-[0_0_80px_20px_rgba(244,63,94,0.25)]`,!g&&e.speaking&&`shadow-[0_0_80px_20px_rgba(52,211,153,0.3)]`,e.speaking&&`animate-breathe`),children:(0,U.jsx)(de,{kind:t?.wizard.avatar??`round`,size:g?140:200,fluffy:!0,interactive:!1})}),g?(0,U.jsx)(`span`,{className:`absolute bottom-2 left-3 max-w-[85%] truncate rounded-md bg-black/50 px-2 py-0.5 text-[0.75rem]`,children:t?.wizard.title??``}):null]})]}),a&&!g?(0,U.jsx)(we,{voice:e}):a&&(v||y)?(0,U.jsx)(`div`,{className:`shrink-0 px-4 pb-2 sm:px-5`,children:(0,U.jsxs)(`div`,{className:`mx-auto max-w-[720px] space-y-1 text-center`,children:[y?(0,U.jsx)(`p`,{className:`line-clamp-1 text-[0.8125rem] text-white/50`,children:y.text}):null,v?(0,U.jsx)(`p`,{className:`line-clamp-3 text-[0.9375rem] text-white/95 leading-snug`,children:v.text}):null]})}):null,e.error?(0,U.jsx)(`p`,{className:`shrink-0 px-5 pb-2 text-center text-[0.8125rem] text-rose`,children:e.error}):null,(0,U.jsx)(`div`,{className:`flex shrink-0 items-center justify-center gap-3 px-4 pt-1 pb-4`,children:a?(0,U.jsxs)(U.Fragment,{children:[(0,U.jsx)(W,{label:i(e.muted?`video.unmute`:`video.mute`),on:!e.muted,onClick:e.toggleMute,children:e.muted?(0,U.jsx)(se,{className:`size-5`}):(0,U.jsx)(b,{className:`size-5`})}),(0,U.jsx)(W,{label:i(e.camera?`talk.cameraOff`:`talk.camera`),on:e.camera,onClick:()=>e.camera?e.stopCamera():void e.startCamera(),children:e.camera?(0,U.jsx)(h,{className:`size-5`}):(0,U.jsx)(V,{className:`size-5`})}),e.camera&&Se?(0,U.jsx)(W,{label:i(`video.flip`),onClick:()=>void e.flipCamera(),children:(0,U.jsx)(s,{className:`size-5`})}):null,(0,U.jsx)(W,{label:i(`video.leave`),danger:!0,onClick:m,children:(0,U.jsx)(ce,{className:`size-5`})})]}):(0,U.jsxs)(`div`,{className:`flex flex-col items-center gap-2`,children:[(0,U.jsxs)(`button`,{type:`button`,disabled:o||!t?.talk,onClick:()=>void p(),className:`flex h-12 items-center gap-2 rounded-full bg-emerald-500 px-6 font-medium text-[0.9375rem] text-white transition hover:brightness-110 disabled:opacity-50`,children:[o?(0,U.jsx)(_,{className:`size-4`}):n?(0,U.jsx)(h,{className:`size-5`}):(0,U.jsx)(b,{className:`size-5`}),i(u?`video.rejoin`:n?`video.join`:`talk.start`)]}),!u&&!e.error?(0,U.jsx)(`p`,{className:`max-w-sm text-center text-[0.75rem] text-white/50`,children:i(n?`video.hint`:`talk.joinHint`)}):null]})})]})}var Ee=e=>L[e.kind]!==`device`,De=1024,Oe=4e3;function ke(e,t){return e?e.length>t?`${e.slice(0,t)} …`:e:``}function Ae(e,t,n=!1){let r=[`status: ${e.status}`,`camera: ${n?`on`:`off`}`];if(e.ask)return r.push(e.ask.kind===`confirm`?`question: the step wants to "${e.ask.action.summary}" in ${e.ask.service}; answer_ask allows or skips it`:`question: a sign-in at ${e.ask.site.host}; the person types it on the screen, wait`),r.join(`
|
|
2
2
|
`);if(e.status===`running`){let t=[...e.events].reverse().find(e=>e.type===`tool`||e.type===`info`||e.type===`step_started`);return r.push(`working on: ${e.step?.title??``}`),t&&r.push(`doing: ${M(t)}`),r.join(`
|
|
3
3
|
`)}if(e.status===`done`){r.push(`done. made:`);for(let{step:t,output:n}of e.shown)r.push(`- ${t.title}: ${ke(n?.text,400)||`(a file, on the screen)`}`);return r.join(`
|
|
4
4
|
`)}if(e.status===`failed`)return r.push(`failed: ${e.error??``}; go_back or the person retries on the screen`),r.join(`
|