wizards 0.3.5 → 0.3.7
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/agents/studio-assistant.js +285 -31
- package/apps/runtime/dist/agents/website.js +256 -34
- package/apps/runtime/dist/db/schema.js +1 -1
- package/apps/runtime/dist/docs/user/test-and-share.md +21 -11
- package/apps/runtime/dist/documents/parse.js +14 -0
- package/apps/runtime/dist/engine/steps.js +42 -6
- package/apps/runtime/dist/engine/template.js +50 -3
- package/apps/runtime/dist/film/project.js +54 -4
- package/apps/runtime/dist/routes/studio.js +52 -3
- package/apps/runtime/dist/services/brand.js +6 -3
- package/apps/runtime/dist/services/project-files.js +59 -3
- package/apps/runtime/dist/services/projects.js +150 -2
- package/apps/runtime/dist/services/wizards.js +25 -0
- package/apps/web/dist/assets/AboutDialog-C0dN86zd.js +1 -0
- package/apps/web/dist/assets/{ChangelogDialog-VEBTlC3f.js → ChangelogDialog-Cv81t7tj.js} +1 -1
- package/apps/web/dist/assets/ChatView-uogJ3nht.js +10 -0
- package/apps/web/dist/assets/EditorPage-n8YuTh6j.js +3 -0
- package/apps/web/dist/assets/{FlowPreview-86xWWfdk.js → FlowPreview-D4dp1MWS.js} +1 -1
- package/apps/web/dist/assets/{Harness-CF6H2TYJ.js → Harness-v7r0e6vK.js} +2 -2
- package/apps/web/dist/assets/NewWizardChannels-Be-7VhBi.js +1 -0
- package/apps/web/dist/assets/NewWizardPage-C8hPvrK8.js +7 -0
- package/apps/web/dist/assets/ProjectPage-B686ArYy.js +1 -0
- package/apps/web/dist/assets/PublicRunner-DeCpVfZP.js +1 -0
- package/apps/web/dist/assets/{ReadOnly-mhKW496R.js → ReadOnly-B-UCgnqW.js} +1 -1
- package/apps/web/dist/assets/RunDrawer-C6pzi8AJ.js +4 -0
- package/apps/web/dist/assets/{RunnerView-CTRFgyu5.js → RunnerView-Deenymq0.js} +1 -1
- package/apps/web/dist/assets/SettingsPage-CK6L0yEe.js +1 -0
- package/apps/web/dist/assets/SetupPage-9CH3qXdH.js +1 -0
- package/apps/web/dist/assets/SharePage-B778xUFo.js +1 -0
- package/apps/web/dist/assets/changelog-DCJo2mbx.js +1 -0
- package/apps/web/dist/assets/{circle-alert-CYs622_r.js → circle-alert-DLvC9ePT.js} +1 -1
- package/apps/web/dist/assets/{esm-B52LIMhP.js → esm-BJskogLD.js} +1 -1
- package/apps/web/dist/assets/index-D6hUM8NU.css +1 -0
- package/apps/web/dist/assets/index-Df6UxElH.js +12 -0
- package/apps/web/dist/assets/{lock-BvSWZOin.js → lock-DR7NakPn.js} +1 -1
- package/apps/web/dist/assets/{phone-CI2Flerg.js → phone-BORh3jfv.js} +1 -1
- package/apps/web/dist/assets/{settings-menu-BOOPxcJH.js → settings-menu-DV5D91TD.js} +1 -1
- package/apps/web/dist/assets/{ui-CMdSOoUZ.js → ui-BOCXzzHi.js} +1 -1
- package/apps/web/dist/assets/{upload-Cz9HgBT9.js → upload-B3yv8gsk.js} +1 -1
- package/apps/web/dist/index.html +3 -8
- package/apps/web/dist/mcp/flow.html +2 -2
- package/node_modules/@engenty-wizards/plugin-sdk/dist/index.d.ts +3 -3
- package/node_modules/@engenty-wizards/shared/dist/changes.d.ts +22 -0
- package/node_modules/@engenty-wizards/shared/dist/changes.js +61 -0
- package/node_modules/@engenty-wizards/shared/dist/definition.d.ts +8 -8
- package/node_modules/@engenty-wizards/shared/dist/marketplace.d.ts +1 -1
- package/node_modules/@engenty-wizards/shared/dist/projects.d.ts +138 -3
- package/node_modules/@engenty-wizards/shared/dist/projects.js +153 -4
- package/node_modules/@engenty-wizards/shared/dist/wizard-package.d.ts +1 -1
- package/package.json +1 -1
- package/apps/web/dist/assets/AboutDialog-D1N4-3FE.js +0 -1
- package/apps/web/dist/assets/ChatView-DSRUEpb6.js +0 -10
- package/apps/web/dist/assets/EditorPage-UkaHDklX.js +0 -3
- package/apps/web/dist/assets/Marketplace-C-Vz3yEk.js +0 -2
- package/apps/web/dist/assets/NewWizardChannels-Cc7gDitg.js +0 -1
- package/apps/web/dist/assets/NewWizardPage-sY5q-l99.js +0 -7
- package/apps/web/dist/assets/ProjectPage-iSdpJAZS.js +0 -2
- package/apps/web/dist/assets/PublicRunner-BgRXMUxS.js +0 -1
- package/apps/web/dist/assets/RunDrawer-B0gJzdxH.js +0 -4
- package/apps/web/dist/assets/SettingsPage-CBF8i6j6.js +0 -1
- package/apps/web/dist/assets/SetupPage-Fpz9aSLN.js +0 -1
- package/apps/web/dist/assets/SharePage-Dv3Csh4A.js +0 -1
- package/apps/web/dist/assets/brand-BamUjXVr.js +0 -2
- package/apps/web/dist/assets/changelog-ViHoNW7e.js +0 -1
- package/apps/web/dist/assets/index-Bdx1Qity.js +0 -11
- package/apps/web/dist/assets/index-CDdJDojq.css +0 -1
- package/apps/web/dist/assets/session-BEHF6g4Y.js +0 -1
- package/apps/web/dist/assets/useMutation-DKyQXgyj.js +0 -1
- package/apps/web/dist/assets/volume-2-CyQuz1nn.js +0 -1
|
@@ -139,7 +139,7 @@ export interface PluginSpaceFileEvent {
|
|
|
139
139
|
file: {
|
|
140
140
|
id: string;
|
|
141
141
|
name: string;
|
|
142
|
-
kind: "logo" | "asset" | "document";
|
|
142
|
+
kind: "logo" | "asset" | "document" | "pattern";
|
|
143
143
|
mime: string;
|
|
144
144
|
};
|
|
145
145
|
}
|
|
@@ -327,7 +327,7 @@ export interface PluginSpaceFile {
|
|
|
327
327
|
name: string;
|
|
328
328
|
mime: string;
|
|
329
329
|
size: number;
|
|
330
|
-
kind: "logo" | "asset" | "document";
|
|
330
|
+
kind: "logo" | "asset" | "document" | "pattern";
|
|
331
331
|
updatedAt: string;
|
|
332
332
|
}
|
|
333
333
|
/** What a plugin wrote into a space. */
|
|
@@ -386,7 +386,7 @@ export interface PluginSpaceData {
|
|
|
386
386
|
parent?: string;
|
|
387
387
|
}): Promise<PluginSpacePage[]>;
|
|
388
388
|
/** The space's files of a kind (`document` when left out), newest first. */
|
|
389
|
-
files(space: string, kind?: "logo" | "asset" | "document"): Promise<PluginSpaceFile[]>;
|
|
389
|
+
files(space: string, kind?: "logo" | "asset" | "document" | "pattern"): Promise<PluginSpaceFile[]>;
|
|
390
390
|
/** One file of the space with its bytes: a price list someone dropped into Wissen. */
|
|
391
391
|
readFile(space: string, fileId: string): Promise<PluginSpaceFile & {
|
|
392
392
|
data: Uint8Array;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { WizardDefinition } from "./definition.js";
|
|
2
|
+
import type { WorkspaceFile } from "./workspace.js";
|
|
3
|
+
/**
|
|
4
|
+
* What changed in a draft since the version people run: the wizard's own settings, each step
|
|
5
|
+
* by its title, the steps' order, the workspace's files. "Änderungen live schalten" lists it.
|
|
6
|
+
*/
|
|
7
|
+
export interface VersionChange {
|
|
8
|
+
kind: "wizard" | "step" | "order" | "file";
|
|
9
|
+
change: "added" | "removed" | "changed";
|
|
10
|
+
/** The step's title or the file's path. */
|
|
11
|
+
name?: string;
|
|
12
|
+
/** What of a changed step or of the wizard itself: the definition's keys (`instructions`, `fields`). */
|
|
13
|
+
parts?: string[];
|
|
14
|
+
}
|
|
15
|
+
/** A version as it runs: its definition and its workspace. */
|
|
16
|
+
interface Version {
|
|
17
|
+
definition: WizardDefinition;
|
|
18
|
+
files: Pick<WorkspaceFile, "path" | "hash">[];
|
|
19
|
+
}
|
|
20
|
+
/** What `after` changes of `before`: the wizard first, then its steps in their new order, then its files. */
|
|
21
|
+
export declare function versionChanges(before: Version, after: Version): VersionChange[];
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
const same = (a, b) => JSON.stringify(a) === JSON.stringify(b);
|
|
2
|
+
/** The keys whose values differ, in the order the newer one has them. */
|
|
3
|
+
function keysChanged(before, after) {
|
|
4
|
+
const was = before;
|
|
5
|
+
const now = after;
|
|
6
|
+
const keys = [...new Set([...Object.keys(now), ...Object.keys(was)])];
|
|
7
|
+
return keys.filter((k) => !same(was[k], now[k]));
|
|
8
|
+
}
|
|
9
|
+
/** What `after` changes of `before`: the wizard first, then its steps in their new order, then its files. */
|
|
10
|
+
export function versionChanges(before, after) {
|
|
11
|
+
const changes = [];
|
|
12
|
+
const { steps: oldSteps, ...oldWizard } = before.definition;
|
|
13
|
+
const { steps: newSteps, ...newWizard } = after.definition;
|
|
14
|
+
const parts = keysChanged(oldWizard, newWizard);
|
|
15
|
+
if (parts.length) {
|
|
16
|
+
changes.push({ kind: "wizard", change: "changed", parts });
|
|
17
|
+
}
|
|
18
|
+
const old = new Map(oldSteps.map((s) => [s.id, s]));
|
|
19
|
+
const now = new Set(newSteps.map((s) => s.id));
|
|
20
|
+
for (const step of newSteps) {
|
|
21
|
+
const was = old.get(step.id);
|
|
22
|
+
if (!was) {
|
|
23
|
+
changes.push({ kind: "step", change: "added", name: step.title });
|
|
24
|
+
}
|
|
25
|
+
else if (!same(was, step)) {
|
|
26
|
+
changes.push({
|
|
27
|
+
kind: "step",
|
|
28
|
+
change: "changed",
|
|
29
|
+
name: step.title,
|
|
30
|
+
parts: keysChanged(was, step).filter((k) => k !== "id"),
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
for (const step of oldSteps) {
|
|
35
|
+
if (!now.has(step.id)) {
|
|
36
|
+
changes.push({ kind: "step", change: "removed", name: step.title });
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
// The steps both have, in each one's order: a move is one change, however many steps moved.
|
|
40
|
+
const kept = (steps) => steps.map((s) => s.id).filter((id) => old.has(id) && now.has(id));
|
|
41
|
+
if (!same(kept(oldSteps), kept(newSteps))) {
|
|
42
|
+
changes.push({ kind: "order", change: "changed" });
|
|
43
|
+
}
|
|
44
|
+
const oldFiles = new Map(before.files.map((f) => [f.path, f.hash]));
|
|
45
|
+
const newFiles = new Map(after.files.map((f) => [f.path, f.hash]));
|
|
46
|
+
for (const [path, hash] of newFiles) {
|
|
47
|
+
const was = oldFiles.get(path);
|
|
48
|
+
if (was === undefined) {
|
|
49
|
+
changes.push({ kind: "file", change: "added", name: path });
|
|
50
|
+
}
|
|
51
|
+
else if (was !== hash) {
|
|
52
|
+
changes.push({ kind: "file", change: "changed", name: path });
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
for (const path of oldFiles.keys()) {
|
|
56
|
+
if (!newFiles.has(path)) {
|
|
57
|
+
changes.push({ kind: "file", change: "removed", name: path });
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
return changes;
|
|
61
|
+
}
|
|
@@ -285,12 +285,12 @@ export declare const outputFieldSchema: z.ZodObject<{
|
|
|
285
285
|
id: z.ZodString;
|
|
286
286
|
kind: z.ZodEnum<{
|
|
287
287
|
number: "number";
|
|
288
|
-
choice: "choice";
|
|
289
|
-
score: "score";
|
|
290
288
|
text: "text";
|
|
291
289
|
list: "list";
|
|
292
290
|
table: "table";
|
|
293
291
|
yesno: "yesno";
|
|
292
|
+
choice: "choice";
|
|
293
|
+
score: "score";
|
|
294
294
|
}>;
|
|
295
295
|
description: z.ZodOptional<z.ZodString>;
|
|
296
296
|
columns: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -460,12 +460,12 @@ export declare const agentStepSchema: z.ZodObject<{
|
|
|
460
460
|
id: z.ZodString;
|
|
461
461
|
kind: z.ZodEnum<{
|
|
462
462
|
number: "number";
|
|
463
|
-
choice: "choice";
|
|
464
|
-
score: "score";
|
|
465
463
|
text: "text";
|
|
466
464
|
list: "list";
|
|
467
465
|
table: "table";
|
|
468
466
|
yesno: "yesno";
|
|
467
|
+
choice: "choice";
|
|
468
|
+
score: "score";
|
|
469
469
|
}>;
|
|
470
470
|
description: z.ZodOptional<z.ZodString>;
|
|
471
471
|
columns: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -1142,12 +1142,12 @@ export declare const stepSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1142
1142
|
id: z.ZodString;
|
|
1143
1143
|
kind: z.ZodEnum<{
|
|
1144
1144
|
number: "number";
|
|
1145
|
-
choice: "choice";
|
|
1146
|
-
score: "score";
|
|
1147
1145
|
text: "text";
|
|
1148
1146
|
list: "list";
|
|
1149
1147
|
table: "table";
|
|
1150
1148
|
yesno: "yesno";
|
|
1149
|
+
choice: "choice";
|
|
1150
|
+
score: "score";
|
|
1151
1151
|
}>;
|
|
1152
1152
|
description: z.ZodOptional<z.ZodString>;
|
|
1153
1153
|
columns: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -2076,12 +2076,12 @@ export declare const wizardSchema: z.ZodObject<{
|
|
|
2076
2076
|
id: z.ZodString;
|
|
2077
2077
|
kind: z.ZodEnum<{
|
|
2078
2078
|
number: "number";
|
|
2079
|
-
choice: "choice";
|
|
2080
|
-
score: "score";
|
|
2081
2079
|
text: "text";
|
|
2082
2080
|
list: "list";
|
|
2083
2081
|
table: "table";
|
|
2084
2082
|
yesno: "yesno";
|
|
2083
|
+
choice: "choice";
|
|
2084
|
+
score: "score";
|
|
2085
2085
|
}>;
|
|
2086
2086
|
description: z.ZodOptional<z.ZodString>;
|
|
2087
2087
|
columns: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -214,7 +214,7 @@ export type MarketplacePlan = keyof typeof MARKETPLACE_PLANS;
|
|
|
214
214
|
export declare const ITEM_FORMAT_IDS: ("text" | "image" | "audio" | "video" | "document" | "dashboard" | "table")[];
|
|
215
215
|
export declare const INDUSTRY_IDS: ("any" | "trades" | "gastronomy" | "hospitality" | "realEstate" | "retail" | "health" | "professional" | "agency" | "events" | "publicSector")[];
|
|
216
216
|
export declare const USE_CASE_IDS: ("marketing" | "sales" | "accounting" | "service" | "research" | "hr" | "operations" | "website" | "visuals" | "inquiries" | "advice")[];
|
|
217
|
-
export declare const CAPABILITY_IDS: ("
|
|
217
|
+
export declare const CAPABILITY_IDS: ("text" | "code" | "image" | "browser" | "video" | "speech" | "film" | "web" | "documents" | "listening" | "connectors")[];
|
|
218
218
|
export declare const MARKETPLACE_PLAN_IDS: ("free" | "pro")[];
|
|
219
219
|
/** The formats a run hands over, read from what the result step offers. */
|
|
220
220
|
export declare function formatsOf(def: WizardDefinition): ItemFormat[];
|
|
@@ -24,8 +24,134 @@ export interface BrandColor {
|
|
|
24
24
|
name: string;
|
|
25
25
|
/** #rrggbb */
|
|
26
26
|
value: string;
|
|
27
|
+
/** The `ColorSection` it belongs to; none for the standard colours. */
|
|
28
|
+
section?: string;
|
|
27
29
|
}
|
|
28
|
-
export declare const
|
|
30
|
+
export declare const COLOR_SECTION_KINDS: readonly ["colors", "gradients", "patterns"];
|
|
31
|
+
export type ColorSectionKind = (typeof COLOR_SECTION_KINDS)[number];
|
|
32
|
+
/**
|
|
33
|
+
* Further colours of one use, as a brand guide groups them: "Illustration – for drawings and
|
|
34
|
+
* charts". Optional. A section holds colours, gradients or patterns (`kind`, colours when none).
|
|
35
|
+
* Colours in no section are the standard ones: they come first, and the first of them is the
|
|
36
|
+
* accent.
|
|
37
|
+
*/
|
|
38
|
+
export interface ColorSection {
|
|
39
|
+
id: string;
|
|
40
|
+
title: string;
|
|
41
|
+
/** When to use what is in it. */
|
|
42
|
+
description: string;
|
|
43
|
+
kind?: ColorSectionKind;
|
|
44
|
+
}
|
|
45
|
+
export declare const GRADIENT_TYPES: readonly ["linear", "radial", "conic"];
|
|
46
|
+
export type GradientType = (typeof GRADIENT_TYPES)[number];
|
|
47
|
+
/** A gradient of the brand, as CSS draws it: its type, its angle and its colour stops. */
|
|
48
|
+
export interface BrandGradient {
|
|
49
|
+
id: string;
|
|
50
|
+
name: string;
|
|
51
|
+
/** The gradients section it is in. */
|
|
52
|
+
section: string;
|
|
53
|
+
type: GradientType;
|
|
54
|
+
/** Degrees: the direction of a linear one, where a conic one starts. */
|
|
55
|
+
angle: number;
|
|
56
|
+
stops: {
|
|
57
|
+
color: string;
|
|
58
|
+
at: number;
|
|
59
|
+
}[];
|
|
60
|
+
}
|
|
61
|
+
/** A pattern or a fill of the brand: a picture of the space (`file`), tiled or filling. */
|
|
62
|
+
export interface BrandPattern {
|
|
63
|
+
id: string;
|
|
64
|
+
name: string;
|
|
65
|
+
/** The patterns section it is in. */
|
|
66
|
+
section: string;
|
|
67
|
+
/** The project file (kind `pattern`) with the picture. */
|
|
68
|
+
file: string;
|
|
69
|
+
/** Repeated as a tile; else it fills the area. */
|
|
70
|
+
tile?: boolean;
|
|
71
|
+
}
|
|
72
|
+
/** The gradient as CSS. */
|
|
73
|
+
export declare function gradientCss(g: Pick<BrandGradient, "type" | "angle" | "stops">): string;
|
|
74
|
+
/**
|
|
75
|
+
* A CSS gradient read back: linear, radial or conic, with hex stops. Stops without a position
|
|
76
|
+
* are spread evenly. Null where it is not one of these.
|
|
77
|
+
*/
|
|
78
|
+
export declare function parseGradient(css: string): Pick<BrandGradient, "type" | "angle" | "stops"> | null;
|
|
79
|
+
/**
|
|
80
|
+
* The colours as stored: the standard ones first, then each section's in the sections' order; a
|
|
81
|
+
* section that is not there any more is dropped from its colours.
|
|
82
|
+
*/
|
|
83
|
+
export declare function orderColors(colors: BrandColor[], sections: ColorSection[]): BrandColor[];
|
|
84
|
+
/**
|
|
85
|
+
* Further logos of one use, as a brand guide groups them: "Logomark – small spaces, app icons".
|
|
86
|
+
* Optional. Logos in no section are the standard ones: they come first, without a title, and
|
|
87
|
+
* the first of them is the main logo.
|
|
88
|
+
*/
|
|
89
|
+
export interface LogoSection {
|
|
90
|
+
id: string;
|
|
91
|
+
title: string;
|
|
92
|
+
/** When to use the logos in it. */
|
|
93
|
+
description: string;
|
|
94
|
+
/** The logo files in it, in order. A file sits in one section at most. */
|
|
95
|
+
logos: string[];
|
|
96
|
+
}
|
|
97
|
+
/** The main logo: the first standard one (in no section), else the first of all. */
|
|
98
|
+
export declare function mainLogo<T extends {
|
|
99
|
+
id: string;
|
|
100
|
+
}>(logos: T[], sections: LogoSection[] | undefined): T | undefined;
|
|
101
|
+
/** The sign before a rule: a bullet unless chosen. */
|
|
102
|
+
export declare const RULE_MARKS: readonly ["bullet", "do", "dont", "question", "important", "number"];
|
|
103
|
+
export type RuleMark = (typeof RULE_MARKS)[number];
|
|
104
|
+
/** A rule of the brand — for its logos, colours or type — in the admin's words. */
|
|
105
|
+
export interface BrandRule {
|
|
106
|
+
text: string;
|
|
107
|
+
/** None: a bullet. */
|
|
108
|
+
mark?: RuleMark;
|
|
109
|
+
}
|
|
110
|
+
/** Rules as a model reads them: the sign said in words, numbered ones counted. */
|
|
111
|
+
export declare function ruleLines(rules: BrandRule[]): string;
|
|
112
|
+
/** A typeface of the brand and what it is for: "Space Grotesk – headings". */
|
|
113
|
+
export interface BrandFont {
|
|
114
|
+
id: string;
|
|
115
|
+
/** The family as CSS names it: "Space Grotesk". */
|
|
116
|
+
family: string;
|
|
117
|
+
/** What it is for, in the admin's words. */
|
|
118
|
+
role: string;
|
|
119
|
+
/** The weights the brand uses: 400, 600, … */
|
|
120
|
+
weights: number[];
|
|
121
|
+
}
|
|
122
|
+
/** A text style of the type scale: "Headline XL – Space Grotesk 600, 48 px, line 90 %, −4 %". */
|
|
123
|
+
export interface TextStyle {
|
|
124
|
+
id: string;
|
|
125
|
+
name: string;
|
|
126
|
+
/** The `BrandFont` it is set in; none for the first font. */
|
|
127
|
+
font?: string;
|
|
128
|
+
/** px */
|
|
129
|
+
size: number;
|
|
130
|
+
weight: number;
|
|
131
|
+
/** Line height in % of the size. */
|
|
132
|
+
lineHeight: number;
|
|
133
|
+
/** Letter spacing in % of the size. */
|
|
134
|
+
tracking: number;
|
|
135
|
+
uppercase?: boolean;
|
|
136
|
+
}
|
|
137
|
+
export declare const FONT_WEIGHTS: readonly [300, 400, 500, 600, 700, 800];
|
|
138
|
+
/** A text style as a model and a person read it: "Space Grotesk 600, 48 px, line 90 %, tracking −4 %". */
|
|
139
|
+
export declare function textStyleLine(style: TextStyle, fonts: BrandFont[]): string;
|
|
140
|
+
/**
|
|
141
|
+
* Assets of one kind, shown as a tab of their own, named by its title: "Icons", "Background
|
|
142
|
+
* images". Optional.
|
|
143
|
+
* Assets in no section are the general ones, in the first tab.
|
|
144
|
+
*/
|
|
145
|
+
export interface AssetSection {
|
|
146
|
+
id: string;
|
|
147
|
+
title: string;
|
|
148
|
+
/** The asset files in it, in order. A file sits in one section at most. */
|
|
149
|
+
assets: string[];
|
|
150
|
+
}
|
|
151
|
+
/** The sections as stored: each file in its first section only, ids not known to `files` left out. */
|
|
152
|
+
export declare function cleanLogoSections(sections: LogoSection[], files?: string[]): LogoSection[];
|
|
153
|
+
export declare function cleanAssetSections(sections: AssetSection[], files?: string[]): AssetSection[];
|
|
154
|
+
export declare const PROJECT_FILE_KINDS: readonly ["logo", "asset", "document", "pattern"];
|
|
29
155
|
export type ProjectFileKind = (typeof PROJECT_FILE_KINDS)[number];
|
|
30
156
|
/** `pending`: being read, described and indexed. */
|
|
31
157
|
export type ProjectFileStatus = "pending" | "ready" | "failed";
|
|
@@ -48,17 +174,26 @@ export interface ProjectFileView {
|
|
|
48
174
|
}
|
|
49
175
|
export declare const PROJECT_LIMITS: {
|
|
50
176
|
readonly facts: 100;
|
|
51
|
-
readonly colors:
|
|
177
|
+
readonly colors: 32;
|
|
178
|
+
readonly fonts: 6;
|
|
179
|
+
readonly textStyles: 16;
|
|
180
|
+
/** Sections of logos, and of colours, each. */
|
|
181
|
+
readonly logoSections: 8;
|
|
182
|
+
/** Rows of logo rules. */
|
|
183
|
+
readonly logoRules: 16;
|
|
52
184
|
readonly files: {
|
|
53
|
-
readonly logo:
|
|
185
|
+
readonly logo: 24;
|
|
54
186
|
readonly asset: 100;
|
|
55
187
|
readonly document: 2000;
|
|
188
|
+
readonly pattern: 24;
|
|
56
189
|
};
|
|
190
|
+
readonly gradients: 24;
|
|
57
191
|
readonly bytes: {
|
|
58
192
|
readonly logo: 5000000;
|
|
59
193
|
readonly asset: 15000000;
|
|
60
194
|
readonly video: 80000000;
|
|
61
195
|
readonly document: 30000000;
|
|
196
|
+
readonly pattern: 10000000;
|
|
62
197
|
};
|
|
63
198
|
};
|
|
64
199
|
/** The largest file of a kind and type a project takes. */
|
|
@@ -79,13 +79,162 @@ export const BASIC_FACTS = [
|
|
|
79
79
|
{ key: "website", de: "Website", en: "Website" },
|
|
80
80
|
{ key: "iban", de: "IBAN", en: "IBAN" },
|
|
81
81
|
];
|
|
82
|
+
export const COLOR_SECTION_KINDS = ["colors", "gradients", "patterns"];
|
|
83
|
+
export const GRADIENT_TYPES = ["linear", "radial", "conic"];
|
|
84
|
+
/** The gradient as CSS. */
|
|
85
|
+
export function gradientCss(g) {
|
|
86
|
+
const stops = [...g.stops]
|
|
87
|
+
.sort((a, b) => a.at - b.at)
|
|
88
|
+
.map((s) => `${s.color} ${Math.round(s.at)}%`)
|
|
89
|
+
.join(", ");
|
|
90
|
+
if (g.type === "radial") {
|
|
91
|
+
return `radial-gradient(circle at center, ${stops})`;
|
|
92
|
+
}
|
|
93
|
+
if (g.type === "conic") {
|
|
94
|
+
return `conic-gradient(from ${Math.round(g.angle)}deg at center, ${stops})`;
|
|
95
|
+
}
|
|
96
|
+
return `linear-gradient(${Math.round(g.angle)}deg, ${stops})`;
|
|
97
|
+
}
|
|
98
|
+
const SIDES = {
|
|
99
|
+
top: 0,
|
|
100
|
+
"top right": 45,
|
|
101
|
+
right: 90,
|
|
102
|
+
"bottom right": 135,
|
|
103
|
+
bottom: 180,
|
|
104
|
+
"bottom left": 225,
|
|
105
|
+
left: 270,
|
|
106
|
+
"top left": 315,
|
|
107
|
+
};
|
|
108
|
+
/**
|
|
109
|
+
* A CSS gradient read back: linear, radial or conic, with hex stops. Stops without a position
|
|
110
|
+
* are spread evenly. Null where it is not one of these.
|
|
111
|
+
*/
|
|
112
|
+
export function parseGradient(css) {
|
|
113
|
+
const m = css.trim().match(/^(repeating-)?(linear|radial|conic)-gradient\(\s*([\s\S]*)\)\s*;?$/i);
|
|
114
|
+
if (!m) {
|
|
115
|
+
return null;
|
|
116
|
+
}
|
|
117
|
+
const type = m[2].toLowerCase();
|
|
118
|
+
const parts = m[3].split(/,(?![^(]*\))/).map((p) => p.trim());
|
|
119
|
+
let angle = type === "linear" ? 180 : 0;
|
|
120
|
+
const head = parts[0] ?? "";
|
|
121
|
+
if (!/^#|^rgb|^hsl|^oklch/i.test(head)) {
|
|
122
|
+
parts.shift();
|
|
123
|
+
const deg = head.match(/(-?[\d.]+)deg/);
|
|
124
|
+
const side = head.match(/^to\s+(.+)$/i)?.[1].toLowerCase();
|
|
125
|
+
if (deg) {
|
|
126
|
+
angle = Number(deg[1]);
|
|
127
|
+
}
|
|
128
|
+
else if (side && side in SIDES) {
|
|
129
|
+
angle = SIDES[side];
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
const stops = parts
|
|
133
|
+
.map((p) => p.match(/^(#[0-9a-f]{3,8})\b\s*(-?[\d.]+%)?/i))
|
|
134
|
+
.filter((x) => Boolean(x))
|
|
135
|
+
.map((x, i, all) => ({
|
|
136
|
+
color: x[1].toLowerCase(),
|
|
137
|
+
at: x[2] ? Number.parseFloat(x[2]) : all.length > 1 ? (i / (all.length - 1)) * 100 : 0,
|
|
138
|
+
}));
|
|
139
|
+
return stops.length >= 2 ? { type, angle: ((angle % 360) + 360) % 360, stops } : null;
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* The colours as stored: the standard ones first, then each section's in the sections' order; a
|
|
143
|
+
* section that is not there any more is dropped from its colours.
|
|
144
|
+
*/
|
|
145
|
+
export function orderColors(colors, sections) {
|
|
146
|
+
const at = (c) => (c.section ? sections.findIndex((s) => s.id === c.section) : -1);
|
|
147
|
+
return colors
|
|
148
|
+
.map((c) => (c.section && at(c) < 0 ? { name: c.name, value: c.value } : c))
|
|
149
|
+
.map((c, i) => ({ c, i }))
|
|
150
|
+
.sort((a, b) => at(a.c) - at(b.c) || a.i - b.i)
|
|
151
|
+
.map(({ c }) => c);
|
|
152
|
+
}
|
|
153
|
+
/** The main logo: the first standard one (in no section), else the first of all. */
|
|
154
|
+
export function mainLogo(logos, sections) {
|
|
155
|
+
const grouped = new Set(sections?.flatMap((s) => s.logos));
|
|
156
|
+
return logos.find((f) => !grouped.has(f.id)) ?? logos[0];
|
|
157
|
+
}
|
|
158
|
+
/** The sign before a rule: a bullet unless chosen. */
|
|
159
|
+
export const RULE_MARKS = ["bullet", "do", "dont", "question", "important", "number"];
|
|
160
|
+
/** Rules as a model reads them: the sign said in words, numbered ones counted. */
|
|
161
|
+
export function ruleLines(rules) {
|
|
162
|
+
let n = 0;
|
|
163
|
+
return rules
|
|
164
|
+
.map((r) => {
|
|
165
|
+
switch (r.mark) {
|
|
166
|
+
case "do":
|
|
167
|
+
return `- Do: ${r.text}`;
|
|
168
|
+
case "dont":
|
|
169
|
+
return `- Don't: ${r.text}`;
|
|
170
|
+
case "question":
|
|
171
|
+
return `- To check with the person: ${r.text}`;
|
|
172
|
+
case "important":
|
|
173
|
+
return `- Important: ${r.text}`;
|
|
174
|
+
case "number":
|
|
175
|
+
n += 1;
|
|
176
|
+
return `${n}. ${r.text}`;
|
|
177
|
+
default:
|
|
178
|
+
return `- ${r.text}`;
|
|
179
|
+
}
|
|
180
|
+
})
|
|
181
|
+
.join("\n");
|
|
182
|
+
}
|
|
183
|
+
export const FONT_WEIGHTS = [300, 400, 500, 600, 700, 800];
|
|
184
|
+
/** A text style as a model and a person read it: "Space Grotesk 600, 48 px, line 90 %, tracking −4 %". */
|
|
185
|
+
export function textStyleLine(style, fonts) {
|
|
186
|
+
const family = (fonts.find((f) => f.id === style.font) ?? fonts[0])?.family;
|
|
187
|
+
return [
|
|
188
|
+
family ? `${family} ${style.weight}` : `weight ${style.weight}`,
|
|
189
|
+
`${style.size} px`,
|
|
190
|
+
`line ${style.lineHeight} %`,
|
|
191
|
+
`tracking ${style.tracking} %`,
|
|
192
|
+
style.uppercase ? "uppercase" : "",
|
|
193
|
+
]
|
|
194
|
+
.filter(Boolean)
|
|
195
|
+
.join(", ");
|
|
196
|
+
}
|
|
197
|
+
/** Each file in its first list only; ids not known to `files` left out. */
|
|
198
|
+
function uniqueFiles(lists, files) {
|
|
199
|
+
const seen = new Set();
|
|
200
|
+
const known = files ? new Set(files) : null;
|
|
201
|
+
return lists.map((ids) => ids.filter((id) => {
|
|
202
|
+
if (seen.has(id) || (known && !known.has(id))) {
|
|
203
|
+
return false;
|
|
204
|
+
}
|
|
205
|
+
seen.add(id);
|
|
206
|
+
return true;
|
|
207
|
+
}));
|
|
208
|
+
}
|
|
209
|
+
/** The sections as stored: each file in its first section only, ids not known to `files` left out. */
|
|
210
|
+
export function cleanLogoSections(sections, files) {
|
|
211
|
+
const lists = uniqueFiles(sections.map((s) => s.logos), files);
|
|
212
|
+
return sections.map((s, i) => ({ ...s, logos: lists[i] }));
|
|
213
|
+
}
|
|
214
|
+
export function cleanAssetSections(sections, files) {
|
|
215
|
+
const lists = uniqueFiles(sections.map((s) => s.assets), files);
|
|
216
|
+
return sections.map((s, i) => ({ ...s, assets: lists[i] }));
|
|
217
|
+
}
|
|
82
218
|
// --- files -----------------------------------------------------------------------
|
|
83
|
-
export const PROJECT_FILE_KINDS = ["logo", "asset", "document"];
|
|
219
|
+
export const PROJECT_FILE_KINDS = ["logo", "asset", "document", "pattern"];
|
|
84
220
|
export const PROJECT_LIMITS = {
|
|
85
221
|
facts: 100,
|
|
86
|
-
colors:
|
|
87
|
-
|
|
88
|
-
|
|
222
|
+
colors: 32,
|
|
223
|
+
fonts: 6,
|
|
224
|
+
textStyles: 16,
|
|
225
|
+
/** Sections of logos, and of colours, each. */
|
|
226
|
+
logoSections: 8,
|
|
227
|
+
/** Rows of logo rules. */
|
|
228
|
+
logoRules: 16,
|
|
229
|
+
files: { logo: 24, asset: 100, document: 2000, pattern: 24 },
|
|
230
|
+
gradients: 24,
|
|
231
|
+
bytes: {
|
|
232
|
+
logo: 5_000_000,
|
|
233
|
+
asset: 15_000_000,
|
|
234
|
+
video: 80_000_000,
|
|
235
|
+
document: 30_000_000,
|
|
236
|
+
pattern: 10_000_000,
|
|
237
|
+
},
|
|
89
238
|
};
|
|
90
239
|
/** The largest file of a kind and type a project takes. */
|
|
91
240
|
export function projectFileLimit(kind, mime) {
|
|
@@ -32,8 +32,8 @@ export declare const manifestSchema: z.ZodObject<{
|
|
|
32
32
|
name: z.ZodString;
|
|
33
33
|
domain: z.ZodOptional<z.ZodString>;
|
|
34
34
|
sourceKind: z.ZodOptional<z.ZodEnum<{
|
|
35
|
-
openapi: "openapi";
|
|
36
35
|
mcp: "mcp";
|
|
36
|
+
openapi: "openapi";
|
|
37
37
|
}>>;
|
|
38
38
|
}, z.core.$strip>>>;
|
|
39
39
|
mcpServers: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wizards",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.7",
|
|
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.",
|
|
5
5
|
"license": "FSL-1.1-MIT",
|
|
6
6
|
"homepage": "https://engenty.ai",
|
|
@@ -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}from"./logo-C4V2_3Ar.js";import{t as i}from"./preload-helper-CNEI7N0N.js";import{Ct as a,Dt as o,Tt as s,Zt as c,bt as l,ft as u,ht as d,jt as f,kt as p,mt as m,nn as h,pt as g}from"./ui-CMdSOoUZ.js";import{B as _,Q as v,V as y}from"./index-Bdx1Qity.js";import{c as b,f as x}from"./settings-menu-BOOPxcJH.js";import{ReleaseNotes as S,loadReleases as C,releaseDate as w,releaseLabel as T}from"./ChangelogDialog-VEBTlC3f.js";var E=e(t(),1),D=[{name:`engenty wizards`,description:{de:`KI-Wizards aus einer Beschreibung, mit einem Link geteilt.`,en:`AI wizards built from a description, shared with a link.`},homepage:`https://github.com/engenty/wizards`,license:`FSL-1.1-MIT`},{name:`engenty`,description:{de:`Konnektoren, Datentabellen, Suche und die Engenties stammen aus dem engenty-Framework.`,en:`Connectors, data tables, search and the engenties come from the engenty framework.`},homepage:`https://github.com/engenty/engenty`,license:`FSL-1.1-MIT`}],O=[{name:`Mastra`,description:{de:`Agent-Framework hinter den KI-Schritten.`,en:`Agent framework behind the AI steps.`},homepage:`https://github.com/mastra-ai/mastra`,license:`Apache-2.0`},{name:`AI SDK`,description:{de:`Modell-Aufrufe für Text, Bild, Video und Sprache.`,en:`Model calls for text, image, video and speech.`},homepage:`https://github.com/vercel/ai`,license:`Apache-2.0`},{name:`Model Context Protocol`,description:{de:`MCP-Server zum Bauen von Wizards, MCP-Client für Werkzeuge der Schritte.`,en:`MCP server for building wizards, MCP client for the steps' tools.`},homepage:`https://github.com/modelcontextprotocol/typescript-sdk`,license:`MIT`},{name:`Hono`,description:{de:`HTTP-API der Runtime.`,en:`The runtime's HTTP API.`},homepage:`https://github.com/honojs/hono`,license:`MIT`},{name:`Drizzle ORM`,description:{de:`Schema und Migrationen der Datenbanken.`,en:`Schema and migrations of the databases.`},homepage:`https://github.com/drizzle-team/drizzle-orm`,license:`Apache-2.0`},{name:`libSQL`,description:{de:`Eine Datenbank je Mandant, lokal als Datei oder bei Turso.`,en:`One database per tenant, a local file or at Turso.`},homepage:`https://github.com/tursodatabase/libsql`,license:`MIT`},{name:`Playwright`,description:{de:`Browser-Schritte sowie PDF- und PNG-Export.`,en:`Browser steps and the PDF and PNG export.`},homepage:`https://github.com/microsoft/playwright`,license:`Apache-2.0`},{name:`agentOS`,description:{de:`Sandbox für Code-Schritte ohne Docker.`,en:`Sandbox for code steps without Docker.`},homepage:`https://github.com/rivet-dev/agentos`,license:`Apache-2.0`},{name:`React`,description:{de:`UI-Bibliothek der Web-App.`,en:`UI library of the web app.`},homepage:`https://github.com/facebook/react`,license:`MIT`},{name:`Vite`,description:{de:`Build-Werkzeug der Web-App.`,en:`Build tool of the web app.`},homepage:`https://github.com/vitejs/vite`,license:`MIT`},{name:`Tailwind CSS`,description:{de:`Styling der Oberfläche.`,en:`Styling of the interface.`},homepage:`https://github.com/tailwindlabs/tailwindcss`,license:`MIT`},{name:`React Flow`,description:{de:`Das Diagramm der Schritte im Editor.`,en:`The diagram of steps in the editor.`},homepage:`https://github.com/xyflow/xyflow`,license:`MIT`},{name:`TanStack Query`,description:{de:`Server-Daten in der Web-App.`,en:`Server data in the web app.`},homepage:`https://github.com/TanStack/query`,license:`MIT`},{name:`xterm.js`,description:{de:`Das Terminal auf der Seite, in dem sich KI-Clients anmelden.`,en:`The terminal on the page where AI clients sign in.`},homepage:`https://github.com/xtermjs/xterm.js`,license:`MIT`},{name:`Lucide`,description:{de:`Icons.`,en:`Icons.`},homepage:`https://github.com/lucide-icons/lucide`,license:`ISC`},{name:`Geist & Geist Mono`,description:{de:`Schrift der Oberfläche.`,en:`Typeface of the interface.`},homepage:`https://github.com/vercel/geist-font`,license:`OFL-1.1`},{name:`Space Grotesk`,description:{de:`Schrift der Überschriften.`,en:`Typeface of the headings.`},homepage:`https://github.com/floriankarsten/space-grotesk`,license:`OFL-1.1`},{name:`git-cliff`,description:{de:`Erzeugt den Changelog aus den Commits.`,en:`Generates the changelog from the commits.`},homepage:`https://github.com/orhun/git-cliff`,license:`MIT OR Apache-2.0`}],k=e(n(),1),A=(e,...t)=>t.some(t=>t?.toLowerCase().includes(e));function j({name:e,homepage:t,version:n,license:r,description:i}){return(0,k.jsxs)(`li`,{className:`py-2.5`,children:[(0,k.jsxs)(`div`,{className:`flex flex-wrap items-baseline gap-x-2.5 gap-y-0.5`,children:[t?(0,k.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,k.jsx)(c,{"aria-hidden":!0,className:`size-3 text-ink-4`})]}):(0,k.jsx)(`span`,{className:`font-medium text-[0.875rem] text-ink`,children:e}),n?(0,k.jsx)(`span`,{className:`text-[0.75rem] text-ink-3 tabular-nums`,children:n}):null,(0,k.jsx)(`span`,{className:`text-[0.75rem] text-ink-3`,children:r})]}),i?(0,k.jsx)(`p`,{className:`mt-0.5 text-[0.8125rem] text-ink-3`,children:i}):null]})}function M({title:e,hint:t,children:n}){return(0,k.jsxs)(`section`,{className:`mt-6`,children:[(0,k.jsx)(`h3`,{className:`border-border-soft border-b pb-2 font-display font-semibold text-[1rem]`,children:e}),t?(0,k.jsx)(`p`,{className:`mt-2 text-[0.8125rem] text-ink-3`,children:t}):null,n]})}function N({credits:e}){return(0,k.jsx)(`ul`,{className:`divide-y divide-border-soft`,children:e.map(e=>(0,k.jsx)(j,{name:e.name,homepage:e.homepage,license:e.license,description:e.description[o]},e.name))})}function P({label:e,packages:t}){return(0,k.jsxs)(`div`,{className:`mt-4`,children:[(0,k.jsx)(`h4`,{className:`font-medium text-[0.75rem] text-ink-3 tracking-wide`,children:e}),(0,k.jsx)(`ul`,{className:`divide-y divide-border-soft`,children:t.map(e=>(0,k.jsx)(j,{...e},e.name))})]})}function F({active:e}){let[t,n]=(0,E.useState)(null),[r,a]=(0,E.useState)(``);(0,E.useEffect)(()=>{if(!e||t)return;let r=!1;return i(()=>import(`./oss-credits-BQQX0kvk.js`).then(e=>{r||n(e.default)}),[]),()=>{r=!0}},[e,t]),(0,E.useEffect)(()=>{e||a(``)},[e]);let o=r.trim().toLowerCase(),s=e=>o?e.filter(e=>A(o,e.name,e.license,e.description.de,e.description.en)):e,c=e=>o?e.filter(e=>A(o,e.name,e.license,e.version)):e,u=s(D),f=s(O),m=t?[{id:`shared`,label:p(`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):[],h=u.length===0&&f.length===0&&m.length===0;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(`p`,{className:`mb-4 text-[0.875rem] text-ink-3`,children:p(`about.creditsHint`)}),(0,k.jsx)(d,{type:`search`,value:r,placeholder:p(`about.search`),onChange:e=>a(e.target.value)}),u.length>0?(0,k.jsx)(M,{title:p(`about.creditsProduct`),children:(0,k.jsx)(N,{credits:u})}):null,f.length>0?(0,k.jsx)(M,{title:p(`about.creditsBuiltWith`),children:(0,k.jsx)(N,{credits:f})}):null,t===null?(0,k.jsx)(`div`,{className:`flex justify-center py-10 text-ink-3`,children:(0,k.jsx)(l,{})}):m.length>0?(0,k.jsx)(M,{title:p(`about.creditsDeps`),hint:o?void 0:p(`about.creditsDepsHint`),children:m.map(e=>(0,k.jsx)(P,{label:e.label,packages:e.packages},e.id))}):null,t!==null&&h?(0,k.jsx)(g,{children:p(`about.noMatches`)}):null]})}var I=[`new`,`earlier`,`credits`],L=e=>p(e===`new`?`about.tab.new`:e===`earlier`?`about.tab.earlier`:`about.credits`),R=e=>e===1?p(`about.change`):p(`about.changes`,{n:e});function z({open:e,onClose:t,me:n}){let i=n?.mode===`local`,{data:o,latest:c}=y(i&&e),[d,g]=(0,E.useState)(null),[D,O]=(0,E.useState)(`new`),A=x(I.indexOf(D)),j=o?.newer&&c?c:v;(0,E.useEffect)(()=>{if(!e)return;let t=!1;return g(null),C(j===`0.3.5`?void 0:j).then(e=>{t||g(e)}),()=>{t=!0}},[e,j]);let M=d?.find(e=>e.version===`v${j}`)??d?.[0]??null,N=d?.filter(e=>e!==M)??[],P=i?o?.kind??null:`cloud`;return(0,k.jsxs)(u,{open:e,onClose:t,wide:!0,height:`tall`,children:[(0,k.jsx)(`div`,{className:`-mt-2 -mr-2 sticky top-0 z-10 flex h-0 justify-end`,children:(0,k.jsx)(m,{label:p(`common.close`),onClick:t,children:(0,k.jsx)(f,{className:`size-4`})})}),(0,k.jsxs)(`div`,{className:`flex flex-col items-center pt-4 text-center`,children:[(0,k.jsx)(r,{size:96}),(0,k.jsxs)(`div`,{className:`mt-4 font-display font-semibold text-[1.5rem] tracking-tight`,children:[`engenty`,(0,k.jsx)(`span`,{className:`text-ember`,children:`.`}),(0,k.jsx)(`span`,{className:`ml-1.5 font-normal text-ink-3`,children:`wizards`})]}),(0,k.jsxs)(`div`,{className:`mt-1 text-[0.9375rem] text-ink-3 tabular-nums`,children:[p(`about.version`,{v}),P?` · ${p(`about.kind.${P}`)}`:``]})]}),i?(0,k.jsx)(`div`,{className:`mt-5`,children:(0,k.jsx)(_,{enabled:e})}):null,(0,k.jsx)(`div`,{className:`mt-6 flex justify-center`,children:(0,k.jsx)(a,{value:D,onChange:O,options:I.map(e=>({id:e,label:L(e)})),label:p(`about.title`)})}),(0,k.jsxs)(`div`,{className:s(`mt-5`,b(A)),children:[D===`new`?d===null?(0,k.jsx)(`div`,{className:`flex justify-center py-6 text-ink-3`,children:(0,k.jsx)(l,{})}):M?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(`h3`,{className:`flex items-baseline gap-3 border-border-soft border-b pb-2 font-display font-semibold text-[1rem]`,children:[T(M),(0,k.jsx)(`span`,{className:`font-normal font-sans text-[0.8125rem] text-ink-3 tabular-nums`,children:w(M)})]}),(0,k.jsx)(`div`,{className:`mt-3`,children:(0,k.jsx)(S,{release:M})})]}):(0,k.jsx)(`p`,{className:`text-[0.875rem] text-ink-3`,children:p(`about.changelogEmpty`)}):null,D===`earlier`?(0,k.jsx)(`div`,{className:`flex flex-col divide-y divide-border-soft`,children:N.map(e=>(0,k.jsxs)(`details`,{className:`group/r py-2`,children:[(0,k.jsxs)(`summary`,{className:`flex cursor-pointer list-none items-baseline gap-3 text-[0.875rem] [&::-webkit-details-marker]:hidden`,children:[(0,k.jsx)(h,{className:`size-3.5 shrink-0 self-center text-ink-4 transition group-open/r:rotate-90`}),(0,k.jsx)(`span`,{className:`font-medium text-ink tabular-nums`,children:T(e)}),(0,k.jsx)(`span`,{className:`text-[0.8125rem] text-ink-3 tabular-nums`,children:w(e)}),(0,k.jsx)(`span`,{className:`ml-auto text-[0.8125rem] text-ink-4`,children:R(e.commits.length)})]}),(0,k.jsx)(`div`,{className:`mt-2 pl-6`,children:(0,k.jsx)(S,{release:e})})]},e.version??`unreleased`))}):null,D===`credits`?(0,k.jsx)(F,{active:!0}):null]},D)]})}export{z as AboutDialog};
|