Skip to content

[TextField] input "size" attribute#4060

Merged
lambertwang-zz merged 3 commits intomicrosoft:masterfrom
lambertwang-zz:law/textfieldMinSize
Feb 21, 2018
Merged

[TextField] input "size" attribute#4060
lambertwang-zz merged 3 commits intomicrosoft:masterfrom
lambertwang-zz:law/textfieldMinSize

Conversation

@lambertwang-zz
Copy link
Copy Markdown

@lambertwang-zz lambertwang-zz commented Feb 21, 2018

Pull request checklist

  • Addresses an existing issue: Fixes #0000
  • Include a change request file using $ npm run change

Description of changes

Size is set to 1 for the input element in order to force the browser to respect the width set on parent elements. When size is set, it tells the browser it must show at least that number of characters in the textfield. Size defaults to 20 which forces the field to have a minimum width that may be larger than the intended size of the textfield.

See: https://html.spec.whatwg.org/multipage/input.html#the-size-attribute

default size input text

@lambertwang-zz lambertwang-zz changed the title [TextField] input size" attribute [TextField] input "size" attribute Feb 21, 2018
@lambertwang-zz lambertwang-zz merged commit 6b2f588 into microsoft:master Feb 21, 2018
@microsoft microsoft locked as resolved and limited conversation to collaborators Aug 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants