Skip to content
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

PM-5550 Implement on-page autofil for single line TOTP #12058

Merged
merged 24 commits into from
Dec 13, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
85a6736
PM-5550 initial commit -Initial render
dan-livefront Nov 19, 2024
49fc569
Merge branch 'main' into PM-5550-implement-on-page-autofill-menu-for-โ€ฆ
dan-livefront Nov 20, 2024
dcd4ae2
Merge branch 'main' into PM-5550-implement-on-page-autofill-menu-for-โ€ฆ
dan-livefront Nov 20, 2024
6f68692
add refresh overlay
dan-livefront Nov 21, 2024
164b770
localize and clean up
dan-livefront Nov 25, 2024
897fe61
- Clean up code
dan-livefront Nov 27, 2024
172c806
version()
dan-livefront Nov 27, 2024
48a8b7e
Merge branch 'main' into PM-5550-implement-on-page-autofill-menu-for-โ€ฆ
dan-livefront Nov 27, 2024
44d076a
Add and translate aria labels
dan-livefront Nov 27, 2024
a20eb14
Merge branch 'main' into PM-5550-implement-on-page-autofill-menu-for-โ€ฆ
dan-livefront Nov 27, 2024
8c82c86
Merge branch 'PM-5550-implement-on-page-autofill-menu-for-totp' of giโ€ฆ
dan-livefront Nov 27, 2024
f258bef
add aria labels
dan-livefront Dec 2, 2024
00b96fd
implement feature flag
dan-livefront Dec 3, 2024
7b4aaf0
address totp tests
dan-livefront Dec 3, 2024
c53b767
Merge branch 'main' into PM-5550-implement-on-page-autofill-menu-for-โ€ฆ
dan-livefront Dec 3, 2024
e5e2715
clean up totpfield function
dan-livefront Dec 3, 2024
911ab15
fix styling and tests, update snapshots
dan-livefront Dec 4, 2024
2e6f878
Update apps/browser/src/_locales/en/messages.json
dan-livefront Dec 5, 2024
0c23dee
Update apps/browser/src/_locales/en/messages.json
dan-livefront Dec 5, 2024
c9831a4
remove group tag
dan-livefront Dec 5, 2024
97f9692
update snapshots
dan-livefront Dec 5, 2024
9c2c03e
adress feedback
dan-livefront Dec 10, 2024
e7a7277
merge conflict
dan-livefront Dec 11, 2024
8aa2616
Merge branch 'main' into PM-5550-implement-on-page-autofill-menu-for-โ€ฆ
dan-livefront Dec 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -171,9 +171,13 @@ export class InlineMenuFieldQualificationService
return this.isFieldForLoginFormFallback(field);
}

const isTotpField = this.isTotpField(field);
/**
* Autofill does not fill password type totp input fields
*/
if (this.inlineMenuTotpFeatureFlag) {
if (isTotpField) {
const isTotpField = this.isTotpField(field);
const passwordType = field.type === "password";
if (isTotpField && !passwordType) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit (for follow up work in next PRs, don't worry about it in this one), let's move that comment to be more local to the line in question:

Suggested change
/**
* Autofill does not fill password type totp input fields
*/
if (this.inlineMenuTotpFeatureFlag) {
if (isTotpField) {
const isTotpField = this.isTotpField(field);
const passwordType = field.type === "password";
if (isTotpField && !passwordType) {
if (this.inlineMenuTotpFeatureFlag) {
const isTotpField = this.isTotpField(field);
// Autofill does not fill totp inputs with a "password" `type` attribute value
const passwordType = field.type === "password";
if (isTotpField && !passwordType) {

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do! good call out.

return true;
}
}
Expand Down
2 changes: 1 addition & 1 deletion apps/browser/src/background/runtime.background.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default class RuntimeBackground {
"biometricUnlockAvailable",
"getUseTreeWalkerApiForPageDetailsCollectionFeatureFlag",
"getInlineMenuFieldQualificationFeatureFlag",
"getInlineMenuTotpFlag",
"getInlineMenuTotpFeatureFlag",
];

if (messagesWithResponse.includes(msg.command)) {
Expand Down
Loading