Skip to content

feat(render,weather): PixelArt shape + media_pixel + weather sprites - #260

Merged
unhappychoice merged 5 commits into
mainfrom
feat/pixel-art-shape
Jun 6, 2026
Merged

unhappychoice merged 5 commits into
mainfrom
feat/pixel-art-shape

Conversation

@unhappychoice

@unhappychoice unhappychoice commented Jun 4, 2026 •

Copy link
Copy Markdown
Owner

Implements #259.

Summary

  • New PixelArt shape (payload::PixelArtData, row-major RGBA grid + optional label) + media_pixel renderer that draws each cell as a truecolor ▀ half-block. Distinct from Image / media_image: works in any 24-bit-colour terminal, no kitty / sixel / iTerm2 protocol dependency.
  • weather fetcher gains a PixelArt shape variant. Eight bundled 16x16 sprites cover the WMO buckets (clear, mostly_clear, partly_cloudy, overcast, fog, rain, snow, thunderstorm); unknown codes fall back to overcast.
  • basic_read_store learns PixelArt so users can drop their own sprite JSON at $HOME/.splashboard/store/<id>.json without depending on a network fetcher.

Sprites are authored as ASCII grids with per-sprite palettes in weather/sprites.rs, decoded once via OnceLock. PR diff stays text-only.

Two pixel rows pack into one terminal cell, so a 16x16 sprite renders as 16 columns × 8 rows. Honours align / max_width / max_height; jagged rows surface an in-band error; the shared is_empty_body placeholder catches zero-row grids.

After merge: tick the media_pixel checkbox on #61 and update the weather entry on #68.

media_pixel reference (mirror of /reference/renderers/media/media_pixel/)

Draws a small pixel-art sprite cell-by-cell with truecolor half-blocks. Works in any terminal with 24-bit colour. Two stacked pixels fit into one cell, so a 16x16 sprite renders as 16 columns × 8 rows. Transparent pixels (a = 0) blend with the theme background.

Accepts Animates
pixel_art no

Options

Option Type Required Default Description
align "left" | "center" | "right" no "left" Horizontal placement of the sprite within the available cell.
max_width cells (u16) no area width Upper bound on the rendered sprite width in cells. Overflow is clipped from the right.
max_height cells (u16) no area height Upper bound on the rendered sprite height in cells (each cell = 2 pixel rows). Overflow is clipped from the bottom.

Theme tokens

Key Description
bg Used to fill transparent (a = 0) pixels.
text Used for the optional caption rendered under the sprite.

Compatible fetchers

Shape Fetchers
pixel_art basic_read_store, weather

Test plan

  • cargo test --lib — 3245 pass, 0 fail
  • cargo test -p xtask — 2 pass
  • cargo clippy --all-targets -- -D warnings — clean
  • cargo fmt --all -- --check — clean
  • cargo run --bin splashboard -- catalog renderer media_pixel — option schema + compatible fetchers list correct
  • Smoke test: basic_read_store widget consumes all 8 weather sprite JSONs over a 4×2 grid; eight buckets render in truecolor, transparent regions blend with theme bg, captions appear below each sprite.

Summary by CodeRabbit

  • New Features

    • Added inline PixelArt payload and truecolor pixel-art support, a terminal renderer drawing sprites with half-blocks, weather provider offering PixelArt shape, sample pixel-art sprite, and read-store support for PixelArt payloads.
  • Tests

    • Added comprehensive tests for sprite dimensions, palettes, label mapping, rendering behavior (transparency, alignment, captions), format roundtrips, and shape registration.
  • Chores

    • Updated snapshot/documentation sizes and registry mappings for the new renderer.

unhappychoice and others added 2 commits June 4, 2026 19:50
Introduces a small fixed-grid sprite shape paired with a truecolor
half-block renderer (`▀`). Distinct from `Image`: `Image` carries a path
rendered via terminal-graphics protocols (kitty / sixel / iTerm2);
`PixelArt` carries inline RGBA data that works in any 24-bit-colour
terminal. Pixels with `a = 0` blend into the theme background.

Two pixel rows pack into one terminal cell, so a 16x16 sprite renders as
16 columns × 8 rows. Honours `align` (left / center / right), `max_width`,
`max_height`; reports an in-band error for jagged rows; the centralised
`is_empty_body` placeholder catches zero-row grids.

Refs #259, #61 (media_pixel checkbox).

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Extends the `weather` fetcher (Open-Meteo now) with a `PixelArt` shape
variant. Each WMO weather code maps to one of eight bundled 16x16
sprites: clear / mostly_clear / partly_cloudy / overcast / fog / rain /
snow / thunderstorm. Unknown codes fall back to overcast so the renderer
always has something to draw.

