acrylblends 1.3.1 → 1.4.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/dist/index.d.ts +1 -1
- package/dist/index.js +14 -5
- package/dist/index.js.map +1 -1
- package/legacy/README.md +4 -1
- package/legacy/agent/858de7a1ad0b/src/app.ts +289 -0
- package/legacy/agent/858de7a1ad0b/src/routes.ts +145 -0
- package/legacy/agent/b96ba6e3598a/src/app.ts +285 -0
- package/legacy/agent/b96ba6e3598a/src/routes.ts +145 -0
- package/legacy/agent/ecbc84f1c1e5/src/app.ts +291 -0
- package/legacy/agent/ecbc84f1c1e5/src/routes.ts +145 -0
- package/legacy/blank/2447ac6d5d24/src/app.ts +61 -0
- package/legacy/blank/387f7e25aaeb/src/app.ts +81 -0
- package/legacy/blank/5b9f10e1ba5e/src/app.ts +61 -0
- package/legacy/blank/5f6dd8910c50/src/app.ts +152 -0
- package/legacy/blank/5f6dd8910c50/src/routes.ts +75 -0
- package/legacy/blank/a7e8f539ffee/src/app.ts +160 -0
- package/legacy/blank/a7e8f539ffee/src/routes.ts +75 -0
- package/legacy/blank/bdb9735e013b/src/app.ts +61 -0
- package/legacy/blank/c3be1d735b1a/src/app.ts +61 -0
- package/legacy/blank/c3be1d735b1a/src/routes.ts +18 -0
- package/legacy/blank/e04303a7f8dd/src/app.ts +61 -0
- package/legacy/chat/5120c4a9fa61/src/app.ts +157 -0
- package/legacy/chat/5120c4a9fa61/src/routes.ts +29 -0
- package/legacy/chat/d4464dfb3b04/src/app.ts +165 -0
- package/legacy/chat/d4464dfb3b04/src/routes.ts +29 -0
- package/legacy/frozen.json +7 -0
- package/legacy/layouts.json +146 -45
- package/legacy/nodejs/9d59115118c7/src/app.ts +150 -0
- package/legacy/nodejs/9d59115118c7/src/routes.ts +59 -0
- package/legacy/nodejs/a6a340b4d3a6/src/app.ts +158 -0
- package/legacy/nodejs/a6a340b4d3a6/src/routes.ts +59 -0
- package/legacy/notes/fb43a1c5f3b4/src/app.ts +165 -0
- package/legacy/notes/fb43a1c5f3b4/src/routes.ts +21 -0
- package/legacy/notes/fc3fe7c749d2/src/app.ts +157 -0
- package/legacy/notes/fc3fe7c749d2/src/routes.ts +21 -0
- package/legacy/todo/164274ffcf7f/src/app.ts +145 -0
- package/legacy/todo/164274ffcf7f/src/todo.ts +137 -0
- package/lib/cordis/door.d.ts +27 -6
- package/lib/cordis/door.js +40 -9
- package/package.json +1 -1
- package/plugins/acryl-door/src/cli/acryl.ts +7 -2
- package/plugins/acryl-door/src/host/door.ts +41 -3
- package/plugins/acryl-door/src/host/verbs.ts +3 -3
- package/plugins/extensions/index.ts +12 -6
- package/plugins/plugin-share/index.ts +99 -1
- package/plugins/plugin-share/publish.ts +17 -3
- package/plugins/plugin-share/pull-check.ts +2 -0
- package/plugins/plugin-share/pull-list.ts +71 -0
- package/plugins/showcase/cards.ts +162 -0
- package/plugins/showcase/index.ts +116 -0
- package/plugins/showcase/plugin.json +11 -0
- package/templates/agent/AGENTS.md +4 -0
- package/templates/agent/blend.yaml +3 -0
- package/templates/agent/src/app.ts +2 -0
- package/templates/agent/src/routes.ts +23 -5
- package/templates/agent/template.json +1 -0
- package/templates/agent/test/app.test.ts +26 -0
- /package/legacy/blank/{d6d371c9a65e → 2447ac6d5d24}/src/routes.ts +0 -0
- /package/legacy/blank/{5a91c558af22 → 387f7e25aaeb}/src/routes.ts +0 -0
- /package/legacy/blank/{b2cbb759c889 → 5b9f10e1ba5e}/src/routes.ts +0 -0
- /package/legacy/blank/{9c650cf52bf3 → bdb9735e013b}/src/routes.ts +0 -0
- /package/legacy/blank/{aea589283445 → e04303a7f8dd}/src/routes.ts +0 -0
package/dist/index.d.ts
CHANGED
|
@@ -163,7 +163,7 @@ export declare function libraryRoot(): string;
|
|
|
163
163
|
/** Every plugin in the library, by name. */
|
|
164
164
|
export declare function readLibrary(root?: string): Map<string, LibraryPlugin>;
|
|
165
165
|
/** The plugins to copy for `names`: each one after everything it requires, no duplicates. */
|
|
166
|
-
export declare function closure(names: readonly string[], library:
|
|
166
|
+
export declare function closure(names: readonly string[], library: ReadonlyMap<string, LibraryPlugin>): LibraryPlugin[];
|
|
167
167
|
/** Copy one library plugin's source into `<app>/plugins/<name>/`. Throws when that folder already exists. */
|
|
168
168
|
export declare function copyPlugin(plugin: LibraryPlugin, appDir: string, root?: string): string;
|
|
169
169
|
//#endregion
|
package/dist/index.js
CHANGED
|
@@ -2027,6 +2027,12 @@ const MOUNTED = [
|
|
|
2027
2027
|
name: "feedback",
|
|
2028
2028
|
local: "feedback",
|
|
2029
2029
|
needs: ["acryl-router"]
|
|
2030
|
+
},
|
|
2031
|
+
{
|
|
2032
|
+
name: "showcase",
|
|
2033
|
+
local: "showcase",
|
|
2034
|
+
needs: ["plugin-share"],
|
|
2035
|
+
after: "plugin-share"
|
|
2030
2036
|
}
|
|
2031
2037
|
];
|
|
2032
2038
|
/** A row, in either line ending: a file edited on Windows (or checked out with core.autocrlf) is still a Blend. */
|
|
@@ -3489,6 +3495,8 @@ function carriedCopies(dir) {
|
|
|
3489
3495
|
}
|
|
3490
3496
|
/** The plugins the frame's host layer mounts by path: any framed app carries them, and an app made before the frame gets them here. */
|
|
3491
3497
|
const HOST_PLUGINS = ["acryl-web-server", "acryl-page"];
|
|
3498
|
+
/** A library plugin a scaffold file imports: `from '../plugins/<name>/...'`. */
|
|
3499
|
+
const PLUGIN_IMPORT = /from '\.\.\/plugins\/([^/']+)\//gu;
|
|
3492
3500
|
/** The profile script the DSH-profile layout used; the host launcher replaced it, so an app upgraded from that layout drops it. */
|
|
3493
3501
|
const OLD_PROFILE_SCRIPT = "scripts/ide-profile.mjs";
|
|
3494
3502
|
/**
|
|
@@ -3572,13 +3580,14 @@ function planFrameStep(appDir, library, templateDirFor = templateDir) {
|
|
|
3572
3580
|
state: generatedState(existsSync(path) ? readText(path) : void 0, rows.appPlugins)
|
|
3573
3581
|
});
|
|
3574
3582
|
}
|
|
3575
|
-
const
|
|
3583
|
+
const imported = files.filter((file) => file.file.endsWith(".ts")).flatMap((file) => [...file.text.matchAll(PLUGIN_IMPORT)].map((match) => match[1]));
|
|
3584
|
+
const addedPlugins = closure([.../* @__PURE__ */ new Set([...HOST_PLUGINS, ...imported])].filter((plugin) => library.has(plugin)), library).map((plugin) => plugin.name).filter((plugin) => !existsSync(join(appDir, "plugins", plugin)));
|
|
3576
3585
|
const oldScript = join(appDir, OLD_PROFILE_SCRIPT);
|
|
3577
3586
|
const removeProfileScript = existsSync(oldScript) && GENERATED_MARKER.test(readText(oldScript).split("\n", 1)[0] ?? "");
|
|
3578
3587
|
const input = frameProfileInput(specs, name, rows.rows);
|
|
3579
3588
|
const profile = planIdeProfileWrite(appDir, input);
|
|
3580
3589
|
const conflicts = [...files.filter((file) => file.state === "conflict").map((file) => file.file), ...profile.files.filter((file) => file.state === "conflict").map((file) => file.file)];
|
|
3581
|
-
const changed = files.some((file) => file.state !== "same") || profile.manifestChanged || profile.files.some((file) => file.state !== "same") ||
|
|
3590
|
+
const changed = files.some((file) => file.state !== "same") || profile.manifestChanged || profile.files.some((file) => file.state !== "same") || addedPlugins.length > 0 || removeProfileScript;
|
|
3582
3591
|
return {
|
|
3583
3592
|
kind: "planned",
|
|
3584
3593
|
template,
|
|
@@ -3586,7 +3595,7 @@ function planFrameStep(appDir, library, templateDirFor = templateDir) {
|
|
|
3586
3595
|
profile,
|
|
3587
3596
|
files,
|
|
3588
3597
|
kept,
|
|
3589
|
-
|
|
3598
|
+
addedPlugins,
|
|
3590
3599
|
removeProfileScript,
|
|
3591
3600
|
conflicts,
|
|
3592
3601
|
...conflictLines === void 0 ? {} : { conflictLines },
|
|
@@ -3603,7 +3612,7 @@ function frameReport(frame) {
|
|
|
3603
3612
|
for (const file of frame.files) if (file.state !== "same") parts.push(`${file.file} ${file.state === "update" ? "updated" : "added"}`);
|
|
3604
3613
|
for (const file of frame.profile.files) if (file.state !== "same") parts.push(`${file.file} ${file.state === "update" ? "updated" : "added"}`);
|
|
3605
3614
|
if (frame.profile.clientRowsAdded.length > 0) parts.push(`scripts/ide-host.mjs client rows added (${frame.profile.clientRowsAdded.join(", ")})`);
|
|
3606
|
-
for (const plugin of frame.
|
|
3615
|
+
for (const plugin of frame.addedPlugins) parts.push(`plugins/${plugin} added`);
|
|
3607
3616
|
if (frame.removeProfileScript) parts.push(`${OLD_PROFILE_SCRIPT} removed`);
|
|
3608
3617
|
if (frame.profile.manifestChanged) parts.push("package.json merged (dev runs scripts/ide-host.mjs)");
|
|
3609
3618
|
for (const { file, mountable } of frame.kept) if (!mountable) parts.push(`${file} kept as the app's (edited): it does not export FRAME_MOUNT_PREFIX, so the frame cannot show the app until it does (a fresh app's ${file} shows how)`);
|
|
@@ -3777,7 +3786,7 @@ async function upgrade(options, io) {
|
|
|
3777
3786
|
cpSync(join(appDir, file.file), join(backup, file.file));
|
|
3778
3787
|
frameBackups += 1;
|
|
3779
3788
|
}
|
|
3780
|
-
for (const plugin of frame.
|
|
3789
|
+
for (const plugin of frame.addedPlugins) {
|
|
3781
3790
|
const known = library.get(plugin);
|
|
3782
3791
|
if (known === void 0) continue;
|
|
3783
3792
|
copyPlugin(known, appDir);
|