chore(post-images): Bump satori to 0.25.0 (#125) - #209
Open
bbornino wants to merge 1 commit into
Open
Conversation
Investigated the playfulprogramming#125 regression (code text disappearing from the banner background on newer satori). Diffed satori's source between 0.13.2 and 0.25.0 across text/whitespace handling and found nothing that would explain it; the existing banner/link-preview snapshot tests and a manual render with longer multi-line code both pass unmodified on 0.25.0. Added a regression test with longer, realistic code content as coverage for this bug shape going forward.
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 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. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #125.
Summary
Bumps
satorifrom 0.13.2 to 0.25.0 inpackages/post-images.Investigation
#125 describes the blurred code snippet in the banner background
(
packages/post-images/src/layouts/banner.ts'scode()function,two stacked
<pre>tags withfilter: blur(1px)) going blank afterupgrading satori — with before/after screenshots on the issue.
I could not reproduce that regression against this repo:
0.13.2and0.25.0acrosshandler/presets.ts,text/processor.ts,builder/text.ts,handler/compute.ts, andtext/index.ts(the files that own<pre>defaults,white-spacehandling, and glyph/path rendering).Nothing in that range touches whitespace collapsing or
pretextrendering in a way that would blank it out — the real changes are
Yoga API updates (box-sizing, position: static/contents), text-decoration
(skip-ink, double lines), text-indent, and a word-wrap tweak unrelated
to
pre.banner.test.tsand
link-preview.test.tssnapshot tests pass unmodified againsttheir existing golden PNGs (generated on 0.13.2).
and a longer, realistic multi-line TypeScript/JSX code sample (to
stress wrapping/overflow) — code renders fully and correctly in
both cases.
tsc --noEmitis clean with the new satori types.No other code changes were needed in
banner.tsorindex.ts'ssatori()call — grepped the rest of the monorepo andpackages/post-imagesis the only place satori is referenced or version-pinned.
Open question: since the issue's screenshots show a real blank
render, it's possible the bug was already fixed in an intermediate
satori release between 0.13.2 and 0.25.0, or that it depended on
post content/environment specifics not present in our test fixtures.
Flagging this rather than closing it as unreproducible outright —
worth a second pair of eyes/screenshots if it resurfaces.
Changes
packages/post-images/package.json— satori0.13.2→0.25.0pnpm-lock.yaml— updated accordinglypackages/post-images/tests/banner.test.ts— new regression testrendering longer, multi-line code (imports, JSX, multi-line functions)
through the banner layout, checked against a new golden
tests/banner-long-code.png, generated from the current (0.25.0)output and confirmed correct by eye. Gives permanent coverage for
this bug shape rather than a one-off manual check.
Test plan
pnpm test:unit(lint, knip, publint, sherif, vitest across allNX projects) — clean
pnpm run build:all— cleanpnpm run prettier— clean (only pre-existing warning on.claude/settings.local.json, unrelated to this change)banner-long-code.pngand the existingbanner.png/link-preview.pngrenders by eye