bext: update private repo sync banners
Created by: taras-yemets
Closes issues/31920.
See also PR https://github.com/sourcegraph/sourcegraph/pull/31690 discussion.
Show different instructions on the options page for repo not found error depending on Sourcegraph URL and whether the user is admin.
Sourcegraph instance | User is admin | Screenshot | Notes |
---|---|---|---|
Cloud | Sourceraph button text is 'Configure on Sourcegraph'. It navigates to user settings manage repositories page with current repo name as filter query. | ||
Self-hosted / managed | - Link in the extension popup navigates user to add repos docs page - Sourceraph button text is 'Repository not found'. It still links to the repository, but will show 'Not Found' page. This information is just for context, the button is not the matter of change of this PR. |
||
Self-hosted / managed |
|
UPD: updated copies according to this comment
Test plan
sg run bext
- Sourcegraph cloud instance
- set Sourcegraph URL to Sourcegrpah Cloud
- log in to your cloud account
- go to the private repository page which is not synced in user settings
- check the private repo message on the options page (see screenshots above)
- Sourcegraph on-prem / managed instance
- set Sourcegrpah URL to on-prem / managed instance
- log in as non-admin user
- check not-synced repo message on the options page (see screenshots above)
- log in as admin user
- check not-synced repo message for the admin user (see screenshots above)