@seed-ship/mcp-ui-solid 6.17.0 → 6.18.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.
Files changed (156) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/README.md +50 -3
  3. package/dist/adapters/index.d.ts +2 -0
  4. package/dist/adapters/index.d.ts.map +1 -1
  5. package/dist/adapters/presentation.cjs +141 -0
  6. package/dist/adapters/presentation.cjs.map +1 -0
  7. package/dist/adapters/presentation.d.ts +68 -0
  8. package/dist/adapters/presentation.d.ts.map +1 -0
  9. package/dist/adapters/presentation.js +141 -0
  10. package/dist/adapters/presentation.js.map +1 -0
  11. package/dist/adapters.cjs +4 -0
  12. package/dist/adapters.cjs.map +1 -1
  13. package/dist/adapters.d.cts +2 -0
  14. package/dist/adapters.d.ts +2 -0
  15. package/dist/adapters.js +4 -0
  16. package/dist/adapters.js.map +1 -1
  17. package/dist/components/ChartJSRenderer.cjs +165 -65
  18. package/dist/components/ChartJSRenderer.cjs.map +1 -1
  19. package/dist/components/ChartJSRenderer.d.ts.map +1 -1
  20. package/dist/components/ChartJSRenderer.js +168 -68
  21. package/dist/components/ChartJSRenderer.js.map +1 -1
  22. package/dist/components/ComponentToolbar.cjs.map +1 -1
  23. package/dist/components/ComponentToolbar.d.ts.map +1 -1
  24. package/dist/components/ComponentToolbar.js.map +1 -1
  25. package/dist/components/EditableLayoutContext.cjs +17 -0
  26. package/dist/components/EditableLayoutContext.cjs.map +1 -0
  27. package/dist/components/EditableLayoutContext.d.ts +5 -0
  28. package/dist/components/EditableLayoutContext.d.ts.map +1 -0
  29. package/dist/components/EditableLayoutContext.js +17 -0
  30. package/dist/components/EditableLayoutContext.js.map +1 -0
  31. package/dist/components/EditableUIResourceRenderer.cjs +87 -84
  32. package/dist/components/EditableUIResourceRenderer.cjs.map +1 -1
  33. package/dist/components/EditableUIResourceRenderer.d.ts.map +1 -1
  34. package/dist/components/EditableUIResourceRenderer.js +87 -84
  35. package/dist/components/EditableUIResourceRenderer.js.map +1 -1
  36. package/dist/components/ElicitationForm.cjs.map +1 -1
  37. package/dist/components/ElicitationForm.js.map +1 -1
  38. package/dist/components/FeedbackInline.cjs +0 -1
  39. package/dist/components/FeedbackInline.cjs.map +1 -1
  40. package/dist/components/FeedbackInline.js +0 -1
  41. package/dist/components/FeedbackInline.js.map +1 -1
  42. package/dist/components/GraphRenderer.cjs.map +1 -1
  43. package/dist/components/GraphRenderer.d.ts.map +1 -1
  44. package/dist/components/GraphRenderer.js.map +1 -1
  45. package/dist/components/GridRenderer.cjs +12 -6
  46. package/dist/components/GridRenderer.cjs.map +1 -1
  47. package/dist/components/GridRenderer.d.ts.map +1 -1
  48. package/dist/components/GridRenderer.js +13 -7
  49. package/dist/components/GridRenderer.js.map +1 -1
  50. package/dist/components/MapRenderer.cjs.map +1 -1
  51. package/dist/components/MapRenderer.d.ts.map +1 -1
  52. package/dist/components/MapRenderer.js.map +1 -1
  53. package/dist/components/PresentationFeedback.cjs +0 -1
  54. package/dist/components/PresentationFeedback.cjs.map +1 -1
  55. package/dist/components/PresentationFeedback.js +0 -1
  56. package/dist/components/PresentationFeedback.js.map +1 -1
  57. package/dist/components/UIResourceRenderer.cjs +37 -22
  58. package/dist/components/UIResourceRenderer.cjs.map +1 -1
  59. package/dist/components/UIResourceRenderer.d.ts.map +1 -1
  60. package/dist/components/UIResourceRenderer.js +38 -23
  61. package/dist/components/UIResourceRenderer.js.map +1 -1
  62. package/dist/components/VerifiedText.cjs +0 -4
  63. package/dist/components/VerifiedText.cjs.map +1 -1
  64. package/dist/components/VerifiedText.d.ts.map +1 -1
  65. package/dist/components/VerifiedText.js +0 -4
  66. package/dist/components/VerifiedText.js.map +1 -1
  67. package/dist/components/chart-data-table.cjs +73 -0
  68. package/dist/components/chart-data-table.cjs.map +1 -0
  69. package/dist/components/chart-data-table.d.ts +23 -0
  70. package/dist/components/chart-data-table.d.ts.map +1 -0
  71. package/dist/components/chart-data-table.js +73 -0
  72. package/dist/components/chart-data-table.js.map +1 -0
  73. package/dist/context/MCPUIStringsContext.cjs +10 -9
  74. package/dist/context/MCPUIStringsContext.cjs.map +1 -1
  75. package/dist/context/MCPUIStringsContext.d.ts +17 -5
  76. package/dist/context/MCPUIStringsContext.d.ts.map +1 -1
  77. package/dist/context/MCPUIStringsContext.js +11 -10
  78. package/dist/context/MCPUIStringsContext.js.map +1 -1
  79. package/dist/hooks/createResponsiveGrid.cjs +37 -0
  80. package/dist/hooks/createResponsiveGrid.cjs.map +1 -0
  81. package/dist/hooks/createResponsiveGrid.d.ts +6 -0
  82. package/dist/hooks/createResponsiveGrid.d.ts.map +1 -0
  83. package/dist/hooks/createResponsiveGrid.js +37 -0
  84. package/dist/hooks/createResponsiveGrid.js.map +1 -0
  85. package/dist/index.cjs +1 -0
  86. package/dist/index.cjs.map +1 -1
  87. package/dist/index.js +1 -0
  88. package/dist/index.js.map +1 -1
  89. package/dist/mcp-ui-spec/dist/schemas.cjs +13 -1
  90. package/dist/mcp-ui-spec/dist/schemas.cjs.map +1 -1
  91. package/dist/mcp-ui-spec/dist/schemas.js +13 -1
  92. package/dist/mcp-ui-spec/dist/schemas.js.map +1 -1
  93. package/dist/services/chat-bus.cjs.map +1 -1
  94. package/dist/services/chat-bus.d.ts.map +1 -1
  95. package/dist/services/chat-bus.js.map +1 -1
  96. package/dist/services/chat-prompt-controller.cjs.map +1 -1
  97. package/dist/services/chat-prompt-controller.d.ts.map +1 -1
  98. package/dist/services/chat-prompt-controller.js.map +1 -1
  99. package/dist/services/component-registry.cjs +162 -22
  100. package/dist/services/component-registry.cjs.map +1 -1
  101. package/dist/services/component-registry.d.ts +6 -3
  102. package/dist/services/component-registry.d.ts.map +1 -1
  103. package/dist/services/component-registry.js +162 -22
  104. package/dist/services/component-registry.js.map +1 -1
  105. package/dist/services/telemetry.cjs +0 -1
  106. package/dist/services/telemetry.cjs.map +1 -1
  107. package/dist/services/telemetry.js +0 -1
  108. package/dist/services/telemetry.js.map +1 -1
  109. package/dist/services/validation.cjs +21 -7
  110. package/dist/services/validation.cjs.map +1 -1
  111. package/dist/services/validation.d.ts.map +1 -1
  112. package/dist/services/validation.js +21 -7
  113. package/dist/services/validation.js.map +1 -1
  114. package/dist/types/index.d.ts +43 -8
  115. package/dist/types/index.d.ts.map +1 -1
  116. package/dist/types.d.cts +43 -8
  117. package/dist/types.d.ts +43 -8
  118. package/docs/briefs/VISUALIZATION-FOUNDATION-2026-09-14.md +105 -0
  119. package/package.json +4 -4
  120. package/src/adapters/index.ts +18 -0
  121. package/src/adapters/presentation.test.ts +114 -0
  122. package/src/adapters/presentation.ts +229 -0
  123. package/src/components/ChartJSRenderer.test.tsx +325 -0
  124. package/src/components/ChartJSRenderer.tsx +162 -27
  125. package/src/components/ChatPrompt.test.tsx +1 -1
  126. package/src/components/ComponentToolbar.tsx +1 -1
  127. package/src/components/EditableLayoutContext.tsx +12 -0
  128. package/src/components/EditableUIResourceRenderer.tsx +11 -8
  129. package/src/components/ElicitationForm.tsx +1 -1
  130. package/src/components/FeedbackInline.tsx +1 -1
  131. package/src/components/GraphRenderer.test.tsx +1 -2
  132. package/src/components/GraphRenderer.tsx +0 -2
  133. package/src/components/GridRenderer.tsx +6 -4
  134. package/src/components/MapRenderer.tsx +0 -3
  135. package/src/components/PresentationFeedback.tsx +1 -1
  136. package/src/components/ResponsiveGrid.test.tsx +166 -0
  137. package/src/components/TableRenderer.pagination.test.tsx +31 -0
  138. package/src/components/UIResourceRenderer.tsx +14 -9
  139. package/src/components/VerifiedText.tsx +0 -5
  140. package/src/components/chart-data-table.ts +97 -0
  141. package/src/context/MCPUIStringsContext.test.tsx +60 -0
  142. package/src/context/MCPUIStringsContext.tsx +31 -12
  143. package/src/hooks/createResponsiveGrid.ts +41 -0
  144. package/src/services/chat-bus.test.ts +1 -1
  145. package/src/services/chat-bus.ts +0 -2
  146. package/src/services/chat-prompt-controller.ts +0 -8
  147. package/src/services/component-registry.test.ts +81 -2
  148. package/src/services/component-registry.ts +167 -23
  149. package/src/services/telemetry.ts +1 -1
  150. package/src/services/validation.test.ts +1 -14
  151. package/src/services/validation.ts +23 -6
  152. package/src/services/visualization-validation.test.ts +42 -0
  153. package/src/types/index.ts +50 -9
  154. package/src/types/visualization-contracts.test.ts +66 -0
  155. package/src/utils/perf.test.ts +3 -3
  156. package/tsconfig.tsbuildinfo +1 -1
