-
Notifications
You must be signed in to change notification settings - Fork 22.5k
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
Mute default :focus form highlight #36103
Conversation
The applied border colour (border-color: #000;) is cascaded by the default border highlight (blue colour in Chrome). Therefore I reckon the default styling needs to be muted.
Preview URLs (comment last updated: 2024-10-18 02:20:18) |
Thanks - I am closing this because I think it is invalid. There don't appear to be any If you can show exactly what the before and after change is (screenshots) then perhaps we can discuss. Note that any changes made here also have to be made in the corresponding example code linked from the page. |
Thanks for your response. Here's where I reproduced the change: Here's how I applied the change and confirmed both the property is applied to the element and the appearance is affected as per the property. |
Thank you, but I cannot reproduce. Using the current version you can see below the border is black to start with and that there is no computed property for outline - i.e. no blue outline that is inherited. It may be that this is set differently on another browser, but I still think adding this fix would be more confusing than helpful. |
THanks for your patience @josuke0227 . Yes, I think that instead of muting the outline, what you have suggested will work better, and more important, be more consistent across browsers. input:focus,
textarea:focus {
/* To give a little highlight on active elements */
outline-color: #000;
} BUT, as I noted before, we also need to make this same change in https://github.com/mdn/learning-area/blob/main/html/forms/your-first-HTML-form/first-form-styled.html and the other linked examples - can you do that too, and link to here? This should be tested on at least chrome and FF. |
@josuke0227 - thank you for the testing and confirmation. Can you apply your fix here, and cross link from your PR to https://github.com/mdn/learning-area/blob/main/html/forms/your-first-HTML-form/first-form-styled.html I can then review and merge them together. |
Hi @hamishwillee, I've just updated the other one. Thank you! |
Thanks @josuke0227 - might not get to this until Friday, but have not forgotten! |
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.
Thanks very much @josuke0227 - also for your patience with my review.
The applied border colour (border-color: #000;) is cascaded by the default border highlight (blue colour in Chrome). Therefore I reckon the default styling needs to be muted.