* PM-26302 create helper that will assign local data to ciphers and cached ciphers on decryption
* remove helper and call local data only on get cipher for url to make operation less expensive
* add tests for local data using functions that call the getcipherforurl function
* reorder to have early null check
* Added right click functionality on cipher row
* Updated menu directive to position menu option on mouse event location
* Updated menu directive to reopen menu option on new mouse event location and close previously opened menu-option
* removed preventdefault call
* Added new events for favorite and edit cipher
* Added new menu options favorite, edit cipher
Added new copy options for the other cipher types
Simplified the copy by using the copy cipher field directive
* Listen to new events
* Refactored parameter to be MouseEvent
* Added locales
* Remove the backdrop from `MenuTriggerForDirective`
* Handle the Angular overlay's outside pointer events
* Cleaned up cipher row component as copy functions and disable menu functions would not be needed anymore
* Fixed bug with right clicking on a row
* Add right click to collections
* Disable backdrop on right click
* Fixed bug where dvivided didn't show for secure notes
* Added comments to enable to disable context menu
* Removed conditionals
* Removed preferences setting to enable to disable setting
* Removed setting from right click listener
* improve context menu positioning to prevent viewport clipping
* Keep icon consisten when favorite or not
* fixed prettier issues
* removed duplicate translation keys
* Fix favorite status not persisting by toggling in handleFavoriteEvent
* Addressed claude comments
* Added comment to variable
---------
Co-authored-by: Addison Beck <github@addisonbeck.com>
* [CL-874] Replace or ignore hardcoded colors in svgs
* missed the logo color remaining in dark mode
* set svg color lint rule to error
* add bw blue color
With the introduction of the ImportMetadataService for all import component, the DI setup was missing for th org-import.component
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
* use PureCrypto in master password service decryptUserKeyWithMasterKey
* test for legacy AES256-CBC
* update SDK version to include the `PureCrypto.decrypt_user_key_with_master_key`
* change from integration to unit tests, use fake state provider
* 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>
* Verify route and input to be a valid organizationId
* Optimize canImport check
Instead of loading the user and organization again, used the previously loaded organization and check the permission directly
* Reset organization in case organizationId is set to undefined
---------
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
* Add importer metadata to native code
* Impl napi code in ts
* Impl napi code in ts
* Fix clippy
* Fix clippy
* remove ts util tests
* Check for installed browsers
* PR fixes
* test fix
* fix clippy
* fix tests
* Bug fix
* clippy fix
* Correct tests
* fix clippy
* fix clippy
* Correct tests
* Correct tests
* [PM-25521] Wire up loading metadata on desktop (#16813)
* Initial commit
* Fix issues regarding now unused feature flag
* Fixed ts-strict issues
---------
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
Co-authored-by: adudek-bw <adudek@bitwarden.com>
* Remove logic to skip Brave as that now happens via the native code
* Define default capabilities which can be overwritten by specifc client/platform
* Fix DI issues
* Do not overwrite existing importers, just add new ones or update existing ones
* feat: [PM-25521] return metadata directly (not as JSON) (#16882)
* feat: return metadata directly (not as JSON)
* Fix broken builds
Move getMetaData into chromium_importer
Remove chromium_importer_metadata and any related service
Parse object from native instead of json
* Run cargo fmt
* Fix cargo dependency sort order
* Use exposed type from NAPI instead of redefining it.
* Run cargo fmt
---------
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
* Only enable chromium loader for installed and supported browsers
---------
Co-authored-by: Daniel James Smith <2670567+djsmith85@users.noreply.github.com>
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
Co-authored-by: Andreas Coroiu <acoroiu@bitwarden.com>
* fix: always try to register clearOn events
`registerEvents` already checks for existing registered events so there is no
need to have a pre-check in `doStorageSave`. It causes issues because the
`newState` and `oldState` parameters come from the custom deserializer which
might never return `null` (e.g. transforming `null` to some default value).
Better to just use the list of registered events as a source of truth.
A performance check shows that most calls would only save a couple of
milliseconds (ranges from 0.8 ms to 18 ms) and the total amount of time
saved from application startup, to unlock, to showing the vault is about 100 ms.
I haven't been able to perceive the change.
* Revert "feat: add folder.clear warning (#16376)"
This reverts commit a2e36c4489.
* fix(auth-tech-debt): [PM-24103] Remove Get User Key to UserKey$ - Fixed and updated tests.
* fix(auth-tech-debt): [PM-24103] Remove Get User Key to UserKey$ - Fixed test variable being made more vague.
* Update CSS class & refactor to use control flow instead of *ngIf directives
* Migrate to Tailwind classes for styling on the use-browser-link component
* Refactor if directive - use control flow instead
* Refactor to leverage Tailwind CSS
The Key Connector URL was getting overwritten back to the default URL on `submit()` because `valueChanges` gets triggered during `submit()`. This fix adds a check to make sure we only set the default URL when changing TO Key Connector from a different decryption option. In other words, don't overwrite back to the default URL during `submit()`.
Also removes the trailing slash `/` from the default URL.
* do not show organization error message for any invalid timeout
* use newValue rather than the current form value when early return
* add missing error message
* Add initial changes for thenew premium design
* Add the messages
* Add the new dialog modal
* Resolve the flag issue
* Added changes for redirect
* Fix the unitest errors
* Resolve the badge issue
* refactor the code base pr comments
* refactor phishing-warning.component
* add hideBackground input to anon-layout component
* add icon tile component to CL
* add storybook story; fix binding bug in template
* export icon-tile from CL
* update design of phishing warning page
* revert icon button to use string type; add comment to icon scss
* update callout to allow no icon/title on all variants
* update phishing warning styles
* fix defects
* crowdin messages cannot be changed, they must be replaced
* add global css override
* add phishing help link
* update icon used in tile
* tweak styles
• prefer undefined over null
• obtain required UserId once per method, before branching
• guards moved to beginning of methods
* lift UserId retrieval to occur once during import
* remove redundant userId retrieval
* 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>