fix: improve export filename and import confirmation UX (#232)

Export filename:
- Include username for multi-user/instance distinction
- Include timestamp with time (YYYYMMDD-HHMM) instead of date only
- Example: medassist-export-daniel-20260216-2108.json

Import confirmation:
- Show friendly 'Import Data?' dialog on empty instances instead of
  scary 'Replace All Data?' warning with danger button
- Only show destructive warning when there is existing data to replace
- Use primary button style for empty-state import

Closes #231
This commit is contained in:
Daniel Volz
2026-02-16 22:20:20 +01:00
committed by GitHub
parent e41efdf98b
commit 08a18fc14a
6 changed files with 30 additions and 10 deletions
@@ -86,6 +86,7 @@ const createMockContext = (overrides = {}) => ({
handleImportConfirm: vi.fn(),
importResult: null,
setImportResult: vi.fn(),
meds: [],
...overrides,
});