-
-
Notifications
You must be signed in to change notification settings - Fork 278
v1.2.0 #5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
v1.2.0 #5
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* initial AI commit * initial plan * tweaks in plan * feat: Complete Phase 1 - Transform shadcn/ui to Grafana UI MCP server - Update package metadata and branding for Grafana UI - Migrate GitHub API integration from shadcn-ui/ui to grafana/grafana repository - Create new parser utilities for Grafana UI multi-file component structure: - component-parser.ts: TypeScript analysis and props extraction - story-parser.ts: Storybook story analysis with interactive features detection - mdx-parser.ts: Documentation parsing with accessibility analysis - Enhance caching layer with TTL-based invalidation and Grafana-specific utilities - Update CLI interface with Grafana UI branding - Remove shadcn-specific tools (blocks) not applicable to Grafana UI - Update all existing tools to work with Grafana repository structure - Verify build system and project compilation Phase 1 implementation complete - ready for Phase 2 tool enhancements. * update claude commands * feat: Complete Phase 2 - Implement 6 new Grafana-specific MCP tools ## Phase 2 Implementation Summary This commit completes Phase 2 of the Grafana UI MCP server transformation, adding 6 powerful new tools that provide comprehensive access to Grafana's component ecosystem. ### ✅ New Tools Implemented (6) 1. **get_component_documentation** - Rich MDX documentation parsing - Section extraction with examples and metadata - Accessibility guidelines detection - Usage pattern identification 2. **get_component_stories** - Storybook story analysis - Interactive features detection - Story argument extraction - Example code parsing 3. **get_component_tests** - Test file analysis - Usage pattern extraction from test cases - Test description parsing - Edge case documentation 4. **search_components** - Advanced component search - Fuzzy matching by component name - Optional documentation content search - Relevance scoring and ranking 5. **get_theme_tokens** - Design system integration - Complete theme token extraction - Category filtering (colors, typography, spacing, etc.) - Multi-theme support (light/dark) 6. **get_component_dependencies** - Dependency analysis - Shallow and deep dependency trees - External vs internal dependency categorization - Circular dependency detection ### 🔧 Infrastructure Enhancements - **theme-extractor.ts** (NEW): 774-line comprehensive utility for parsing Grafana design system tokens with support for colors, typography, spacing, shadows, border radius, z-index, and breakpoints - **Enhanced axios.ts**: Added 4 new GitHub API methods with proper error handling and caching integration - **Updated tools.ts**: Added all 6 new tools with MCP server integration, maintaining backward compatibility - **Enhanced handler.ts**: Added Zod validation schemas for all new tools with comprehensive input validation ### 📊 Results - **Total Tools**: 11 (5 existing + 6 new) - **Build Status**: ✅ All TypeScript compilation successful - **Server Status**: ✅ All tools registered and working - **Error Handling**: ✅ Comprehensive McpError integration - **Validation**: ✅ Zod schemas for all tool parameters ### 🚀 Ready for Phase 3 Phase 2 provides complete access to the Grafana UI component ecosystem with: - Rich documentation parsing - Interactive example extraction - Advanced search capabilities - Complete design system integration - Comprehensive dependency analysis The foundation is now ready for Phase 3 (Documentation and Testing). * tweak cli tools * phase-3 plans * another test check * update docs * shelldandy * prettier * removing cheerio * prettier * update prompts * feat: complete Phase 4 - Prompts Migration to Grafana UI - Replace all 5 shadcn/ui prompts with Grafana UI specific prompts - Add comprehensive Grafana UI focused prompt handlers - Implement 4 new helper functions for Grafana-specific instructions - Update all tool references to use available Grafana UI MCP tools - Add observability and monitoring focus throughout all prompts - Enhance optimization instructions with Grafana theming support Phase 4 Summary: - build-grafana-dashboard: monitoring/observability dashboards - create-grafana-form: authentication, settings, configuration forms - optimize-grafana-component: performance/accessibility optimizations - create-data-visualization: tables, charts, visualizations - build-admin-interface: admin interfaces with Grafana patterns All prompts now leverage the full suite of 11 Grafana UI MCP tools and provide comprehensive guidance for AI-assisted Grafana UI development. * feat: complete Phase 5 - Resources Migration to Grafana UI - **Complete Resource Templates Migration** (src/resource-templates.ts): - Replaced shadcn/ui CLI commands with Grafana UI setup scripts - Added get_grafana_ui_setup_script with React + @grafana/ui integration - Added get_component_usage_example with TypeScript support - Created comprehensive setup instructions with ThemeProvider config - **Complete Resources Migration** (src/resources.ts): - Removed hardcoded list of 40+ shadcn/ui components - Added dynamic GitHub API integration with axios.getAvailableComponents() - Added get_grafana_components for real-time component discovery - Added get_grafana_ui_info with comprehensive library information - Enhanced error handling with fallback component lists - **Updated Project Specification** (specs/01-grafana-ui.md): - Documented Phase 5 completion with full implementation details - Added final architecture summary: 11 tools, 2 resources, 2 templates, 5 prompts - Marked project as COMPLETE TRANSFORMATION from shadcn/ui to Grafana UI **Final Architecture:** - 11 fully functional MCP tools - 2 dynamic resources with GitHub API integration - 2 Grafana UI focused resource templates - 5 comprehensive Grafana UI development prompts - 100% migration from shadcn/ui to Grafana UI ecosystem All components now provide comprehensive access to Grafana's component library optimized for observability and monitoring UI development. * prettier * remove unused files * rename plan * point to my npm * update author name * pre-release version * update: migrate test and examples scripts to Grafana UI - Update test-package.sh to test grafana-ui-mcp-server - Update examples.sh with Grafana UI branding and tool descriptions - Remove block-related tools as they don't apply to Grafana UI - Update MCP server names and package references * remove: V4_MIGRATION_SUMMARY.md as it's no longer relevant * ready for publishing
* feat: add support for GITHUB_TOKEN environment variable Add GITHUB_TOKEN as an alternative to GITHUB_PERSONAL_ACCESS_TOKEN for better compatibility with common GitHub workflows and CI/CD environments. - Add GITHUB_TOKEN support in src/index.ts and src/utils/axios.ts - Update documentation across README.md, ASSISTANTS.md, examples.sh, and PUBLISHING.md - Maintain backward compatibility with existing GITHUB_PERSONAL_ACCESS_TOKEN Priority order: --github-api-key flag > GITHUB_PERSONAL_ACCESS_TOKEN > GITHUB_TOKEN * 1.1.0 * badge bump
Add comprehensive Cursor configuration instructions including: - Platform-specific access instructions for settings - Two configuration methods (CLI args and env vars) - Clear JSON examples following existing documentation style - Post-configuration setup instructions
* plan * feat: consolidate 11 tools into unified grafana_ui tool - Replace 11 individual MCP tools with single configurable tool - Add action parameter to determine operation (get_component, get_demo, etc.) - Implement comprehensive parameter validation based on action type - Maintain all existing functionality through action-based routing - Simplify MCP client configuration from 11 tools to 1 - Reduce cognitive overhead for AI agents - Add specification document for tool consolidation BREAKING CHANGE: Individual tool names replaced with single grafana_ui tool All functionality preserved through action parameter * docs: update README to reflect unified tool interface - Document new grafana_ui tool with action-based routing - Update all usage examples to use unified tool syntax - Add migration guide for breaking changes from v1.x - Highlight benefits of unified tool approach - Update troubleshooting section with new tool name - Maintain all existing functionality documentation * style: apply linter formatting fixes * refactor: update prompts and CLI help to use unified tool interface - Update all prompt instructions to use 'grafana_ui' tool with action parameters - Replace old tool names (get_component, list_components, etc.) with unified syntax - Update CLI help text to reflect new unified tool interface - Add usage examples showing action-based routing - Maintain all existing functionality through new interface * prettier
* add the plan * feat: add local Grafana repository support Add --grafana-repo-path option to enable direct filesystem access to local Grafana repositories, providing faster development workflows and offline support. Key Features: • CLI option: --grafana-repo-path / -l for local repository path • Environment variable: GRAFANA_REPO_PATH support • Precedence: Local repo → GitHub API key → Unauthenticated GitHub • Graceful fallback to GitHub API when local files missing • All 11 MCP tools support both local and remote sources • Source indication in responses (local vs github) Benefits: • ⚡ Faster access via direct filesystem reads • 🚫 No rate limits for unlimited component access • 🔄 Real-time updates for local changes • 📡 Offline support without internet dependency • 🧪 Development workflow for uncommitted changes Files: • src/index.ts - CLI argument parsing and configuration • src/utils/axios.ts - Filesystem support for all functions • README.md - Local development documentation Maintains full backward compatibility while enabling powerful local development capabilities.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the pr,it's now under review
Author
|
My bad! I need to detach my fork to prevent this from happening again |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
bump version