Found a total of 2 related content
CSS new property Field-sizing can make input, textarea and select adapt to their content
Article Introduction:Introducing field-sizing
field-sizing is a new CSS property that enables inputs, textareas, and selects to automatically scale to the size of their content.
fixed , which is the current behavior for inputs, text areas, and selections, where they have a fixed size regardless of content.
content , causes the form element to scale to the size of the content
When you apply it to an input or select, it will scale to the width of the content. When you apply it to a textarea, it will scale to the height of the content.
Example
2024-09-21
comment 0
959