Skip to content

0.13.0 — a privacy statement assembled from what was chosen

Choose a tag to compare

@NiKrause NiKrause released this 01 Sep 13:32
· 2 commits to main since this release
52f9bdc

qr-intro can now assemble a privacy statement from what somebody actually
chose, and make accepting it the way out.

intro.privacy = {
  accept: true,
  clauses: state => [
    state.relayOptIn ? 'A relay may hold this briefly.' : 'Nothing leaves this network.',
    `Identity: ${state.identity}`
  ]
}
intro.choices = { identity: 'passkey' }   // merged, not replaced

The clauses are the consumer's. What an app does with somebody's data is the
app's to state, and an element shipping its own text would be putting words in
its mouth — so it supplies the state and repaints when an answer changes.

With accept: true the close button is disabled and close() refuses until the
tick is set. Both were needed: a dialog dismissable with Escape while its
statement is unaccepted has no gate, only a greyed-out button.

The panel sits beside the explanation on a wide screen, under it on a narrow
one, in a <details> that folds — open to begin with, since one folded on
arrival is one nobody read. Its ground is tokened rather than fixed
(--qr-intro-panel-background and friends): a hard white panel is right in a
light theme and a hole in a dark one, and this element is dark by default.

Nothing that existed changed. An element that is passed no privacy is exactly
what it was, down to having one checkbox in its shadow tree rather than two —
which an existing test insisted on, and caught when the first attempt built the
accept tick up front and hid it.

New: privacy, choices, accepted. German strings for all three new labels.

From #165, for the intro consolidation in #164.