feat(design): M70 r1 —— 补第 4 档「天蓝」候选 #3C8DBC(四档对比)
③ 的 primary `#0C6780` 偏青(teal),不是「天蓝」。新增 ④ 天蓝:种子 `#3C8DBC` (CAM16 hue 239.5°,夹 ③ 与 ①② 之间)+ 中性彩度 12 → primary `#236488`。 - `tests/skyseed_candidates.rs`:候选表 3 → 4 档,④ 的 9 角色 × light/dark 全部进 pin; `the_three_tiers_are_actually_distinguishable` 改为 `the_candidates_are_actually_distinguishable`, 增加「③ 与 ④ 中性彩度相同、主色/容器必须靠色相区分」的断言 - `tests/contrast_aa.rs`:候选 WCAG 门禁 3 → 4 档(26 × 4 × 2 = 208 项) - 默认值**不动**:仍为 ③ `#87CEEB`(临时默认,待用户看完四档再拍); `product_default_is_the_recommended_candidate` 保持原样,专门在默认与推荐不一致时报警 - 文档:`color/mod.rs` 与 `palettes.rs` 的候选清单补上 ④ 与「改一行即可切 ④」的说明
This commit is contained in:
1 parent
79404fa9d1
commit
9519a89472
4 files changed
+67
-27
No files matched your search
@@ -159,13 +159,14 @@ fn baseline_light_and_dark_both_pass() {
|
||||
|
||||
#[test]
|
||||
fn sky_seed_candidates_meet_wcag_aa() {
|
||||
// M70:三档默认色候选(种子 + 中性彩度)必须过同一条 26 组门禁。
|
||||
// M70:四档默认色候选(种子 + 中性彩度)必须过同一条 26 组门禁。
|
||||
// 中性彩度改变只影响色相/彩度,不影响 tone 轴,所以理论上恒过——这里就是要**证明**它恒过,
|
||||
// 而不是相信它。任何一档不达标,该档直接判为不可用(不许为了好看放宽阈值)。
|
||||
let candidates = [
|
||||
("① 保守蓝", "#2196F3", 6.0_f64),
|
||||
("② 冷调蓝", "#2196F3", 12.0),
|
||||
("③ 浅冷蓝", "#87CEEB", 12.0),
|
||||
("④ 天蓝", "#3C8DBC", 12.0),
|
||||
];
|
||||
let mut failures = Vec::new();
|
||||
let mut worst = (f32::MAX, String::new());
|
||||
|
||||
Reference in new issue
Block a user