message / frontend /src /index.css
hunian
feat: 重构前端控制台和工具页面
a43ac26
Raw
History Blame Contribute Delete
3.75 kB
@tailwind base;
@tailwind components;
@tailwind utilities;
@layer base {
:root {
--background: 0 0% 100%;
--foreground: 222.2 84% 4.9%;
--card: 0 0% 100%;
--card-foreground: 222.2 84% 4.9%;
--popover: 0 0% 100%;
--popover-foreground: 222.2 84% 4.9%;
--primary: 222.2 47.4% 11.2%;
--primary-foreground: 210 40% 98%;
--secondary: 210 40% 96.1%;
--secondary-foreground: 222.2 47.4% 11.2%;
--muted: 210 40% 96.1%;
--muted-foreground: 215.4 16.3% 46.9%;
--accent: 210 40% 96.1%;
--accent-foreground: 222.2 47.4% 11.2%;
--destructive: 0 84.2% 60.2%;
--destructive-foreground: 210 40% 98%;
--border: 214.3 31.8% 91.4%;
--input: 214.3 31.8% 91.4%;
--ring: 222.2 84% 4.9%;
--radius: 0.5rem;
}
.dark {
--background: 222.2 84% 4.9%;
--foreground: 210 40% 98%;
--card: 222.2 84% 4.9%;
--card-foreground: 210 40% 98%;
--popover: 222.2 84% 4.9%;
--popover-foreground: 210 40% 98%;
--primary: 210 40% 98%;
--primary-foreground: 222.2 47.4% 11.2%;
--secondary: 217.2 32.6% 17.5%;
--secondary-foreground: 210 40% 98%;
--muted: 217.2 32.6% 17.5%;
--muted-foreground: 215 20.2% 65.1%;
--accent: 217.2 32.6% 17.5%;
--accent-foreground: 210 40% 98%;
--destructive: 0 62.8% 30.6%;
--destructive-foreground: 210 40% 98%;
--border: 217.2 32.6% 17.5%;
--input: 217.2 32.6% 17.5%;
--ring: 212.7 26.8% 83.9%;
}
}
@layer base {
* {
@apply border-border;
}
body {
@apply bg-background text-foreground;
font-family: 'Inter', sans-serif;
}
}
/* 控制台语义 token */
@layer base {
:root {
/* 表面层级:控制台页面使用更紧凑的表面层次 */
--console-surface-base: 0 0% 100%;
--console-surface-raised: 210 40% 98%;
--console-surface-overlay: 0 0% 100%;
/* 文本强弱:控制台使用更紧凑的文本层级 */
--console-text-primary: 222.2 84% 4.9%;
--console-text-secondary: 215.4 16.3% 46.9%;
--console-text-muted: 215 20.2% 65.1%;
/* 边框:控制台使用细边框分隔信息 */
--console-border: 214.3 31.8% 91.4%;
--console-border-strong: 214.3 31.8% 80%;
/* 状态色 */
--console-status-enabled: 142 76% 36%;
--console-status-enabled-bg: 142 76% 96%;
--console-status-disabled: 0 0% 60%;
--console-status-disabled-bg: 0 0% 96%;
--console-status-error: 0 84% 60%;
--console-status-error-bg: 0 84% 96%;
--console-status-warning: 38 92% 50%;
--console-status-warning-bg: 38 92% 96%;
--console-status-info: 221 83% 53%;
--console-status-info-bg: 221 83% 96%;
/* 密度间距 */
--console-gap-xs: 0.25rem;
--console-gap-sm: 0.5rem;
--console-gap-md: 0.75rem;
--console-gap-lg: 1rem;
--console-gap-xl: 1.5rem;
/* 圆角:控制台使用小圆角 */
--console-radius-sm: 4px;
--console-radius-md: 6px;
--console-radius-lg: 8px;
}
.dark {
--console-surface-base: 222.2 84% 4.9%;
--console-surface-raised: 217.2 32.6% 12%;
--console-surface-overlay: 222.2 84% 6%;
--console-text-primary: 210 40% 98%;
--console-text-secondary: 215 20.2% 65.1%;
--console-text-muted: 215 20.2% 50%;
--console-border: 217.2 32.6% 17.5%;
--console-border-strong: 217.2 32.6% 25%;
--console-status-enabled: 142 76% 50%;
--console-status-enabled-bg: 142 76% 15%;
--console-status-disabled: 0 0% 50%;
--console-status-disabled-bg: 0 0% 15%;
--console-status-error: 0 84% 60%;
--console-status-error-bg: 0 84% 15%;
--console-status-warning: 38 92% 50%;
--console-status-warning-bg: 38 92% 15%;
--console-status-info: 221 83% 53%;
--console-status-info-bg: 221 83% 15%;
}
}