This article wants to share with you a small function, that is, use the Chrome browser to select the account that remembers the password. The input box will automatically add a yellow background. Some design input boxes have a transparent background, and this yellow needs to be removed. background. Let me share with you how to deal with the yellow background of the input after the Chrome browser remembers the password. Let’s take a look. I hope it can help you.
Use the Chrome browser to select the account that remembers the password, and the input box will automatically add a yellow background. Some design input boxes have a transparent background, and this yellow background needs to be removed;
Method 1: Shadow coverage
input:-webkit-autofill { -webkit-box-shadow: 0 0 0 1000px white inset !important; }
Because it is setting the color coverage , so it is only effective for non-transparent solid color backgrounds;
Method 2: Modify the time when the chrome browser renders the yellow background
:-webkit-autofill { -webkit-text-fill-color: #fff !important; transition: background-color 5000s ease-in-out 0s; }
Perfect solution
How about everyone learn it? Hurry up and give it a try.
Related recommendations:
Examples of how to control the input input format in html
For the input box, the input value is limited to float Point-type js method
javascript input input box fuzzy prompt function detailed explanation
The above is the detailed content of How to deal with the yellow background of input after the browser remembers the password. For more information, please follow other related articles on the PHP Chinese website!