feat(import): the import theater during SIE execute (#1471)
* feat(onboarding): branch question on the journey done screen Second slice of the approved activation concept: the moment the company exists, the done screen asks "Var fanns bokföringen innan?" with provider chips (real logos), SIE file, and new-business options, plus a quiet look-around escape. Choices persist initial_setup_path (fire-and-forget) and deep-link into the existing flows: providers jump straight to the migration wizard's connect step (sieViaApi providers only; Visma/Bokio land on the provider list where the SIE-first gate lives), the SIE chip opens the upload step, new business lands on Hem with step one checked off. mode='add' keeps the plain "Öppna Accounted" button: the concept's own guard, and it avoids writing the path onto the previous company if setActiveCompany silently failed. Routing lives in a pure helper with tests; anonymous onboarding_branch_chosen funnel event follows the guarded capture pattern. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * fix(onboarding): review triage: single-choice latch, preselect reset Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * fix: restore package-lock.json to main (worktree npm install mutated it) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * feat(import): the import theater: a knowledge graph draws itself during SIE execute Third slice of the activation concept. While the SIE import commits server-side (one opaque call, up to ~5 min), the client parses the same file locally (the parser is browser-clean) and a canvas constellation builds itself: company hub, fiscal years as tree rings, account-class anchors, top accounts and recognized counterparties, with paced narration lines alongside. The final line holds with the elapsed counter until the server answers, so the theater never outruns the truth. - lib/import/theater-model.ts: pure aggregation of ParsedSIEFile into a capped display model (14 accounts, 12 counterparties, >=2 sightings, internal accounting texts skipped, counterparty attached to its counter account rather than the bank leg). Tested with fixture-string SIE per the sie-parser test pattern. - components/import/ImportTheater.tsx: ink-on-paper canvas + narration, tokens read per frame (theme/palette reactive, JourneyOrb idiom), reduced motion renders the settled graph and all lines instantly. - Wizard: client parse kicks off at execute start via dynamic import, capped at 8 MB; any failure silently leaves the existing spinner takeover, which also remains for oversized files. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> --------- Co-authored-by: Jakob Wennberg <311770904+jakobwennberg-oss@users.noreply.github.com> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
Jakob Wennberg
parent
622b144a3d
commit
d4ef4f8bc4
@@ -6486,6 +6486,18 @@
|
||||
"import": {
|
||||
"title": "Import / export",
|
||||
"subtitle": "Import bank transactions or bookkeeping data into your company",
|
||||
"theater_reading": "Reading {company}",
|
||||
"theater_years": "{count, plural, one {# fiscal year} other {# fiscal years}}",
|
||||
"theater_vouchers": "Reading the vouchers",
|
||||
"theater_vouchers_unit": "vouchers",
|
||||
"theater_accounts": "Mapping the chart of accounts to BAS 2026",
|
||||
"theater_accounts_sub": "{mapped} of {total} accounts",
|
||||
"theater_counterparties": "Recognizing counterparties",
|
||||
"theater_counterparties_sub": "{count, plural, one {# counterparty} other {# counterparties}}",
|
||||
"theater_balance": "Checking the balance",
|
||||
"theater_balance_ok": "Every year balances",
|
||||
"theater_balance_warn": "Imbalance found, see the warnings afterwards",
|
||||
"theater_writing": "Writing to the journal ...",
|
||||
"export_title": "Export",
|
||||
"export_subtitle": "Download your bookkeeping as a SIE file or back it up to Google Drive",
|
||||
"tab_import": "Import",
|
||||
|
||||
@@ -6486,6 +6486,18 @@
|
||||
"import": {
|
||||
"title": "Importera / exportera",
|
||||
"subtitle": "Importera banktransaktioner eller bokföringsdata till ditt företag",
|
||||
"theater_reading": "Läser {company}",
|
||||
"theater_years": "{count, plural, one {# räkenskapsår} other {# räkenskapsår}}",
|
||||
"theater_vouchers": "Verifikaten läses in",
|
||||
"theater_vouchers_unit": "verifikat",
|
||||
"theater_accounts": "Kontoplanen mappas mot BAS 2026",
|
||||
"theater_accounts_sub": "{mapped} av {total} konton",
|
||||
"theater_counterparties": "Motparter känns igen",
|
||||
"theater_counterparties_sub": "{count, plural, one {# motpart} other {# motparter}}",
|
||||
"theater_balance": "Kontrollerar balansen",
|
||||
"theater_balance_ok": "Varje år balanserar",
|
||||
"theater_balance_warn": "Obalans hittad, se varningarna efteråt",
|
||||
"theater_writing": "Skriver till journalen ...",
|
||||
"export_title": "Exportera",
|
||||
"export_subtitle": "Ladda ner bokföringen som SIE-fil eller säkerhetskopia till Google Drive",
|
||||
"tab_import": "Importera",
|
||||
|
||||
Reference in New Issue
Block a user