From 218c9ab6b37013d22ee7af1e9a395378d62aabe8 Mon Sep 17 00:00:00 2001 From: Sylvain Duchesne Date: Wed, 12 Aug 2026 14:59:37 +0200 Subject: [PATCH] =?UTF-8?q?docs:=20la=20doctrine=20dit=20quand=20la=20barr?= =?UTF-8?q?i=C3=A8re=20s'affiche,=20pas=20seulement=20ce=20qu'elle=20fait?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit La feuille décrivait l'ordre de résolution de l'identifiant mais taisait la règle qui décide de l'affichage — page de tête toujours, iframe jamais — et c'est exactement ce qui vient d'être corrigé dans le code. Elle porte désormais le raisonnement : le discriminant est le cadre parce que l'identifiant est un état observable alors que la présence d'un portefeuille ne l'est pas, et qu'un écran conditionnel doit donc deviner l'état qui compte. Plus les deux faits observés sur les sites réels qui ferment les alternatives — l'import ouvre un sélecteur sur place, et notre onglet ne reçoit aucun signal quand il réussit. --- .project/concepts/e2e-harness/_debt.md | 10 ---------- .project/concepts/sign-in/_debt.md | 7 ------- .../concepts/sign-in/knowledge_how-a-user-gets-in.md | 12 ++++++++++++ 3 files changed, 12 insertions(+), 17 deletions(-) delete mode 100644 .project/concepts/e2e-harness/_debt.md delete mode 100644 .project/concepts/sign-in/_debt.md diff --git a/.project/concepts/e2e-harness/_debt.md b/.project/concepts/e2e-harness/_debt.md deleted file mode 100644 index 0803289..0000000 --- a/.project/concepts/e2e-harness/_debt.md +++ /dev/null @@ -1,10 +0,0 @@ -# Doc-debt — e2e-harness - -> Presence of a block = doc to update. Processed → delete the block; no blocks left → delete this file. -> One block = one "big change": `why` + `files` + `verify` (leaves to review). - -## Raw markers (consolidate into blocks, then delete) -- TOUCHED packages/polyfill/e2e/run.ts @2026-08-12 (session f93872b5-293a-4916-a353-181409a96d42) -- TOUCHED packages/polyfill/e2e/polyfill-entry.ts @2026-08-12 (session f93872b5-293a-4916-a353-181409a96d42) -- TOUCHED packages/polyfill/e2e/notebook.ts @2026-08-12 (session f93872b5-293a-4916-a353-181409a96d42) -- TOUCHED packages/polyfill/e2e/probe-frame-check.ts @2026-08-12 (session f93872b5-293a-4916-a353-181409a96d42) diff --git a/.project/concepts/sign-in/_debt.md b/.project/concepts/sign-in/_debt.md deleted file mode 100644 index ef55021..0000000 --- a/.project/concepts/sign-in/_debt.md +++ /dev/null @@ -1,7 +0,0 @@ -# Doc-debt — sign-in - -> Presence of a block = doc to update. Processed → delete the block; no blocks left → delete this file. -> One block = one "big change": `why` + `files` + `verify` (leaves to review). - -## Raw markers (consolidate into blocks, then delete) -- TOUCHED packages/polyfill/src/shared-wallet/access-gate.ts @2026-08-12 (session f93872b5-293a-4916-a353-181409a96d42) diff --git a/.project/concepts/sign-in/knowledge_how-a-user-gets-in.md b/.project/concepts/sign-in/knowledge_how-a-user-gets-in.md index a28213f..633dc73 100644 --- a/.project/concepts/sign-in/knowledge_how-a-user-gets-in.md +++ b/.project/concepts/sign-in/knowledge_how-a-user-gets-in.md @@ -15,6 +15,18 @@ Then the page is handed to the broker, which opens the wallet and reloads the ap What is genuinely ours is the one thing `init()` cannot do: **put the identifier into the URL before `init()` reads it**. `init()` hands over `window.location.href`; it does not know the parameter exists. +## When the `barrier` shows, and why it is not a question of identity + +**Top-level: always. Inside the broker iframe: never** — there the identifier arrives in the URL and the page stands aside. + +The discriminator is the frame, not whether an identity is known, and the difference is not ergonomic. An identity is state we can observe; whether the person still has a wallet in this browser is state we cannot — it lives in another origin's storage. A screen that decides on the identity is therefore *guessing* at the state that matters, and when it guesses "already set up" while NextGraph's side is gone, it hides the only controls that could repair the situation. + +What that costs is not a degraded experience but a dead end: sent to the broker without a wallet, the person lands on a static page carrying **no return path to the application**. The browser's Back button is the only way out, and it only helps if the `barrier` is there to catch them on arrival. + +A known identifier therefore **prefills the field; it never skips the screen**. And nothing detects whether the wallet is already there: all steps are always shown, and whoever already has one ignores them. No checkbox, no "I already have it" — knowing whether you imported a wallet into this browser is not something a person can be asked. + +Two facts, observed on the live sites, close the alternatives: clicking the wallet application's import control opens a file chooser **in place** — no navigation, no new tab; and our own page receives **no signal at all** when the import succeeds (no opener, no message, no storage or focus event, no reload). Detecting the return is impossible, not merely fragile. + ## Why the identifier travels by URL The flow runs in **two contexts with separate storage partitions** — the top-level page and the broker iframe — because browsers partition storage by top-level site. A value written top-level is not the value the iframe reads.