@fragment-dev/cli 2026.6.5 → 2026.6.8-3
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 +2 -3
- package/dist/{chunk-EDVJM4CG.js → chunk-BUK3FVRS.js} +1 -1
- package/dist/{chunk-WBV5XJEX.js → chunk-UDV5USSB.js} +1 -1
- package/dist/commands/designer-mcp.js +1 -1
- package/dist/commands.js +2 -2
- package/dist/designer/server.js +10 -4
- package/dist/index.js +2 -2
- package/oclif.manifest.json +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -236,7 +236,7 @@ EXAMPLES
|
|
|
236
236
|
|
|
237
237
|
## `fragment designer-mcp`
|
|
238
238
|
|
|
239
|
-
|
|
239
|
+
Connect your LLM to the Fragment Schema designer (experimental)
|
|
240
240
|
|
|
241
241
|
```
|
|
242
242
|
USAGE
|
|
@@ -248,8 +248,7 @@ FLAGS
|
|
|
248
248
|
--host=<value> [default: 127.0.0.1] Host to bind the HTTP server on
|
|
249
249
|
|
|
250
250
|
DESCRIPTION
|
|
251
|
-
|
|
252
|
-
dashboard.
|
|
251
|
+
Connect your LLM to the Fragment Schema designer (experimental)
|
|
253
252
|
|
|
254
253
|
EXAMPLES
|
|
255
254
|
$ fragment designer-mcp
|
|
@@ -16,7 +16,7 @@ var import_core = __toESM(require_lib(), 1);
|
|
|
16
16
|
var import_chalk = __toESM(require_source(), 1);
|
|
17
17
|
var DesignerMcp = class _DesignerMcp extends FragmentCommand {
|
|
18
18
|
static {
|
|
19
|
-
this.description = "
|
|
19
|
+
this.description = "Connect your LLM to the Fragment Schema designer (experimental)";
|
|
20
20
|
}
|
|
21
21
|
static {
|
|
22
22
|
this.examples = [
|
package/dist/commands.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
COMMANDS
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-BUK3FVRS.js";
|
|
4
4
|
import "./chunk-6OHUBHOM.js";
|
|
5
5
|
import "./chunk-4GFUVXOU.js";
|
|
6
6
|
import "./chunk-KWPWX7YO.js";
|
|
@@ -37,7 +37,7 @@ import "./chunk-TUJDC72W.js";
|
|
|
37
37
|
import "./chunk-IDKZFORS.js";
|
|
38
38
|
import "./chunk-LUXIPN36.js";
|
|
39
39
|
import "./chunk-JSQLWL2J.js";
|
|
40
|
-
import "./chunk-
|
|
40
|
+
import "./chunk-UDV5USSB.js";
|
|
41
41
|
import "./chunk-THGLXMNF.js";
|
|
42
42
|
import "./chunk-QG5ISRA6.js";
|
|
43
43
|
import "./chunk-O7AE4SQS.js";
|
package/dist/designer/server.js
CHANGED
|
@@ -216,10 +216,10 @@ var require_lib2 = __commonJS({
|
|
|
216
216
|
function isString(s) {
|
|
217
217
|
return typeof s === "string" || s instanceof String;
|
|
218
218
|
}
|
|
219
|
-
function
|
|
219
|
+
function isOriginAllowed2(origin, allowedOrigin) {
|
|
220
220
|
if (Array.isArray(allowedOrigin)) {
|
|
221
221
|
for (var i = 0; i < allowedOrigin.length; ++i) {
|
|
222
|
-
if (
|
|
222
|
+
if (isOriginAllowed2(origin, allowedOrigin[i])) {
|
|
223
223
|
return true;
|
|
224
224
|
}
|
|
225
225
|
}
|
|
@@ -249,7 +249,7 @@ var require_lib2 = __commonJS({
|
|
|
249
249
|
value: "Origin"
|
|
250
250
|
}]);
|
|
251
251
|
} else {
|
|
252
|
-
isAllowed =
|
|
252
|
+
isAllowed = isOriginAllowed2(requestOrigin, options.origin);
|
|
253
253
|
headers.push([{
|
|
254
254
|
key: "Access-Control-Allow-Origin",
|
|
255
255
|
value: isAllowed ? requestOrigin : false
|
|
@@ -12775,13 +12775,18 @@ var StreamableHTTPServerTransport = class {
|
|
|
12775
12775
|
|
|
12776
12776
|
// src/designer/server.ts
|
|
12777
12777
|
var LOCALHOST_REGEX = /^https?:\/\/(localhost|127\.0\.0\.1|([a-z0-9-]+\.)*fragment\.localhost)(:\d+)?$/;
|
|
12778
|
+
var FRAGMENT_DASHBOARD_ORIGINS = /* @__PURE__ */ new Set([
|
|
12779
|
+
"https://dashboard.fragment.dev",
|
|
12780
|
+
"https://dashboard.engineering.fragment.dev"
|
|
12781
|
+
]);
|
|
12782
|
+
var isOriginAllowed = (origin, extraOrigins = []) => LOCALHOST_REGEX.test(origin) || FRAGMENT_DASHBOARD_ORIGINS.has(origin) || extraOrigins.includes(origin);
|
|
12778
12783
|
var buildCorsOptions = (allowedOrigins = []) => ({
|
|
12779
12784
|
origin: (origin, cb) => {
|
|
12780
12785
|
if (!origin) {
|
|
12781
12786
|
cb(null, true);
|
|
12782
12787
|
return;
|
|
12783
12788
|
}
|
|
12784
|
-
if (
|
|
12789
|
+
if (isOriginAllowed(origin, allowedOrigins)) {
|
|
12785
12790
|
cb(null, true);
|
|
12786
12791
|
return;
|
|
12787
12792
|
}
|
|
@@ -13142,6 +13147,7 @@ export {
|
|
|
13142
13147
|
computeSchemaConflict,
|
|
13143
13148
|
getMcpClientKey,
|
|
13144
13149
|
getMcpClientPresence,
|
|
13150
|
+
isOriginAllowed,
|
|
13145
13151
|
startDesignerMcpServer
|
|
13146
13152
|
};
|
|
13147
13153
|
/*! Bundled license information:
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
COMMANDS
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-BUK3FVRS.js";
|
|
4
4
|
import "./chunk-6OHUBHOM.js";
|
|
5
5
|
import "./chunk-4GFUVXOU.js";
|
|
6
6
|
import "./chunk-KWPWX7YO.js";
|
|
@@ -37,7 +37,7 @@ import "./chunk-TUJDC72W.js";
|
|
|
37
37
|
import "./chunk-IDKZFORS.js";
|
|
38
38
|
import "./chunk-LUXIPN36.js";
|
|
39
39
|
import "./chunk-JSQLWL2J.js";
|
|
40
|
-
import "./chunk-
|
|
40
|
+
import "./chunk-UDV5USSB.js";
|
|
41
41
|
import {
|
|
42
42
|
require_lib
|
|
43
43
|
} from "./chunk-THGLXMNF.js";
|
package/oclif.manifest.json
CHANGED
|
@@ -777,7 +777,7 @@
|
|
|
777
777
|
"designer-mcp": {
|
|
778
778
|
"aliases": [],
|
|
779
779
|
"args": {},
|
|
780
|
-
"description": "
|
|
780
|
+
"description": "Connect your LLM to the Fragment Schema designer (experimental)",
|
|
781
781
|
"examples": [
|
|
782
782
|
"<%= config.bin %> <%= command.id %>",
|
|
783
783
|
"<%= config.bin %> <%= command.id %> --port 4321",
|
|
@@ -1023,5 +1023,5 @@
|
|
|
1023
1023
|
"help": "Generate GraphQL queries from your Schema for your SDK."
|
|
1024
1024
|
}
|
|
1025
1025
|
},
|
|
1026
|
-
"version": "2026.6.
|
|
1026
|
+
"version": "2026.6.8-3"
|
|
1027
1027
|
}
|