max / makeover-webview
- Co-Authored-By
- Claude Opus 5 (1M context) <noreply@anthropic.com>
1 file changed,
+13 insertions,
-3 deletions
| @@ -936,7 +936,10 @@ | |||
| 936 | 936 | let css = stylesheet(&Emit::default()); | |
| 937 | 937 | for selector in ["button", "card", "chip", "tab", "segment", "toggle"] { | |
| 938 | 938 | assert!(css.contains(&format!(".{selector}:hover {{")), "{selector}"); | |
| 939 | - | assert!(css.contains(&format!(".{selector}:active {{")), "{selector}"); | |
| 939 | + | assert!( | |
| 940 | + | css.contains(&format!(".{selector}:active {{")), | |
| 941 | + | "{selector}" | |
| 942 | + | ); | |
| 940 | 943 | assert!( | |
| 941 | 944 | css.contains(&format!(".{selector}:focus-visible {{")), | |
| 942 | 945 | "{selector} has no focus ring" | |
| @@ -1192,7 +1195,11 @@ | |||
| 1192 | 1195 | assert!(!css.contains("visibility:")); | |
| 1193 | 1196 | // Opacity leaves the hit area behind, so the pair travels together or | |
| 1194 | 1197 | // the row carries an invisible tappable control. | |
| 1195 | - | assert!(css.contains(".row-actions {\n opacity: 0;\n pointer-events: none;\n }")); | |
| 1198 | + | assert!( | |
| 1199 | + | css.contains( | |
| 1200 | + | ".row-actions {\n opacity: 0;\n pointer-events: none;\n }" | |
| 1201 | + | ) | |
| 1202 | + | ); | |
| 1196 | 1203 | assert!(css.contains("opacity: 1;\n pointer-events: auto;")); | |
| 1197 | 1204 | ||
| 1198 | 1205 | // And on a device with no hover the row carries no such control at | |
| @@ -1201,7 +1208,10 @@ | |||
| 1201 | 1208 | // the capability query with the reveal. | |
| 1202 | 1209 | let hide = css.find(".row-actions {").expect("hide rule"); | |
| 1203 | 1210 | let query = css[..hide].rfind("@media").expect("a query precedes it"); | |
| 1204 | - | assert!(css[query..hide].find('}').is_none(), "the hide escaped the query"); | |
| 1211 | + | assert!( | |
| 1212 | + | css[query..hide].find('}').is_none(), | |
| 1213 | + | "the hide escaped the query" | |
| 1214 | + | ); | |
| 1205 | 1215 | } | |
| 1206 | 1216 | ||
| 1207 | 1217 | #[test] |