feat(ads): client banner rotation, fade UX & live toggle (PR2)
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Has been skipped
CI / integration (pull_request) Has been skipped
CI / ui (pull_request) Successful in 50s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 58s
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Has been skipped
CI / integration (pull_request) Has been skipped
CI / ui (pull_request) Successful in 50s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 58s
Consume the server-driven banner block (PR1) in the UI and retire the gate. - banner.ts: createScheduler — a smooth weighted round-robin over campaigns (each appears its weight share per cycle, evenly interleaved) with round-robin over a campaign's messages; the rotator drives fade-in -> hold/scroll -> fade-out -> gap -> fade-in, a lone message stays put, reduce-motion swaps instantly without scroll. - model.ts/codec.ts: Profile.banner (Banner/BannerCampaign/BannerTimings) decoded from the fbs block. - Screen.svelte: drop the compile-time SHOW_AD_BANNER; render AdBanner from app.profile.banner (campaigns + timings + reduceMotion). - AdBanner.svelte: opacity-driven fades + scroll host; the rotator is recreated when the campaigns/timings change (a `banner` notify re-fetch swaps them in place). - app.svelte.ts: on the `notify` `banner` sub-kind, refreshProfile() so the banner shows/hides in place. - tests: scheduler distribution + round-robin, the fade sequence, single-message, reduce-motion, stop(); codec banner decode. UI_DESIGN.md + trackers updated.
This commit is contained in:
@@ -1428,9 +1428,9 @@ cannot submit; three-way admin filter.
|
||||
docker-network caddy hop `172.18.0.x` for chat moderation, and bucketing the gateway's
|
||||
per-IP rate limiter on it). Correct + spoof-safe in **both** contours (prod has no host
|
||||
caddy → public clients untrusted → real peer used). `peerIP` unit-tested.
|
||||
- **Ad banner** gated **off** behind a compile-time `SHOW_AD_BANNER=false` in `Screen.svelte`
|
||||
— the `{#if}` branch, the `AdBanner` import and `banner.ts` are tree-shaken out of the prod
|
||||
bundle (code kept for post-release polish).
|
||||
- **Ad banner** was gated off here behind `SHOW_AD_BANNER=false`; the **AD** phase
|
||||
(PRERELEASE.md) later turned it into the real server-driven advertising network and removed
|
||||
the gate (`Screen` renders it from `app.profile.banner`).
|
||||
- **Landing** Telegram entry is now just the **64px logo** (clickable, no button/caption).
|
||||
- **TG-fullscreen header** reworked again: title + menu are one **centred pair** (hamburger
|
||||
right of the title) pinned to the **bottom** of the TG nav band, lining up with Telegram's
|
||||
|
||||
Reference in New Issue
Block a user