mirror of
https://github.com/coder/coder.git
synced 2026-10-16 14:48:56 +08:00
> 🤖 This PR was modified by Coder Agents on behalf of Jake Howell. Until we meet again. ## Stack - #27636 - #27718 - #27719 - #27722 - #27723 - #27724 - #27728 - #27730 - #27732 - #27762 - #27763 - #27786 - #27787 - #27788 - #27789 - #27790 - #27791 - #27817 - #27820 - #28009 ## Final removal (`c39b664`) Removes the last of MUI and Emotion now that every surface has been migrated: - **Dependencies**: drops `@mui/material` and `@emotion/{cache,css,react,styled}` from `package.json` / `pnpm-lock.yaml`, and deletes the `@types/emotion.d.ts` and `@types/mui.d.ts` module augmentations. - **Theming**: replaces the Emotion `CacheProvider`, MUI `ThemeProvider` / `StyledEngineProvider`, and `CssBaseline` in `ThemeProvider` with a lightweight `theme/context.tsx` that exposes `ThemeContextProvider` and a `useTheme` hook. - **Global styles**: moves the base `body` styles (background, text color, font, antialiasing) that `CssBaseline` previously provided into `index.css`, and drops the temporary MUI modal/popover scrollbar-gutter workaround. - **Cleanup**: removes the MUI → shadcn / Emotion → Tailwind migration guidance from `site/AGENTS.md`, updates the Storybook `preview.tsx`, and adjusts assorted components (`Command`, `Slider`, `Switch`, `Tabs`, `SyntaxHighlighter`, timing charts) and theme files to consume the new context instead of MUI/Emotion.
79 lines
2.5 KiB
JSON
79 lines
2.5 KiB
JSON
{
|
|
"emeraldwalk.runonsave": {
|
|
"commands": [
|
|
{
|
|
"match": "database/queries/*.sql",
|
|
"cmd": "make gen"
|
|
},
|
|
{
|
|
"match": "provisionerd/proto/provisionerd.proto",
|
|
"cmd": "make provisionerd/proto/provisionerd.pb.go"
|
|
}
|
|
]
|
|
},
|
|
"search.exclude": {
|
|
"**.pb.go": true,
|
|
"**/*.gen.json": true,
|
|
"**/testdata/*": true,
|
|
"coderd/apidoc/**": true,
|
|
"docs/reference/api/*.md": true,
|
|
"docs/reference/cli/*.md": true,
|
|
"docs/templates/*.md": true,
|
|
"LICENSE": true,
|
|
"scripts/metricsdocgen/metrics": true,
|
|
"site/out/**": true,
|
|
"site/storybook-static/**": true,
|
|
"**.map": true,
|
|
"pnpm-lock.yaml": true
|
|
},
|
|
// Ensure files always have a newline.
|
|
"files.insertFinalNewline": true,
|
|
"go.lintTool": "golangci-lint",
|
|
"go.lintFlags": ["--fast"],
|
|
"go.coverageDecorator": {
|
|
"type": "gutter",
|
|
"coveredGutterStyle": "blockgreen",
|
|
"uncoveredGutterStyle": "blockred"
|
|
},
|
|
// The codersdk is used by coderd another other packages extensively.
|
|
// To reduce redundancy in tests, it's covered by other packages.
|
|
// Since package coverage pairing can't be defined, all packages cover
|
|
// all other packages.
|
|
"go.testFlags": ["-short", "-coverpkg=./..."],
|
|
// We often use a version of TypeScript that's ahead of the version shipped
|
|
// with VS Code.
|
|
"typescript.tsdk": "./site/node_modules/typescript/lib",
|
|
// Playwright tests in VSCode will open a browser to live "view" the test.
|
|
"playwright.reuseBrowser": true,
|
|
|
|
"[javascript][javascriptreact][json][jsonc][typescript][typescriptreact]": {
|
|
"editor.defaultFormatter": "biomejs.biome",
|
|
"editor.codeActionsOnSave": {
|
|
"source.fixAll.biome": "explicit"
|
|
// "source.organizeImports.biome": "explicit"
|
|
}
|
|
},
|
|
|
|
"tailwindCSS.classFunctions": ["cva", "cn"],
|
|
"[css][html][markdown][yaml]": {
|
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
|
},
|
|
"typos.config": ".github/workflows/typos.toml",
|
|
"[markdown]": {
|
|
"editor.defaultFormatter": "DavidAnson.vscode-markdownlint"
|
|
},
|
|
"biome.lsp.bin": "site/node_modules/.bin/biome",
|
|
|
|
// Prefer type only imports.
|
|
"typescript.preferences.preferTypeOnlyAutoImports": true,
|
|
// Prefer aliased/non-relative imports (e.g. "#/...") over "../../...".
|
|
"typescript.preferences.importModuleSpecifier": "non-relative",
|
|
"javascript.preferences.importModuleSpecifier": "non-relative",
|
|
// We discourage people from various older libraries that
|
|
// are no longer recommended/being migrated from.
|
|
"typescript.preferences.autoImportSpecifierExcludeRegexes": [
|
|
// we prefer people use `lodash/foo` over `lodash`
|
|
"^lodash$"
|
|
]
|
|
}
|