get_component_developer_notes
Retrieve developer implementation notes for accessibility components, including code examples, WCAG mappings, and technical guidance for web or native platforms.
Instructions
Get developer implementation notes for a component. Includes code examples, WCAG mappings, and technical guidance.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| platform | Yes | Platform (web or native) | |
| component | Yes | Component name (e.g., "button", "checkbox") |
Implementation Reference
- src/index.ts:314-347 (handler)Primary handler function that executes the tool logic: fetches developer notes via ContentLoader for the specified platform and component, returns as MCP text content, handles errors with suggestions and available formats.async function handleGetComponentDeveloperNotes(args: any) { try { const content = await contentLoader.getComponentContent(args.platform, args.component, 'developerNotes'); return { content: [ { type: 'text', text: content, }, ], }; } catch (error: any) { const suggestions = contentLoader.getSimilarComponents(args.platform, args.component); const formats = contentLoader.getAvailableFormats(args.platform, args.component); return { content: [ { type: 'text', text: JSON.stringify( { error: error.message, component: args.component, suggestions, availableFormats: formats, }, null, 2 ), }, ], isError: true, }; }
- src/tool-definitions.ts:150-168 (schema)Tool schema definition including name, description, and input schema requiring 'platform' (web/native) and 'component'.{ name: 'get_component_developer_notes', description: 'Get developer implementation notes for a component. Includes code examples, WCAG mappings, and technical guidance.', inputSchema: { type: 'object', properties: { platform: { type: 'string', enum: ['web', 'native'], description: 'Platform (web or native)', }, component: { type: 'string', description: 'Component name (e.g., "button", "checkbox")', }, }, required: ['platform', 'component'], }, },
- src/index.ts:66-67 (registration)Registration in the MCP CallToolRequestSchema handler switch statement, delegating to the handler function.case 'get_component_developer_notes': return await handleGetComponentDeveloperNotes(args);
- netlify/functions/api.js:60-62 (handler)Inline handler for the Netlify HTTP deployment, simplified version fetching and returning developer notes content.case 'get_component_developer_notes': { const content = await contentLoader.getComponentContent(args.platform, args.component, 'developerNotes'); return { content: [{ type: 'text', text: content }] };
- netlify/functions/api.js:60-62 (registration)Tool registration and inline handling in the Netlify api.js switch for HTTP MCP transport.case 'get_component_developer_notes': { const content = await contentLoader.getComponentContent(args.platform, args.component, 'developerNotes'); return { content: [{ type: 'text', text: content }] };