流式字号
用 clamp() 让标题字号随视口平滑缩放:手机不挤、桌面不大得离谱。
流体标题
拖动滑块调整缩放
实现提示词
Set display headings with clamp(28px, 5vw, 64px) so type scales fluidly with the viewport.Set display headings with clamp(28px, 5vw, 64px). Animate the size transition smoothly on viewport change.设计规范条目
### Fluid Typography (#fluid-type) Category: Typography Use clamp() for fluid type that scales smoothly with the viewport — not cramped on mobile, not huge on desktop. - Do: Set display headings with clamp(28px, 5vw, 64px) so type scales fluidly with the viewport With motion: Set display headings with clamp(28px, 5vw, 64px). Animate the size transition smoothly on viewport change. Live demo: https://uidesignmd.com/guides/fluid-type/