@treeui/mcp 0.4.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.cjs CHANGED
@@ -34,9 +34,9 @@ var import_server = require("@modelcontextprotocol/sdk/server/index.js");
34
34
 
35
35
  // src/generated/treeui.catalog.json
36
36
  var treeui_catalog_default = {
37
- generatedAt: "2026-07-18T01:52:38.578Z",
37
+ generatedAt: "2026-07-18T23:35:26.876Z",
38
38
  packageName: "@treeui/vue",
39
- packageVersion: "0.14.0",
39
+ packageVersion: "0.16.0",
40
40
  decisionGuides: [
41
41
  {
42
42
  id: "single-choice",
@@ -186,6 +186,44 @@ var treeui_catalog_default = {
186
186
  }
187
187
  ]
188
188
  },
189
+ {
190
+ id: "navigate-or-act",
191
+ question: "Navigate somewhere vs. perform an action",
192
+ options: [
193
+ {
194
+ use: "TLink",
195
+ when: [
196
+ "Activating it changes the URL \u2014 an external link, a route, or an in-page anchor.",
197
+ "It should be openable in a new tab, copyable, and crawlable."
198
+ ],
199
+ notes: []
200
+ },
201
+ {
202
+ use: "TButton",
203
+ when: [
204
+ "Activating it runs behavior on the current page \u2014 submit, open an overlay, delete, toggle.",
205
+ "It needs sizes, action variants, or a loading state."
206
+ ],
207
+ notes: [
208
+ 'Use `variant="ghost"` when an action needs to look understated like a link.'
209
+ ]
210
+ },
211
+ {
212
+ use: "TNavMenu",
213
+ when: [
214
+ "The links are app-section navigation inside a shell or sidebar."
215
+ ],
216
+ notes: []
217
+ },
218
+ {
219
+ use: "TBreadcrumb",
220
+ when: [
221
+ "The links express where the current page sits in a hierarchy."
222
+ ],
223
+ notes: []
224
+ }
225
+ ]
226
+ },
189
227
  {
190
228
  id: "feedback-choice",
191
229
  question: "Communicate status or feedback",
@@ -980,6 +1018,22 @@ var treeui_catalog_default = {
980
1018
  type: "boolean",
981
1019
  default: "true"
982
1020
  },
1021
+ {
1022
+ name: "showCollapseButton",
1023
+ type: "boolean",
1024
+ default: "true",
1025
+ note: "Renders the built-in collapse toggle in the sidebar footer. Desktop only, and only when `collapsible` is set \u2014 no need to wire your own."
1026
+ },
1027
+ {
1028
+ name: "collapseLabel",
1029
+ type: "string",
1030
+ default: "Collapse sidebar"
1031
+ },
1032
+ {
1033
+ name: "expandLabel",
1034
+ type: "string",
1035
+ default: "Expand sidebar"
1036
+ },
983
1037
  {
984
1038
  name: "menuLabel",
985
1039
  type: "string",
@@ -1014,14 +1068,26 @@ var treeui_catalog_default = {
1014
1068
  {
1015
1069
  name: "header"
1016
1070
  },
1071
+ {
1072
+ name: "header-start"
1073
+ },
1074
+ {
1075
+ name: "sidebar-header"
1076
+ },
1017
1077
  {
1018
1078
  name: "sidebar"
1019
1079
  },
1080
+ {
1081
+ name: "sidebar-footer"
1082
+ },
1020
1083
  {
1021
1084
  name: "default"
1022
1085
  },
1023
1086
  {
1024
1087
  name: "menu-icon"
1088
+ },
1089
+ {
1090
+ name: "collapse-icon"
1025
1091
  }
1026
1092
  ],
1027
1093
  a11y: [
@@ -1049,7 +1115,10 @@ var treeui_catalog_default = {
1049
1115
  "left_and_right_variants: true",
1050
1116
  "locks_body_scroll_while_drawer_open: true",
1051
1117
  "overlay_click_closes_when_enabled: true",
1052
- "exposes_slot_props_with_mobile_collapsed_and_toggles: true"
1118
+ "exposes_slot_props_with_mobile_collapsed_and_toggles: true",
1119
+ "sidebar_footer_pinned_to_bottom: true",
1120
+ "sidebar_header_and_footer_inset_to_align_with_nav_icons: true",
1121
+ "header_mirrors_shell_columns_when_header_start_is_used: true"
1053
1122
  ],
1054
1123
  selection: {
1055
1124
  keywords: [
@@ -1358,6 +1427,18 @@ var treeui_catalog_default = {
1358
1427
  name: "type",
1359
1428
  type: "button | submit | reset",
1360
1429
  default: "button"
1430
+ },
1431
+ {
1432
+ name: "block",
1433
+ type: "boolean",
1434
+ default: "false",
1435
+ note: "Stretches the button to the full width of its container. Useful for menu rows and mobile CTAs."
1436
+ },
1437
+ {
1438
+ name: "align",
1439
+ type: "start | center | end",
1440
+ default: "center",
1441
+ note: "Content alignment; only meaningful together with `block`. Use `start` for left-aligned icon+label menu rows."
1361
1442
  }
1362
1443
  ],
1363
1444
  events: [
@@ -1423,7 +1504,6 @@ var treeui_catalog_default = {
1423
1504
  values: [
1424
1505
  "outline",
1425
1506
  "soft",
1426
- "solid",
1427
1507
  "inset"
1428
1508
  ]
1429
1509
  },
@@ -1462,7 +1542,8 @@ var treeui_catalog_default = {
1462
1542
  a11y: [],
1463
1543
  behavior: [
1464
1544
  "body_wrapper_class: t-card__body",
1465
- "solid_variant_rescopes_color_tokens_for_nested_content: true"
1545
+ 'variant_effects: {"outline":"Base surface with a default border. The styling baseline \u2014 the `t-card--outline` class is emitted but carries no CSS rule of its own.","soft":"Subtle tinted surface (bg-subtle), same border and shadow as outline.","inset":"Same tinted surface as soft, but with no shadow, so it reads as recessed inside another surface."}',
1546
+ "note: No card variant inverts its surface, so nested content inherits the normal color tokens. For a high-emphasis card, use a brand-colored border rather than an inverted background."
1466
1547
  ],
1467
1548
  selection: {
1468
1549
  keywords: [
@@ -1791,6 +1872,92 @@ var treeui_catalog_default = {
1791
1872
  },
1792
1873
  recipes: []
1793
1874
  },
1875
+ {
1876
+ name: "TColorSwatch",
1877
+ aliases: [],
1878
+ package: "@treeui/vue",
1879
+ kind: "form",
1880
+ category: "Data Entry",
1881
+ status: "available",
1882
+ purpose: "Pick a colour from a row of preset swatches, with an optional native colour input for an arbitrary value. Built for accent/brand pickers.",
1883
+ sourceFile: "packages/vue/src/components/TColorSwatch.vue",
1884
+ storyFile: "apps/docs/src/stories/ColorSwatch.stories.ts",
1885
+ storyTitle: "Components/Data Entry/ColorSwatch",
1886
+ manifestFile: "docs/ai/COMPONENTS/color-swatch.yaml",
1887
+ props: [
1888
+ {
1889
+ name: "modelValue",
1890
+ type: "string",
1891
+ default: "undefined",
1892
+ note: "Selected colour as a hex string. Matching is case-insensitive."
1893
+ },
1894
+ {
1895
+ name: "options",
1896
+ type: "TColorSwatchOption[]",
1897
+ default: "[]",
1898
+ note: "Preset swatches, each `{ label, value }`. `label` becomes the button's accessible name."
1899
+ },
1900
+ {
1901
+ name: "allowCustom",
1902
+ type: "boolean",
1903
+ default: "false",
1904
+ note: 'Appends a native `<input type="color">` for values outside the presets.'
1905
+ },
1906
+ {
1907
+ name: "size",
1908
+ type: "TSize",
1909
+ default: "md",
1910
+ values: [
1911
+ "sm",
1912
+ "md",
1913
+ "lg"
1914
+ ]
1915
+ },
1916
+ {
1917
+ name: "label",
1918
+ type: "string",
1919
+ default: "Color",
1920
+ note: 'Accessible label for the swatch group (`role="group"`).'
1921
+ },
1922
+ {
1923
+ name: "customLabel",
1924
+ type: "string",
1925
+ default: "Custom color"
1926
+ },
1927
+ {
1928
+ name: "disabled",
1929
+ type: "boolean",
1930
+ default: "false"
1931
+ }
1932
+ ],
1933
+ events: [
1934
+ {
1935
+ name: "update:modelValue"
1936
+ }
1937
+ ],
1938
+ slots: [],
1939
+ a11y: [
1940
+ 'Wrapper is `role="group"` labelled by `label`.',
1941
+ "Each swatch is a native button with `aria-pressed` reflecting selection and `aria-label` from the option label.",
1942
+ "Selection is conveyed by an outline (not colour alone), since the swatch's own colour is the content."
1943
+ ],
1944
+ behavior: [
1945
+ "emits_on_preset_click: true",
1946
+ "emits_on_custom_input: true",
1947
+ "blocks_interaction_when_disabled: true"
1948
+ ],
1949
+ selection: {
1950
+ keywords: [],
1951
+ useWhen: [],
1952
+ avoidWhen: [],
1953
+ alternatives: []
1954
+ },
1955
+ setup: {
1956
+ required: [],
1957
+ notes: []
1958
+ },
1959
+ recipes: []
1960
+ },
1794
1961
  {
1795
1962
  name: "TCombobox",
1796
1963
  aliases: [],
@@ -2141,12 +2308,14 @@ var treeui_catalog_default = {
2141
2308
  {
2142
2309
  name: "padded",
2143
2310
  type: "boolean",
2144
- default: "true"
2311
+ default: "true",
2312
+ note: "Adds `.is-padded`, i.e. an inline padding of `clamp(var(--tree-space-4), 3vw, var(--tree-space-6))`.\n"
2145
2313
  },
2146
2314
  {
2147
2315
  name: "centered",
2148
2316
  type: "boolean",
2149
- default: "true"
2317
+ default: "true",
2318
+ note: "Adds `.is-centered`, i.e. `margin-inline: auto`."
2150
2319
  }
2151
2320
  ],
2152
2321
  events: [],
@@ -3041,6 +3210,7 @@ var treeui_catalog_default = {
3041
3210
  "role: menu",
3042
3211
  "trigger_aria_haspopup: menu",
3043
3212
  "trigger_aria_expanded: true",
3213
+ "trigger_aria_controls: menu id, while open",
3044
3214
  "aria_disabled_on_disabled_items: true",
3045
3215
  "focus_visible_on_trigger: true",
3046
3216
  "keyboard_arrow_navigation: true",
@@ -3050,9 +3220,11 @@ var treeui_catalog_default = {
3050
3220
  ],
3051
3221
  behavior: [
3052
3222
  "outside_click_closes_menu: true",
3053
- "focus_restores_on_close: true",
3223
+ "outside_click_restores_focus: false",
3054
3224
  "chevron_rotates_when_open: true",
3055
- "menu_grows_to_fit_items_without_wrapping: true"
3225
+ "menu_grows_to_fit_items_without_wrapping: true",
3226
+ "opening_focuses_first_enabled_item: true",
3227
+ 'focus_restores_on_close: {"value":true,"detail":"Focus returns to the trigger when the menu closes from inside it \u2014 selecting an item or pressing Escape. It deliberately does NOT move focus on an outside click, where the pointer has already placed focus elsewhere.\\n","applies_to_custom_trigger":true}'
3056
3228
  ],
3057
3229
  selection: {
3058
3230
  keywords: [
@@ -3448,7 +3620,7 @@ var treeui_catalog_default = {
3448
3620
  name: "htmlFor",
3449
3621
  type: "string",
3450
3622
  required: false,
3451
- description: "The id of the associated form control, used on the <label> for attribute."
3623
+ description: "Rendered verbatim as the <label for> attribute. There is no id generation: when omitted, the label carries no `for` and is NOT associated with any control. The consumer must pass this AND set the same value as `id` on the child control.\n"
3452
3624
  },
3453
3625
  {
3454
3626
  name: "error",
@@ -3506,10 +3678,11 @@ var treeui_catalog_default = {
3506
3678
  }
3507
3679
  ],
3508
3680
  a11y: [
3509
- "Uses native <label> element with for attribute for input association.",
3681
+ "Renders a native <label> element, but ONLY when `label` or the `label` slot is provided.",
3510
3682
  "Error messages are wrapped in role='alert' for screen reader announcements.",
3511
3683
  "Required indicator (*) is aria-hidden to avoid redundant announcements; use aria-required on the input itself.",
3512
- "Error takes precedence over hint to avoid conflicting messages."
3684
+ "Error takes precedence over hint to avoid conflicting messages.",
3685
+ "Extra attrs land on the root <div> (inheritAttrs: false), not on the child control."
3513
3686
  ],
3514
3687
  behavior: [],
3515
3688
  selection: {
@@ -3774,6 +3947,20 @@ var treeui_catalog_default = {
3774
3947
  "lg"
3775
3948
  ]
3776
3949
  },
3950
+ {
3951
+ name: "width",
3952
+ type: "TFieldWidth",
3953
+ default: "full",
3954
+ values: [
3955
+ "xs",
3956
+ "sm",
3957
+ "md",
3958
+ "lg",
3959
+ "xl",
3960
+ "full"
3961
+ ],
3962
+ note: "Inline-size cap (max-inline-size). Fluid by default; use instead of an inline width style."
3963
+ },
3777
3964
  {
3778
3965
  name: "disabled",
3779
3966
  type: "boolean",
@@ -3858,6 +4045,43 @@ var treeui_catalog_default = {
3858
4045
  "tag-input"
3859
4046
  ]
3860
4047
  },
4048
+ {
4049
+ name: "TKbd",
4050
+ aliases: [],
4051
+ package: "@treeui/vue",
4052
+ kind: "primitive",
4053
+ category: "Data Display",
4054
+ status: "available",
4055
+ purpose: "Keyboard-key hint (e.g. \u2318K, Esc, Ctrl) rendered as a native <kbd> with the library's chip styling.",
4056
+ sourceFile: "packages/vue/src/components/TKbd.vue",
4057
+ storyFile: "apps/docs/src/stories/Kbd.stories.ts",
4058
+ storyTitle: "Components/Data Display/Kbd",
4059
+ manifestFile: "docs/ai/COMPONENTS/kbd.yaml",
4060
+ props: [],
4061
+ events: [],
4062
+ slots: [
4063
+ {
4064
+ name: "default"
4065
+ }
4066
+ ],
4067
+ a11y: [
4068
+ "Uses the native <kbd> element so assistive tech announces it as keyboard input."
4069
+ ],
4070
+ behavior: [
4071
+ "renders_native_kbd_element: true"
4072
+ ],
4073
+ selection: {
4074
+ keywords: [],
4075
+ useWhen: [],
4076
+ avoidWhen: [],
4077
+ alternatives: []
4078
+ },
4079
+ setup: {
4080
+ required: [],
4081
+ notes: []
4082
+ },
4083
+ recipes: []
4084
+ },
3861
4085
  {
3862
4086
  name: "TLink",
3863
4087
  aliases: [],
@@ -3919,10 +4143,39 @@ var treeui_catalog_default = {
3919
4143
  ],
3920
4144
  behavior: [],
3921
4145
  selection: {
3922
- keywords: [],
3923
- useWhen: [],
3924
- avoidWhen: [],
3925
- alternatives: []
4146
+ keywords: [
4147
+ "link",
4148
+ "anchor",
4149
+ "hyperlink",
4150
+ "navigation",
4151
+ "router link",
4152
+ "external link",
4153
+ "href",
4154
+ "to"
4155
+ ],
4156
+ useWhen: [
4157
+ "The action navigates somewhere \u2014 a URL, a route, or an anchor on the page.",
4158
+ "You want consistent link styling with `default`, `muted`, or `danger` emphasis.",
4159
+ "You want a component that renders RouterLink when vue-router is installed and a plain <a> when it is not, without branching in the template."
4160
+ ],
4161
+ avoidWhen: [
4162
+ "The control performs an action rather than navigating (submit, open a dialog, delete) \u2014 that is a button, even if it looks like a link.",
4163
+ "You need a full call-to-action surface with variants, sizes, and a loading state."
4164
+ ],
4165
+ alternatives: [
4166
+ {
4167
+ component: "TButton",
4168
+ when: 'The control performs an action. Use `variant="ghost"` for a low-emphasis, link-like button.'
4169
+ },
4170
+ {
4171
+ component: "TBreadcrumb",
4172
+ when: "The links form a hierarchy trail."
4173
+ },
4174
+ {
4175
+ component: "TNavMenu",
4176
+ when: "The links are app-section navigation in a shell or sidebar."
4177
+ }
4178
+ ]
3926
4179
  },
3927
4180
  setup: {
3928
4181
  required: [],
@@ -3936,7 +4189,8 @@ var treeui_catalog_default = {
3936
4189
  package: "@treeui/vue",
3937
4190
  category: "Form",
3938
4191
  status: "stable",
3939
- description: "A rich Markdown editor with live preview, toolbar formatting, keyboard shortcuts, and image paste/drop upload support.\n",
4192
+ description: "A Markdown editor with an always-visible side-by-side live preview, toolbar formatting, keyboard shortcuts, and image paste/drop upload support.\n",
4193
+ sourceFile: "packages/vue/src/components/TMarkdownEditor.vue",
3940
4194
  storyFile: "apps/docs/src/stories/MarkdownEditor.stories.ts",
3941
4195
  storyTitle: "Components/Form/MarkdownEditor",
3942
4196
  manifestFile: "docs/ai/COMPONENTS/markdown-editor.yaml",
@@ -3972,6 +4226,12 @@ var treeui_catalog_default = {
3972
4226
  type: "(file: File) => Promise<string>",
3973
4227
  default: "undefined",
3974
4228
  description: "Async function that receives a File and returns the uploaded image URL. When not provided, pasting an image inserts an empty markdown image tag.\n"
4229
+ },
4230
+ {
4231
+ name: "sanitize",
4232
+ type: "(html: string) => string",
4233
+ default: "undefined",
4234
+ description: "Optional extra sanitizer applied to the rendered preview HTML as the final step, after the built-in rendering. It is an ADDITIVE escape hatch, not a toggle: pass DOMPurify or a stricter policy of your own instead of forking the component.\n"
3975
4235
  }
3976
4236
  ],
3977
4237
  events: [
@@ -3998,12 +4258,12 @@ var treeui_catalog_default = {
3998
4258
  }
3999
4259
  ],
4000
4260
  a11y: [
4001
- 'Toolbar has role="toolbar" with aria-label.',
4002
- 'Tab buttons use role="tab" and aria-selected.',
4003
- 'Preview pane has aria-label="Markdown preview".',
4261
+ 'Toolbar has role="toolbar" with aria-label="Markdown formatting".',
4262
+ 'Toolbar groups are separated by elements with role="separator".',
4263
+ 'Preview pane carries aria-label="Markdown preview".',
4004
4264
  'Upload status bar uses role="status" and aria-live="polite".',
4005
4265
  "All toolbar buttons have title attributes describing the action.",
4006
- "Textarea has aria-label for screen readers."
4266
+ "Textarea has aria-label (mirrors the placeholder text)."
4007
4267
  ],
4008
4268
  behavior: [],
4009
4269
  selection: {
@@ -5079,7 +5339,7 @@ var treeui_catalog_default = {
5079
5339
  props: [
5080
5340
  {
5081
5341
  name: "plans",
5082
- type: "PricingPlan[]",
5342
+ type: "TPricingPlan[]",
5083
5343
  required: true,
5084
5344
  description: "Array of plan objects. Each plan supports the same props as PricingCard (title, description, price, currency, period, features, highlighted, badge, buttonText, disabled).\n"
5085
5345
  },
@@ -5100,14 +5360,14 @@ var treeui_catalog_default = {
5100
5360
  {
5101
5361
  name: "select",
5102
5362
  description: "Emitted when any plan's CTA is clicked. Provides the plan data and index.",
5103
- payload: "[plan: PricingPlan, index: number]"
5363
+ payload: "[plan: TPricingPlan, index: number]"
5104
5364
  }
5105
5365
  ],
5106
5366
  slots: [
5107
5367
  {
5108
5368
  name: "plan",
5109
5369
  description: "Custom rendering for each plan card.",
5110
- note: "{ plan: PricingPlan, index: number }"
5370
+ note: "{ plan: TPricingPlan, index: number }"
5111
5371
  }
5112
5372
  ],
5113
5373
  a11y: [
@@ -5266,7 +5526,7 @@ var treeui_catalog_default = {
5266
5526
  package: "@treeui/vue",
5267
5527
  category: "Feedback",
5268
5528
  status: "draft",
5269
- description: "Determinate and indeterminate progress indicator. Supports linear bar and circular ring variants.\n",
5529
+ description: "Determinate and indeterminate progress indicator. Renders a linear bar only \u2014 there is no circular, ring, or radial variant, and no `variant`/`shape`/`type` prop. Compose one yourself if you need it.\n",
5270
5530
  storyFile: "apps/docs/src/stories/Progress.stories.ts",
5271
5531
  storyTitle: "Components/Feedback/Progress",
5272
5532
  manifestFile: "docs/ai/COMPONENTS/progress.yaml",
@@ -5306,7 +5566,8 @@ var treeui_catalog_default = {
5306
5566
  "role: progressbar",
5307
5567
  'attributes: ["aria-valuenow (omitted when indeterminate)","aria-valuemin (always 0)","aria-valuemax (always 100)","aria-label"]',
5308
5568
  "keyboard:",
5309
- "notes: Indeterminate state omits aria-valuenow so assistive tech announces the bar as indeterminate."
5569
+ "notes: Indeterminate state omits aria-valuenow so assistive tech announces the bar as indeterminate.",
5570
+ "value_is_normalized: aria-valuenow is `value / max` expressed as a 0\u2013100 percentage, not the raw `value`. aria-valuemax stays 100 regardless of the `max` prop, so the two always agree. The `label` is also repeated in a visually hidden span."
5310
5571
  ],
5311
5572
  behavior: [],
5312
5573
  selection: {
@@ -5508,6 +5769,20 @@ var treeui_catalog_default = {
5508
5769
  "lg"
5509
5770
  ]
5510
5771
  },
5772
+ {
5773
+ name: "width",
5774
+ type: "TFieldWidth",
5775
+ default: "full",
5776
+ values: [
5777
+ "xs",
5778
+ "sm",
5779
+ "md",
5780
+ "lg",
5781
+ "xl",
5782
+ "full"
5783
+ ],
5784
+ note: "Inline-size cap (max-inline-size). Fluid by default; use instead of an inline width style."
5785
+ },
5511
5786
  {
5512
5787
  name: "disabled",
5513
5788
  type: "boolean",
@@ -5662,10 +5937,13 @@ var treeui_catalog_default = {
5662
5937
  ],
5663
5938
  slots: [
5664
5939
  {
5665
- name: "item"
5940
+ name: "item",
5941
+ description: `Replaces the default row body (indicator, label, description, meta). Renders INSIDE the row's <button role="option">.
5942
+ `
5666
5943
  },
5667
5944
  {
5668
- name: "empty"
5945
+ name: "empty",
5946
+ description: "Replaces `emptyText` when `items` is empty."
5669
5947
  }
5670
5948
  ],
5671
5949
  a11y: [
@@ -5678,7 +5956,8 @@ var treeui_catalog_default = {
5678
5956
  ],
5679
5957
  behavior: [
5680
5958
  "can_be_controlled_or_uncontrolled: true",
5681
- "supports_rich_row_rendering_via_slot: true",
5959
+ "supports_presentational_row_slot: true",
5960
+ "supports_interactive_content_in_rows: false",
5682
5961
  "empty_state_text_supported: true"
5683
5962
  ],
5684
5963
  selection: {
@@ -5922,6 +6201,46 @@ var treeui_catalog_default = {
5922
6201
  },
5923
6202
  recipes: []
5924
6203
  },
6204
+ {
6205
+ name: "TSpacer",
6206
+ aliases: [],
6207
+ package: "@treeui/vue",
6208
+ kind: "layout",
6209
+ category: "Layout",
6210
+ status: "available",
6211
+ purpose: "Flexible spacer that absorbs free space between siblings in a flex layout (e.g. TStack), replacing hand-written margin:auto / flex:1.",
6212
+ sourceFile: "packages/vue/src/components/TSpacer.vue",
6213
+ storyFile: "apps/docs/src/stories/Spacer.stories.ts",
6214
+ storyTitle: "Components/Layout/Spacer",
6215
+ manifestFile: "docs/ai/COMPONENTS/spacer.yaml",
6216
+ props: [
6217
+ {
6218
+ name: "as",
6219
+ type: "string",
6220
+ default: "div"
6221
+ }
6222
+ ],
6223
+ events: [],
6224
+ slots: [],
6225
+ a11y: [
6226
+ "Rendered with aria-hidden='true'; it is a layout-only element with no content."
6227
+ ],
6228
+ behavior: [
6229
+ "grows_to_fill_free_space: true",
6230
+ "pushes_siblings_apart_or_to_ends: true"
6231
+ ],
6232
+ selection: {
6233
+ keywords: [],
6234
+ useWhen: [],
6235
+ avoidWhen: [],
6236
+ alternatives: []
6237
+ },
6238
+ setup: {
6239
+ required: [],
6240
+ notes: []
6241
+ },
6242
+ recipes: []
6243
+ },
5925
6244
  {
5926
6245
  name: "TSparkline",
5927
6246
  aliases: [],
@@ -6095,49 +6414,125 @@ var treeui_catalog_default = {
6095
6414
  recipes: []
6096
6415
  },
6097
6416
  {
6098
- name: "TStack",
6417
+ name: "TSplit",
6099
6418
  aliases: [],
6100
6419
  package: "@treeui/vue",
6101
6420
  kind: "layout",
6102
6421
  category: "Layout",
6103
6422
  status: "available",
6104
- purpose: "One-dimensional spacing and alignment wrapper for vertical or horizontal compositions.",
6105
- sourceFile: "packages/vue/src/components/TStack.vue",
6106
- storyFile: "apps/docs/src/stories/Stack.stories.ts",
6107
- storyTitle: "Components/Layout/Stack",
6108
- manifestFile: "docs/ai/COMPONENTS/stack.yaml",
6423
+ purpose: "Responsive two-pane layout (a wider main pane + a narrower aside) that sits side by side and stacks to one column when narrow \u2014 no media query.",
6424
+ sourceFile: "packages/vue/src/components/TSplit.vue",
6425
+ storyFile: "apps/docs/src/stories/Split.stories.ts",
6426
+ storyTitle: "Components/Layout/Split",
6427
+ manifestFile: "docs/ai/COMPONENTS/split.yaml",
6109
6428
  props: [
6110
6429
  {
6111
6430
  name: "as",
6112
6431
  type: "string",
6113
6432
  default: "div"
6114
6433
  },
6115
- {
6116
- name: "direction",
6117
- type: "TStackDirection",
6118
- default: "vertical",
6119
- values: [
6120
- "vertical",
6121
- "horizontal"
6122
- ]
6123
- },
6124
6434
  {
6125
6435
  name: "gap",
6126
6436
  type: "string",
6127
- default: "var(--tree-space-4)"
6437
+ default: "var(--tree-space-5)"
6128
6438
  },
6129
6439
  {
6130
- name: "align",
6131
- type: "string",
6132
- default: "stretch"
6440
+ name: "ratio",
6441
+ type: "number",
6442
+ default: "2",
6443
+ note: "How many times faster the main pane grows than the aside pane."
6133
6444
  },
6134
6445
  {
6135
- name: "justify",
6446
+ name: "minWidth",
6136
6447
  type: "string",
6137
- default: "flex-start"
6448
+ default: "18rem",
6449
+ note: "Min width each pane keeps before the layout wraps to a single column (flex-wrap, no @media)."
6138
6450
  },
6139
6451
  {
6140
- name: "wrap",
6452
+ name: "side",
6453
+ type: "start | end",
6454
+ default: "end",
6455
+ note: "Which side the aside pane sits on when side by side."
6456
+ },
6457
+ {
6458
+ name: "align",
6459
+ type: "string",
6460
+ default: "start",
6461
+ note: "Cross-axis alignment (align-items)."
6462
+ }
6463
+ ],
6464
+ events: [],
6465
+ slots: [
6466
+ {
6467
+ name: "default"
6468
+ },
6469
+ {
6470
+ name: "aside"
6471
+ }
6472
+ ],
6473
+ a11y: [
6474
+ "Layout-only wrapper; semantics come from the slotted content."
6475
+ ],
6476
+ behavior: [
6477
+ "wraps_to_single_column_when_narrow: true",
6478
+ "media_query_free: true"
6479
+ ],
6480
+ selection: {
6481
+ keywords: [],
6482
+ useWhen: [],
6483
+ avoidWhen: [],
6484
+ alternatives: []
6485
+ },
6486
+ setup: {
6487
+ required: [],
6488
+ notes: []
6489
+ },
6490
+ recipes: []
6491
+ },
6492
+ {
6493
+ name: "TStack",
6494
+ aliases: [],
6495
+ package: "@treeui/vue",
6496
+ kind: "layout",
6497
+ category: "Layout",
6498
+ status: "available",
6499
+ purpose: "One-dimensional spacing and alignment wrapper for vertical or horizontal compositions.",
6500
+ sourceFile: "packages/vue/src/components/TStack.vue",
6501
+ storyFile: "apps/docs/src/stories/Stack.stories.ts",
6502
+ storyTitle: "Components/Layout/Stack",
6503
+ manifestFile: "docs/ai/COMPONENTS/stack.yaml",
6504
+ props: [
6505
+ {
6506
+ name: "as",
6507
+ type: "string",
6508
+ default: "div"
6509
+ },
6510
+ {
6511
+ name: "direction",
6512
+ type: "TStackDirection",
6513
+ default: "vertical",
6514
+ values: [
6515
+ "vertical",
6516
+ "horizontal"
6517
+ ]
6518
+ },
6519
+ {
6520
+ name: "gap",
6521
+ type: "string",
6522
+ default: "var(--tree-space-4)"
6523
+ },
6524
+ {
6525
+ name: "align",
6526
+ type: "string",
6527
+ default: "stretch"
6528
+ },
6529
+ {
6530
+ name: "justify",
6531
+ type: "string",
6532
+ default: "flex-start"
6533
+ },
6534
+ {
6535
+ name: "wrap",
6141
6536
  type: "boolean",
6142
6537
  default: "false"
6143
6538
  },
@@ -6145,6 +6540,12 @@ var treeui_catalog_default = {
6145
6540
  name: "reverse",
6146
6541
  type: "boolean",
6147
6542
  default: "false"
6543
+ },
6544
+ {
6545
+ name: "grow",
6546
+ type: "boolean",
6547
+ default: "false",
6548
+ note: "Expands the stack to fill available space along its parent's main axis (flex: 1 with min-size 0). Use it to make a sidebar column fill its container height."
6148
6549
  }
6149
6550
  ],
6150
6551
  events: [],
@@ -6192,6 +6593,80 @@ var treeui_catalog_default = {
6192
6593
  "chart-surface"
6193
6594
  ]
6194
6595
  },
6596
+ {
6597
+ name: "TStackItem",
6598
+ aliases: [],
6599
+ package: "@treeui/vue",
6600
+ kind: "layout",
6601
+ category: "Layout",
6602
+ status: "available",
6603
+ purpose: "Per-child flex control inside a TStack \u2014 grow, shrink, basis, min width and align-self \u2014 so one item can fill the row without hand-written CSS.",
6604
+ sourceFile: "packages/vue/src/components/TStackItem.vue",
6605
+ storyFile: "apps/docs/src/stories/StackItem.stories.ts",
6606
+ storyTitle: "Components/Layout/StackItem",
6607
+ manifestFile: "docs/ai/COMPONENTS/stack-item.yaml",
6608
+ props: [
6609
+ {
6610
+ name: "as",
6611
+ type: "string",
6612
+ default: "div"
6613
+ },
6614
+ {
6615
+ name: "grow",
6616
+ type: "boolean | number",
6617
+ default: "false",
6618
+ note: "true = flex-grow 1; a number sets the grow factor."
6619
+ },
6620
+ {
6621
+ name: "shrink",
6622
+ type: "boolean | number",
6623
+ default: "undefined",
6624
+ note: "false prevents shrinking; a number sets the shrink factor."
6625
+ },
6626
+ {
6627
+ name: "basis",
6628
+ type: "string",
6629
+ default: "undefined",
6630
+ note: "flex-basis (initial main-axis size)."
6631
+ },
6632
+ {
6633
+ name: "minWidth",
6634
+ type: "string",
6635
+ default: "undefined",
6636
+ note: "Minimum main-axis size before it wraps/shrinks."
6637
+ },
6638
+ {
6639
+ name: "align",
6640
+ type: "string",
6641
+ default: "undefined",
6642
+ note: "Per-item cross-axis alignment (align-self)."
6643
+ }
6644
+ ],
6645
+ events: [],
6646
+ slots: [
6647
+ {
6648
+ name: "default"
6649
+ }
6650
+ ],
6651
+ a11y: [
6652
+ "Layout-only wrapper; semantics come from the slotted content."
6653
+ ],
6654
+ behavior: [
6655
+ "controls_single_flex_child: true",
6656
+ "defaults_min_inline_size_zero: true"
6657
+ ],
6658
+ selection: {
6659
+ keywords: [],
6660
+ useWhen: [],
6661
+ avoidWhen: [],
6662
+ alternatives: []
6663
+ },
6664
+ setup: {
6665
+ required: [],
6666
+ notes: []
6667
+ },
6668
+ recipes: []
6669
+ },
6195
6670
  {
6196
6671
  name: "TStat",
6197
6672
  aliases: [],
@@ -6663,7 +7138,7 @@ var treeui_catalog_default = {
6663
7138
  ],
6664
7139
  slots: [
6665
7140
  {
6666
- name: "unnamed"
7141
+ name: "default"
6667
7142
  }
6668
7143
  ],
6669
7144
  a11y: [
@@ -6794,6 +7269,95 @@ var treeui_catalog_default = {
6794
7269
  "tag-input"
6795
7270
  ]
6796
7271
  },
7272
+ {
7273
+ name: "TText",
7274
+ aliases: [],
7275
+ package: "@treeui/vue",
7276
+ kind: "primitive",
7277
+ category: "Data Display",
7278
+ status: "available",
7279
+ purpose: "Typography primitive for body text, labels and headings \u2014 size, tone, weight and truncation from tokens, with no hand-written CSS.",
7280
+ sourceFile: "packages/vue/src/components/TText.vue",
7281
+ storyFile: "apps/docs/src/stories/Text.stories.ts",
7282
+ storyTitle: "Components/Data Display/Text",
7283
+ manifestFile: "docs/ai/COMPONENTS/text.yaml",
7284
+ props: [
7285
+ {
7286
+ name: "as",
7287
+ type: "string",
7288
+ default: "span",
7289
+ note: "Render element. Use `p`, `h1`\u2013`h6`, `label`, `small`, `strong`, \u2026 for correct semantics."
7290
+ },
7291
+ {
7292
+ name: "size",
7293
+ type: "TTextSize",
7294
+ default: "undefined",
7295
+ values: [
7296
+ "xs",
7297
+ "sm",
7298
+ "md",
7299
+ "lg",
7300
+ "xl",
7301
+ "2xl",
7302
+ "3xl"
7303
+ ],
7304
+ note: "Maps to --tree-font-size-*. Omitted = inherit."
7305
+ },
7306
+ {
7307
+ name: "tone",
7308
+ type: "TTextTone",
7309
+ default: "default",
7310
+ values: [
7311
+ "default",
7312
+ "muted",
7313
+ "inverse",
7314
+ "brand"
7315
+ ],
7316
+ note: "`default` inherits the current colour; others map to --tree-color-text-* / brand."
7317
+ },
7318
+ {
7319
+ name: "weight",
7320
+ type: "TTextWeight",
7321
+ default: "undefined",
7322
+ values: [
7323
+ "regular",
7324
+ "medium",
7325
+ "semibold",
7326
+ "bold"
7327
+ ]
7328
+ },
7329
+ {
7330
+ name: "truncate",
7331
+ type: "boolean",
7332
+ default: "false",
7333
+ note: "Clip to a single line with an ellipsis."
7334
+ }
7335
+ ],
7336
+ events: [],
7337
+ slots: [
7338
+ {
7339
+ name: "default"
7340
+ }
7341
+ ],
7342
+ a11y: [
7343
+ "Choose `as` to convey the correct semantics (e.g. headings via h1\u2013h6); TText adds only visual styling."
7344
+ ],
7345
+ behavior: [
7346
+ "semantic_element_controlled_by_as: true",
7347
+ "token_driven_size_tone_weight: true"
7348
+ ],
7349
+ selection: {
7350
+ keywords: [],
7351
+ useWhen: [],
7352
+ avoidWhen: [],
7353
+ alternatives: []
7354
+ },
7355
+ setup: {
7356
+ required: [],
7357
+ notes: []
7358
+ },
7359
+ recipes: []
7360
+ },
6797
7361
  {
6798
7362
  name: "TTextarea",
6799
7363
  aliases: [],
@@ -6822,6 +7386,20 @@ var treeui_catalog_default = {
6822
7386
  "lg"
6823
7387
  ]
6824
7388
  },
7389
+ {
7390
+ name: "width",
7391
+ type: "TFieldWidth",
7392
+ default: "full",
7393
+ values: [
7394
+ "xs",
7395
+ "sm",
7396
+ "md",
7397
+ "lg",
7398
+ "xl",
7399
+ "full"
7400
+ ],
7401
+ note: "Inline-size cap (max-inline-size). Fluid by default; use instead of an inline width style."
7402
+ },
6825
7403
  {
6826
7404
  name: "disabled",
6827
7405
  type: "boolean",
@@ -7371,6 +7949,847 @@ var treeui_catalog_default = {
7371
7949
  "hierarchy-picker"
7372
7950
  ]
7373
7951
  }
7952
+ ],
7953
+ tokens: [
7954
+ {
7955
+ cssVar: "--tree-font-family-sans",
7956
+ path: "font.family.sans",
7957
+ value: "'Google Sans Flex', 'Segoe UI', sans-serif",
7958
+ category: "font",
7959
+ description: "Typography token: font family, size, weight, or line height."
7960
+ },
7961
+ {
7962
+ cssVar: "--tree-font-family-mono",
7963
+ path: "font.family.mono",
7964
+ value: "'Google Sans Code', 'SFMono-Regular', monospace",
7965
+ category: "font",
7966
+ description: "Typography token: font family, size, weight, or line height."
7967
+ },
7968
+ {
7969
+ cssVar: "--tree-font-size-xs",
7970
+ path: "font.size.xs",
7971
+ value: "0.6875rem",
7972
+ category: "font",
7973
+ description: "Typography token: font family, size, weight, or line height."
7974
+ },
7975
+ {
7976
+ cssVar: "--tree-font-size-sm",
7977
+ path: "font.size.sm",
7978
+ value: "0.8125rem",
7979
+ category: "font",
7980
+ description: "Typography token: font family, size, weight, or line height."
7981
+ },
7982
+ {
7983
+ cssVar: "--tree-font-size-md",
7984
+ path: "font.size.md",
7985
+ value: "0.9375rem",
7986
+ category: "font",
7987
+ description: "Typography token: font family, size, weight, or line height."
7988
+ },
7989
+ {
7990
+ cssVar: "--tree-font-size-base",
7991
+ path: "font.size.base",
7992
+ value: "0.9375rem",
7993
+ category: "font",
7994
+ description: "Typography token: font family, size, weight, or line height."
7995
+ },
7996
+ {
7997
+ cssVar: "--tree-font-size-lg",
7998
+ path: "font.size.lg",
7999
+ value: "1.125rem",
8000
+ category: "font",
8001
+ description: "Typography token: font family, size, weight, or line height."
8002
+ },
8003
+ {
8004
+ cssVar: "--tree-font-size-xl",
8005
+ path: "font.size.xl",
8006
+ value: "1.375rem",
8007
+ category: "font",
8008
+ description: "Typography token: font family, size, weight, or line height."
8009
+ },
8010
+ {
8011
+ cssVar: "--tree-font-size-2xl",
8012
+ path: "font.size.2xl",
8013
+ value: "1.375rem",
8014
+ category: "font",
8015
+ description: "Typography token: font family, size, weight, or line height."
8016
+ },
8017
+ {
8018
+ cssVar: "--tree-font-size-3xl",
8019
+ path: "font.size.3xl",
8020
+ value: "1.75rem",
8021
+ category: "font",
8022
+ description: "Typography token: font family, size, weight, or line height."
8023
+ },
8024
+ {
8025
+ cssVar: "--tree-font-size-4xl",
8026
+ path: "font.size.4xl",
8027
+ value: "2.25rem",
8028
+ category: "font",
8029
+ description: "Typography token: font family, size, weight, or line height."
8030
+ },
8031
+ {
8032
+ cssVar: "--tree-font-size-5xl",
8033
+ path: "font.size.5xl",
8034
+ value: "3rem",
8035
+ category: "font",
8036
+ description: "Typography token: font family, size, weight, or line height."
8037
+ },
8038
+ {
8039
+ cssVar: "--tree-font-weight-regular",
8040
+ path: "font.weight.regular",
8041
+ value: "400",
8042
+ category: "font",
8043
+ description: "Typography token: font family, size, weight, or line height."
8044
+ },
8045
+ {
8046
+ cssVar: "--tree-font-weight-medium",
8047
+ path: "font.weight.medium",
8048
+ value: "500",
8049
+ category: "font",
8050
+ description: "Typography token: font family, size, weight, or line height."
8051
+ },
8052
+ {
8053
+ cssVar: "--tree-font-weight-semibold",
8054
+ path: "font.weight.semibold",
8055
+ value: "600",
8056
+ category: "font",
8057
+ description: "Typography token: font family, size, weight, or line height."
8058
+ },
8059
+ {
8060
+ cssVar: "--tree-font-weight-bold",
8061
+ path: "font.weight.bold",
8062
+ value: "700",
8063
+ category: "font",
8064
+ description: "Typography token: font family, size, weight, or line height."
8065
+ },
8066
+ {
8067
+ cssVar: "--tree-font-weight-extrabold",
8068
+ path: "font.weight.extrabold",
8069
+ value: "800",
8070
+ category: "font",
8071
+ description: "Typography token: font family, size, weight, or line height."
8072
+ },
8073
+ {
8074
+ cssVar: "--tree-font-lineHeight-compact",
8075
+ path: "font.lineHeight.compact",
8076
+ value: "1.1",
8077
+ category: "font",
8078
+ description: "Typography token: font family, size, weight, or line height."
8079
+ },
8080
+ {
8081
+ cssVar: "--tree-font-lineHeight-ui",
8082
+ path: "font.lineHeight.ui",
8083
+ value: "1.15",
8084
+ category: "font",
8085
+ description: "Typography token: font family, size, weight, or line height."
8086
+ },
8087
+ {
8088
+ cssVar: "--tree-font-lineHeight-tight",
8089
+ path: "font.lineHeight.tight",
8090
+ value: "1.25",
8091
+ category: "font",
8092
+ description: "Typography token: font family, size, weight, or line height."
8093
+ },
8094
+ {
8095
+ cssVar: "--tree-font-lineHeight-heading",
8096
+ path: "font.lineHeight.heading",
8097
+ value: "1.3",
8098
+ category: "font",
8099
+ description: "Typography token: font family, size, weight, or line height."
8100
+ },
8101
+ {
8102
+ cssVar: "--tree-font-lineHeight-base",
8103
+ path: "font.lineHeight.base",
8104
+ value: "1.5",
8105
+ category: "font",
8106
+ description: "Typography token: font family, size, weight, or line height."
8107
+ },
8108
+ {
8109
+ cssVar: "--tree-font-lineHeight-body",
8110
+ path: "font.lineHeight.body",
8111
+ value: "1.6",
8112
+ category: "font",
8113
+ description: "Typography token: font family, size, weight, or line height."
8114
+ },
8115
+ {
8116
+ cssVar: "--tree-font-lineHeight-relaxed",
8117
+ path: "font.lineHeight.relaxed",
8118
+ value: "1.65",
8119
+ category: "font",
8120
+ description: "Typography token: font family, size, weight, or line height."
8121
+ },
8122
+ {
8123
+ cssVar: "--tree-space-0",
8124
+ path: "space.0",
8125
+ value: "0",
8126
+ category: "space",
8127
+ description: "Spacing scale step for padding, margin, and gap."
8128
+ },
8129
+ {
8130
+ cssVar: "--tree-space-1",
8131
+ path: "space.1",
8132
+ value: "0.25rem",
8133
+ category: "space",
8134
+ description: "Spacing scale step for padding, margin, and gap."
8135
+ },
8136
+ {
8137
+ cssVar: "--tree-space-2",
8138
+ path: "space.2",
8139
+ value: "0.5rem",
8140
+ category: "space",
8141
+ description: "Spacing scale step for padding, margin, and gap."
8142
+ },
8143
+ {
8144
+ cssVar: "--tree-space-3",
8145
+ path: "space.3",
8146
+ value: "0.75rem",
8147
+ category: "space",
8148
+ description: "Spacing scale step for padding, margin, and gap."
8149
+ },
8150
+ {
8151
+ cssVar: "--tree-space-4",
8152
+ path: "space.4",
8153
+ value: "1rem",
8154
+ category: "space",
8155
+ description: "Spacing scale step for padding, margin, and gap."
8156
+ },
8157
+ {
8158
+ cssVar: "--tree-space-5",
8159
+ path: "space.5",
8160
+ value: "1.25rem",
8161
+ category: "space",
8162
+ description: "Spacing scale step for padding, margin, and gap."
8163
+ },
8164
+ {
8165
+ cssVar: "--tree-space-6",
8166
+ path: "space.6",
8167
+ value: "1.5rem",
8168
+ category: "space",
8169
+ description: "Spacing scale step for padding, margin, and gap."
8170
+ },
8171
+ {
8172
+ cssVar: "--tree-space-8",
8173
+ path: "space.8",
8174
+ value: "2rem",
8175
+ category: "space",
8176
+ description: "Spacing scale step for padding, margin, and gap."
8177
+ },
8178
+ {
8179
+ cssVar: "--tree-space-12",
8180
+ path: "space.12",
8181
+ value: "3rem",
8182
+ category: "space",
8183
+ description: "Spacing scale step for padding, margin, and gap."
8184
+ },
8185
+ {
8186
+ cssVar: "--tree-space-16",
8187
+ path: "space.16",
8188
+ value: "4rem",
8189
+ category: "space",
8190
+ description: "Spacing scale step for padding, margin, and gap."
8191
+ },
8192
+ {
8193
+ cssVar: "--tree-radius-sm",
8194
+ path: "radius.sm",
8195
+ value: "0.375rem",
8196
+ category: "radius",
8197
+ description: "Corner radius scale step."
8198
+ },
8199
+ {
8200
+ cssVar: "--tree-radius-md",
8201
+ path: "radius.md",
8202
+ value: "0.625rem",
8203
+ category: "radius",
8204
+ description: "Corner radius scale step."
8205
+ },
8206
+ {
8207
+ cssVar: "--tree-radius-lg",
8208
+ path: "radius.lg",
8209
+ value: "0.875rem",
8210
+ category: "radius",
8211
+ description: "Corner radius scale step."
8212
+ },
8213
+ {
8214
+ cssVar: "--tree-radius-pill",
8215
+ path: "radius.pill",
8216
+ value: "999px",
8217
+ category: "radius",
8218
+ description: "Corner radius scale step."
8219
+ },
8220
+ {
8221
+ cssVar: "--tree-shadow-xs",
8222
+ path: "shadow.xs",
8223
+ value: "0 1px 2px rgba(15, 23, 42, 0.06)",
8224
+ category: "shadow",
8225
+ description: "Elevation shadow."
8226
+ },
8227
+ {
8228
+ cssVar: "--tree-shadow-sm",
8229
+ path: "shadow.sm",
8230
+ value: "0 6px 18px rgba(15, 23, 42, 0.08)",
8231
+ category: "shadow",
8232
+ description: "Elevation shadow."
8233
+ },
8234
+ {
8235
+ cssVar: "--tree-shadow-md",
8236
+ path: "shadow.md",
8237
+ value: "0 14px 34px rgba(15, 23, 42, 0.12)",
8238
+ category: "shadow",
8239
+ description: "Elevation shadow."
8240
+ },
8241
+ {
8242
+ cssVar: "--tree-gradient-brand",
8243
+ path: "gradient.brand",
8244
+ value: "linear-gradient(135deg, var(--tree-color-brand-primary), var(--tree-color-brand-hover))",
8245
+ category: "gradient",
8246
+ description: "Gradient composed from the themed brand variables."
8247
+ },
8248
+ {
8249
+ cssVar: "--tree-border-width-subtle",
8250
+ path: "border.width.subtle",
8251
+ value: "1px",
8252
+ category: "border",
8253
+ description: "Border width step."
8254
+ },
8255
+ {
8256
+ cssVar: "--tree-border-width-strong",
8257
+ path: "border.width.strong",
8258
+ value: "1.5px",
8259
+ category: "border",
8260
+ description: "Border width step."
8261
+ },
8262
+ {
8263
+ cssVar: "--tree-motion-duration-fast",
8264
+ path: "motion.duration.fast",
8265
+ value: "100ms",
8266
+ category: "motion",
8267
+ description: "Motion duration or easing curve."
8268
+ },
8269
+ {
8270
+ cssVar: "--tree-motion-duration-moderate",
8271
+ path: "motion.duration.moderate",
8272
+ value: "200ms",
8273
+ category: "motion",
8274
+ description: "Motion duration or easing curve."
8275
+ },
8276
+ {
8277
+ cssVar: "--tree-motion-duration-normal",
8278
+ path: "motion.duration.normal",
8279
+ value: "300ms",
8280
+ category: "motion",
8281
+ description: "Motion duration or easing curve."
8282
+ },
8283
+ {
8284
+ cssVar: "--tree-motion-duration-slow",
8285
+ path: "motion.duration.slow",
8286
+ value: "400ms",
8287
+ category: "motion",
8288
+ description: "Motion duration or easing curve."
8289
+ },
8290
+ {
8291
+ cssVar: "--tree-motion-duration-slower",
8292
+ path: "motion.duration.slower",
8293
+ value: "500ms",
8294
+ category: "motion",
8295
+ description: "Motion duration or easing curve."
8296
+ },
8297
+ {
8298
+ cssVar: "--tree-motion-easing-standard",
8299
+ path: "motion.easing.standard",
8300
+ value: "cubic-bezier(0.2, 0, 0, 1)",
8301
+ category: "motion",
8302
+ description: "Motion duration or easing curve."
8303
+ },
8304
+ {
8305
+ cssVar: "--tree-motion-easing-easeOut",
8306
+ path: "motion.easing.easeOut",
8307
+ value: "cubic-bezier(0, 0, 0.2, 1)",
8308
+ category: "motion",
8309
+ description: "Motion duration or easing curve."
8310
+ },
8311
+ {
8312
+ cssVar: "--tree-motion-easing-easeInOut",
8313
+ path: "motion.easing.easeInOut",
8314
+ value: "cubic-bezier(0.4, 0, 0.2, 1)",
8315
+ category: "motion",
8316
+ description: "Motion duration or easing curve."
8317
+ },
8318
+ {
8319
+ cssVar: "--tree-motion-easing-easeIn",
8320
+ path: "motion.easing.easeIn",
8321
+ value: "cubic-bezier(0.4, 0, 1, 1)",
8322
+ category: "motion",
8323
+ description: "Motion duration or easing curve."
8324
+ },
8325
+ {
8326
+ cssVar: "--tree-size-control-sm",
8327
+ path: "size.control.sm",
8328
+ value: "2rem",
8329
+ category: "size",
8330
+ description: "Control and icon sizing scale step."
8331
+ },
8332
+ {
8333
+ cssVar: "--tree-size-control-md",
8334
+ path: "size.control.md",
8335
+ value: "2.5rem",
8336
+ category: "size",
8337
+ description: "Control and icon sizing scale step."
8338
+ },
8339
+ {
8340
+ cssVar: "--tree-size-control-lg",
8341
+ path: "size.control.lg",
8342
+ value: "3rem",
8343
+ category: "size",
8344
+ description: "Control and icon sizing scale step."
8345
+ },
8346
+ {
8347
+ cssVar: "--tree-size-icon-sm",
8348
+ path: "size.icon.sm",
8349
+ value: "1rem",
8350
+ category: "size",
8351
+ description: "Control and icon sizing scale step."
8352
+ },
8353
+ {
8354
+ cssVar: "--tree-size-icon-md",
8355
+ path: "size.icon.md",
8356
+ value: "1.25rem",
8357
+ category: "size",
8358
+ description: "Control and icon sizing scale step."
8359
+ },
8360
+ {
8361
+ cssVar: "--tree-size-icon-lg",
8362
+ path: "size.icon.lg",
8363
+ value: "1.5rem",
8364
+ category: "size",
8365
+ description: "Control and icon sizing scale step."
8366
+ },
8367
+ {
8368
+ cssVar: "--tree-size-icon-xl",
8369
+ path: "size.icon.xl",
8370
+ value: "2rem",
8371
+ category: "size",
8372
+ description: "Control and icon sizing scale step."
8373
+ },
8374
+ {
8375
+ cssVar: "--tree-size-icon-2xl",
8376
+ path: "size.icon.2xl",
8377
+ value: "3rem",
8378
+ category: "size",
8379
+ description: "Control and icon sizing scale step."
8380
+ },
8381
+ {
8382
+ cssVar: "--tree-layout-grid-columns",
8383
+ path: "layout.grid.columns",
8384
+ value: "12",
8385
+ category: "layout",
8386
+ description: "Layout grid, gutter, or margin measurement."
8387
+ },
8388
+ {
8389
+ cssVar: "--tree-layout-grid-base",
8390
+ path: "layout.grid.base",
8391
+ value: "8px",
8392
+ category: "layout",
8393
+ description: "Layout grid, gutter, or margin measurement."
8394
+ },
8395
+ {
8396
+ cssVar: "--tree-layout-gutter-sm",
8397
+ path: "layout.gutter.sm",
8398
+ value: "1rem",
8399
+ category: "layout",
8400
+ description: "Layout grid, gutter, or margin measurement."
8401
+ },
8402
+ {
8403
+ cssVar: "--tree-layout-gutter-md",
8404
+ path: "layout.gutter.md",
8405
+ value: "1.5rem",
8406
+ category: "layout",
8407
+ description: "Layout grid, gutter, or margin measurement."
8408
+ },
8409
+ {
8410
+ cssVar: "--tree-layout-margin-sm",
8411
+ path: "layout.margin.sm",
8412
+ value: "1.5rem",
8413
+ category: "layout",
8414
+ description: "Layout grid, gutter, or margin measurement."
8415
+ },
8416
+ {
8417
+ cssVar: "--tree-layout-margin-md",
8418
+ path: "layout.margin.md",
8419
+ value: "2rem",
8420
+ category: "layout",
8421
+ description: "Layout grid, gutter, or margin measurement."
8422
+ },
8423
+ {
8424
+ cssVar: "--tree-layout-margin-lg",
8425
+ path: "layout.margin.lg",
8426
+ value: "3rem",
8427
+ category: "layout",
8428
+ description: "Layout grid, gutter, or margin measurement."
8429
+ },
8430
+ {
8431
+ cssVar: "--tree-z-base",
8432
+ path: "z.base",
8433
+ value: "1",
8434
+ category: "z",
8435
+ description: "Stacking layer (z-index)."
8436
+ },
8437
+ {
8438
+ cssVar: "--tree-z-dropdown",
8439
+ path: "z.dropdown",
8440
+ value: "1000",
8441
+ category: "z",
8442
+ description: "Stacking layer (z-index)."
8443
+ },
8444
+ {
8445
+ cssVar: "--tree-z-popover",
8446
+ path: "z.popover",
8447
+ value: "1050",
8448
+ category: "z",
8449
+ description: "Stacking layer (z-index)."
8450
+ },
8451
+ {
8452
+ cssVar: "--tree-z-sticky",
8453
+ path: "z.sticky",
8454
+ value: "1100",
8455
+ category: "z",
8456
+ description: "Stacking layer (z-index)."
8457
+ },
8458
+ {
8459
+ cssVar: "--tree-z-overlay",
8460
+ path: "z.overlay",
8461
+ value: "1200",
8462
+ category: "z",
8463
+ description: "Stacking layer (z-index)."
8464
+ },
8465
+ {
8466
+ cssVar: "--tree-z-modal",
8467
+ path: "z.modal",
8468
+ value: "1300",
8469
+ category: "z",
8470
+ description: "Stacking layer (z-index)."
8471
+ },
8472
+ {
8473
+ cssVar: "--tree-z-toast",
8474
+ path: "z.toast",
8475
+ value: "1400",
8476
+ category: "z",
8477
+ description: "Stacking layer (z-index)."
8478
+ },
8479
+ {
8480
+ cssVar: "--tree-breakpoint-sm",
8481
+ path: "breakpoint.sm",
8482
+ value: "640px",
8483
+ category: "breakpoint",
8484
+ description: "Responsive breakpoint width."
8485
+ },
8486
+ {
8487
+ cssVar: "--tree-breakpoint-md",
8488
+ path: "breakpoint.md",
8489
+ value: "768px",
8490
+ category: "breakpoint",
8491
+ description: "Responsive breakpoint width."
8492
+ },
8493
+ {
8494
+ cssVar: "--tree-breakpoint-lg",
8495
+ path: "breakpoint.lg",
8496
+ value: "1024px",
8497
+ category: "breakpoint",
8498
+ description: "Responsive breakpoint width."
8499
+ },
8500
+ {
8501
+ cssVar: "--tree-breakpoint-xl",
8502
+ path: "breakpoint.xl",
8503
+ value: "1280px",
8504
+ category: "breakpoint",
8505
+ description: "Responsive breakpoint width."
8506
+ },
8507
+ {
8508
+ cssVar: "--tree-color-bg-primary",
8509
+ path: "color.bg.primary",
8510
+ value: "#f6f8fa",
8511
+ category: "color",
8512
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8513
+ themeValues: {
8514
+ light: "#f6f8fa",
8515
+ dark: "#1c2128"
8516
+ }
8517
+ },
8518
+ {
8519
+ cssVar: "--tree-color-bg-surface",
8520
+ path: "color.bg.surface",
8521
+ value: "#ffffff",
8522
+ category: "color",
8523
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8524
+ themeValues: {
8525
+ light: "#ffffff",
8526
+ dark: "#22272e"
8527
+ }
8528
+ },
8529
+ {
8530
+ cssVar: "--tree-color-bg-subtle",
8531
+ path: "color.bg.subtle",
8532
+ value: "#eff2f5",
8533
+ category: "color",
8534
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8535
+ themeValues: {
8536
+ light: "#eff2f5",
8537
+ dark: "#2d333b"
8538
+ }
8539
+ },
8540
+ {
8541
+ cssVar: "--tree-color-border-default",
8542
+ path: "color.border.default",
8543
+ value: "#d0d7de",
8544
+ category: "color",
8545
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8546
+ themeValues: {
8547
+ light: "#d0d7de",
8548
+ dark: "#444c56"
8549
+ }
8550
+ },
8551
+ {
8552
+ cssVar: "--tree-color-border-strong",
8553
+ path: "color.border.strong",
8554
+ value: "#afb8c1",
8555
+ category: "color",
8556
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8557
+ themeValues: {
8558
+ light: "#afb8c1",
8559
+ dark: "#576270"
8560
+ }
8561
+ },
8562
+ {
8563
+ cssVar: "--tree-color-text-primary",
8564
+ path: "color.text.primary",
8565
+ value: "#1f2328",
8566
+ category: "color",
8567
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8568
+ themeValues: {
8569
+ light: "#1f2328",
8570
+ dark: "#adbac7"
8571
+ }
8572
+ },
8573
+ {
8574
+ cssVar: "--tree-color-text-muted",
8575
+ path: "color.text.muted",
8576
+ value: "#59636e",
8577
+ category: "color",
8578
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8579
+ themeValues: {
8580
+ light: "#59636e",
8581
+ dark: "#95a3b2"
8582
+ }
8583
+ },
8584
+ {
8585
+ cssVar: "--tree-color-text-inverse",
8586
+ path: "color.text.inverse",
8587
+ value: "#ffffff",
8588
+ category: "color",
8589
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8590
+ themeValues: {
8591
+ light: "#ffffff",
8592
+ dark: "#1c2128"
8593
+ }
8594
+ },
8595
+ {
8596
+ cssVar: "--tree-color-brand-primary",
8597
+ path: "color.brand.primary",
8598
+ value: "#0969da",
8599
+ category: "color",
8600
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8601
+ themeValues: {
8602
+ light: "#0969da",
8603
+ dark: "#539bf5"
8604
+ }
8605
+ },
8606
+ {
8607
+ cssVar: "--tree-color-brand-hover",
8608
+ path: "color.brand.hover",
8609
+ value: "#0550ae",
8610
+ category: "color",
8611
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8612
+ themeValues: {
8613
+ light: "#0550ae",
8614
+ dark: "#6cabf7"
8615
+ }
8616
+ },
8617
+ {
8618
+ cssVar: "--tree-color-brand-soft",
8619
+ path: "color.brand.soft",
8620
+ value: "#ddf4ff",
8621
+ category: "color",
8622
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8623
+ themeValues: {
8624
+ light: "#ddf4ff",
8625
+ dark: "#1a3453"
8626
+ }
8627
+ },
8628
+ {
8629
+ cssVar: "--tree-color-brand-contrast",
8630
+ path: "color.brand.contrast",
8631
+ value: "#ffffff",
8632
+ category: "color",
8633
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8634
+ themeValues: {
8635
+ light: "#ffffff",
8636
+ dark: "#0a1a2f"
8637
+ }
8638
+ },
8639
+ {
8640
+ cssVar: "--tree-color-status-success",
8641
+ path: "color.status.success",
8642
+ value: "#1a7f37",
8643
+ category: "color",
8644
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8645
+ themeValues: {
8646
+ light: "#1a7f37",
8647
+ dark: "#57ab5a"
8648
+ }
8649
+ },
8650
+ {
8651
+ cssVar: "--tree-color-status-warning",
8652
+ path: "color.status.warning",
8653
+ value: "#9a6700",
8654
+ category: "color",
8655
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8656
+ themeValues: {
8657
+ light: "#9a6700",
8658
+ dark: "#c69026"
8659
+ }
8660
+ },
8661
+ {
8662
+ cssVar: "--tree-color-status-error",
8663
+ path: "color.status.error",
8664
+ value: "#d1242f",
8665
+ category: "color",
8666
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8667
+ themeValues: {
8668
+ light: "#d1242f",
8669
+ dark: "#f47067"
8670
+ }
8671
+ },
8672
+ {
8673
+ cssVar: "--tree-color-status-info",
8674
+ path: "color.status.info",
8675
+ value: "#0969da",
8676
+ category: "color",
8677
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8678
+ themeValues: {
8679
+ light: "#0969da",
8680
+ dark: "#6cb6ff"
8681
+ }
8682
+ },
8683
+ {
8684
+ cssVar: "--tree-color-chart-1",
8685
+ path: "color.chart.1",
8686
+ value: "#2a78d6",
8687
+ category: "color",
8688
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8689
+ themeValues: {
8690
+ light: "#2a78d6",
8691
+ dark: "#3987e5"
8692
+ }
8693
+ },
8694
+ {
8695
+ cssVar: "--tree-color-chart-2",
8696
+ path: "color.chart.2",
8697
+ value: "#1baf7a",
8698
+ category: "color",
8699
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8700
+ themeValues: {
8701
+ light: "#1baf7a",
8702
+ dark: "#199e70"
8703
+ }
8704
+ },
8705
+ {
8706
+ cssVar: "--tree-color-chart-3",
8707
+ path: "color.chart.3",
8708
+ value: "#eda100",
8709
+ category: "color",
8710
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8711
+ themeValues: {
8712
+ light: "#eda100",
8713
+ dark: "#c98500"
8714
+ }
8715
+ },
8716
+ {
8717
+ cssVar: "--tree-color-chart-4",
8718
+ path: "color.chart.4",
8719
+ value: "#008300",
8720
+ category: "color",
8721
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8722
+ themeValues: {
8723
+ light: "#008300",
8724
+ dark: "#008300"
8725
+ }
8726
+ },
8727
+ {
8728
+ cssVar: "--tree-color-chart-5",
8729
+ path: "color.chart.5",
8730
+ value: "#4a3aa7",
8731
+ category: "color",
8732
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8733
+ themeValues: {
8734
+ light: "#4a3aa7",
8735
+ dark: "#9085e9"
8736
+ }
8737
+ },
8738
+ {
8739
+ cssVar: "--tree-color-chart-6",
8740
+ path: "color.chart.6",
8741
+ value: "#e34948",
8742
+ category: "color",
8743
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8744
+ themeValues: {
8745
+ light: "#e34948",
8746
+ dark: "#e66767"
8747
+ }
8748
+ },
8749
+ {
8750
+ cssVar: "--tree-color-chart-7",
8751
+ path: "color.chart.7",
8752
+ value: "#e87ba4",
8753
+ category: "color",
8754
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8755
+ themeValues: {
8756
+ light: "#e87ba4",
8757
+ dark: "#d55181"
8758
+ }
8759
+ },
8760
+ {
8761
+ cssVar: "--tree-color-chart-8",
8762
+ path: "color.chart.8",
8763
+ value: "#eb6834",
8764
+ category: "color",
8765
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8766
+ themeValues: {
8767
+ light: "#eb6834",
8768
+ dark: "#d95926"
8769
+ }
8770
+ },
8771
+ {
8772
+ cssVar: "--tree-color-overlay",
8773
+ path: "color.overlay",
8774
+ value: "rgba(31, 35, 40, 0.5)",
8775
+ category: "color",
8776
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8777
+ themeValues: {
8778
+ light: "rgba(31, 35, 40, 0.5)",
8779
+ dark: "rgba(13, 17, 23, 0.6)"
8780
+ }
8781
+ },
8782
+ {
8783
+ cssVar: "--tree-color-focus-ring",
8784
+ path: "color.focus-ring",
8785
+ value: "rgba(9, 105, 218, 0.32)",
8786
+ category: "color",
8787
+ description: "Themed semantic color, resolved per [data-tree-theme].",
8788
+ themeValues: {
8789
+ light: "rgba(9, 105, 218, 0.32)",
8790
+ dark: "rgba(83, 155, 245, 0.32)"
8791
+ }
8792
+ }
7374
8793
  ]
7375
8794
  };
7376
8795
 
@@ -7616,6 +9035,43 @@ var searchRecipes = (query, limit = 6) => catalog.recipes.map((recipe) => ({
7616
9035
  recipe,
7617
9036
  score: scoreMatch(query, recipeSearchText(recipe))
7618
9037
  })).filter((result) => result.score > 0).sort((left, right) => right.score - left.score || left.recipe.name.localeCompare(right.recipe.name)).slice(0, limit);
9038
+ var tokenValues = (token) => [
9039
+ token.value,
9040
+ ...Object.values(token.themeValues ?? {})
9041
+ ];
9042
+ var REM_ROOT_PX = 16;
9043
+ var lengthAliases = (query) => {
9044
+ const match = query.trim().match(/^(\d*\.?\d+)(rem|px)$/i);
9045
+ if (!match) {
9046
+ return [];
9047
+ }
9048
+ const amount = Number(match[1]);
9049
+ if (!Number.isFinite(amount)) {
9050
+ return [];
9051
+ }
9052
+ const unit = match[2].toLowerCase();
9053
+ const converted = unit === "rem" ? amount * REM_ROOT_PX : amount / REM_ROOT_PX;
9054
+ return [`${Number(converted.toFixed(4))}${unit === "rem" ? "px" : "rem"}`];
9055
+ };
9056
+ var scoreToken = (token, query) => {
9057
+ const identity = normalizeText(stringifyFields([token.cssVar, token.path]));
9058
+ const category = normalizeText(token.category);
9059
+ const values = normalizeText(stringifyFields(tokenValues(token)));
9060
+ const description = normalizeText(token.description ?? "");
9061
+ const valueScore = Math.max(
9062
+ ...[query, ...lengthAliases(query)].map((candidate) => scoreMatch(candidate, values))
9063
+ );
9064
+ let score = 0;
9065
+ score += scoreMatch(query, identity) * 3;
9066
+ score += scoreMatch(query, category) * 2;
9067
+ score += valueScore * 2;
9068
+ score += scoreMatch(query, description);
9069
+ return Math.max(score, 0);
9070
+ };
9071
+ var searchTokens = (query, limit = 12) => catalog.tokens.map((token) => ({
9072
+ token,
9073
+ score: scoreToken(token, query)
9074
+ })).filter((result) => result.score > 0).sort((left, right) => right.score - left.score || left.token.cssVar.localeCompare(right.token.cssVar)).slice(0, limit);
7619
9075
  var formatFieldList = (label, values) => values.length > 0 ? `${label}: ${values.join(", ")}` : void 0;
7620
9076
  var formatComponentSummary = (component) => {
7621
9077
  const lines = [
@@ -7660,6 +9116,12 @@ var formatRecipeResults = (results) => results.length > 0 ? results.map((result,
7660
9116
  const useWhen = result.recipe.useWhen[0];
7661
9117
  return `${index + 1}. ${result.recipe.name}: ${useWhen ?? "No recipe summary available."} Components: ${result.recipe.compose.join(", ")}.`;
7662
9118
  }).join("\n") : "No matching TreeUI recipes found.";
9119
+ var formatTokenResults = (results) => results.length > 0 ? results.map((result, index) => {
9120
+ const { token } = result;
9121
+ const themeValues = token.themeValues ? Object.entries(token.themeValues).map(([theme, value]) => `${theme} ${value}`).join(" | ") : void 0;
9122
+ const description = token.description ? ` ${token.description}` : "";
9123
+ return `${index + 1}. ${token.cssVar}: ${themeValues ?? token.value} (${token.category} | ${token.path}).${description}`;
9124
+ }).join("\n") : "No matching TreeUI design tokens found.";
7663
9125
  var formatSetupGuide = (componentName) => {
7664
9126
  if (!componentName) {
7665
9127
  return [
@@ -7709,6 +9171,12 @@ var resourceList = [
7709
9171
  description: "Reusable multi-component composition recipes.",
7710
9172
  mimeType: "application/json"
7711
9173
  },
9174
+ {
9175
+ uri: "treeui://tokens",
9176
+ name: "TreeUI design tokens",
9177
+ description: "Flat list of --tree-* design tokens with per-theme values.",
9178
+ mimeType: "application/json"
9179
+ },
7712
9180
  ...catalog.components.map((component) => ({
7713
9181
  uri: `treeui://components/${component.name}`,
7714
9182
  name: component.name,
@@ -7736,6 +9204,9 @@ var readResourcePayload = (uri) => {
7736
9204
  if (uri === "treeui://recipes") {
7737
9205
  return catalog.recipes;
7738
9206
  }
9207
+ if (uri === "treeui://tokens") {
9208
+ return catalog.tokens;
9209
+ }
7739
9210
  const componentMatch = uri.match(/^treeui:\/\/components\/([^/]+)$/);
7740
9211
  if (componentMatch) {
7741
9212
  const component = findComponent(componentMatch[1]);
@@ -7837,6 +9308,21 @@ var createTreeuiMcpServer = () => {
7837
9308
  },
7838
9309
  required: ["query"]
7839
9310
  }
9311
+ },
9312
+ {
9313
+ name: "search_tokens",
9314
+ description: "Search TreeUI design tokens by CSS variable, category, path, or shipped value. Use this before hardcoding any color, spacing, radius, or breakpoint value.",
9315
+ inputSchema: {
9316
+ type: "object",
9317
+ properties: {
9318
+ query: {
9319
+ type: "string",
9320
+ description: "A CSS variable such as --tree-gradient-brand, a category or path such as space or color.status, or a literal value such as 64rem or #0969da."
9321
+ },
9322
+ limit: { type: "number", description: "Maximum number of tokens to return." }
9323
+ },
9324
+ required: ["query"]
9325
+ }
7840
9326
  }
7841
9327
  ]
7842
9328
  }));
@@ -7877,6 +9363,13 @@ var createTreeuiMcpServer = () => {
7877
9363
  }
7878
9364
  return asTextContent(formatRecipeResults(searchRecipes(query, readNumberArg(args, "limit", 6))));
7879
9365
  }
9366
+ if (name === "search_tokens") {
9367
+ const query = readStringArg(args, "query");
9368
+ if (!query) {
9369
+ return asErrorTextContent('The "query" argument is required.');
9370
+ }
9371
+ return asTextContent(formatTokenResults(searchTokens(query, readNumberArg(args, "limit", 12))));
9372
+ }
7880
9373
  return asErrorTextContent(`Unknown tool: ${name}`);
7881
9374
  });
7882
9375
  server.setRequestHandler(import_types.ListResourcesRequestSchema, async () => ({