@taiga-ui/mcp 0.1.0-alpha.5 → 0.1.0-alpha.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -8,18 +8,20 @@
8
8
 
9
9
  > **🚀 The fastest way to integrate Taiga UI components into your AI workflow**
10
10
 
11
- A Model Context Protocol (MCP) server that provides AI assistants with comprehensive access to [Taiga UI](https://taiga-ui.dev) components. Seamlessly retrieve Taiga UI components implementations for your AI-powered development workflow.
11
+ A Model Context Protocol (MCP) server that provides AI assistants with comprehensive access to
12
+ [Taiga UI](https://taiga-ui.dev) components. Seamlessly retrieve Taiga UI components implementations for your AI-powered
13
+ development workflow.
12
14
 
13
15
  ### Key Features
14
16
 
15
- * **Docs + code snippets**. Full Taiga UI markdown plus ready Angular examples in one place.
16
- * **Two MCP tools**. Discover with `get_list_components`, fetch examples via `get_component_example`.
17
- * **Configurable & lightweight**. Swap source URL (stable/next) without local Angular install.
17
+ - **Docs + code snippets**. Full Taiga UI markdown plus ready Angular examples in one place.
18
+ - **Two MCP tools**. Discover with `get_list_components`, fetch examples via `get_component_example`.
19
+ - **Configurable & lightweight**. Swap source URL (stable/next) without local Angular install.
18
20
 
19
21
  ### Requirements
20
22
 
21
- - Node.js 18 or newer
22
- - VS Code, Cursor, Windsurf, Claude Desktop, Goose or any other MCP client
23
+ - Node.js 18 or newer
24
+ - VS Code, Cursor, Windsurf, Claude Desktop, Goose or any other MCP client
23
25
 
24
26
  ### Getting started
25
27
 
@@ -29,15 +31,15 @@ First, install the Taiga UI MCP server with your client.
29
31
 
30
32
  ```json5
31
33
  {
32
- "mcpServers": {
33
- "taiga-ui": {
34
- "command": "npx",
35
- "args": [
36
- "@taiga-ui/mcp@latest",
37
- "--source-url=https://taiga-ui.dev/llms-full.txt" // or file from "/next" version, if you want
38
- ]
39
- }
40
- }
34
+ mcpServers: {
35
+ 'taiga-ui': {
36
+ command: 'npx',
37
+ args: [
38
+ '@taiga-ui/mcp@latest',
39
+ '--source-url=https://taiga-ui.dev/llms-full.txt', // or file from "/next" version, if you want
40
+ ],
41
+ },
42
+ },
41
43
  }
42
44
  ```
43
45
 
@@ -47,51 +49,51 @@ First, install the Taiga UI MCP server with your client.
47
49
  <summary><b>Core automation</b></summary>
48
50
 
49
51
  1. `get_list_components { query?: string }`
50
-
51
- - Lists component / section identifiers (with fuzzy substring filtering) along with basic metadata (category, package, type).
52
- - Input: optional `query` string to filter IDs (case-insensitive substring).
53
- - Output: strictly structured JSON containing `items`, `total`, `query`.
52
+ - Lists component / section identifiers (with fuzzy substring filtering) along with basic metadata (category,
53
+ package, type).
54
+ - Input: optional `query` string to filter IDs (case-insensitive substring).
55
+ - Output: strictly structured JSON containing `items`, `total`, `query`.
54
56
 
55
57
  ```json5
56
58
  {
57
- "items": [
58
- { "id": "components/Alert", "name": "Alert", "category": "components", "package": "CORE", "type": "component" }
59
- ],
60
- "total": 1,
61
- "query": null
59
+ items: [{id: 'components/Alert', name: 'Alert', category: 'components', package: 'CORE', type: 'component'}],
60
+ total: 1,
61
+ query: null,
62
62
  }
63
63
  ```
64
64
 
65
65
  2. `get_component_example { "names": ["...", "..."] }`
66
-
67
- - Returns full markdown content for each resolved section (entire component documentation).
68
- - Fuzzy name resolution: exact match, path segment, suffix, substring, and `Tui*` variants.
69
- - Input: `{ names: string[] }` (each name length 2).
70
- - Output: `results` array with objects: `query`, `id` (if resolved), `package`, `type`, `suggestions` (only when unresolved), `content` (array of code blocks, if examples exist). Top-level also includes `matched` (count of resolved names).
66
+ - Returns full markdown content for each resolved section (entire component documentation).
67
+ - Fuzzy name resolution: exact match, path segment, suffix, substring, and `Tui*` variants.
68
+ - Input: `{ names: string[] }` (each name length 2).
69
+ - Output: `results` array with objects: `query`, `id` (if resolved), `package`, `type`, `suggestions` (only when
70
+ unresolved), `content` (array of code blocks, if examples exist). Top-level also includes `matched` (count of
71
+ resolved names).
71
72
 
72
73
  ```json5
73
74
  {
74
- "results": [
75
- {
76
- "query": "Alert",
77
- "id": "components/Alert",
78
- "package": "CORE",
79
- "type": "component",
80
- "content": ["# components/Alert\n- **Package**: ... (full section markdown here)"]
81
- }
82
- ],
83
- "matched": 1
75
+ results: [
76
+ {
77
+ query: 'Alert',
78
+ id: 'components/Alert',
79
+ package: 'CORE',
80
+ type: 'component',
81
+ content: ['# components/Alert\n- **Package**: ... (full section markdown here)'],
82
+ },
83
+ ],
84
+ matched: 1,
84
85
  }
85
86
  ```
86
87
 
87
- > Tip: Combine `get_list_components` to discover IDs and then fetch full implementation snippets with `get_component_example`.
88
+ > Tip: Combine `get_list_components` to discover IDs and then fetch full implementation snippets with
89
+ > `get_component_example`.
88
90
 
89
91
  </details>
90
92
 
91
93
  ### Maintained
92
94
 
93
- Taiga UI MCP is a part of [Taiga UI](https://github.com/taiga-family/taiga-ui) libraries family which is backed and used by a
94
- large enterprise. This means you can rely on timely support and continuous development.
95
+ Taiga UI MCP is a part of [Taiga UI](https://github.com/taiga-family/taiga-ui) libraries family which is backed and used
96
+ by a large enterprise. This means you can rely on timely support and continuous development.
95
97
 
96
98
  ### Authors
97
99
 
package/dist/index.js CHANGED
@@ -5,3 +5,4 @@ start().catch((err) => {
5
5
  logError('Unhandled startup error', err);
6
6
  process.exit(1);
7
7
  });
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA,OAAO,EAAC,KAAK,EAAC,MAAM,oBAAoB,CAAC;AACzC,OAAO,EAAC,QAAQ,EAAC,MAAM,mBAAmB,CAAC;AAE3C,KAAK,EAAE,CAAC,KAAK,CAAC,CAAC,GAAY,EAAE,EAAE;IAC3B,QAAQ,CAAC,yBAAyB,EAAE,GAAG,CAAC,CAAC;IAEzC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AACpB,CAAC,CAAC,CAAC"}
@@ -1 +1,2 @@
1
1
  export {};
2
+ //# sourceMappingURL=doc-types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"doc-types.js","sourceRoot":"","sources":["../../src/schemas/doc-types.ts"],"names":[],"mappings":""}
@@ -1,31 +1,33 @@
1
- import { state } from './server.js';
2
1
  import { parseContent } from '../utils/parse-content.js';
2
+ import { state } from './server.js';
3
3
  // 6-hour refresh window
4
4
  const REFRESH_INTERVAL_MS = 6 * 60 * 60 * 1000;
5
5
  export async function fetchSource() {
6
6
  const argProvidedUrl = process.argv
7
7
  .find((arg) => arg.startsWith('--source-url='))
8
8
  ?.split('=')[1];
9
- const sourceUrl = argProvidedUrl || process.env.SOURCE_URL;
9
+ const sourceUrl = argProvidedUrl ?? process.env.SOURCE_URL;
10
10
  if (!sourceUrl) {
11
11
  throw new Error('Source URL not provided. Set SOURCE_URL or pass --source-url=...');
12
12
  }
13
13
  const response = await fetch(sourceUrl).catch((error) => {
14
- throw new Error(`Network error fetching documentation source: ${error?.message || error}`);
14
+ throw new Error(`Network error fetching documentation source: ${error instanceof Error ? error.message : String(error)}`);
15
15
  });
16
- if (!response.ok)
16
+ if (!response.ok) {
17
17
  throw new Error(`Failed to fetch documentation (HTTP ${response.status} ${response.statusText}) from ${sourceUrl}`);
18
+ }
18
19
  const content = await response.text();
19
- if (!content.trim())
20
+ if (!content.trim()) {
20
21
  throw new Error(`Fetched documentation from ${sourceUrl} is empty.`);
22
+ }
21
23
  return { url: sourceUrl, content };
22
24
  }
23
25
  export async function ensureSourceLoaded() {
24
- const isContentStale = !state.lastLoadedAt ||
25
- Date.now() - state.lastLoadedAt > REFRESH_INTERVAL_MS;
26
- if (!(state.sections.length > 0) || isContentStale) {
26
+ const isContentStale = !state.lastLoadedAt || Date.now() - state.lastLoadedAt > REFRESH_INTERVAL_MS;
27
+ if (!state.sections.length || isContentStale) {
27
28
  const { url, content } = await fetchSource();
28
29
  parseContent(content, url);
29
30
  state.lastLoadedAt = Date.now();
30
31
  }
31
32
  }
33
+ //# sourceMappingURL=fetch.js.map
@@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;QAClB,MAAM,IAAI,KAAK,CAAC,8BAA8B,SAAS,YAAY,CAAC,CAAC;IACzE,CAAC;IAED,OAAO,EAAC,GAAG,EAAE,SAAS,EAAE,OAAO,EAAC,CAAC;AACrC,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,kBAAkB;IACpC,MAAM,cAAc,GAChB,CAAC,KAAK,CAAC,YAAY,IAAI,IAAI,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,YAAY,GAAG,mBAAmB,CAAC;IAEjF,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM,IAAI,cAAc,EAAE,CAAC;QAC3C,MAAM,EAAC,GAAG,EAAE,OAAO,EAAC,GAAG,MAAM,WAAW,EAAE,CAAC;QAE3C,YAAY,CAAC,OAAO,EAAE,GAAG,CAAC,CAAC;QAE3B,KAAK,CAAC,YAAY,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC;IACpC,CAAC;AACL,CAAC"}
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
3
3
  import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
4
- import { ensureSourceLoaded } from './fetch.js';
5
4
  import { registerAllTools } from '../tools/index.js';
5
+ import { ensureSourceLoaded } from './fetch.js';
6
6
  export const state = {
7
7
  sections: [],
8
8
  sourceUrl: undefined,
@@ -24,3 +24,4 @@ export async function start() {
24
24
  await server.connect(transport);
25
25
  console.error(`Angular Taiga UI MCP Server running. Fetched source components: ${state.sections.length}`);
26
26
  }
27
+ //# sourceMappingURL=server.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.js","sourceRoot":"","sources":["../../src/server/server.ts"],"names":[],"mappings":";AACA,OAAO,EAAC,SAAS,EAAC,MAAM,yCAAyC,CAAC;AAClE,OAAO,EAAC,oBAAoB,EAAC,MAAM,2CAA2C,CAAC;AAG/E,OAAO,EAAC,gBAAgB,EAAC,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAC,kBAAkB,EAAC,MAAM,YAAY,CAAC;AAQ9C,MAAM,CAAC,MAAM,KAAK,GAAe;IAC7B,QAAQ,EAAE,EAAE;IACZ,SAAS,EAAE,SAAS;IACpB,YAAY,EAAE,SAAS;CAC1B,CAAC;AAEF,MAAM,MAAM,GAAG,IAAI,SAAS,CAAC;IACzB,IAAI,EAAE,cAAc;IACpB,OAAO,EAAE,eAAe;CAC3B,CAAC,CAAC;AAEH,gBAAgB,CAAC,MAAM,CAAC,CAAC;AAEzB,MAAM,CAAC,KAAK,UAAU,KAAK;IACvB,IAAI,CAAC;QACD,MAAM,kBAAkB,EAAE,CAAC;IAC/B,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACb,OAAO,CAAC,KAAK,CAAC,6BAA6B,EAAE,KAAK,CAAC,CAAC;IACxD,CAAC;IAED,MAAM,SAAS,GAAG,IAAI,oBAAoB,EAAE,CAAC;IAE7C,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IAEhC,OAAO,CAAC,KAAK,CACT,mEAAmE,KAAK,CAAC,QAAQ,CAAC,MAAM,EAAE,CAC7F,CAAC;AACN,CAAC"}
@@ -18,14 +18,12 @@ export function registerGetComponentExampleTool(server) {
18
18
  matched: z.number(),
19
19
  },
20
20
  }, async ({ names }) => {
21
- if (!names || !names.length) {
21
+ if (!names.length) {
22
22
  const output = {
23
23
  error: 'Provide at least one name in names array.',
24
24
  };
25
25
  return {
26
- content: [
27
- { type: 'text', text: JSON.stringify(output, null, 2) },
28
- ],
26
+ content: [{ type: 'text', text: JSON.stringify(output, null, 2) }],
29
27
  structuredContent: output,
30
28
  };
31
29
  }
@@ -33,10 +31,9 @@ export function registerGetComponentExampleTool(server) {
33
31
  const { results, matches } = buildQueryResults(names);
34
32
  const output = { results, matched: matches };
35
33
  return {
36
- content: [
37
- { type: 'text', text: JSON.stringify(output, null, 2) },
38
- ],
34
+ content: [{ type: 'text', text: JSON.stringify(output, null, 2) }],
39
35
  structuredContent: output,
40
36
  };
41
37
  });
42
38
  }
39
+ //# sourceMappingURL=get-component-example.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-component-example.js","sourceRoot":"","sources":["../../src/tools/get-component-example.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,OAAO,EAAC,kBAAkB,EAAC,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAE5D,MAAM,UAAU,+BAA+B,CAAC,MAAiB;IAC7D,MAAM,CAAC,YAAY,CACf,uBAAuB,EACvB;QACI,KAAK,EAAE,uBAAuB;QAC9B,WAAW,EACP,2JAA2J;QAC/J,WAAW,EAAE,EAAC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAC;QACvD,YAAY,EAAE;YACV,OAAO,EAAE,CAAC,CAAC,KAAK,CACZ,CAAC,CAAC,MAAM,CAAC;gBACL,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE;gBACjB,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;gBACzB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;gBACzC,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;gBACtC,WAAW,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;gBAC3C,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;aAC1C,CAAC,CACL;YACD,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;SACtB;KACJ,EACD,KAAK,EAAE,EAAC,KAAK,EAAoB,EAAE,EAAE;QACjC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;YAChB,MAAM,MAAM,GAAG;gBACX,KAAK,EAAE,2CAA2C;aACrD,CAAC;YAEF,OAAO;gBACH,OAAO,EAAE,CAAC,EAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,EAAC,CAAC;gBAChE,iBAAiB,EAAE,MAAM;aAC5B,CAAC;QACN,CAAC;QAED,MAAM,kBAAkB,EAAE,CAAC;QAE3B,MAAM,EAAC,OAAO,EAAE,OAAO,EAAC,GAAG,iBAAiB,CAAC,KAAK,CAAC,CAAC;QACpD,MAAM,MAAM,GAAG,EAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAC,CAAC;QAE3C,OAAO;YACH,OAAO,EAAE,CAAC,EAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,EAAC,CAAC;YAChE,iBAAiB,EAAE,MAAM;SAC5B,CAAC;IACN,CAAC,CACJ,CAAC;AACN,CAAC"}
@@ -36,3 +36,4 @@ export function registerGetListComponentsTool(server) {
36
36
  };
37
37
  });
38
38
  }
39
+ //# sourceMappingURL=get-list-components.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-list-components.js","sourceRoot":"","sources":["../../src/tools/get-list-components.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,OAAO,EAAC,kBAAkB,EAAC,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAC,uBAAuB,EAAC,MAAM,6BAA6B,CAAC;AAEpE,MAAM,UAAU,6BAA6B,CAAC,MAAiB;IAC3D,MAAM,CAAC,YAAY,CACf,qBAAqB,EACrB;QACI,KAAK,EAAE,iBAAiB;QACxB,WAAW,EACP,qEAAqE;QACzE,WAAW,EAAE,EAAC,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,EAAC;QAC3C,YAAY,EAAE;YACV,KAAK,EAAE,CAAC,CAAC,KAAK,CACV,CAAC,CAAC,MAAM,CAAC;gBACL,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE;gBACd,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;gBAChB,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE;gBACpB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;gBAC9B,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;aAC9B,CAAC,CACL;YACD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE;YACjB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;SAC/B;KACJ,EACD,KAAK,EAAE,EAAC,KAAK,EAAmB,EAAE,EAAE;QAChC,MAAM,kBAAkB,EAAE,CAAC;QAE3B,MAAM,EAAC,KAAK,EAAE,eAAe,EAAC,GAAG,uBAAuB,CAAC,KAAK,CAAC,CAAC;QAEhE,MAAM,MAAM,GAAG;YACX,KAAK;YACL,KAAK,EAAE,KAAK,CAAC,MAAM;YACnB,KAAK,EAAE,eAAe;SACzB,CAAC;QAEF,OAAO;YACH,OAAO,EAAE;gBACL;oBACI,IAAI,EAAE,MAAM;oBACZ,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;iBACxC;aACJ;YACD,iBAAiB,EAAE,MAAM;SAC5B,CAAC;IACN,CAAC,CACJ,CAAC;AACN,CAAC"}
@@ -1,6 +1,7 @@
1
- import { registerGetListComponentsTool } from './get-list-components.js';
2
1
  import { registerGetComponentExampleTool } from './get-component-example.js';
2
+ import { registerGetListComponentsTool } from './get-list-components.js';
3
3
  export function registerAllTools(server) {
4
4
  registerGetListComponentsTool(server);
5
5
  registerGetComponentExampleTool(server);
6
6
  }
7
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,+BAA+B,EAAC,MAAM,4BAA4B,CAAC;AAC3E,OAAO,EAAC,6BAA6B,EAAC,MAAM,0BAA0B,CAAC;AAEvE,MAAM,UAAU,gBAAgB,CAAC,MAAiB;IAC9C,6BAA6B,CAAC,MAAM,CAAC,CAAC;IACtC,+BAA+B,CAAC,MAAM,CAAC,CAAC;AAC5C,CAAC"}
@@ -9,9 +9,7 @@ export function findSection(name) {
9
9
  const camelCase = pascalCase
10
10
  ? pascalCase.charAt(0).toLowerCase() + pascalCase.slice(1)
11
11
  : '';
12
- const tuiVariant = pascalCase.startsWith('Tui')
13
- ? pascalCase
14
- : 'Tui' + pascalCase;
12
+ const tuiVariant = pascalCase.startsWith('Tui') ? pascalCase : `Tui${pascalCase}`;
15
13
  const variants = [
16
14
  name.toLowerCase(),
17
15
  pascalCase,
@@ -22,26 +20,29 @@ export function findSection(name) {
22
20
  // Exact match
23
21
  for (const variant of variants) {
24
22
  const exactMatch = state.sections.find((section) => section.id.toLowerCase() === variant.toLowerCase());
25
- if (exactMatch)
23
+ if (exactMatch) {
26
24
  return exactMatch;
25
+ }
27
26
  }
28
27
  // Last path segment match
29
28
  for (const variant of variants) {
30
- const segmentMatch = state.sections.find((section) => section.id.split('/').pop()?.toLowerCase() ===
31
- variant.toLowerCase());
32
- if (segmentMatch)
29
+ const segmentMatch = state.sections.find((section) => section.id.split('/').pop()?.toLowerCase() === variant.toLowerCase());
30
+ if (segmentMatch) {
33
31
  return segmentMatch;
32
+ }
34
33
  }
35
34
  // Ends-with match
36
35
  for (const variant of variants) {
37
- const endsWithMatch = state.sections.find((section) => section.id.toLowerCase().endsWith('/' + variant.toLowerCase()));
38
- if (endsWithMatch)
36
+ const endsWithMatch = state.sections.find((section) => section.id.toLowerCase().endsWith(`/${variant.toLowerCase()}`));
37
+ if (endsWithMatch) {
39
38
  return endsWithMatch;
39
+ }
40
40
  }
41
41
  // Substring fallback
42
42
  const substringMatch = state.sections.find((section) => section.id.toLowerCase().includes(name.toLowerCase()));
43
- if (substringMatch)
43
+ if (substringMatch) {
44
44
  return substringMatch;
45
+ }
45
46
  return undefined;
46
47
  }
47
48
  export function suggestSections(query) {
@@ -62,3 +63,4 @@ export function suggestSections(query) {
62
63
  .sort((a, b) => a.score - b.score)
63
64
  .map((result) => result.id);
64
65
  }
66
+ //# sourceMappingURL=find-section.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"find-section.js","sourceRoot":"","sources":["../../src/utils/find-section.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,KAAK,EAAC,MAAM,qBAAqB,CAAC;AAE1C,MAAM,UAAU,WAAW,CAAC,IAAY;IACpC,MAAM,UAAU,GAAG,IAAI;SAClB,WAAW,EAAE;SACb,KAAK,CAAC,SAAS,CAAC;SAChB,MAAM,CAAC,OAAO,CAAC;SACf,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;SAC3D,IAAI,CAAC,EAAE,CAAC,CAAC;IAEd,MAAM,SAAS,GAAG,UAAU;QACxB,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC;QAC1D,CAAC,CAAC,EAAE,CAAC;IAET,MAAM,UAAU,GAAG,UAAU,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,MAAM,UAAU,EAAE,CAAC;IAElF,MAAM,QAAQ,GAAG;QACb,IAAI,CAAC,WAAW,EAAE;QAClB,UAAU;QACV,SAAS;QACT,U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AAQ,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,CACxD,CAAC;IAEF,IAAI,cAAc,EAAE,CAAC;QACjB,OAAO,cAAc,CAAC;IAC1B,CAAC;IAED,OAAO,SAAS,CAAC;AACrB,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,KAAa;IACzC,MAAM,eAAe,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC;IAE5C,OAAO,KAAK,CAAC,QAAQ;SAChB,GAAG,CAAC,CAAC,OAAO,EAAE,EAAE;QACb,MAAM,cAAc,GAAG,OAAO,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC;QAChD,MAAM,UAAU,GAAG,cAAc,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;QAE3D,OAAO,UAAU,KAAK,CAAC,CAAC;YACpB,CAAC,CAAC,IAAI;YACN,CAAC,CAAC;gBACI,EAAE,EAAE,OAAO,CAAC,EAAE;gBACd,KAAK,EACD,UAAU,GAAG,EAAE;oBACf,IAAI,CAAC,GAAG,CAAC,cAAc,CAAC,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC;aAC/D,CAAC;IACZ,CAAC,CAAC;SACD,MAAM,CAAC,CAAC,SAAS,EAA4C,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;SAC5E,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC;SACjC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AACpC,CAAC"}
@@ -1,13 +1,12 @@
1
1
  import { state } from '../server/server.js';
2
2
  export function constructComponentsList(query = '') {
3
- const normalizedQuery = query?.toLowerCase().replace(/^tui/, '');
3
+ const normalizedQuery = query.toLowerCase().replace(/^tui/, '');
4
4
  const items = state.sections
5
- .filter((section) => !normalizedQuery ||
6
- section.id.toLowerCase().includes(normalizedQuery))
5
+ .filter((section) => !normalizedQuery || section.id.toLowerCase().includes(normalizedQuery))
7
6
  .map((section) => {
8
7
  const idParts = section.id.split('/');
9
- const name = idParts[idParts.length - 1] || section.id;
10
- const category = idParts[0] || '';
8
+ const name = idParts[idParts.length - 1] ?? section.id;
9
+ const category = idParts[0] ?? '';
11
10
  return {
12
11
  id: section.id,
13
12
  name,
@@ -18,3 +17,4 @@ export function constructComponentsList(query = '') {
18
17
  });
19
18
  return { items, normalizedQuery };
20
19
  }
20
+ //# sourceMappingURL=list-components.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"list-components.js","sourceRoot":"","sources":["../../src/utils/list-components.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,KAAK,EAAC,MAAM,qBAAqB,CAAC;AAU1C,MAAM,UAAU,uBAAuB,CAAC,KAAK,GAAG,EAAE;IAI9C,MAAM,eAAe,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;IAEhE,MAAM,KAAK,GAAsB,KAAK,CAAC,QAAQ;SAC1C,MAAM,CACH,CAAC,OAAO,EAAE,EAAE,CACR,CAAC,eAAe,IAAI,OAAO,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,eAAe,CAAC,CAC7E;SACA,GAAG,CAAC,CAAC,OAAO,EAAE,EAAE;QACb,MAAM,OAAO,GAAG,OAAO,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACtC,MAAM,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,IAAI,OAAO,CAAC,EAAE,CAAC;QACvD,MAAM,QAAQ,GAAG,OAAO,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;QAElC,OAAO;YACH,EAAE,EAAE,OAAO,CAAC,EAAE;YACd,IAAI;YACJ,QAAQ;YACR,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,IAAI;YAChC,IAAI,EAAE,OAAO,CAAC,IAAI,IAAI,IAAI;SAC7B,CAAC;IACN,CAAC,CAAC,CAAC;IAEP,OAAO,EAAC,KAAK,EAAE,eAAe,EAAC,CAAC;AACpC,CAAC"}
@@ -1,7 +1,8 @@
1
1
  export function logError(message, err) {
2
- const stack = err instanceof Error ? err.stack || err.message : String(err);
2
+ const stack = err instanceof Error ? (err.stack ?? err.message) : String(err);
3
3
  console.error(`[ERROR] ${message}: ${stack}`);
4
4
  }
5
5
  export function logInfo(message) {
6
6
  console.error(`[INFO] ${message}`);
7
7
  }
8
+ //# sourceMappingURL=logger.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/utils/logger.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,QAAQ,CAAC,OAAe,EAAE,GAAY;IAClD,MAAM,KAAK,GAAG,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,IAAI,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAE9E,OAAO,CAAC,KAAK,CAAC,WAAW,OAAO,KAAK,KAAK,EAAE,CAAC,CAAC;AAClD,CAAC;AAED,MAAM,UAAU,OAAO,CAAC,OAAe;IACnC,OAAO,CAAC,KAAK,CAAC,UAAU,OAAO,EAAE,CAAC,CAAC;AACvC,CAAC"}
@@ -3,11 +3,13 @@ function extractMeta(text) {
3
3
  let pkg;
4
4
  let kind;
5
5
  const pkgMatch = /\*\*Package\*\*:\s*`([^`]+)`/i.exec(text);
6
- if (pkgMatch)
6
+ if (pkgMatch?.[1]) {
7
7
  pkg = pkgMatch[1];
8
+ }
8
9
  const typeMatch = /\*\*Type\*\*:\s*([^\n]+)/i.exec(text);
9
- if (typeMatch)
10
+ if (typeMatch?.[1]) {
10
11
  kind = typeMatch[1].trim();
12
+ }
11
13
  return { package: pkg, kind };
12
14
  }
13
15
  export function parseContent(rawContent, sourceUrl) {
@@ -15,12 +17,17 @@ export function parseContent(rawContent, sourceUrl) {
15
17
  const lines = rawContent.split(/\r?\n/);
16
18
  const headerIndices = [];
17
19
  for (let lineIndex = 0; lineIndex < lines.length; lineIndex++) {
18
- const headerMatch = /^#\s+(.+)$/.exec(lines[lineIndex]);
19
- if (headerMatch)
20
+ const line = lines[lineIndex];
21
+ if (line === undefined) {
22
+ continue;
23
+ }
24
+ const headerMatch = /^#\s+(.+)$/.exec(line);
25
+ if (headerMatch?.[1]) {
20
26
  headerIndices.push({
21
27
  line: lineIndex,
22
28
  title: headerMatch[1].trim(),
23
29
  });
30
+ }
24
31
  }
25
32
  state.sections = headerIndices.map((header, headerIndex) => {
26
33
  const start = header.line;
@@ -36,3 +43,4 @@ export function parseContent(rawContent, sourceUrl) {
36
43
  };
37
44
  });
38
45
  }
46
+ //# sourceMappingURL=parse-content.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"parse-content.js","sourceRoot":"","sources":["../../src/utils/parse-content.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,KAAK,EAAC,MAAM,qBAAqB,CAAC;AAE1C,SAAS,WAAW,CAAC,IAAY;IAC7B,IAAI,GAAuB,CAAC;IAC5B,IAAI,IAAwB,CAAC;IAE7B,MAAM,QAAQ,GAAG,+BAA+B,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAE5D,IAAI,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAChB,GAAG,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;IACtB,CAAC;IAED,MAAM,SAAS,GAAG,2BAA2B,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAEzD,IAAI,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QACjB,IAAI,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;IAC/B,CAAC;IAED,OAAO,EAAC,OAAO,EAAE,GAAG,EAAE,IAAI,EAAC,CAAC;AAChC,CAAC;AAED,MAAM,UAAU,YAAY,CAAC,UAAkB,EAAE,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CAAC;IACN,CAAC,CAAC,CAAC;AACP,CAAC"}
@@ -2,8 +2,9 @@ import { findSection, suggestSections } from './find-section.js';
2
2
  export function extractContentSnippets(section) {
3
3
  const text = section.content || '';
4
4
  const trimmed = text.trim();
5
- if (!trimmed)
5
+ if (!trimmed) {
6
6
  return [];
7
+ }
7
8
  const cleaned = trimmed
8
9
  .split(/\r?\n/)
9
10
  .map((line) => line.replace(/^#{1,6}\s*/, ''))
@@ -27,13 +28,15 @@ export function buildQueryResults(names) {
27
28
  const foundResult = {
28
29
  query: queryName,
29
30
  id: section.id,
30
- package: section.package || null,
31
- type: section.kind || null,
31
+ package: section.package ?? null,
32
+ type: section.kind ?? null,
32
33
  };
33
- if (snippets.length)
34
+ if (snippets.length) {
34
35
  foundResult.content = snippets;
36
+ }
35
37
  results.push(foundResult);
36
38
  }
37
39
  const matches = results.filter((result) => !!result.id).length;
38
40
  return { results, matches };
39
41
  }
42
+ //# sourceMappingURL=query-results.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"query-results.js","sourceRoot":"","sources":["../../src/utils/query-results.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,WAAW,EAAE,eAAe,EAAC,MAAM,mBAAmB,CAAC;AAE/D,MAAM,UAAU,sBAAsB,CAAC,OAAmB;IACtD,MAAM,IAAI,GAAG,OAAO,CAAC,OAAO,IAAI,EAAE,CAAC;IACnC,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,EAAE,CAAC;IAE5B,IAAI,CAAC,OAAO,EAAE,CAAC;QACX,OAAO,EAAE,CAAC;IACd,CAAC;IAED,MAAM,OAAO,GAAG,OAAO;SAClB,KAAK,CAAC,OAAO,CAAC;SACd,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;SAC7C,IAAI,CAAC,IAAI,CAAC;SACV,IAAI,EAAE,CAAC;IAEZ,OAAO,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AACpC,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,KAAe;IAI7C,MAAM,OAAO,GAAkB,EAAE,CAAC;IAElC,KAAK,MAAM,SAAS,IAAI,KAAK,EAAE,CAAC;QAC5B,MAAM,OAAO,GAAG,WAAW,CAAC,SAAS,CAAC,CAAC;QAEvC,IAAI,CAAC,OAAO,EAAE,CAAC;YACX,MAAM,QAAQ,GAAgB;gBAC1B,KAAK,EAAE,SAAS;gBAChB,WAAW,EAAE,eAAe,CAAC,SAAS,CAAC;aAC1C,CAAC;YAEF,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;YAEvB,SAAS;QACb,CAAC;QAED,MAAM,QAAQ,GAAG,sBAAsB,CAAC,OAAO,CAAC,CAAC;QAEjD,MAAM,WAAW,GAAgB;YAC7B,KAAK,EAAE,SAAS;YAChB,EAAE,EAAE,OAAO,CAAC,EAAE;YACd,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,IAAI;YAChC,IAAI,EAAE,OAAO,CAAC,IAAI,IAAI,IAAI;SAC7B,CAAC;QAEF,IAAI,QAAQ,CAAC,MAAM,EAAE,CAAC;YAClB,WAAW,CAAC,OAAO,GAAG,QAAQ,CAAC;QACnC,CAAC;QAED,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAC9B,CAAC;IAED,MAAM,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,MAAM,CAAC;IAE/D,OAAO,EAAC,OAAO,EAAE,OAAO,EAAC,CAAC;AAC9B,CAAC"}
package/package.json CHANGED
@@ -1,17 +1,7 @@
1
1
  {
2
2
  "name": "@taiga-ui/mcp",
3
- "version": "0.1.0-alpha.5",
3
+ "version": "0.1.0-alpha.6",
4
4
  "description": "Model Context Protocol server providing Taiga UI documentation search and scaffolding tools.",
5
- "type": "module",
6
- "main": "./dist/index.js",
7
- "bin": {
8
- "taiga-ui-mcp": "./dist/index.js"
9
- },
10
- "files": [
11
- "dist/**/*",
12
- "README.md",
13
- "LICENSE"
14
- ],
15
5
  "keywords": [
16
6
  "mcp",
17
7
  "model-context-protocol",
@@ -23,7 +13,6 @@
23
13
  "claude",
24
14
  "copilot"
25
15
  ],
26
- "license": "Apache-2.0",
27
16
  "homepage": "https://github.com/taiga-family/taiga-ui-mcp#README",
28
17
  "bugs": {
29
18
  "url": "https://github.com/taiga-family/taiga-ui-mcp/issues"
@@ -32,29 +21,63 @@
32
21
  "type": "git",
33
22
  "url": "git+https://github.com/taiga-family/taiga-ui-mcp.git"
34
23
  },
35
- "authors": [
36
- "Vladimir Potekhin <vladimir.potekh@gmail.com>",
37
- "German Panov <zidakbew@gmail.com>"
24
+ "license": "Apache-2.0",
25
+ "type": "module",
26
+ "main": "./dist/index.js",
27
+ "bin": {
28
+ "taiga-ui-mcp": "./dist/index.js"
29
+ },
30
+ "files": [
31
+ "dist/**/*",
32
+ "README.md",
33
+ "LICENSE"
38
34
  ],
39
35
  "scripts": {
36
+ "prepare": "husky",
37
+ "*** Workflow ***": "",
40
38
  "start": "node dist/index.js",
41
39
  "clean": "rm -rf dist",
42
- "build": "npm run clean && tsc && chmod +x dist/index.js",
40
+ "build": "npm run clean && tsc --incremental false && chmod 755 dist/index.js",
41
+ "*** Format ***": "",
42
+ "lint": "eslint .",
43
+ "cspell": "cspell --relative --dot --gitignore .",
44
+ "prettier": "prettier !package-lock.json . --ignore-path .gitignore",
45
+ "typecheck": "tsc --noEmit --incremental false",
43
46
  "prepublishOnly": "npm run build",
44
47
  "release": "npm publish --access public --tag latest",
45
48
  "postrelease": "npm dist-tag add @taiga-ui/mcp@$(node -p 'require(`./package.json`).version') alpha"
46
49
  },
47
- "engines": {
48
- "node": ">=18.0.0"
50
+ "commitlint": {
51
+ "extends": [
52
+ "@taiga-ui/commitlint-config"
53
+ ]
54
+ },
55
+ "lint-staged": {
56
+ "*.{js,ts,html,md,less,json,svg,yml}": [
57
+ "npm run lint -- --fix",
58
+ "prettier --write"
59
+ ]
49
60
  },
61
+ "browserslist": [
62
+ "extends @taiga-ui/browserslist-config"
63
+ ],
64
+ "prettier": "@taiga-ui/prettier-config",
50
65
  "dependencies": {
51
- "@modelcontextprotocol/sdk": "^1.20.0",
52
- "zod": "^3.25.76"
66
+ "@modelcontextprotocol/sdk": "1.20.0",
67
+ "zod": "3.25.76"
53
68
  },
54
69
  "devDependencies": {
55
- "@taiga-ui/release-it-config": "0.344.0",
56
- "@taiga-ui/auto-changelog-config": "0.344.0",
57
- "@types/node": "^24.7.2",
58
- "typescript": "^5.9.3"
59
- }
70
+ "@taiga-ui/configs": "0.352.0",
71
+ "@types/node": "24.9.1",
72
+ "husky": "9.1.7",
73
+ "lint-staged": "15.5.2",
74
+ "typescript": "5.9.3"
75
+ },
76
+ "engines": {
77
+ "node": ">=18.0.0"
78
+ },
79
+ "authors": [
80
+ "Vladimir Potekhin <vladimir.potekh@gmail.com>",
81
+ "German Panov <zidakbew@gmail.com>"
82
+ ]
60
83
  }