-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[PM-21724] - add safari and firefox to list of potential browser vendors #14857
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
New Issues (5)Checkmarx found the following issues in this Pull Request
Fixed Issues (2)Great job! The following issues were fixed in this Pull Request
|
Codecov ReportAttention: Patch coverage is
✅ All tests successful. No failed tests found.
Additional details and impacted files@@ Coverage Diff @@
## main #14857 +/- ##
==========================================
- Coverage 36.49% 36.33% -0.16%
==========================================
Files 3200 3200
Lines 92679 93309 +630
Branches 16694 16858 +164
==========================================
+ Hits 33822 33904 +82
- Misses 56403 56969 +566
+ Partials 2454 2436 -18 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
get browserClientVendorExtended() { | ||
if (this.browserClientVendor !== BrowserClientVendors.Unknown) { | ||
return this.browserClientVendor; | ||
} | ||
if (this.platformUtilsService.isFirefox()) { | ||
return "Firefox"; | ||
} | ||
if (this.platformUtilsService.isSafari()) { | ||
return "Safari"; | ||
} | ||
return this.i18nService.t("turnOffBrowserAutofill", this.browserClientVendor); | ||
} | ||
|
||
get spotlightButtonText() { | ||
return this.i18nService.t("turnOffBrowserAutofill", this.browserClientVendorExtended); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How are we representing the case where the client is Unknown
now?
Even if our logic currently covers every known vendor case, could we have a fallback for unexpected cases? Otherwise you risk concatenating "undefined" into the string, no?
get browserClientVendorExtended() { | |
if (this.browserClientVendor !== BrowserClientVendors.Unknown) { | |
return this.browserClientVendor; | |
} | |
if (this.platformUtilsService.isFirefox()) { | |
return "Firefox"; | |
} | |
if (this.platformUtilsService.isSafari()) { | |
return "Safari"; | |
} | |
return this.i18nService.t("turnOffBrowserAutofill", this.browserClientVendor); | |
} | |
get spotlightButtonText() { | |
return this.i18nService.t("turnOffBrowserAutofill", this.browserClientVendorExtended); | |
} | |
get browserClientVendorExtended() { | |
if (this.browserClientVendor !== BrowserClientVendors.Unknown) { | |
return this.browserClientVendor; | |
} | |
if (this.platformUtilsService.isFirefox()) { | |
return "Firefox"; | |
} | |
if (this.platformUtilsService.isSafari()) { | |
return "Safari"; | |
} | |
return BrowserClientVendors.Unknown; | |
} | |
get spotlightButtonText() { | |
if (this.browserClientVendorExtended === BrowserClientVendors.Unknown) { | |
return this.i18nService.t("turnOffAutofill"); | |
} | |
return this.i18nService.t("turnOffBrowserAutofill", this.browserClientVendorExtended); | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jprusik Ah yes ofc. Thanks for pointing this out. I've pushed an update with a small addition to your suggestion.
|
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-21724
📔 Objective
This PR adds safari and firefox to the list of potential browser vendors for the autofill spotlight nudge.
📸 Screenshots
⏰ Reminders before review
🦮 Reviewer guidelines
:+1:
) or similar for great changes:memo:
) or ℹ️ (:information_source:
) for notes or general info:question:
) for questions:thinking:
) or 💭 (:thought_balloon:
) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion:art:
) for suggestions / improvements:x:
) or:warning:
) for more significant problems or concerns needing attention:seedling:
) or ♻️ (:recycle:
) for future improvements or indications of technical debt:pick:
) for minor or nitpick changes