Das Bildschirmdesign
Original herunterladen ↓CRM-142: Bildschirmdesign
Nur Text-Wireframe; kein Laufzeitscreenshot und keine implementierte Funktion.
Contacts [Import contacts]
Keep your customer contacts in one place.
┌ Import contacts ────────────────────────────────────┐
│ CSV stays in this browser. │
│ Maximum 100 KB (100,000 bytes), 500 nonblank records.│
│ Required columns: name, email. Optional: company. │
│ CSV file [Choose file] customer-contacts.csv │
│ [Review CSV] [Back to contacts] │
│ Review: Ready 3 · Invalid 1 · Duplicate 2 │
│ Record 1 · Jordan Lee · jordan@example.test │
│ Company: Fieldwork, Inc. · Ready │
│ …all six records, each with outcome/reason… │
│ [ ] Fail next save │
│ [Import ready contacts] [Cancel import] │
└────────────────────────────────────────────────────┘
Search contacts [Name, email or company]
[Live status]
[Existing contact cards]
▸ Add contact
Import contacts öffnet das Panel und fokussiert CSV file. Review CSV ist ohne ausgewählte Datei und während des Lesens deaktiviert. Nutze accept=".csv,text/csv" als Auswahlhinweis, nicht als Validierung. Dateiauswahl setzt Fehler/Anzahlen/Vorschau zurück und erlaubt erneute Auswahl derselben Datei. Prüfung ist ein ausdrücklicher lokaler Lesevorgang; sie schreibt nichts. Lesestatus anzeigen, dann Prüfüberschrift fokussieren (tabindex="-1") und Anzahlen über das bestehende #statusankündigen. Ein verspätetes Leseergebnis darf keine neuere Auswahl ersetzen oder ein abgebrochenes Panel wieder öffnen.
Für samples/customer-contacts.csv gegenüber initialContacts von src/contacts.js:
| Datensatz | Name | Ergebnis / sichtbarer Grund |
|---|---|---|
| 1 | Jordan Lee | Ready |
| 2 | Alex Duplicate | Duplicate: Email already in Contacts. |
| 3 | Missing Email | Invalid: Enter a valid email. |
| 4 | Casey "CJ" Kim | Ready |
| 5 | Jordan Again | Duplicate: Email repeats earlier valid record 1. |
| 6 | <img src=x onerror=alert(1)> | Ready; display literal text |
Zeige für jeden Datensatz getrimmte Werte von name, email und company; fehlendes company zeigt „: “. Gründe umfassen auch „Name is required.“ und kombinierte Fehler für fehlenden Namen/ungültige E-Mail. Zitierte eingebettete Zeilenumbrüche bleiben mit pre-wrap lesbar. Keine Zeilenbearbeitung in der App: „Fix invalid rows in your CSV and choose the file again.“ Strukturfehler zeigen etwa „Unclosed quote in record 2. Nothing imported.“ und deaktivieren die Bestätigung. Grenzen und fehlende/doppelte Header erhalten ebenso konkrete Meldungen.
Bestätigungstext: „Import 3 ready contacts; skip 3 invalid or duplicate records.“ Der zugängliche Buttonname bleibt Import ready contacts; bei null Ready-Zeilen oder beim Speichern deaktivieren. Kein zusätzliches Bestätigungsmodal. Beim Speichern „Saving contacts…“ anzeigen und Datei-/Prüf-/Abbruch-/Hinzufügen-Änderungen verhindern. Bei Fehler alle Vorschaudaten erhalten, Bestätigung fokussieren und „Could not save contacts. Try again.“ ankündigen. Bestätigungsbeschriftung für den neuen Versuch erhalten. Fail next save aktiviert genau einen tatsächlichen Speicherversuch (Add oder Import), setzt sich bei Verbrauch zurück und reicht die fail-Option des Adapters weiter; es löscht keine Kontakte.
Nach erfolgreichem Beispielimport im frischen Browser: „Added 3 contacts; skipped 3 records.“ Panel schließen, Suche zum Anzeigen importierter Kontakte leeren, insgesamt fünf Kontakte rendern und Import contacts fokussieren. Tatsächliche Anzahlen können nach erneuter Validierung abweichen. Cancel/Back fokussieren Import contacts und melden „Import cancelled. Contacts unchanged.“ Sie leeren die Suche nicht.
Alle Bedienelemente haben Beschriftungen, native Button-/Checkbox-Semantik und logische DOM-Tab-Reihenfolge; Enter aktiviert Buttons, Space schaltet die Demo-Checkbox. Bestehenden sichtbaren Fokusring beibehalten. Keine Fokusfalle. Bei 320px eine Spalte, umbrechende Aktionen, begrenztes Dateifeld und Umbruch langer E-Mails/Texte verwenden; Karten behalten sichtbare Feldbeschriftungen und Ergebnistexte, nie nur Farbe. Am Desktop bestehende 1050px-Inhaltsbreite und breitere Kartenfelder beibehalten. Kein horizontaler Seitenscroll. Tastatur-, 320px- und Desktop-Prüfungen sind geplant, nicht ausgeführt.
Originaldatei & Quelldetails
output/docs/screen-design.md.txt · SHA-256 c2b1dc590b78cce4048445b09ac398e19d11c1bef1b9b255b3a71aeb91e48cd0
# CRM-142 screen design
Text wireframe only; no runtime screenshot or implemented feature.
```text
Contacts [Import contacts]
Keep your customer contacts in one place.
┌ Import contacts ────────────────────────────────────┐
│ CSV stays in this browser. │
│ Maximum 100 KB (100,000 bytes), 500 nonblank records.│
│ Required columns: name, email. Optional: company. │
│ CSV file [Choose file] customer-contacts.csv │
│ [Review CSV] [Back to contacts] │
│ Review: Ready 3 · Invalid 1 · Duplicate 2 │
│ Record 1 · Jordan Lee · jordan@example.test │
│ Company: Fieldwork, Inc. · Ready │
│ …all six records, each with outcome/reason… │
│ [ ] Fail next save │
│ [Import ready contacts] [Cancel import] │
└────────────────────────────────────────────────────┘
Search contacts [Name, email or company]
[Live status]
[Existing contact cards]
▸ Add contact
```
`Import contacts` opens the panel and focuses `CSV file`. `Review CSV` is disabled without a selected file and while reading. Use `accept=".csv,text/csv"` as a chooser hint, not validation. File selection resets errors/counts/preview and permits reselecting the same file. Review is an explicit local read; it writes nothing. Show reading status, then focus the review heading (`tabindex="-1"`) and announce counts through existing `#status`. A stale read result must not replace a newer selection or reopen a cancelled panel.
For `samples/customer-contacts.csv` against `initialContacts` from `src/contacts.js`:
| Record | Name | Outcome / visible reason |
| --- | --- | --- |
| 1 | Jordan Lee | Ready |
| 2 | Alex Duplicate | Duplicate — Email already in Contacts. |
| 3 | Missing Email | Invalid — Enter a valid email. |
| 4 | Casey "CJ" Kim | Ready |
| 5 | Jordan Again | Duplicate — Email repeats earlier valid record 1. |
| 6 | `<img src=x onerror=alert(1)>` | Ready; display literal text |
Display every record's trimmed name, email and company; absent company shows “—”. Reasons also cover “Name is required.” and combined missing-name/invalid-email errors. Quoted embedded newlines remain readable with pre-wrap. No in-app row editing: “Fix invalid rows in your CSV and choose the file again.” Structural errors show e.g. “Unclosed quote in record 2. Nothing imported.” and disable confirmation. Limits and missing/duplicate headers have similarly specific messages.
Confirmation copy: “Import 3 ready contacts; skip 3 invalid or duplicate records.” Button accessible name stays `Import ready contacts`; disable when Ready is zero or saving. No additional confirmation modal. While saving show “Saving contacts…” and prevent file/review/cancel/add mutations. On failure keep all preview data, focus confirmation and announce “Could not save contacts. Try again.” Keep the confirmation label for retry. `Fail next save` arms one actual save attempt (Add or Import), resets when consumed, and passes the adapter's fail option; it does not clear contacts.
After successful sample import in a fresh browser: “Added 3 contacts; skipped 3 records.” Close panel, clear search to expose imported contacts, render five total contacts, focus Import contacts. Actual counts may differ after revalidation. Cancel/Back focus Import contacts and announce “Import cancelled. Contacts unchanged.” They do not clear the search.
All controls have labels, native buttons/checkbox semantics and logical DOM tab order; Enter activates buttons, Space toggles the demo checkbox. Retain the existing visible focus ring. No focus trap. At 320px use a single column, wrap actions, constrain file input, and break long emails/text; cards retain visible field labels and outcome text (never color alone). At desktop keep the existing 1050px content width and use wider card fields. No horizontal page scroll. Keyboard, 320px and desktop checks are planned, not executed.