Conversation
# Conflicts: # src/index.ts # src/tools/replace-hard-coded-values-tool.ts
There was a problem hiding this comment.
Pull request overview
This PR refactors the remaining standalone tool functions into class-based implementations, following the established Tool class pattern. The changes extract 6 tools (validate, theme-generator, accessibility/check-contrast, migration, scaffold, and sticker-sheet) from function-based modules into class-based tool implementations with external markdown template files.
Changes:
- Migrated 6 remaining tool functions to class-based Tool implementations
- Introduced markdown template files for tool output formatting
- Added
readToolFilehelper function to load markdown templates - Updated index.ts to use new tool class instances instead of inline tool registrations
Reviewed changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/tools/validate.ts | Deleted - functionality moved to validate-token-usage-tool.ts |
| src/tools/theme-generator.ts | Deleted - functionality moved to generate-theme-tool.ts |
| src/tools/migration.ts | Deleted - functionality moved to suggest-token-migration-tool.ts |
| src/tools/scaffold.ts | Deleted - functionality moved to generate-component-scaffold-tool.ts |
| src/tools/accessibility.ts | Deleted - functionality moved to check-contrast-tool.ts |
| src/tools/sticker-sheet.ts | Deleted - functionality moved to generate-sticker-sheet-tool.ts (note: file doesn't exist in diff but referenced in PR) |
| src/tools/validate-token-usage-tool.ts | New class-based implementation with markdown templates |
| src/tools/generate-theme-tool.ts | New class-based implementation with markdown templates |
| src/tools/suggest-token-migration-tool.ts | New class-based implementation with markdown templates |
| src/tools/generate-component-scaffold-tool.ts | New class-based implementation with markdown templates |
| src/tools/check-contrast-tool.ts | New class-based implementation with markdown templates |
| src/tools/generate-sticker-sheet-tool.ts | Refactored to class-based implementation, simplified framework handling |
| src/tools/*.md (9 files) | New markdown template files for tool output formatting |
| src/tools/replace-hard-coded-values-tool.ts | Updated import to include ToolInputSchema type |
| src/index.ts | Removed inline tool registrations, updated to use new tool class instances |
| src/_internal/resource-path.ts | Added readToolFile helper function |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Jeremy-Walton
approved these changes
Feb 5, 2026
dallasbpeters
pushed a commit
that referenced
this pull request
Feb 6, 2026
* Create read tool file method * extract the theme generator * Finish tool class extractions * Extract md files * specifiy import type * update type * removed unused parameter * removed useless variable stuff
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
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.
Why?
Extract Remaining tools into classes.
What Changed