🎨 Color Shade & Tint Generator

Mix a base colour with white for lighter tints and with black for darker shades to build a coordinated ladder for buttons and backgrounds.

📐 工作原理与说明
tint = C·(1−t) + 255·t;shade = C·(1−t) + 0·t(t 为混合比例,0 ≤ t ≤ 1)
按线性混色:tint 是在基色上按比例混入白色得到更亮的色,shade 是混入黑色得到更暗的色;按固定步长生成整组明暗色卡,用于按钮、背景与边框的层次设计。

Formula & Standard References

Item Formula / Note Source / Standard
Lightness shift hold hue and saturation, step lightness to build tints and shades CSS Color Module Level 4
Linear blending C = C1 x (1 - t) + C2 x t with t as the mix ratio CSS Color Module Level 4 color-mix()
Contrast retention shades must still meet the 4.5:1 readability requirement WCAG 2.2 (1.4.3)
⚠️ 使用说明与注意事项

📋 说明

左→右为由浅(tint)到基色再到深(shade)的渐变;每侧档数即混入白/黑的比例步数。

设计系统(如 Tailwind 的 50–900)常用这种按明度分档的色板组织方式。