@rio-cloud/uikit-mcp 1.1.9 → 1.1.11

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 (211) hide show
  1. package/README.md +2 -1
  2. package/dist/doc-metadata.json +334 -94
  3. package/dist/docs/components/accentBar.md +110 -116
  4. package/dist/docs/components/activity.md +1 -1
  5. package/dist/docs/components/analyticsAnalysisOverlay.md +630 -0
  6. package/dist/docs/components/animatedNumber.md +2 -2
  7. package/dist/docs/components/animatedTextReveal.md +53 -55
  8. package/dist/docs/components/animations.md +21 -21
  9. package/dist/docs/components/appHeader.md +27 -38
  10. package/dist/docs/components/appLayout.md +23 -77
  11. package/dist/docs/components/appNavigationBar.md +1 -1
  12. package/dist/docs/components/areaCharts.md +57 -61
  13. package/dist/docs/components/aspectRatioPlaceholder.md +1 -1
  14. package/dist/docs/components/assetTree.md +429 -342
  15. package/dist/docs/components/autosuggests.md +1 -1
  16. package/dist/docs/components/avatar.md +1 -1
  17. package/dist/docs/components/banner.md +2 -2
  18. package/dist/docs/components/barCharts.md +530 -414
  19. package/dist/docs/components/barList.md +10 -10
  20. package/dist/docs/components/basicMap.md +104 -39
  21. package/dist/docs/components/bottomSheet.md +2 -2
  22. package/dist/docs/components/button.md +8 -2
  23. package/dist/docs/components/buttonToolbar.md +1 -1
  24. package/dist/docs/components/calendarStripe.md +59 -63
  25. package/dist/docs/components/card.md +1 -1
  26. package/dist/docs/components/carousel.md +1 -1
  27. package/dist/docs/components/chartColors.md +1 -1
  28. package/dist/docs/components/chartsGettingStarted.md +1 -1
  29. package/dist/docs/components/chat.md +2 -2
  30. package/dist/docs/components/checkbox.md +15 -10
  31. package/dist/docs/components/circularProgress.md +6 -6
  32. package/dist/docs/components/clearableInput.md +1 -1
  33. package/dist/docs/components/collapse.md +2 -2
  34. package/dist/docs/components/composedCharts.md +63 -51
  35. package/dist/docs/components/contentLoader.md +1 -1
  36. package/dist/docs/components/dataTabs.md +33 -33
  37. package/dist/docs/components/datepickers.md +693 -685
  38. package/dist/docs/components/dayPicker.md +5624 -0
  39. package/dist/docs/components/dayPickerCalendar.md +5289 -0
  40. package/dist/docs/components/dialogs.md +17 -19
  41. package/dist/docs/components/divider.md +1 -1
  42. package/dist/docs/components/dropdowns.md +3264 -3276
  43. package/dist/docs/components/editableContent.md +91 -91
  44. package/dist/docs/components/expander.md +4 -1
  45. package/dist/docs/components/fade.md +1 -1
  46. package/dist/docs/components/fadeExpander.md +1 -1
  47. package/dist/docs/components/fadeUp.md +32 -36
  48. package/dist/docs/components/feedback.md +1 -1
  49. package/dist/docs/components/filePickers.md +1 -1
  50. package/dist/docs/components/formLabel.md +29 -31
  51. package/dist/docs/components/groupedItemList.md +3 -7
  52. package/dist/docs/components/htmlTable.md +5074 -0
  53. package/dist/docs/components/iconList.md +4 -4
  54. package/dist/docs/components/imagePreloader.md +1 -1
  55. package/dist/docs/components/labeledElement.md +1 -1
  56. package/dist/docs/components/licensePlate.md +1 -1
  57. package/dist/docs/components/lineCharts.md +172 -170
  58. package/dist/docs/components/listMenu.md +15 -12
  59. package/dist/docs/components/loadMore.md +4 -2
  60. package/dist/docs/components/mainNavigation.md +1 -1
  61. package/dist/docs/components/mapCircle.md +10 -1
  62. package/dist/docs/components/mapCluster.md +25 -1
  63. package/dist/docs/components/mapContext.md +12 -4
  64. package/dist/docs/components/mapDraggableMarker.md +12 -1
  65. package/dist/docs/components/mapGettingStarted.md +39 -1
  66. package/dist/docs/components/mapInfoBubble.md +129 -2
  67. package/dist/docs/components/mapLayerGroup.md +10 -1
  68. package/dist/docs/components/mapMarker.md +10 -1
  69. package/dist/docs/components/mapPolygon.md +288 -85
  70. package/dist/docs/components/mapRoute.md +262 -172
  71. package/dist/docs/components/mapSettings.md +28 -1
  72. package/dist/docs/components/mapUtils.md +1 -1
  73. package/dist/docs/components/mapViewportHistory.md +287 -0
  74. package/dist/docs/components/multiselects.md +217 -18
  75. package/dist/docs/components/noData.md +1 -1
  76. package/dist/docs/components/notifications.md +2 -2
  77. package/dist/docs/components/numbercontrol.md +15 -15
  78. package/dist/docs/components/onboarding.md +1 -1
  79. package/dist/docs/components/page.md +1 -1
  80. package/dist/docs/components/pager.md +1 -1
  81. package/dist/docs/components/pieCharts.md +237 -211
  82. package/dist/docs/components/popover.md +1 -1
  83. package/dist/docs/components/position.md +1 -1
  84. package/dist/docs/components/radialBarCharts.md +446 -398
  85. package/dist/docs/components/radioCardGroup.md +1 -1
  86. package/dist/docs/components/radiobutton.md +98 -98
  87. package/dist/docs/components/releaseNotes.md +1 -1
  88. package/dist/docs/components/resizer.md +1 -1
  89. package/dist/docs/components/responsiveColumnStripe.md +1 -1
  90. package/dist/docs/components/responsiveVideo.md +1 -1
  91. package/dist/docs/components/rioglyph.md +1 -1
  92. package/dist/docs/components/rules.md +41 -47
  93. package/dist/docs/components/saveableInput.md +252 -252
  94. package/dist/docs/components/selects.md +332 -161
  95. package/dist/docs/components/sidebar.md +1 -1
  96. package/dist/docs/components/sliders.md +1 -1
  97. package/dist/docs/components/smoothScrollbars.md +19 -13
  98. package/dist/docs/components/spinners.md +1 -1
  99. package/dist/docs/components/states.md +15 -1
  100. package/dist/docs/components/statsWidgets.md +1 -1
  101. package/dist/docs/components/statusBar.md +3 -1
  102. package/dist/docs/components/stepButton.md +1 -1
  103. package/dist/docs/components/steppedProgressBars.md +9 -11
  104. package/dist/docs/components/subNavigation.md +1 -1
  105. package/dist/docs/components/supportMarker.md +1 -1
  106. package/dist/docs/components/svgImage.md +1 -1
  107. package/dist/docs/components/switch.md +5 -1
  108. package/dist/docs/components/table.md +21361 -0
  109. package/dist/docs/components/tableControls.md +982 -0
  110. package/dist/docs/components/tagManager.md +1 -1
  111. package/dist/docs/components/tags.md +1 -1
  112. package/dist/docs/components/teaser.md +1 -1
  113. package/dist/docs/components/textTruncateMiddle.md +1 -1
  114. package/dist/docs/components/timeline.md +1 -1
  115. package/dist/docs/components/timepicker.md +3 -1
  116. package/dist/docs/components/toggleButton.md +3 -1
  117. package/dist/docs/components/tooltip.md +8 -2
  118. package/dist/docs/components/tracker.md +1 -1
  119. package/dist/docs/components/virtualList.md +60 -60
  120. package/dist/docs/foundations.md +761 -3077
  121. package/dist/docs/start/changelog.md +73 -3
  122. package/dist/docs/start/goodtoknow.md +5 -1
  123. package/dist/docs/start/guidelines/color-combinations.md +5 -1
  124. package/dist/docs/start/guidelines/custom-css.md +26 -2
  125. package/dist/docs/start/guidelines/custom-rioglyph.md +20 -2
  126. package/dist/docs/start/guidelines/formatting.md +2254 -249
  127. package/dist/docs/start/guidelines/iframe.md +53 -19
  128. package/dist/docs/start/guidelines/obfuscate-data.md +24 -2
  129. package/dist/docs/start/guidelines/print-css.md +16 -2
  130. package/dist/docs/start/guidelines/spinner.md +1 -1
  131. package/dist/docs/start/guidelines/state-in-url.md +1138 -11
  132. package/dist/docs/start/guidelines/supported-browsers.md +9 -2
  133. package/dist/docs/start/guidelines/writing.md +228 -2
  134. package/dist/docs/start/howto.md +155 -13
  135. package/dist/docs/start/intro.md +40 -2
  136. package/dist/docs/start/responsiveness.md +27 -1
  137. package/dist/docs/templates/ai-assistant.md +311 -0
  138. package/dist/docs/templates/common-table.md +814 -0
  139. package/dist/docs/templates/detail-views.md +846 -0
  140. package/dist/docs/templates/expandable-details.md +214 -0
  141. package/dist/docs/templates/feature-cards.md +479 -0
  142. package/dist/docs/templates/form-summary.md +179 -0
  143. package/dist/docs/templates/form-toggle.md +329 -0
  144. package/dist/docs/templates/list-blocks.md +872 -0
  145. package/dist/docs/templates/loading-progress.md +100 -0
  146. package/dist/docs/templates/options-panel.md +132 -0
  147. package/dist/docs/templates/panel-variants.md +137 -0
  148. package/dist/docs/templates/progress-cards.md +541 -0
  149. package/dist/docs/templates/progress-success.md +125 -0
  150. package/dist/docs/templates/settings-form.md +401 -0
  151. package/dist/docs/templates/stats-blocks.md +1245 -0
  152. package/dist/docs/templates/table-panel.md +310 -0
  153. package/dist/docs/templates/usage-cards.md +199 -0
  154. package/dist/docs/utilities/classNames.md +89 -1
  155. package/dist/docs/utilities/deviceUtils.md +2 -2
  156. package/dist/docs/utilities/featureToggles.md +182 -2
  157. package/dist/docs/utilities/fuelTypeUtils.md +27 -29
  158. package/dist/docs/utilities/getTrackingAttributes.md +322 -0
  159. package/dist/docs/utilities/routeUtils.md +211 -3
  160. package/dist/docs/utilities/useAfterMount.md +1 -1
  161. package/dist/docs/utilities/useAutoAnimate.md +1 -1
  162. package/dist/docs/utilities/useAverage.md +1 -1
  163. package/dist/docs/utilities/useClickOutside.md +1 -1
  164. package/dist/docs/utilities/useClipboard.md +2 -2
  165. package/dist/docs/utilities/useCookies.md +1 -1
  166. package/dist/docs/utilities/useCount.md +1 -1
  167. package/dist/docs/utilities/useDarkMode.md +5 -4
  168. package/dist/docs/utilities/useDebugInfo.md +3 -3
  169. package/dist/docs/utilities/useDraggableElement.md +281 -0
  170. package/dist/docs/utilities/useEffectOnce.md +1 -1
  171. package/dist/docs/utilities/useElapsedTime.md +1 -1
  172. package/dist/docs/utilities/useElementSize.md +1 -1
  173. package/dist/docs/utilities/useEsc.md +1 -1
  174. package/dist/docs/utilities/useEvent.md +1 -1
  175. package/dist/docs/utilities/useFocusTrap.md +1 -1
  176. package/dist/docs/utilities/useFullscreen.md +1 -1
  177. package/dist/docs/utilities/useHover.md +1 -1
  178. package/dist/docs/utilities/useIncomingPostMessages.md +1 -1
  179. package/dist/docs/utilities/useInterval.md +1 -1
  180. package/dist/docs/utilities/useIsFocusWithin.md +1 -1
  181. package/dist/docs/utilities/useKey.md +8 -10
  182. package/dist/docs/utilities/useLocalStorage.md +1 -1
  183. package/dist/docs/utilities/useLocationSuggestions.md +1 -1
  184. package/dist/docs/utilities/useMax.md +1 -1
  185. package/dist/docs/utilities/useMin.md +1 -1
  186. package/dist/docs/utilities/useMutationObserver.md +1 -1
  187. package/dist/docs/utilities/useOnScreen.md +1 -1
  188. package/dist/docs/utilities/useOnlineStatus.md +1 -1
  189. package/dist/docs/utilities/usePostMessage.md +2 -2
  190. package/dist/docs/utilities/usePostMessageSender.md +1 -1
  191. package/dist/docs/utilities/usePrevious.md +110 -2
  192. package/dist/docs/utilities/useResizeObserver.md +35 -15
  193. package/dist/docs/utilities/useRioCookieConsent.md +1 -1
  194. package/dist/docs/utilities/useScrollPosition.md +3 -6
  195. package/dist/docs/utilities/useSearch.md +1 -3
  196. package/dist/docs/utilities/useSearchHighlight.md +1 -1
  197. package/dist/docs/utilities/useSorting.md +370 -239
  198. package/dist/docs/utilities/useStateWithValidation.md +1 -1
  199. package/dist/docs/utilities/useSum.md +1 -1
  200. package/dist/docs/utilities/useTableExport.md +364 -288
  201. package/dist/docs/utilities/useTableSelection.md +88 -92
  202. package/dist/docs/utilities/useTimeout.md +1 -1
  203. package/dist/docs/utilities/useToggle.md +1 -1
  204. package/dist/docs/utilities/useUrlState.md +1 -1
  205. package/dist/docs/utilities/useWindowResize.md +1 -1
  206. package/dist/index.mjs +173 -69
  207. package/dist/search-synonyms.json +214 -76
  208. package/dist/version.json +2 -2
  209. package/package.json +4 -5
  210. package/dist/docs/components/mapRouteGenerator.md +0 -6
  211. package/dist/docs/components/tables.md +0 -8
