Skip to content

MudAutocomplete: Modify default autocomplete method (#9318)#9354

Merged
henon merged 1 commit intoMudBlazor:devfrom
Aaron2404:modify-default-autocomplete-method
Jul 10, 2024
Merged

MudAutocomplete: Modify default autocomplete method (#9318)#9354
henon merged 1 commit intoMudBlazor:devfrom
Aaron2404:modify-default-autocomplete-method

Conversation

@Aaron2404
Copy link
Contributor

@Aaron2404 Aaron2404 commented Jul 9, 2024

Description

This PR introduces a new default method for autocompletion to ensure the autocorrect operates as expected on Chrome.

Problem

The existing method of disabling autocomplete by appending a unique identifier to the autocomplete attribute no longer works in Chrome as of 2024. Recent changes in browser behavior have rendered this approach ineffective.

Solution

The problem can be resolved by simply using "off" as the default value for the autocomplete attribute, this solution has been thoroughly tested to ensure compatibility with other browsers.

References

Fixes: #9318

How Has This Been Tested?

  • Updated existing unit tests.
  • Visually on desktop and when possible iOS and Android using:
    • Chrome
    • Edge
    • Firefox
    • Safari

Type of Changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • The PR is submitted to the correct branch (dev).
  • My code follows the code style of this project.
  • I've added relevant tests.

Modified: Unit tests to comply with the changes made.
@github-actions github-actions bot added bug Unexpected behavior or functionality not working as intended PR: needs review labels Jul 9, 2024
@codecov
Copy link

codecov bot commented Jul 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.76%. Comparing base (28bc599) to head (8ed77f6).
Report is 331 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #9354      +/-   ##
==========================================
+ Coverage   89.82%   90.76%   +0.93%     
==========================================
  Files         412      403       -9     
  Lines       11878    12665     +787     
  Branches     2364     2447      +83     
==========================================
+ Hits        10670    11495     +825     
+ Misses        681      618      -63     
- Partials      527      552      +25     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@danielchalmers
Copy link
Member

Looks good. What changed since #959?

@Aaron2404
Copy link
Contributor Author

@henon

@henon
Copy link
Contributor

henon commented Jul 10, 2024

Looks good. What changed since #959?

Chrome possibly didn't respect "off" back then but now seems to.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Unexpected behavior or functionality not working as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The current default method for disabling autofill is ineffective in chrome.

3 participants