Sprites are authored as ASCII grids with a per-sprite palette in
`weather/sprites.rs`, decoded once via `OnceLock`. Keeps the binary text
diff reviewable (no PNG assets to track) and bypasses any runtime PNG
decode.

Refs #259, #68 (weather extension).

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@coderabbitai

coderabbitai Bot commented Jun 4, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 283e699a-413a-4f98-b7e9-6f02d3c58738

📥 Commits

Reviewing files that changed from the base of the PR and between 22251b1 and f14bd32.

📒 Files selected for processing (2)
  • src/fetcher/read_store.rs
  • src/fetcher/weather/sprites.rs
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/fetcher/weather/sprites.rs

📝 Walkthrough

Walkthrough

Adds inline PixelArt payloads, a cached 16×16 weather sprite catalog mapped from WMO codes, a media_pixel terminal half-block renderer, and integrates PixelArt into the weather fetcher, samples, read-store, and snapshot preview config.

Changes

Pixel Art Sprite Feature

Layer / File(s) Summary
Data Contracts: Pixel Color and Art Data
src/payload.rs
Body::PixelArt(PixelArtData) variant added; PixelColor (RGBA with transparency helpers) and PixelArtData (2D pixel grid with optional label) structures defined to support inline sprite payloads.
Shape Enum and Dispatch
src/render/mod.rs
Shape::PixelArt variant added; shape_of, as_str, and is_empty_body updated for routing; media_pixel renderer module declared and registered as a builtin; PixelArt shape routed to media_pixel renderer by default.
Weather Sprite System: Catalog and Code Mapping
src/fetcher/weather/mod.rs, src/fetcher/weather/sprites.rs
Sprites submodule added; public catalog() and sprite_for_code(code: u16) API maps WMO weather codes to cached 16×16 sprites with weather labels; internal decode/build logic translates ASCII grids via palette helpers; eight weather conditions bundled; unit tests validate grid dimensions, palette coverage, and code→sprite label mapping.
Media Pixel Renderer: Half-block Terminal Rendering
src/render/media_pixel.rs
MediaPixelRenderer draws PixelArtData as 24-bit truecolor terminal half-blocks; supports alignment, width/height limits, caption placement, and transparent-pixel theme blending; validates uniform pixel rows and includes comprehensive tests for glyph/color rendering, alignment behavior, and edge cases.
Weather Fetcher, Samples, ReadStore, and Snapshot Config Integration
src/fetcher/weather/now.rs, src/samples.rs, src/fetcher/read_store.rs, xtask/src/snapshots.rs
WeatherFetcher extended to support Shape::PixelArt in shapes list, sample_body, and fetch output via sprite_for_code; pixel_art_sample() helper added to provide a 4×4 demo sprite; ReadStore deserialization and empty-body defaults extended for PixelArt; snapshot config maps PixelArt to weather fetcher and documents media_pixel canvas size.

Sequence Diagram

sequenceDiagram
  participant WMOCode as Weather Code
  participant SpriteCatalog as Sprite Catalog
  participant PixelArtData as PixelArtData
  participant MediaPixelRenderer as Media Pixel Renderer
  participant TerminalBuffer as Terminal Buffer

  WMOCode->>SpriteCatalog: sprite_for_code(code)
  SpriteCatalog->>PixelArtData: return cached PixelArtData + label
  PixelArtData->>MediaPixelRenderer: render(Body::PixelArt)
  MediaPixelRenderer->>MediaPixelRenderer: sample top and bottom pixels per cell
  MediaPixelRenderer->>MediaPixelRenderer: resolve transparent pixels to theme bg
  MediaPixelRenderer->>TerminalBuffer: set half-block glyph + fg/bg truecolor
  TerminalBuffer->>TerminalBuffer: display sprite in terminal buffer
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related issues

Poem

I nibble pixels, stitch the sky,
Sixteen by sixteen — a tiny sigh.
From code to sprite I hop and sow,
Half-blocks gleam where weather glow.
🐇✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 64.47% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately captures the main changes: introduction of a PixelArt shape, the media_pixel renderer, and weather sprite integration.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/pixel-art-shape

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (3)
src/samples.rs (1)

52-53: ⚡ Quick win

Include Shape::PixelArt in the canonical-sample shape test matrix.

canonical_sample now supports PixelArt (Line 52), but canonical_sample_matches_requested_shape still skips it. Adding it there prevents silent drift between sample fallback and shape routing.

