You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Import today stops at aggregate counts in a confirm modal (previewImportMerge → ImportMergeReport with added/updated/unchanged/removed per entity type). Operators cannot see which channels, zones, contacts, talk groups, or RX group lists will land in the project, what field-level changes merge would apply, or what normalisation decisions the adapter made before merge.
Flow
Today
Gap
New project (Home → ImportDropzone)
Parses files and creates project immediately
No preview step; no continue/cancel
Active project (ImportIntoActivePanel on Import & export)
Modal with file summary + count lines
No per-entity list; no field diff; no visibility into merge heuristics
#58 shipped merge/overwrite with a lightweight confirm modal and explicitly deferred field-level diffs to a follow-up. This ticket is that follow-up, expanded to both import entry points and future import normalisation features.
Intended outcome
A dedicated import preview step in the import workflow — a route or full-page panel (not only a modal) — that runs before any codeplug is created or mutated. The operator reviews what will happen, then continues or cancels.
Preview content (all adapters)
For the selected vendor format / adapter, show a structured preview of the parsed import result before apply:
Section
Contents
Files
Recognised, skipped, and error files (existing ImportResult messages)
Channels
List of channels to import — name, mode, frequencies, key refs
Zones
Zone names + member channel names (resolved where possible)
Contacts / talk groups / RX group lists
Names and membership summaries
Warnings
Unresolved zone members, parse warnings, profile-specific notes
Adapter-agnostic UI: entity shapes come from internal ImportResult / parsed models, not vendor column names in the preview layer.
Normalisation decisions (show when applicable)
When import adapters apply best-effort collapse heuristics, the preview must surface what was decided — not silently merge:
New codeplug from import (Home) — after parse, navigate to preview with parsed payload in session/state; Continue creates the project; Cancel returns without side effects.
Merge / overwrite (Import & export) — after parse + mode selection, navigate to preview showing diff vs active codeplug; Continue calls applyImportToActive; Cancel discards pending import.
Replace or supersede the current ImportIntoActivePanel confirm modal with the preview page (modal may remain for trivial no-change cases if desired).
UX notes
Preview is read-only — no inline editing of import rows in v1.
Group by entity type; filter/search for large codeplugs.
Show merge mode (merge vs overwrite) prominently on active-project preview.
"No changes" path: short message + Close (idempotent re-import).
Affected
New route e.g. /import/preview (or nested under home / import-export) + page component
Builds on#58 (active import + previewImportMerge) and #7 (adapter registry).
Pairs with#46 and #36 — preview must expose their merge/collapse decisions when those features ship; design the ImportDecision shape now so adapters can populate it incrementally.
Vendor boundaries: diff compares internal model fields; wire column names stay in adapter/reference docs only.
Privacy: parsed import stays in browser memory / session until Continue; never commit operator exports.
Out of scope
Editing import rows on the preview page (change in CRUD after import instead).
Three-way merge or conflict resolution UI (imported values win on update).
Undo after Continue (operator re-imports a backup).
Export preview (separate concern).
Workflow note
Branch from origin/main, atomic conventional commits (preview data layer → page UI → wire Home + active flows → tests/docs), PR linking Closes #N. Pair with docs/features / progress-tracking skills for multi-slice work.
Problem
Import today stops at aggregate counts in a confirm modal (
previewImportMerge→ImportMergeReportwith added/updated/unchanged/removed per entity type). Operators cannot see which channels, zones, contacts, talk groups, or RX group lists will land in the project, what field-level changes merge would apply, or what normalisation decisions the adapter made before merge.ImportDropzone)ImportIntoActivePanelon Import & export)#58 shipped merge/overwrite with a lightweight confirm modal and explicitly deferred field-level diffs to a follow-up. This ticket is that follow-up, expanded to both import entry points and future import normalisation features.
Intended outcome
A dedicated import preview step in the import workflow — a route or full-page panel (not only a modal) — that runs before any codeplug is created or mutated. The operator reviews what will happen, then continues or cancels.
Preview content (all adapters)
For the selected vendor format / adapter, show a structured preview of the parsed import result before apply:
ImportResultmessages)Adapter-agnostic UI: entity shapes come from internal
ImportResult/ parsed models, not vendor column names in the preview layer.Normalisation decisions (show when applicable)
When import adapters apply best-effort collapse heuristics, the preview must surface what was decided — not silently merge:
GB7GL+GB7GL DMR→ one multi-mode channel (FM + DMR)" or "Left as 2 separate channels (ambiguous)"GB7XX TG235+GB7XX TG2351→ one logical channel with 2 talk groups"ImportMessagewith severity warning tied to a decisionDecisions belong in
ImportResult(or a siblingImportPreviewtype) at the import boundary — the UI only renders them.Merge / overwrite diff (active project only)
When importing into an existing codeplug with merge or overwrite mode, show the diff that would be applied against the active project:
importEntityComparedetects inequality)Reuse / extend
previewImportMergeandimportEntityCompare.tsto return entity-level change lists, not onlyEntityImportStatsaggregates.For overwrite, clearly warn which entire entity arrays will be replaced (existing behaviour) and list removed names.
Workflow integration
applyImportToActive; Cancel discards pending import.Replace or supersede the current
ImportIntoActivePanelconfirm modal with the preview page (modal may remain for trivial no-change cases if desired).UX notes
Affected
/import/preview(or nested under home / import-export) + page componentsrc/lib/importMerge.ts— extend preview to return entity-level diffssrc/lib/importEntityCompare.ts— optional field-level diff helpersrc/lib/import/types.ts—ImportDecision/ normalisation notes from adapterssrc/components/ImportDropzone/— defer apply; hand off to previewsrc/components/ImportIntoActivePanel/— wire preview page instead of modal-only flowsrc/state/codeplugStore.tsx— pending import state (session or transient store slice)importWorkflow.ts)docs/features/import-export/README.md, component sidecarNotes / dependencies
previewImportMerge) and #7 (adapter registry).ImportDecisionshape now so adapters can populate it incrementally.Out of scope
Workflow note
Branch from
origin/main, atomic conventional commits (preview data layer → page UI → wire Home + active flows → tests/docs), PR linkingCloses #N. Pair withdocs/features/ progress-tracking skills for multi-slice work.