@engenty/wizards-runtime 0.10.0 → 0.11.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/apps/runtime/dist/app.js +18 -2
- package/apps/runtime/dist/db/live-triggers.js +144 -0
- package/apps/runtime/dist/db/migrations/tenant/0023_live_change.sql +167 -0
- package/apps/runtime/dist/db/migrations/tenant/0024_live_presence.sql +28 -0
- package/apps/runtime/dist/db/migrations/tenant/meta/0023_snapshot.json +3860 -0
- package/apps/runtime/dist/db/migrations/tenant/meta/0024_snapshot.json +3967 -0
- package/apps/runtime/dist/db/migrations/tenant/meta/_journal.json +14 -0
- package/apps/runtime/dist/db/schema.js +41 -0
- package/apps/runtime/dist/docs/user-guide/meta.json +1 -0
- package/apps/runtime/dist/docs/user-guide/together.md +60 -0
- package/apps/runtime/dist/index.js +5 -1
- package/apps/runtime/dist/live/feed.js +34 -0
- package/apps/runtime/dist/live/hub.js +200 -0
- package/apps/runtime/dist/live/origin.js +53 -0
- package/apps/runtime/dist/live/views.js +146 -0
- package/apps/runtime/dist/mcp/handler.js +7 -1
- package/apps/runtime/dist/mcp/tools.js +51 -2
- package/apps/runtime/dist/routes/api.js +71 -2
- package/apps/runtime/dist/routes/live.js +85 -0
- package/apps/runtime/dist/routes/studio.js +47 -85
- package/apps/runtime/dist/services/presence.js +132 -0
- package/apps/runtime/dist/services/space-data.js +33 -6
- package/apps/runtime/dist/sync/apply.js +4 -0
- package/apps/runtime/dist/sync/client.js +146 -1
- package/apps/runtime/dist/texts.js +2 -0
- package/apps/web/dist/assets/AboutDialog-9VcgySrQ.js +1 -0
- package/apps/web/dist/assets/{ChangelogDialog-Bv02g8av.js → ChangelogDialog-BXvT2VMU.js} +1 -1
- package/apps/web/dist/assets/EditorPage-Cvzd0nah.js +4 -0
- package/apps/web/dist/assets/{FlowPreview-dc5C92kK.js → FlowPreview-BV1NJ0rF.js} +1 -1
- package/apps/web/dist/assets/{Harness-D0nFOIVx.js → Harness-DYviBlHB.js} +2 -2
- package/apps/web/dist/assets/Marketplace-DTSg7_U7.js +2 -0
- package/apps/web/dist/assets/{NewWizardChannels-i62Y_2DZ.js → NewWizardChannels-DiujJzOR.js} +1 -1
- package/apps/web/dist/assets/NewWizardPage-CngUh9g-.js +7 -0
- package/apps/web/dist/assets/OnboardingPage-DFKJnWtw.js +1 -0
- package/apps/web/dist/assets/PreviewPane-C0E9OLzB.js +9 -0
- package/apps/web/dist/assets/ProjectPage-CYDX-JYc.js +1 -0
- package/apps/web/dist/assets/PublicRunner-CkRO_Pw-.js +1 -0
- package/apps/web/dist/assets/{ReadOnly-Mv5M2OV9.js → ReadOnly-E-h9y_QO.js} +1 -1
- package/apps/web/dist/assets/SettingsPage-BMgP3aRV.js +2 -0
- package/apps/web/dist/assets/SetupPage-DBO_rzj7.js +1 -0
- package/apps/web/dist/assets/{SharePage-CBSRK0wF.js → SharePage-BvvmYB5N.js} +1 -1
- package/apps/web/dist/assets/changelog-zllICQ4q.js +1 -0
- package/apps/web/dist/assets/{coins-BGZKYmu6.js → coins-DQ91VJAB.js} +1 -1
- package/apps/web/dist/assets/index-Bjn557f1.js +20 -0
- package/apps/web/dist/assets/index-DN0VMwsS.css +1 -0
- package/apps/web/dist/assets/{phone-BzHhwehj.js → phone-jIuRIwyg.js} +1 -1
- package/apps/web/dist/assets/{runners-C1-zIlry.js → runners-DloOxEbh.js} +1 -1
- package/apps/web/dist/assets/session-BpsCkDv6.js +2 -0
- package/apps/web/dist/assets/{settings-menu-BZRGhsIO.js → settings-menu-CoLUNJGQ.js} +1 -1
- package/apps/web/dist/assets/theme-2XjIQXH3.js +11 -0
- package/apps/web/dist/assets/{ui-BI1RPFWT.js → ui-BIWmkPh6.js} +3 -3
- package/apps/web/dist/assets/{upload-CwT8oMz0.js → upload-BcOvBWHS.js} +1 -1
- package/apps/web/dist/assets/{useMutation-byk81dDj.js → useMutation-CD7HmAxR.js} +1 -1
- package/apps/web/dist/assets/{volume-2-B1Pz6Iwt.js → volume-2-D2To9w5D.js} +1 -1
- package/apps/web/dist/assets/{wrench-CvzXRbWN.js → wrench-B98ubRvB.js} +1 -1
- package/apps/web/dist/index.html +8 -8
- package/apps/web/dist/mcp/flow.html +2 -2
- package/node_modules/@engenty/wizards-shared/dist/feature-flags.d.ts +6 -0
- package/node_modules/@engenty/wizards-shared/dist/feature-flags.js +6 -0
- package/node_modules/@engenty/wizards-shared/dist/live.d.ts +46 -0
- package/node_modules/@engenty/wizards-shared/dist/live.js +9 -0
- package/node_modules/@engenty/wizards-shared/dist/run.d.ts +1 -0
- package/node_modules/@engenty/wizards-shared/dist/run.js +2 -0
- package/package.json +1 -1
- package/plugin/.claude-plugin/plugin.json +1 -1
- package/plugin/plugin.json +1 -1
- package/apps/web/dist/assets/AboutDialog-D1YHT0jc.js +0 -1
- package/apps/web/dist/assets/EditorPage-BThoZwqO.js +0 -4
- package/apps/web/dist/assets/Marketplace-Cnd8BF3q.js +0 -2
- package/apps/web/dist/assets/NewWizardPage-BcpRA1fx.js +0 -7
- package/apps/web/dist/assets/OnboardingPage-BcMDEXNq.js +0 -1
- package/apps/web/dist/assets/PreviewPane-GHcVV2Hu.js +0 -4
- package/apps/web/dist/assets/ProjectPage-TDywzUOd.js +0 -1
- package/apps/web/dist/assets/PublicRunner-B6JINLpR.js +0 -1
- package/apps/web/dist/assets/SettingsPage-B-F1dLgt.js +0 -2
- package/apps/web/dist/assets/SetupPage-CVdsdVBW.js +0 -1
- package/apps/web/dist/assets/changelog-BR1lxaWv.js +0 -1
- package/apps/web/dist/assets/index-D3-kv1WF.js +0 -14
- package/apps/web/dist/assets/index-DcUL6teA.css +0 -1
- package/apps/web/dist/assets/session-B_JeZnJ0.js +0 -2
- package/apps/web/dist/assets/theme-HcCfZDzS.js +0 -11
|
@@ -33,6 +33,12 @@ export declare const FEATURES: {
|
|
|
33
33
|
readonly label: "Two-way sync with the cloud";
|
|
34
34
|
readonly hint: "A local install with an account keeps its spaces in step with the organization in the cloud, both ways: wizards, knowledge, data and files.";
|
|
35
35
|
};
|
|
36
|
+
readonly liveChanges: {
|
|
37
|
+
readonly kind: "release";
|
|
38
|
+
readonly default: true;
|
|
39
|
+
readonly label: "Live changes in the studio";
|
|
40
|
+
readonly hint: "An open studio shows what changed elsewhere (another member, a run, the AI, the sync) without a reload.";
|
|
41
|
+
};
|
|
36
42
|
readonly unsetConnectors: {
|
|
37
43
|
readonly kind: "release";
|
|
38
44
|
readonly default: false;
|
|
@@ -25,6 +25,12 @@ export const FEATURES = {
|
|
|
25
25
|
label: "Two-way sync with the cloud",
|
|
26
26
|
hint: "A local install with an account keeps its spaces in step with the organization in the cloud, both ways: wizards, knowledge, data and files.",
|
|
27
27
|
},
|
|
28
|
+
liveChanges: {
|
|
29
|
+
kind: "release",
|
|
30
|
+
default: true,
|
|
31
|
+
label: "Live changes in the studio",
|
|
32
|
+
hint: "An open studio shows what changed elsewhere (another member, a run, the AI, the sync) without a reload.",
|
|
33
|
+
},
|
|
28
34
|
unsetConnectors: {
|
|
29
35
|
kind: "release",
|
|
30
36
|
default: false,
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Live changes (docs/plans/live-changes.md): every write to an item a studio shows is numbered
|
|
3
|
+
* in the tenant's `live_change` feed, and an open studio hears of it. The kinds start equal to
|
|
4
|
+
* the two-way sync's; they are their own list so a kind can be live without syncing.
|
|
5
|
+
*/
|
|
6
|
+
export declare const LIVE_KINDS: readonly ["space", "wizard", "translation", "message", "page", "table", "row", "category", "file", "connector", "presence"];
|
|
7
|
+
export type LiveKind = (typeof LIVE_KINDS)[number];
|
|
8
|
+
/** `put`: the item was added or changed. `del`: the item itself was deleted. */
|
|
9
|
+
export type LiveOp = "put" | "del";
|
|
10
|
+
/** One changed item, as the feed and the stream carry it. */
|
|
11
|
+
export interface LiveItem {
|
|
12
|
+
kind: LiveKind;
|
|
13
|
+
op: LiveOp;
|
|
14
|
+
/** The changed item's id, as the two-way sync names it. */
|
|
15
|
+
item: string;
|
|
16
|
+
projectId: string | null;
|
|
17
|
+
/** Where the item shows when its id alone doesn't say: a row's table, a translation's wizard. */
|
|
18
|
+
parent: string | null;
|
|
19
|
+
/** The feed's number of the item's last change in this batch. */
|
|
20
|
+
seq?: number;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* A change as the studio's stream sends it: a `put` carries the item's view when it has one, the
|
|
24
|
+
* JSON its GET route answers, so the studio can show it without asking again.
|
|
25
|
+
*/
|
|
26
|
+
export interface LiveChange extends LiveItem {
|
|
27
|
+
view?: unknown;
|
|
28
|
+
}
|
|
29
|
+
/** Who is in a wizard, page or table: a signal for people and AI, never a lock. */
|
|
30
|
+
export interface PresenceEntry {
|
|
31
|
+
/** The person's id, or the client's for an agent. */
|
|
32
|
+
who: string;
|
|
33
|
+
/** One editor of that person: a tab. */
|
|
34
|
+
tab: string;
|
|
35
|
+
whoKind: "person" | "agent" | "assistant" | "run";
|
|
36
|
+
name: string;
|
|
37
|
+
/** The app an agent acts through; for the assistant, whom it acts for. */
|
|
38
|
+
client: string | null;
|
|
39
|
+
place: string | null;
|
|
40
|
+
placeLabel: string | null;
|
|
41
|
+
state: "viewing" | "editing";
|
|
42
|
+
seenAt: string;
|
|
43
|
+
}
|
|
44
|
+
/** The kinds of item presence is kept for. */
|
|
45
|
+
export declare const PRESENCE_KINDS: readonly ["wizard", "page", "table"];
|
|
46
|
+
export type PresenceKind = (typeof PRESENCE_KINDS)[number];
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { SYNC_KINDS } from "./sync.js";
|
|
2
|
+
/**
|
|
3
|
+
* Live changes (docs/plans/live-changes.md): every write to an item a studio shows is numbered
|
|
4
|
+
* in the tenant's `live_change` feed, and an open studio hears of it. The kinds start equal to
|
|
5
|
+
* the two-way sync's; they are their own list so a kind can be live without syncing.
|
|
6
|
+
*/
|
|
7
|
+
export const LIVE_KINDS = [...SYNC_KINDS, "presence"];
|
|
8
|
+
/** The kinds of item presence is kept for. */
|
|
9
|
+
export const PRESENCE_KINDS = ["wizard", "page", "table"];
|
|
@@ -445,6 +445,7 @@ declare const NOTES_EN: {
|
|
|
445
445
|
readonly workspaceWizardFileLarger: "The workspace in the wizard file is larger than 25 MB.";
|
|
446
446
|
readonly unknownTemplate: "There’s no template “{starterId}”.";
|
|
447
447
|
readonly wizardChangedMeantime: "The wizard was changed in the meantime.";
|
|
448
|
+
readonly itemChangedMeantime: "This was changed elsewhere in the meantime.";
|
|
448
449
|
readonly valueNotExist: "This value doesn’t exist.";
|
|
449
450
|
readonly nothingFiledUnderValue: "Nothing is filed under this value yet.";
|
|
450
451
|
readonly filmNotRenderedNeeds: "The film couldn’t be rendered. It needs ffmpeg and a timeline in the widget.";
|
|
@@ -274,6 +274,7 @@ const NOTES_EN = {
|
|
|
274
274
|
workspaceWizardFileLarger: "The workspace in the wizard file is larger than 25 MB.",
|
|
275
275
|
unknownTemplate: "There’s no template “{starterId}”.",
|
|
276
276
|
wizardChangedMeantime: "The wizard was changed in the meantime.",
|
|
277
|
+
itemChangedMeantime: "This was changed elsewhere in the meantime.",
|
|
277
278
|
valueNotExist: "This value doesn’t exist.",
|
|
278
279
|
nothingFiledUnderValue: "Nothing is filed under this value yet.",
|
|
279
280
|
filmNotRenderedNeeds: "The film couldn’t be rendered. It needs ffmpeg and a timeline in the widget.",
|
|
@@ -583,6 +584,7 @@ const NOTES_DE = {
|
|
|
583
584
|
workspaceWizardFileLarger: "Der Arbeitsbereich in der Wizard-Datei ist größer als 25 MB.",
|
|
584
585
|
unknownTemplate: "Die Vorlage „{starterId}“ gibt es nicht.",
|
|
585
586
|
wizardChangedMeantime: "Der Wizard wurde inzwischen geändert.",
|
|
587
|
+
itemChangedMeantime: "Das wurde inzwischen anderswo geändert.",
|
|
586
588
|
valueNotExist: "Diesen Wert gibt es nicht.",
|
|
587
589
|
nothingFiledUnderValue: "Unter diesem Wert steht noch nichts.",
|
|
588
590
|
filmNotRenderedNeeds: "Der Film ließ sich nicht rendern. Dafür braucht es ffmpeg und eine Zeitleiste im Widget.",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@engenty/wizards-runtime",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "Make a wish. Get your wizard. It guides you step by step. Let AI do the work. Runs on your machine, on the AI subscription you already have. The runtime, which `npx wizards` installs.",
|
|
5
5
|
"license": "FSL-1.1-MIT AND CC-BY-4.0",
|
|
6
6
|
"homepage": "https://engenty.ai",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wizards",
|
|
3
3
|
"displayName": "engenty wizards",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.11.0",
|
|
5
5
|
"description": "Build page-by-page AI wizards that people open on a shared link — designed, tested and published from Claude Code — run your published ones in the chat, and keep them in a pane beside it.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "engenty"
|
package/plugin/plugin.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json",
|
|
3
3
|
"name": "engenty-wizards",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.11.0",
|
|
5
5
|
"description": "Build page-by-page AI wizards that people open on a shared link, test and publish them from the chat, and run your published ones here.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "engenty",
|
|
@@ -1 +0,0 @@
|
|
|
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,Bt as i,Ht as a,Jt as o,Mr as s,Rr as c,Ut as l,Vt as u,Zt as d,on as f,sr as p}from"./ui-BI1RPFWT.js";import{t as m}from"./preload-helper-DpV6A1kQ.js";import{t as h}from"./logo-CGNoptDg.js";import{K as g,at as _,ot as v}from"./index-D3-kv1WF.js";import{c as y,f as b}from"./settings-menu-BZRGhsIO.js";import{ReleaseNotes as x,loadReleases as S,releaseDate as C,releaseLabel as w}from"./ChangelogDialog-Bv02g8av.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)(s,{"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:f(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),[r,i]=(0,T.useState)(``);(0,T.useEffect)(()=>{if(!e||t)return;let r=!1;return m(()=>import(`./oss-credits-C2JUsf2d.js`).then(e=>{r||n(e.default)}),[]),()=>{r=!0}},[e,t]),(0,T.useEffect)(()=>{e||i(``)},[e]);let a=r.trim().toLowerCase(),s=e=>a?e.filter(e=>k(a,e.name,e.license,f(e.description))):e,c=e=>a?e.filter(e=>k(a,e.name,e.license,e.version)):e,d=s(E),p=s(D),h=t?[{id:`shared`,label:f(`about.creditsShared`),packages:c(t.shared)},...t.groups.map(e=>({id:e.id,label:e.label,packages:c(e.packages)}))].filter(e=>e.packages.length>0):[],g=d.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:f(`about.creditsHint`)}),(0,O.jsx)(l,{type:`search`,value:r,placeholder:f(`about.search`),onChange:e=>i(e.target.value)}),d.length>0?(0,O.jsx)(j,{title:f(`about.creditsProduct`),children:(0,O.jsx)(M,{credits:d})}):null,p.length>0?(0,O.jsx)(j,{title:f(`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)(o,{})}):h.length>0?(0,O.jsx)(j,{title:f(`about.creditsDeps`),hint:a?void 0:f(`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)(u,{children:f(`about.noMatches`)}):null]})}var F=[`new`,`earlier`,`credits`],I=e=>f(e===`new`?`about.tab.new`:e===`earlier`?`about.tab.earlier`:`about.credits`),L=e=>e===1?f(`about.change`):f(`about.changes`,{n:e});function R({me:e,active:t,initialTab:n=`new`}){let i=e?.mode===`local`,{data:a,latest:s}=_(i&&t),[l,u]=(0,T.useState)(null),[p,m]=(0,T.useState)(n);(0,T.useEffect)(()=>m(n),[n]);let E=b(F.indexOf(p)),D=a?.newer&&s?s:v;(0,T.useEffect)(()=>{if(!t)return;let e=!1;return u(null),S(D===`0.10.0`?void 0:D).then(t=>{e||u(t)}),()=>{e=!0}},[t,D]);let k=l?.find(e=>e.version===`v${D}`)??l?.[0]??null,A=l?.filter(e=>e!==k)??[],j=i?a?.kind??null:`cloud`;return(0,O.jsxs)(O.Fragment,{children:[(0,O.jsxs)(`div`,{className:`flex flex-col items-center pt-4 text-center`,children:[(0,O.jsx)(h,{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:[f(`about.version`,{v}),j?` · ${f(`about.kind.${j}`)}`:``]})]}),i?(0,O.jsx)(`div`,{className:`mt-5`,children:(0,O.jsx)(g,{enabled:t})}):null,(0,O.jsx)(`div`,{className:`mt-6 flex justify-center`,children:(0,O.jsx)(d,{value:p,onChange:m,options:F.map(e=>({id:e,label:I(e)})),label:f(`about.title`)})}),(0,O.jsxs)(`div`,{className:r(`mt-5`,y(E)),children:[p===`new`?l===null?(0,O.jsx)(`div`,{className:`flex justify-center py-6 text-ink-3`,children:(0,O.jsx)(o,{})}):k?(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(k),(0,O.jsx)(`span`,{className:`font-normal font-sans text-[0.8125rem] text-ink-3 tabular-nums`,children:C(k)})]}),(0,O.jsx)(`div`,{className:`mt-3`,children:(0,O.jsx)(x,{release:k})})]}):(0,O.jsx)(`p`,{className:`text-[0.875rem] text-ink-3`,children:f(`about.changelogEmpty`)}):null,p===`earlier`?(0,O.jsx)(`div`,{className:`flex flex-col divide-y divide-border-soft`,children:A.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)(c,{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,p===`credits`?(0,O.jsx)(P,{active:!0}):null]},p)]})}function z({open:e,onClose:t,me:n}){return(0,O.jsxs)(i,{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)(a,{label:f(`common.close`),onClick:t,children:(0,O.jsx)(p,{className:`size-4`})})}),(0,O.jsx)(R,{me:n,active:e})]})}export{z as AboutDialog,R as AboutPanel};
|