Skip to content

[PM-32810] feat: Add Bank Account vault, listing, and search surfaces#6877

Merged
SaintPatrck merged 3 commits intomainfrom
new-item-types/PM-32810_bank-account-discovery
May 7, 2026
Merged

[PM-32810] feat: Add Bank Account vault, listing, and search surfaces#6877
SaintPatrck merged 3 commits intomainfrom
new-item-types/PM-32810_bank-account-discovery

Conversation

@SaintPatrck
Copy link
Copy Markdown
Contributor

🎟️ Tracking

PM-32810

Stacked parent: #6875

📔 Objective

Surface Bank Account ciphers across the discovery surfaces — the My Vault group list, the dedicated Bank Account listing screen, and search — and add overflow copy actions for account number and routing number. Pairs with the detail-screen slice in #6875 to complete the read-only Bank Account experience.

📸 Screenshots

@SaintPatrck SaintPatrck requested review from a team and david-livefront as code owners May 6, 2026 14:03
@github-actions github-actions Bot added app:password-manager Bitwarden Password Manager app context app:authenticator Bitwarden Authenticator app context t:feature Change Type - Feature Development labels May 6, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 6, 2026

Codecov Report

❌ Patch coverage is 69.94819% with 58 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.72%. Comparing base (7fd63f7) to head (8539dfb).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...ure/itemlisting/model/ListingItemOverflowAction.kt 0.00% 12 Missing ⚠️
...bitwarden/ui/vault/feature/vault/VaultViewModel.kt 85.00% 2 Missing and 7 partials ⚠️
...rden/ui/platform/feature/search/SearchViewModel.kt 66.66% 1 Missing and 7 partials ⚠️
...t/feature/itemlisting/VaultItemListingViewModel.kt 68.18% 1 Missing and 6 partials ⚠️
...rm/feature/search/util/SearchTypeDataExtensions.kt 0.00% 3 Missing and 1 partial ⚠️
...itemlisting/util/VaultItemListingDataExtensions.kt 60.00% 2 Missing and 2 partials ⚠️
...temlisting/util/VaultItemListingStateExtensions.kt 0.00% 2 Missing and 2 partials ⚠️
...den/ui/platform/feature/search/SearchNavigation.kt 25.00% 3 Missing ⚠️
.../feature/itemlisting/VaultItemListingNavigation.kt 25.00% 3 Missing ⚠️
...ui/vault/feature/vault/util/VaultDataExtensions.kt 84.61% 0 Missing and 2 partials ⚠️
... and 2 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6877      +/-   ##
==========================================
+ Coverage   85.08%   85.72%   +0.63%     
==========================================
  Files         948      843     -105     
  Lines       62720    60719    -2001     
  Branches     8909     8915       +6     
==========================================
- Hits        53368    52049    -1319     
+ Misses       6302     5606     -696     
- Partials     3050     3064      +14     
Flag Coverage Δ
app-data 17.51% <0.00%> (+0.24%) ⬆️
app-ui-auth-tools 19.84% <0.00%> (-0.37%) ⬇️
app-ui-platform 15.71% <13.33%> (-0.19%) ⬇️
app-ui-vault 26.27% <65.00%> (-0.43%) ⬇️
authenticator 6.47% <0.00%> (-0.03%) ⬇️
lib-core-network-bridge 4.16% <0.00%> (-0.02%) ⬇️
lib-data-ui 1.00% <0.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@SaintPatrck SaintPatrck marked this pull request as draft May 6, 2026 14:28
@SaintPatrck SaintPatrck force-pushed the new-item-types/PM-32810_bank-account-discovery branch from 2411583 to 42bb0e7 Compare May 6, 2026 15:24
@SaintPatrck SaintPatrck force-pushed the new-item-types/PM-32810_bank-account-view branch from 3797c7d to bfcd3f6 Compare May 6, 2026 15:38
Base automatically changed from new-item-types/PM-32810_bank-account-view to main May 6, 2026 16:16
@SaintPatrck SaintPatrck force-pushed the new-item-types/PM-32810_bank-account-discovery branch from 42bb0e7 to 43c1cf8 Compare May 6, 2026 17:14
@SaintPatrck SaintPatrck added ai-review-vnext Request a Claude code review using the vNext workflow and removed app:authenticator Bitwarden Authenticator app context labels May 6, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 6, 2026

