mirror of
https://github.com/supabase/supabase.git
synced 2026-05-06 08:56:46 -04:00
070316cb87
This pull request migrates all SCSS stylesheets in the `apps/studio` and
`apps/docs` projects to CSS, updates import paths accordingly, and
consolidates PostCSS configuration to use a shared config. The migration
includes renaming files, updating import statements, converting SCSS
comments to CSS comments, and removing redundant or legacy configuration
files. The changes improve maintainability and consistency across the
codebase.
**Migration from SCSS to CSS:**
* All SCSS stylesheets in `apps/studio/styles` and `apps/docs/styles`
have been renamed to `.css`, and their contents updated by converting
SCSS comments (`// ...`) to CSS comments (`/* ... */`). All relevant
import statements in the app entry points have been updated to reference
the new `.css` files.
**PostCSS configuration consolidation:**
* The separate `postcss.config.cjs` files in `apps/design-system`,
`apps/learn`, and `apps/studio` now all import from a shared
`config/postcss.config`, ensuring consistent PostCSS setup across
projects. The legacy `postcss.config.js` in `apps/studio` has been
removed.
**Code and style consistency improvements:**
* All instances of the SCSS-specific `#{!important}` in Tailwind
`@apply` rules have been replaced with the standard CSS `!important`
syntax.
* Minor fixes and comment updates were made throughout the stylesheets
to improve readability and maintainability, such as moving or clarifying
TODOs and notes.
These changes streamline the styling approach, reduce build complexity,
and make it easier to maintain and scale the design system and
documentation styles.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **Refactor**
* Consolidated PostCSS configuration across apps
* Migrated many stylesheet imports from SCSS to CSS
* Standardized CSS comment and @apply syntax for consistency
* **Chores**
* Removed SCSS (sass) dev dependency
* Added autoprefixer and tailwindcss/nesting to PostCSS plugins
* Removed SCSS module type declarations (cleaned up typings)
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
299 lines
6.4 KiB
CSS
299 lines
6.4 KiB
CSS
@import './../../../packages/ui/build/css/source/global.css';
|
|
@import './../../../packages/ui/build/css/themes/dark.css';
|
|
@import './../../../packages/ui/build/css/themes/light.css';
|
|
@import './../../../packages/ui/build/css/themes/classic-dark.css';
|
|
|
|
@tailwind components;
|
|
|
|
:root {
|
|
--chart-1: var(--brand-default);
|
|
--chart-2: 173 58% 39%;
|
|
--chart-3: 197 37% 24%;
|
|
--chart-4: 43 74% 66%;
|
|
--chart-5: 27 87% 67%;
|
|
--chart-blue: 217 91% 60%;
|
|
--chart-warning: hsl(var(--warning-default));
|
|
--chart-destructive: hsl(var(--destructive-default));
|
|
--sidebar-background: var(--background-dash-sidebar);
|
|
--sidebar-foreground: var(--foreground-default);
|
|
--sidebar-primary: var(--foreground-default);
|
|
--sidebar-primary-foreground: var(--warning-default);
|
|
--sidebar-accent: var(--background-selection);
|
|
--sidebar-accent-foreground: var(--foreground-default);
|
|
--sidebar-border: var(--border-default);
|
|
--sidebar-ring: 217.2 91.2% 59.8%;
|
|
--header-height: 3rem;
|
|
}
|
|
|
|
[data-theme='deep-dark'],
|
|
.deep-dark,
|
|
[data-theme='dark'],
|
|
.dark {
|
|
--chart-1: var(--brand-default);
|
|
--chart-2: 160 60% 45%;
|
|
--chart-3: 30 80% 55%;
|
|
--chart-4: 280 65% 60%;
|
|
--chart-5: 340 75% 55%;
|
|
--chart-blue: 217 91% 65%;
|
|
--chart-warning: hsl(var(--warning-default));
|
|
--chart-destructive: hsl(var(--destructive-default));
|
|
--sidebar-background: var(--background-dash-sidebar);
|
|
--sidebar-foreground: var(--foreground-default);
|
|
--sidebar-primary: var(--foreground-default);
|
|
--sidebar-primary-foreground: var(--warning-default);
|
|
--sidebar-accent: var(--background-selection);
|
|
--sidebar-accent-foreground: var(--foreground-default);
|
|
--sidebar-border: var(--border-default);
|
|
--sidebar-ring: 217.2 91.2% 59.8%;
|
|
}
|
|
|
|
html,
|
|
body,
|
|
#__next,
|
|
.main {
|
|
@apply bg-dash-sidebar relative;
|
|
@apply text-foreground;
|
|
@apply overflow-x-clip;
|
|
-moz-osx-font-smoothing: grayscale;
|
|
-webkit-font-smoothing: antialiased;
|
|
overscroll-behavior: none;
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.form-group .form-text,
|
|
.Form .form-text {
|
|
@apply text-foreground-lighter;
|
|
}
|
|
|
|
.form-group input,
|
|
.form-group input[type='text'],
|
|
.form-group input[type='email'],
|
|
.form-group input[type='url'],
|
|
.form-group input[type='password'],
|
|
.form-group input[type='number'],
|
|
.form-group input[type='date'],
|
|
.form-group input[type='datetime-local'],
|
|
.form-group input[type='month'],
|
|
.form-group input[type='search'],
|
|
.form-group input[type='tel'],
|
|
.form-group input[type='time'],
|
|
.form-group input[type='week'],
|
|
.form-group input[multiple],
|
|
.form-group textarea,
|
|
.form-group select,
|
|
input.form-control,
|
|
.form-control input,
|
|
.form-control textarea {
|
|
@apply block;
|
|
@apply box-border;
|
|
/* @apply w-full ; */
|
|
@apply rounded-md;
|
|
@apply shadow-sm;
|
|
@apply transition-all;
|
|
@apply text-foreground;
|
|
@apply border;
|
|
@apply focus:shadow-md;
|
|
|
|
@apply focus:border-stronger;
|
|
@apply focus:ring-border-overlay;
|
|
|
|
@apply bg-studio;
|
|
@apply border-strong border;
|
|
|
|
@apply outline-none;
|
|
@apply focus:ring-2 focus:ring-current;
|
|
}
|
|
|
|
.form-group input,
|
|
.form-group select,
|
|
.form-group textarea {
|
|
@apply px-4 py-2;
|
|
}
|
|
|
|
.form-group input:focus,
|
|
.form-group input[type='text']:focus,
|
|
.form-group input[type='email']:focus,
|
|
.form-group input[type='url']:focus,
|
|
.form-group input[type='password']:focus,
|
|
.form-group input[type='number']:focus,
|
|
.form-group input[type='date']:focus,
|
|
.form-group input[type='datetime-local']:focus,
|
|
.form-group input[type='month']:focus,
|
|
.form-group input[type='search']:focus,
|
|
.form-group input[type='tel']:focus,
|
|
.form-group input[type='time']:focus,
|
|
.form-group input[type='week']:focus,
|
|
.form-group input[multiple]:focus,
|
|
.form-group textarea:focus,
|
|
.form-group select:focus,
|
|
.form-group input:focus .form-control:focus {
|
|
box-shadow: 0 0 0 2px rgba(62, 207, 142, 0.1);
|
|
}
|
|
|
|
/* icons in date / time inputs */
|
|
.dark input[type='date']::-webkit-calendar-picker-indicator,
|
|
.dark input[type='datetime-local']::-webkit-calendar-picker-indicator,
|
|
.dark input[type='time']::-webkit-calendar-picker-indicator {
|
|
filter: invert(0.8);
|
|
}
|
|
|
|
input.is-invalid {
|
|
@apply bg-red-100;
|
|
@apply border border-red-700;
|
|
@apply focus:ring-red-500;
|
|
@apply placeholder:text-red-600;
|
|
}
|
|
|
|
input::placeholder {
|
|
@apply text-foreground-lighter;
|
|
}
|
|
|
|
.form-group input::placeholder {
|
|
@apply text-foreground-lighter;
|
|
}
|
|
|
|
.billing-input-fixed {
|
|
@apply w-full appearance-none rounded border bg-gray-700 py-2 px-3 leading-tight text-gray-300 shadow;
|
|
}
|
|
|
|
a {
|
|
color: inherit;
|
|
text-decoration: none;
|
|
}
|
|
|
|
.input-mono {
|
|
input,
|
|
textarea {
|
|
@apply font-mono;
|
|
}
|
|
}
|
|
|
|
.input-sm {
|
|
input,
|
|
textarea {
|
|
@apply text-sm;
|
|
}
|
|
}
|
|
|
|
.input-xs {
|
|
input,
|
|
textarea {
|
|
@apply text-xs;
|
|
}
|
|
}
|
|
|
|
input[type='radio'] {
|
|
@apply p-0;
|
|
}
|
|
|
|
input[type='number'] {
|
|
-moz-appearance: textfield; /* Firefox, Not included in tailwind styles reset */
|
|
}
|
|
|
|
/* TODO: It doesnt' work, need to check */
|
|
.hide-scrollbar {
|
|
scrollbar-width: none; /* Firefox */
|
|
-ms-overflow-style: none; /* Internet Explorer 10+ */
|
|
}
|
|
|
|
.hide-scrollbar::-webkit-scrollbar {
|
|
width: 0;
|
|
height: 0;
|
|
display: none;
|
|
}
|
|
|
|
div[data-radix-portal]:not(.portal--toast) {
|
|
z-index: 2147483646 !important;
|
|
}
|
|
|
|
.billing-compute-radio {
|
|
label {
|
|
@apply items-center justify-between;
|
|
&:last-child {
|
|
opacity: 100 !important;
|
|
}
|
|
}
|
|
}
|
|
|
|
.recharts-tooltip-cursor {
|
|
@apply fill-transparent;
|
|
}
|
|
|
|
.expandable-tr {
|
|
display: grid;
|
|
grid-template-columns: repeat(5, 1fr);
|
|
}
|
|
|
|
.expanded-row-content {
|
|
display: grid;
|
|
grid-column: 1/-1;
|
|
justify-content: flex-start;
|
|
}
|
|
|
|
.multi-select {
|
|
button {
|
|
display: block;
|
|
width: 100%;
|
|
}
|
|
}
|
|
|
|
@media (prefers-color-scheme: dark) {
|
|
html {
|
|
color-scheme: dark;
|
|
}
|
|
}
|
|
|
|
.text-area-resize-none {
|
|
textarea {
|
|
@apply resize-none;
|
|
}
|
|
}
|
|
|
|
.capitalize-sentence:first-letter {
|
|
text-transform: capitalize;
|
|
}
|
|
|
|
.input-clear {
|
|
input {
|
|
@apply pr-7;
|
|
}
|
|
}
|
|
|
|
/* to do: remove this CSS and do the same thing in a reusable tooltip component */
|
|
[data-radix-popper-content-wrapper] {
|
|
@apply z-50 !important;
|
|
}
|
|
|
|
.settings-container {
|
|
@apply mx-auto max-w-4xl xl:max-w-6xl;
|
|
}
|
|
|
|
.react-grid-item.react-grid-placeholder {
|
|
@apply bg-brand-500 !important;
|
|
}
|
|
|
|
.react-grid-item > .react-resizable-handle::after {
|
|
content: '';
|
|
position: absolute;
|
|
right: 3px !important;
|
|
bottom: 3px !important;
|
|
width: 6px !important;
|
|
height: 6px !important;
|
|
@apply border-strong dark:border-r-2 dark:border-b-2 dark:border-overlay !important;
|
|
}
|
|
|
|
@keyframes typewriter {
|
|
from {
|
|
width: 0;
|
|
}
|
|
}
|
|
|
|
@keyframes blink-caret {
|
|
50% {
|
|
border-color: transparent;
|
|
}
|
|
}
|