Skip to content

Commit

Permalink
[Credentials Import] Check local credentials before showing prompt (#650
Browse files Browse the repository at this point in the history
)

* chore: remove response

* chore: rename pixel

* feat: update copy

* feat: update locales

* fix: only show tooltip if there's no credentials locally stored
  • Loading branch information
dbajpeyi authored Sep 9, 2024
1 parent bd62c42 commit d879b6c
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 5 deletions.
3 changes: 2 additions & 1 deletion dist/autofill-debug.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion dist/autofill.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/UI/controllers/HTMLTooltipUIController.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,8 @@ export class HTMLTooltipUIController extends UIController {

}

if (topContextData.credentialsImport) {
const hasNoCredentialsData = this._options.device.getLocalCredentials().length === 0
if (topContextData.credentialsImport && hasNoCredentialsData) {
this._options.device.firePixel({pixelName: 'autofill_import_credentials_prompt_shown'})
return new CredentialsImportTooltip(config, topContextData.inputType, getPosition, tooltipOptions)
.render(this._options.device, {
Expand Down
3 changes: 2 additions & 1 deletion swift-package/Resources/assets/autofill-debug.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion swift-package/Resources/assets/autofill.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit d879b6c

Please sign in to comment.