1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-06 00:13:28 +00:00
Commit Graph

392 Commits

Author SHA1 Message Date
Jordan Aasen
474ffa2ce1 [PM-25360] - allow item details name to be selectable (#17693)
* allow item details name to be selectable

* use tw class
2025-12-04 09:13:21 -08:00
Jeffrey Holland
cf416388d7 Fix stale data issue in new login popout (#17307)
* Fix stale data issue in new login popout

* Update the comments

* Address critical claude code bot suggestions

* Clean out all stale data from pop up

* Fix cached cipher issue

* Fix caching issue between tab and overlay flow

* Address claude comments
2025-12-03 09:46:40 +01:00
Nick Krantz
dd99190ca2 allow for archived ciphers to be shared into an organization (#17592) 2025-12-02 11:43:02 -06:00
Nik Gilmore
e694ab490c [PM-23562] Prevent closing dialog and window when uploading an attachment (#17287)
* Prevent users from cancelling an in-flight upload, and attempt to block them from closing the window.

* Add comment for deprecated event.returnValue
2025-12-01 12:50:13 -08:00
Vicki League
10424e227b [CL-717][PM-27966] Update to Angular 20 and Storybook 9 (#17638) 2025-12-01 14:15:58 -05:00
Bryan Cunningham
963a9156fb [CL-910] Use tooltip in title directive (#17084)
* use tooltip in a11y directive

* remove commented code

* add deprecation warning to appA11yTitle directive

* use label for tooltip in carousel nav

* wait for timeout before assertion

* remove unnecessary title directive use

* fix private variable lint errors

* increase tooltip show delay

* fix spec delay and export as constant

* use delay constant

---------

Co-authored-by: Vicki League <vleague@bitwarden.com>
2025-12-01 11:59:20 -05:00
Bryan Cunningham
540da69daf [CL-761] Enable strict template typechecking (#17334)
* enable strict template typechecking

* add callout component to module

* fixing popup action types

* fixing cipher item copy types

* fix archive cipher type

* fixing trash list items types

* fix remaining trash list item type errors

* use CipherViewLike as correct type

* change popup back directive to attribute selector

* allow undefined in popupBackAction handler

* Remove undefined from type

* fix error with firefox commercial build

---------

Co-authored-by: Vicki League <vleague@bitwarden.com>
2025-11-25 11:04:37 -05:00
Oscar Hinton
4c36a46ef2 Enable directive-class-suffix (#17385) 2025-11-24 18:03:16 +01:00
Oscar Hinton
9efc31534b [PM-28231] Enable component-class-suffix (#17384)
* Enable component-class-suffix

* Rename file
2025-11-18 13:26:38 +01:00
Nick Krantz
610537535a persist archive date when cloning a cipher (#16986) 2025-11-17 14:14:03 -06:00
Mark Youssef
a55d0f02f2 [CL-672] update mobile design of dialog (#14828)
---------

Co-authored-by: Vicki League <vleague@bitwarden.com>
2025-11-13 21:59:03 -05:00
SmithThe4th
519889f8f4 Persist ssh key changes when extension loses focus (#17267) 2025-11-07 10:54:04 -05:00
Vicki League
c404ee210b [PM-26984] Use medium instead of semibold or bold (#17191) 2025-11-06 11:27:46 -05:00
Nick Krantz
30af9425d8 prevent form status changes from triggering a valueChanges emission (#17181)
- previous data within the cipher can be overwritten by the initial form data
2025-11-06 08:28:05 -06:00
Shane Melton
60b16a796c [PM-27848] Undo OnPush change detection strategy change for CipherViewComponent (#17235) 2025-11-05 11:02:56 -08:00
Shane Melton
7e5f02f90c [PM-24469] Implement Risk Insights for Premium in Cipher view component (#17012)
* [PM-24469] Refactor CipherViewComponent to use Angular signals and computed properties for improved reactivity

* [PM-24469] Refactor CipherViewComponent to utilize Angular signals for organization data retrieval

* [PM-24469] Refactor CipherViewComponent to utilize Angular signals for folder data retrieval

* [PM-24469] Cleanup organization signal

* [PM-24469] Refactor CipherViewComponent to replace signal for card expiration with computed property

* [PM-24469] Improve collections loading in CipherViewComponent

* [PM-24469] Remove redundant loadCipherData method

* [PM-24469] Refactor CipherViewComponent to replace signal with computed property for pending change password tasks

* [PM-24469] Refactor LoginCredentialsViewComponent to rename hadPendingChangePasswordTask to showChangePasswordLink for clarity

* [PM-24469] Introduce showChangePasswordLink computed property for improved readability

* [PM-24469] Initial RI for premium logic

* [PM-24469] Refactor checkPassword risk checking logic

* [PM-24469] Cleanup premium check

* [PM-24469] Cleanup UI visuals

* [PM-24469] Fix missing typography import

* [PM-24469] Cleanup docs

* [PM-24469] Add feature flag

* [PM-24469] Ensure password risk check is only performed when the feature is enabled, and the cipher is editable by the user, and it has a password

* [PM-24469] Refactor password risk evaluation logic and add unit tests for risk assessment

* [PM-24469] Fix mismatched CipherId type

* [PM-24469] Fix test dependencies

* [PM-24469] Fix config service mock in emergency view dialog spec

* [PM-24469] Wait for decrypted vault before calculating cipher risk

* [PM-24469] startWith(false) for passwordIsAtRisk signal to avoid showing stale values when cipher changes

* [PM-24469] Exclude organization owned ciphers from JIT risk analysis

* [PM-24469] Add initial cipher-view component test boilerplate

* [PM-24469] Add passwordIsAtRisk signal tests

* [PM-24469] Ignore soft deleted items for RI for premium feature

* [PM-24469] Fix tests
2025-11-04 12:15:53 -08:00
Jordan Aasen
d364dfdda0 [PM-26182] - [Defect] [Browser] Safari - Autofill on page load default setting is missing yes or no (#16605)
* handle parenthesis translation

* add whitespace around placeholder with parentheses

* fix test

* fix label

* fix spec
2025-11-04 10:59:00 -08:00
Shane Melton
51a557514f [PM-20379] Fix At-risk password task permission bug (#17110)
* [PM-20379] Fix at risk password task permission checks

* [PM-20379] Fix at risk password component specs

* [PM-20379] Cleanup FIXMEs

* [PM-20379] Update to OnPush

* [PM-20379] Add tests for pendingTasks$

* [PM-20379] Reduce test boilerplate / redundancy

* [PM-20379] Cleanup as any

* [PM-20379] Remove redundant "should" language
2025-10-29 14:47:55 -07:00
Bryan Cunningham
5b815c4ae4 [CL-879] use tooltip on icon button (#16576)
* Add tooltip to icon button to display label

* remove legacy cdr variable

* create overlay on focus or hover

* attach describdedby ids

* fix type errors

* remove aria-describedby when not necessary

* fix failing tests

* implement Claude feedback

* fixing broken specs

* remove host attr binding

* Simplify directive aria logic

* Move id to statis number

* do not render empty tooltip

* pass id to tooltip component

* remove pointer-events none to allow tooltip on normal buttons

* exclude some tooltip stories

* change describedby input name

* add story with tooltip on regular button

* enhanced tooltip docs

* set model directly

* change model to input
2025-10-29 09:49:16 -04:00
Oscar Hinton
af6e19335d Vault - Prefer signal & change detection (#16947) 2025-10-27 11:13:11 -04:00
cyprain-okeke
b9f48d83b2 [PM 25897] Copy and UI Tweaks for Payment Method Component (#16851)
* Implement the Ui changes to align as expected

* Align the Text in card number, expiration date and security code vertically

* Change the Zip to ZIP

* Remove readonly modifier from signal declarations
2025-10-27 13:53:05 +01:00
Nik Gilmore
0ec3f661d5 [PM-22992] Send lastKnownRevisionDate with Attachment API calls (#16862)
* Add lastKnownRevisionDate to Attachment methods.

* Address issues raised by Claude PR

* Fix string errors

* Show error to user in event of attachment upload failure

* Improve error handling for missing cipher

* Add unit tests for attachment lastKnownRevisionDate

* Remove generic title from toast errors

* Move lastKnwonRevisionDate to function input
2025-10-22 16:19:57 -07:00
Nick Krantz
91be36bfcf force a null value for angular forms as undefined gets forced to null anyway (#16985) 2025-10-22 12:27:48 -05:00
Jason Ng
0340a881ae [PM-20040] all tasks complete banner (#16033)
* saved WIP

* created at risk password callout service to hold state for callout data. wip

* update at-risk-password-callout to use states for tracking showing and dismissing success banner

* adding spec file for new serive

* update styles to match figma

* minor wording changes

* fix undefined lint error in at risk password callout

* moved service to libs

* added another route guard so when user clears all at risk items they are directed back to the vault page

* small cleanup in at risk callout component and at risk pw guard

* clean up code in at risk password callout component

* update state to memory

* refactor for readability at risk password callout component

* move state update logic from component to at risk password callout service

* fix: bypass router cache on back() in popout

* Revert "fix: bypass router cache on back() in popout"

This reverts commit 23f9312434.

* refactor updatePendingTasksState call

* refactor at risk password callout component and service. remove signals, implement logic through observables. Completed value for tasks utilized.

* clean up completedTasks in at risk password callout service

* add updated state value to prevent banner among diff clients

* move hasInteracted call to page component to avoid looping

* remove excess call in service

* update icon null logic in banner component

* update the callout to use a new banner

* fix classes

* updating banners in at risk password callout component

* anchor tag

* move at-risk callout to above nudges

* update `showCompletedTasksBanner$` variable naming

---------

Co-authored-by: Andreas Coroiu <andreas.coroiu@gmail.com>
Co-authored-by: Nick Krantz <nick@livefront.com>
2025-10-22 11:37:58 -05:00
Nick Krantz
d9e1bde5e0 change equality checks to account for null and undefined (#16971) 2025-10-21 14:54:35 -05:00
Alex Morask
5b2682ff21 [PM-26356] Remove client-side pre-consolidated billing code (#16707)
* Remove legacy provider files

* Removing index files to make file re-org easier

* Move manage-clients.component and associated API invocation to AC

* Move add-existing-organization-dialog.component to AC

* Move manage-client-name-dialog.component and associated API call to AC

* Move misc clients files to AC

* Move create-client-dialog.component and associated API call to AC

* Move manage-client-subscription-dialog.component to AC

* Update provider-layout.component

* Cleanup

* Fix linting
2025-10-21 14:15:29 -05:00
Nick Krantz
22eb49aed1 [PM-19337] Desktop Archive (#16787)
* fix typescript errors

* add archive filter to desktop

* exclude archive items from search

* add left click menu options for archive

* add MP prompt checks for archive/unarchive

* assure that a cipher cannot be assigned to collections when archived

* move cipher from archive vault if a user loses premium

* ensure clone only shows when archive is active

* refactor right side footer actions to getter so it can be expanded

* add confirmation prompt for archiving cipher

* add utility service for archiving/unarchiving a cipher

* add archive/unarchive ability to footer of desktop

* add tests for utilities service

* handle null emission of `cipherViews$`

* use active user id directly from activeAccount

* remove unneeded load of vault items

* refresh internal cipher when archive is toggled - forcing the footer view to update

* refresh current cipher when archived from the left-click menu

* only show archive for viewing a cipher

* add cipher form tests

* clear archive date when soft deleting

* update success messages

* remove archive date when cloning

* fix crowdin message swap

* fix test

* move MP prompt before archive prompt - match PM-26994

* fix failing test

* add optional chaining

* move template logic into class

* condense logic

* `unArchive`
2025-10-20 10:04:32 -05:00
Ben Brooks
91a661a025 feat(policies): PM-19311 Enforce URI Match Defaults organization policy (#16430)
* feat(policies): Add URI Match Default Policy enum

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* feat(policies): Add logic to read and set the default from policy data

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* In settings, set default, disable select and display hint

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Move applyUriMatchPolicy to writeValue function

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Remove code to disable individual options because we're disabling the entire select

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* WiP move resolved defaultUriMatch to Domain Settings Service

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Address local test failures related to null observables

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* add missing services

* Fix test to use new resolvedDefaultUriMatchStrategy$

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Move definition of defaultMatchDetection$ out of constructor

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Update cipher form story to use resolvedDefaultUriMatchStrategy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'pm-19310-uri-match-policy' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Fix incomplete storybook mock in cipher form stories

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Add I18n key description

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Add comment regarding potential memory leak in domain settings service

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Add explicit check for null policy data

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Add explicit check for undefined policy data

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'pm-19310-uri-match-policy' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Add shareReplay to address potential memory leak

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'pm-19310-uri-match-policy' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Merge branch 'main' of github.com:bitwarden/clients into pm-19310-uri-match-policy

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Remove outdated comment

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

* Improve type safety/validation and null checks in DefaultDomainSettingsService

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>

---------

Signed-off-by: Ben Brooks <bbrooks@bitwarden.com>
Co-authored-by: Jonathan Prusik <jprusik@classynemesis.com>
2025-10-17 07:58:17 -07:00
Jason Ng
98af7a13ed [PM-19152] Archive in Web (#16686)
* archive and unarchive an individual item

* bulk archive and unachive

* updates to text strings for archive empty state and tooltips

* update translation keys to have an archive verb and noun differentiation

* if premium member loses premium and has archive items. apply filter changes, and item more option changes

* updating unArchive text

* unarchive an archived item on edit if user loses premium

* updates for unarchive btn, refactor archive flag for less churn

* add services to cipher form stories

* add refresh to archive calls in vault, update bulk archive copy

* Do not show archive ability for deleted items

* add archive check for login menu actions

* remove assign to collections for archive filter

* update bulk success message

* add error handling for archive methods

* fix null reference check

* add unarchive icon

---------

Co-authored-by: Nick Krantz <nick@livefront.com>
2025-10-14 16:41:05 -05:00
Nik Gilmore
4d2106a7c0 [PM-26096] Bugfix: Decryption errors for folders prevent vault access (#16796)
* Handle scenario where folders fail to decrypt

* Add comment explaining the folderViews$ filter check
2025-10-09 10:46:20 -07:00
Nick Krantz
d747dc30a2 [PM-26648] Unarchive Icon (#16784)
* add unarchive icon to font

* fix cipher-form stories

* move unarchive to the proper section

* add premium icon
2025-10-08 14:14:22 -05:00
Shane Melton
9f0a565241 [PM-25682] Migrate CipherView and subviews to be TS strict compliant (#16463)
* [PM-25682] Remove ts-strict-ignore from Vault view models and update types to be strict

* [PM-25682] Ignore ViewEncryptableKeys error for old decrypt methods

* [PM-25682] Add null/undefined as possible types for isNull* and other helpers that include null checks internally

* [PM-25682] Use patchValue instead of setValue which does not support undefined values

* [PM-25682] Add type assertions and other misc. null checks where necessary

* [PM-25682] Fix importers specs

* [PM-25682] Cleanup card view/details

* [PM-25682] Fix cipher view hasAttachment helper

* [PM-25682] Cleanup unecessary null assignments in notification.background.spec.ts

* [PM-25682] Ensure linkedId is undefined instead of null

* [PM-25682] Cleanup misc typing errors

* [PM-25682] Make the CipherId required

* [PM-25682] Undo CipherId assertions

* [PM-25682] Undo brand initial value change

* [PM-25682] Update SshKeyView

* [PM-25682] Add constructor to Fido2CredentialView

* [PM-25682] Prettier

* [PM-25682] Fix strict type warnings after merge with main

* [PM-25682] Cleanup cipher view spec

* [PM-25682] Cleanup new type warnings after merge

* [PM-25682] Undo removed eslint-disable-next-line comment

* [PM-25682] Fix flaky test

* [PM-25682] Use satisfies instead of as for Fido2CredentialAutofillView
2025-10-07 11:40:57 -04:00
Oscar Hinton
8cf379d997 [PM-22305] Upgrade typescript to 5.8 (#15044)
Upgrade to the latest supported typescript version in Angular.

Resolved TS errors by:
  - adding `: any` which is what the compiler previously implied and now warns about.
  - adding `toJSON` to satisfy requirement.
2025-10-06 12:39:40 -04:00
Jordan Aasen
7a38b22667 [PM-24951] - update "My Items" icon to bwi-user (#16674)
* update "My Items" icon to bwi-user

* fix tests

* revert changse to reports. fix assign collections.

* revert remaining changes to reports
2025-10-02 14:39:13 -07:00
Danielle Flinn
087e1a6155 [CL-866] Add default callout and update styles (#16481)
* Updated callout styles 
* Added default callout variant
* Refactored component to support icon + content variants (with no header)

---------

Co-authored-by: Vicki League <vleague@bitwarden.com>
Co-authored-by: Bryan Cunningham <bryan.cunningham@me.com>
2025-10-01 23:00:47 +00:00
Nick Krantz
727689d827 [PM-24534] Archive via CLI (#16502)
* refactor `canInteract` into a component level usage.

- The default service is going to be used in the CLI which won't make use of the UI-related aspects

* all nested entities to be imported from the vault

* initial add of archive command to the cli

* add archive to oss serve

* check for deleted cipher when attempting to archive

* add searchability/list functionality for archived ciphers

* restore an archived cipher

* unarchive a cipher when a user is editing it and has lost their premium status

* add missing feature flags

* re-export only needed services from the vault

* add needed await

* add prompt when applicable for editing an archived cipher

* move cipher archive service into `common/vault`

* fix testing code
2025-09-30 10:45:04 -04:00
Nick Krantz
c4ee2fdae2 [PM-25982] Assign to Collections - My Items (#16591)
* update cipher form to exclude my items collections

* handle default collections for assign to collections and bulk

* account for every returning true for empty arrays
2025-09-29 13:06:36 -05:00
Nik Gilmore
645478af52 [PM-18629] Hide reorder icon when displaying only one custom field (#16460) 2025-09-29 09:52:37 -07:00
Addison Beck
b8d4be6cd0 build: add nx configuration in libs/vault (#16551) 2025-09-24 21:51:51 -05:00
Jordan Aasen
6024f6eef2 [PM-25879][PM-25881] - [Defect] Premium badges missing reusable component (#16461)
* clean up premium badge component

* add provider to desktop settings

* rename prop.

* add provider to send component

* fix storybook

* fix test

* move dependency to new send dropdown component

* Revert "move dependency to new send dropdown component"

This reverts commit f134526279.

* remove hasPremium
2025-09-23 09:32:45 -07:00
Nick Krantz
2de21e607c disable autofill options when the form is disabled (#16505) 2025-09-22 11:38:28 -05:00
Jason Ng
dbec02cf8d [PM-24533] Initialize Archive Feature (#16226)
* [PM-19237] Add Archive Filter Type (#13852)
* Browser can archive and unarchive items
* Create Archive Cipher Service
* Add flag and premium permissions to Archive 

---------

Co-authored-by: SmithThe4th <gsmith@bitwarden.com>
Co-authored-by: Shane <smelton@bitwarden.com>
Co-authored-by: Patrick Pimentel <ppimentel@bitwarden.com>
2025-09-22 11:06:02 -04:00
Nick Krantz
200fc71c5c [PM-24305] Only enable the cipher form when it is disabled (#16259)
* only enable the cipher form when it is disabled

* switch to tracking the last emitted state for disabled rather than the form status.

The form status can be changed if any child control changes
2025-09-17 13:58:46 -05:00
Jordan Aasen
db9061d120 [PM-25633] - [Defect] Fix premium badge in totp (#16373)
* fixes to premium upgrade

* revert change to dialog

* handle premium upgrade prompt redirect in AC

* use new input/output api
2025-09-11 12:15:29 -07:00
Nick Krantz
840e6a9ae2 Reapply "[PM-21024] Use Server for Password Change URLs (#14912)" (#16322) (#16372)
This reverts commit 0040c857ec.
2025-09-11 08:40:11 -05:00
Jordan Aasen
30af3d7035 [PM-24985][PM-24986][PM-25211][PM-24987] - [Vault] Migrate components to use Premium badge component (#16227)
* migrate all components to use PremiumBadgeComponent

* move badge component to vault

* move premium badge to vault

* move premium badge to billing

* fix import

* use premium badge in tools new send dropdown

* remove badge module import

* remove module
2025-09-09 13:39:24 -07:00
Nick Krantz
0040c857ec Revert "[PM-21024] Use Server for Password Change URLs (#14912)" (#16322)
This reverts commit fcc2bc96d1.
2025-09-06 08:57:55 -07:00
Jordan Aasen
e8e1a9891a [PM-20034] - [Vault][Browser] Display View Login button and specific banner when an At-risk password task is missing a valid website (#16206)
* add banner for at risk pw without uri

* remove unnecessary title attr. use hasUris
2025-09-04 15:30:39 -07:00
Nick Krantz
ca9b531571 avoid using the SDK to decrypt attachments for emergency access (#16293)
- The SDK does not have emergency access functionality built in at this point.
2025-09-04 14:31:52 -05:00
Nick Krantz
ca554897be [PM-24269] Enable ownership field for personal items (#16069)
* remove global check for personal ownership as `setFormState` now handles it

* ensure that the organizationId is disabled for new ciphers

* only check for personal ownership change for enabling/disabling the entire form - this ensure that it is only applied when the data ownership policy is applied

- The bug was caused by a regular user that wasn't in an organization, their form was getting fully disabled when it shouldn't.

* fix type checking

* do not disable organization id after an organization is selected
2025-09-04 10:39:34 -05:00