diff --git a/Plans/08 WebKit engine/S058-ad-removal-animation.md b/Plans/08 WebKit engine/S058-ad-removal-animation.md index 894bfa0..c4fc8b5 100644 --- a/Plans/08 WebKit engine/S058-ad-removal-animation.md +++ b/Plans/08 WebKit engine/S058-ad-removal-animation.md @@ -36,8 +36,8 @@ Port the original, which is the spec: `~/Documents/Apps/Nacre/nacre/services.py` - [x] Port `ZAP_JS` detection + overlay + collapse into the cosmetic script (keep the class/id → selectors round trip), options (animate, ms, bg, badge, off) from the browser per page; badge SVG built in Rust from theme colours. - [x] Safety rules (players, sizes, off-screen, max 12, paused sites) and Motion off / setting off → plain hide. - [x] Test page `tests/smoke/pages/ads.html` (a few visible ad boxes matching local cosmetic rules, one inside a fake player, one tiny, one off-screen) + smoke: shots mid-animation (overlay + badge visible) and after (slots collapsed, layout closed), player untouched, Motion off = instant; dark and light. -- [ ] Visible run on a real ad-heavy page (e.g. a news site) on DP-1 (D-045): watch it, read the shots; note anything that flickers or jumps. -- [ ] PROGRESS entry, INDEX line, tracker, commit `S058: …`, push. +- [x] Visible run on a real ad-heavy page (e.g. a news site) on DP-1 (D-045): watch it, read the shots; note anything that flickers or jumps. +- [x] PROGRESS entry, INDEX line, tracker, commit `S058: …`, push. ## End criteria - The smoke shows the overlay with the cookie shield mid-animation and the closed layout after; player element intact. @@ -49,6 +49,3 @@ Port the original, which is the spec: `~/Documents/Apps/Nacre/nacre/services.py` ## Handoff (→ PROGRESS.md) What differs from the original, if anything. -## Resume -Boxes 1–2 done (src/inject.rs `COSMETIC_JS`, `App::zap_options` in src/app.rs, `theme::zap_badge`). Box 3 in -progress: `tests/smoke/pages/ads.html` + `tests/smoke/zap.txt` (`SMOKE_SIZE=1280x900 tools/smoke.sh tests/smoke/zap.txt`). diff --git a/Plans/INDEX.md b/Plans/INDEX.md index 4b0ef85..344d2e1 100644 --- a/Plans/INDEX.md +++ b/Plans/INDEX.md @@ -10,7 +10,7 @@ Dropped with Servo (D-032): S011, S029, S030, S032, S033, S037, S038. ## 08 WebKit engine (in this order) - [x] [S053 — Remove Servo: vendor crates, gst-mse, Servo-only tests/tools, docs and texts](08%20WebKit%20engine/S053-servo-removal.md) · Sonnet high - [x] [S057 — Small UI bugs: Customize panel scroll, site colour from the favicon, colour picker glyphs, beforeunload on quit](08%20WebKit%20engine/S057-small-ui-bugs.md) · Sonnet high -- [ ] [S058 — Ads vanish before your eyes: Pie-style cookie shield removal animation (port of the original)](08%20WebKit%20engine/S058-ad-removal-animation.md) · Opus medium +- [x] [S058 — Ads vanish before your eyes: Pie-style cookie shield removal animation (port of the original)](08%20WebKit%20engine/S058-ad-removal-animation.md) · Opus medium - [ ] [S051 — Profile folder, sealed cookies, site data, incognito, media source](08%20WebKit%20engine/S051-profile-cookies-media.md) · Opus medium - [ ] [S052 — WebKit tuning defaults, background tabs, memory check](08%20WebKit%20engine/S052-tuning-defaults.md) · Sonnet high - [ ] [S054 — Site pass on WebKit vs Chromium reference](08%20WebKit%20engine/S054-site-pass.md) · Opus high diff --git a/docs/PROGRESS.md b/docs/PROGRESS.md index c663cb3..2de5efc 100644 --- a/docs/PROGRESS.md +++ b/docs/PROGRESS.md @@ -439,6 +439,13 @@ Later: S010 list: user checks the Discord icon with their own client (the Discor - Not done: a Stay answer on a tab that closed in a quit leaves it reloaded (state of form fields lost); no visible run. - Later: other Areas that only paint (none found) would repeat the Customize bug. +## S058 — Ad removal animation: Pie-style cookie shield, port of the original zapper (2026-11-14) +- Done: `COSMETIC_JS` (src/inject.rs) ports `ZAP_JS`: the class/id → selectors round trip stays; selectors now get a 1 ms `__nz_detect` animation and `animationstart` hands over each rendered match (WebKit fires it). Visible ads get an overlay (primaryContainer 92 % + cookie shield badge, `theme::zap_badge` in the window's theme colours) that squishes and spins away while the ad fades, then the slot collapses (340 ms) and gets `display:none`. Options per `cosmetic.hide(selectors, opts)` call from `App::zap_options` (animate, ms = 900 × Motion scale, min 0.3; bg; badge). +- Safety: `