react-textarea-autosize
Advanced tools
Comparing version 4.0.1 to 4.0.2
@@ -0,1 +1,7 @@ | ||
'use strict'; | ||
Object.defineProperty(exports, "__esModule", { | ||
value: true | ||
}); | ||
exports.default = calculateNodeHeight; | ||
/** | ||
@@ -5,8 +11,2 @@ * calculateNodeHeight(uiTextNode, useCache = false) | ||
'use strict'; | ||
Object.defineProperty(exports, '__esModule', { | ||
value: true | ||
}); | ||
exports['default'] = calculateNodeHeight; | ||
var HIDDEN_TEXTAREA_STYLE = '\n min-height:0 !important;\n max-height:none !important;\n height:0 !important;\n visibility:hidden !important;\n overflow:hidden !important;\n position:absolute !important;\n z-index:-1000 !important;\n top:0 !important;\n right:0 !important\n'; | ||
@@ -17,3 +17,3 @@ | ||
var computedStyleCache = {}; | ||
var hiddenTextarea = undefined; | ||
var hiddenTextarea = void 0; | ||
@@ -43,2 +43,3 @@ function calculateNodeHeight(uiTextNode) { | ||
// narrower for content | ||
hiddenTextarea.setAttribute('style', sizingStyle + ';' + HIDDEN_TEXTAREA_STYLE); | ||
@@ -115,2 +116,1 @@ hiddenTextarea.value = uiTextNode.value || uiTextNode.placeholder || ''; | ||
} | ||
module.exports = exports['default']; |
@@ -72,3 +72,3 @@ 'use strict'; | ||
props.style = _extends({}, props.style, { | ||
height: this.state.height | ||
height: this.state.height || 0 | ||
}); | ||
@@ -75,0 +75,0 @@ var maxHeight = Math.max(props.style.maxHeight ? props.style.maxHeight : Infinity, this.state.maxHeight); |
{ | ||
"name": "react-textarea-autosize", | ||
"description": "textarea component for React which grows with content", | ||
"version": "4.0.1", | ||
"version": "4.0.2", | ||
"author": { | ||
@@ -6,0 +6,0 @@ "name": "Andrey Popp", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16660
324