[PM-38154] feat: Add Passport view screen#2770
Conversation
Surface synced Passport ciphers in the vault list and search, gated behind the pm-32009-new-item-types feature flag, mirroring the Driver's License integration: passport group filtering, id-card icon, type-section row, and the Copy passport number overflow action. Add/Edit/View screens remain stubbed pending PM-38153/PM-38154.
Adds the add/edit SwiftUI surface for Passport items: 13 fields in the Figma order, with passport number and national identification number as hidden fields with reveal toggles, and date of birth, issue date, and expiration date rendered read-only (long localized display, raw ISO round-trip) pending the shared DateFieldPicker (PM-38360). Exposes Passport in the add-item picker gated behind the newItemTypes flag, injects ConfigService into VaultRepository for that gating, wires the state to SDK PassportView round-trip, and shows the add-item FAB on the Passports group screen.
Wire passport through both response-model BitwardenSdk.Cipher inits so a synced passport's fields survive sync-to-store and populate the edit form.
Adds the read-only detail view for passport items, rendering the passport details section: given name, surname, dates, sex, birth place, nationality, issuing country/authority, and passport type. The passport number and national identification number are masked with reveal toggles; the name and number fields support copy. Wires the view into the per-type dispatch in ViewItemDetailsView.
…ssport-view # Conflicts: # BitwardenResources/Localizations/en.lproj/Localizable.strings # BitwardenShared/Core/Vault/Models/Enum/CipherType.swift # BitwardenShared/Core/Vault/Models/Enum/CipherTypeTests.swift # BitwardenShared/UI/Vault/PreviewContent/BitwardenSdk+VaultFixtures.swift # BitwardenShared/UI/Vault/Vault/VaultGroup/VaultGroupState.swift # BitwardenShared/UI/Vault/VaultItem/AddEditItem/AddEditPassportItem/AddEditPassportItemState.swift # BitwardenShared/UI/Vault/VaultItem/AddEditItem/AddEditPassportItem/PassportItemState.swift # BitwardenShared/UI/Vault/VaultItem/CipherItemStateTests.swift # BitwardenShared/UI/Vault/VaultItem/ViewItem/ViewItemAction.swift # BitwardenShared/UI/Vault/VaultItem/ViewItem/ViewItemActionTests.swift # BitwardenShared/UI/Vault/VaultItem/ViewItem/ViewItemProcessorTests.swift
🤖 Bitwarden Claude Code ReviewOverall Assessment: APPROVE Reviewed the read-only passport detail view added for passport vault items, including the new Code Review DetailsNo findings at or above the reporting threshold. The processor's Existing review threads (build artifacts, private-view docs, moving section-empty into state, test alphabetization) are already addressed by the author or are active human-reviewer discussions, so no duplicate comments were posted. |
| @@ -0,0 +1,29 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | |||
There was a problem hiding this comment.
Details and fix
This PR adds the entire export/build.xcresult/ bundle (binary Data/* blobs plus this Info.plist). These are Xcode test/build result artifacts that should not be tracked in git — they bloat the repository and history permanently, and are unrelated to the passport view feature.
Fix:
git rm -r --cached export/and remove the directory from the commit- Add
export/(or*.xcresult) to.gitignoreso it cannot be re-added accidentally
Confirmed these paths do not exist on origin/main and are not currently covered by .gitignore.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2770 +/- ##
==========================================
+ Coverage 87.93% 87.94% +0.01%
==========================================
Files 1728 1741 +13
Lines 168727 170489 +1762
==========================================
+ Hits 148365 149938 +1573
- Misses 20362 20551 +189 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-38154
📔 Objective
Adds the read-only detail view for passport vault items. The passport details section renders given name, surname, date of birth, sex, birth place, nationality, passport number, passport type, national identification number, issuing country, issuing authority/office, issue date, and expiration date. Each field is hidden when empty, and the section is hidden entirely when the passport has no details.
The passport number and national identification number are masked with a reveal toggle; the name and number fields support copy to clipboard.
📸 Screenshots