Suggested test update
@@ fn canonical_sample_matches_requested_shape() {
             Shape::Bars,
+            Shape::PixelArt,
             Shape::Calendar,

Also applies to: 199-216

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/samples.rs` around lines 52 - 53, The test matrix skip logic in
canonical_sample_matches_requested_shape omits Shape::PixelArt while
canonical_sample now returns PixelArt (see Shape::PixelArt and
pixel_art_sample), causing a mismatch; update the match arms in
canonical_sample_matches_requested_shape to include Shape::PixelArt alongside
the other shapes (and likewise add PixelArt to the other match block referenced
in the later section around the 199-216 region) so the test covers PixelArt and
the routing/fallback behavior remains consistent.
src/payload.rs (1)

239-284: ⚡ Quick win

Add serde contract tests for PixelArt payloads.

PixelArt was added to the wire format, but this file’s tests don’t currently pin its shape-tag round-trip or alpha-default behavior (a omitted => 255). That leaves cache/compat regressions unguarded.

Suggested test additions
@@
     #[test]
+    fn pixel_art_round_trips_and_shape_tag_is_stable() {
+        let p = bare(Body::PixelArt(PixelArtData {
+            pixels: vec![vec![PixelColor::opaque(255, 0, 0)]],
+            label: Some("demo".into()),
+        }));
+        assert_eq!(p, round_trip(&p));
+        let v: serde_json::Value = serde_json::to_value(&p).unwrap();
+        assert_eq!(v["shape"], "pixel_art");
+    }
+
+    #[test]
+    fn pixel_color_alpha_defaults_to_opaque_when_omitted() {
+        let c: PixelColor = serde_json::from_str(r#"{"r":1,"g":2,"b":3}"#).unwrap();
+        assert_eq!(c.a, 255);
+    }
+
+    #[test]
+    fn transparent_alpha_round_trips() {
+        let c = PixelColor::TRANSPARENT;
+        let s = serde_json::to_string(&c).unwrap();
+        let back: PixelColor = serde_json::from_str(&s).unwrap();
+        assert_eq!(back, c);
+    }
+
+    #[test]
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/payload.rs` around lines 239 - 284, Add serde contract tests that verify
PixelArt payloads (PixelArtData) round-trip their shape/tag through the wire and
that PixelColor's alpha defaulting works: serialize a PixelArtData with
PixelColor entries missing the `a` field and ensure deserializing yields a
PixelColor with a == 255 (use PixelColor::opaque or check opaque_alpha via
PixelColor::opaque) and that a transparent pixel (PixelColor::TRANSPARENT)
round-trips correctly; also include a test that the serialized shape/tag for
PixelArtData is stable across round-trip. Locate tests exercising PixelArtData,
PixelColor, and their serde behaviour and add assertions that deserializing
serialized JSON without `a` produces opaque alpha and that labels/pixel grid
structure round-trip unchanged.
src/render/mod.rs (1)

396-433: ⚡ Quick win

Extend shape/renderer regression tests for PixelArt.

You wired media_pixel and Shape::PixelArt correctly, but the two coverage tables (registry_resolves_all_builtins, default_renderer_covers_every_shape) still omit them. That makes future breakage easy to miss.

Suggested test updates
@@ fn registry_resolves_all_builtins() {
             "media_image",
+            "media_pixel",
@@ fn default_renderer_covers_every_shape() {
             Shape::Image,
+            Shape::PixelArt,
             Shape::Calendar,
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/render/mod.rs` around lines 396 - 433, Update the two regression tests so
PixelArt is included: in the test named registry_resolves_all_builtins add
"media_pixel" (the renderer registered via media_pixel::MediaPixelRenderer) to
the expected builtins list/check so the registry resolution assertion covers it,
and in default_renderer_covers_every_shape include Shape::PixelArt (which should
resolve via default_renderer_for to "media_pixel") in the set of shapes asserted
to have default renderers; run the tests to confirm both
registry_resolves_all_builtins and default_renderer_covers_every_shape now
account for PixelArt.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@xtask/src/snapshots.rs`:
- Line 149: The preview canvas for PixelArt (Shape::PixelArt mapped to
"weather") is being clipped because renderer_dimensions() still falls back to
(40, 5) for media_pixel; update renderer_dimensions() to return a taller canvas
for MediaType::MediaPixel (e.g., (40, 10) or (40, 12)) so a 16×16 sprite plus
optional label fits without truncation. Locate the renderer_dimensions() match
arm for MediaType::MediaPixel and change the returned tuple accordingly so
PixelArt previews are not clipped.

---

Nitpick comments:
In `@src/payload.rs`:
- Around line 239-284: Add serde contract tests that verify PixelArt payloads
(PixelArtData) round-trip their shape/tag through the wire and that PixelColor's
alpha defaulting works: serialize a PixelArtData with PixelColor entries missing
the `a` field and ensure deserializing yields a PixelColor with a == 255 (use
PixelColor::opaque or check opaque_alpha via PixelColor::opaque) and that a
transparent pixel (PixelColor::TRANSPARENT) round-trips correctly; also include
a test that the serialized shape/tag for PixelArtData is stable across
round-trip. Locate tests exercising PixelArtData, PixelColor, and their serde
behaviour and add assertions that deserializing serialized JSON without `a`
produces opaque alpha and that labels/pixel grid structure round-trip unchanged.

In `@src/render/mod.rs`:
- Around line 396-433: Update the two regression tests so PixelArt is included:
in the test named registry_resolves_all_builtins add "media_pixel" (the renderer
registered via media_pixel::MediaPixelRenderer) to the expected builtins
list/check so the registry resolution assertion covers it, and in
default_renderer_covers_every_shape include Shape::PixelArt (which should
resolve via default_renderer_for to "media_pixel") in the set of shapes asserted
to have default renderers; run the tests to confirm both
registry_resolves_all_builtins and default_renderer_covers_every_shape now
account for PixelArt.

In `@src/samples.rs`:
- Around line 52-53: The test matrix skip logic in
canonical_sample_matches_requested_shape omits Shape::PixelArt while
canonical_sample now returns PixelArt (see Shape::PixelArt and
pixel_art_sample), causing a mismatch; update the match arms in
canonical_sample_matches_requested_shape to include Shape::PixelArt alongside
the other shapes (and likewise add PixelArt to the other match block referenced
in the later section around the 199-216 region) so the test covers PixelArt and
the routing/fallback behavior remains consistent.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 24ce7523-f9ef-4011-8d8e-164532a852e6

📥 Commits

Reviewing files that changed from the base of the PR and between ca1f2fa and ca78384.

📒 Files selected for processing (8)
  • src/fetcher/weather/mod.rs
  • src/fetcher/weather/now.rs
  • src/fetcher/weather/sprites.rs
  • src/payload.rs
  • src/render/media_pixel.rs
  • src/render/mod.rs
  • src/samples.rs
  • xtask/src/snapshots.rs

Comment thread xtask/src/snapshots.rs
Shape::PointSeries => "weather",
Shape::Bars => "github_languages",
Shape::Image => "github_avatar",
Shape::PixelArt => "weather",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Add explicit snapshot canvas sizing for media_pixel to avoid clipped previews.

Line 149 enables PixelArt renderer previews via weather, but renderer_dimensions() still falls back to (40, 5) for media_pixel, which truncates a 16×16 sprite (~8 rows, plus optional label).

Suggested fix
@@ fn renderer_dimensions(renderer: &str) -> (u16, u16) {
         "media_image" => (40, 5),
+        "media_pixel" => (40, 10),
         "grid_calendar" => (28, 10),
@@ fn renderer_dimensions_match_documented_sizes() {
             ("media_image", (40, 5)),
+            ("media_pixel", (40, 10)),
@@ fn representative_fetcher_prefers_documented_examples() {
             (Shape::Image, "github_avatar"),
+            (Shape::PixelArt, "weather"),
             (Shape::Calendar, "clock"),
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@xtask/src/snapshots.rs` at line 149, The preview canvas for PixelArt
(Shape::PixelArt mapped to "weather") is being clipped because
renderer_dimensions() still falls back to (40, 5) for media_pixel; update
renderer_dimensions() to return a taller canvas for MediaType::MediaPixel (e.g.,
(40, 10) or (40, 12)) so a 16×16 sprite plus optional label fits without
truncation. Locate the renderer_dimensions() match arm for MediaType::MediaPixel
and change the returned tuple accordingly so PixelArt previews are not clipped.

@codecov

codecov Bot commented Jun 4, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 95.74861% with 23 lines in your changes missing coverage. Please review.
✅ Project coverage is 95.62%. Comparing base (ca1f2fa) to head (f14bd32).

Files with missing lines Patch % Lines
src/samples.rs 0.00% 16 Missing ⚠️
src/render/media_pixel.rs 98.65% 4 Missing ⚠️
src/payload.rs 66.66% 3 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##             main     #260    +/-   ##
========================================
  Coverage   95.62%   95.62%            
========================================
  Files         248      250     +2     
  Lines       67832    68372   +540     
========================================
+ Hits        64865    65382   +517     
- Misses       2967     2990    +23     
Files with missing lines Coverage Δ
src/fetcher/read_store.rs 99.48% <100.00%> (+0.02%) ⬆️
src/fetcher/weather/mod.rs 100.00% <ø> (ø)
src/fetcher/weather/now.rs 91.43% <100.00%> (+0.06%) ⬆️
src/fetcher/weather/sprites.rs 100.00% <100.00%> (ø)
src/render/mod.rs 99.38% <100.00%> (+<0.01%) ⬆️
src/payload.rs 99.08% <66.66%> (-0.92%) ⬇️
src/render/media_pixel.rs 98.65% <98.65%> (ø)
src/samples.rs 91.62% <0.00%> (-8.38%) ⬇️

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Three follow-on additions caught by the Phase 3 self-review pass on
PR #260:

- `registry_resolves_all_builtins` learns the `media_pixel` builtin.
- `default_renderer_covers_every_shape` iterates `Shape::PixelArt`.
- `xtask::snapshots::renderer_dimensions` overrides the default
  (40 × 5) with a tighter (20 × 5) box matched to the canonical 4 × 4
  PixelArt sample plus its caption row.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

♻️ Duplicate comments (1)
xtask/src/snapshots.rs (1)

84-86: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

media_pixel snapshot height is still too small for weather PixelArt previews.

Line 86 uses (20, 5), which clips 16×16 weather sprites rendered as half-blocks (~8 rows before caption). This breaks fetcher-page previews for weather + media_pixel; the test on Line 234 currently locks in that clipping behavior.

Suggested fix
-        // Canonical PixelArt sample is a 4x4 smiley (2 cells wide × 2 cells tall) with a
-        // one-line caption; (20, 5) gives breathing room without dwarfing the sprite.
-        "media_pixel" => (20, 5),
+        // Weather PixelArt sprites are 16x16 and render as ~8 terminal rows with half-blocks;
+        // keep headroom for caption and avoid clipping in fetcher-page previews.
+        "media_pixel" => (20, 10),
@@
-            ("media_pixel", (20, 5)),
+            ("media_pixel", (20, 10)),
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@xtask/src/snapshots.rs` around lines 84 - 86, The snapshot size for the
"media_pixel" entry in snapshots.rs is too short vertically (currently "(20,
5)") and clips 16×16 weather sprites rendered as half-blocks; update the tuple
for the "media_pixel" key to increase the height (e.g., change (20, 5) to
something like (20, 10) or at least (20, 9)) so the full ~8 rows of pixel-art
plus the caption fit without clipping, and run the snapshot tests that reference
this snapshot to confirm the preview no longer truncates.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Duplicate comments:
In `@xtask/src/snapshots.rs`:
- Around line 84-86: The snapshot size for the "media_pixel" entry in
snapshots.rs is too short vertically (currently "(20, 5)") and clips 16×16
weather sprites rendered as half-blocks; update the tuple for the "media_pixel"
key to increase the height (e.g., change (20, 5) to something like (20, 10) or
at least (20, 9)) so the full ~8 rows of pixel-art plus the caption fit without
clipping, and run the snapshot tests that reference this snapshot to confirm the
preview no longer truncates.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 2cdc0c20-16e2-4bfa-aec6-287486be04be

📥 Commits

Reviewing files that changed from the base of the PR and between ca78384 and 22251b1.

📒 Files selected for processing (2)
  • src/render/mod.rs
  • xtask/src/snapshots.rs
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/render/mod.rs

unhappychoice and others added 2 commits June 4, 2026 20:31
Adds PixelArt to `READ_STORE_SHAPES`, `from_json`, `from_toml`, and
`empty_body`, plus a structured-cases entry exercising both formats.
Users can now drop a sprite at
`$HOME/.splashboard/store/<id>.json` and point a `basic_read_store`
widget at it with `shape = "pixel_art"` — the escape hatch the PixelArt
shape needed to stand on its own without depending on a network fetcher.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
The original SPRITE_FOG used 1-pixel-row bands; under media_pixel's
half-block packing each cell ended up as `fg=fog / bg=transparent`, so
the sprite read as a faint pinstripe instead of fog. Bands are now two
pixel rows thick so each one packs into a single solid cell, with
varied horizontal indents giving a drifting feel.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@unhappychoice
unhappychoice merged commit 030a6be into main Jun 6, 2026
7 checks passed
@unhappychoice
unhappychoice deleted the feat/pixel-art-shape branch June 6, 2026 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant