@progress/kendo-react-mcp 1.1.3 → 1.1.5

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/LICENSE.md CHANGED
@@ -1,15 +1,11 @@
1
- This project has been released under the [Apache License, version 2.0](http://www.apache.org/licenses/LICENSE-2.0.html), the text of which is included below. This license applies ONLY to the source of this repository and does not extend to any other Kendo UI distribution or variant, or any other 3rd party libraries used in a repository. For licensing information about KendoReact, see the [License Agreements page](https://www.telerik.com/purchase/license-agreement/progress-kendoreact).
1
+ # KendoReact
2
2
 
3
- > Copyright © 2025 Progress Software Corporation and/or its subsidiaries or affiliates.
3
+ This package is part of the [KendoReact](https://www.telerik.com/kendo-react-ui) suite.
4
4
 
5
- > Licensed under the Apache License, Version 2.0 (the "License");
6
- > you may not use this file except in compliance with the License.
7
- > You may obtain a copy of the License at
5
+ ## License
8
6
 
9
- > [http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0)
7
+ This is commercial software. To use it, you need to agree to the [**Telerik End User License Agreement for KendoReact**](https://www.telerik.com/purchase/license-agreement/progress-kendoreact). If you do not own a commercial license, this file shall be governed by the trial license terms.
10
8
 
11
- > Unless required by applicable law or agreed to in writing, software
12
- > distributed under the License is distributed on an "AS IS" BASIS,
13
- > WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- > See the License for the specific language governing permissions and
15
- > limitations under the License.
9
+ All available Kendo UI commercial licenses may be obtained at https://www.telerik.com/kendo-react-ui/pricing.
10
+
11
+ *Copyright © 2025 Progress Software Corporation and/or one of its subsidiaries or affiliates. All rights reserved.*
package/dist/index.js CHANGED
@@ -1,90 +1,7 @@
1
1
  #!/usr/bin/env node
2
- var G=Object.defineProperty;var D=(e,t,r)=>t in e?G(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var h=(e,t,r)=>D(e,typeof t!="symbol"?t+"":t,r);import{McpServer as M}from"@modelcontextprotocol/sdk/server/mcp.js";import{StdioServerTransport as O}from"@modelcontextprotocol/sdk/server/stdio.js";import{z as k}from"zod";var A="Kendo UI for React",C="react",f=["ActionSheet","AIPrompt","Animation","AppBar","ArcGauge","AutoComplete","Avatar","Badge","Barcode","BottomNavigation","Breadcrumb","Button","ButtonGroup","Calendar","Card","Chart","ChartWizard","Chat","Checkbox","Chip","ChipList","ChunkProgressBar","CircularGauge","ColorGradient","ColorPalette","ColorPicker","ComboBox","ContextMenu","ConversationalUI","DataGrid","Grid","DataQuery","DateMath","DateInput","DatePicker","DateRangePicker","DateTimePicker","Dialog","Drag&Drop","Drawer","Drawing","DropDownButton","DropDownList","DropDownTree","Editor","Error","ExcelExport","ExpansionPanel","ExternalDropZone","FileSaver","FileManager","Filter","FlatColorPicker","FloatingActionButton","FloatingLabel","FontIcon","Form","Gantt","Gauge","General","GridLayout","Hint","InlineAIPrompt","Input","Label","LinearGauge","ListBox","ListView","Loader","Map","MaskedTextBox","Menu","MultiColumnComboBox","MultiSelect","MultiSelectTree","MultiViewCalendar","Notification","NumericTextBox","OrgChart","PageTemplates/BuildingBlocks","Pager","PanelBar","PDFProcessing","PDFViewer","PivotGrid","Popover","Popup","ProgressBar","QRCode","RadialGauge","RadioButton","RadioGroup","RangeSlider","Rating","Ripple","Sankey","Scheduler","ScrollView","Signature","Skeleton","Slider","Sortable","Sparkline","SpeechToTextButton","SplitButton","Splitter","Spreadsheet","StackLayout","Stepper","StockChart","SVGIcon","Switch","TabStrip","TaskBoard","TextArea","TextBox","TileLayout","Timeline","TimePicker","Toolbar","Tooltip","TreeList","TreeView","Typography","Upload","VSCodeExtension","Window"];import{dirname as L,join as U}from"path";import{fileURLToPath as F}from"url";import{readFileSync as R}from"node:fs";import a from"node:fs";import m from"node:path";import _ from"@grpc/proto-loader";import u from"@grpc/grpc-js";var w=["TELERIK_LICENSE","KENDO_UI_LICENSE"],I="TELERIK_LICENSE_PATH",l=(e=>(e[e.UNAUTHENTICATED=16]="UNAUTHENTICATED",e[e.RESOURCE_EXHAUSTED=8]="RESOURCE_EXHAUSTED",e[e.PERMISSION_DENIED=7]="PERMISSION_DENIED",e))(l||{}),E=!1,n=process.env.DEBUG_LOG_FILE,v=!!(n&&typeof n=="string");if(v){let e=m.resolve(n),t=m.dirname(e);if(t!=="."&&t!==process.cwd()&&!a.existsSync(t))try{a.mkdirSync(t,{recursive:!0})}catch(r){console.error("Error creating log directory:",r)}if(!a.existsSync(e))try{a.writeFileSync(e,"")}catch(r){console.error("Error creating log file:",r)}}else E=!1;E=v&&!!n&&a.existsSync(m.resolve(n));function i(...e){if(E&&n){let t=`${new Date().toISOString()}: ${e.join(" ")}
3
- `,r=m.resolve(n);a.appendFile(r,t,o=>{o&&console.error("Error writing to log file:",o)})}}var s=process.env[I],y=process.env[w[0]]||process.env[w[1]],g=class extends Error{constructor(e){super(e),this.name="LicenseError"}};function P(){if(!s&&!y)throw new g(`No license found. Please set one of the following environment variables: ${w.join(", ")} or ${I}`);let e;if(s)try{e=R(s,"utf8"),i("License key read from file: ",s)}catch{throw new g(`Error reading license file: ${s}. Please verify the file exists and is readable.`)}return y&&(e=y,i("License key read from environment variable.")),e}var S=class{constructor(e,t){h(this,"client");h(this,"isDev");this.contextApiUrl=e,this.protoPath=t;let r=_.loadSync(this.protoPath,{keepCase:!0,longs:String,enums:String,defaults:!0,oneofs:!0});this.isDev=this.contextApiUrl?.includes("localhost")||this.contextApiUrl?.includes("127.0.0.1"),i("Using ContextApi URl:",this.contextApiUrl);let o=u.loadPackageDefinition(r);this.client=new o.ContextQueryService(this.contextApiUrl||"contextapi.telerik.com:443",this.isDev?u.credentials.createInsecure():u.credentials.createSsl())}async query(e){let t=this.isDev?"fake_license":P(),r=new u.Metadata;if(t&&typeof t=="string"){t=t.replace(/^\uFEFF/,"");try{r.add("x-license-key",t)}catch(o){return i("Error adding license key to metadata:",o),Promise.reject(new Error(`Failed to use license key: ${o.message}`))}}return t&&typeof t=="string"&&r.add("x-license-key",t),new Promise((o,d)=>{this.client.query(e,r,(c,p)=>{c?d(c):o(p)})})}};var N=U(L(F(import.meta.url)),"../proto/service.proto"),B=new S("contextapi.telerik.com:443",N);async function T(e){return B.query(e)}import V from"fs";import x from"path";import{fileURLToPath as q}from"url";var K=q(import.meta.url),H=x.dirname(K),j=x.resolve(H,"../package.json"),$=JSON.parse(V.readFileSync(j,"utf-8")),b=new M({name:"kendo-and-kendo-resources",version:$.version});b.tool("kendo_react_assistant",`Answers questions and retrieves documentation about Kendo UI for React.
4
- Use this tool when the user asks about Kendo UI for React features, specific components (e.g., Grid, Chart, Editor), implementation details, or general usage.
5
- Provide the user's detailed question as the 'query'. If the question pertains to a specific Kendo UI for React component,
6
- specify its name in the 'component' parameter. This tool can be automatically triggered when the following phrases are detected in the user's input/prompt:
7
- - 'kendo';
8
- - '/kendo';
9
- - '/kendoreact'
10
- - '/ask_kendo';
11
- - '/help_kendo';
12
- - '@kendo';
13
- - '@kendoreact';
14
- - '@ask_kendo';
15
- - '@help_kendo'.`,{query:k.string().describe("The query to search for."),component:k.enum(f).describe("The component to search for. If not specified, you can use General.")},async({query:e,component:t})=>{i("Calling tool: ",JSON.stringify({query:e,component:t})),t==="Grid"&&(t="DataGrid");try{let r=await T({query:e,component:t.toLocaleLowerCase(),lib_name:C,text_matches_count:3,code_matches_count:0,allowed_types:["documentation"]});i("Response from context API: ",JSON.stringify(r));let o=J(),d=r.values.join(`
16
-
17
- `),c=d.trim(),p=[{type:"text",text:d+(c?`
18
-
19
- `+o:"")}];return i("Response from tool: ",JSON.stringify(p)),{content:p}}catch(r){throw i("Error calling context API: ",JSON.stringify(r)),r?.code===l.UNAUTHENTICATED?new Error("Error: You are not authenticated. Please verify the Telerik License Key provided is valid."):r?.code===l.RESOURCE_EXHAUSTED?new Error(`Error: You have exceeded the extension quota. Upgrade to subscription licensing in order to unlock full access. Message: ${r.message}.`):r?.code===l.PERMISSION_DENIED?new Error(`Error: You do not have permission to access this resource. Please verify that you have a valid ${A} license key.`):r instanceof g?(i("License error: ",r.message),r):new Error(`Error: An error occurred while calling the service. Please try again later.
20
-
21
- Error Message: ${r.message}`)}});function J(){return`
22
- ## Available ReactComponent enum values:
23
- ${f.join(", ")}
24
-
25
- ## Rules
26
- When generating code, explanations, or refactorings, always follow these rules:
27
-
28
- 1. Component Awareness
29
- Whenever a component name is mentioned\u2014regardless of how it's written (all lowercase, all uppercase, mixed case, separate words, or even with typos)\u2014you should always look up the correct example from the corresponding component.
30
-
31
- Key points:
32
- - Match component names case-insensitively and robustly to minor variations
33
- - If someone refers to a component (e.g., "button", "BUTTON", "BuTtOn"), match it to the correct component (Button)
34
- - After matching, use the example or information associated with that component
35
- - The matching should be case-insensitive and robust to minor variations
36
-
37
- Example: If someone asks about "grid", "GRID", or "GrId", you always refer to DataGrid for the example.
38
-
39
- Gotcha:
40
- Don't just use the word as given\u2014always normalize it and check the component to avoid mistakes or mismatches.
41
-
42
- 2. Links Awareness
43
- When providing links or references to documentation, always use links from the https://www.telerik.com/kendo-react-ui domain. Avoid using slug syntax like { slug overview } or any placeholder syntax. Instead, provide complete, direct URLs that users can immediately navigate to.
44
-
45
- Key points:
46
- - Use only https://www.telerik.com/kendo-react-ui domain for Kendo React UI documentation links
47
- - Provide complete URLs, not slug placeholders
48
- - Ensure links are directly accessible and functional
49
- - Avoid any template or placeholder syntax in URLs
50
-
51
- Example:
52
- \u2705 Correct: https://www.telerik.com/kendo-react-ui/components/grid/
53
- \u274C Incorrect: { slug overview } or /components/{component-name}/overview
54
-
55
- 3. Editor Tools Awareness
56
- For Editor component cases, always use the proper EditorTools import structure and never define tools as strings. Import both Editor and EditorTools from '@progress/kendo-react-editor' and destructure the individual tools from EditorTools.
57
-
58
- Required pattern:
59
- \`\`\`jsx
60
- import { Editor, EditorTools } from '@progress/kendo-react-editor';
61
-
62
- const {
63
- Bold, Italic, Underline, Strikethrough,
64
- Subscript, Superscript, ForeColor, BackColor,
65
- CleanFormatting, AlignLeft, AlignCenter, AlignRight, AlignJustify,
66
- Indent, Outdent, OrderedList, UnorderedList,
67
- NumberedList, BulletedList, Undo, Redo,
68
- FontSize, FontName, FormatBlock, Link, Unlink,
69
- InsertImage, ViewHtml, InsertTable, InsertFile,
70
- SelectAll, Print, Pdf, TableProperties, TableCellProperties,
71
- AddRowBefore, AddRowAfter, AddColumnBefore, AddColumnAfter,
72
- DeleteRow, DeleteColumn, DeleteTable, MergeCells, SplitCell
73
- } = EditorTools;
74
- \`\`\`
75
-
76
- Key points:
77
- - Always import both Editor and EditorTools from '@progress/kendo-react-editor'
78
- - Destructure individual tools from EditorTools object
79
- - Use the destructured tool references directly in the tools array
80
- - Never define tools as strings (e.g., 'bold', 'italic')
81
- - Group related tools in sub-arrays for better organization
82
-
83
- Example:
84
- \u2705 Correct: tools={[[Bold, Italic, Underline], [AlignLeft, AlignCenter]]}
85
- \u274C Incorrect: tools={[['bold', 'italic', 'underline'], ['alignLeft', 'alignCenter']]}
86
-
87
- 4. DataGrid Deprecated Properties Awareness
2
+ var P=Object.defineProperty;var U=(e,r,t)=>r in e?P(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t;var h=(e,r,t)=>U(e,typeof r!="symbol"?r+"":r,t);import{McpServer as V}from"@modelcontextprotocol/sdk/server/mcp.js";import{StdioServerTransport as K}from"@modelcontextprotocol/sdk/server/stdio.js";import{z as D}from"zod";var C="Kendo UI for React",I="react",A=["ActionSheet","AIPrompt","Animation","AppBar","ArcGauge","AutoComplete","Avatar","Badge","Barcode","BottomNavigation","Breadcrumb","Button","ButtonGroup","Calendar","Card","Chart","ChartWizard","Chat","Checkbox","Chip","ChipList","ChunkProgressBar","CircularGauge","ColorGradient","ColorPalette","ColorPicker","ComboBox","ContextMenu","ConversationalUI","DataGrid","Grid","DataQuery","DateMath","DateInput","DatePicker","DateRangePicker","DateTimePicker","Dialog","Drag&Drop","Drawer","Drawing","DropDownButton","DropDownList","DropDownTree","Editor","Error","ExcelExport","ExpansionPanel","ExternalDropZone","FileSaver","FileManager","Filter","FlatColorPicker","FloatingActionButton","FloatingLabel","FontIcon","Form","Gantt","Gauge","General","GridLayout","Hint","InlineAIPrompt","Input","Label","LinearGauge","ListBox","ListView","Loader","Map","MaskedTextBox","Menu","MultiColumnComboBox","MultiSelect","MultiSelectTree","MultiViewCalendar","Notification","NumericTextBox","OrgChart","PageTemplates/BuildingBlocks","Pager","PanelBar","PDFProcessing","PDFViewer","PivotGrid","Popover","Popup","ProgressBar","QRCode","RadialGauge","RadioButton","RadioGroup","RangeSlider","Rating","Ripple","Sankey","Scheduler","ScrollView","Signature","Skeleton","Slider","Sortable","Sparkline","SpeechToTextButton","SplitButton","Splitter","Spreadsheet","StackLayout","Stepper","StockChart","SVGIcon","Switch","TabStrip","TaskBoard","TextArea","TextBox","TileLayout","Timeline","TimePicker","Toolbar","Tooltip","TreeList","TreeView","Typography","Upload","VSCodeExtension","Window"];import{dirname as N,join as B}from"path";import{fileURLToPath as M}from"url";import{readFileSync as _}from"node:fs";import s from"node:fs";import m from"node:path";import F from"@grpc/proto-loader";import u from"@grpc/grpc-js";var E=["TELERIK_LICENSE","KENDO_UI_LICENSE"],S="TELERIK_LICENSE_PATH",d=(e=>(e[e.UNAUTHENTICATED=16]="UNAUTHENTICATED",e[e.RESOURCE_EXHAUSTED=8]="RESOURCE_EXHAUSTED",e[e.PERMISSION_DENIED=7]="PERMISSION_DENIED",e))(d||{}),y=!1,n=process.env.DEBUG_LOG_FILE,w=!!(n&&typeof n=="string");if(w){let e=m.resolve(n),r=m.dirname(e);if(r!=="."&&r!==process.cwd()&&!s.existsSync(r))try{s.mkdirSync(r,{recursive:!0})}catch(t){console.error("Error creating log directory:",t)}if(!s.existsSync(e))try{s.writeFileSync(e,"")}catch(t){console.error("Error creating log file:",t)}}else y=!1;y=w&&!!n&&s.existsSync(m.resolve(n));function i(...e){if(y&&n){let r=`${new Date().toISOString()}: ${e.join(" ")}
3
+ `,t=m.resolve(n);s.appendFile(t,r,o=>{o&&console.error("Error writing to log file:",o)})}}var l=process.env[S],f=process.env[E[0]]||process.env[E[1]],g=class extends Error{constructor(e){super(e),this.name="LicenseError"}};function L(){if(!l&&!f)throw new g(`No license found. Please set one of the following environment variables: ${E.join(", ")} or ${S}`);let e;if(l)try{e=_(l,"utf8"),i("License key read from file: ",l)}catch{throw new g(`Error reading license file: ${l}. Please verify the file exists and is readable.`)}return f&&(e=f,i("License key read from environment variable.")),e}var T=class{constructor(e,r){h(this,"client");h(this,"isDev");this.contextApiUrl=e,this.protoPath=r;let t=F.loadSync(this.protoPath,{keepCase:!0,longs:String,enums:String,defaults:!0,oneofs:!0});this.isDev=this.contextApiUrl?.includes("localhost")||this.contextApiUrl?.includes("127.0.0.1"),i("Using ContextApi URl:",this.contextApiUrl);let o=u.loadPackageDefinition(t);this.client=new o.ContextQueryService(this.contextApiUrl||"contextapi.telerik.com:443",this.isDev?u.credentials.createInsecure():u.credentials.createSsl())}async query(e){let r=this.isDev?"fake_license":L(),t=new u.Metadata;if(r&&typeof r=="string"){r=r.replace(/^\uFEFF/,"");try{t.add("x-license-key",r)}catch(o){return i("Error adding license key to metadata:",o),Promise.reject(new Error(`Failed to use license key: ${o.message}`))}}return r&&typeof r=="string"&&t.add("x-license-key",r),new Promise((o,a)=>{this.client.query(e,t,(c,p)=>{c?a(c):o(p)})})}};var O=B(N(M(import.meta.url)),"../proto/service.proto"),q=new T("contextapi.telerik.com:443",O);async function v(e){return q.query(e)}import $ from"fs";import R from"path";import{fileURLToPath as H}from"url";var x=`
4
+ ## DataGrid Deprecated Properties Awareness
88
5
  For DataGrid component cases, avoid using deprecated properties and always use their modern replacements. The following properties are deprecated and should not be used:
89
6
 
90
7
  Deprecated properties and their modern replacements:
@@ -113,10 +30,10 @@ Key points:
113
30
  - Focus on current DataGrid API patterns using state properties and cells/rows props
114
31
 
115
32
  Example:
116
- \u274C Deprecated: selectedField="isSelected" editField="inEdit"
117
- \u2705 Modern: Use select and edit state properties with proper configuration
118
-
119
- 5. Smart Grid (AI-Enhanced Grid) Implementation Guidelines
33
+ Deprecated: selectedField="isSelected" editField="inEdit"
34
+ Modern: Use select and edit state properties with proper configuration
35
+ `;var k=`
36
+ ## Smart Grid (AI-Enhanced Grid) Implementation Guidelines
120
37
  **CRITICAL: When users ask about ANY of these AI grid terms, ALWAYS provide GridToolbarAIAssistant implementation (not basic Grid):**
121
38
 
122
39
  **Primary AI Grid Trigger Terms (case-insensitive):**
@@ -143,10 +60,96 @@ Example Smart Grid suggestions by domain:
143
60
  - Inventory: 'Sort by stock level', 'Show out of stock items', 'Group by category'
144
61
  - Always include: 'Clear sorting', 'Clear filtering', 'Clear grouping'
145
62
 
146
- \u274C Basic Grid: <Grid data={data}><GridColumn field="name" /></Grid>
147
- \u2705 Smart Grid: Complete AI-enhanced setup with GridToolbarAIAssistant, proper callbacks, reset functionality, and contextual suggestions
63
+ Basic Grid: <Grid data={data}><GridColumn field="name" /></Grid>
64
+ Smart Grid: Complete AI-enhanced setup with GridToolbarAIAssistant, proper callbacks, reset functionality, and contextual suggestions
148
65
 
149
66
  Important Disclaimer:
150
67
  Always include this disclaimer when providing Smart Grid examples:
151
68
  "The demos in this article use a Telerik-hosted AI service for demonstration purposes only. For production applications, you should implement your own AI service that understands your specific domain, data, and business requirements."
152
- `}async function W(){let e=new O;i("Starting server..."),await b.connect(e)}W();
69
+ `;var G=`
70
+ ## Editor Tools Awareness
71
+ For Editor component cases, always use the proper EditorTools import structure and never define tools as strings. Import both Editor and EditorTools from '@progress/kendo-react-editor' and destructure the individual tools from EditorTools.
72
+
73
+ Required pattern:
74
+ \`\`\`jsx
75
+ import { Editor, EditorTools } from '@progress/kendo-react-editor';
76
+
77
+ const {
78
+ Bold, Italic, Underline, Strikethrough,
79
+ Subscript, Superscript, ForeColor, BackColor,
80
+ CleanFormatting, AlignLeft, AlignCenter, AlignRight, AlignJustify,
81
+ Indent, Outdent, OrderedList, UnorderedList,
82
+ NumberedList, BulletedList, Undo, Redo,
83
+ FontSize, FontName, FormatBlock, Link, Unlink,
84
+ InsertImage, ViewHtml, InsertTable, InsertFile,
85
+ SelectAll, Print, Pdf, TableProperties, TableCellProperties,
86
+ AddRowBefore, AddRowAfter, AddColumnBefore, AddColumnAfter,
87
+ DeleteRow, DeleteColumn, DeleteTable, MergeCells, SplitCell
88
+ } = EditorTools;
89
+ \`\`\`
90
+
91
+ Key points:
92
+ - Always import both Editor and EditorTools from '@progress/kendo-react-editor'
93
+ - Destructure individual tools from EditorTools object
94
+ - Use the destructured tool references directly in the tools array
95
+ - Never define tools as strings (e.g., 'bold', 'italic')
96
+ - Group related tools in sub-arrays for better organization
97
+
98
+ Example:
99
+ Correct: tools={[[Bold, Italic, Underline], [AlignLeft, AlignCenter]]}
100
+ Incorrect: tools={[['bold', 'italic', 'underline'], ['alignLeft', 'alignCenter']]}
101
+ `;var j=H(import.meta.url),J=R.dirname(j),Y=R.resolve(J,"../package.json"),z=JSON.parse($.readFileSync(Y,"utf-8")),b=new V({name:"kendo-and-kendo-resources",version:z.version});b.tool("kendo_react_assistant",`Answers questions and retrieves documentation about Kendo UI for React.
102
+ Use this tool when the user asks about Kendo UI for React features, specific components (e.g., Grid, Chart, Editor), implementation details, or general usage.
103
+ Provide the user's detailed question as the 'query'. If the question pertains to a specific Kendo UI for React component,
104
+ specify its name in the 'component' parameter. This tool can be automatically triggered when the following phrases are detected in the user's input/prompt:
105
+ - 'kendo';
106
+ - '/kendo';
107
+ - '/kendoreact'
108
+ - '/ask_kendo';
109
+ - '/help_kendo';
110
+ - '@kendo';
111
+ - '@kendoreact';
112
+ - '@ask_kendo';
113
+ - '@help_kendo'.`,{query:D.string().describe("The query to search for."),component:D.enum(A).describe("The component to search for. If not specified, you can use General.")},async({query:e,component:r})=>{i("Calling tool: ",JSON.stringify({query:e,component:r})),r==="Grid"&&(r="DataGrid");try{let t=await v({query:e,component:r.toLocaleLowerCase(),lib_name:I,text_matches_count:3,code_matches_count:0,allowed_types:["documentation"]});i("Response from context API: ",JSON.stringify(t));let o=Q(r.toLowerCase()),a=t.values.join(`
114
+
115
+ `),c=a.trim(),p=[{type:"text",text:a+(c?`
116
+
117
+ `+o:"")}];return i("Response from tool: ",JSON.stringify(p)),{content:p}}catch(t){throw i("Error calling context API: ",JSON.stringify(t)),t?.code===d.UNAUTHENTICATED?new Error("Error: You are not authenticated. Please verify the Telerik License Key provided is valid."):t?.code===d.RESOURCE_EXHAUSTED?new Error(`Error: You have exceeded the extension quota. Upgrade to subscription licensing in order to unlock full access. Message: ${t.message}.`):t?.code===d.PERMISSION_DENIED?new Error(`Error: You do not have permission to access this resource. Please verify that you have a valid ${C} license key.`):t instanceof g?(i("License error: ",t.message),t):new Error(`Error: An error occurred while calling the service. Please try again later.
118
+
119
+ Error Message: ${t.message}`)}});function Q(e){let r=e==="datagrid"?x?.trim():"",t=e==="datagrid"?k?.trim():"",o=e==="editor"?G?.trim():"";return`
120
+ # Kendo UI for React Assistant Guidelines
121
+
122
+ ## Documentation References
123
+ MUST use official Kendo UI for React documentation only.
124
+
125
+ Required Format:
126
+ - Domain: https://www.telerik.com/kendo-react-ui
127
+ - Use complete, functional URLs (no placeholders or slug syntax)
128
+
129
+ Examples:
130
+ Correct: https://www.telerik.com/kendo-react-ui/components/grid/
131
+ Incorrect: { slug overview } or /components/{component-name}/overview
132
+
133
+ ## Styling & Theming
134
+ MUST verify existing theme configuration before adding new styles.
135
+
136
+ Requirements:
137
+ 1. Check if Kendo UI themes are already configured
138
+ 2. Only recommend theme additions when missing
139
+ 3. Provide appropriate import methods
140
+
141
+ ## Icon Implementation
142
+ MUST prioritize SVG icons over font icons.
143
+
144
+ Guidelines:
145
+ - Primary: SVG icons from @progress/kendo-svg-icons
146
+ - Fallback: Font icons with CSS: <link rel="stylesheet" href="https://unpkg.com/@progress/kendo-font-icons/dist/index.css" />
147
+
148
+ ${r.length>0||t.length>0||o.length>0?`## Component-Specific Instructions
149
+
150
+ ${r}
151
+
152
+ ${t}
153
+
154
+ ${o}`:""}
155
+ `}async function W(){let e=new K;i("Starting server... "),await b.connect(e)}W();
@@ -0,0 +1 @@
1
+ export declare const datagridInstructions = "\n## DataGrid Deprecated Properties Awareness\nFor DataGrid component cases, avoid using deprecated properties and always use their modern replacements. The following properties are deprecated and should not be used:\n\nDeprecated properties and their modern replacements:\n- selectedField \u2192 use the select state property\n- editField \u2192 use the edit state property\n- expandedField \u2192 use the detailExpand state property\n- onExpandChange \u2192 use onDetailExpandChange for detail-row expansion or onGroupExpandChange for group expansion\n- cellRender \u2192 use the cells={{ data: CustomCell }} prop\n- rowRender \u2192 use the rows={{ data: CustomRow }} prop\n- filterCellRender \u2192 use the cells={{ filterCell: CustomCell }} prop\n- headerCellRender \u2192 use the cells={{ headerCell: CustomHeaderCell }} prop\n- column.cell \u2192 use the column.cells={{ data: CustomCell }} prop\n- column.headerCell \u2192 use the column.cells={{ headerCell: CustomHeaderCell }} prop\n- column.filterCell \u2192 use the column.cells={{ filterCell: CustomCell }} prop\n- column.footerCell \u2192 use the column.cells={{ footerCell: CustomFooterCell }} prop\n\nAdditional modern updates:\n- Input component in Column Menu Filter has been replaced with Textbox\n- scrollable prop now defaults to virtual\n- Virtual scrolling no longer applies height by default\n\nKey points:\n- Never suggest or use these deprecated properties in DataGrid examples\n- Always provide modern alternatives when users ask about these properties\n- Explain that these properties are deprecated and provide the specific modern replacement\n- Focus on current DataGrid API patterns using state properties and cells/rows props\n\nExample:\nDeprecated: selectedField=\"isSelected\" editField=\"inEdit\"\nModern: Use select and edit state properties with proper configuration\n";
@@ -0,0 +1 @@
1
+ export declare const editorInstructions = "\n## Editor Tools Awareness\nFor Editor component cases, always use the proper EditorTools import structure and never define tools as strings. Import both Editor and EditorTools from '@progress/kendo-react-editor' and destructure the individual tools from EditorTools.\n\nRequired pattern:\n```jsx\nimport { Editor, EditorTools } from '@progress/kendo-react-editor';\n\nconst {\n Bold, Italic, Underline, Strikethrough,\n Subscript, Superscript, ForeColor, BackColor,\n CleanFormatting, AlignLeft, AlignCenter, AlignRight, AlignJustify,\n Indent, Outdent, OrderedList, UnorderedList,\n NumberedList, BulletedList, Undo, Redo,\n FontSize, FontName, FormatBlock, Link, Unlink,\n InsertImage, ViewHtml, InsertTable, InsertFile,\n SelectAll, Print, Pdf, TableProperties, TableCellProperties,\n AddRowBefore, AddRowAfter, AddColumnBefore, AddColumnAfter,\n DeleteRow, DeleteColumn, DeleteTable, MergeCells, SplitCell\n} = EditorTools;\n```\n\nKey points:\n- Always import both Editor and EditorTools from '@progress/kendo-react-editor'\n- Destructure individual tools from EditorTools object\n- Use the destructured tool references directly in the tools array\n- Never define tools as strings (e.g., 'bold', 'italic')\n- Group related tools in sub-arrays for better organization\n\nExample:\nCorrect: tools={[[Bold, Italic, Underline], [AlignLeft, AlignCenter]]}\nIncorrect: tools={[['bold', 'italic', 'underline'], ['alignLeft', 'alignCenter']]}\n";
@@ -0,0 +1 @@
1
+ export declare const smartGridInstructions = "\n## Smart Grid (AI-Enhanced Grid) Implementation Guidelines\n**CRITICAL: When users ask about ANY of these AI grid terms, ALWAYS provide GridToolbarAIAssistant implementation (not basic Grid):**\n\n**Primary AI Grid Trigger Terms (case-insensitive):**\n- smart grid, smartgrid, smart-grid, smart_grid, SMART GRID, SmArt GrId\n- ai grid, aigrid, ai-grid, ai_grid, AI GRID, aI-griD, AIGrid \n- ai enhanced grid, ai-enhanced-grid, ai_enhanced_grid, AI Enhanced Grid\n- ai powered grid, ai-powered-grid, ai_powered_grid, AI Powered Grid\n- intelligent grid, intelligent-grid, intelligent_grid, Intelligent Grid\n- grid with ai, grid-with-ai, grid_with_ai, Grid with AI\n- grid ai assistant, gridaiassistant, grid-ai-assistant, Grid AI Assistant\n- grid toolbar ai assistant, gridtoolbaraiassistant, GridToolbarAIAssistant\n- grid assistant, gridassistant, grid-assistant, Grid Assistant\n\n**Additional variations that should trigger AI Grid:**\n- ai enhanced, ai powered, smart, intelligent + grid (any spacing/casing)\n- grid + ai, grid + smart, grid + intelligent (any spacing/casing) \n- Any mention of GridToolbarAIAssistant component specifically\n\n**Recognition Rule: If query contains ANY combination of AI/Smart/Intelligent + Grid terms, respond with complete GridToolbarAIAssistant setup.**\n\nExample Smart Grid suggestions by domain:\n- Financial: 'Sort by Amount descending', 'Show only failed transactions', 'Filter where currency is USD'\n- Sales: 'Group by region', 'Show top performing products', 'Filter by date range'\n- Inventory: 'Sort by stock level', 'Show out of stock items', 'Group by category'\n- Always include: 'Clear sorting', 'Clear filtering', 'Clear grouping'\n\nBasic Grid: <Grid data={data}><GridColumn field=\"name\" /></Grid>\nSmart Grid: Complete AI-enhanced setup with GridToolbarAIAssistant, proper callbacks, reset functionality, and contextual suggestions\n\nImportant Disclaimer:\nAlways include this disclaimer when providing Smart Grid examples:\n\"The demos in this article use a Telerik-hosted AI service for demonstration purposes only. For production applications, you should implement your own AI service that understands your specific domain, data, and business requirements.\"\n";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-react-mcp",
3
- "version": "1.1.3",
3
+ "version": "1.1.5",
4
4
  "type": "module",
5
5
  "bin": "./dist/index.js",
6
6
  "license": "See LICENSE.md",
@@ -23,15 +23,10 @@
23
23
  "LICENSE.md",
24
24
  "!**/*.tsbuildinfo"
25
25
  ],
26
- "scripts": {
27
- "build": "tsc",
28
- "test": "vitest",
29
- "test:run": "vitest run"
30
- },
31
26
  "dependencies": {
32
- "@grpc/grpc-js": "^1.13.3",
33
- "@grpc/proto-loader": "^0.7.15",
34
- "@modelcontextprotocol/sdk": "^1.8.0",
27
+ "@grpc/grpc-js": "^1.14.1",
28
+ "@grpc/proto-loader": "^0.8.0",
29
+ "@modelcontextprotocol/sdk": "^1.21.1",
35
30
  "tslib": "^2.3.0"
36
31
  },
37
32
  "devDependencies": {
@@ -1,5 +1,6 @@
1
1
  syntax = "proto3";
2
2
  option go_package = "github.com/telerik/ai-builder/contextapi/pkg/api/pb";
3
+ import "google/protobuf/empty.proto";
3
4
 
4
5
 
5
6
  message ContextQueryRequest {
@@ -9,8 +10,7 @@ message ContextQueryRequest {
9
10
  int32 code_matches_count = 4;
10
11
  repeated string allowed_types = 5;
11
12
  string component = 6;
12
- string userId = 7;
13
- string filters_json = 8;
13
+ string filters_json = 7;
14
14
  }
15
15
 
16
16
  message Item {
@@ -47,10 +47,62 @@ message BuildingBlocksSearchResponse {
47
47
  repeated BuildingBlockItem items = 1;
48
48
  }
49
49
 
50
+ message ProductInfo {
51
+ int32 id = 1;
52
+ string code = 2;
53
+ string name = 3;
54
+ }
55
+
56
+ message LicenseInfo {
57
+ int32 id = 1;
58
+ string name = 2;
59
+ string type = 3;
60
+ bool active = 4;
61
+ }
62
+
63
+ message SupportPackageInfo {
64
+ int32 id = 1;
65
+ string name = 2;
66
+ string public_name = 3;
67
+ int32 response_time_hours = 4;
68
+ bool active = 5;
69
+ repeated string incident_types = 6;
70
+ }
71
+
72
+ message AvailabilityInfo {
73
+ string license_start = 1;
74
+ string license_end = 2;
75
+ string support_start = 3;
76
+ string support_end = 4;
77
+ }
78
+
79
+ message EntitlementInfo {
80
+ string code = 1;
81
+ ProductInfo product = 2;
82
+ LicenseInfo license = 3;
83
+ SupportPackageInfo support_package = 4;
84
+ repeated AvailabilityInfo availability = 5;
85
+ bool is_license_available = 6;
86
+ bool is_support_available = 7;
87
+ }
88
+
89
+ message UserInfo {
90
+ string user_id = 1;
91
+ string user_email = 2;
92
+ }
93
+
94
+ message ValidateUserLicenseResponse {
95
+ EntitlementInfo entitlement = 1;
96
+ UserInfo user_info = 2;
97
+ bool has_exceeded_rate_limit = 3;
98
+ }
99
+
50
100
  service ContextQueryService {
51
101
  rpc Query(ContextQueryRequest) returns (StringArray);
52
102
  rpc IconsSearch(CssSearchRequst) returns (StringArray);
53
103
  rpc CssUtilsSearch(CssSearchRequst) returns (StringArray);
54
- rpc BuildingBlocksSearch(BuildingBlocksSearchRequest) returns (BuildingBlocksSearchResponse);
104
+ rpc BuildingBlocksSearch(BuildingBlocksSearchRequest) returns (BuildingBlocksSearchResponse);
105
+ rpc ValidateUserLicense(google.protobuf.Empty) returns (ValidateUserLicenseResponse);
106
+ rpc RecordUserRequest(google.protobuf.Empty) returns (google.protobuf.Empty);
55
107
  }
56
108