1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-07-16 13:55:52 +02:00
bitwarden-browser/apps/desktop
Matt Gibson 7a7fe08a32
Ps/pm 2910/handle switch messaging (#6823)
* Handle switch messaging

TODO: handle loading state for account switcher

* Async updates required for state

* Fallback to email for current account avatar

* Await un-awaited promises

* Remove unnecessary Prune

Prune was getting confused in browser and deleting memory in browser on
account switch. This method isn't needed since logout already removes
memory data, which is the condition for pruning

* Fix temp password in browser

* Use direct memory access until data is serializable

Safari uses a different message object extraction than firefox/chrome
and is removing `UInt8Array`s. Until all data passed into StorageService
is guaranteed serializable, we need to use direct access in state
service

* Reload badge and context menu on switch

* Gracefully switch account as they log out.

* Maintain location on account switch

* Remove unused state definitions

* Prefer null for state

undefined can be misinterpreted to indicate a value has not been set.

* Hack: structured clone in memory storage

We are currently getting dead objects on account switch due to updating
the object in the foreground state service. However, the storage service
is owned by the background. This structured clone hack ensures that all
objects stored in memory are owned by the appropriate context

* Null check nullable values

active account can be null, so we should include null safety in the
equality

* Correct background->foreground switch command

* Already providing background memory storage

* Handle connection and clipboard on switch account

* Prefer strict equal

* Ensure structuredClone is available to jsdom

This is a deficiency in jsdom --
https://github.com/jsdom/jsdom/issues/3363 -- structured clone is well
supported.

* Fixup types in faker class
2023-11-29 09:59:50 -05:00
..
.vscode Multi root workspace tweaks (#2858) 2022-06-13 21:39:36 -05:00
config Individual Vault Item Encryption Feature (#6241) 2023-09-28 08:44:57 -04:00
desktop_native [BEEEP] [PM-565] Implement clipboard logic in rust (#4516) 2023-10-02 18:50:57 +02:00
native-messaging-test-runner Update dependency uuid to v9 (#5960) 2023-08-21 16:58:21 +00:00
resources Update Plist files for MAS (#2951) 2022-06-22 15:10:21 -04:00
scripts [PM-3996] Scaffolding for preload script (#6065) 2023-10-12 11:50:17 +02:00
src Ps/pm 2910/handle switch messaging (#6823) 2023-11-29 09:59:50 -05:00
stores Update year in copyrights (#4325) 2022-12-28 21:59:23 +01:00
.eslintrc.json [EC-184] Desktop cleanup (#2553) 2022-05-05 19:03:56 +02:00
.gitignore Simplify our gitignore files (#2925) 2022-06-17 15:33:51 +02:00
crowdin.yml Fix Crowdin Pull workflow (#2667) 2022-05-10 10:20:32 -04:00
electron-builder.json [PM-4300] downgrade electron to v25.9.1 (#6573) 2023-10-13 10:26:56 -04:00
installer.nsh Add NSIS custom installer script for UAC fix on Windows (#2856) 2022-06-08 08:47:10 -04:00
jest.config.js [PM-2328] Fix jest deprecations (#5483) 2023-05-22 20:19:16 +02:00
package.json Bumped desktop version to 2023.10.2 (#6833) 2023-11-08 11:17:35 -05:00
postcss.config.js [PM-2237] Add tailwind to desktop & browser (#5326) 2023-07-14 15:03:42 -04:00
README.md Update urls to match the contributing docs (#4192) 2022-12-06 11:20:27 +01:00
sign.js Move desktop into apps/desktop 2022-05-05 17:20:34 +02:00
tailwind.config.js [PM-2237] Add tailwind to desktop & browser (#5326) 2023-07-14 15:03:42 -04:00
test.setup.ts [SG-397] Configure jest for Desktop and add simple tests (#3467) 2022-09-15 12:31:15 -04:00
tsconfig.json Assign ownership to many libs files (#6928) 2023-11-27 20:59:44 +00:00
tsconfig.renderer.json Add support for migrated jslib (#2826) 2022-06-03 18:01:07 +02:00
tsconfig.spec.json [SG-397] Configure jest for Desktop and add simple tests (#3467) 2022-09-15 12:31:15 -04:00
webpack.main.js [PM-3996] Scaffolding for preload script (#6065) 2023-10-12 11:50:17 +02:00
webpack.preload.js [PM-3996] Scaffolding for preload script (#6065) 2023-10-12 11:50:17 +02:00
webpack.renderer.js Noop notifications for dev (#6671) 2023-10-24 15:18:23 +02:00

Github Workflow build on master Crowdin Join the chat at https://gitter.im/bitwarden/Lobby

Bitwarden Desktop Application

Platforms

The Bitwarden desktop app is written using Electron and Angular. The application installs on Windows, macOS, and Linux distributions.

Desktop Vault

Documentation

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