package/dist/index.mjs CHANGED
@@ -132,7 +132,7 @@ function buildSearchIndex(entries) {
132
132
  });
133
133
  for (const entry of entries) index.add({
134
134
  id: entry.id,
135
- title: entry.title,
135
+ title: entry.indexTitle ?? entry.title,
136
136
  lead: entry.lead ?? "",
137
137
  summary: entry.summary,
138
138
  searchText: entry.searchText,
@@ -149,14 +149,163 @@ function buildSearchIndex(entries) {
149
149
  return { search };
150
150
  }
151
151
  //#endregion
152
+ //#region server/lib/search-docs.ts
153
+ function normaliseKey(value) {
154
+ return value.toLowerCase().trim();
155
+ }
156
+ function slugifyHeading(value) {
157
+ return normaliseKey(value).replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "");
158
+ }
159
+ function compactText(value) {
160
+ return value.replace(/\s+/g, " ").trim();
161
+ }
162
+ function stripMarkdownForSearch(markdown) {
163
+ return compactText(markdown.replace(/```[\s\S]*?```/g, " ").replace(/^#{1,6}\s+/gm, "").replace(/`([^`]+)`/g, "$1").replace(/\*\*([^*]+)\*\*/g, "$1").replace(/\*([^*]+)\*/g, "$1").replace(/__([^_]+)__|_([^_]+)_/g, (_, bold, italic) => bold ?? italic ?? "").replace(/<[^>]+>/g, " ").replace(/[[\]()*_>#|]/g, " "));
164
+ }
165
+ function excerpt(value, maxLength = 240) {
166
+ const text = compactText(value);
167
+ if (text.length <= maxLength) return text;
168
+ return `${text.slice(0, maxLength - 1).trimEnd()}…`;
169
+ }
170
+ function extractSecondLevelMarkdownSections(markdown) {
171
+ const sections = [];
172
+ const lines = markdown.split(/\r?\n/);
173
+ let current = null;
174
+ for (const line of lines) {
175
+ const match = /^##\s+(.+?)\s*$/.exec(line);
176
+ if (match) {
177
+ if (current) sections.push({
178
+ heading: current.heading,
179
+ body: current.bodyLines.join("\n").trim()
180
+ });
181
+ current = {
182
+ heading: match[1].trim(),
183
+ bodyLines: []
184
+ };
185
+ continue;
186
+ }
187
+ if (current) current.bodyLines.push(line);
188
+ }
189
+ if (current) sections.push({
190
+ heading: current.heading,
191
+ body: current.bodyLines.join("\n").trim()
192
+ });
193
+ return sections;
194
+ }
195
+ function expandDomainSynonyms(rawQuery, config) {
196
+ const query = normaliseKey(rawQuery);
197
+ const expansions = /* @__PURE__ */ new Set();
198
+ const preferred = /* @__PURE__ */ new Set();
199
+ const hints = /* @__PURE__ */ new Set();
200
+ const synonyms = config.synonyms ?? {};
201
+ const preferredDocIds = config.preferredDocIds ?? {};
202
+ const allKeys = new Set([
203
+ ...Object.keys(synonyms),
204
+ ...Object.keys(preferredDocIds),
205
+ ...Object.keys(config.hints ?? {})
206
+ ]);
207
+ for (const key of allKeys) {
208
+ if (!query.includes(normaliseKey(key))) continue;
209
+ for (const value of synonyms[key] ?? []) if (normaliseKey(value) !== query) expansions.add(value);
210
+ for (const id of preferredDocIds[key] ?? []) preferred.add(id);
211
+ if (config.hints?.[key]) hints.add(config.hints[key]);
212
+ }
213
+ return {
214
+ expansions: Array.from(expansions),
215
+ preferredDocIds: Array.from(preferred),
216
+ hints: Array.from(hints)
217
+ };
218
+ }
219
+ function buildFoundationSectionAliases(foundation, markdown) {
220
+ if (!foundation || !markdown) return [];
221
+ return extractSecondLevelMarkdownSections(markdown).map((section) => {
222
+ const slug = slugifyHeading(section.heading);
223
+ if (!slug) return null;
224
+ const plainText = stripMarkdownForSearch(section.body);
225
+ const guidance = `Matched section: "${section.heading}". After reading this resource, use the "## ${section.heading}" section; ignore unrelated Foundations sections unless they are needed for context.`;
226
+ const summary = plainText ? `${guidance} Section excerpt: ${excerpt(plainText)}` : guidance;
227
+ return {
228
+ id: `foundations#${slug}`,
229
+ resourceDocId: foundation.id,
230
+ title: `Foundations: ${section.heading}`,
231
+ indexTitle: section.heading,
232
+ lead: null,
233
+ summary,
234
+ searchText: [section.heading, plainText].filter(Boolean).join("\n"),
235
+ category: foundation.category,
236
+ section: foundation.section,
237
+ boost: [
238
+ section.heading,
239
+ `foundations ${section.heading}`,
240
+ `#foundations/${slug}`
241
+ ].join(" "),
242
+ matchedHeading: section.heading
243
+ };
244
+ }).filter((entry) => Boolean(entry));
245
+ }
246
+ function buildSearchEntries(metadata, options = {}) {
247
+ const foundation = metadata.find((entry) => entry.id === "foundations");
248
+ return [...metadata, ...buildFoundationSectionAliases(foundation, options.foundationMarkdown ?? null)];
249
+ }
250
+ function resolveSearchDocs(options) {
251
+ const { query, limit, index, entriesById, synonymsConfig, resourceForDocId } = options;
252
+ const searchQueue = [query];
253
+ const domainSynonyms = expandDomainSynonyms(query, synonymsConfig);
254
+ for (const extra of domainSynonyms.expansions) searchQueue.push(extra);
255
+ const seen = /* @__PURE__ */ new Set();
256
+ const results = [];
257
+ const normalizedQuery = normaliseKey(query);
258
+ function addResult(id) {
259
+ if (seen.has(id)) return results.length >= limit;
260
+ const entry = entriesById.get(id);
261
+ if (!entry) return false;
262
+ seen.add(id);
263
+ const resourceDocId = entry.resourceDocId ?? entry.id;
264
+ results.push({
265
+ resource: resourceForDocId(resourceDocId),
266
+ title: entry.title,
267
+ summary: entry.summary,
268
+ category: entry.category,
269
+ section: entry.section,
270
+ matchedHeading: entry.matchedHeading
271
+ });
272
+ return results.length >= limit;
273
+ }
274
+ if (/\bfoundations?\b/.test(normalizedQuery)) for (const entry of entriesById.values()) {
275
+ if (!entry.matchedHeading) continue;
276
+ if (!normalizedQuery.includes(normaliseKey(entry.matchedHeading))) continue;
277
+ if (addResult(entry.id)) return {
278
+ results,
279
+ domainSynonyms
280
+ };
281
+ }
282
+ for (const id of domainSynonyms.preferredDocIds) if (addResult(id)) return {
283
+ results,
284
+ domainSynonyms
285
+ };
286
+ for (const searchQuery of searchQueue) {
287
+ const hits = index.search(searchQuery, {
288
+ limit: Math.max(limit * 2, 10),
289
+ suggest: true
290
+ });
291
+ for (const group of hits) for (const id of group.result ?? []) if (addResult(String(id))) return {
292
+ results,
293
+ domainSynonyms
294
+ };
295
+ }
296
+ return {
297
+ results,
298
+ domainSynonyms
299
+ };
300
+ }
301
+ //#endregion
152
302
  //#region package.json
153
- var version = "1.1.9";
303
+ var version = "1.1.11";
154
304
  //#endregion
155
305
  //#region server/index.ts
156
306
  const DIST_ROOT = import.meta.dirname;
157
307
  const { metadata, synonyms, version: capturedVersionInfo } = loadCompiledData(DIST_ROOT);
158
308
  const CAPTURED_UIKIT_VERSION = capturedVersionInfo?.version ?? null;
159
- const metadataById = new Map(metadata.map((m) => [m.id, m]));
160
309
  const server = new McpServer({
161
310
  name: "uikit-mcp-server",
162
311
  version
@@ -169,24 +318,6 @@ const server = new McpServer({
169
318
  function buildResourceUri(docId) {
170
319
  return new URL(`uikit-doc://${docId}`);
171
320
  }
172
- function expandDomainSynonyms(rawQuery, config) {
173
- const query = rawQuery.toLowerCase();
174
- const expansions = /* @__PURE__ */ new Set();
175
- const preferred = /* @__PURE__ */ new Set();
176
- const hints = /* @__PURE__ */ new Set();
177
- for (const [key, values] of Object.entries(config.synonyms ?? {})) if (query.includes(key.toLowerCase())) {
178
- (values ?? []).forEach((value) => {
179
- if (value.toLowerCase() !== query) expansions.add(value);
180
- });
181
- (config.preferredDocIds?.[key] ?? []).forEach((id) => preferred.add(id));
182
- if (config.hints?.[key]) hints.add(config.hints[key]);
183
- }
184
- return {
185
- expansions: Array.from(expansions),
186
- preferredDocIds: Array.from(preferred),
187
- hints: Array.from(hints)
188
- };
189
- }
190
321
  function registerDocResources(docs) {
191
322
  for (const doc of docs) {
192
323
  const safeId = assertSafeDocId(doc.id);
@@ -207,7 +338,7 @@ function registerDocResources(docs) {
207
338
  }
208
339
  console.error(`Registered ${docs.length} documentation resources.`);
209
340
  }
210
- function registerSearchTool(index, metadataMap, synonymsConfig) {
341
+ function registerSearchTool(index, entriesMap, synonymsConfig) {
211
342
  const inputSchema = {
212
343
  query: z.string().min(1, "Query is required"),
213
344
  limit: z.number().int().min(1).max(20).optional()
@@ -217,7 +348,8 @@ function registerSearchTool(index, metadataMap, synonymsConfig) {
217
348
  title: z.string(),
218
349
  summary: z.string().optional(),
219
350
  category: z.string().nullish(),
220
- section: z.string().nullish()
351
+ section: z.string().nullish(),
352
+ matchedHeading: z.string().optional()
221
353
  })) };
222
354
  server.registerTool("search_docs", {
223
355
  title: "Search UI Kit docs",
@@ -231,50 +363,14 @@ function registerSearchTool(index, metadataMap, synonymsConfig) {
231
363
  openWorldHint: false
232
364
  }
233
365
  }, async ({ query, limit = 5 }) => {
234
- const searchQueue = [query];
235
- const domainSynonyms = expandDomainSynonyms(query, synonymsConfig);
236
- for (const extra of domainSynonyms.expansions) searchQueue.push(extra);
237
- const seen = /* @__PURE__ */ new Set();
238
- const resolved = [];
239
- for (const id of domainSynonyms.preferredDocIds) {
240
- if (seen.has(id)) continue;
241
- const doc = metadataMap.get(id);
242
- if (!doc) continue;
243
- seen.add(id);
244
- resolved.push({
245
- resource: buildResourceUri(id).href,
246
- title: doc.title,
247
- summary: doc.summary,
248
- category: doc.category,
249
- section: doc.section
250
- });
251
- if (resolved.length >= limit) break;
252
- }
253
- for (const searchQuery of searchQueue) {
254
- const hits = index.search(searchQuery, {
255
- limit: Math.max(limit * 2, 10),
256
- suggest: true
257
- });
258
- for (const group of hits) {
259
- for (const id of group.result ?? []) {
260
- const docId = String(id);
261
- if (seen.has(docId)) continue;
262
- seen.add(docId);
263
- const doc = metadataMap.get(docId);
264
- if (!doc) continue;
265
- resolved.push({
266
- resource: buildResourceUri(docId).href,
267
- title: doc.title,
268
- summary: doc.summary,
269
- category: doc.category,
270
- section: doc.section
271
- });
272
- if (resolved.length >= limit) break;
273
- }
274
- if (resolved.length >= limit) break;
275
- }
276
- if (resolved.length >= limit) break;
277
- }
366
+ const { results: resolved, domainSynonyms } = resolveSearchDocs({
367
+ query,
368
+ limit,
369
+ index,
370
+ entriesById: entriesMap,
371
+ synonymsConfig,
372
+ resourceForDocId: (docId) => buildResourceUri(docId).href
373
+ });
278
374
  let text = resolved.length > 0 ? resolved.map((entry, idx) => `${idx + 1}. ${entry.title} (${entry.resource})${entry.summary ? `\n ${entry.summary}` : ""}`).join("\n\n").concat("\n\nAlways call readResource on one of the URIs above instead of guessing component routes.") : `No matches for "${query}".`;
279
375
  const uniqueHints = Array.from(new Set(domainSynonyms.hints.filter(Boolean)));
280
376
  if (uniqueHints.length) text += `\n\n${uniqueHints.join("\n")}`;
@@ -289,9 +385,17 @@ function registerSearchTool(index, metadataMap, synonymsConfig) {
289
385
  });
290
386
  }
291
387
  async function main() {
292
- const index = buildSearchIndex(metadata);
388
+ let foundationMarkdown = null;
389
+ try {
390
+ foundationMarkdown = loadMarkdown(DIST_ROOT, "foundations");
391
+ } catch {
392
+ foundationMarkdown = null;
393
+ }
394
+ const searchEntries = buildSearchEntries(metadata, { foundationMarkdown });
395
+ const searchEntriesById = new Map(searchEntries.map((entry) => [entry.id, entry]));
396
+ const index = buildSearchIndex(searchEntries);
293
397
  registerDocResources(metadata);
294
- registerSearchTool(index, metadataById, synonyms);
398
+ registerSearchTool(index, searchEntriesById, synonyms);
295
399
  const docIds = new Set(metadata.map((m) => m.id));
296
400
  const missingPreferred = /* @__PURE__ */ new Set();
297
401
  for (const ids of Object.values(synonyms.preferredDocIds ?? {})) for (const id of ids ?? []) if (!docIds.has(id)) missingPreferred.add(id);
@@ -1,134 +1,272 @@
1
1
  {
2
2
  "synonyms": {
3
- "install": [
4
- "installation",
5
- "setup",
6
- "how to",
7
- "howto",
8
- "getting started"
3
+ "accordion": [
4
+ "expander"
9
5
  ],
10
- "version": [
11
- "release"
6
+ "alert": [
7
+ "notification",
8
+ "toast"
12
9
  ],
13
10
  "button": [
14
11
  "btn",
15
- "cta",
16
- "buttons"
12
+ "buttons",
13
+ "cta"
14
+ ],
15
+ "chip": [
16
+ "tag",
17
+ "badge"
18
+ ],
19
+ "csv export": [
20
+ "download",
21
+ "export",
22
+ "table export"
23
+ ],
24
+ "datagrid": [
25
+ "grid",
26
+ "table"
27
+ ],
28
+ "date picker": [
29
+ "calendar",
30
+ "datepicker"
31
+ ],
32
+ "datepicker": [
33
+ "calendar",
34
+ "date picker"
35
+ ],
36
+ "download": [
37
+ "export",
38
+ "csv export",
39
+ "table export"
17
40
  ],
18
41
  "dropdown": [
19
- "select",
20
- "combobox"
42
+ "combobox",
43
+ "select"
21
44
  ],
22
- "select": [
23
- "dropdown",
24
- "combobox"
45
+ "expander": [
46
+ "accordion"
25
47
  ],
26
- "table": [
27
- "datagrid",
28
- "grid"
48
+ "export": [
49
+ "download",
50
+ "csv export",
51
+ "table export"
29
52
  ],
30
- "datagrid": [
31
- "table",
32
- "grid"
53
+ "file picker": [
54
+ "file upload",
55
+ "filepicker",
56
+ "upload"
57
+ ],
58
+ "file upload": [
59
+ "file picker",
60
+ "filepicker",
61
+ "upload"
62
+ ],
63
+ "filepicker": [
64
+ "file picker",
65
+ "file upload",
66
+ "upload"
33
67
  ],
34
68
  "form": [
35
- "input",
36
- "field"
69
+ "field",
70
+ "input"
71
+ ],
72
+ "getting started": [
73
+ "how to use",
74
+ "install",
75
+ "installation",
76
+ "setup"
77
+ ],
78
+ "how to use": [
79
+ "getting started",
80
+ "install",
81
+ "installation",
82
+ "setup"
83
+ ],
84
+ "install": [
85
+ "getting started",
86
+ "how to",
87
+ "howto",
88
+ "installation",
89
+ "setup"
90
+ ],
91
+ "installation": [
92
+ "getting started",
93
+ "how to use",
94
+ "install",
95
+ "setup"
96
+ ],
97
+ "license plate": [
98
+ "licenseplate",
99
+ "number plate"
100
+ ],
101
+ "licenseplate": [
102
+ "license plate",
103
+ "number plate"
37
104
  ],
38
105
  "modal": [
39
106
  "dialog"
40
107
  ],
41
- "dialog": [
42
- "modal"
108
+ "notification": [
109
+ "alert",
110
+ "toast"
111
+ ],
112
+ "number plate": [
113
+ "license plate",
114
+ "licenseplate"
115
+ ],
116
+ "pager": [
117
+ "pages",
118
+ "pagination",
119
+ "paging"
120
+ ],
121
+ "pagination": [
122
+ "pager",
123
+ "pages",
124
+ "paging"
125
+ ],
126
+ "select": [
127
+ "combobox",
128
+ "dropdown"
129
+ ],
130
+ "setup": [
131
+ "getting started",
132
+ "install",
133
+ "installation"
134
+ ],
135
+ "table": [
136
+ "datagrid",
137
+ "grid"
138
+ ],
139
+ "table export": [
140
+ "csv export",
141
+ "download",
142
+ "export"
143
+ ],
144
+ "tag": [
145
+ "badge",
146
+ "chip"
43
147
  ],
44
148
  "toast": [
45
149
  "alert",
46
150
  "notification"
47
151
  ],
152
+ "upload": [
153
+ "file picker",
154
+ "file upload",
155
+ "filepicker"
156
+ ],
157
+ "version": [
158
+ "release"
159
+ ]
160
+ },
161
+ "preferredDocIds": {
162
+ "accordion": [
163
+ "components/expander"
164
+ ],
48
165
  "alert": [
49
- "toast",
50
- "notification"
166
+ "components/notifications"
51
167
  ],
52
- "datepicker": [
53
- "date picker",
54
- "calendar"
168
+ "button": [
169
+ "components/button"
170
+ ],
171
+ "chip": [
172
+ "components/tags"
173
+ ],
174
+ "csv export": [
175
+ "utilities/useTableExport"
176
+ ],
177
+ "datagrid": [
178
+ "components/table"
55
179
  ],
56
180
  "date picker": [
57
- "datepicker",
58
- "calendar"
181
+ "components/datepickers"
59
182
  ],
60
- "accordion": [
61
- "expander"
183
+ "datepicker": [
184
+ "components/datepickers"
185
+ ],
186
+ "dialog": [
187
+ "components/dialogs"
188
+ ],
189
+ "download": [
190
+ "utilities/useTableExport"
191
+ ],
192
+ "dropdown": [
193
+ "components/dropdowns"
62
194
  ],
63
195
  "expander": [
64
- "accordion"
196
+ "components/expander"
65
197
  ],
66
- "chip": [
67
- "tag",
68
- "badge"
198
+ "export": [
199
+ "utilities/useTableExport"
69
200
  ],
70
- "tag": [
71
- "chip",
72
- "badge"
73
- ]
74
- },
75
- "preferredDocIds": {
76
- "install": [
77
- "start/howto"
201
+ "file picker": [
202
+ "components/filePickers"
203
+ ],
204
+ "file upload": [
205
+ "components/filePickers"
206
+ ],
207
+ "filepicker": [
208
+ "components/filePickers"
78
209
  ],
79
210
  "getting started": [
80
211
  "start/howto"
81
212
  ],
82
- "setup": [
213
+ "how to use": [
83
214
  "start/howto"
84
215
  ],
85
- "version": [
216
+ "install": [
86
217
  "start/howto"
87
218
  ],
88
- "button": [
89
- "components/button"
90
- ],
91
- "dropdown": [
92
- "components/dropdowns"
93
- ],
94
- "select": [
95
- "components/dropdowns"
219
+ "installation": [
220
+ "start/howto"
96
221
  ],
97
- "table": [
98
- "components/tables"
222
+ "license plate": [
223
+ "components/licensePlate"
99
224
  ],
100
- "datagrid": [
101
- "components/tables"
225
+ "licenseplate": [
226
+ "components/licensePlate"
102
227
  ],
103
228
  "modal": [
104
229
  "components/dialogs"
105
230
  ],
106
- "dialog": [
107
- "components/dialogs"
108
- ],
109
- "toast": [
231
+ "notification": [
110
232
  "components/notifications"
111
233
  ],
112
- "alert": [
113
- "components/notifications"
234
+ "number plate": [
235
+ "components/licensePlate"
114
236
  ],
115
- "datepicker": [
116
- "components/datepickers"
237
+ "pager": [
238
+ "components/pager"
117
239
  ],
118
- "date picker": [
119
- "components/datepickers"
240
+ "pagination": [
241
+ "components/pager"
120
242
  ],
121
- "accordion": [
122
- "components/expander"
243
+ "paging": [
244
+ "components/pager"
123
245
  ],
124
- "expander": [
125
- "components/expander"
246
+ "select": [
247
+ "components/dropdowns",
248
+ "components/selects"
126
249
  ],
127
- "chip": [
128
- "components/tags"
250
+ "setup": [
251
+ "start/howto"
252
+ ],
253
+ "table": [
254
+ "components/table"
255
+ ],
256
+ "table export": [
257
+ "utilities/useTableExport"
129
258
  ],
130
259
  "tag": [
131
260
  "components/tags"
261
+ ],
262
+ "toast": [
263
+ "components/notifications"
264
+ ],
265
+ "upload": [
266
+ "components/filePickers"
267
+ ],
268
+ "version": [
269
+ "start/howto"
132
270
  ]
133
271
  }
134
272
  }
package/dist/version.json CHANGED
@@ -1,4 +1,4 @@
1
1
  {
2
- "version": "2.2.1",
3
- "captured_at": "2026-03-06T10:42:10.406Z"
2
+ "version": "2.4.0",
3
+ "captured_at": "2026-04-27T14:59:49.832Z"
4
4
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rio-cloud/uikit-mcp",
3
- "version": "1.1.9",
3
+ "version": "1.1.11",
4
4
  "description": "MCP server that serves the captured RIO UI Kit documentation to Model Context Protocol clients.",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -26,7 +26,6 @@
26
26
  "crawl:full": "tsx tools/crawl-full.ts",
27
27
  "crawl:navigation": "tsx crawler/cli/crawl-navigation.ts",
28
28
  "capture:all": "tsx crawler/cli/capture-all.ts",
29
- "mcp:demo-client": "npm run build:server && tsx tools/demo-client.ts",
30
29
  "mcp:server": "npm run build:server && node dist/index.mjs"
31
30
  },
32
31
  "dependencies": {
@@ -36,13 +35,13 @@
36
35
  },
37
36
  "overrides": {
38
37
  "@hono/node-server": "1.19.13",
39
- "hono": "4.12.12"
38
+ "hono": "4.12.14"
40
39
  },
41
40
  "devDependencies": {
42
41
  "@types/node": "24.12.2",
43
42
  "playwright": "1.59.1",
44
- "tsdown": "0.21.7",
43
+ "tsdown": "0.21.9",
45
44
  "tsx": "4.21.0",
46
- "typescript": "6.0.2"
45
+ "typescript": "6.0.3"
47
46
  }
48
47
  }
@@ -1,6 +0,0 @@
1
- # components/mapRouteGenerator
2
-
3
- *Category:* Components
4
- *Section:* Map
5
- *Source:* https://uikit.developers.rio.cloud/#/components/mapRouteGenerator
6
- *Captured:* 2026-03-06T10:41:22.292Z