🤖 Bitwarden Claude Code Review

Overall Assessment: APPROVE

This PR adds Bank Account discovery surfaces (My Vault group, dedicated listing, search) and copy actions for account/routing numbers, gated behind the NewItemTypes feature flag. The implementation mirrors the existing SSH key surfaces and follows the established UDF/State-Action patterns in VaultViewModel, VaultItemListingViewModel, and SearchViewModel. Test coverage is comprehensive across all added overflow actions, listing states, and the new vault group rendering. The earlier reviewer feedback (feature-flag gating, named param, full-content test assertions, and reactive flag observation via state) appears addressed across commits 069f696e0 and 8539dfb16.

Code Review Details

No actionable findings. Notable observations:

  • The new copy handlers (handleCopyAccountNumberClick, handleCopyRoutingNumberClick) use takeIf { it.isNotBlank() } to avoid copying empty strings — a slight improvement over the existing CopyNumberClick which writes .orEmpty() unconditionally.
  • CipherListViewType.BankAccount icon switched from ic_note to ic_payment_card, matching the existing detail-screen mapping in CipherViewExtensions.kt and the Card listing icon.
  • handleNewItemTypesFlagUpdateReceive re-runs updateVaultState on flag change so showBankAccountGroup reflects the latest flag value without waiting for the next vault data emission.

@SaintPatrck SaintPatrck force-pushed the new-item-types/PM-32810_bank-account-discovery branch from 43c1cf8 to 69ab81c Compare May 6, 2026 17:42
@github-actions github-actions Bot added the app:authenticator Bitwarden Authenticator app context label May 6, 2026
@SaintPatrck SaintPatrck marked this pull request as ready for review May 6, 2026 17:48
}
}

item(key = "bank_accounts_group") {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should something like this be behind a feature flag?

override val id: String,
override val name: Text,
override val startIcon: IconData = IconData.Local(
BitwardenDrawable.ic_payment_card,
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor but can you add a name to this param

)

val content = actual as VaultState.ViewState.Content
assertEquals(2, content.bankAccountItemsCount)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we assert the full content like the other tests.

…faces

Surfaces Bank Account ciphers in the My Vault group list, the dedicated
listing screen, and search, including overflow copy actions for account
and routing numbers.
Hides the My Vault Bank Account group when the NewItemTypes feature
flag is off, matching the gating already applied to the add-item
type selector. Also names the BankAccount startIcon param and
expands the bank-account toViewState test to assert full Content.
@SaintPatrck SaintPatrck force-pushed the new-item-types/PM-32810_bank-account-discovery branch from 31f0fe7 to 069f696 Compare May 7, 2026 15:16
isRefreshing = false,
restrictItemTypesPolicyOrgIds = state.restrictItemTypesPolicyOrgIds,
validTotpIds = validTotpIds,
isNewItemTypesEnabled = featureFlagManager.getFeatureFlag(FlagKey.NewItemTypes),
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Normally we would put this on the state and observe realtime change to the flag.

Subscribes to FlagKey.NewItemTypes via getFeatureFlagFlow so changes
propagate reactively, mirroring the existing CredentialExchangeProtocolExport
pattern. Adds isNewItemTypesEnabled to VaultState; toViewState callers
and the add-item-type selector read from state. The flag handler also
re-runs updateVaultState so showBankAccountGroup reflects the latest
flag value without waiting for the next vault data emission.

Also adds showBankAccountGroup = true to the two VaultScreenTest cases
that exercise the bank account group, since the fixture default is
now false.
@SaintPatrck
Copy link
Copy Markdown
Contributor Author

Thanks @david-livefront

@SaintPatrck SaintPatrck added this pull request to the merge queue May 7, 2026
Merged via the queue into main with commit a9cc18e May 7, 2026
24 checks passed
@SaintPatrck SaintPatrck deleted the new-item-types/PM-32810_bank-account-discovery branch May 7, 2026 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-review-vnext Request a Claude code review using the vNext workflow app:authenticator Bitwarden Authenticator app context app:password-manager Bitwarden Password Manager app context t:feature Change Type - Feature Development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants