vsce: implement access token sidebar view
Created by: tjkandala
Add access token sidebar view for VSCE v1. Fixes issues from the preview release like accepting bad tokens (caused by my spaghetti code), reloading without user consent.
Videos
- Success flow
- Failure flow
Notes
- Why is there a notification on the bottom right? To let the user know to update their token in case it is invalidated between sessions.
- Why do we want users to reload the window? We dispose all resources and prevent API requests on settings (either URL or access token) changes to prevent any private data (like repo names) from being sent to other instances. I included access tokens since theoretically a user could have opened a private repo while authenticated, then removed their access token to "log out", but I don't know if that's really a vulnerability. If we think that reloading is really inconvenient, we can make that a requirement only for instance change, not access token change.
- Next steps (1 step per PR): Implement search UI, implement remote file browsing, add code intel/Sourcegraph extensions, pings/analytics.