Dark Mode
暗黑模式
stylekitMITProfessional · professionalLight and dark · bothMedium · mediumBlue · blueVivid · vividSerif · serifGeneral · generalLanding · landing
优雅的深色界面设计,低对比度层次、微妙的边框和高亮。适合开发工具、专业应用、深夜阅读模式。
NNorthwind
Product · PricingSpecimen
Make the work feel finished
One interface, dressed in this style. Compare type, color, radius, and density.
128
Active
4.8
Score
12ms
Edge
Attribution
"Dark Mode" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86.
https://github.com/AnxForever/stylekit · api/styles/dark-mode · bfa7da909e86 · © AnxForever
Do
- 使用深色背景 bg-slate-900, bg-gray-900, bg-[#0f172a]
- 卡片使用略浅的背景 bg-slate-800/50,hover 时提亮 hover:bg-slate-800
- 边框使用低对比度 border-slate-700,hover 时照亮 hover:border-slate-500
- 文字使用 text-slate-100 主要, text-slate-400 次要,group-hover 时次要文字提亮 group-hover:text-slate-300
- 高亮色保持高饱和度 blue-500, green-500
- 按钮使用内发光 shadow-[inset_0_1px_0_rgba(255,255,255,0.15)] 模拟暗色光源
- 按钮必须有 active:scale-[0.98] 触觉按压确认
- 所有可交互元素必须有 focus:ring-2 focus:ring-offset-2 focus:ring-offset-slate-900
Don't
- 禁止使用纯白文字 text-white(过于刺眼)
- 禁止使用高对比度边框
- 禁止使用纯黑背景 #000000(过于沉闷)
- 禁止在深色背景上使用深色文字
- 禁止高亮色使用过多
- 禁止阴影使用浅色(深色背景上用浅色阴影无法体现层次)
- 禁止按钮缺少 active:scale-[0.98](按钮需要触觉确认,否则如同装饰)
- 禁止 focus:ring 缺少 focus:ring-offset-slate-900(暗色背景上焦点环必须与元素分离才可见)
Prompt
Create a developer dashboard using Dark Mode style: - Sidebar navigation with slate-800 background - Main content on slate-900 - Metric cards with subtle borders - Code blocks with syntax highlighting - Status indicators with colored dots - Blue accent for primary actions - Comfortable contrast for long sessions --- "Dark Mode" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86. powered by Styledex — https://styledex.dev
Tokens
DTCG
{
"$schema": "https://www.designtokens.org/schemas/2025.10/format.json",
"$description": "Dark Mode. \"Dark Mode\" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86.",
"$extensions": {
"dev.styledex": {
"id": "stylekit-dark-mode",
"license": "MIT",
"attribution": "\"Dark Mode\" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86.",
"banner": "powered by Styledex — https://styledex.dev"
}
},
"color": {
"background": {
"$type": "color",
"$value": "#0f172a"
},
"foreground": {
"$type": "color",
"$value": "#f1f5f9"
},
"card": {
"$type": "color",
"$value": "#0f172a"
},
"card-foreground": {
"$type": "color",
"$value": "#f1f5f9"
},
"primary": {
"$type": "color",
"$value": "#3b82f6"
},
"primary-foreground": {
"$type": "color",
"$value": "#fafaf9"
},
"secondary": {
"$type": "color",
"$value": "#0f172a"
},
"secondary-foreground": {
"$type": "color",
"$value": "#f1f5f9"
},
"accent": {
"$type": "color",
"$value": "#22c55e"
},
"accent-foreground": {
"$type": "color",
"$value": "#fafaf9"
},
"muted": {
"$type": "color",
"$value": "#1d2537"
},
"muted-foreground": {
"$type": "color",
"$value": "#9d9fa2"
},
"border": {
"$type": "color",
"$value": "#313748"
},
"destructive": {
"$type": "color",
"$value": "#dc2626"
},
"ring": {
"$type": "color",
"$value": "#3b82f6"
}
},
"font": {
"sans": {
"$type": "fontFamily",
"$value": [
"ui-sans-serif",
"system-ui",
"sans-serif"
]
},
"serif": {
"$type": "fontFamily",
"$value": [
"ui-serif",
"Georgia",
"serif"
]
},
"mono": {
"$type": "fontFamily",
"$value": [
"ui-monospace",
"SFMono-Regular",
"Menlo",
"monospace"
]
}
},
"radius": {
"base": {
"$type": "dimension",
"$value": "0.5rem"
}
},
"spacing": {
"base": {
"$type": "dimension",
"$value": "1rem"
}
},
"shadow": {
"base": {
"$type": "shadow",
"$value": "0 1px 2px rgba(0,0,0,0.06), 0 8px 24px rgba(0,0,0,0.04)"
}
}
}
CSS
/* powered by Styledex — https://styledex.dev */
/* "Dark Mode" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86. */
:root {
--background: #0f172a;
--foreground: #f1f5f9;
--card: #0f172a;
--card-foreground: #f1f5f9;
--primary: #3b82f6;
--primary-foreground: #fafaf9;
--secondary: #0f172a;
--secondary-foreground: #f1f5f9;
--accent: #22c55e;
--accent-foreground: #fafaf9;
--muted: #1d2537;
--muted-foreground: #9d9fa2;
--border: #313748;
--destructive: #dc2626;
--ring: #3b82f6;
--radius: 0.5rem;
--font-sans: ui-sans-serif, system-ui, sans-serif;
--font-serif: ui-serif, Georgia, serif;
--font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
--spacing: 1rem;
--shadow: 0 1px 2px rgba(0,0,0,0.06), 0 8px 24px rgba(0,0,0,0.04);
}
Tailwind
/* powered by Styledex — https://styledex.dev */
/* "Dark Mode" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86. */
/** Tailwind theme extend for Dark Mode (stylekit-dark-mode) */
module.exports = {
"theme": {
"extend": {
"colors": {
"background": "#0f172a",
"foreground": "#f1f5f9",
"card": "#0f172a",
"primary": "#3b82f6",
"primary-foreground": "#fafaf9",
"secondary": "#0f172a",
"accent": "#22c55e",
"muted": "#1d2537",
"border": "#313748",
"destructive": "#dc2626",
"ring": "#3b82f6"
},
"borderRadius": {
"lg": "0.5rem"
},
"fontFamily": {
"sans": [
"ui-sans-serif",
"system-ui",
"sans-serif"
],
"serif": [
"ui-serif",
"Georgia",
"serif"
],
"mono": [
"ui-monospace",
"SFMono-Regular",
"Menlo",
"monospace"
]
},
"boxShadow": {
"styledex": "0 1px 2px rgba(0,0,0,0.06), 0 8px 24px rgba(0,0,0,0.04)"
}
}
}
};
shadcn
/* powered by Styledex — https://styledex.dev */
/* "Dark Mode" from https://github.com/AnxForever/stylekit (MIT). © AnxForever. api/styles/dark-mode @ bfa7da909e86. */
@layer base {
:root {
--background: #0f172a;
--foreground: #f1f5f9;
--card: #0f172a;
--card-foreground: #f1f5f9;
--primary: #3b82f6;
--primary-foreground: #fafaf9;
--secondary: #0f172a;
--secondary-foreground: #f1f5f9;
--accent: #22c55e;
--accent-foreground: #fafaf9;
--muted: #1d2537;
--muted-foreground: #9d9fa2;
--border: #313748;
--destructive: #dc2626;
--ring: #3b82f6;
--radius: 0.5rem;
--font-sans: ui-sans-serif, system-ui, sans-serif;
--font-serif: ui-serif, Georgia, serif;
--font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
--spacing: 1rem;
--shadow: 0 1px 2px rgba(0,0,0,0.06), 0 8px 24px rgba(0,0,0,0.04);
}
}