@certrev/cert-block 0.5.4 → 0.5.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +45 -0
- package/README.md +12 -1
- package/package.json +10 -1
- package/src/__tests__/readme-version.test.ts +51 -0
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,51 @@ change the rendered cert output and never break a compiling integration** (regis
|
|
|
5
5
|
exports, types). Anything that would alter what a visitor sees — or require integration changes —
|
|
6
6
|
is announced loudly here first.
|
|
7
7
|
|
|
8
|
+
## 0.5.5 — 2026-07-31
|
|
9
|
+
|
|
10
|
+
- **New:** `repository`, `homepage`, and `bugs` in `package.json` — the npm page now links to the
|
|
11
|
+
public source mirror (`github.com/CertREV/cert-kit`, `packages/cert-block`) and to the issue
|
|
12
|
+
tracker, so the registry listing is no longer a dead end. Provenance metadata only: no code, no
|
|
13
|
+
exports, no dependency change.
|
|
14
|
+
- **Docs:** README gains a source-repo link and states the peer requirement explicitly — **React
|
|
15
|
+
`>=18`**. `peerDependencies.react` has enforced `>=18.0.0` since before 0.5.0 (and
|
|
16
|
+
`peerDependenciesMeta` marks it non-optional), but the README never said so; a consumer had to
|
|
17
|
+
read `package.json` to find the floor.
|
|
18
|
+
- Rendered output: **byte-identical to 0.5.4** (metadata and prose only — no file under `dist/`
|
|
19
|
+
changes).
|
|
20
|
+
|
|
21
|
+
## 0.5.4 — 2026-07-23
|
|
22
|
+
|
|
23
|
+
- **Backfilled — this release shipped with no entry.** 0.5.4 published 2026-07-23 and is the first
|
|
24
|
+
release after this file was written; every other version from 0.3.0 on has a section, including
|
|
25
|
+
0.5.2 (a no-op republish). It changed the public type surface without the notice the contract
|
|
26
|
+
above requires. The omission is recorded here rather than quietly closed.
|
|
27
|
+
- **Changed:** `FONT_SLOTS` / `FONT_STACKS` (`render-def`) widened 3 → 5 — `grotesk` (Plus Jakarta
|
|
28
|
+
Sans) and `mono` (JetBrains Mono) added at the shared guide values, byte-identical to this
|
|
29
|
+
package's `RENDER_BLOCK_FONT_STACKS`, the portal `FONT_SLOT_STACKS`, and the Liquid twin's
|
|
30
|
+
branches. Purely additive: `sans` / `serif` / `system` are untouched, so the card == modal
|
|
31
|
+
invariant holds. Shipped lockstep with the portal's Liquid + WordPress grotesk/mono wiring
|
|
32
|
+
(POR-10775 / POR-10721) — Phase-3 enablement of a vocabulary that was dormant on both engines,
|
|
33
|
+
not a repair of a live intra-page mismatch: before this release the Liquid card dropped
|
|
34
|
+
`grotesk`/`mono` too, and fell back exactly as the modal did.
|
|
35
|
+
- **Breaking (types) — belonged in a minor, with notice:** `FONT_SLOTS`, `FONT_STACKS`, `FontSlot`
|
|
36
|
+
and `isFontSlot` are public exports. Widening the `FontSlot` union 3 → 5 breaks any consumer
|
|
37
|
+
holding an exhaustive `Record<FontSlot, string>` or an exhaustive `switch` over the slots — a
|
|
38
|
+
break of a compiling integration (exports, types) under the semver contract at the top of this
|
|
39
|
+
file, shipped in a patch.
|
|
40
|
+
- Rendered output: the design-locked cert card and the modal bundle are **byte-identical to
|
|
41
|
+
0.5.3** — across the two published tarballs `dist/components/render-cert-block.js` (sha1
|
|
42
|
+
`22267d5d…`) and all 65 files under `dist/modal/` (`certrev-cert.js` sha1 `2013ebbe…`) are
|
|
43
|
+
unchanged, and neither resolves the shared `FONT_STACKS` (the card carries its own
|
|
44
|
+
`RENDER_BLOCK_FONT_STACKS`, which already listed all five slots; the modal consults no font map
|
|
45
|
+
at all). `<certrev-badge>` passes no `renderDef`, so it is unaffected by construction. Output can
|
|
46
|
+
differ on ONE path: a caller passing a `renderDef` with `fontSlot: 'grotesk' | 'mono'` into the
|
|
47
|
+
legacy `<CertBadge>` / `renderBadgeHtml`, where that slot now resolves to a `--certrev-font`
|
|
48
|
+
stack instead of being dropped as invalid. No brand could author those slots at release time (the
|
|
49
|
+
portal editor did not offer them; every known `render_def` writer emits `sans`), so no visitor's
|
|
50
|
+
render is known to have changed — that last point is inference from the call graph and the
|
|
51
|
+
authoring surface, not a production data check.
|
|
52
|
+
|
|
8
53
|
## 0.5.3 — 2026-07-22
|
|
9
54
|
|
|
10
55
|
- **New:** `certRevCertComponent` (`./builder`) — the drop-in gen2 registration entry, with the
|
package/README.md
CHANGED
|
@@ -226,6 +226,12 @@ RFC-8785 JCS implementation used for signature verification). To be clear about
|
|
|
226
226
|
**nothing cryptographic runs at card render** — the cert card draws purely from block options;
|
|
227
227
|
verification enters only with the modal / the `getVerifiedEnvelope` verify layer.
|
|
228
228
|
|
|
229
|
+
React is the one **peer** dependency left — **`react >=18.0.0`**, declared non-optional, so a
|
|
230
|
+
peer-enforcing resolver (npm 7+) fails the install on React 17 with `ERESOLVE` rather than
|
|
231
|
+
warning. Only the React entries need it: `./webcomponent` and `./modal` build React-free (no
|
|
232
|
+
`react/jsx-runtime`) and there is no `react-dom` peer. CI builds and runs the SSR tests on
|
|
233
|
+
React 18.3; the range admits 19.
|
|
234
|
+
|
|
229
235
|
## Known issues (upstream)
|
|
230
236
|
|
|
231
237
|
- `@builder.io/sdk-react@5.2.4` ships types that fail to compile under
|
|
@@ -251,7 +257,12 @@ Facts are mocked via `makeMockPayload` / `makeSignedEnvelope` (`src/contract/fix
|
|
|
251
257
|
|
|
252
258
|
## Version
|
|
253
259
|
|
|
254
|
-
`0.5.
|
|
260
|
+
`0.5.5` — see [CHANGELOG.md](./CHANGELOG.md) for the release history and the semver contract
|
|
255
261
|
(patch/minor never change the rendered cert output or break a compiling integration). Publishes
|
|
256
262
|
**publicly** to npm as `@certrev/cert-block` (`publishConfig.access: public`) via GitHub Actions
|
|
257
263
|
trusted publishing (OIDC); the internal `@certrev` GitHub-Packages channel mirrors it.
|
|
264
|
+
|
|
265
|
+
Source is public at [`CertREV/cert-kit`](https://github.com/CertREV/cert-kit) (MIT) — this
|
|
266
|
+
package is `packages/cert-block/`; report a vulnerability privately through that repo's
|
|
267
|
+
`SECURITY.md`. The tarball also ships `src/` alongside `dist/`, so a security review reads the
|
|
268
|
+
exact code for the version it installed.
|
package/package.json
CHANGED
|
@@ -1,7 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@certrev/cert-block",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.5",
|
|
4
4
|
"description": "Headless / crypto_verify render edge for the CertREV CertDeliveryEnvelope. SSR-safe React components (<CertBadge>/<ExpertBio>/<CertRevBacklink>), a deterministic schema.org JSON-LD projector, a fail-closed verify layer over the shared VerdictKernel, and a framework-agnostic <certrev-badge> Web Component. Sign once (portal), render everywhere (Hydrogen / Next / Builder / universal embed).",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "git+https://github.com/CertREV/cert-kit.git",
|
|
8
|
+
"directory": "packages/cert-block"
|
|
9
|
+
},
|
|
10
|
+
"homepage": "https://github.com/CertREV/cert-kit/tree/HEAD/packages/cert-block#readme",
|
|
11
|
+
"bugs": {
|
|
12
|
+
"url": "https://github.com/CertREV/cert-kit/issues"
|
|
13
|
+
},
|
|
5
14
|
"type": "module",
|
|
6
15
|
"main": "./dist/index.js",
|
|
7
16
|
"types": "./dist/index.d.ts",
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { readFileSync } from 'node:fs'
|
|
2
|
+
import { describe, expect, it } from 'vitest'
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Both public packages open a `## Version` section with a bare version stamp, and both ship
|
|
6
|
+
* README.md inside the published tarball (`files`) — so the stamp is what a consumer reads
|
|
7
|
+
* after `npm i`, not just what a browser shows on GitHub.
|
|
8
|
+
*
|
|
9
|
+
* It has now drifted twice, in both packages:
|
|
10
|
+
* - cert-contract 0.5.1 was a docs-only release whose entire purpose was unsticking this
|
|
11
|
+
* stamp ("README Version section brought current (0.4.0 / 0.5.0 were missing)").
|
|
12
|
+
* - cert-block 0.5.4 bumped package.json and touched nothing else, so the published 0.5.4
|
|
13
|
+
* tarball ships a README claiming to be 0.5.3. That is live on npm right now.
|
|
14
|
+
*
|
|
15
|
+
* Nothing caught either one, because nothing was looking: the stamp is prose, and prose has
|
|
16
|
+
* no compiler. A release step nobody can forget beats a release step written down somewhere.
|
|
17
|
+
* This is that step.
|
|
18
|
+
*
|
|
19
|
+
* The two packages word the line differently ("`x.y.z` — see" vs "Current: `x.y.z` — see"),
|
|
20
|
+
* so the pattern below matches the first backticked token after the heading rather than a
|
|
21
|
+
* fixed sentence. If a README reshapes that section, update the pattern — do not delete the
|
|
22
|
+
* assertion; the drift it catches has shipped to npm twice.
|
|
23
|
+
*/
|
|
24
|
+
const PACKAGES = ['cert-block', 'cert-contract'] as const
|
|
25
|
+
|
|
26
|
+
describe.each(PACKAGES)('%s README version stamp', (pkgName) => {
|
|
27
|
+
const pkgUrl = new URL(`../../../${pkgName}/package.json`, import.meta.url)
|
|
28
|
+
const readmeUrl = new URL(`../../../${pkgName}/README.md`, import.meta.url)
|
|
29
|
+
|
|
30
|
+
const { version } = JSON.parse(readFileSync(pkgUrl, 'utf8')) as { version: string }
|
|
31
|
+
const readme = readFileSync(readmeUrl, 'utf8')
|
|
32
|
+
|
|
33
|
+
it('matches package.json — bump both, or neither', () => {
|
|
34
|
+
// First backticked token after the `## Version` heading.
|
|
35
|
+
const stamp = readme.match(/^## Version\s*\n+[^`\n]*`([^`]+)`/m)
|
|
36
|
+
|
|
37
|
+
expect(
|
|
38
|
+
stamp,
|
|
39
|
+
`${pkgName}: README has no \`## Version\` section opening with a backticked stamp. If the ` +
|
|
40
|
+
'section was renamed or reshaped, update this pattern to match the new shape rather ' +
|
|
41
|
+
'than deleting the assertion.',
|
|
42
|
+
).not.toBeNull()
|
|
43
|
+
|
|
44
|
+
expect(
|
|
45
|
+
stamp?.[1],
|
|
46
|
+
`${pkgName}: README's \`## Version\` stamp is ${stamp?.[1]} but package.json is ${version}. ` +
|
|
47
|
+
'README.md ships inside the npm tarball, so this mismatch gets published to consumers. ' +
|
|
48
|
+
`Bump the stamp in packages/${pkgName}/README.md.`,
|
|
49
|
+
).toBe(version)
|
|
50
|
+
})
|
|
51
|
+
})
|