1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-16 02:27:00 +02:00
bitwarden-browser/apps/web
Matt Gibson c70a5aa024
[PM-6688] Use AccountService as account source (#8893)
* Use account service to track accounts and active account

* Remove state service active account Observables.

* Add email verified to account service

* Do not store account info on logged out accounts

* Add account activity tracking to account service

* Use last account activity from account service

* migrate or replicate account service data

* Add `AccountActivityService` that handles storing account last active data

* Move active and next active user to account service

* Remove authenticated accounts from state object

* Fold account activity into account service

* Fix builds

* Fix desktop app switch

* Fix logging out non active user

* Expand helper to handle new authenticated accounts location

* Prefer view observable to tons of async pipes

* Fix `npm run test:types`

* Correct user activity sorting test

* Be more precise about log out messaging

* Fix dev compare errors

All stored values are serializable, the next step wasn't necessary and was erroring on some types that lack `toString`.

* If the account in unlocked on load of lock component, navigate away from lock screen

* Handle no users case for auth service statuses

* Specify account to switch to

* Filter active account out of inactive accounts

* Prefer constructor init

* Improve comparator

* Use helper methods internally

* Fixup component tests

* Clarify name

* Ensure accounts object has only valid userIds

* Capitalize const values

* Prefer descriptive, single-responsibility guards

* Update libs/common/src/state-migrations/migrate.ts

Co-authored-by: Justin Baur <19896123+justindbaur@users.noreply.github.com>

* Fix merge

* Add user Id validation

activity for undefined was being set, which was resulting in requests for the auth status of `"undefined"` (string) userId, due to key enumeration. These changes stop that at both locations, as well as account add for good measure.

---------

Co-authored-by: Justin Baur <19896123+justindbaur@users.noreply.github.com>
2024-04-30 09:13:02 -04:00
..
.vscode
config [SM-1031] Remove SecretsManager & showDDG compile flags (#8610) 2024-04-08 17:46:24 +02:00
scripts
src [PM-6688] Use AccountService as account source (#8893) 2024-04-30 09:13:02 -04:00
.dockerignore
.eslintrc.json
.gitignore
config.js
crowdin.yml
dev-server.shared.pem
Dockerfile
entrypoint.sh
jest.config.js Auth/PM-5268 - DeviceTrustCryptoService state provider migration (#7882) 2024-04-01 16:02:58 -04:00
package.json Bumped browser,cli,desktop,web version to (#8875) 2024-04-23 11:32:09 +00:00
postcss.config.js
README.md
tailwind.config.js
test.setup.ts
tsconfig.json
tsconfig.spec.json
webpack.config.js [deps] AC: Update webpack-dev-server to v5 (#8482) 2024-03-25 15:27:45 -05:00

The Bitwarden web project is an Angular application that powers the web vault (https://vault.bitwarden.com/).

Github Workflow build on master Crowdin DockerHub gitter chat

Documentation

Please refer to the Web vault section of the Contributing Documentation for build instructions, recommended tooling, code style tips, and lots of other great information to get you started.