swiss-design
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSwiss Design System
瑞士风格设计系统
A design system rooted in the Swiss International Style of the 1950s–60s: grotesque typography, rigorous grid, bold geometric forms, generous whitespace, and restrained color.
本设计系统源自20世纪50-60年代的瑞士国际风格:无衬线排版、严谨网格、醒目几何形态、充足留白以及克制配色。
Six Principles
六大原则
- Grid first. Every layout lives on a 12-column grid with an 8px base unit.
- Mobile first, always. Design for the smallest viewport first, then expand. Every layout must work at 320px and at 1440px. Use ,
sm:,md:Tailwind prefixes systematically.lg: - Whitespace is structure. Generous padding and margins are not waste — they are the design.
- Opacity, not hue, creates hierarchy. Never introduce a second color to indicate text weight or importance. Use opacity.
- One accent. Each project gets exactly one accent color, used sparingly at multiple opacities.
- Narrow columns. Body text never exceeds . Wider columns hurt legibility.
max-w-[60ch]
- 网格优先。所有布局均基于12列网格,基础单位为8px。
- 始终移动端优先。先针对最小视口进行设计,再逐步扩展。所有布局必须适配320px和1440px的视口。系统性地使用、
sm:、md:等Tailwind前缀。lg: - 留白即结构。充足的内边距和外边距并非浪费——它们本身就是设计的一部分。
- 用透明度而非色调构建层级。绝不通过引入第二种颜色来区分文本权重或重要性,使用透明度即可。
- 单一强调色。每个项目仅使用一种强调色,通过不同透明度少量运用。
- 窄列文本。正文文本宽度永远不超过,过宽的列会损害可读性。
max-w-[60ch]
Typography
排版系统
Primary font: IBM Plex Sans (Google Fonts)
html
<link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&display=swap" rel="stylesheet">Fallback chain (in order of preference):
| Font | Source | Character |
|---|---|---|
| IBM Plex Sans | Google Fonts | Primary. Rational, slightly condensed, 1960s systems rationalism |
| Hanken Grotesk | Google Fonts | Closest to Neue Haas Grotesk lineage |
| Barlow | Google Fonts | Condensed Swiss-grid proportions, strong vertical rhythm |
| Host Grotesk | Google Fonts | Warm grotesque, good at all sizes |
| DM Sans | Google Fonts | Clean neo-grotesque fallback |
| system-ui | Built-in | Last resort |
css
font-family: 'IBM Plex Sans', 'Hanken Grotesk', 'Barlow', 'Host Grotesk', 'DM Sans', system-ui, sans-serif;Type scale:
| Role | Tailwind | Line height | Max width |
|---|---|---|---|
| Display | | | unconstrained |
| H1 | | | unconstrained |
| H2 | | | unconstrained |
| H3 | | | unconstrained |
| Body | | | |
| Small | | | |
| Caption | | | unconstrained |
| Mono | | | |
- Headings: (300) or
font-light(400). Never bold for headings.font-normal - Emphasis within body: (500). Never
font-medium(700).font-bold - Letter spacing on display/h1: (-0.02em).
tracking-tight - Captions and labels: .
tracking-wide uppercase text-xs
主字体: IBM Plex Sans(Google Fonts)
html
<link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&display=swap" rel="stylesheet">回退字体链(优先级从高到低):
| 字体 | 来源 | 特征 |
|---|---|---|
| IBM Plex Sans | Google Fonts | 主字体。理性、略窄,兼具20世纪60年代的系统理性主义风格 |
| Hanken Grotesk | Google Fonts | 最接近Neue Haas Grotesk字体谱系 |
| Barlow | Google Fonts | 符合瑞士网格比例的窄体字体,垂直韵律感强 |
| Host Grotesk | Google Fonts | 温暖风格的无衬线字体,适配所有字号 |
| DM Sans | Google Fonts | 简洁的新无衬线回退字体 |
| system-ui | 系统内置 | 最终备选 |
css
font-family: 'IBM Plex Sans', 'Hanken Grotesk', 'Barlow', 'Host Grotesk', 'DM Sans', system-ui, sans-serif;字号层级:
| 用途 | Tailwind类 | 行高 | 最大宽度 |
|---|---|---|---|
| 展示文本 | | | 无限制 |
| 一级标题 | | | 无限制 |
| 二级标题 | | | 无限制 |
| 三级标题 | | | 无限制 |
| 正文 | | | |
| 小号文本 | | | |
| 说明文本 | | | 无限制 |
| 等宽文本 | | | |
- 标题:使用(300)或
font-light(400),标题绝不使用粗体。font-normal - 正文中的强调内容:使用(500),绝不使用
font-medium(700)。font-bold - 展示文本/一级标题的字间距:(-0.02em)。
tracking-tight - 说明文本和标签:使用。
tracking-wide uppercase text-xs
Color System
配色系统
Stone palette (light mode → dark mode)
石色系配色(浅色模式 → 深色模式)
| Role | Light | Dark | Tailwind |
|---|---|---|---|
| Page background | | | |
| Surface / card | | | |
| Subtle surface | | | |
| Border | | | |
| Subtle border | | | |
| Primary text | | | |
| Secondary text | | | |
| Tertiary text | | | |
| Placeholder | | | |
| 用途 | 浅色模式 | 深色模式 | Tailwind类 |
|---|---|---|---|
| 页面背景 | | | |
| 表层/卡片 | | | |
| 次级表层 | | | |
| 边框 | | | |
| 次级边框 | | | |
| 主文本 | | | |
| 次级文本 | | | |
| 三级文本 | | | |
| 占位文本 | | | |
Opacity hierarchy (the core rule)
透明度层级(核心规则)
To make text less dominant, reduce opacity — never change the hue.
Full presence: text-stone-900 (primary)
Softer: text-stone-900/70 (secondary, labels)
Quiet: text-stone-900/40 (tertiary, captions)
Ghosted: text-stone-900/20 (disabled, placeholder)Dark mode: replace with . The opacity values stay identical.
stone-900stone-50如需降低文本的视觉权重,只需降低透明度——绝不改变色调。
完全醒目: text-stone-900 (主文本)
柔和显示: text-stone-900/70 (次级文本、标签)
弱化显示: text-stone-900/40 (三级文本、说明文字)
虚化显示: text-stone-900/20 (禁用状态、占位文本)深色模式:将替换为,透明度数值保持不变。
stone-900stone-50Accent color
强调色
Each project uses one accent color. Default is Swiss poster red.
| Name | Hex | Tailwind arbitrary |
|---|---|---|
| Swiss Red (default) | | |
| Cobalt | | |
| Golden | | |
| Forest | | |
Use accent at these opacities only:
Full: bg-[#C8102E] text-[#C8102E]
Muted: bg-[#C8102E]/60 text-[#C8102E]/60
Subtle: bg-[#C8102E]/20 (backgrounds, tints)
Ghost: bg-[#C8102E]/10 (very light tints)每个项目仅使用一种强调色,默认使用瑞士海报红。
| 名称 | 十六进制值 | Tailwind自定义值 |
|---|---|---|
| 瑞士红(默认) | | |
| 钴蓝色 | | |
| 金色 | | |
| 森林绿 | | |
仅可使用以下透明度的强调色:
完全醒目: bg-[#C8102E] text-[#C8102E]
柔和显示: bg-[#C8102E]/60 text-[#C8102E]/60
次级背景: bg-[#C8102E]/20 (背景、淡色)
淡色背景: bg-[#C8102E]/10 (极浅淡色)Spacing & Grid
间距与网格
Base unit: 8px. All spacing is a multiple of 8.
| Token | Value | Usage |
|---|---|---|
| 8px | Tight inline gaps |
| 16px | Component internal |
| 32px | Between components |
| 64px | Between sections |
| 64px | Section padding (minimum) |
| 96px | Section padding (standard) |
| 128px | Section padding (generous) |
Grid:
html
<!-- 12-column grid — always mobile-first, columns collapse to full-width on small screens -->
<div class="grid grid-cols-12 gap-4 md:gap-8">
<div class="col-span-12 md:col-span-8">...</div>
<div class="col-span-12 md:col-span-4">...</div>
</div>Max content width: or with .
max-w-5xlmax-w-6xlmx-auto px-4 md:px-8基础单位: 8px。所有间距均为8px的倍数。
| 标识 | 值 | 用途 |
|---|---|---|
| 8px | 紧凑的内联间距 |
| 16px | 组件内部间距 |
| 32px | 组件之间的间距 |
| 64px | 区块之间的间距 |
| 64px | 区块内边距(最小值) |
| 96px | 区块内边距(标准值) |
| 128px | 区块内边距(充足值) |
网格:
html
<!-- 12列网格 —— 始终移动端优先,小屏幕下列自动变为全屏宽度 -->
<div class="grid grid-cols-12 gap-4 md:gap-8">
<div class="col-span-12 md:col-span-8">...</div>
<div class="col-span-12 md:col-span-4">...</div>
</div>内容最大宽度: 使用或,搭配。
max-w-5xlmax-w-6xlmx-auto px-4 md:px-8Responsive Design
响应式设计
The Swiss grid adapts fluidly across viewports. Every layout decision must be made at two scales: mobile (single column, generous vertical rhythm) and desktop (multi-column, horizontal tension).
Breakpoint strategy:
| Prefix | Width | Use for |
|---|---|---|
| (none) | 0px+ | Mobile — single column, full width |
| 640px+ | Large phones, small tablets |
| 768px+ | Tablets, narrow desktop — introduce 2-col layouts |
| 1024px+ | Desktop — full 12-col grid, max content width |
Mobile layout rules:
- All grid columns collapse to
col-span-12 - Section padding reduces:
py-16 md:py-24 lg:py-32 - Horizontal padding tightens:
px-4 md:px-8 - Display type scales down:
text-5xl md:text-7xl lg:text-8xl - Multi-column nav collapses to hamburger or hidden
- Tables scroll horizontally: wrap in
overflow-x-auto - Side-by-side cards stack vertically:
grid-cols-1 md:grid-cols-2 lg:grid-cols-3
Fluid type pattern:
html
<!-- Scale display type fluidly across viewports -->
<h1 class="text-4xl sm:text-5xl md:text-6xl lg:text-7xl font-normal tracking-tight leading-none">
Swiss International Style
</h1>
<!-- Or use clamp() for truly fluid scaling -->
<h1 class="text-[clamp(2rem,6vw,5rem)] font-normal tracking-tight leading-none">
Swiss International Style
</h1>Responsive section pattern:
html
<section class="py-16 md:py-24 lg:py-32 border-b border-stone-200 dark:border-stone-800">
<div class="max-w-6xl mx-auto px-4 md:px-8">
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
...
</div>
</div>
</section>Touch targets: All interactive elements must be at least 44×44px on mobile. Use for buttons and nav links.
min-h-[44px] min-w-[44px]Navigation on mobile: Collapse to a minimal top bar. Hide secondary nav links below . Never use hamburger menus with deeply nested hierarchies — the Swiss style favors flat, clear navigation.
md:瑞士网格可流畅适配不同视口。所有布局决策需兼顾两种尺度:移动端(单列布局、充足垂直韵律)和桌面端(多列布局、水平张力)。
断点策略:
| 前缀 | 宽度 | 适用场景 |
|---|---|---|
| (无) | 0px+ | 移动端 —— 单列、全屏宽度 |
| 640px+ | 大屏手机、小尺寸平板 |
| 768px+ | 平板、窄屏桌面 —— 引入双列布局 |
| 1024px+ | 桌面端 —— 完整12列网格、内容最大宽度 |
移动端布局规则:
- 所有网格列自动变为
col-span-12 - 区块内边距缩减:
py-16 md:py-24 lg:py-32 - 水平内边距收紧:
px-4 md:px-8 - 展示文本缩小:
text-5xl md:text-7xl lg:text-8xl - 多列导航折叠为汉堡菜单或隐藏
- 表格可横向滚动:包裹在中
overflow-x-auto - 并排卡片垂直堆叠:
grid-cols-1 md:grid-cols-2 lg:grid-cols-3
流式文本模式:
html
<!-- 跨视口流畅缩放展示文本 -->
<h1 class="text-4xl sm:text-5xl md:text-6xl lg:text-7xl font-normal tracking-tight leading-none">
Swiss International Style
</h1>
<!-- 或使用clamp()实现真正的流式缩放 -->
<h1 class="text-[clamp(2rem,6vw,5rem)] font-normal tracking-tight leading-none">
Swiss International Style
</h1>响应式区块模式:
html
<section class="py-16 md:py-24 lg:py-32 border-b border-stone-200 dark:border-stone-800">
<div class="max-w-6xl mx-auto px-4 md:px-8">
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
...
</div>
</div>
</section>触摸目标: 移动端所有交互元素尺寸至少为44×44px。按钮和导航链接使用。
min-h-[44px] min-w-[44px]移动端导航: 折叠为极简顶部栏。隐藏以下的次级导航链接。瑞士风格偏好扁平化、清晰的导航,切勿使用带有深层嵌套层级的汉堡菜单。
md:Dark Mode
深色模式
Use Tailwind's strategy (respects system preference automatically):
mediajs
// tailwind.config.js
darkMode: 'media'Every color token has a variant. See the stone palette table above. Never use or — always use stone scale.
dark:bg-blackbg-white使用Tailwind的策略(自动遵循系统偏好):
mediajs
// tailwind.config.js
darkMode: 'media'每个配色标识都有变体。详见上方石色系配色表。绝不使用或——始终使用石色系层级。
dark:bg-blackbg-whiteGotchas
注意事项
- Never use a second color to signal hierarchy. Opacity only. , not
text-stone-900/70.text-stone-500 - Never exceed for body text. Wider columns are illegible.
max-w-[60ch] - Never or
bg-white. Usebg-black/bg-stone-50.bg-stone-950 - IBM Plex Sans is not a system font. Always include the Google Fonts tag.
<link> - One accent per project. Do not introduce a second accent color. Use opacity variations instead.
- Headings are light, not bold. for display and h1,
font-lightfor h2–h3.font-normal - No border-radius on structural elements. Inputs, cards, and containers use or at most
rounded-none. The Swiss style is rectilinear.rounded-sm - Section padding is generous. Minimum , standard
py-16. Never less.py-24 - Every layout must work on mobile. Default (no prefix) classes are mobile. Always add and
md:variants for larger viewports. Never build desktop-first and try to retrofit mobile.lg: - Tables on mobile need . Never let a wide table break mobile layout.
overflow-x-auto - Touch targets minimum 44px. Buttons, links, and nav items must be tappable on mobile.
- Fluid type, not fixed. Use responsive type classes () or
text-3xl md:text-5xl— never a single fixed size that works only at one viewport.clamp()
- 绝不使用第二种颜色构建层级。仅使用透明度。使用,而非
text-stone-900/70。text-stone-500 - 正文文本宽度绝不超过。过宽的列可读性差。
max-w-[60ch] - 绝不使用或
bg-white。使用bg-black/bg-stone-50。bg-stone-950 - IBM Plex Sans并非系统字体。务必引入Google Fonts的标签。
<link> - 每个项目仅使用一种强调色。切勿引入第二种强调色,使用透明度变体替代。
- 标题使用轻量字重,而非粗体。展示文本和一级标题使用,二级至三级标题使用
font-light。font-normal - 结构元素不使用圆角。输入框、卡片和容器使用或最多
rounded-none。瑞士风格为直线型设计。rounded-sm - 区块内边距要充足。最小值为,标准值为
py-16,切勿更小。py-24 - 所有布局必须适配移动端。默认(无前缀)类为移动端样式。务必为更大视口添加和
md:变体。绝不为桌面端优先设计再适配移动端。lg: - 移动端表格需添加。切勿让宽表格破坏移动端布局。
overflow-x-auto - 触摸目标最小尺寸为44px。按钮、链接和导航项在移动端必须可点击。
- 使用流式文本,而非固定尺寸。使用响应式文本类()或
text-3xl md:text-5xl——绝不使用仅适配单一视口的固定尺寸。clamp()
When to read reference files
参考文件查阅场景
| Task | File |
|---|---|
| Full color token table, CSS custom properties, dark mode details | |
| Tailwind component patterns: buttons, cards, nav, forms, badges | |
Paste-ready | |
| Applying this system to an existing page, audit checklist | |
| 任务 | 文件 |
|---|---|
| 完整配色标识表、CSS自定义属性、深色模式细节 | |
| Tailwind组件模式:按钮、卡片、导航、表单、徽章 | |
可直接粘贴的 | |
| 将本系统应用于现有页面、审核清单 | |