@legendapp/spark 0.0.1-next.3 → 0.0.1-next.5
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/README.md +1 -1
- package/camera.ts +13 -0
- package/customize.ts +2 -0
- package/html.ts +1 -0
- package/markdown.ts +1 -0
- package/package.json +34 -15
- package/patches/camera/react-native-nitro-image.patch +320 -0
- package/patches/camera/react-native-nitro-modules.patch +50 -0
- package/patches/camera/react-native-vision-camera.patch +2662 -0
- package/patches/camera/upstream.json +22 -0
- package/patches/dependencies.json +14 -0
- package/patches/react-native-enriched-html@1.1.1.patch +854 -0
- package/patches/react-native-enriched-markdown@1.1.1.patch +9261 -0
- package/postinstall.cjs +1 -0
- package/schema.json +104 -0
- package/skills/spark/SKILL.md +56 -0
- package/skills/spark/UPGRADING.md +246 -0
- package/ui-swipe.ts +1 -0
- package/vendor/node_modules/@legendapp/spark-ai/package.json +4 -4
- package/vendor/node_modules/@legendapp/spark-ai/src/invocation-command.cjs +11 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/invocation-command.d.cts +2 -0
- package/vendor/node_modules/@legendapp/spark-ai/src/invocations.ts +2 -19
- package/vendor/node_modules/@legendapp/spark-audio/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-auth-session/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-cli/dist/add-desktop.js +4 -4
- package/vendor/node_modules/@legendapp/spark-cli/dist/build.js +65 -11
- package/vendor/node_modules/@legendapp/spark-cli/dist/cli-arguments.js +2 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/commands.js +3 -2
- package/vendor/node_modules/@legendapp/spark-cli/dist/create.js +36 -13
- package/vendor/node_modules/@legendapp/spark-cli/dist/credentials.js +41 -26
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-ai.cjs +108 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-artifacts.js +315 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-cli.cjs +75 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-github.cjs +133 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-policy.cjs +102 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-provider.cjs +2 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/customize-worker.cjs +273 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/dependency-pins.js +157 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/dev-command.js +3 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/dev.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/enriched-html-pins.js +128 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/errors.js +100 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/examples.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/expo-dev-patch.cjs +30 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/expo-native.cjs +5 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/helpers.js +1 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/index.js +52 -7
- package/vendor/node_modules/@legendapp/spark-cli/dist/init-template.d.cts +1 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/js-runtime.cjs +96 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/json.js +16 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/migration-helpers.cjs +152 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/migration-helpers.d.cts +15 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/migrations.cjs +184 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/migrations.d.cts +16 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/native-patch-preflight.js +5 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/package-manager-config.js +41 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/package-manager.js +13 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/process.js +7 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/project-version.js +12 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/project.js +66 -30
- package/vendor/node_modules/@legendapp/spark-cli/dist/release.js +2 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/release.json +20 -20
- package/vendor/node_modules/@legendapp/spark-cli/dist/runtime-bootstrap.ps1 +87 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/runtime-bootstrap.sh +107 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/runtime-downloads.tsv +13 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/sdk-install.js +8 -3
- package/vendor/node_modules/@legendapp/spark-cli/dist/universal.cjs +2 -1
- package/vendor/node_modules/@legendapp/spark-cli/dist/upgrade.js +102 -0
- package/vendor/node_modules/@legendapp/spark-cli/dist/windows.js +1 -8
- package/vendor/node_modules/@legendapp/spark-cli/package.json +6 -4
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/.claude/skills/spark/SKILL.md +9 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/AGENTS.md +4 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/CLAUDE.md +4 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/README.md +15 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/blank-typescript/package.json +47 -3
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/.claude/skills/spark/SKILL.md +9 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/AGENTS.md +4 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/CLAUDE.md +4 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/README.md +15 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/universal/package.json +46 -3
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/.claude/skills/spark/SKILL.md +9 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/AGENTS.md +4 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/CLAUDE.md +4 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/README.md +15 -0
- package/vendor/node_modules/@legendapp/spark-cli/templates/windows/package.json +47 -3
- package/vendor/node_modules/@legendapp/spark-clipboard/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-codex/package.json +4 -4
- package/vendor/node_modules/@legendapp/spark-commands/package.json +6 -6
- package/vendor/node_modules/@legendapp/spark-context-menu/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-desktop-app/macos/RNDesktopApp.mm +14 -1
- package/vendor/node_modules/@legendapp/spark-desktop-app/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/contracts/menu.ts +6 -4
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/customize-hooks.ts +17 -0
- package/vendor/node_modules/@legendapp/spark-desktop-app/src/customize.ts +117 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/app.plugin.cjs +20 -1
- package/vendor/node_modules/@legendapp/spark-desktop-config/config.cjs +5 -2
- package/vendor/node_modules/@legendapp/spark-desktop-config/config.d.cts +14 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/customize-provider.cjs +16 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/customize.cjs +16 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/expo.cjs +1 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/native-patches.cjs +106 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/native-patches.d.cts +1 -0
- package/vendor/node_modules/@legendapp/spark-desktop-config/package.json +5 -4
- package/vendor/node_modules/@legendapp/spark-desktop-config/schema.json +104 -0
- package/vendor/node_modules/@legendapp/spark-desktop-host/SparkCustomize.mm +517 -0
- package/vendor/node_modules/@legendapp/spark-desktop-host/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-desktop-links/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/macos/RNDesktopShortcuts.mm +3 -1
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/macos/keyboard-manager/RNKeyboardManager.h +3 -0
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/macos/keyboard-manager/RNKeyboardManager.mm +1 -1
- package/vendor/node_modules/@legendapp/spark-desktop-shortcuts/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-desktop-windows/macos/window-manager/RNWindowManager.mm +44 -4
- package/vendor/node_modules/@legendapp/spark-desktop-windows/package.json +4 -4
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/api.ts +65 -26
- package/vendor/node_modules/@legendapp/spark-desktop-windows/src/macos-adapter.ts +8 -6
- package/vendor/node_modules/@legendapp/spark-documents/package.json +8 -8
- package/vendor/node_modules/@legendapp/spark-drag-drop/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-file-dialog/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-file-system/macos/SparkFileMutations.h +1 -0
- package/vendor/node_modules/@legendapp/spark-file-system/macos/SparkFileMutations.mm +11 -10
- package/vendor/node_modules/@legendapp/spark-file-system/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-global-shortcuts/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-html/package.json +24 -0
- package/vendor/node_modules/@legendapp/spark-html/src/Html.tsx +22 -0
- package/vendor/node_modules/@legendapp/spark-html/src/HtmlInput.tsx +102 -0
- package/vendor/node_modules/@legendapp/spark-html/src/index.ts +4 -0
- package/vendor/node_modules/@legendapp/spark-html/src/types.ts +4 -0
- package/vendor/node_modules/@legendapp/spark-markdown/package.json +24 -0
- package/vendor/node_modules/@legendapp/spark-markdown/src/Markdown.tsx +24 -0
- package/vendor/node_modules/@legendapp/spark-markdown/src/MarkdownInput.tsx +111 -0
- package/vendor/node_modules/@legendapp/spark-markdown/src/index.ts +4 -0
- package/vendor/node_modules/@legendapp/spark-message-dialog/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-native-menu/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-notifications/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-notifications/windows/SparkNotifications/SparkNotifications.h +16 -11
- package/vendor/node_modules/@legendapp/spark-processes/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-rich-text/package.json +18 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/components.tsx +52 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/index.ts +4 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/types.ts +24 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/useInputShortcuts.macos.ts +55 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/useInputShortcuts.ts +13 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/useInputValue.ts +14 -0
- package/vendor/node_modules/@legendapp/spark-rich-text/src/value.ts +16 -0
- package/vendor/node_modules/@legendapp/spark-secure-storage/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-settings/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-settings-ui/package.json +5 -5
- package/vendor/node_modules/@legendapp/spark-sqlite/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-system/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-tray/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-ui/macos/appkit-split-view/RNSidebarSplitViewComponent.mm +360 -35
- package/vendor/node_modules/@legendapp/spark-ui/macos/swipe-actions/RNSwipeActions.h +10 -0
- package/vendor/node_modules/@legendapp/spark-ui/macos/swipe-actions/RNSwipeActions.mm +422 -0
- package/vendor/node_modules/@legendapp/spark-ui/package.json +4 -3
- package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/SidebarSplitViewNativeComponent.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/appkit-split-view/index.tsx +30 -13
- package/vendor/node_modules/@legendapp/spark-ui/src/swipe-actions/SwipeActionsNativeComponent.ts +11 -0
- package/vendor/node_modules/@legendapp/spark-ui/src/swipe-actions/index.tsx +41 -0
- package/vendor/node_modules/@legendapp/spark-updates/package.json +3 -3
- package/vendor/node_modules/@legendapp/spark-webview/package.json +2 -2
- package/vendor/node_modules/@legendapp/spark-window-options/package.json +1 -1
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
const { createHash } = require("node:crypto");
|
|
2
|
+
const fs = require("node:fs");
|
|
3
|
+
const path = require("node:path");
|
|
4
|
+
const { createRequire } = require("node:module");
|
|
5
|
+
|
|
6
|
+
const cameraPackages = ["react-native-nitro-image", "react-native-vision-camera"];
|
|
7
|
+
|
|
8
|
+
function prepareNativePatches(root) {
|
|
9
|
+
const manifestFile = path.join(root, "package.json");
|
|
10
|
+
if (!fs.existsSync(manifestFile)) return {};
|
|
11
|
+
const app = JSON.parse(fs.readFileSync(manifestFile, "utf8"));
|
|
12
|
+
if (app.name !== "@legendapp/spark" && !app.dependencies?.["@legendapp/spark"] && !app.devDependencies?.["@legendapp/spark"]) return {};
|
|
13
|
+
const appRequire = createRequire(manifestFile);
|
|
14
|
+
let sparkFile;
|
|
15
|
+
try { sparkFile = appRequire.resolve("@legendapp/spark/package.json"); }
|
|
16
|
+
catch (error) { if (error.code === "MODULE_NOT_FOUND") return {}; throw error; }
|
|
17
|
+
const spark = JSON.parse(fs.readFileSync(sparkFile, "utf8"));
|
|
18
|
+
const directory = path.dirname(sparkFile);
|
|
19
|
+
const patchesRoot = spark.spark?.bundledModuleRoot
|
|
20
|
+
? path.join(directory, "patches") : path.resolve(__dirname, "../../patches");
|
|
21
|
+
const pins = {};
|
|
22
|
+
if (cameraPackages.some(name => spark.dependencies?.[name])) {
|
|
23
|
+
const cameraPins = JSON.parse(fs.readFileSync(path.join(patchesRoot, "camera/upstream.json"), "utf8"));
|
|
24
|
+
for (const name of ["react-native-nitro-modules", ...cameraPackages]) {
|
|
25
|
+
pins[name] = { ...cameraPins[name], patch: `camera/${name}.patch`,
|
|
26
|
+
requires: name === "react-native-vision-camera" ? ["react-native-nitro-modules", "react-native-nitro-image"] : ["react-native-nitro-modules"] };
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
const integrations = path.join(patchesRoot, "dependencies.json");
|
|
30
|
+
if (fs.existsSync(integrations)) Object.assign(pins, JSON.parse(fs.readFileSync(integrations, "utf8")));
|
|
31
|
+
const active = Object.keys(pins).filter(name => spark.dependencies?.[name]);
|
|
32
|
+
if (!active.length) return {};
|
|
33
|
+
const { parsePatch, applyPatch, reversePatch } = require("diff");
|
|
34
|
+
const queue = [appRequire, createRequire(sparkFile)];
|
|
35
|
+
const visited = new Set();
|
|
36
|
+
const packages = {};
|
|
37
|
+
for (const req of queue) {
|
|
38
|
+
for (const name of active) {
|
|
39
|
+
let file;
|
|
40
|
+
try { file = req.resolve(`${name}/package.json`); }
|
|
41
|
+
catch (error) {
|
|
42
|
+
if (error.code !== "MODULE_NOT_FOUND") throw error;
|
|
43
|
+
if (req === appRequire) continue;
|
|
44
|
+
throw new Error(`Spark needs ${name}@${pins[name].version}. Finish installing dependencies before native preparation.`);
|
|
45
|
+
}
|
|
46
|
+
if (!fs.existsSync(file)) throw new Error(`Spark needs ${name}@${pins[name].version}. Finish installing dependencies before native preparation.`);
|
|
47
|
+
const packageRoot = fs.realpathSync(path.dirname(file));
|
|
48
|
+
if (visited.has(packageRoot)) continue;
|
|
49
|
+
visited.add(packageRoot);
|
|
50
|
+
packages[name] = { root: packageRoot };
|
|
51
|
+
queue.push(createRequire(file));
|
|
52
|
+
const manifest = JSON.parse(fs.readFileSync(file, "utf8"));
|
|
53
|
+
const pin = pins[name];
|
|
54
|
+
if (manifest.version !== pin.version) throw new Error(`Spark needs ${name}@${pin.version}; found ${manifest.version}. Use the SDK's pinned dependency version.`);
|
|
55
|
+
const bytes = fs.readFileSync(path.join(patchesRoot, pin.patch));
|
|
56
|
+
const writes = [];
|
|
57
|
+
for (const patch of parsePatch(bytes.toString("utf8"))) {
|
|
58
|
+
const relative = patch.newFileName.replace(/^b\//, "");
|
|
59
|
+
const target = path.resolve(packageRoot, relative);
|
|
60
|
+
if (!target.startsWith(packageRoot + path.sep) || patch.newFileName === "/dev/null") throw new Error(`Invalid native patch target: ${relative}`);
|
|
61
|
+
let current = fs.existsSync(target) ? fs.readFileSync(target, "utf8") : "";
|
|
62
|
+
if (patch.oldFileName === "/dev/null") {
|
|
63
|
+
const next = applyPatch("", patch);
|
|
64
|
+
if (current === next) continue;
|
|
65
|
+
if (current !== "") throw new Error(`Cannot apply Spark's ${name} patch to ${relative}. Reinstall dependencies before retrying.`);
|
|
66
|
+
writes.push([target, next]);
|
|
67
|
+
continue;
|
|
68
|
+
}
|
|
69
|
+
if (relative === "package.json" && manifest.spark?.dependencyPatch) {
|
|
70
|
+
const original = JSON.parse(current);
|
|
71
|
+
delete original.spark.dependencyPatch;
|
|
72
|
+
delete original.spark.sdk;
|
|
73
|
+
delete original.spark.requires;
|
|
74
|
+
if (!Object.keys(original.spark).length) delete original.spark;
|
|
75
|
+
current = JSON.stringify(original, null, 2) + "\n";
|
|
76
|
+
}
|
|
77
|
+
if (applyPatch(current, reversePatch(patch)) !== false) continue;
|
|
78
|
+
const next = applyPatch(current, patch);
|
|
79
|
+
if (next === false) throw new Error(`Cannot apply Spark's ${name} patch to ${relative}. Reinstall dependencies before retrying.`);
|
|
80
|
+
writes.push([target, next]);
|
|
81
|
+
}
|
|
82
|
+
// Verify every file before writing; rename rather than mutate package-manager cache hardlinks.
|
|
83
|
+
for (const [target, next] of writes) {
|
|
84
|
+
fs.mkdirSync(path.dirname(target), { recursive: true });
|
|
85
|
+
const temporary = `${target}.spark-${process.pid}.tmp`;
|
|
86
|
+
fs.writeFileSync(temporary, next); fs.renameSync(temporary, target);
|
|
87
|
+
}
|
|
88
|
+
const patched = JSON.parse(fs.readFileSync(file, "utf8"));
|
|
89
|
+
patched.spark ??= {};
|
|
90
|
+
if (name !== "react-native-nitro-modules") {
|
|
91
|
+
patched.spark.sdk = true;
|
|
92
|
+
patched.spark.requires = pin.requires ?? [];
|
|
93
|
+
}
|
|
94
|
+
patched.spark.dependencyPatch = { schema: 1, version: pin.version,
|
|
95
|
+
patchHash: createHash("sha256").update(bytes).digest("hex"), upstreamIntegrity: pin.integrity };
|
|
96
|
+
const serialized = JSON.stringify(patched, null, 2) + "\n";
|
|
97
|
+
if (fs.readFileSync(file, "utf8") !== serialized) {
|
|
98
|
+
const temporary = `${file}.spark-${process.pid}.tmp`;
|
|
99
|
+
fs.writeFileSync(temporary, serialized); fs.renameSync(temporary, file);
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
return packages;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
module.exports = { prepareNativePatches };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export function prepareNativePatches(root: string): Record<string, { root: string }>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@legendapp/spark-desktop-config",
|
|
3
|
-
"version": "0.0.1-next.
|
|
3
|
+
"version": "0.0.1-next.5",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "app.plugin.cjs",
|
|
6
6
|
"files": [
|
|
@@ -11,10 +11,11 @@
|
|
|
11
11
|
],
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"expo-desktop-config-plugins": "1.2.0",
|
|
14
|
-
"@legendapp/spark-desktop-host": "0.0.1-next.
|
|
15
|
-
"@legendapp/spark-window-options": "0.0.1-next.
|
|
14
|
+
"@legendapp/spark-desktop-host": "0.0.1-next.5",
|
|
15
|
+
"@legendapp/spark-window-options": "0.0.1-next.5",
|
|
16
16
|
"@expo/config-plugins": "54.0.5",
|
|
17
|
-
"@expo/config-types": "54.0.10"
|
|
17
|
+
"@expo/config-types": "54.0.10",
|
|
18
|
+
"diff": "8.0.4"
|
|
18
19
|
},
|
|
19
20
|
"private": true
|
|
20
21
|
}
|
|
@@ -452,6 +452,110 @@
|
|
|
452
452
|
"extends": {
|
|
453
453
|
"const": "expo",
|
|
454
454
|
"description": "Compose desktop options onto the existing Expo configuration."
|
|
455
|
+
},
|
|
456
|
+
"customize": {
|
|
457
|
+
"oneOf": [
|
|
458
|
+
{
|
|
459
|
+
"const": false
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
"type": "object",
|
|
463
|
+
"additionalProperties": false,
|
|
464
|
+
"required": [
|
|
465
|
+
"repository",
|
|
466
|
+
"files"
|
|
467
|
+
],
|
|
468
|
+
"properties": {
|
|
469
|
+
"repository": {
|
|
470
|
+
"type": "string",
|
|
471
|
+
"pattern": "^[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+$"
|
|
472
|
+
},
|
|
473
|
+
"files": {
|
|
474
|
+
"type": "array",
|
|
475
|
+
"minItems": 1,
|
|
476
|
+
"items": {
|
|
477
|
+
"type": "string"
|
|
478
|
+
}
|
|
479
|
+
},
|
|
480
|
+
"tag": {
|
|
481
|
+
"type": "string"
|
|
482
|
+
},
|
|
483
|
+
"toolkitRepository": {
|
|
484
|
+
"type": "string"
|
|
485
|
+
},
|
|
486
|
+
"toolkitTag": {
|
|
487
|
+
"type": "string"
|
|
488
|
+
},
|
|
489
|
+
"ui": {
|
|
490
|
+
"enum": [
|
|
491
|
+
"default",
|
|
492
|
+
"custom"
|
|
493
|
+
],
|
|
494
|
+
"default": "default"
|
|
495
|
+
},
|
|
496
|
+
"provider": {
|
|
497
|
+
"oneOf": [
|
|
498
|
+
{
|
|
499
|
+
"type": "object",
|
|
500
|
+
"additionalProperties": false,
|
|
501
|
+
"required": [
|
|
502
|
+
"kind",
|
|
503
|
+
"endpoint",
|
|
504
|
+
"model"
|
|
505
|
+
],
|
|
506
|
+
"properties": {
|
|
507
|
+
"kind": {
|
|
508
|
+
"enum": [
|
|
509
|
+
"local",
|
|
510
|
+
"remote"
|
|
511
|
+
]
|
|
512
|
+
},
|
|
513
|
+
"endpoint": {
|
|
514
|
+
"type": "string"
|
|
515
|
+
},
|
|
516
|
+
"model": {
|
|
517
|
+
"type": "string",
|
|
518
|
+
"minLength": 1
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
},
|
|
522
|
+
{
|
|
523
|
+
"type": "object",
|
|
524
|
+
"additionalProperties": false,
|
|
525
|
+
"required": [
|
|
526
|
+
"kind",
|
|
527
|
+
"tool"
|
|
528
|
+
],
|
|
529
|
+
"properties": {
|
|
530
|
+
"kind": {
|
|
531
|
+
"const": "cli"
|
|
532
|
+
},
|
|
533
|
+
"tool": {
|
|
534
|
+
"enum": [
|
|
535
|
+
"codex",
|
|
536
|
+
"claude"
|
|
537
|
+
]
|
|
538
|
+
},
|
|
539
|
+
"model": {
|
|
540
|
+
"type": "string",
|
|
541
|
+
"minLength": 1
|
|
542
|
+
}
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
]
|
|
546
|
+
},
|
|
547
|
+
"sourceRoot": {
|
|
548
|
+
"type": "string",
|
|
549
|
+
"description": "Relative ancestor of the app project. files are relative to this source snapshot root."
|
|
550
|
+
},
|
|
551
|
+
"githubClientId": {
|
|
552
|
+
"type": "string",
|
|
553
|
+
"pattern": "^[A-Za-z0-9_]+$",
|
|
554
|
+
"description": "GitHub OAuth app client ID with device flow enabled."
|
|
555
|
+
}
|
|
556
|
+
}
|
|
557
|
+
}
|
|
558
|
+
]
|
|
455
559
|
}
|
|
456
560
|
},
|
|
457
561
|
"allOf": [
|