Closed general

Show component verification in the page header, not as a README widget

Ray · ·closed by Colby Knox

Component pages show their verification as a README widget today: ::adom-verified{src="/<owner>/<slug>/render/verification.json"} on the line under the title (from adom/component-widgets, widgets/verified-widget.js). It takes about six lines of height for what is one fact, and it only appears when a README remembers to include it. Agreed in chat today (Ray, Colby, John): promote it to page chrome so it is a standard, not a README convention.

What we want

  • The wiki reads verification.json from the page repo and shows a compact Verified badge in the page header, near the vouch, or right under the hero image or model. Colby's call on the exact spot.
  • Clicking the badge opens the verification log, so nothing the card shows today is lost.
  • Pages without verification.json show nothing, not "unverified".

The data (already on the pages)

verification.json, schema adom/verification@1, committed in each component page repo. The widget's header comment documents it in full; the short version:

{
  "schema": "adom/verification@1",
  "part": "RP2354A",
  "variants": [{ "mpn": "...", "note": "...", "stocked": false }],
  "entries": [{
    "date": "2026-10-27", "by": { "name": "Ray Kholodovsky", "handle": "ray" },
    "status": "verified | open | superseded",
    "title": "...",
    "scope": ["symbol", "footprint", "3d-model", "pins"],
    "checks": [{ "text": "...", "result": "pass | fail | note" }],
    "evidence": [{ "label": "...", "href": "docs/..." }],
    "files": { "rp2354a.kicad_mod": "<sha256>" }
  }]
}

The factory writes these files with tools/verify_log.py from component-widgets, so the format can stay as it is.

Keep: the amber state

Each entry lists the sha256 of the files it verified. The widget hashes them in the browser today and turns amber ("changed since verified") when one differs. That is the useful part of the mark; please keep it. Doing it server-side at render time would be better than in the browser.

Our side once it ships

We remove the ::adom-verified line from the component READMEs (or make the widget a no-op when the header already shows the badge), so pages do not show it twice.

Example page: https://wiki.adom.inc/adom/rp2354a

1 Reply

Colby Knox ·

Shipped to prod (git-wiki 16e4a553).

  • Badge: component pages with a verification.json show a Verified badge under the title row's badges. Clicking it opens the full log: variants, every record, checks, evidence, and each pinned file with its state.
  • Server-side hashing: the files are hashed on the server once per commit. The badge turns amber when a pinned file changed after the record that pinned it. If you verify the changed file again with a newer record, the badge goes green, and the older record shows "re-verified".
  • README widget: where the badge shows, ::adom-verified is skipped, so nothing renders twice. You can remove that line from the component READMEs whenever convenient.
  • Signing a record: the page's owner, org members and admins can add one from the log dialog ("Add a record") or through POST /api/pages/<owner>/<slug>/verification. The server sets the signer from the account and hashes the pinned files at HEAD, so --by is no longer typed. PATCH .../verification/<index> with {"status":"superseded"} retires a record, or closes an open item. A CLI verb (adom-wiki page verify) is requested in adom/adom-wiki-cli#70. Until it ships, verify_log.py plus a push still works.
  • Everyone else: readers get "Report it as an issue" and "Propose a fix" at the bottom of the log.
  • One badge, not two tiers: the header's trust badge ("Made by Adom", "Unreviewed", and so on) already says whether Adom stands behind the page. The Verified badge says who checked the part data. Next: the server will also stamp the pushing account on entries added through a hand-pushed verification.json, and fill in existing entries from commit history.

RP2354A is amber on purpose: rp2354a.kicad_mod and rp2354a.kicad_sym no longer match the hashes in your 2026-10-27 record. If the edits are fine, open the log on https://wiki.adom.inc/adom/rp2354a, choose "Add a record" and sign it. The page goes green and keeps the old record as history.

Colby Knox closed this ·

Log in to reply.