Repository navigation
fix: picking Column Drop left the field blank - #18
Conversation
Reported as "Column Drop 这个效果似乎现在看不到". It was not faint — the stage came up with ZERO cells. `columns` moves a highlight down a column, and a per-dot `animation-delay` can only OFFSET a dot's phase, never move anything. So `buildCss` returns null for it, which is the correct and documented behaviour. The playground computed `cssAvailable` correctly, DISABLED the CSS switch and printed the reason — and then passed `renderer="css"` anyway. The engine was asked for something it refuses, and `paintCss` returned without painting anything. Disabling a control without honouring it is the worst of the available answers: the switch explains itself while the field shows nothing. The toggle now records a preference that the preset can overrule, and what the field is actually painted with follows: `css` only when `cssAvailable`, and the readout and the copied snippet say `svg` rather than claiming a mode the engine is not in. A paste that said `renderer="css"` would have handed a consumer the same blank field. The engine normalises the same thing for direct callers, which matters more than the site: `paintable()` rewrites the renderer to `svg` when the preset is not expressible, so `handle.options.renderer` tells the truth about what is on screen. Doing it in the option resolution rather than inside `paintCss` is deliberate — a frame callback retrying a build it knows will fail does that once per frame, and `cssGap()` still reports why. SECOND, AND IT WAS A LIE RATHER THAN DEAD WEIGHT: the stylesheet emitted `@keyframes botui-dm-columns`, and that rule animated nothing. `spike` is a gaussian centred on the cycle seam, so sampling it at the two positions its stop table names — 0 and 1 — gives full brightness at BOTH ends: a static, fully-lit field. Every consumer shipped that rule, and it described a motion the renderer had already refused to draw. `keyframesFor` now applies the same `preset.css` rule `buildCss` does, so the document only carries motions that can actually run — and a test walks every renderable preset to prove none went missing. 215 tests (was 209), oxlint 0, registry ok, both changelog ledgers.
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. 🧰 Additional context used📚 Code guidelines (3)No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (7)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 5 remain after this review. 📝 WalkthroughWalkthroughThe playground and dot-matrix engine now use SVG when a selected preset is not CSS-renderable. The CSS stylesheet no longer emits keyframes for unsupported presets. ChangesRenderer eligibility
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~20 minutes Change: Bug fix Merge Risk: ⚪ Minimal · up to Selecting an effect the CSS renderer cannot express, such as Column Drop, now falls back to SVG, so the field is no longer blank. The readout and copied snippet report the renderer actually in use. No remaining merge-blocking risk was found. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The fallback makes rendering and copied configuration consistent. The inspected paths show no new privilege or sensitive-data access, but assurance is limited for embedding environments outside the reviewed browser flow. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 5 files. (2 skipped: 2 unsupported.)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Comment |
Why
Reported as "Column Drop 这个效果似乎现在看不到". It was not faint — the stage came up with
zero cells.
Change outline
columnsmoves a highlight down a column; a per-dotanimation-delaycan only offseta dot's phase, never move anything. So
buildCssreturnsnullfor it — correct anddocumented behaviour.
The playground computed
cssAvailablecorrectly, disabled the CSS switch and printed thereason — then passed
renderer="css"anyway. The engine was asked for something it refuses,and
paintCssreturned without painting anything.with follows, so
rendereriscssonly whencssAvailable.svgrather than claiming a mode the engine isnot in — a paste saying
renderer="css"handed consumers the same blank field.paintable()), for direct callers:handle.options.rendererreports what is actually painted. Deliberately in option resolution, not inside
paintCss—a frame callback retrying a build it knows will fail does that once per frame, and
cssGap()still reports why.Special things to note
columnsstill hascss: false—this makes the refusal visible rather than blank, which is the documented contract.
@keyframes botui-dm-columns, and that rule animated nothing:spikeis a gaussiancentred on the cycle seam, so sampling it at the two positions its stop table names — 0 and
1 — yields full brightness at both ends. Every consumer shipped a rule describing a
static, fully-lit field for a motion the renderer had already refused.
keyframesFornowapplies the same
preset.cssrulebuildCssdoes, and a test walks every renderable presetto prove none went missing.
svg; the copy omitsrenderer="css"; and the switch becomes usable again for a motion CSS can express.🤖 Generated with Claude Code
Summary by CodeRabbit