v0.5.4
Highlights
- Banner pastes as one line per row again — copying the
/stockbanner from Arc or Chrome was producing 9-11 stacked lines per visual row instead of the readable banner. Chromium's clipboard serializer inserts a newline between sibling<text>SVG elements, and pylon's emitter splits each row across<rect>block-glyph runs, leaving 9-11 sibling<text>per banner row. A newrender.CoalesceSVGTextpost-processor merges same-row<text>siblings into one<text>carrying<tspan>children —<tspan>siblings serialize as a single text run. Idempotent and a no-op for non-fragmented rows. Wired into the SVG and HTML render paths; PNG path is intentionally skipped because pylon's SVG rasterizer reads<text>bodies viaxml.Decoderwhich drops chardata once a child element appears. - Bare
?lang=zhresolves tozh-TW— explicit user override now lands on the deployment's native script (TW market focus) as the least-surprising outcome. Previous behavior followed CLDR's bare-zh → simplified default, which surprised TW visitors typing?lang=zh. Callers wanting simplified must say?lang=zh-CNor?lang=zh-Hansexplicitly. TheAccept-Languagematcher path is unchanged —Accept-Language: zhstill routes tozh-CNvia the CLDR matcher; the divergence is contained to the explicit override path.
Other changes
render/svg_coalesce.goandrender/svg_coalesce_test.goadd the post-processor and 7 unit tests + 1 end-to-end viarender.Bannercovering: solo-row byte-identity, multi-segment coalescing, rect preservation, idempotence, empty input, multi-row groups, and a live/tmp/stock.svgsnapshot smoke test.internal/i18n/i18n.go::parseLocaleQueryflips barezhfromLocaleZhCNtoLocaleZhTW. The doc comment explains why (deployment audience > CLDR default for the explicit-override path).docs/localization.mdupdated: the BCP-47 acceptance table now listszhunder Traditional, the prose paragraph documents the divergence between?lang=andAccept-Languagepaths.
Container image
ghcr.io/cmj0121/imagelet:0.5.4