@jxsuite/protocol 0.4.0 → 0.5.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/package.json +2 -2
- package/src/routes.ts +29 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jxsuite/protocol",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "The Studio Backend Protocol — wire types and the canonical route table every Jx Studio backend implements",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -25,6 +25,6 @@
|
|
|
25
25
|
"test:coverage": "bun test --isolate --coverage"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@jxsuite/schema": "^1.
|
|
28
|
+
"@jxsuite/schema": "^1.1.0"
|
|
29
29
|
}
|
|
30
30
|
}
|
package/src/routes.ts
CHANGED
|
@@ -75,9 +75,19 @@ export const STUDIO_ROUTES = {
|
|
|
75
75
|
"Starter templates (StarterInfo[])",
|
|
76
76
|
"The New Project picker offers only blank/templates.",
|
|
77
77
|
),
|
|
78
|
+
importSite: route(
|
|
79
|
+
"POST",
|
|
80
|
+
"/__studio/import-site",
|
|
81
|
+
"Clone a live website into a project; streams NDJSON progress",
|
|
82
|
+
"The New Project Import tab is unavailable.",
|
|
83
|
+
),
|
|
78
84
|
|
|
79
85
|
// ─── Filesystem ───────────────────────────────────────────────────────────
|
|
80
|
-
files: route(
|
|
86
|
+
files: route(
|
|
87
|
+
"GET",
|
|
88
|
+
"/__studio/files",
|
|
89
|
+
"List a directory (DirEntry[]); with ?glob=<pattern>, search matching files project-wide",
|
|
90
|
+
),
|
|
81
91
|
fileRead: route("GET", "/__studio/file", "Read a file's text content"),
|
|
82
92
|
fileWrite: route("PUT", "/__studio/file", "Write a file's text content"),
|
|
83
93
|
fileDelete: route("DELETE", "/__studio/file", "Delete a file"),
|
|
@@ -133,6 +143,24 @@ export const STUDIO_ROUTES = {
|
|
|
133
143
|
"Extract a $studio schema from a class source",
|
|
134
144
|
"Plugin property panels fall back to generic JSON editing.",
|
|
135
145
|
),
|
|
146
|
+
codeFormat: route(
|
|
147
|
+
"POST",
|
|
148
|
+
"/__studio/code/format",
|
|
149
|
+
"Format posted source {code, path?} → {code, errors}",
|
|
150
|
+
"Code editors skip format-on-open/save (codeService returns null).",
|
|
151
|
+
),
|
|
152
|
+
codeMinify: route(
|
|
153
|
+
"POST",
|
|
154
|
+
"/__studio/code/minify",
|
|
155
|
+
"Minify posted source {code} → {code}",
|
|
156
|
+
"Compiled-output minification is skipped.",
|
|
157
|
+
),
|
|
158
|
+
codeLint: route(
|
|
159
|
+
"POST",
|
|
160
|
+
"/__studio/code/lint",
|
|
161
|
+
"Lint posted source {code, path?} → {diagnostics}",
|
|
162
|
+
"Code editors show no lint markers.",
|
|
163
|
+
),
|
|
136
164
|
|
|
137
165
|
// ─── Packages ─────────────────────────────────────────────────────────────
|
|
138
166
|
packages: route("GET", "/__studio/packages", "List dependencies (PackageInfo[])"),
|