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

height:0 and width:0 don't work on border #82

Open
Petercopter opened this issue May 31, 2024 · 1 comment
Open

height:0 and width:0 don't work on border #82

Petercopter opened this issue May 31, 2024 · 1 comment

Comments

@Petercopter
Copy link

Petercopter commented May 31, 2024

If there is a border on the select input then

height: 0;
width: 0;

don't work correctly to remove the input from the dom. If the border is 1px, you get a 2x2 square. Even the absolutely plain select input with no styling does this, I had to add border:0 to get it to work.
image

EDIT:
Well this is interesting. If you add border: 0, the input validation no longer shows...

@justin-oh
Copy link

I'm experiencing the original issue. In my case, I don't have a need for validation.

If setting border: 0 makes the element no longer focusable by validation, is that because it is behaving the same as a hidden element? What if all properties of the element were set to 0, except for height: 1px then offset that by margin-bottom: -1px?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants