Skip to content

fix(EN10168 v0.5.0): render url / qr-code / image supplementary values in the product description - #333

Merged
stiebitzhofer merged 2 commits into
mainfrom
fix/en10168-supplementary-types
Oct 5, 2026
Merged

stiebitzhofer merged 2 commits into
mainfrom
fix/en10168-supplementary-types

Conversation

@stiebitzhofer

Copy link
Copy Markdown
Member

Problem

`ProductDescription.SupplementaryInformation` never passed a value's `Type` to the `KeyValue` template:

  • a B-field with `"Type": "url"` printed as plain text;
  • one with `"qr-code"` or `"image"` printed its `data:` URI as text.

It surfaced on the Steel Mill SE demo certificate: B20 holds the passport URL and B21 the passport QR code. With the old stylesheet B21 renders as `data:image/…`.

Fix

For `url`, `email`, `phone`, `qr-code` and `image`, the bare `Value` and the `Type` are passed, so the template renders a link or a graphic. Every other type keeps its "Value Unit" text.

This mirrors material-identity/schema `legacy/schemas/EN10168/v0.5.0/stylesheet.xsl` (schema PR #405); the two files are byte-identical again.

Verification

  • All 12 `test/fixtures/EN10168/v0.5.0` certificates rendered with the old and the new stylesheet: identical text output.
  • The Steel Mill SE certificate: B20 renders as a link, and B21 as a QR code that decodes to `https://dpp.s1seven.com/dpp/sms/H26-204517\`.
  • `npx jest`: 272 passed, 3 skipped.

🤖 Generated with Claude Code

…s in the product description

ProductDescription.SupplementaryInformation never passed a value's Type to the KeyValue
template, so a B-field with Type "url" printed as plain text and one with Type "qr-code" or
"image" printed its data URI as text. Seen on the Steel Mill SE demo certificate, where B20
carries the passport URL and B21 the passport QR code.

For Type url, email, phone, qr-code and image, the bare Value and the Type are now passed, so
the template renders a link or a graphic. Every other type keeps the "Value Unit" text it
always rendered.

Mirror of material-identity/schema legacy/schemas/EN10168/v0.5.0/stylesheet.xsl (schema
PR #405); the two files are byte-identical again. Checked by rendering all 12
test/fixtures/EN10168/v0.5.0 certificates with the old and the new stylesheet: text output
identical. npx jest: 272 passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@stiebitzhofer
stiebitzhofer requested a review from asamark October 2, 2026 17:50
@eamon0989
eamon0989 temporarily deployed to s1-schemas-pr-333 October 5, 2026 11:01 Inactive
@stiebitzhofer
stiebitzhofer merged commit f88053c into main Oct 5, 2026
12 checks passed
@stiebitzhofer
stiebitzhofer deleted the fix/en10168-supplementary-types branch October 5, 2026 11:03

This branch was previously deployed

1 inactive deployment
s1-schemas-pr-333 — d4101866 Deployed Oct 5, 2026 by eamon0989
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.

3 participants