Closed Bug 1317524 Opened 9 years ago Closed 4 years ago

[css-grid] <input type=number> does not stretch in the inline-axis

Categories

(Core :: Layout: Form Controls, defect, P3)

defect

Tracking

()

RESOLVED WORKSFORME
Tracking Status
firefox53 --- affected

People

(Reporter: MatsPalmgren_bugz, Assigned: MatsPalmgren_bugz)

References

(Blocks 1 open bug)

Details

(Keywords: testcase)

Attachments

(1 file)

data:text/html,<div style="display:grid; grid:200px/600px"><input type=number></div>
Attached patch wip — — Splinter Review
The reason it doesn't work appears to be a definite 'inline-size' in the UA sheet. It works if I change it to a 'min-inline-size' instead. (FYI, a definite computed width/height inhibits CSS Align stretching: https://drafts.csswg.org/css-align-3/#valdef-justify-self-stretch ) Do you think this change would be web-compatible? I worry that if an author have set an explicit 'width' that is less than 20ch then this UA min-value will trump that (the author then needs to set min-width:0 or whatever). An alternative fix might be to remove this UA value and add an "intrinsic" value in C++ (GetMinISize/GetPrefISize) instead, maybe? Thoughts?
Flags: needinfo?(jwatt)
(In reply to Mats Palmgren (:mats) from comment #1) > Do you think this change would be web-compatible? > I worry that if an author have set an explicit 'width' that is less than > 20ch then this UA min-value will trump that (the author then needs to set > min-width:0 or whatever). I expect that there's a reasonable number of sites that have done this, so I share that concern. > An alternative fix might be to remove this UA value and add an "intrinsic" > value in C++ (GetMinISize/GetPrefISize) instead, maybe? I think that would be safer. It also seems more consistent with Chrome which doesn't appear to set inline-size/min-inline-size.
Flags: needinfo?(jwatt)

This works now.

Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: