Skip to content

fix: normalize encoded face image sources - #78

Open
vahapogut wants to merge 1 commit into
tscircuit:mainfrom
vahapogut:codex/normalize-face-image-data
Open

fix: normalize encoded face image sources#78
vahapogut wants to merge 1 commit into
tscircuit:mainfrom
vahapogut:codex/normalize-face-image-data

Conversation

@vahapogut

Copy link
Copy Markdown

Fixes #3

@algora-pbc /claim #3

Summary

  • Accept bare encoded PNG strings for Box.faceImages.top by normalizing them to data:image/png;base64,....
  • Preserve existing data/URL image hrefs and support inline SVG markup by encoding it as data:image/svg+xml;base64,....
  • Add regression coverage for bare encoded top-face PNGs.

Verification

  • bun run build
  • bun x biome check lib\render-elements.ts tests\topimage-encoded.test.ts
  • Direct render verification with bun confirmed encoded face images are normalized.
  • git diff --check

Note: bun test tests\topimage-encoded.test.ts is blocked on this Windows machine because the repo preload imports bun-match-svg/looks-same, and sharp fails to install/link locally.

@vercel

vercel Bot commented Jun 23, 2026

Copy link
Copy Markdown

@vahapogut is attempting to deploy a commit to the tscircuit Team on Vercel.

A member of the Team first needs to authorize it.

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.

Add support for Box.faceImages.top = "encoded image"

1 participant