@@ -3,14 +3,14 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const validation = require("./validation.cjs");
4
4
  const QuickchartRegistry = {
5
5
  type: "chart",
6
- name: "Quickchart",
7
- description: "Render charts using Quickchart.io API. Supports bar, line, pie, doughnut, radar, and scatter charts. Best for visualizing numerical data with 2-10 data series and up to 1000 data points.",
6
+ name: "Chart.js",
7
+ description: "Render charts locally with Chart.js. Supports bar, line, pie, doughnut, radar, scatter, bubble, and polarArea charts, including point and time-series data. An external QuickChart fallback is available only when the host explicitly opts in.",
8
8
  schema: {
9
9
  type: "object",
10
10
  properties: {
11
11
  type: {
12
12
  type: "string",
13
- enum: ["bar", "line", "pie", "doughnut", "radar", "scatter"],
13
+ enum: ["bar", "line", "pie", "doughnut", "radar", "scatter", "bubble", "polarArea"],
14
14
  description: "Chart type"
15
15
  },
16
16
  title: {
@@ -32,8 +32,22 @@ const QuickchartRegistry = {
32
32
  properties: {
33
33
  label: { type: "string" },
34
34
  data: {
35
- type: "array",
36
- items: { type: "number" }
35
+ // Empty arrays match both branches; mirror Zod's inclusive union.
36
+ anyOf: [
37
+ { type: "array", items: { type: "number" } },
38
+ {
39
+ type: "array",
40
+ items: {
41
+ type: "object",
42
+ properties: {
43
+ x: { oneOf: [{ type: "string" }, { type: "number" }] },
44
+ y: { type: "number" },
45
+ r: { type: "number", minimum: 0 }
46
+ },
47
+ required: ["x", "y"]
48
+ }
49
+ }
50
+ ]
37
51
  },
38
52
  backgroundColor: {
39
53
  oneOf: [{ type: "string" }, { type: "array", items: { type: "string" } }]
@@ -41,7 +55,9 @@ const QuickchartRegistry = {
41
55
  borderColor: {
42
56
  oneOf: [{ type: "string" }, { type: "array", items: { type: "string" } }]
43
57
  },
44
- borderWidth: { type: "number" }
58
+ borderWidth: { type: "number" },
59
+ fill: { oneOf: [{ type: "boolean" }, { type: "string" }] },
60
+ tension: { type: "number" }
45
61
  },
46
62
  required: ["label", "data"]
47
63
  }
@@ -51,8 +67,34 @@ const QuickchartRegistry = {
51
67
  },
52
68
  options: {
53
69
  type: "object",
54
- description: "Chart.js options for customization"
55
- }
70
+ description: "Supported Chart.js options for customization",
71
+ properties: {
72
+ responsive: { type: "boolean" },
73
+ maintainAspectRatio: { type: "boolean" },
74
+ tension: { type: "number" },
75
+ scales: {},
76
+ plugins: {}
77
+ }
78
+ },
79
+ renderer: {
80
+ type: "string",
81
+ enum: ["native", "iframe", "auto"],
82
+ description: "Renderer preference; external iframe use still requires host opt-in"
83
+ },
84
+ exportable: { type: "boolean", description: "Show the PNG export action" },
85
+ timeAxis: {
86
+ type: "object",
87
+ description: "Time-series x-axis configuration; the host must install and register a compatible Chart.js date adapter",
88
+ properties: {
89
+ parser: { type: "string" },
90
+ unit: { type: "string", enum: ["day", "week", "month", "quarter", "year"] },
91
+ tooltipFormat: { type: "string" },
92
+ min: { type: "string" },
93
+ max: { type: "string" }
94
+ }
95
+ },
96
+ height: { type: "string", description: "Chart container height as a CSS value" },
97
+ className: { type: "string" }
56
98
  },
57
99
  required: ["type", "data"]
58
100
  },
@@ -110,7 +152,7 @@ const QuickchartRegistry = {
110
152
  const TableRegistry = {
111
153
  type: "table",
112
154
  name: "DataTable",
113
- description: "Render tabular data with sortable columns and pagination. Best for displaying structured records with up to 100 rows. Supports column width customization and cell formatting.",
155
+ description: "Render tabular data with sortable columns, client-side search, context-aware paging, virtualization, and export controls. Best for structured records with up to 100 rows per payload.",
114
156
  schema: {
115
157
  type: "object",
116
158
  properties: {
@@ -142,11 +184,67 @@ const TableRegistry = {
142
184
  },
143
185
  pagination: {
144
186
  type: "object",
187
+ description: "Legacy server-pagination metadata",
145
188
  properties: {
146
189
  currentPage: { type: "number" },
147
190
  pageSize: { type: "number" },
148
191
  totalRows: { type: "number" }
149
192
  }
193
+ },
194
+ searchable: {
195
+ type: "boolean",
196
+ description: "Show the client-side search field (default: true)"
197
+ },
198
+ searchPlaceholder: { type: "string", description: "Search field placeholder" },
199
+ pageSize: {
200
+ type: "integer",
201
+ minimum: 0,
202
+ description: "Rows per page in expanded mode (default: 25; 0 disables client paging)"
203
+ },
204
+ chatPageSize: {
205
+ type: "integer",
206
+ minimum: 0,
207
+ description: "Rows per page in chat mode (default: min(10, pageSize); 0 disables client paging)"
208
+ },
209
+ initialPage: {
210
+ type: "integer",
211
+ minimum: 0,
212
+ description: "Initial zero-based client page"
213
+ },
214
+ virtualize: {
215
+ oneOf: [
216
+ { type: "boolean" },
217
+ {
218
+ type: "object",
219
+ properties: {
220
+ enabled: { type: "boolean" },
221
+ rowHeight: { type: "integer", minimum: 1 },
222
+ overscan: { type: "integer", minimum: 0 },
223
+ threshold: { type: "integer", minimum: 1 }
224
+ }
225
+ }
226
+ ]
227
+ },
228
+ exportable: {
229
+ oneOf: [
230
+ { type: "boolean" },
231
+ {
232
+ type: "object",
233
+ properties: {
234
+ formats: {
235
+ type: "array",
236
+ items: { type: "string", enum: ["csv", "tsv", "json"] }
237
+ },
238
+ filename: { type: "string" }
239
+ }
240
+ }
241
+ ]
242
+ },
243
+ className: { type: "string" },
244
+ citationMap: { type: "object", description: "Citation metadata keyed by marker id" },
245
+ maxHeight: {
246
+ oneOf: [{ type: "string" }, { type: "number" }],
247
+ description: "Inline table height cap; use 'auto' to disable it"
150
248
  }
151
249
  },
152
250
  required: ["columns", "rows"]
@@ -781,19 +879,36 @@ const MapRegistry = {
781
879
  const GraphRegistry = {
782
880
  type: "graph",
783
881
  name: "NodeLinkGraph",
784
- description: "Render a node-link graph (entities and their relationships) with @antv/g6. Best for provenance/source chains, dependency or process graphs, and ontology-lite entity/relation views. Degrades to an edge table when the graph engine is unavailable.",
882
+ description: "Render a node-link graph (entities and their relationships) with the optional @antv/g6 peer. Best for provenance/source chains, dependency or process graphs, and ontology-lite entity/relation views.",
785
883
  schema: {
786
884
  type: "object",
787
885
  properties: {
886
+ title: { type: "string" },
788
887
  nodes: {
789
888
  type: "array",
790
889
  description: "Graph nodes (at least one required)",
890
+ minItems: 1,
791
891
  items: {
792
892
  type: "object",
793
893
  properties: {
794
- id: { type: "string" },
894
+ id: { type: "string", minLength: 1 },
795
895
  label: { type: "string" },
796
- group: { type: "string" }
896
+ type: { type: "string" },
897
+ size: {
898
+ oneOf: [
899
+ { type: "number" },
900
+ {
901
+ type: "array",
902
+ items: [{ type: "number" }, { type: "number" }],
903
+ additionalItems: false,
904
+ minItems: 2,
905
+ maxItems: 2
906
+ }
907
+ ]
908
+ },
909
+ weight: { type: "number" },
910
+ style: { type: "object" },
911
+ data: { type: "object" }
797
912
  },
798
913
  required: ["id"]
799
914
  }
@@ -804,20 +919,46 @@ const GraphRegistry = {
804
919
  items: {
805
920
  type: "object",
806
921
  properties: {
807
- source: { type: "string" },
808
- target: { type: "string" },
922
+ source: { type: "string", minLength: 1 },
923
+ target: { type: "string", minLength: 1 },
809
924
  label: { type: "string" },
810
- weight: { type: "number" }
925
+ type: { type: "string" },
926
+ weight: { type: "number" },
927
+ style: { type: "object" },
928
+ data: { type: "object" }
811
929
  },
812
930
  required: ["source", "target"]
813
931
  }
814
932
  },
815
933
  layout: {
816
- type: "string",
817
- enum: ["force", "radial", "grid", "dagre", "circular"],
818
- description: "Layout algorithm (default: force)"
934
+ oneOf: [
935
+ {
936
+ type: "string",
937
+ enum: ["force", "dagre", "mindmap", "tree", "circular", "grid", "concentric"]
938
+ },
939
+ {
940
+ type: "object",
941
+ properties: {
942
+ type: {
943
+ type: "string",
944
+ enum: ["force", "dagre", "mindmap", "tree", "circular", "grid", "concentric"]
945
+ },
946
+ options: { type: "object" }
947
+ },
948
+ required: ["type"]
949
+ }
950
+ ],
951
+ description: "Layout shorthand or layout-plus-options object"
819
952
  },
820
- directed: { type: "boolean", description: "Render edges as directed (arrows)" }
953
+ height: { type: "string" },
954
+ width: { type: "string" },
955
+ rendererPref: { type: "string", enum: ["canvas"] },
956
+ fitView: { type: "boolean" },
957
+ enableZoom: { type: "boolean" },
958
+ enableDrag: { type: "boolean" },
959
+ enableSelect: { type: "boolean" },
960
+ tooltip: { type: "boolean" },
961
+ className: { type: "string" }
821
962
  },
822
963
  required: ["nodes"]
823
964
  },
@@ -829,11 +970,10 @@ const GraphRegistry = {
829
970
  type: "graph",
830
971
  position: { colStart: 1, colSpan: 12 },
831
972
  params: {
832
- directed: true,
833
973
  layout: "dagre",
834
974
  nodes: [
835
- { id: "claim", label: "Population = 522 250", group: "claim" },
836
- { id: "source", label: "INSEE 2021", group: "source" }
975
+ { id: "claim", label: "Population = 522 250", weight: 2 },
976
+ { id: "source", label: "INSEE 2021", weight: 1 }
837
977
  ],
838
978
  edges: [{ source: "claim", target: "source", label: "derived from" }]
839
979
  }
@@ -1 +1 @@
1
- {"version":3,"file":"component-registry.cjs","sources":["../../src/services/component-registry.ts"],"sourcesContent":["/**\n * Component Registry Service\n * Phase 0: Static registry with Quickchart and Table definitions\n * Phase 1: Dynamic registry populated from /api/mcp/tools/list\n *\n * Provides component schemas for LLM prompt engineering\n */\n\nimport type { ComponentRegistryEntry, ComponentType } from '../types'\nimport { DEFAULT_RESOURCE_LIMITS } from './validation'\n\n/**\n * Quickchart Component Registry Entry\n * Based on Quickchart API documentation\n */\nexport const QuickchartRegistry: ComponentRegistryEntry = {\n type: 'chart',\n name: 'Quickchart',\n description:\n 'Render charts using Quickchart.io API. Supports bar, line, pie, doughnut, radar, and scatter charts. Best for visualizing numerical data with 2-10 data series and up to 1000 data points.',\n schema: {\n type: 'object',\n properties: {\n type: {\n type: 'string',\n enum: ['bar', 'line', 'pie', 'doughnut', 'radar', 'scatter'],\n description: 'Chart type',\n },\n title: {\n type: 'string',\n description: 'Chart title (optional)',\n },\n data: {\n type: 'object',\n properties: {\n labels: {\n type: 'array',\n items: { type: 'string' },\n description: 'X-axis labels',\n },\n datasets: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n label: { type: 'string' },\n data: {\n type: 'array',\n items: { type: 'number' },\n },\n backgroundColor: {\n oneOf: [{ type: 'string' }, { type: 'array', items: { type: 'string' } }],\n },\n borderColor: {\n oneOf: [{ type: 'string' }, { type: 'array', items: { type: 'string' } }],\n },\n borderWidth: { type: 'number' },\n },\n required: ['label', 'data'],\n },\n },\n },\n required: ['labels', 'datasets'],\n },\n options: {\n type: 'object',\n description: 'Chart.js options for customization',\n },\n },\n required: ['type', 'data'],\n },\n examples: [\n {\n query: 'Show me document types distribution',\n component: {\n id: 'example-bar-1',\n type: 'chart',\n position: { colStart: 1, colSpan: 6 },\n params: {\n type: 'bar',\n title: 'Document Types',\n data: {\n labels: ['PDF', 'DOCX', 'TXT', 'XLSX'],\n datasets: [\n {\n label: 'Count',\n data: [245, 189, 123, 98],\n backgroundColor: ['rgba(59, 130, 246, 0.8)'],\n },\n ],\n },\n },\n },\n },\n {\n query: 'Display upload trends over the last week',\n component: {\n id: 'example-line-1',\n type: 'chart',\n position: { colStart: 1, colSpan: 6 },\n params: {\n type: 'line',\n title: 'Upload Trends',\n data: {\n labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],\n datasets: [\n {\n label: 'Uploads',\n data: [42, 38, 51, 47, 63, 29, 15],\n borderColor: 'rgb(59, 130, 246)',\n },\n ],\n },\n options: {\n tension: 0.4,\n },\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Table Component Registry Entry\n */\nexport const TableRegistry: ComponentRegistryEntry = {\n type: 'table',\n name: 'DataTable',\n description:\n 'Render tabular data with sortable columns and pagination. Best for displaying structured records with up to 100 rows. Supports column width customization and cell formatting.',\n schema: {\n type: 'object',\n properties: {\n title: {\n type: 'string',\n description: 'Table title (optional)',\n },\n columns: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n key: { type: 'string', description: 'Data key for this column' },\n label: { type: 'string', description: 'Column header label' },\n sortable: { type: 'boolean', description: 'Whether column is sortable' },\n width: { type: 'string', description: 'CSS width (e.g., \"30%\")' },\n },\n required: ['key', 'label'],\n },\n minItems: 1,\n },\n rows: {\n type: 'array',\n items: {\n type: 'object',\n description: 'Row data matching column keys',\n },\n maxItems: 100,\n },\n pagination: {\n type: 'object',\n properties: {\n currentPage: { type: 'number' },\n pageSize: { type: 'number' },\n totalRows: { type: 'number' },\n },\n },\n },\n required: ['columns', 'rows'],\n },\n examples: [\n {\n query: 'Show me the most recent documents',\n component: {\n id: 'example-table-1',\n type: 'table',\n position: { colStart: 1, colSpan: 8 },\n params: {\n title: 'Recent Documents',\n columns: [\n { key: 'name', label: 'Name', sortable: true, width: '40%' },\n { key: 'type', label: 'Type', sortable: true, width: '15%' },\n { key: 'size', label: 'Size', width: '15%' },\n { key: 'modified', label: 'Modified', sortable: true, width: '30%' },\n ],\n rows: [\n { name: 'Report.pdf', type: 'PDF', size: '2.4 MB', modified: '2 hours ago' },\n { name: 'Slides.pptx', type: 'PPTX', size: '8.7 MB', modified: '1 day ago' },\n ],\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Metric Card Component Registry Entry\n */\nexport const MetricRegistry: ComponentRegistryEntry = {\n type: 'metric',\n name: 'MetricCard',\n description:\n 'Display a single metric with optional trend indicator. Best for KPIs, statistics, and summary numbers. Supports trend direction (up/down/neutral) and subtitles.',\n schema: {\n type: 'object',\n properties: {\n title: {\n type: 'string',\n description: 'Metric title',\n },\n value: {\n oneOf: [{ type: 'string' }, { type: 'number' }],\n description: 'Metric value',\n },\n unit: {\n type: 'string',\n description: 'Unit of measurement (optional)',\n },\n trend: {\n type: 'object',\n properties: {\n value: { type: 'number', description: 'Percentage change' },\n direction: { type: 'string', enum: ['up', 'down', 'neutral'] },\n },\n },\n subtitle: {\n type: 'string',\n description: 'Additional context (optional)',\n },\n },\n required: ['title', 'value'],\n },\n examples: [\n {\n query: 'Show total document count',\n component: {\n id: 'example-metric-1',\n type: 'metric',\n position: { colStart: 1, colSpan: 3 },\n params: {\n title: 'Total Documents',\n value: '1,247',\n trend: {\n value: 12.5,\n direction: 'up',\n },\n subtitle: '+142 this month',\n },\n },\n },\n ],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 5 * 1024, // 5KB\n renderTimeout: 1000, // 1s\n },\n}\n\n/**\n * Text Component Registry Entry\n */\nexport const TextRegistry: ComponentRegistryEntry = {\n type: 'text',\n name: 'TextBlock',\n description:\n 'Render text content with optional markdown support. Best for explanations, summaries, and context. Supports basic HTML formatting.',\n schema: {\n type: 'object',\n properties: {\n content: {\n type: 'string',\n description: 'Text content (HTML allowed, will be sanitized)',\n },\n markdown: {\n type: 'boolean',\n description: 'Whether content is markdown (not yet implemented)',\n },\n className: {\n type: 'string',\n description: 'Custom CSS classes',\n },\n },\n required: ['content'],\n },\n examples: [\n {\n query: 'Explain the document distribution',\n component: {\n id: 'example-text-1',\n type: 'text',\n position: { colStart: 1, colSpan: 12 },\n params: {\n content:\n '<p>Your document library contains <strong>1,247 files</strong> across 5 different formats. PDFs represent the largest category at 35% of total storage.</p>',\n },\n },\n },\n ],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 10 * 1024, // 10KB\n renderTimeout: 1000, // 1s\n },\n}\n\n// ============================================================================\n// Sprint 4: Additional Component Registry Entries\n// ============================================================================\n\n/**\n * Grid Component Registry Entry\n * Nested CSS Grid layout for organizing multiple components\n */\nexport const GridRegistry: ComponentRegistryEntry = {\n type: 'grid',\n name: 'GridLayout',\n description:\n 'Nested CSS Grid layout for organizing multiple components. Supports named areas, responsive columns (1-12), and custom gap spacing. Best for complex dashboard layouts and template builder.',\n schema: {\n type: 'object',\n properties: {\n columns: {\n type: 'number',\n description: 'Number of columns (default: 12)',\n },\n gap: {\n type: 'string',\n description: 'Gap between items (e.g., \"1rem\")',\n },\n minRowHeight: {\n type: 'string',\n description: 'Minimum row height (optional)',\n },\n areas: {\n type: 'array',\n items: {\n type: 'array',\n items: { type: 'string' },\n },\n description: 'CSS Grid template areas for named regions',\n },\n children: {\n type: 'array',\n items: { type: 'object' },\n description: 'Child UIComponents to render within the grid',\n },\n },\n required: ['children'],\n },\n examples: [],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Action Component Registry Entry\n * Interactive button or link that triggers tool calls\n */\nexport const ActionRegistry: ComponentRegistryEntry = {\n type: 'action',\n name: 'ActionButton',\n description:\n 'Interactive button or link that triggers tool calls or navigation. Best for user interactions, form submissions, and workflow triggers.',\n schema: {\n type: 'object',\n properties: {\n label: {\n type: 'string',\n description: 'Button text',\n },\n type: {\n type: 'string',\n enum: ['button', 'link'],\n description: 'Render as button or link',\n },\n action: {\n type: 'string',\n enum: ['tool-call', 'link', 'submit'],\n description: 'Action type to perform',\n },\n toolName: {\n type: 'string',\n description: 'Tool name to call (for tool-call action)',\n },\n params: {\n type: 'object',\n description: 'Parameters to pass to the tool',\n },\n url: {\n type: 'string',\n description: 'URL for link action',\n },\n variant: {\n type: 'string',\n enum: ['primary', 'secondary', 'outline', 'ghost', 'danger'],\n description: 'Visual style variant',\n },\n size: {\n type: 'string',\n enum: ['sm', 'md', 'lg'],\n description: 'Button size',\n },\n disabled: {\n type: 'boolean',\n description: 'Whether the action is disabled',\n },\n },\n required: ['label', 'type', 'action'],\n },\n examples: [],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Footer Component Registry Entry\n * Display execution metadata like timing and source count\n */\nexport const FooterRegistry: ComponentRegistryEntry = {\n type: 'footer',\n name: 'FooterSection',\n description:\n 'Footer section displaying execution metadata. Best for showing timing, model info, and source counts. Auto-injected by layouts when metadata is provided.',\n schema: {\n type: 'object',\n properties: {\n poweredBy: {\n type: 'string',\n description: 'Powered by text (optional)',\n },\n executionTime: {\n type: 'number',\n description: 'Execution time in milliseconds',\n },\n model: {\n type: 'string',\n description: 'LLM model used',\n },\n sourceCount: {\n type: 'number',\n description: 'Number of sources used',\n },\n customText: {\n type: 'string',\n description: 'Custom footer text',\n },\n links: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n label: { type: 'string' },\n url: { type: 'string' },\n },\n },\n description: 'Footer links',\n },\n },\n },\n examples: [],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 5 * 1024,\n renderTimeout: 1000,\n },\n}\n\n/**\n * Carousel Component Registry Entry\n * Display multiple items with horizontal scrolling\n */\nexport const CarouselRegistry: ComponentRegistryEntry = {\n type: 'carousel',\n name: 'Carousel',\n description:\n 'Horizontal carousel for displaying multiple items with snap scrolling and navigation buttons. Best for showcasing related content, image galleries, or card collections.',\n schema: {\n type: 'object',\n properties: {\n items: {\n type: 'array',\n items: { type: 'object' },\n description: 'Array of UIComponents to display in carousel',\n },\n height: {\n type: 'string',\n description: 'Carousel height (optional)',\n },\n },\n required: ['items'],\n },\n examples: [],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Artifact Component Registry Entry\n * Display downloadable artifacts like generated files\n */\nexport const ArtifactRegistry: ComponentRegistryEntry = {\n type: 'artifact',\n name: 'Artifact',\n description:\n 'Display downloadable artifacts like generated files or exports. Shows filename, size, and download button. Best for CSV exports, PDF reports, and generated documents.',\n schema: {\n type: 'object',\n properties: {\n url: {\n type: 'string',\n description: 'Download URL for the artifact',\n },\n filename: {\n type: 'string',\n description: 'Display filename',\n },\n mimeType: {\n type: 'string',\n description: 'MIME type (e.g., \"text/csv\", \"application/pdf\")',\n },\n size: {\n type: 'number',\n description: 'File size in bytes',\n },\n description: {\n type: 'string',\n description: 'Description of the artifact',\n },\n },\n required: ['url', 'filename', 'mimeType'],\n },\n examples: [],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 5 * 1024,\n renderTimeout: 1000,\n },\n}\n\n/**\n * Code Block Registry Entry\n */\nexport const CodeRegistry: ComponentRegistryEntry = {\n type: 'code',\n name: 'CodeBlock',\n description:\n 'Render syntax-highlighted code blocks with line numbers, copy button, and word wrap toggle. Supports all languages via highlight.js auto-detection. Best for displaying source code, configuration files, CLI output, or API responses.',\n schema: {\n type: 'object',\n properties: {\n code: { type: 'string', description: 'The code content to display' },\n language: { type: 'string', description: 'Programming language for syntax highlighting (auto-detected if omitted)' },\n filename: { type: 'string', description: 'Filename shown in header bar' },\n showLineNumbers: { type: 'boolean', description: 'Show line numbers (default: true)' },\n startLine: { type: 'number', description: 'Starting line number (default: 1)' },\n maxHeight: { type: 'string', description: 'CSS max-height for scrollable code blocks' },\n theme: { type: 'string', enum: ['light', 'dark'], description: 'Color theme (follows system preference by default)' },\n },\n required: ['code'],\n },\n examples: [\n {\n query: 'Show me how to connect to the API',\n component: {\n id: 'example-code-1',\n type: 'code',\n position: { colStart: 1, colSpan: 8 },\n params: {\n code: 'const client = new MCPClient({ url: \"https://api.example.com\" });\\nawait client.connect();\\nconst result = await client.query(\"SELECT * FROM documents\");',\n language: 'typescript',\n filename: 'example.ts',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Map Registry Entry\n */\nconst MAP_LAT_LNG_POINT_SCHEMA = {\n oneOf: [\n {\n type: 'array',\n items: { type: 'number' },\n minItems: 2,\n maxItems: 2,\n description: '[latitude, longitude] tuple',\n },\n {\n type: 'object',\n properties: {\n lat: { type: 'number' },\n lng: { type: 'number' },\n },\n required: ['lat', 'lng'],\n description: '{ lat, lng } object',\n },\n ],\n}\n\nconst MAP_GEOJSON_POSITION_SCHEMA = {\n type: 'array',\n items: { type: 'number' },\n minItems: 2,\n}\n\nconst MAP_GEOJSON_COORDINATES_SCHEMA = {\n anyOf: [\n MAP_GEOJSON_POSITION_SCHEMA,\n { type: 'array', items: MAP_GEOJSON_POSITION_SCHEMA },\n { type: 'array', items: { type: 'array', items: MAP_GEOJSON_POSITION_SCHEMA } },\n {\n type: 'array',\n items: {\n type: 'array',\n items: { type: 'array', items: MAP_GEOJSON_POSITION_SCHEMA },\n },\n },\n ],\n}\n\nconst MAP_GEOJSON_BBOX_SCHEMA = {\n type: 'array',\n items: { type: 'number' },\n}\n\nconst MAP_GEOJSON_GEOMETRY_TYPE_SCHEMA = {\n type: 'string',\n enum: [\n 'Point',\n 'MultiPoint',\n 'LineString',\n 'MultiLineString',\n 'Polygon',\n 'MultiPolygon',\n 'GeometryCollection',\n ],\n}\n\nconst MAP_GEOJSON_SIMPLE_GEOMETRY_SCHEMA = {\n type: 'object',\n properties: {\n type: MAP_GEOJSON_GEOMETRY_TYPE_SCHEMA,\n coordinates: MAP_GEOJSON_COORDINATES_SCHEMA,\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type'],\n}\n\nconst MAP_GEOJSON_GEOMETRY_SCHEMA = {\n type: 'object',\n properties: {\n type: MAP_GEOJSON_GEOMETRY_TYPE_SCHEMA,\n coordinates: MAP_GEOJSON_COORDINATES_SCHEMA,\n geometries: { type: 'array', items: MAP_GEOJSON_SIMPLE_GEOMETRY_SCHEMA },\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type'],\n}\n\nconst MAP_GEOJSON_FEATURE_SCHEMA = {\n type: 'object',\n properties: {\n type: { type: 'string', enum: ['Feature'] },\n geometry: { oneOf: [MAP_GEOJSON_GEOMETRY_SCHEMA, { type: 'null' }] },\n properties: { oneOf: [{ type: 'object' }, { type: 'null' }] },\n id: { oneOf: [{ type: 'string' }, { type: 'number' }] },\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type', 'geometry'],\n}\n\nconst MAP_GEOJSON_FEATURE_COLLECTION_SCHEMA = {\n type: 'object',\n properties: {\n type: { type: 'string', enum: ['FeatureCollection'] },\n features: { type: 'array', items: MAP_GEOJSON_FEATURE_SCHEMA },\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type', 'features'],\n}\n\nconst MAP_GEOJSON_SCHEMA = {\n oneOf: [\n MAP_GEOJSON_FEATURE_COLLECTION_SCHEMA,\n MAP_GEOJSON_FEATURE_SCHEMA,\n MAP_GEOJSON_GEOMETRY_SCHEMA,\n ],\n description: 'GeoJSON FeatureCollection, Feature, or Geometry',\n}\n\nconst MAP_GEOJSON_STYLE_SCHEMA = {\n type: 'object',\n properties: {\n fillColor: { type: 'string' },\n fillOpacity: { type: 'number' },\n strokeColor: { type: 'string' },\n strokeWeight: { type: 'number' },\n strokeOpacity: { type: 'number' },\n choroplethField: { type: 'string' },\n choroplethScale: {\n type: 'array',\n items: {\n type: 'array',\n items: [{ type: 'number' }, { type: 'string' }],\n additionalItems: false,\n minItems: 2,\n maxItems: 2,\n },\n },\n choroplethFallback: { type: 'string' },\n },\n}\n\nconst MAP_POPUP_SCHEMA = {\n type: 'object',\n properties: {\n titleField: { type: 'string' },\n fields: { type: 'array', items: { type: 'string' } },\n template: {\n type: 'string',\n description: 'Trusted-host HTML template; ignored on the default untrusted renderer path',\n },\n },\n}\n\nexport const MapRegistry: ComponentRegistryEntry = {\n type: 'map',\n name: 'InteractiveMap',\n description:\n 'Render interactive maps on the default OpenStreetMap base layer (using Leaflet internally) from already-resolved markers, GeoJSON, named layers, clustering, or PMTiles. The renderer does not geocode place names.',\n schema: {\n type: 'object',\n properties: {\n center: {\n ...MAP_LAT_LNG_POINT_SCHEMA,\n description: 'Initial map center as [lat, lng] or { lat, lng }',\n },\n zoom: { type: 'number', description: 'Initial zoom level (default: 13)' },\n markers: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n position: MAP_LAT_LNG_POINT_SCHEMA,\n tooltip: { type: 'string' },\n popup: { type: 'string' },\n },\n required: ['position'],\n },\n },\n height: { type: 'string', description: 'CSS height (default: 400px)' },\n fitBounds: { type: 'boolean', description: 'Auto-fit to rendered markers and features' },\n zoomControl: { type: 'boolean', description: 'Show Leaflet zoom controls' },\n scrollWheelZoom: { type: 'boolean', description: 'Allow scroll-wheel zoom' },\n tileLayer: {\n type: 'string',\n description:\n 'Optional base tile URL template (defaults to OpenStreetMap); the host remains responsible for network policy',\n },\n attribution: { type: 'string', description: 'Base-map attribution' },\n className: { type: 'string', description: 'Custom CSS class' },\n geojson: MAP_GEOJSON_SCHEMA,\n geojsonStyle: MAP_GEOJSON_STYLE_SCHEMA,\n popup: MAP_POPUP_SCHEMA,\n layers: {\n type: 'array',\n description: 'Named GeoJSON overlays',\n items: {\n type: 'object',\n properties: {\n name: { type: 'string', minLength: 1 },\n visible: { type: 'boolean' },\n geojson: MAP_GEOJSON_SCHEMA,\n style: MAP_GEOJSON_STYLE_SCHEMA,\n popup: MAP_POPUP_SCHEMA,\n },\n required: ['name', 'geojson'],\n },\n },\n clustering: {\n oneOf: [\n { type: 'boolean' },\n {\n type: 'object',\n properties: {\n maxClusterRadius: { type: 'number' },\n spiderfyOnMaxZoom: { type: 'boolean' },\n showCoverageOnHover: { type: 'boolean' },\n disableClusteringAtZoom: { type: 'number' },\n animateAddingMarkers: { type: 'boolean' },\n },\n },\n ],\n description: 'Enable marker clustering or provide cluster options',\n },\n pmtiles: {\n type: 'object',\n description: 'PMTiles vector-tile overlay (requires the optional protomaps-leaflet peer)',\n properties: {\n url: { type: 'string' },\n attribution: { type: 'string' },\n paintRules: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n dataLayer: { type: 'string' },\n symbolizer: { type: 'string', enum: ['polygon', 'line', 'circle'] },\n color: { type: 'string' },\n width: { type: 'number' },\n opacity: { type: 'number' },\n },\n required: ['dataLayer', 'symbolizer'],\n },\n },\n labelRules: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n dataLayer: { type: 'string' },\n textField: { type: 'string' },\n fontSize: { type: 'number' },\n },\n required: ['dataLayer', 'textField'],\n },\n },\n maxZoom: { type: 'number' },\n minZoom: { type: 'number' },\n },\n required: ['url'],\n },\n },\n required: [],\n },\n examples: [\n {\n query: 'Show office locations on a map',\n component: {\n id: 'example-map-1',\n type: 'map',\n position: { colStart: 1, colSpan: 12 },\n params: {\n center: [48.8566, 2.3522],\n zoom: 5,\n markers: [\n { position: [48.8566, 2.3522], tooltip: 'Paris', popup: 'HQ — 120 employees' },\n { position: [51.5074, -0.1278], tooltip: 'London', popup: 'UK Office — 45 employees' },\n ],\n fitBounds: true,\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Graph Registry Entry (v6.12.0 — audit P1.5)\n */\nexport const GraphRegistry: ComponentRegistryEntry = {\n type: 'graph',\n name: 'NodeLinkGraph',\n description:\n 'Render a node-link graph (entities and their relationships) with @antv/g6. Best for provenance/source chains, dependency or process graphs, and ontology-lite entity/relation views. Degrades to an edge table when the graph engine is unavailable.',\n schema: {\n type: 'object',\n properties: {\n nodes: {\n type: 'array',\n description: 'Graph nodes (at least one required)',\n items: {\n type: 'object',\n properties: {\n id: { type: 'string' },\n label: { type: 'string' },\n group: { type: 'string' },\n },\n required: ['id'],\n },\n },\n edges: {\n type: 'array',\n description: 'Edges between node ids',\n items: {\n type: 'object',\n properties: {\n source: { type: 'string' },\n target: { type: 'string' },\n label: { type: 'string' },\n weight: { type: 'number' },\n },\n required: ['source', 'target'],\n },\n },\n layout: {\n type: 'string',\n enum: ['force', 'radial', 'grid', 'dagre', 'circular'],\n description: 'Layout algorithm (default: force)',\n },\n directed: { type: 'boolean', description: 'Render edges as directed (arrows)' },\n },\n required: ['nodes'],\n },\n examples: [\n {\n query: 'Show how this figure was derived',\n component: {\n id: 'example-graph-1',\n type: 'graph',\n position: { colStart: 1, colSpan: 12 },\n params: {\n directed: true,\n layout: 'dagre',\n nodes: [\n { id: 'claim', label: 'Population = 522 250', group: 'claim' },\n { id: 'source', label: 'INSEE 2021', group: 'source' },\n ],\n edges: [{ source: 'claim', target: 'source', label: 'derived from' }],\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Form Registry Entry\n */\nexport const FormRegistry: ComponentRegistryEntry = {\n type: 'form',\n name: 'Form',\n description:\n 'Render interactive forms with text inputs, selects, checkboxes, date pickers, and conditional fields. Supports persistence, validation, and submit actions that trigger MCP tool calls.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string', description: 'Form title' },\n fields: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n name: { type: 'string' },\n label: { type: 'string' },\n type: { type: 'string', enum: ['text', 'number', 'email', 'password', 'textarea', 'select', 'checkbox', 'radio', 'date'] },\n required: { type: 'boolean' },\n placeholder: { type: 'string' },\n options: { type: 'array', items: { type: 'object', properties: { label: { type: 'string' }, value: { type: 'string' } } } },\n },\n required: ['name', 'label', 'type'],\n },\n },\n submitLabel: { type: 'string', description: 'Submit button text (default: \"Submit\")' },\n layout: { type: 'string', enum: ['vertical', 'horizontal', 'inline'] },\n },\n required: ['fields'],\n },\n examples: [\n {\n query: 'Create a document upload form',\n component: {\n id: 'example-form-1',\n type: 'form',\n position: { colStart: 1, colSpan: 6 },\n params: {\n title: 'Upload Document',\n fields: [\n { name: 'title', label: 'Document Title', type: 'text', required: true },\n { name: 'category', label: 'Category', type: 'select', options: [{ label: 'Report', value: 'report' }, { label: 'Invoice', value: 'invoice' }] },\n { name: 'notes', label: 'Notes', type: 'textarea' },\n ],\n submitLabel: 'Upload',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Modal Registry Entry\n */\nexport const ModalRegistry: ComponentRegistryEntry = {\n type: 'modal',\n name: 'Modal',\n description:\n 'Render a dialog overlay with Portal rendering. Supports sizes from small to fullscreen, close on Escape/backdrop, and nested content. Best for confirmations, detail views, and focused interactions.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string', description: 'Modal header title' },\n size: { type: 'string', enum: ['sm', 'md', 'lg', 'xl', 'full'], description: 'Modal width (default: md)' },\n showClose: { type: 'boolean', description: 'Show close button (default: true)' },\n closeOnEscape: { type: 'boolean', description: 'Close on Escape key (default: true)' },\n closeOnBackdrop: { type: 'boolean', description: 'Close on backdrop click (default: true)' },\n maxHeight: { type: 'string', description: 'CSS max-height for scrollable content' },\n },\n required: [],\n },\n examples: [\n {\n query: 'Show document details in a dialog',\n component: {\n id: 'example-modal-1',\n type: 'modal',\n position: { colStart: 1, colSpan: 12 },\n params: {\n title: 'Document Details',\n size: 'lg',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Action Group Registry Entry\n */\nexport const ActionGroupRegistry: ComponentRegistryEntry = {\n type: 'action-group',\n name: 'ActionGroup',\n description:\n 'Render a group of action buttons in horizontal, vertical, or grid layout. Each action triggers an MCP tool call. Best for presenting multiple related actions like CRUD operations or workflow steps.',\n schema: {\n type: 'object',\n properties: {\n actions: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n label: { type: 'string' },\n toolName: { type: 'string' },\n params: { type: 'object' },\n variant: { type: 'string', enum: ['primary', 'secondary', 'danger', 'ghost'] },\n icon: { type: 'string' },\n },\n required: ['label', 'toolName'],\n },\n },\n layout: { type: 'string', enum: ['horizontal', 'vertical', 'grid'], description: 'Button layout' },\n label: { type: 'string', description: 'Group label' },\n },\n required: ['actions'],\n },\n examples: [\n {\n query: 'Show actions for this document',\n component: {\n id: 'example-action-group-1',\n type: 'action-group',\n position: { colStart: 1, colSpan: 6 },\n params: {\n label: 'Document Actions',\n actions: [\n { label: 'Download', type: 'button', action: 'tool-call', toolName: 'document_download', params: { id: '123' }, variant: 'primary' },\n { label: 'Share', type: 'button', action: 'tool-call', toolName: 'document_share', params: { id: '123' }, variant: 'secondary' },\n { label: 'Delete', type: 'button', action: 'tool-call', toolName: 'document_delete', params: { id: '123' }, variant: 'danger' },\n ],\n layout: 'horizontal',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Image Gallery Registry Entry\n */\nexport const ImageGalleryRegistry: ComponentRegistryEntry = {\n type: 'image-gallery',\n name: 'ImageGallery',\n description:\n 'Render a grid of images with lightbox overlay for fullscreen viewing. Supports captions, configurable columns, aspect ratios, and keyboard navigation in lightbox mode.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string', description: 'Gallery title' },\n images: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Image URL' },\n alt: { type: 'string', description: 'Alt text' },\n caption: { type: 'string', description: 'Caption text' },\n thumbnail: { type: 'string', description: 'Thumbnail URL (optional, falls back to url)' },\n },\n required: ['url'],\n },\n },\n columns: { type: 'number', enum: [2, 3, 4, 5], description: 'Grid columns (default: 3)' },\n aspectRatio: { type: 'string', enum: ['1:1', '16:9', '4:3', 'auto'] },\n lightbox: { type: 'boolean', description: 'Enable lightbox overlay (default: true)' },\n },\n required: ['images'],\n },\n examples: [\n {\n query: 'Show document thumbnails',\n component: {\n id: 'example-gallery-1',\n type: 'image-gallery',\n position: { colStart: 1, colSpan: 12 },\n params: {\n title: 'Recent Documents',\n images: [\n { url: '/thumbnails/doc1.png', alt: 'Q4 Report', caption: 'Q4 Report — 24 pages' },\n { url: '/thumbnails/doc2.png', alt: 'Invoice #4521', caption: 'Invoice #4521' },\n ],\n columns: 4,\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Video Registry Entry\n */\nexport const VideoRegistry: ComponentRegistryEntry = {\n type: 'video',\n name: 'Video',\n description:\n 'Embed video from YouTube, Vimeo, or direct URLs. Auto-detects provider from URL and renders appropriate embed. Supports aspect ratios, autoplay, and start time.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Video URL (YouTube, Vimeo, or direct)' },\n title: { type: 'string', description: 'Video title' },\n caption: { type: 'string', description: 'Caption below video' },\n aspectRatio: { type: 'string', enum: ['16:9', '4:3', '1:1', '21:9'], description: 'Aspect ratio (default: 16:9)' },\n autoplay: { type: 'boolean', description: 'Auto-play video' },\n startTime: { type: 'number', description: 'Start time in seconds' },\n },\n required: ['url'],\n },\n examples: [\n {\n query: 'Show the product demo video',\n component: {\n id: 'example-video-1',\n type: 'video',\n position: { colStart: 1, colSpan: 8 },\n params: {\n url: 'https://www.youtube.com/watch?v=dQw4w9WgXcQ',\n title: 'Product Demo',\n aspectRatio: '16:9',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Iframe Registry Entry\n */\nexport const IframeRegistry: ComponentRegistryEntry = {\n type: 'iframe',\n name: 'Iframe',\n description:\n 'Embed external content via sandboxed iframe. Domain whitelist enforced for security. Supports Mermaid diagrams, Excalidraw, GitHub Gists, Figma, and 60+ whitelisted domains.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'URL to embed (must be on whitelist)' },\n title: { type: 'string', description: 'Iframe title for accessibility' },\n height: { type: 'string', description: 'CSS height (default: 400px)' },\n sandbox: { type: 'string', description: 'Sandbox attribute (default: restrictive)' },\n },\n required: ['url'],\n },\n examples: [\n {\n query: 'Show the architecture diagram',\n component: {\n id: 'example-iframe-1',\n type: 'iframe',\n position: { colStart: 1, colSpan: 12 },\n params: {\n url: 'https://mermaid.ink/svg/graph+TD;A-->B;B-->C',\n title: 'Architecture Diagram',\n height: '500px',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Image Registry Entry\n */\nexport const ImageRegistry: ComponentRegistryEntry = {\n type: 'image',\n name: 'Image',\n description:\n 'Render a single image with optional alt text, caption, and link. Best for logos, screenshots, diagrams, or any standalone visual content.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Image URL' },\n alt: { type: 'string', description: 'Alt text for accessibility' },\n title: { type: 'string', description: 'Image title / heading' },\n width: { type: 'string', description: 'CSS width' },\n height: { type: 'string', description: 'CSS height' },\n },\n required: ['url'],\n },\n examples: [\n {\n query: 'Show the company logo',\n component: {\n id: 'example-image-1',\n type: 'image',\n position: { colStart: 1, colSpan: 4 },\n params: {\n url: '/images/logo.png',\n alt: 'Company Logo',\n } as any,\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Link Registry Entry\n */\nexport const LinkRegistry: ComponentRegistryEntry = {\n type: 'link',\n name: 'Link',\n description:\n 'Render a styled link card with title, description, and URL. Best for navigation, references, and external resource links.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Link destination URL' },\n label: { type: 'string', description: 'Link display text' },\n description: { type: 'string', description: 'Link description' },\n icon: { type: 'string', description: 'Icon identifier' },\n },\n required: ['url', 'label'],\n },\n examples: [\n {\n query: 'Link to the API documentation',\n component: {\n id: 'example-link-1',\n type: 'link',\n position: { colStart: 1, colSpan: 4 },\n params: {\n url: 'https://docs.example.com/api',\n label: 'API Documentation',\n description: 'Full reference for the REST API',\n } as any,\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Component Registry - All components indexed by type\n */\nexport const ComponentRegistry: Map<ComponentType, ComponentRegistryEntry> = new Map([\n ['chart', QuickchartRegistry],\n ['table', TableRegistry],\n ['metric', MetricRegistry],\n ['text', TextRegistry],\n // Sprint 4 additions\n ['grid', GridRegistry],\n ['action', ActionRegistry],\n ['footer', FooterRegistry],\n ['carousel', CarouselRegistry],\n ['artifact', ArtifactRegistry],\n // v2.2.5: Complete registry\n ['code', CodeRegistry],\n ['map', MapRegistry],\n ['graph', GraphRegistry], // v6.12.0: audit P1.5 — registry/schema parity\n\n ['form', FormRegistry],\n ['modal', ModalRegistry],\n ['action-group', ActionGroupRegistry],\n ['image-gallery', ImageGalleryRegistry],\n ['video', VideoRegistry],\n ['iframe', IframeRegistry],\n ['image', ImageRegistry],\n ['link', LinkRegistry],\n])\n\n/**\n * Get component registry entry by type\n */\nexport function getComponentEntry(type: ComponentType): ComponentRegistryEntry | undefined {\n return ComponentRegistry.get(type)\n}\n\n/**\n * Get all component types\n */\nexport function getAllComponentTypes(): ComponentType[] {\n return Array.from(ComponentRegistry.keys())\n}\n\n/**\n * Get registry as JSON for LLM context\n */\nexport function getRegistryForLLM(): string {\n const entries = Array.from(ComponentRegistry.values()).map((entry) => ({\n type: entry.type,\n name: entry.name,\n description: entry.description,\n schema: entry.schema,\n examples: entry.examples.map((ex) => ({\n query: ex.query,\n component: ex.component,\n })),\n limits: entry.limits,\n }))\n\n return JSON.stringify(entries, null, 2)\n}\n\n/**\n * Validate component against registry schema\n * (Future: Use Zod for runtime validation)\n */\nexport function validateAgainstRegistry(\n componentType: ComponentType,\n params: any\n): { valid: boolean; errors?: string[]; warnings?: string[] } {\n const entry = getComponentEntry(componentType)\n if (!entry) {\n // Warn but don't block — renderer may exist even without registry entry\n return { valid: true, warnings: [`No registry entry for type: ${componentType}`] }\n }\n\n // Basic validation (Phase 1 will add Zod schema validation)\n const required = entry.schema.required || []\n const missing = required.filter((key: string) => !(key in params))\n\n if (missing.length > 0) {\n return {\n valid: false,\n errors: missing.map((key: string) => `Missing required field: ${key}`),\n }\n }\n\n return { valid: true }\n}\n"],"names":["DEFAULT_RESOURCE_LIMITS"],"mappings":";;;AAeO,MAAM,qBAA6C;AAAA,EACxD,MAAM;AAAA,EACN,MAAM;AAAA,EACN,aACE;AAAA,EACF,QAAQ;AAAA,IACN,MAAM;AAAA,IACN,YAAY;AAAA,MACV,MAAM;AAAA,QACJ,MAAM;AAAA,QACN,MAAM,CAAC,OAAO,QAAQ,OAAO,YAAY,SAAS,SAAS;AAAA,QAC3D,aAAa;AAAA,MAAA;AAAA,MAEf,OAAO;AAAA,QACL,MAAM;AAAA,QACN,aAAa;AAAA,MAAA;AAAA,MAEf,MAAM;AAAA,QACJ,MAAM;AAAA,QACN,YAAY;AAAA,UACV,QAAQ;AAAA,YACN,MAAM;AAAA,YACN,OAAO,EAAE,MAAM,SAAA;AAAA,YACf,aAAa;AAAA,UAAA;AAAA,UAEf,UAAU;AAAA,YACR,MAAM;AAAA,YACN,OAAO;AAAA,cACL,MAAM;AAAA,cACN,YAAY;AAAA,gBACV,OAAO,EAAE,MAAM,SAAA;AAAA,gBACf,MAAM;AAAA,kBACJ,MAAM;AAAA,kBACN,OAAO,EAA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,UAAU,cAAc;AAAA,EACzB,CAAC,QAAQ,YAAY;AAAA;AAAA,EAErB,CAAC,QAAQ,YAAY;AAAA,EACrB,CAAC,UAAU,cAAc;AAAA,EACzB,CAAC,UAAU,cAAc;AAAA,EACzB,CAAC,YAAY,gBAAgB;AAAA,EAC7B,CAAC,YAAY,gBAAgB;AAAA;AAAA,EAE7B,CAAC,QAAQ,YAAY;AAAA,EACrB,CAAC,OAAO,WAAW;AAAA,EACnB,CAAC,SAAS,aAAa;AAAA;AAAA,EAEvB,CAAC,QAAQ,YAAY;AAAA,EACrB,CAAC,SAAS,aAAa;AAAA,EACvB,CAAC,gBAAgB,mBAAmB;AAAA,EACpC,CAAC,iBAAiB,oBAAoB;AAAA,EACtC,CAAC,SAAS,aAAa;AAAA,EACvB,CAAC,UAAU,cAAc;AAAA,EACzB,CAAC,SAAS,aAAa;AAAA,EACvB,CAAC,QAAQ,YAAY;AACvB,CAAC;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"component-registry.cjs","sources":["../../src/services/component-registry.ts"],"sourcesContent":["/**\n * Component Registry Service\n * Phase 0: Static registry with Chart and Table definitions\n * Phase 1: Dynamic registry populated from /api/mcp/tools/list\n *\n * Provides component schemas for LLM prompt engineering\n */\n\nimport type { ComponentRegistryEntry, ComponentType } from '../types'\nimport { DEFAULT_RESOURCE_LIMITS } from './validation'\n\n/**\n * Chart Component Registry Entry\n *\n * The historical export name is retained for source compatibility. The\n * renderer is local-first: Chart.js is the native implementation, while the\n * external QuickChart fallback is a host-level opt-in.\n */\nexport const QuickchartRegistry: ComponentRegistryEntry = {\n type: 'chart',\n name: 'Chart.js',\n description:\n 'Render charts locally with Chart.js. Supports bar, line, pie, doughnut, radar, scatter, bubble, and polarArea charts, including point and time-series data. An external QuickChart fallback is available only when the host explicitly opts in.',\n schema: {\n type: 'object',\n properties: {\n type: {\n type: 'string',\n enum: ['bar', 'line', 'pie', 'doughnut', 'radar', 'scatter', 'bubble', 'polarArea'],\n description: 'Chart type',\n },\n title: {\n type: 'string',\n description: 'Chart title (optional)',\n },\n data: {\n type: 'object',\n properties: {\n labels: {\n type: 'array',\n items: { type: 'string' },\n description: 'X-axis labels',\n },\n datasets: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n label: { type: 'string' },\n data: {\n // Empty arrays match both branches; mirror Zod's inclusive union.\n anyOf: [\n { type: 'array', items: { type: 'number' } },\n {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n x: { oneOf: [{ type: 'string' }, { type: 'number' }] },\n y: { type: 'number' },\n r: { type: 'number', minimum: 0 },\n },\n required: ['x', 'y'],\n },\n },\n ],\n },\n backgroundColor: {\n oneOf: [{ type: 'string' }, { type: 'array', items: { type: 'string' } }],\n },\n borderColor: {\n oneOf: [{ type: 'string' }, { type: 'array', items: { type: 'string' } }],\n },\n borderWidth: { type: 'number' },\n fill: { oneOf: [{ type: 'boolean' }, { type: 'string' }] },\n tension: { type: 'number' },\n },\n required: ['label', 'data'],\n },\n },\n },\n required: ['labels', 'datasets'],\n },\n options: {\n type: 'object',\n description: 'Supported Chart.js options for customization',\n properties: {\n responsive: { type: 'boolean' },\n maintainAspectRatio: { type: 'boolean' },\n tension: { type: 'number' },\n scales: {},\n plugins: {},\n },\n },\n renderer: {\n type: 'string',\n enum: ['native', 'iframe', 'auto'],\n description: 'Renderer preference; external iframe use still requires host opt-in',\n },\n exportable: { type: 'boolean', description: 'Show the PNG export action' },\n timeAxis: {\n type: 'object',\n description:\n 'Time-series x-axis configuration; the host must install and register a compatible Chart.js date adapter',\n properties: {\n parser: { type: 'string' },\n unit: { type: 'string', enum: ['day', 'week', 'month', 'quarter', 'year'] },\n tooltipFormat: { type: 'string' },\n min: { type: 'string' },\n max: { type: 'string' },\n },\n },\n height: { type: 'string', description: 'Chart container height as a CSS value' },\n className: { type: 'string' },\n },\n required: ['type', 'data'],\n },\n examples: [\n {\n query: 'Show me document types distribution',\n component: {\n id: 'example-bar-1',\n type: 'chart',\n position: { colStart: 1, colSpan: 6 },\n params: {\n type: 'bar',\n title: 'Document Types',\n data: {\n labels: ['PDF', 'DOCX', 'TXT', 'XLSX'],\n datasets: [\n {\n label: 'Count',\n data: [245, 189, 123, 98],\n backgroundColor: ['rgba(59, 130, 246, 0.8)'],\n },\n ],\n },\n },\n },\n },\n {\n query: 'Display upload trends over the last week',\n component: {\n id: 'example-line-1',\n type: 'chart',\n position: { colStart: 1, colSpan: 6 },\n params: {\n type: 'line',\n title: 'Upload Trends',\n data: {\n labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],\n datasets: [\n {\n label: 'Uploads',\n data: [42, 38, 51, 47, 63, 29, 15],\n borderColor: 'rgb(59, 130, 246)',\n },\n ],\n },\n options: {\n tension: 0.4,\n },\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Table Component Registry Entry\n */\nexport const TableRegistry: ComponentRegistryEntry = {\n type: 'table',\n name: 'DataTable',\n description:\n 'Render tabular data with sortable columns, client-side search, context-aware paging, virtualization, and export controls. Best for structured records with up to 100 rows per payload.',\n schema: {\n type: 'object',\n properties: {\n title: {\n type: 'string',\n description: 'Table title (optional)',\n },\n columns: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n key: { type: 'string', description: 'Data key for this column' },\n label: { type: 'string', description: 'Column header label' },\n sortable: { type: 'boolean', description: 'Whether column is sortable' },\n width: { type: 'string', description: 'CSS width (e.g., \"30%\")' },\n },\n required: ['key', 'label'],\n },\n minItems: 1,\n },\n rows: {\n type: 'array',\n items: {\n type: 'object',\n description: 'Row data matching column keys',\n },\n maxItems: 100,\n },\n pagination: {\n type: 'object',\n description: 'Legacy server-pagination metadata',\n properties: {\n currentPage: { type: 'number' },\n pageSize: { type: 'number' },\n totalRows: { type: 'number' },\n },\n },\n searchable: {\n type: 'boolean',\n description: 'Show the client-side search field (default: true)',\n },\n searchPlaceholder: { type: 'string', description: 'Search field placeholder' },\n pageSize: {\n type: 'integer',\n minimum: 0,\n description: 'Rows per page in expanded mode (default: 25; 0 disables client paging)',\n },\n chatPageSize: {\n type: 'integer',\n minimum: 0,\n description: 'Rows per page in chat mode (default: min(10, pageSize); 0 disables client paging)',\n },\n initialPage: {\n type: 'integer',\n minimum: 0,\n description: 'Initial zero-based client page',\n },\n virtualize: {\n oneOf: [\n { type: 'boolean' },\n {\n type: 'object',\n properties: {\n enabled: { type: 'boolean' },\n rowHeight: { type: 'integer', minimum: 1 },\n overscan: { type: 'integer', minimum: 0 },\n threshold: { type: 'integer', minimum: 1 },\n },\n },\n ],\n },\n exportable: {\n oneOf: [\n { type: 'boolean' },\n {\n type: 'object',\n properties: {\n formats: {\n type: 'array',\n items: { type: 'string', enum: ['csv', 'tsv', 'json'] },\n },\n filename: { type: 'string' },\n },\n },\n ],\n },\n className: { type: 'string' },\n citationMap: { type: 'object', description: 'Citation metadata keyed by marker id' },\n maxHeight: {\n oneOf: [{ type: 'string' }, { type: 'number' }],\n description: \"Inline table height cap; use 'auto' to disable it\",\n },\n },\n required: ['columns', 'rows'],\n },\n examples: [\n {\n query: 'Show me the most recent documents',\n component: {\n id: 'example-table-1',\n type: 'table',\n position: { colStart: 1, colSpan: 8 },\n params: {\n title: 'Recent Documents',\n columns: [\n { key: 'name', label: 'Name', sortable: true, width: '40%' },\n { key: 'type', label: 'Type', sortable: true, width: '15%' },\n { key: 'size', label: 'Size', width: '15%' },\n { key: 'modified', label: 'Modified', sortable: true, width: '30%' },\n ],\n rows: [\n { name: 'Report.pdf', type: 'PDF', size: '2.4 MB', modified: '2 hours ago' },\n { name: 'Slides.pptx', type: 'PPTX', size: '8.7 MB', modified: '1 day ago' },\n ],\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Metric Card Component Registry Entry\n */\nexport const MetricRegistry: ComponentRegistryEntry = {\n type: 'metric',\n name: 'MetricCard',\n description:\n 'Display a single metric with optional trend indicator. Best for KPIs, statistics, and summary numbers. Supports trend direction (up/down/neutral) and subtitles.',\n schema: {\n type: 'object',\n properties: {\n title: {\n type: 'string',\n description: 'Metric title',\n },\n value: {\n oneOf: [{ type: 'string' }, { type: 'number' }],\n description: 'Metric value',\n },\n unit: {\n type: 'string',\n description: 'Unit of measurement (optional)',\n },\n trend: {\n type: 'object',\n properties: {\n value: { type: 'number', description: 'Percentage change' },\n direction: { type: 'string', enum: ['up', 'down', 'neutral'] },\n },\n },\n subtitle: {\n type: 'string',\n description: 'Additional context (optional)',\n },\n },\n required: ['title', 'value'],\n },\n examples: [\n {\n query: 'Show total document count',\n component: {\n id: 'example-metric-1',\n type: 'metric',\n position: { colStart: 1, colSpan: 3 },\n params: {\n title: 'Total Documents',\n value: '1,247',\n trend: {\n value: 12.5,\n direction: 'up',\n },\n subtitle: '+142 this month',\n },\n },\n },\n ],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 5 * 1024, // 5KB\n renderTimeout: 1000, // 1s\n },\n}\n\n/**\n * Text Component Registry Entry\n */\nexport const TextRegistry: ComponentRegistryEntry = {\n type: 'text',\n name: 'TextBlock',\n description:\n 'Render text content with optional markdown support. Best for explanations, summaries, and context. Supports basic HTML formatting.',\n schema: {\n type: 'object',\n properties: {\n content: {\n type: 'string',\n description: 'Text content (HTML allowed, will be sanitized)',\n },\n markdown: {\n type: 'boolean',\n description: 'Whether content is markdown (not yet implemented)',\n },\n className: {\n type: 'string',\n description: 'Custom CSS classes',\n },\n },\n required: ['content'],\n },\n examples: [\n {\n query: 'Explain the document distribution',\n component: {\n id: 'example-text-1',\n type: 'text',\n position: { colStart: 1, colSpan: 12 },\n params: {\n content:\n '<p>Your document library contains <strong>1,247 files</strong> across 5 different formats. PDFs represent the largest category at 35% of total storage.</p>',\n },\n },\n },\n ],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 10 * 1024, // 10KB\n renderTimeout: 1000, // 1s\n },\n}\n\n// ============================================================================\n// Sprint 4: Additional Component Registry Entries\n// ============================================================================\n\n/**\n * Grid Component Registry Entry\n * Nested CSS Grid layout for organizing multiple components\n */\nexport const GridRegistry: ComponentRegistryEntry = {\n type: 'grid',\n name: 'GridLayout',\n description:\n 'Nested CSS Grid layout for organizing multiple components. Supports named areas, responsive columns (1-12), and custom gap spacing. Best for complex dashboard layouts and template builder.',\n schema: {\n type: 'object',\n properties: {\n columns: {\n type: 'number',\n description: 'Number of columns (default: 12)',\n },\n gap: {\n type: 'string',\n description: 'Gap between items (e.g., \"1rem\")',\n },\n minRowHeight: {\n type: 'string',\n description: 'Minimum row height (optional)',\n },\n areas: {\n type: 'array',\n items: {\n type: 'array',\n items: { type: 'string' },\n },\n description: 'CSS Grid template areas for named regions',\n },\n children: {\n type: 'array',\n items: { type: 'object' },\n description: 'Child UIComponents to render within the grid',\n },\n },\n required: ['children'],\n },\n examples: [],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Action Component Registry Entry\n * Interactive button or link that triggers tool calls\n */\nexport const ActionRegistry: ComponentRegistryEntry = {\n type: 'action',\n name: 'ActionButton',\n description:\n 'Interactive button or link that triggers tool calls or navigation. Best for user interactions, form submissions, and workflow triggers.',\n schema: {\n type: 'object',\n properties: {\n label: {\n type: 'string',\n description: 'Button text',\n },\n type: {\n type: 'string',\n enum: ['button', 'link'],\n description: 'Render as button or link',\n },\n action: {\n type: 'string',\n enum: ['tool-call', 'link', 'submit'],\n description: 'Action type to perform',\n },\n toolName: {\n type: 'string',\n description: 'Tool name to call (for tool-call action)',\n },\n params: {\n type: 'object',\n description: 'Parameters to pass to the tool',\n },\n url: {\n type: 'string',\n description: 'URL for link action',\n },\n variant: {\n type: 'string',\n enum: ['primary', 'secondary', 'outline', 'ghost', 'danger'],\n description: 'Visual style variant',\n },\n size: {\n type: 'string',\n enum: ['sm', 'md', 'lg'],\n description: 'Button size',\n },\n disabled: {\n type: 'boolean',\n description: 'Whether the action is disabled',\n },\n },\n required: ['label', 'type', 'action'],\n },\n examples: [],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Footer Component Registry Entry\n * Display execution metadata like timing and source count\n */\nexport const FooterRegistry: ComponentRegistryEntry = {\n type: 'footer',\n name: 'FooterSection',\n description:\n 'Footer section displaying execution metadata. Best for showing timing, model info, and source counts. Auto-injected by layouts when metadata is provided.',\n schema: {\n type: 'object',\n properties: {\n poweredBy: {\n type: 'string',\n description: 'Powered by text (optional)',\n },\n executionTime: {\n type: 'number',\n description: 'Execution time in milliseconds',\n },\n model: {\n type: 'string',\n description: 'LLM model used',\n },\n sourceCount: {\n type: 'number',\n description: 'Number of sources used',\n },\n customText: {\n type: 'string',\n description: 'Custom footer text',\n },\n links: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n label: { type: 'string' },\n url: { type: 'string' },\n },\n },\n description: 'Footer links',\n },\n },\n },\n examples: [],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 5 * 1024,\n renderTimeout: 1000,\n },\n}\n\n/**\n * Carousel Component Registry Entry\n * Display multiple items with horizontal scrolling\n */\nexport const CarouselRegistry: ComponentRegistryEntry = {\n type: 'carousel',\n name: 'Carousel',\n description:\n 'Horizontal carousel for displaying multiple items with snap scrolling and navigation buttons. Best for showcasing related content, image galleries, or card collections.',\n schema: {\n type: 'object',\n properties: {\n items: {\n type: 'array',\n items: { type: 'object' },\n description: 'Array of UIComponents to display in carousel',\n },\n height: {\n type: 'string',\n description: 'Carousel height (optional)',\n },\n },\n required: ['items'],\n },\n examples: [],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Artifact Component Registry Entry\n * Display downloadable artifacts like generated files\n */\nexport const ArtifactRegistry: ComponentRegistryEntry = {\n type: 'artifact',\n name: 'Artifact',\n description:\n 'Display downloadable artifacts like generated files or exports. Shows filename, size, and download button. Best for CSV exports, PDF reports, and generated documents.',\n schema: {\n type: 'object',\n properties: {\n url: {\n type: 'string',\n description: 'Download URL for the artifact',\n },\n filename: {\n type: 'string',\n description: 'Display filename',\n },\n mimeType: {\n type: 'string',\n description: 'MIME type (e.g., \"text/csv\", \"application/pdf\")',\n },\n size: {\n type: 'number',\n description: 'File size in bytes',\n },\n description: {\n type: 'string',\n description: 'Description of the artifact',\n },\n },\n required: ['url', 'filename', 'mimeType'],\n },\n examples: [],\n limits: {\n maxDataPoints: 1,\n maxTableRows: 1,\n maxPayloadSize: 5 * 1024,\n renderTimeout: 1000,\n },\n}\n\n/**\n * Code Block Registry Entry\n */\nexport const CodeRegistry: ComponentRegistryEntry = {\n type: 'code',\n name: 'CodeBlock',\n description:\n 'Render syntax-highlighted code blocks with line numbers, copy button, and word wrap toggle. Supports all languages via highlight.js auto-detection. Best for displaying source code, configuration files, CLI output, or API responses.',\n schema: {\n type: 'object',\n properties: {\n code: { type: 'string', description: 'The code content to display' },\n language: { type: 'string', description: 'Programming language for syntax highlighting (auto-detected if omitted)' },\n filename: { type: 'string', description: 'Filename shown in header bar' },\n showLineNumbers: { type: 'boolean', description: 'Show line numbers (default: true)' },\n startLine: { type: 'number', description: 'Starting line number (default: 1)' },\n maxHeight: { type: 'string', description: 'CSS max-height for scrollable code blocks' },\n theme: { type: 'string', enum: ['light', 'dark'], description: 'Color theme (follows system preference by default)' },\n },\n required: ['code'],\n },\n examples: [\n {\n query: 'Show me how to connect to the API',\n component: {\n id: 'example-code-1',\n type: 'code',\n position: { colStart: 1, colSpan: 8 },\n params: {\n code: 'const client = new MCPClient({ url: \"https://api.example.com\" });\\nawait client.connect();\\nconst result = await client.query(\"SELECT * FROM documents\");',\n language: 'typescript',\n filename: 'example.ts',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Map Registry Entry\n */\nconst MAP_LAT_LNG_POINT_SCHEMA = {\n oneOf: [\n {\n type: 'array',\n items: { type: 'number' },\n minItems: 2,\n maxItems: 2,\n description: '[latitude, longitude] tuple',\n },\n {\n type: 'object',\n properties: {\n lat: { type: 'number' },\n lng: { type: 'number' },\n },\n required: ['lat', 'lng'],\n description: '{ lat, lng } object',\n },\n ],\n}\n\nconst MAP_GEOJSON_POSITION_SCHEMA = {\n type: 'array',\n items: { type: 'number' },\n minItems: 2,\n}\n\nconst MAP_GEOJSON_COORDINATES_SCHEMA = {\n anyOf: [\n MAP_GEOJSON_POSITION_SCHEMA,\n { type: 'array', items: MAP_GEOJSON_POSITION_SCHEMA },\n { type: 'array', items: { type: 'array', items: MAP_GEOJSON_POSITION_SCHEMA } },\n {\n type: 'array',\n items: {\n type: 'array',\n items: { type: 'array', items: MAP_GEOJSON_POSITION_SCHEMA },\n },\n },\n ],\n}\n\nconst MAP_GEOJSON_BBOX_SCHEMA = {\n type: 'array',\n items: { type: 'number' },\n}\n\nconst MAP_GEOJSON_GEOMETRY_TYPE_SCHEMA = {\n type: 'string',\n enum: [\n 'Point',\n 'MultiPoint',\n 'LineString',\n 'MultiLineString',\n 'Polygon',\n 'MultiPolygon',\n 'GeometryCollection',\n ],\n}\n\nconst MAP_GEOJSON_SIMPLE_GEOMETRY_SCHEMA = {\n type: 'object',\n properties: {\n type: MAP_GEOJSON_GEOMETRY_TYPE_SCHEMA,\n coordinates: MAP_GEOJSON_COORDINATES_SCHEMA,\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type'],\n}\n\nconst MAP_GEOJSON_GEOMETRY_SCHEMA = {\n type: 'object',\n properties: {\n type: MAP_GEOJSON_GEOMETRY_TYPE_SCHEMA,\n coordinates: MAP_GEOJSON_COORDINATES_SCHEMA,\n geometries: { type: 'array', items: MAP_GEOJSON_SIMPLE_GEOMETRY_SCHEMA },\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type'],\n}\n\nconst MAP_GEOJSON_FEATURE_SCHEMA = {\n type: 'object',\n properties: {\n type: { type: 'string', enum: ['Feature'] },\n geometry: { oneOf: [MAP_GEOJSON_GEOMETRY_SCHEMA, { type: 'null' }] },\n properties: { oneOf: [{ type: 'object' }, { type: 'null' }] },\n id: { oneOf: [{ type: 'string' }, { type: 'number' }] },\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type', 'geometry'],\n}\n\nconst MAP_GEOJSON_FEATURE_COLLECTION_SCHEMA = {\n type: 'object',\n properties: {\n type: { type: 'string', enum: ['FeatureCollection'] },\n features: { type: 'array', items: MAP_GEOJSON_FEATURE_SCHEMA },\n bbox: MAP_GEOJSON_BBOX_SCHEMA,\n },\n required: ['type', 'features'],\n}\n\nconst MAP_GEOJSON_SCHEMA = {\n oneOf: [\n MAP_GEOJSON_FEATURE_COLLECTION_SCHEMA,\n MAP_GEOJSON_FEATURE_SCHEMA,\n MAP_GEOJSON_GEOMETRY_SCHEMA,\n ],\n description: 'GeoJSON FeatureCollection, Feature, or Geometry',\n}\n\nconst MAP_GEOJSON_STYLE_SCHEMA = {\n type: 'object',\n properties: {\n fillColor: { type: 'string' },\n fillOpacity: { type: 'number' },\n strokeColor: { type: 'string' },\n strokeWeight: { type: 'number' },\n strokeOpacity: { type: 'number' },\n choroplethField: { type: 'string' },\n choroplethScale: {\n type: 'array',\n items: {\n type: 'array',\n items: [{ type: 'number' }, { type: 'string' }],\n additionalItems: false,\n minItems: 2,\n maxItems: 2,\n },\n },\n choroplethFallback: { type: 'string' },\n },\n}\n\nconst MAP_POPUP_SCHEMA = {\n type: 'object',\n properties: {\n titleField: { type: 'string' },\n fields: { type: 'array', items: { type: 'string' } },\n template: {\n type: 'string',\n description: 'Trusted-host HTML template; ignored on the default untrusted renderer path',\n },\n },\n}\n\nexport const MapRegistry: ComponentRegistryEntry = {\n type: 'map',\n name: 'InteractiveMap',\n description:\n 'Render interactive maps on the default OpenStreetMap base layer (using Leaflet internally) from already-resolved markers, GeoJSON, named layers, clustering, or PMTiles. The renderer does not geocode place names.',\n schema: {\n type: 'object',\n properties: {\n center: {\n ...MAP_LAT_LNG_POINT_SCHEMA,\n description: 'Initial map center as [lat, lng] or { lat, lng }',\n },\n zoom: { type: 'number', description: 'Initial zoom level (default: 13)' },\n markers: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n position: MAP_LAT_LNG_POINT_SCHEMA,\n tooltip: { type: 'string' },\n popup: { type: 'string' },\n },\n required: ['position'],\n },\n },\n height: { type: 'string', description: 'CSS height (default: 400px)' },\n fitBounds: { type: 'boolean', description: 'Auto-fit to rendered markers and features' },\n zoomControl: { type: 'boolean', description: 'Show Leaflet zoom controls' },\n scrollWheelZoom: { type: 'boolean', description: 'Allow scroll-wheel zoom' },\n tileLayer: {\n type: 'string',\n description:\n 'Optional base tile URL template (defaults to OpenStreetMap); the host remains responsible for network policy',\n },\n attribution: { type: 'string', description: 'Base-map attribution' },\n className: { type: 'string', description: 'Custom CSS class' },\n geojson: MAP_GEOJSON_SCHEMA,\n geojsonStyle: MAP_GEOJSON_STYLE_SCHEMA,\n popup: MAP_POPUP_SCHEMA,\n layers: {\n type: 'array',\n description: 'Named GeoJSON overlays',\n items: {\n type: 'object',\n properties: {\n name: { type: 'string', minLength: 1 },\n visible: { type: 'boolean' },\n geojson: MAP_GEOJSON_SCHEMA,\n style: MAP_GEOJSON_STYLE_SCHEMA,\n popup: MAP_POPUP_SCHEMA,\n },\n required: ['name', 'geojson'],\n },\n },\n clustering: {\n oneOf: [\n { type: 'boolean' },\n {\n type: 'object',\n properties: {\n maxClusterRadius: { type: 'number' },\n spiderfyOnMaxZoom: { type: 'boolean' },\n showCoverageOnHover: { type: 'boolean' },\n disableClusteringAtZoom: { type: 'number' },\n animateAddingMarkers: { type: 'boolean' },\n },\n },\n ],\n description: 'Enable marker clustering or provide cluster options',\n },\n pmtiles: {\n type: 'object',\n description: 'PMTiles vector-tile overlay (requires the optional protomaps-leaflet peer)',\n properties: {\n url: { type: 'string' },\n attribution: { type: 'string' },\n paintRules: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n dataLayer: { type: 'string' },\n symbolizer: { type: 'string', enum: ['polygon', 'line', 'circle'] },\n color: { type: 'string' },\n width: { type: 'number' },\n opacity: { type: 'number' },\n },\n required: ['dataLayer', 'symbolizer'],\n },\n },\n labelRules: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n dataLayer: { type: 'string' },\n textField: { type: 'string' },\n fontSize: { type: 'number' },\n },\n required: ['dataLayer', 'textField'],\n },\n },\n maxZoom: { type: 'number' },\n minZoom: { type: 'number' },\n },\n required: ['url'],\n },\n },\n required: [],\n },\n examples: [\n {\n query: 'Show office locations on a map',\n component: {\n id: 'example-map-1',\n type: 'map',\n position: { colStart: 1, colSpan: 12 },\n params: {\n center: [48.8566, 2.3522],\n zoom: 5,\n markers: [\n { position: [48.8566, 2.3522], tooltip: 'Paris', popup: 'HQ — 120 employees' },\n { position: [51.5074, -0.1278], tooltip: 'London', popup: 'UK Office — 45 employees' },\n ],\n fitBounds: true,\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Graph Registry Entry (v6.12.0 — audit P1.5)\n */\nexport const GraphRegistry: ComponentRegistryEntry = {\n type: 'graph',\n name: 'NodeLinkGraph',\n description:\n 'Render a node-link graph (entities and their relationships) with the optional @antv/g6 peer. Best for provenance/source chains, dependency or process graphs, and ontology-lite entity/relation views.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string' },\n nodes: {\n type: 'array',\n description: 'Graph nodes (at least one required)',\n minItems: 1,\n items: {\n type: 'object',\n properties: {\n id: { type: 'string', minLength: 1 },\n label: { type: 'string' },\n type: { type: 'string' },\n size: {\n oneOf: [\n { type: 'number' },\n {\n type: 'array',\n items: [{ type: 'number' }, { type: 'number' }],\n additionalItems: false,\n minItems: 2,\n maxItems: 2,\n },\n ],\n },\n weight: { type: 'number' },\n style: { type: 'object' },\n data: { type: 'object' },\n },\n required: ['id'],\n },\n },\n edges: {\n type: 'array',\n description: 'Edges between node ids',\n items: {\n type: 'object',\n properties: {\n source: { type: 'string', minLength: 1 },\n target: { type: 'string', minLength: 1 },\n label: { type: 'string' },\n type: { type: 'string' },\n weight: { type: 'number' },\n style: { type: 'object' },\n data: { type: 'object' },\n },\n required: ['source', 'target'],\n },\n },\n layout: {\n oneOf: [\n {\n type: 'string',\n enum: ['force', 'dagre', 'mindmap', 'tree', 'circular', 'grid', 'concentric'],\n },\n {\n type: 'object',\n properties: {\n type: {\n type: 'string',\n enum: ['force', 'dagre', 'mindmap', 'tree', 'circular', 'grid', 'concentric'],\n },\n options: { type: 'object' },\n },\n required: ['type'],\n },\n ],\n description: 'Layout shorthand or layout-plus-options object',\n },\n height: { type: 'string' },\n width: { type: 'string' },\n rendererPref: { type: 'string', enum: ['canvas'] },\n fitView: { type: 'boolean' },\n enableZoom: { type: 'boolean' },\n enableDrag: { type: 'boolean' },\n enableSelect: { type: 'boolean' },\n tooltip: { type: 'boolean' },\n className: { type: 'string' },\n },\n required: ['nodes'],\n },\n examples: [\n {\n query: 'Show how this figure was derived',\n component: {\n id: 'example-graph-1',\n type: 'graph',\n position: { colStart: 1, colSpan: 12 },\n params: {\n layout: 'dagre',\n nodes: [\n { id: 'claim', label: 'Population = 522 250', weight: 2 },\n { id: 'source', label: 'INSEE 2021', weight: 1 },\n ],\n edges: [{ source: 'claim', target: 'source', label: 'derived from' }],\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Form Registry Entry\n */\nexport const FormRegistry: ComponentRegistryEntry = {\n type: 'form',\n name: 'Form',\n description:\n 'Render interactive forms with text inputs, selects, checkboxes, date pickers, and conditional fields. Supports persistence, validation, and submit actions that trigger MCP tool calls.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string', description: 'Form title' },\n fields: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n name: { type: 'string' },\n label: { type: 'string' },\n type: { type: 'string', enum: ['text', 'number', 'email', 'password', 'textarea', 'select', 'checkbox', 'radio', 'date'] },\n required: { type: 'boolean' },\n placeholder: { type: 'string' },\n options: { type: 'array', items: { type: 'object', properties: { label: { type: 'string' }, value: { type: 'string' } } } },\n },\n required: ['name', 'label', 'type'],\n },\n },\n submitLabel: { type: 'string', description: 'Submit button text (default: \"Submit\")' },\n layout: { type: 'string', enum: ['vertical', 'horizontal', 'inline'] },\n },\n required: ['fields'],\n },\n examples: [\n {\n query: 'Create a document upload form',\n component: {\n id: 'example-form-1',\n type: 'form',\n position: { colStart: 1, colSpan: 6 },\n params: {\n title: 'Upload Document',\n fields: [\n { name: 'title', label: 'Document Title', type: 'text', required: true },\n { name: 'category', label: 'Category', type: 'select', options: [{ label: 'Report', value: 'report' }, { label: 'Invoice', value: 'invoice' }] },\n { name: 'notes', label: 'Notes', type: 'textarea' },\n ],\n submitLabel: 'Upload',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Modal Registry Entry\n */\nexport const ModalRegistry: ComponentRegistryEntry = {\n type: 'modal',\n name: 'Modal',\n description:\n 'Render a dialog overlay with Portal rendering. Supports sizes from small to fullscreen, close on Escape/backdrop, and nested content. Best for confirmations, detail views, and focused interactions.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string', description: 'Modal header title' },\n size: { type: 'string', enum: ['sm', 'md', 'lg', 'xl', 'full'], description: 'Modal width (default: md)' },\n showClose: { type: 'boolean', description: 'Show close button (default: true)' },\n closeOnEscape: { type: 'boolean', description: 'Close on Escape key (default: true)' },\n closeOnBackdrop: { type: 'boolean', description: 'Close on backdrop click (default: true)' },\n maxHeight: { type: 'string', description: 'CSS max-height for scrollable content' },\n },\n required: [],\n },\n examples: [\n {\n query: 'Show document details in a dialog',\n component: {\n id: 'example-modal-1',\n type: 'modal',\n position: { colStart: 1, colSpan: 12 },\n params: {\n title: 'Document Details',\n size: 'lg',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Action Group Registry Entry\n */\nexport const ActionGroupRegistry: ComponentRegistryEntry = {\n type: 'action-group',\n name: 'ActionGroup',\n description:\n 'Render a group of action buttons in horizontal, vertical, or grid layout. Each action triggers an MCP tool call. Best for presenting multiple related actions like CRUD operations or workflow steps.',\n schema: {\n type: 'object',\n properties: {\n actions: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n label: { type: 'string' },\n toolName: { type: 'string' },\n params: { type: 'object' },\n variant: { type: 'string', enum: ['primary', 'secondary', 'danger', 'ghost'] },\n icon: { type: 'string' },\n },\n required: ['label', 'toolName'],\n },\n },\n layout: { type: 'string', enum: ['horizontal', 'vertical', 'grid'], description: 'Button layout' },\n label: { type: 'string', description: 'Group label' },\n },\n required: ['actions'],\n },\n examples: [\n {\n query: 'Show actions for this document',\n component: {\n id: 'example-action-group-1',\n type: 'action-group',\n position: { colStart: 1, colSpan: 6 },\n params: {\n label: 'Document Actions',\n actions: [\n { label: 'Download', type: 'button', action: 'tool-call', toolName: 'document_download', params: { id: '123' }, variant: 'primary' },\n { label: 'Share', type: 'button', action: 'tool-call', toolName: 'document_share', params: { id: '123' }, variant: 'secondary' },\n { label: 'Delete', type: 'button', action: 'tool-call', toolName: 'document_delete', params: { id: '123' }, variant: 'danger' },\n ],\n layout: 'horizontal',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Image Gallery Registry Entry\n */\nexport const ImageGalleryRegistry: ComponentRegistryEntry = {\n type: 'image-gallery',\n name: 'ImageGallery',\n description:\n 'Render a grid of images with lightbox overlay for fullscreen viewing. Supports captions, configurable columns, aspect ratios, and keyboard navigation in lightbox mode.',\n schema: {\n type: 'object',\n properties: {\n title: { type: 'string', description: 'Gallery title' },\n images: {\n type: 'array',\n items: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Image URL' },\n alt: { type: 'string', description: 'Alt text' },\n caption: { type: 'string', description: 'Caption text' },\n thumbnail: { type: 'string', description: 'Thumbnail URL (optional, falls back to url)' },\n },\n required: ['url'],\n },\n },\n columns: { type: 'number', enum: [2, 3, 4, 5], description: 'Grid columns (default: 3)' },\n aspectRatio: { type: 'string', enum: ['1:1', '16:9', '4:3', 'auto'] },\n lightbox: { type: 'boolean', description: 'Enable lightbox overlay (default: true)' },\n },\n required: ['images'],\n },\n examples: [\n {\n query: 'Show document thumbnails',\n component: {\n id: 'example-gallery-1',\n type: 'image-gallery',\n position: { colStart: 1, colSpan: 12 },\n params: {\n title: 'Recent Documents',\n images: [\n { url: '/thumbnails/doc1.png', alt: 'Q4 Report', caption: 'Q4 Report — 24 pages' },\n { url: '/thumbnails/doc2.png', alt: 'Invoice #4521', caption: 'Invoice #4521' },\n ],\n columns: 4,\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Video Registry Entry\n */\nexport const VideoRegistry: ComponentRegistryEntry = {\n type: 'video',\n name: 'Video',\n description:\n 'Embed video from YouTube, Vimeo, or direct URLs. Auto-detects provider from URL and renders appropriate embed. Supports aspect ratios, autoplay, and start time.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Video URL (YouTube, Vimeo, or direct)' },\n title: { type: 'string', description: 'Video title' },\n caption: { type: 'string', description: 'Caption below video' },\n aspectRatio: { type: 'string', enum: ['16:9', '4:3', '1:1', '21:9'], description: 'Aspect ratio (default: 16:9)' },\n autoplay: { type: 'boolean', description: 'Auto-play video' },\n startTime: { type: 'number', description: 'Start time in seconds' },\n },\n required: ['url'],\n },\n examples: [\n {\n query: 'Show the product demo video',\n component: {\n id: 'example-video-1',\n type: 'video',\n position: { colStart: 1, colSpan: 8 },\n params: {\n url: 'https://www.youtube.com/watch?v=dQw4w9WgXcQ',\n title: 'Product Demo',\n aspectRatio: '16:9',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Iframe Registry Entry\n */\nexport const IframeRegistry: ComponentRegistryEntry = {\n type: 'iframe',\n name: 'Iframe',\n description:\n 'Embed external content via sandboxed iframe. Domain whitelist enforced for security. Supports Mermaid diagrams, Excalidraw, GitHub Gists, Figma, and 60+ whitelisted domains.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'URL to embed (must be on whitelist)' },\n title: { type: 'string', description: 'Iframe title for accessibility' },\n height: { type: 'string', description: 'CSS height (default: 400px)' },\n sandbox: { type: 'string', description: 'Sandbox attribute (default: restrictive)' },\n },\n required: ['url'],\n },\n examples: [\n {\n query: 'Show the architecture diagram',\n component: {\n id: 'example-iframe-1',\n type: 'iframe',\n position: { colStart: 1, colSpan: 12 },\n params: {\n url: 'https://mermaid.ink/svg/graph+TD;A-->B;B-->C',\n title: 'Architecture Diagram',\n height: '500px',\n },\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Image Registry Entry\n */\nexport const ImageRegistry: ComponentRegistryEntry = {\n type: 'image',\n name: 'Image',\n description:\n 'Render a single image with optional alt text, caption, and link. Best for logos, screenshots, diagrams, or any standalone visual content.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Image URL' },\n alt: { type: 'string', description: 'Alt text for accessibility' },\n title: { type: 'string', description: 'Image title / heading' },\n width: { type: 'string', description: 'CSS width' },\n height: { type: 'string', description: 'CSS height' },\n },\n required: ['url'],\n },\n examples: [\n {\n query: 'Show the company logo',\n component: {\n id: 'example-image-1',\n type: 'image',\n position: { colStart: 1, colSpan: 4 },\n params: {\n url: '/images/logo.png',\n alt: 'Company Logo',\n } as any,\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Link Registry Entry\n */\nexport const LinkRegistry: ComponentRegistryEntry = {\n type: 'link',\n name: 'Link',\n description:\n 'Render a styled link card with title, description, and URL. Best for navigation, references, and external resource links.',\n schema: {\n type: 'object',\n properties: {\n url: { type: 'string', description: 'Link destination URL' },\n label: { type: 'string', description: 'Link display text' },\n description: { type: 'string', description: 'Link description' },\n icon: { type: 'string', description: 'Icon identifier' },\n },\n required: ['url', 'label'],\n },\n examples: [\n {\n query: 'Link to the API documentation',\n component: {\n id: 'example-link-1',\n type: 'link',\n position: { colStart: 1, colSpan: 4 },\n params: {\n url: 'https://docs.example.com/api',\n label: 'API Documentation',\n description: 'Full reference for the REST API',\n } as any,\n },\n },\n ],\n limits: DEFAULT_RESOURCE_LIMITS,\n}\n\n/**\n * Component Registry - All components indexed by type\n */\nexport const ComponentRegistry: Map<ComponentType, ComponentRegistryEntry> = new Map([\n ['chart', QuickchartRegistry],\n ['table', TableRegistry],\n ['metric', MetricRegistry],\n ['text', TextRegistry],\n // Sprint 4 additions\n ['grid', GridRegistry],\n ['action', ActionRegistry],\n ['footer', FooterRegistry],\n ['carousel', CarouselRegistry],\n ['artifact', ArtifactRegistry],\n // v2.2.5: Complete registry\n ['code', CodeRegistry],\n ['map', MapRegistry],\n ['graph', GraphRegistry], // v6.12.0: audit P1.5 — registry/schema parity\n\n ['form', FormRegistry],\n ['modal', ModalRegistry],\n ['action-group', ActionGroupRegistry],\n ['image-gallery', ImageGalleryRegistry],\n ['video', VideoRegistry],\n ['iframe', IframeRegistry],\n ['image', ImageRegistry],\n ['link', LinkRegistry],\n])\n\n/**\n * Get component registry entry by type\n */\nexport function getComponentEntry(type: ComponentType): ComponentRegistryEntry | undefined {\n return ComponentRegistry.get(type)\n}\n\n/**\n * Get all component types\n */\nexport function getAllComponentTypes(): ComponentType[] {\n return Array.from(ComponentRegistry.keys())\n}\n\n/**\n * Get registry as JSON for LLM context\n */\nexport function getRegistryForLLM(): string {\n const entries = Array.from(ComponentRegistry.values()).map((entry) => ({\n type: entry.type,\n name: entry.name,\n description: entry.description,\n schema: entry.schema,\n examples: entry.examples.map((ex) => ({\n query: ex.query,\n component: ex.component,\n })),\n limits: entry.limits,\n }))\n\n return JSON.stringify(entries, null, 2)\n}\n\n/**\n * Validate component against registry schema\n * (Future: Use Zod for runtime validation)\n */\nexport function validateAgainstRegistry(\n componentType: ComponentType,\n params: any\n): { valid: boolean; errors?: string[]; warnings?: string[] } {\n const entry = getComponentEntry(componentType)\n if (!entry) {\n // Warn but don't block — renderer may exist even without registry entry\n return { valid: true, warnings: [`No registry entry for type: ${componentType}`] }\n }\n\n // Basic validation (Phase 1 will add Zod schema validation)\n const required = entry.schema.required || []\n const missing = required.filter((key: string) => !(key in params))\n\n if (missing.length > 0) {\n return {\n valid: false,\n errors: missing.map((key: string) => `Missing required field: ${key}`),\n }\n }\n\n return { valid: true }\n}\n"],"names":["DEFAULT_RESOURCE_LIMITS"],"mappings":";;;AAkBO,MAAM,qBAA6C;AAAA,EACxD,MAAM;AAAA,EACN,MAAM;AAAA,EACN,aACE;AAAA,EACF,QAAQ;AAAA,IACN,MAAM;AAAA,IACN,YAAY;AAAA,MACV,MAAM;AAAA,QACJ,MAAM;AAAA,QACN,MAAM,CAAC,OAAO,QAAQ,OAAO,YAAY,SAAS,WAAW,UAAU,WAAW;AAAA,QAClF,aAAa;AAAA,MAAA;AAAA,MAEf,OAAO;AAAA,QACL,MAAM;AAAA,QACN,aAAa;AAAA,MAAA;AAAA,MAEf,MAAM;AAAA,QACJ,MAAM;AAAA,QACN,YAAY;AAAA,UACV,QAAQ;AAAA,YACN,MAAM;AAAA,YACN,OAAO,EAAE,MAAM,SAAA;AAAA,YACf,aAAa;AAAA,UAAA;AAAA,UAEf,UAAU;AAAA,YACR,MAAM;AAAA,YACN,OAAO;AAAA,cACL,MAAM;AAAA,cACN,YAAY;AAAA,gBACV,OAAO,EAAE,MAAM,SAAA;AAAA,gBACf,MAAM;AAAA;AAAA,kBAEJ,OAAO;AAAA,oBACL,EAAE,MAAM,SAAS,OAAO,EAAE,MAAM,WAAS;AAAA,oBACzC;AAAA,sBACE,MAAM;AAAA,sBACN,OAAO;AAAA,wBACL,MAAM;AAAA,wBACN,YAAY;AAAA,0BACV,GAAG,EAAE,OAAO,CAAC,EAAE,MAAM,SAAA,GAAY,EAAE,MAAM,SAAA,CAAU,EAAA;AAAA,0BACnD,GAAG,EAAE,MAAM,SAAA;AAAA,0BACX,GAAG,EAAE,MAAM,UAAU,SAAS,EAAA;AAAA,wBAAE;AAAA,wBAElC,UAAU,CAAC,KAAK,GAAG;AAAA,sBAAA;AAAA,oBACrB;AAAA,kB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