Skip to content
This repository has been archived by the owner on Aug 21, 2023. It is now read-only.

Commit

Permalink
Merge 0362733 into ac42f55
Browse files Browse the repository at this point in the history
  • Loading branch information
Jon Quach committed Apr 11, 2019
2 parents ac42f55 + 0362733 commit 7ffaada
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/components/Input/Input.js
Expand Up @@ -127,6 +127,7 @@ export class Input extends Component<Props, State> {
isLast: false,
isNotOnly: false,
isSubtleReadOnly: false,
maxHeight: 320,
moveCursorToEnd: false,
multiline: null,
offsetAmount: 0,
Expand Down
4 changes: 2 additions & 2 deletions src/components/Input/Resizer.tsx
Expand Up @@ -129,8 +129,8 @@ export class Resizer extends React.PureComponent<Props> {
if (!minimumLines) return

return (
<div
ref={this.setMinimumLinesNode}
<GhostUI
innerRef={this.setMinimumLinesNode}
className={this.getContentClassName()}
dangerouslySetInnerHTML={{
__html: this.getContentsForMinimumLines(minimumLines),
Expand Down
4 changes: 2 additions & 2 deletions src/components/Input/__tests__/Input.test.js
Expand Up @@ -370,11 +370,11 @@ describe('Multiline', () => {
expect(wrapper.state()).not.toBe(null)
})

test('Does not set maxHeight on multiline by default', () => {
test('Has a maxHeight by default', () => {
const wrapper = mount(<Input multiline={3} />)
const el = wrapper.find('textarea')

expect(el.prop('style').maxHeight).toBeFalsy()
expect(el.prop('style').maxHeight).toBeTruthy()
})

test('Sets maxHeight on multiline, if specified', () => {
Expand Down

0 comments on commit 7ffaada

Please sign in to comment.