-
Notifications
You must be signed in to change notification settings - Fork 4k
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
fix(TextArea): compute height when hidden #1793
Conversation
src/addons/TextArea/TextArea.js
Outdated
return ( | ||
<ElementType | ||
{...rest} | ||
onChange={this.handleChange} | ||
ref={this.handleRef} | ||
rows={rows} | ||
style={{ ...style, minHeight }} | ||
style={{ resize, height, ...style }} |
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.
Can we sort resize
and height
in alphabetical order? 😄
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.
NO! 😛
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.
Sorted all keys in objects and force pushed 👍
30668d8
to
7bc5f0c
Compare
Codecov Report
@@ Coverage Diff @@
## master #1793 +/- ##
=======================================
Coverage 99.75% 99.75%
=======================================
Files 144 144
Lines 2465 2465
=======================================
Hits 2459 2459
Misses 6 6
Continue to review full report at Codecov.
|
Released in |
Fixes #1405
This PR changes the height calculation do not depend on a visible DOM node. We simply total up the box model height and text height rather than using the
scrollHeight
.