feat(legal): add the trader identification block to the legal pages #138
Inga granskare
Etiketter
Inga etiketter
area/backups
area/ci
area/control-panel
area/identity
area/infra
area/observability
area/payments
area/security
area/storage
area/web
blocked
needs-info
needs-triage
ready-for-implementation
type
bug
type
chore
type
docs
type
epic
type
feature
type
task
wontfix
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Inget förfallodatum satt.
Beroenden
Inga beroenden satta
Referens
bitborg/bitborg-web!138
Läser in…
Hänvisa till i nytt ärende
Ingen beskrivning angiven.
Ta bort grenen "fix/legal-controller-identification"
Borttagning av en gren är permanent. Även om den borttagna grenen kan fortsätta existera en kort tid innan den faktiskt tas bort, kan det INTE ångras i de flesta fall. Vill du fortsätta?
Closes #135 — but deliberately publishes nothing yet. This needs a decision from you before it can
ship.
Structure
One source of truth (
src/lib/legal-entity.ts) rendered by one component(
src/components/legal-entity.astro) at the end of the Terms, the Privacy Policy and/contact, inboth languages. Labels are new
legal.entity.*keys in both dictionaries. The country is an i18nstring rather than a data field, so it reads correctly per locale instead of showing one language's
spelling on the other's page. Invoicing will need the same values, which is the other reason they live
in one module.
Why nothing renders
The registered details are not recorded anywhere I can source them from — no organisationsnummer,
no VAT number and no postal address exist in the project's records.
So nothing was guessed. Each unknown field is
nullwith aTODO(legal)marker, and the block iswithheld all-or-nothing — half an identification block is a worse answer to e-handelslagen § 8 and
GDPR Art. 13(1)(a) than the single line those pages carry today, and it reads as an oversight rather
than a decision. The gate is compiler-checked rather than asserted with a cast. Confirmed against a real
production build:
/terms,/en/privacyand/contactrender no block and no placeholder text. Inpnpm deva dev-only notice names the missing fields so the gap is visible to whoever works on thepages.
Why this stops here rather than shipping
Filling the four fields in is not purely mechanical. Publishing a trader's registration details has
consequences that have to be settled before they go on a page that cannot be un-published, and that
decision is pending. Until it lands the block stays withheld and the three pages render exactly as they
do today.
To finish
Fill in
legalName,organisationNumber,vatNumberandaddressinsrc/lib/legal-entity.ts.Nothing else needs touching — the block then appears on all six pages.
/trial-termswas left alone; the issue named the Terms, the Privacy Policy and/contactonly.Verified
pnpm check0 errors · eslint, stylelint,pnpm format:check,pnpm mdlintall clean ·pnpm test177 passed (8 new for the publish gate) ·pnpm buildsucceeds.7380180f8dc2ed304857