From 7238b12b057101807723e37034f0854659874bbc Mon Sep 17 00:00:00 2001 From: m Date: Fri, 8 May 2026 23:03:52 +0200 Subject: [PATCH] feat(fristenrechner): Step 2 third card "Verfahrensablauf einsehen" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit t-paliad-168 deliverable 1. Adds a discoverable browse-/learn-mode entry to the determinator alongside "Etwas einreichen" / "Etwas ist passiert". Click drops straight into Pathway A's proceeding-tile picker (navigateToPathway("a")). The save-to-project CTA disables itself in this mode — extends isAdhocMode() to also return true when no Step 1 context is set, mirroring the existing ad-hoc explore behaviour. i18n keys: deadlines.step2.browse.title / .desc (DE + EN). --- frontend/src/client/fristenrechner.ts | 12 +++++++++++- frontend/src/client/i18n.ts | 6 ++++++ frontend/src/fristenrechner.tsx | 14 ++++++++++++++ 3 files changed, 31 insertions(+), 1 deletion(-) diff --git a/frontend/src/client/fristenrechner.ts b/frontend/src/client/fristenrechner.ts index ae441ef..4327c40 100644 --- a/frontend/src/client/fristenrechner.ts +++ b/frontend/src/client/fristenrechner.ts @@ -2490,8 +2490,12 @@ function writeStep1ContextToURL(ctx: Step1Context, replace = false) { // isAdhocMode is read by the save-to-project CTA — ad-hoc has no // project to save against, so the CTA disables and renders a hint. +// t-paliad-168: also true when no Step 1 context is set at all (the +// "Verfahrensablauf einsehen" / sidebar deep-link browse path opens +// Pathway A without an Akte). In both cases the user has no project +// to save against; the CTA renders disabled with the same hint. function isAdhocMode(): boolean { - return currentStep1Context.kind === "adhoc"; + return currentStep1Context.kind === "adhoc" || currentStep1Context.kind === "none"; } function adhocSummaryLabel(forum: AdhocForum): string { @@ -2705,6 +2709,12 @@ function initPathwayFork() { document.getElementById("fristen-step2-happened")?.addEventListener("click", () => { navigateToPathway("b", "tree"); }); + // t-paliad-168 — Verfahrensablauf einsehen (browse / learn). Drops + // straight into Pathway A's proceeding-tile picker. The save CTA + // disables itself in this mode (see isBrowseOrAdhocMode below). + document.getElementById("fristen-step2-browse")?.addEventListener("click", () => { + navigateToPathway("a"); + }); // Step 3a cards — File / Draft / Enter. File drops into the existing // Pathway A wizard; Enter routes to the manual-create form; diff --git a/frontend/src/client/i18n.ts b/frontend/src/client/i18n.ts index eea566a..f2b8650 100644 --- a/frontend/src/client/i18n.ts +++ b/frontend/src/client/i18n.ts @@ -21,6 +21,7 @@ const translations: Record> = { "nav.home": "Home", "nav.kostenrechner": "Kostenrechner", "nav.fristenrechner": "Fristenrechner", + "nav.verfahrensablauf": "Verfahrensablauf", "nav.downloads": "Downloads", "nav.links": "Links", "nav.glossar": "Glossar", @@ -263,6 +264,8 @@ const translations: Record> = { "deadlines.step2.file.desc": "Outgoing — eine Frist tritt aus eigener Handlung ein.", "deadlines.step2.happened.title": "Etwas ist passiert", "deadlines.step2.happened.desc": "Incoming — ein Ereignis hat eine Frist ausgelöst.", + "deadlines.step2.browse.title": "Verfahrensablauf einsehen", + "deadlines.step2.browse.desc": "Browse / Learn — sehen, was wann passiert. Keine Frist eintragen.", "deadlines.save.cta.adhoc.hint": "Ad-hoc — kein Projekt, kein Speichern", "deadlines.step3a.heading": "Was möchten Sie einreichen?", "deadlines.step3a.back": "zurück zur Auswahl", @@ -2233,6 +2236,7 @@ const translations: Record> = { "nav.home": "Home", "nav.kostenrechner": "Cost Calculator", "nav.fristenrechner": "Deadline Calculator", + "nav.verfahrensablauf": "Procedure Roadmap", "nav.downloads": "Downloads", "nav.links": "Links", "nav.glossar": "Glossary", @@ -2472,6 +2476,8 @@ const translations: Record> = { "deadlines.step2.file.desc": "Outgoing — your action triggers a deadline.", "deadlines.step2.happened.title": "Something happened", "deadlines.step2.happened.desc": "Incoming — an event triggered a deadline.", + "deadlines.step2.browse.title": "Browse procedure roadmap", + "deadlines.step2.browse.desc": "Browse / Learn — see what happens when. No deadline entered.", "deadlines.save.cta.adhoc.hint": "Ad-hoc — no matter, no save", "deadlines.step3a.heading": "What do you want to file?", "deadlines.step3a.back": "back to selection", diff --git a/frontend/src/fristenrechner.tsx b/frontend/src/fristenrechner.tsx index d247fa0..547c211 100644 --- a/frontend/src/fristenrechner.tsx +++ b/frontend/src/fristenrechner.tsx @@ -207,6 +207,20 @@ export function renderFristenrechner(): string { Incoming — ein Ereignis hat eine Frist ausgelöst. + {/* t-paliad-168 — third card: discoverable browse-/learn-mode + entry. Drops directly into Pathway A (Verfahrensablauf + wizard) with no save flow — mirrors the existing ad-hoc + explore behaviour: timeline renders, save CTA stays + disabled because there's no save intent. */} +