diff --git a/site/src/index.css b/site/src/index.css index a1e9a15043..c446d9ee07 100644 --- a/site/src/index.css +++ b/site/src/index.css @@ -108,6 +108,33 @@ @apply border-border; } + html, + body, + #root, + #storybook-root { + @apply h-full; + } + + button, + input { + @apply font-sans; + } + + input:-webkit-autofill, + input:-webkit-autofill:hover, + input:-webkit-autofill:focus, + input:-webkit-autofill:active { + -webkit-box-shadow: 0 0 0 100px hsl(var(--surface-primary)) inset !important; + } + + ::placeholder { + @apply text-content-secondary; + } + + fieldset { + @apply border-none p-0 m-0 w-full; + } + /* By default, Radix adds a margin to the `body` element when a dropdown is displayed, causing some shifting when the dropdown has a full-width size, as is the case with the mobile menu. diff --git a/site/src/theme/mui.ts b/site/src/theme/mui.ts index ac6b36a7a8..7fcef9bc1a 100644 --- a/site/src/theme/mui.ts +++ b/site/src/theme/mui.ts @@ -5,46 +5,13 @@ /** @deprecated MUI ThemeOptions is deprecated. Migrate to Tailwind CSS theme system. */ import type { ThemeOptions } from "@mui/material/styles"; -import { - BODY_FONT_FAMILY, - BUTTON_LG_HEIGHT, - BUTTON_MD_HEIGHT, -} from "./constants"; +import { BUTTON_LG_HEIGHT, BUTTON_MD_HEIGHT } from "./constants"; import tw from "./tailwindColors"; // biome-ignore lint/suspicious/noExplicitAny: needed for MUI overrides type MuiStyle = any; export const components = { - MuiCssBaseline: { - styleOverrides: (theme) => ` - html, body, #root, #storybook-root { - height: 100%; - } - - button, input { - font-family: ${BODY_FONT_FAMILY}; - } - - input:-webkit-autofill, - input:-webkit-autofill:hover, - input:-webkit-autofill:focus, - input:-webkit-autofill:active { - -webkit-box-shadow: 0 0 0 100px ${theme.palette.background.default} inset !important; - } - - ::placeholder { - color: ${theme.palette.text.disabled}; - } - - fieldset { - border: unset; - padding: 0; - margin: 0; - width: 100%; - } - `, - }, MuiAvatar: { styleOverrides: { root: {