@qikdev/mcp 6.14.6 → 6.16.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/build/src/tools/campaign.d.ts.map +1 -1
- package/build/src/tools/campaign.js +6 -30
- package/build/src/tools/campaign.js.map +1 -1
- package/build/src/tools/checkin.d.ts.map +1 -1
- package/build/src/tools/checkin.js +5 -25
- package/build/src/tools/checkin.js.map +1 -1
- package/build/src/tools/content.d.ts.map +1 -1
- package/build/src/tools/content.js +4 -19
- package/build/src/tools/content.js.map +1 -1
- package/build/src/tools/create.d.ts.map +1 -1
- package/build/src/tools/create.js +2 -7
- package/build/src/tools/create.js.map +1 -1
- package/build/src/tools/definition.d.ts +20 -0
- package/build/src/tools/definition.d.ts.map +1 -1
- package/build/src/tools/definition.js +158 -55
- package/build/src/tools/definition.js.map +1 -1
- package/build/src/tools/duplicates.d.ts.map +1 -1
- package/build/src/tools/duplicates.js +3 -12
- package/build/src/tools/duplicates.js.map +1 -1
- package/build/src/tools/file.d.ts.map +1 -1
- package/build/src/tools/file.js +4 -18
- package/build/src/tools/file.js.map +1 -1
- package/build/src/tools/filters.d.ts.map +1 -1
- package/build/src/tools/filters.js +2 -6
- package/build/src/tools/filters.js.map +1 -1
- package/build/src/tools/form.d.ts.map +1 -1
- package/build/src/tools/form.js +2 -6
- package/build/src/tools/form.js.map +1 -1
- package/build/src/tools/glossary.d.ts.map +1 -1
- package/build/src/tools/glossary.js +5 -24
- package/build/src/tools/glossary.js.map +1 -1
- package/build/src/tools/interface-builder.d.ts.map +1 -1
- package/build/src/tools/interface-builder.js +236 -39
- package/build/src/tools/interface-builder.js.map +1 -1
- package/build/src/tools/list.d.ts.map +1 -1
- package/build/src/tools/list.js +2 -7
- package/build/src/tools/list.js.map +1 -1
- package/build/src/tools/merge.d.ts.map +1 -1
- package/build/src/tools/merge.js +4 -18
- package/build/src/tools/merge.js.map +1 -1
- package/build/src/tools/profile-access.d.ts.map +1 -1
- package/build/src/tools/profile-access.js +5 -24
- package/build/src/tools/profile-access.js.map +1 -1
- package/build/src/tools/profile-relationships.d.ts.map +1 -1
- package/build/src/tools/profile-relationships.js +5 -24
- package/build/src/tools/profile-relationships.js.map +1 -1
- package/build/src/tools/profile.d.ts.map +1 -1
- package/build/src/tools/profile.js +2 -6
- package/build/src/tools/profile.js.map +1 -1
- package/build/src/tools/relationships.d.ts.map +1 -1
- package/build/src/tools/relationships.js +3 -12
- package/build/src/tools/relationships.js.map +1 -1
- package/build/src/tools/reporting.d.ts.map +1 -1
- package/build/src/tools/reporting.js +3 -12
- package/build/src/tools/reporting.js.map +1 -1
- package/build/src/tools/scope.d.ts.map +1 -1
- package/build/src/tools/scope.js +5 -24
- package/build/src/tools/scope.js.map +1 -1
- package/build/src/tools/search.d.ts.map +1 -1
- package/build/src/tools/search.js +2 -6
- package/build/src/tools/search.js.map +1 -1
- package/build/src/tools/smartlist.d.ts.map +1 -1
- package/build/src/tools/smartlist.js +3 -12
- package/build/src/tools/smartlist.js.map +1 -1
- package/build/src/tools/sms.d.ts +1 -0
- package/build/src/tools/sms.d.ts.map +1 -1
- package/build/src/tools/sms.js +55 -6
- package/build/src/tools/sms.js.map +1 -1
- package/build/src/tools/update.d.ts.map +1 -1
- package/build/src/tools/update.js +2 -7
- package/build/src/tools/update.js.map +1 -1
- package/build/src/tools/user.d.ts.map +1 -1
- package/build/src/tools/user.js +2 -6
- package/build/src/tools/user.js.map +1 -1
- package/build/src/tools/utils.d.ts +1 -0
- package/build/src/tools/utils.d.ts.map +1 -1
- package/build/src/tools/utils.js +1 -0
- package/build/src/tools/utils.js.map +1 -1
- package/build/src/tools/workflow.d.ts.map +1 -1
- package/build/src/tools/workflow.js +2 -8
- package/build/src/tools/workflow.js.map +1 -1
- package/package.json +1 -1
package/build/src/tools/form.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ConfigManager } from "../config.js";
|
|
2
|
+
import { createErrorResponse } from "./utils.js";
|
|
2
3
|
// ============================================================================
|
|
3
4
|
// TOOL DEFINITIONS
|
|
4
5
|
// ============================================================================
|
|
@@ -125,12 +126,7 @@ export async function handleListForms(args) {
|
|
|
125
126
|
};
|
|
126
127
|
}
|
|
127
128
|
catch (error) {
|
|
128
|
-
return {
|
|
129
|
-
content: [{
|
|
130
|
-
type: "text",
|
|
131
|
-
text: `Failed to list forms: ${error.message}`
|
|
132
|
-
}]
|
|
133
|
-
};
|
|
129
|
+
return createErrorResponse(`Failed to list forms: ${error.message}`);
|
|
134
130
|
}
|
|
135
131
|
}
|
|
136
132
|
//# sourceMappingURL=form.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"form.js","sourceRoot":"","sources":["../../../src/tools/form.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"form.js","sourceRoot":"","sources":["../../../src/tools/form.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEjD,+EAA+E;AAC/E,mBAAmB;AACnB,+EAA+E;AAE/E,MAAM,CAAC,MAAM,aAAa,GAAS;IACjC,IAAI,EAAE,YAAY;IAClB,WAAW,EAAE;;;;;;;;;;;;;;;;6EAgB8D;IAC3E,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,MAAM,EAAE;gBACN,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,+CAA+C;aAC7D;YACD,IAAI,EAAE;gBACJ,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,qBAAqB;gBAClC,UAAU,EAAE;oBACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,8BAA8B,EAAE;oBACrE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,mCAAmC,EAAE;i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sB,2BAA2B,CAAC,cAAc,EAAE,MAAM,GAAG,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAsDrI;AAID,wBAAsB,wBAAwB,CAAC,IAAI,EAAE;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAoEnI;AAGD,eAAO,MAAM,YAAY;;;;;;;;;;;;;2CAAoB,CAAC;AAC9C,eAAO,MAAM,iBAAiB,+BAAyB,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ConfigManager } from "../config.js";
|
|
2
|
+
import { createErrorResponse } from "./utils.js";
|
|
2
3
|
// Tool for getting the lightweight index of all content types
|
|
3
4
|
export const glossaryIndexTool = {
|
|
4
5
|
name: "get_glossary",
|
|
@@ -74,12 +75,7 @@ export async function handleGetGlossaryIndex() {
|
|
|
74
75
|
};
|
|
75
76
|
}
|
|
76
77
|
catch (error) {
|
|
77
|
-
return
|
|
78
|
-
content: [{
|
|
79
|
-
type: "text",
|
|
80
|
-
text: JSON.stringify({ error: error.message }, null, 2)
|
|
81
|
-
}]
|
|
82
|
-
};
|
|
78
|
+
return createErrorResponse(error.message);
|
|
83
79
|
}
|
|
84
80
|
}
|
|
85
81
|
export async function handleGetContentTypeDetails(contentTypeKey) {
|
|
@@ -103,12 +99,7 @@ export async function handleGetContentTypeDetails(contentTypeKey) {
|
|
|
103
99
|
// Find the specific content type
|
|
104
100
|
const contentTypeInfo = indexData.find(ct => ct.key === contentTypeKey);
|
|
105
101
|
if (!contentTypeInfo) {
|
|
106
|
-
return {
|
|
107
|
-
content: [{
|
|
108
|
-
type: "text",
|
|
109
|
-
text: JSON.stringify({ error: `Content type '${contentTypeKey}' not found` }, null, 2)
|
|
110
|
-
}]
|
|
111
|
-
};
|
|
102
|
+
return createErrorResponse(`Content type '${contentTypeKey}' not found`);
|
|
112
103
|
}
|
|
113
104
|
// Now fetch the detailed documentation from the specific endpoint (URL is already absolute)
|
|
114
105
|
const detailResponse = await fetch(contentTypeInfo.urls.documentation.url, {
|
|
@@ -129,12 +120,7 @@ export async function handleGetContentTypeDetails(contentTypeKey) {
|
|
|
129
120
|
};
|
|
130
121
|
}
|
|
131
122
|
catch (error) {
|
|
132
|
-
return
|
|
133
|
-
content: [{
|
|
134
|
-
type: "text",
|
|
135
|
-
text: JSON.stringify({ error: error.message }, null, 2)
|
|
136
|
-
}]
|
|
137
|
-
};
|
|
123
|
+
return createErrorResponse(error.message);
|
|
138
124
|
}
|
|
139
125
|
}
|
|
140
126
|
// Handler for searching content types by natural language
|
|
@@ -194,12 +180,7 @@ export async function handleSearchContentTypes(args) {
|
|
|
194
180
|
};
|
|
195
181
|
}
|
|
196
182
|
catch (error) {
|
|
197
|
-
return
|
|
198
|
-
content: [{
|
|
199
|
-
type: "text",
|
|
200
|
-
text: JSON.stringify({ error: error.message }, null, 2)
|
|
201
|
-
}]
|
|
202
|
-
};
|
|
183
|
+
return createErrorResponse(error.message);
|
|
203
184
|
}
|
|
204
185
|
}
|
|
205
186
|
// Legacy export for backward compatibility
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glossary.js","sourceRoot":"","sources":["../../../src/tools/glossary.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"glossary.js","sourceRoot":"","sources":["../../../src/tools/glossary.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAkCjD,8DAA8D;AAC9D,MAAM,CAAC,MAAM,iB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AAED,2CAA2C;AAC3C,MAAM,CAAC,MAAM,YAAY,GAAG,iBAAiB,CAAC;AAC9C,MAAM,CAAC,MAAM,iBAAiB,GAAG,sBAAsB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interface-builder.d.ts","sourceRoot":"","sources":["../../../src/tools/interface-builder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,oCAAoC,CAAC;AAgB1D,UAAU,aAAa;IACrB,IAAI,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,CAAC;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,QAAQ;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,QAAQ,EAAE,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iBAAiB,CAAC,EAAE,GAAG,CAAC;CACzB;AAED,UAAU,UAAU;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd;AA+ZD,eAAO,MAAM,mBAAmB,EAAE,
|
|
1
|
+
{"version":3,"file":"interface-builder.d.ts","sourceRoot":"","sources":["../../../src/tools/interface-builder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,oCAAoC,CAAC;AAgB1D,UAAU,aAAa;IACrB,IAAI,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,CAAC;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE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AAG,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAmC9D;AAED,wBAAsB,sBAAsB,CAAC,IAAI,EAAE;IACjD,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,QAAQ,EAAE,CAAC;CACnB,GAAG,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CA2D9D;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE;IACnD,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,UAAU,EAAE,CAAC;CACvB,GAAG,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAiC9D;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE;IAAE,WAAW,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAAC;IAAE,OAAO,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAAE,CAAC,CAoBzJ"}
|
|
@@ -419,7 +419,8 @@ Build interfaces in this order for best results:
|
|
|
419
419
|
6. **Set layout** (\`set_interface_layout\`) — Optionally use a custom component as the page layout wrapper.
|
|
420
420
|
7. **Add routes** (\`add_interface_route\`) — Pages with paths. Use folders for grouping.
|
|
421
421
|
8. **Add sections** (\`add_interface_section\`) — Place marketplace components into routes/header/footer. Prefer dedicated components (Basic Text, Basic Image, Basic Form, Dynamic List, etc.) over Custom Code blocks.
|
|
422
|
-
|
|
422
|
+
|
|
423
|
+
**CRITICAL: Do NOT call \`publish_interface\` unless the user explicitly asks you to publish.** All changes are saved immediately and visible in the editor/preview without publishing. Publishing creates a frozen production snapshot — only do this when the user specifically requests it.
|
|
423
424
|
|
|
424
425
|
**IMPORTANT:** Always check \`list_interface_components\` for a suitable marketplace component before falling back to Custom Code. For example:
|
|
425
426
|
- Use **Basic Text** for rich text content, not Custom Code with HTML
|
|
@@ -484,7 +485,9 @@ Use \`sectionUuid\` to see full details for a specific section including its mod
|
|
|
484
485
|
};
|
|
485
486
|
export const publishInterfaceTool = {
|
|
486
487
|
name: "publish_interface",
|
|
487
|
-
description: `Publish an interface snapshot. Creates a frozen version that can be deployed.
|
|
488
|
+
description: `Publish an interface snapshot. Creates a frozen production version that can be deployed.
|
|
489
|
+
|
|
490
|
+
**CRITICAL:** Only call this tool when the user has EXPLICITLY asked to publish. Never call this as a follow-up to creating, updating, or modifying an interface. All changes are already saved and visible without publishing.
|
|
488
491
|
|
|
489
492
|
**Example:**
|
|
490
493
|
\`\`\`json
|
|
@@ -503,7 +506,7 @@ export const publishInterfaceTool = {
|
|
|
503
506
|
};
|
|
504
507
|
export const addInterfaceRouteTool = {
|
|
505
508
|
name: "add_interface_route",
|
|
506
|
-
description: `Add a route (page) to an interface. Always call \`get_interface\` first to see current routes.
|
|
509
|
+
description: `Add a route (page) to an interface. Always call \`get_interface\` first to see current routes. Do NOT publish after this — changes are saved automatically.
|
|
507
510
|
|
|
508
511
|
Routes can be nested inside folder-type routes using \`parentRouteName\`.
|
|
509
512
|
Dynamic segments use \`:param\` syntax (e.g., \`/article/:slug\`).
|
|
@@ -544,7 +547,7 @@ Dynamic segments use \`:param\` syntax (e.g., \`/article/:slug\`).
|
|
|
544
547
|
};
|
|
545
548
|
export const updateInterfaceRouteTool = {
|
|
546
549
|
name: "update_interface_route",
|
|
547
|
-
description: `Update a route's properties. Always call \`get_interface\` first to see current routes.
|
|
550
|
+
description: `Update a route's properties. Always call \`get_interface\` first to see current routes. Do NOT publish after this — changes are saved automatically.
|
|
548
551
|
|
|
549
552
|
**Example:**
|
|
550
553
|
\`\`\`json
|
|
@@ -584,7 +587,7 @@ export const updateInterfaceRouteTool = {
|
|
|
584
587
|
};
|
|
585
588
|
export const removeInterfaceRouteTool = {
|
|
586
589
|
name: "remove_interface_route",
|
|
587
|
-
description: `Remove a route from an interface. Always call \`get_interface\` first. All sections within the route will be lost.
|
|
590
|
+
description: `Remove a route from an interface. Always call \`get_interface\` first. All sections within the route will be lost. Do NOT publish after this — changes are saved automatically.
|
|
588
591
|
|
|
589
592
|
**Example:**
|
|
590
593
|
\`\`\`json
|
|
@@ -601,7 +604,7 @@ export const removeInterfaceRouteTool = {
|
|
|
601
604
|
};
|
|
602
605
|
export const addInterfaceSectionTool = {
|
|
603
606
|
name: "add_interface_section",
|
|
604
|
-
description: `Add a block component section to an interface. Always call \`get_interface\` first to see current structure.
|
|
607
|
+
description: `Add a block component section to an interface. Always call \`get_interface\` first to see current structure. Do NOT publish after this — changes are saved automatically.
|
|
605
608
|
|
|
606
609
|
This is the core building tool. Place a marketplace component as a section in the header, footer, a route, or nested inside another section's slot.
|
|
607
610
|
|
|
@@ -612,7 +615,7 @@ This is the core building tool. Place a marketplace component as a section in th
|
|
|
612
615
|
- \`"slot"\` - Nested inside another section's slot (requires \`sectionUuid\` and \`slotKey\`)
|
|
613
616
|
|
|
614
617
|
**Common block components:**
|
|
615
|
-
- Custom Code (\`62b5a2bc6343c2335f85946b\`) - model: { html, javascript, scss }
|
|
618
|
+
- Custom Code (\`62b5a2bc6343c2335f85946b\`) - model: { html, javascript, scss }. **All three values must be strings.** Do not pass objects or arrays — non-string values are silently dropped.
|
|
616
619
|
- Website Section (\`647d02f56348660726cc552d\`) - model: { outerClass, innerClass } - has slot "cells"
|
|
617
620
|
- Basic Div (\`64d86d3563ed2a77be372c9a\`) - has slot "content"
|
|
618
621
|
|
|
@@ -624,22 +627,134 @@ When writing HTML for Custom Code sections, prefer vue-ui components over raw HT
|
|
|
624
627
|
|
|
625
628
|
**IMPORTANT:** All HTML must be strictly valid. Self-closing tags MUST include the slash: \`<br/>\`, \`<hr/>\`, \`<img/>\`, etc. Never write \`<br>\` or \`<img>\`.
|
|
626
629
|
|
|
630
|
+
**IMPORTANT (SCSS Scoping):** Component SCSS is automatically scoped — the interface builder wraps your styles in a CSS class closure matching the mounted element. Do NOT wrap your styles in the component's root class name. Write styles as if you are already inside the root element. For example, if your HTML is \`<div class="hero"><h1>Title</h1><p class="subtitle">Text</p></div>\`, your SCSS should be:
|
|
631
|
+
\`\`\`
|
|
632
|
+
h1 { font-size: 3em; }
|
|
633
|
+
.subtitle { color: gray; }
|
|
634
|
+
\`\`\`
|
|
635
|
+
NOT:
|
|
636
|
+
\`\`\`
|
|
637
|
+
.hero { h1 { font-size: 3em; } .subtitle { color: gray; } }
|
|
638
|
+
\`\`\`
|
|
639
|
+
|
|
627
640
|
### Vue-UI Components (prefer over raw HTML where appropriate):
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
- \`<ux-
|
|
631
|
-
- \`<ux-
|
|
632
|
-
- \`<ux-
|
|
633
|
-
- \`<ux-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
- \`<
|
|
637
|
-
- \`<
|
|
638
|
-
- \`<ux-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
- \`<ux-
|
|
642
|
-
- \`<ux-
|
|
641
|
+
|
|
642
|
+
**Navigation & Actions:**
|
|
643
|
+
- \`<ux-link :to="{name:'routeName'}">Link</ux-link>\` - Navigation (NOT <a href>). Compiles to an inline \`<a>\` tag, so add \`display:block\` in CSS if you need block-level behavior.
|
|
644
|
+
- \`<ux-link :to="{name:'detail', params:{slug:item._id}}">...</ux-link>\` - Dynamic routes. Props: \`to\` (string|object), \`href\`, \`target\`, \`disabled\`, \`active\`.
|
|
645
|
+
- \`<ux-button color="primary" @click="method">Click</ux-button>\` - Buttons. Props: \`color\` ("primary"|"default"|"link"|"dismiss"), \`size\` ("xxs"|"xs"|"sm"|"md"|"lg"|"xl"|"xxl"), \`loading\`, \`disabled\`, \`active\`, \`block\`, \`icon\` (circular icon btn), \`to\` (router link), \`href\`, \`target\`, \`bgColor\`, \`fgColor\`.
|
|
646
|
+
- \`<ux-icon icon="fa-icon-name" />\` - Font Awesome icons. Props: \`icon\` (string, e.g. "fa-check", "far fa-copy"), \`spin\`, \`left\` (left margin), \`right\` (right margin), \`fixed\` (fixed width).
|
|
647
|
+
|
|
648
|
+
**Media:**
|
|
649
|
+
- \`<ux-image :item="imageRef" />\` - Images. Props: \`item\` (content object or ID), \`alt\`, \`width\`, \`height\`, \`contain\` (default true), \`cover\`, \`crop\`, \`preview\`, \`lazy\`, \`eager\`, \`quality\`, \`format\`, \`svg\`, \`auto\` (default true).
|
|
650
|
+
- \`<ux-video :item="videoRef" />\` - Videos. Props: \`item\`, \`width\`, \`height\`, \`controls\` (default true), \`autoplay\`, \`loop\`, \`muted\`, \`playsinline\`.
|
|
651
|
+
- \`<ux-avatar :id="profileId" :initials="{firstName, lastName}" />\` - Avatar with initials fallback. Props: \`id\`, \`initials\` (string or object), \`cacheKey\`.
|
|
652
|
+
|
|
653
|
+
**Feedback:**
|
|
654
|
+
- \`<ux-spinner large />\` - Loading spinner. Props: \`large\`. Size attributes: \`lg\`, \`xl\`, \`xxl\`.
|
|
655
|
+
- \`<ux-progress-bar :value="75" active />\` - Progress bar. Props: \`value\` (0-100), \`active\`.
|
|
656
|
+
- \`<ux-info type="success" icon="fa-check">Message</ux-info>\` - Info/alert box. Props: \`type\` ("success"|"warning"|"error"|"info"), \`icon\`.
|
|
657
|
+
- \`<ux-pill :value="{title:'Tag', color:'#fff', bgColor:'#333'}" deleteable />\` - Tag/pill. Props: \`value\` (object with title/name/color/bgColor), \`clickable\`, \`deleteable\`, \`icon\`.
|
|
658
|
+
|
|
659
|
+
**Layout:**
|
|
660
|
+
- \`<flex-row gap center vcenter wrap>\` + \`<flex-cell shrink>\` - Flex row. flex-row props: \`center\`, \`vcenter\`, \`gap\`, \`wrap\`. flex-cell props: \`flex\`, \`center\`, \`vcenter\`, \`alignBottom\`, \`shrink\` (flex: none).
|
|
661
|
+
- \`<flex-column>\` + \`<flex-header>\`, \`<flex-body>\`, \`<flex-footer>\` - Vertical flex column with scrollable body. flex-column props: \`center\`, \`shrink\`.
|
|
662
|
+
- \`<flex-spacer />\` - Expands to fill remaining space.
|
|
663
|
+
|
|
664
|
+
**Containers:**
|
|
665
|
+
- \`<ux-panel>\` + \`<ux-panel-header>\` + \`<ux-panel-body>\` + \`<ux-panel-footer>\` - Card/panel with border, rounded corners, shadow.
|
|
666
|
+
- \`<ux-lazy>\` - Lazy render wrapper (IntersectionObserver). Content only renders near viewport.
|
|
667
|
+
|
|
668
|
+
**Tabs:**
|
|
669
|
+
- \`<ux-tabset vertical inline pills>\` + \`<ux-tab heading="Tab 1" keepAlive>Content</ux-tab>\` - Tab container. tabset props: \`vertical\`, \`inline\`, \`pills\`. tab props: \`heading\`, \`tabKey\`, \`enabled\`, \`keepAlive\`.
|
|
670
|
+
|
|
671
|
+
**Forms:**
|
|
672
|
+
- \`<ux-form :fields="fields" v-model="model" flex />\` - Dynamic form renderer. Props: \`fields\` (array of field definitions), \`modelValue\` (v-model), \`flex\` (side-by-side layout), \`submission\`, \`sandbox\`, \`ignoreDefaults\`, \`includeOfficeOnly\`. Events: \`form:state\` ({dirty, error, touched, invalid, valid, invalidFields}), \`field:mount\`, \`field:dirty\`, \`field:valid\`, \`field:invalid\`, \`field:focus\`, \`field:blur\`. Methods (via ref): \`touch()\`, \`untouch()\`, \`reset()\`, \`getCurrentFormState()\`.
|
|
673
|
+
- \`<ux-form-field :field="fieldDef" v-model="model" />\` - Single form field. Props: \`field\` (field definition object), \`modelValue\` (v-model). CSS classes auto-applied: \`ux-field-touched\`, \`ux-field-dirty\`, \`ux-field-valid\`, \`ux-field-invalid\`, \`ux-field-error\`.
|
|
674
|
+
- \`<ux-checkbox :value="checked" @click="toggle" />\` - Standalone checkbox.
|
|
675
|
+
- \`<ux-switch :value="on" :loading="false" @click="toggle" />\` - Toggle switch.
|
|
676
|
+
|
|
677
|
+
**Menus & Lists:**
|
|
678
|
+
- \`<ux-menu v-model="isOpen" group="nav" right bottom>\` + template#activator="{on}" + v-on="on" - Dropdown menu. Props: \`v-model\` (open state), \`group\`, \`right\`, \`bottom\`, \`closeOnClick\`, \`flex\`. Slots: \`activator\` (scoped, receives \`{on}\` for event binding), \`default\` (menu content).
|
|
679
|
+
- \`<ux-menu-list :items="menuItems" />\` - Nested menu list. Items shape: \`{title, type, route, url, href, target, items, class}\`. Props: \`expandOn\` ("click"), \`displayCaret\`, \`depth\`.
|
|
680
|
+
- \`<ux-list>\` + \`<ux-list-item :to="{name:'route'}">\` - Simple list. list-item props: \`to\`, \`href\`, \`active\`.
|
|
681
|
+
|
|
682
|
+
### Field Definitions (used by ux-form, ux-form-field, $sdk.prompt, and content type definitions):
|
|
683
|
+
|
|
684
|
+
Field definitions are plain objects that describe form inputs. The same format is used for \`<ux-form>\` fields, \`$sdk.prompt()\` fields, and content type definition schemas.
|
|
685
|
+
|
|
686
|
+
**Core Properties:**
|
|
687
|
+
- \`key\` (string, required) — Model key path (e.g., "firstName", "data.email")
|
|
688
|
+
- \`title\` (string) — Display label
|
|
689
|
+
- \`type\` (string) — Data type. Default: "string". Values: "string", "number", "integer", "decimal", "float", "boolean", "date", "email", "url", "reference", "group", "object", "void"
|
|
690
|
+
- \`widget\` (string) — Override the default input widget (see widget list below)
|
|
691
|
+
- \`minimum\` (number) — Min values required. 0 = optional, 1+ = required
|
|
692
|
+
- \`maximum\` (number) — Max values. 1 = single (default), 0 = unlimited
|
|
693
|
+
- \`description\` (string) — Help text shown below the label
|
|
694
|
+
- \`placeholder\` (string) — Placeholder text (alias: \`hint\`)
|
|
695
|
+
- \`options\` (array) — Choices for select/button widgets: \`[{title: "Label", value: "val"}]\`. Options can have \`group\` for optgroup.
|
|
696
|
+
- \`defaultValues\` (array) — Default pre-populated values
|
|
697
|
+
- \`fields\` (array) — Nested field definitions for \`type: "group"\` or reference forms
|
|
698
|
+
|
|
699
|
+
**Display & Behavior:**
|
|
700
|
+
- \`hideTitle\` (boolean) — Hide the field label
|
|
701
|
+
- \`showLabel\` (boolean) — Override label visibility
|
|
702
|
+
- \`autofocus\` (boolean) — Auto-focus on mount
|
|
703
|
+
- \`editable\` (boolean) — Whether the field is editable
|
|
704
|
+
- \`clear\` (boolean) — Forces full width in flex layouts
|
|
705
|
+
- \`officeOnly\` (boolean) — Only visible in admin mode
|
|
706
|
+
- \`sameLine\` (boolean) — Render on same row in group layouts
|
|
707
|
+
- \`size\` (string) — Size hint
|
|
708
|
+
- \`visualHide\` (boolean) — Visually hide the field
|
|
709
|
+
|
|
710
|
+
**Multi-value:**
|
|
711
|
+
- \`plural\` (string) — Plural label for multi-value fields
|
|
712
|
+
- \`addLabel\` (string) — Label for "Add another" button
|
|
713
|
+
- \`reorderable\` (boolean) — Allow drag reordering
|
|
714
|
+
- \`duplicatable\` (boolean) — Allow duplicating entries
|
|
715
|
+
- \`collapsible\` (boolean) — Allow collapsing entries
|
|
716
|
+
|
|
717
|
+
**Group fields (\`type: "group"\`):**
|
|
718
|
+
- \`asObject\` (boolean) — Store as nested object (min/max 1) instead of layout group
|
|
719
|
+
- \`sameLine\` (boolean) — Render child fields side-by-side (flex)
|
|
720
|
+
- \`fields\` (array) — Nested field definitions
|
|
721
|
+
|
|
722
|
+
**Date fields:**
|
|
723
|
+
- \`dateOnly\` (boolean) — Date without time
|
|
724
|
+
- \`minDate\` / \`maxDate\` (Date|string) — Date range constraints
|
|
725
|
+
- \`allDay\` (boolean) — Treat as all-day date
|
|
726
|
+
|
|
727
|
+
**Reference fields:**
|
|
728
|
+
- \`referenceType\` (string) — Content type to reference (e.g., "image", "profile", "event")
|
|
729
|
+
- \`lockFilter\` (object) — Filter to restrict selectable items
|
|
730
|
+
- \`select\` (array) — Fields to retrieve
|
|
731
|
+
- \`columns\` (array) — Column definitions for browser \`[{title, key}]\`
|
|
732
|
+
|
|
733
|
+
**Other type-specific:**
|
|
734
|
+
- \`currency\` (string) — Currency code for currency widget (e.g., "AUD", "USD")
|
|
735
|
+
- \`minValue\` / \`maxValue\` / \`stepValue\` (number) — For slider widget
|
|
736
|
+
- \`prefix\` / \`suffix\` (string) — Text prefix/suffix for text fields
|
|
737
|
+
- \`template\` (string) — HTML for void/html display fields
|
|
738
|
+
- \`syntax\` (string) — Syntax mode for code editor
|
|
739
|
+
- \`sensitive\` (boolean) — Show/hide toggle for password fields
|
|
740
|
+
- \`copyable\` (boolean) — Show copy button
|
|
741
|
+
|
|
742
|
+
**Conditional display:**
|
|
743
|
+
- \`expressions.show\` (string) — Show/hide expression: \`"self.fieldKey === 'value'"\`
|
|
744
|
+
- \`expressions.defaultValue\` (string) — Computed default: \`"self.otherField"\`
|
|
745
|
+
|
|
746
|
+
### Available Widgets (\`widget\` property):
|
|
747
|
+
- **Text:** \`textfield\` (default for string), \`textarea\`, \`richtext\`, \`code\`, \`keyfield\`
|
|
748
|
+
- **Selection:** \`select\`, \`button\`/\`buttons\`/\`buttonselect\`, \`options\`
|
|
749
|
+
- **Boolean:** \`checkbox\`, \`switch\`
|
|
750
|
+
- **Date/Time:** \`datepicker\`/\`datefield\`/\`date\`, \`timefield\`/\`timepicker\`, \`daterange\`, \`dateobject\`
|
|
751
|
+
- **Number:** \`currency\`, \`slider\`
|
|
752
|
+
- **Media:** \`upload\`, \`signature\`, \`color\`
|
|
753
|
+
- **Contact:** \`phone\`/\`phonenumber\`, \`email\`, \`url\`
|
|
754
|
+
- **Location:** \`location\`, \`country\`, \`timezone\`
|
|
755
|
+
- **Content:** \`content-select\`, \`content-search\`, \`form\` (embedded create form), \`type-select\`, \`scope-select\`, \`field-select\`
|
|
756
|
+
- **Display:** \`html\` (display-only, used with type "void"), \`value\` (hidden)
|
|
757
|
+
- **Advanced:** \`filter\`, \`expression\`, \`model\`, \`object\`, \`payment\`
|
|
643
758
|
|
|
644
759
|
### SDK API (available as this.$sdk in JS):
|
|
645
760
|
**App state (\`this.$sdk.app\`):**
|
|
@@ -679,17 +794,73 @@ When writing HTML for Custom Code sections, prefer vue-ui components over raw HT
|
|
|
679
794
|
- \`.parseDate(input)\` / \`.parseNumber(input)\` - Parsers
|
|
680
795
|
- \`.loadExternalScript(url)\` / \`.loadExternalStyle(url)\` - Load external resources
|
|
681
796
|
|
|
797
|
+
**Date (\`this.$sdk.date\`):**
|
|
798
|
+
- \`.timeago(date, options)\` - Relative time ("2 days ago")
|
|
799
|
+
- \`.readableEventDate({startDate, endDate, timezone}, options)\` - Human-readable event date ("5 - 10 May 2026")
|
|
800
|
+
- \`.format(date, formatString)\` - Format date using Luxon tokens
|
|
801
|
+
|
|
682
802
|
**Events (on the $sdk instance itself):**
|
|
683
803
|
- \`this.$sdk.addEventListener(event, callback)\` - Listen for events
|
|
684
804
|
- \`this.$sdk.removeEventListener(event, callback)\` - Stop listening
|
|
685
805
|
- \`this.$sdk.dispatch(event, data)\` - Emit event
|
|
686
806
|
- Events: \`route:change:start\`, \`route:change\`, \`route:change:end\`, \`error\`, \`notification\`
|
|
687
807
|
|
|
688
|
-
**
|
|
689
|
-
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
808
|
+
**Notifications:**
|
|
809
|
+
- \`this.$sdk.notify(message)\` - Show a notification toast
|
|
810
|
+
|
|
811
|
+
**UI Dialogs (\`this.$sdk\`):**
|
|
812
|
+
All dialog methods return a Promise that resolves on user action and rejects if dismissed/cancelled.
|
|
813
|
+
|
|
814
|
+
\`this.$sdk.confirm(title, options?)\` - Confirmation dialog. Options: \`{description}\`. Resolves on confirm, rejects on cancel. Example:
|
|
815
|
+
\`\`\`
|
|
816
|
+
await this.$sdk.confirm('Delete this item?', { description: 'This cannot be undone.' });
|
|
817
|
+
\`\`\`
|
|
818
|
+
|
|
819
|
+
\`this.$sdk.prompt(fields, options?)\` - Form dialog. Returns the form data model object. Options: \`{title, description, model, confirmText, cancelText}\`.
|
|
820
|
+
\`fields\` is an array of field definition objects (see "Field Definitions" section above).
|
|
821
|
+
Example:
|
|
822
|
+
\`\`\`
|
|
823
|
+
const result = await this.$sdk.prompt([
|
|
824
|
+
{ title: 'Name', key: 'name', type: 'string', minimum: 1, maximum: 1 },
|
|
825
|
+
{ title: 'Email', key: 'email', type: 'email', minimum: 1, maximum: 1 },
|
|
826
|
+
{ title: 'Role', key: 'role', widget: 'select', options: [
|
|
827
|
+
{ title: 'Admin', value: 'admin' },
|
|
828
|
+
{ title: 'Editor', value: 'editor' },
|
|
829
|
+
]},
|
|
830
|
+
], {
|
|
831
|
+
title: 'Add Team Member',
|
|
832
|
+
description: 'Enter the new member details',
|
|
833
|
+
model: { role: 'editor' },
|
|
834
|
+
});
|
|
835
|
+
// result = { name: '...', email: '...', role: '...' }
|
|
836
|
+
\`\`\`
|
|
837
|
+
|
|
838
|
+
\`this.$sdk.options(choices, title?, description?, additional?)\` - Options picker. Each choice: \`{title, description, icon, value}\`. Additional options: \`{columns: true, search: true}\`. Resolves with selected choice object.
|
|
839
|
+
\`\`\`
|
|
840
|
+
const choice = await this.$sdk.options([
|
|
841
|
+
{ title: 'Option A', description: 'First option', value: 'a' },
|
|
842
|
+
{ title: 'Option B', description: 'Second option', value: 'b' },
|
|
843
|
+
], 'Choose one', 'Select your preference');
|
|
844
|
+
\`\`\`
|
|
845
|
+
|
|
846
|
+
\`this.$sdk.modal({component, options, style})\` - Custom modal with a Vue component. The component receives \`options\` as a prop and can call \`this.close(result)\` to resolve or \`this.dismiss()\` to reject.
|
|
847
|
+
\`\`\`
|
|
848
|
+
const result = await this.$sdk.modal({
|
|
849
|
+
component: this.$sdk.app.components['myCustomModal'],
|
|
850
|
+
options: { itemId: '123' },
|
|
851
|
+
});
|
|
852
|
+
\`\`\`
|
|
853
|
+
|
|
854
|
+
\`this.$sdk.browse(type, options?)\` - Content browser modal for selecting items. Options: \`{maximum, browserOptions: {sort, select, columns, lockFilter}}\`. Returns array of selected items.
|
|
855
|
+
\`\`\`
|
|
856
|
+
const selected = await this.$sdk.browse('article', {
|
|
857
|
+
maximum: 3,
|
|
858
|
+
browserOptions: {
|
|
859
|
+
sort: { key: 'title', direction: 'asc', type: 'string' },
|
|
860
|
+
columns: [{ title: 'Title', key: 'title' }],
|
|
861
|
+
},
|
|
862
|
+
});
|
|
863
|
+
\`\`\`
|
|
693
864
|
|
|
694
865
|
### JavaScript format (Vue Options API, plain object, NO export default):
|
|
695
866
|
\`\`\`
|
|
@@ -705,6 +876,8 @@ When writing HTML for Custom Code sections, prefer vue-ui components over raw HT
|
|
|
705
876
|
}
|
|
706
877
|
\`\`\`
|
|
707
878
|
|
|
879
|
+
**IMPORTANT (SSR Safety):** Interfaces run on Nuxt. Code in \`created()\` executes on the server too, where \`window\` and \`document\` do not exist. Only access browser APIs in \`mounted()\` or behind \`if (typeof window !== 'undefined')\`.
|
|
880
|
+
|
|
708
881
|
**Examples:**
|
|
709
882
|
\`\`\`json
|
|
710
883
|
{
|
|
@@ -797,7 +970,7 @@ Returns the new section's UUID - save this for updating or nesting into its slot
|
|
|
797
970
|
};
|
|
798
971
|
export const updateInterfaceSectionTool = {
|
|
799
972
|
name: "update_interface_section",
|
|
800
|
-
description: `Update a section's model, title, or other properties. Always call \`get_interface\` first to see current sections and their UUIDs.
|
|
973
|
+
description: `Update a section's model, title, or other properties. Always call \`get_interface\` first to see current sections and their UUIDs. Do NOT publish after this — changes are saved automatically.
|
|
801
974
|
|
|
802
975
|
Model fields are **shallow-merged**: only the fields you provide are updated, others are preserved.
|
|
803
976
|
For example, to update just the HTML of a Custom Code section, send \`model: { html: "<new>" }\` and javascript/scss remain unchanged.
|
|
@@ -840,7 +1013,7 @@ For example, to update just the HTML of a Custom Code section, send \`model: { h
|
|
|
840
1013
|
};
|
|
841
1014
|
export const removeInterfaceSectionTool = {
|
|
842
1015
|
name: "remove_interface_section",
|
|
843
|
-
description: `Remove a section by UUID. Always call \`get_interface\` first to confirm the UUID. Searches header, footer, all routes, and nested slots.
|
|
1016
|
+
description: `Remove a section by UUID. Always call \`get_interface\` first to confirm the UUID. Searches header, footer, all routes, and nested slots. Do NOT publish after this — changes are saved automatically.
|
|
844
1017
|
|
|
845
1018
|
**Example:**
|
|
846
1019
|
\`\`\`json
|
|
@@ -857,28 +1030,38 @@ export const removeInterfaceSectionTool = {
|
|
|
857
1030
|
};
|
|
858
1031
|
export const setInterfaceCustomComponentTool = {
|
|
859
1032
|
name: "set_interface_custom_component",
|
|
860
|
-
description: `Add or update an inline custom component in the interface. Always call \`get_interface\` first to see existing components.
|
|
1033
|
+
description: `Add or update an inline custom component in the interface. Always call \`get_interface\` first to see existing components. Do NOT publish after this — changes are saved automatically.
|
|
861
1034
|
|
|
862
1035
|
Custom components are defined with HTML, JS, and CSS and can be used as tags in other component templates (e.g., \`<event-card />\`).
|
|
863
1036
|
|
|
1037
|
+
**IMPORTANT:** The component model fields (\`html\`, \`js\`, \`css\`) must be **strings only**. Do not pass objects, arrays, or nested structures — non-string values are silently dropped.
|
|
1038
|
+
|
|
864
1039
|
**JS format:** Vue Options API as a plain object \`{}\` without \`export default\`.
|
|
865
1040
|
|
|
866
1041
|
**TIP:** Prefer vue-ui components over raw HTML where a more appropriate component exists:
|
|
867
|
-
- \`<ux-link :to="{name:'route'}">\` for app navigation instead of \`<a href>\`
|
|
1042
|
+
- \`<ux-link :to="{name:'route'}">\` for app navigation instead of \`<a href>\`. Note: compiles to an inline \`<a>\` tag — add \`display:block\` in CSS if you need block-level layout.
|
|
868
1043
|
- \`<ux-button>\` for interactive buttons
|
|
869
1044
|
- \`<ux-icon icon="fa-name" />\` for icons
|
|
870
1045
|
- \`<ux-image :item="ref" />\` for images
|
|
871
1046
|
- \`<flex-row gap center>\` + \`<flex-cell>\` for layout
|
|
872
1047
|
- \`<ux-panel>\` + \`<ux-panel-body>\` for cards
|
|
873
1048
|
|
|
1049
|
+
**SCSS Scoping:** Component CSS is automatically wrapped/scoped to the mounted element. Do NOT wrap your styles in the component's root class — write styles as if already inside the root element. If your HTML is \`<div class="my-comp"><span class="label">Hi</span></div>\`, your CSS should be \`.label { color: red; }\` NOT \`.my-comp { .label { color: red; } }\`.
|
|
1050
|
+
|
|
874
1051
|
**SDK** (via \`this.$sdk\`):
|
|
875
1052
|
- \`this.$sdk.app\` - App state: \`.user\`, \`.route\`, \`.menus\`, \`.services\`, \`.to()\`, \`.createHref()\`, \`.device\`, \`.clock\`
|
|
876
1053
|
- \`this.$sdk.auth\` - Auth: \`.logout()\`, \`.getCurrentUser()\`, \`.changeOrganisation()\`
|
|
877
1054
|
- \`this.$sdk.content\` - Content: \`.list(type, options)\`, \`.get(id)\`
|
|
878
1055
|
- \`this.$sdk.api\` - REST: \`.get()\`, \`.post()\`, \`.put()\`, \`.delete()\`
|
|
879
1056
|
- \`this.$sdk.utils\` - Helpers: \`.id()\`, \`.ids()\`, \`.clone()\`, \`.hash()\`, \`.formatCurrency()\`
|
|
1057
|
+
- \`this.$sdk.date\` - Date formatting: \`.timeago()\`, \`.readableEventDate()\`, \`.format()\`
|
|
880
1058
|
- \`this.$sdk.addEventListener(event, cb)\` - Events: \`route:change\`, \`error\`, \`notification\`
|
|
881
|
-
- \`this.$sdk.
|
|
1059
|
+
- \`this.$sdk.notify(message)\` - Show notification toast
|
|
1060
|
+
- \`this.$sdk.confirm(title, options?)\` - Confirmation dialog (returns Promise, resolves on confirm)
|
|
1061
|
+
- \`this.$sdk.prompt(fields, options?)\` - Form dialog. \`fields\`: array of field definitions (see add_interface_section docs). \`options\`: \`{title, description, model, confirmText}\`. Returns Promise<model>.
|
|
1062
|
+
- \`this.$sdk.options(choices, title?, description?)\` - Options picker. Each choice: \`{title, description, icon, value}\`. Returns Promise<choice>.
|
|
1063
|
+
- \`this.$sdk.modal({component, options})\` - Custom modal. Component calls \`this.close(result)\` to resolve, \`this.dismiss()\` to reject.
|
|
1064
|
+
- \`this.$sdk.browse(type, options?)\` - Content browser. Returns Promise<selectedItems[]>.
|
|
882
1065
|
|
|
883
1066
|
**Example:**
|
|
884
1067
|
\`\`\`json
|
|
@@ -908,13 +1091,18 @@ The component is then available as \`<event-card :item="myItem" />\` in Custom C
|
|
|
908
1091
|
};
|
|
909
1092
|
export const setInterfaceServiceTool = {
|
|
910
1093
|
name: "set_interface_service",
|
|
911
|
-
description: `Add or update a JavaScript service in the interface. Always call \`get_interface\` first to see existing services.
|
|
1094
|
+
description: `Add or update a JavaScript service in the interface. Always call \`get_interface\` first to see existing services. Do NOT publish after this — changes are saved automatically.
|
|
912
1095
|
|
|
913
1096
|
Services are reactive Vue instances available as \`this.$sdk.app.services.serviceName\` in all components.
|
|
914
1097
|
Use for shared state, API calls, or computed data.
|
|
915
1098
|
|
|
916
1099
|
**JS format:** Vue Options API as a plain object \`{}\` without \`export default\`.
|
|
917
1100
|
|
|
1101
|
+
**IMPORTANT:** Interfaces run on Nuxt (SSR). Services are instantiated on the server too, so \`window\`, \`document\`, and other browser APIs are NOT available at creation time. Always guard browser API usage behind a mount check:
|
|
1102
|
+
- Use \`mounted()\` lifecycle hook instead of \`created()\` for any code that accesses \`window\` or \`document\`
|
|
1103
|
+
- Or guard with \`if (typeof window !== 'undefined') { ... }\`
|
|
1104
|
+
- \`created()\` is safe for non-browser logic (API calls via \`$sdk\`, setting data, etc.)
|
|
1105
|
+
|
|
918
1106
|
**Example:**
|
|
919
1107
|
\`\`\`json
|
|
920
1108
|
{
|
|
@@ -937,7 +1125,7 @@ Use for shared state, API calls, or computed data.
|
|
|
937
1125
|
};
|
|
938
1126
|
export const setInterfaceMenuTool = {
|
|
939
1127
|
name: "set_interface_menu",
|
|
940
|
-
description: `Create or update a navigation menu in the interface. Always call \`get_interface\` first to see existing menus.
|
|
1128
|
+
description: `Create or update a navigation menu in the interface. Always call \`get_interface\` first to see existing menus. Do NOT publish after this — changes are saved automatically.
|
|
941
1129
|
|
|
942
1130
|
Menu items link to routes (by name) or external URLs. Items can be nested for dropdown menus.
|
|
943
1131
|
Each item can have \`contextVisibility\` to control when it appears (e.g., show "Dashboard" only to logged-in users, show "Login" only to anonymous visitors).
|
|
@@ -998,12 +1186,12 @@ Each item can have \`contextVisibility\` to control when it appears (e.g., show
|
|
|
998
1186
|
};
|
|
999
1187
|
export const setInterfaceStylesTool = {
|
|
1000
1188
|
name: "set_interface_styles",
|
|
1001
|
-
description: `Update the interface's global SCSS styles and themes. Always call \`get_interface\` first to see current styles.
|
|
1189
|
+
description: `Update the interface's global SCSS styles and themes. Always call \`get_interface\` first to see current styles. Do NOT publish after this — changes are saved automatically.
|
|
1002
1190
|
|
|
1003
1191
|
Only the provided fields are updated; others remain unchanged.
|
|
1004
1192
|
|
|
1005
|
-
- **pre**: SCSS injected before component styles. Use for CSS custom properties (\`:root { --primary: #4F46E5; }\`),
|
|
1006
|
-
- **post**: SCSS injected after component styles. Use for global rules, typography, layout helpers (e.g., \`.v-wrap\`, \`.h-wrap\`).
|
|
1193
|
+
- **pre**: SCSS injected before component styles. Use for CSS custom properties (\`:root { --primary: #4F46E5; }\`) and resets. **Note:** Pre-SCSS is loaded at the start of every component in the builder, so avoid putting external resource imports (e.g., Google Fonts \`@import\`) here.
|
|
1194
|
+
- **post**: SCSS injected after component styles. Use for global rules, typography, layout helpers (e.g., \`.v-wrap\`, \`.h-wrap\`). **Prefer putting external resource imports here** (e.g., Google Fonts \`@import\` URLs) so they are only loaded once, not per-component.
|
|
1007
1195
|
- **themes**: Reusable scoped CSS blocks applied to sections. Each theme has a \`title\`, \`uuid\` (10-char alphanumeric, auto-generated if omitted), and \`body\` (CSS/SCSS). Sections reference themes by UUID in their \`themes\` array — the theme's CSS is scoped to that section.
|
|
1008
1196
|
|
|
1009
1197
|
**Theme workflow:**
|
|
@@ -1011,6 +1199,15 @@ Only the provided fields are updated; others remain unchanged.
|
|
|
1011
1199
|
2. When adding/updating sections, set \`themes: ["<uuid>"]\` to apply the theme's CSS
|
|
1012
1200
|
3. Multiple themes can be stacked on a single section
|
|
1013
1201
|
|
|
1202
|
+
**IMPORTANT:** When using SCSS functions or expressions inside \`:root {}\` CSS custom properties, you must use \`#{}\` interpolation syntax so SCSS evaluates the expression. For example:
|
|
1203
|
+
\`\`\`scss
|
|
1204
|
+
:root {
|
|
1205
|
+
--primary: #4F46E5; // plain values are fine
|
|
1206
|
+
--noise-url: #{imageURL('abc123', 150, 150, 'png')}; // SCSS functions need #{}
|
|
1207
|
+
}
|
|
1208
|
+
\`\`\`
|
|
1209
|
+
Without \`#{}\`, SCSS will output the function call as a literal string instead of evaluating it.
|
|
1210
|
+
|
|
1014
1211
|
**Example:**
|
|
1015
1212
|
\`\`\`json
|
|
1016
1213
|
{
|
|
@@ -1044,7 +1241,7 @@ Only the provided fields are updated; others remain unchanged.
|
|
|
1044
1241
|
};
|
|
1045
1242
|
export const setInterfaceLayoutTool = {
|
|
1046
1243
|
name: "set_interface_layout",
|
|
1047
|
-
description: `Set the interface's layout template. Always call \`get_interface\` first to see the current layout.
|
|
1244
|
+
description: `Set the interface's layout template. Always call \`get_interface\` first to see the current layout. Do NOT publish after this — changes are saved automatically.
|
|
1048
1245
|
|
|
1049
1246
|
The default layout is \`<header-slot/><route-slot/><footer-slot/>\` (empty string = default).
|
|
1050
1247
|
Set to a custom component tag to use a custom layout (e.g., \`<custom-layout />\`).
|
|
@@ -1131,7 +1328,7 @@ export async function handleCreateInterface(args) {
|
|
|
1131
1328
|
return {
|
|
1132
1329
|
content: [{
|
|
1133
1330
|
type: "text",
|
|
1134
|
-
text: `# Interface Created\n\n**Title:** ${args.title}\n**ID:** \`${id}\`\n\nA default "Home" route (path: /) has been created. Use \`get_interface\` to see the structure, then start adding routes and sections.`
|
|
1331
|
+
text: `# Interface Created\n\n**Title:** ${args.title}\n**ID:** \`${id}\`\n\nA default "Home" route (path: /) has been created. Use \`get_interface\` to see the structure, then start adding routes and sections.\n\n**Note:** Do NOT publish unless the user explicitly asks. Changes are saved automatically.`
|
|
1135
1332
|
}]
|
|
1136
1333
|
};
|
|
1137
1334
|
}
|