Repository navigation
Adopt Oxc lint and format tooling for MCP and root #1419
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
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
f1b62db
fix(cli): Regenerate skill versions for 0.48.0
BYK 8671ccc
chore(lint): Adopt Oxc for MCP and root files
BYK 4fb792a
fix(cli): Sync skill versions after releases
BYK d39c63b
Merge branch 'fix/cli-skill-version' of https://github.com/getsentry/…
BYK 6570087
fix(lint): Preserve Oxc rules and editor formatting
BYK d88febb
chore(lint): Merge latest Toolkit main
BYK c024ba6
fix(lint): Document intentional token padding regex
BYK d944a44
fix(ui): Restart terminal animation from keyboard
BYK fb8e2f7
Merge remote-tracking branch 'origin/main' into chore/oxlint-oxfmt
BYK File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| { | ||
| "$schema": "./node_modules/oxfmt/configuration_schema.json", | ||
| "printWidth": 80, | ||
| "tabWidth": 2, | ||
| "sortPackageJson": false, | ||
| "ignorePatterns": [ | ||
| "apps/cli-docs/**", | ||
| "packages/cli/**", | ||
| "packages/mcp-server-mocks/src/fixtures/**", | ||
| "**/worker-configuration.d.ts", | ||
| "**/tsconfig*.json" | ||
| ] | ||
| } |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| { | ||
| "$schema": "./node_modules/oxlint/configuration_schema.json", | ||
| "plugins": ["eslint", "typescript", "unicorn", "oxc", "jsx-a11y"], | ||
| "categories": { | ||
| "correctness": "error" | ||
| }, | ||
| "ignorePatterns": [ | ||
| "apps/cli-docs/**", | ||
| "packages/cli/**", | ||
| "**/worker-configuration.d.ts", | ||
| "**/tsconfig*.json", | ||
| "packages/mcp-server-mocks/src/fixtures/**" | ||
| ], | ||
| "rules": { | ||
| "no-unused-vars": "off", | ||
| "jsx-a11y/interactive-supports-focus": "off" | ||
| }, | ||
| "overrides": [ | ||
| { | ||
| "files": ["packages/mcp-cloudflare/src/client/**/*.tsx"], | ||
| "rules": { | ||
| "jsx-a11y/no-static-element-interactions": "off" | ||
| } | ||
| } | ||
| ] | ||
| } |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| { | ||
| "recommendations": ["biomejs.biome"], | ||
| "recommendations": ["oxc.oxc-vscode", "biomejs.biome"], | ||
| "unwantedRecommendations": [] | ||
| } | ||
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,21 +1,18 @@ | ||
| { | ||
| "editor.defaultFormatter": "oxc.oxc-vscode", | ||
| "editor.formatOnSave": true, | ||
| "editor.formatOnSaveMode": "file", | ||
| "editor.codeActionsOnSave": { | ||
| "source.fixAll.biome": "explicit" | ||
| "source.fixAll.oxc": "explicit" | ||
| }, | ||
| "files.trimTrailingWhitespace": false, | ||
| "files.trimFinalNewlines": false, | ||
| "files.insertFinalNewline": true, | ||
| "cursor.general.enableShadowWorkspace": true, | ||
| "[json]": { | ||
| "editor.tabSize": 2, | ||
| "editor.defaultFormatter": "biomejs.biome" | ||
| "editor.tabSize": 2 | ||
| }, | ||
| "[typescript]": { | ||
| "editor.tabSize": 2, | ||
| "editor.defaultFormatter": "biomejs.biome" | ||
| }, | ||
| "[typescriptreact]": { | ||
| "editor.defaultFormatter": "biomejs.biome" | ||
| "editor.tabSize": 2 | ||
| } | ||
| } |
This file was deleted.
Oops, something went wrong.
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
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
44 changes: 44 additions & 0 deletions
44
packages/mcp-cloudflare/src/client/components/animation/terminal-ui/StepsList.test.ts
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| import { | ||
| Children, | ||
| isValidElement, | ||
| type KeyboardEvent, | ||
| type KeyboardEventHandler, | ||
| } from "react"; | ||
| import { describe, expect, it, vi } from "vitest"; | ||
| import StepsList from "./StepsList"; | ||
|
|
||
| const steps = Array.from({ length: 6 }, (_, index) => ({ | ||
| label: `Step ${index}`, | ||
| description: "", | ||
| startTime: 0, | ||
| pauseMs: null, | ||
| })); | ||
|
|
||
| describe("StepsList keyboard navigation", () => { | ||
| it.each(["Enter", " "])("restarts from the final step with %j", (key) => { | ||
| const restart = vi.fn(); | ||
| const onSelectAction = vi.fn(); | ||
| const element = StepsList({ | ||
| steps, | ||
| globalIndex: steps.length - 1, | ||
| onSelectAction, | ||
| restart, | ||
| }); | ||
| const button = Children.toArray(element.props.children).find( | ||
| (child) => isValidElement(child) && child.type === "button", | ||
| ); | ||
| if (!isValidElement<{ onKeyDown: KeyboardEventHandler }>(button)) { | ||
| throw new Error("Step navigation button is missing"); | ||
| } | ||
|
|
||
| const preventDefault = vi.fn(); | ||
| button.props.onKeyDown({ | ||
| key, | ||
| preventDefault, | ||
| } as unknown as KeyboardEvent<HTMLButtonElement>); | ||
|
|
||
| expect(preventDefault).toHaveBeenCalledOnce(); | ||
| expect(restart).toHaveBeenCalledOnce(); | ||
| expect(onSelectAction).not.toHaveBeenCalled(); | ||
| }); | ||
| }); |
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.