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B,4BAA4B,GAG9B,QAAiB,QAAI","file":"/npm/tt-react-textarea-autosize@6.1.0-tt2/dist/react-textarea-autosize.cjs.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.37.0.\n * Original file: /npm/tt-react-textarea-autosize@6.1.0-tt2/dist/react-textarea-autosize.cjs.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","'use strict';\n\nObject.defineProperty(exports, '__esModule', { value: true });\n\nfunction _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }\n\nvar React = _interopDefault(require('react'));\nvar PropTypes = _interopDefault(require('prop-types'));\nvar shallowequal = _interopDefault(require('shallowequal'));\n\nfunction _extends() {\n  _extends = Object.assign || function (target) {\n    for (var i = 1; i < arguments.length; i++) {\n      var source = arguments[i];\n\n      for (var key in source) {\n        if (Object.prototype.hasOwnProperty.call(source, key)) {\n          target[key] = source[key];\n        }\n      }\n    }\n\n    return target;\n  };\n\n  return _extends.apply(this, arguments);\n}\n\nfunction _inheritsLoose(subClass, superClass) {\n  subClass.prototype = Object.create(superClass.prototype);\n  subClass.prototype.constructor = subClass;\n  subClass.__proto__ = superClass;\n}\n\nvar _sPO = Object.setPrototypeOf || function _sPO(o, p) {\n  o.__proto__ = p;\n  return o;\n};\n\nvar _construct = typeof Reflect === \"object\" && Reflect.construct || function _construct(Parent, args, Class) {\n  var Constructor,\n      a = [null];\n  a.push.apply(a, args);\n  Constructor = Parent.bind.apply(Parent, a);\n  return _sPO(new Constructor(), Class.prototype);\n};\n\nfunction _objectWithoutProperties(source, excluded) {\n  if (source == null) return {};\n  var target = {};\n  var sourceKeys = Object.keys(source);\n  var key, i;\n\n  for (i = 0; i < sourceKeys.length; i++) {\n    key = sourceKeys[i];\n    if (excluded.indexOf(key) >= 0) continue;\n    target[key] = source[key];\n  }\n\n  if (Object.getOwnPropertySymbols) {\n    var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n    for (i = 0; i < sourceSymbolKeys.length; i++) {\n      key = sourceSymbolKeys[i];\n      if (excluded.indexOf(key) >= 0) continue;\n      if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n      target[key] = source[key];\n    }\n  }\n\n  return target;\n}\n\nvar isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined';\n\nvar isIE = isBrowser ? !!document.documentElement.currentStyle : false;\nvar HIDDEN_TEXTAREA_STYLE = {\n  'min-height': '0',\n  'max-height': 'none',\n  height: '0',\n  visibility: 'hidden',\n  overflow: 'hidden',\n  position: 'absolute',\n  'z-index': '-1000',\n  top: '0',\n  right: '0'\n};\nvar SIZING_STYLE = ['letter-spacing', 'line-height', 'font-family', 'font-weight', 'font-size', 'font-style', 'tab-size', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-top', 'padding-right', 'padding-bottom', 'padding-left', 'border-top-width', 'border-right-width', 'border-bottom-width', 'border-left-width', 'box-sizing'];\nvar computedStyleCache = {};\nvar hiddenTextarea = isBrowser && document.createElement('textarea');\n\nvar forceHiddenStyles = function forceHiddenStyles(node) {\n  node.tabIndex = -1;\n  Object.keys(HIDDEN_TEXTAREA_STYLE).forEach(function (key) {\n    node.style.setProperty(key, HIDDEN_TEXTAREA_STYLE[key], 'important');\n  });\n};\n\nif (isBrowser) {\n  forceHiddenStyles(hiddenTextarea);\n}\n\nfunction calculateNodeHeight(uiTextNode, uid, useCache, minRows, maxRows) {\n  if (useCache === void 0) {\n    useCache = false;\n  }\n\n  if (minRows === void 0) {\n    minRows = null;\n  }\n\n  if (maxRows === void 0) {\n    maxRows = null;\n  }\n\n  if (hiddenTextarea.parentNode === null) {\n    document.body.appendChild(hiddenTextarea);\n  } // Copy all CSS properties that have an impact on the height of the content in\n  // the textbox\n\n\n  var nodeStyling = calculateNodeStyling(uiTextNode, uid, useCache);\n\n  if (nodeStyling === null) {\n    return null;\n  }\n\n  var paddingSize = nodeStyling.paddingSize,\n      borderSize = nodeStyling.borderSize,\n      boxSizing = nodeStyling.boxSizing,\n      sizingStyle = nodeStyling.sizingStyle; // Need to have the overflow attribute to hide the scrollbar otherwise\n  // text-lines will not calculated properly as the shadow will technically be\n  // narrower for content\n\n  Object.keys(sizingStyle).forEach(function (key) {\n    hiddenTextarea.style[key] = sizingStyle[key];\n  });\n  forceHiddenStyles(hiddenTextarea);\n  hiddenTextarea.value = uiTextNode.value || uiTextNode.placeholder || 'x';\n  var minHeight = -Infinity;\n  var maxHeight = Infinity;\n  var height = hiddenTextarea.scrollHeight;\n\n  if (boxSizing === 'border-box') {\n    // border-box: add border, since height = content + padding + border\n    height = height + borderSize;\n  } else if (boxSizing === 'content-box') {\n    // remove padding, since height = content\n    height = height - paddingSize;\n  } // measure height of a textarea with a single row\n\n\n  hiddenTextarea.value = 'x';\n  var singleRowHeight = hiddenTextarea.scrollHeight - paddingSize;\n\n  if (minRows !== null || maxRows !== null) {\n    if (minRows !== null) {\n      minHeight = singleRowHeight * minRows;\n\n      if (boxSizing === 'border-box') {\n        minHeight = minHeight + paddingSize + borderSize;\n      }\n\n      height = Math.max(minHeight, height);\n    }\n\n    if (maxRows !== null) {\n      maxHeight = singleRowHeight * maxRows;\n\n      if (boxSizing === 'border-box') {\n        maxHeight = maxHeight + paddingSize + borderSize;\n      }\n\n      height = Math.min(maxHeight, height);\n    }\n  }\n\n  var rowCount = Math.floor(height / singleRowHeight);\n  return {\n    height: height,\n    minHeight: minHeight,\n    maxHeight: maxHeight,\n    rowCount: rowCount\n  };\n}\n\nfunction calculateNodeStyling(node, uid, useCache) {\n  if (useCache === void 0) {\n    useCache = false;\n  }\n\n  if (useCache && computedStyleCache[uid]) {\n    return computedStyleCache[uid];\n  }\n\n  var style = window.getComputedStyle(node);\n\n  if (style === null) {\n    return null;\n  }\n\n  var sizingStyle = SIZING_STYLE.reduce(function (obj, name) {\n    obj[name] = style.getPropertyValue(name);\n    return obj;\n  }, {});\n  var boxSizing = sizingStyle['box-sizing']; // probably node is detached from DOM, can't read computed dimensions\n\n  if (boxSizing === '') {\n    return null;\n  } // IE (Edge has already correct behaviour) returns content width as computed width\n  // so we need to add manually padding and border widths\n\n\n  if (isIE && boxSizing === 'border-box') {\n    sizingStyle.width = parseFloat(sizingStyle.width) + parseFloat(style['border-right-width']) + parseFloat(style['border-left-width']) + parseFloat(style['padding-right']) + parseFloat(style['padding-left']) + 'px';\n  }\n\n  var paddingSize = parseFloat(sizingStyle['padding-bottom']) + parseFloat(sizingStyle['padding-top']);\n  var borderSize = parseFloat(sizingStyle['border-bottom-width']) + parseFloat(sizingStyle['border-top-width']);\n  var nodeInfo = {\n    sizingStyle: sizingStyle,\n    paddingSize: paddingSize,\n    borderSize: borderSize,\n    boxSizing: boxSizing\n  };\n\n  if (useCache) {\n    computedStyleCache[uid] = nodeInfo;\n  }\n\n  return nodeInfo;\n}\n\nvar purgeCache = function purgeCache(uid) {\n  return delete computedStyleCache[uid];\n};\n\nfunction autoInc(seed) {\n  if (seed === void 0) {\n    seed = 0;\n  }\n\n  return function () {\n    return ++seed;\n  };\n}\n\nvar uid = autoInc();\n\n/**\n * <TextareaAutosize />\n */\nvar noop = function noop() {}; // IE11 has a problem with eval source maps, can be reproduced with:\n// eval('\"use strict\"; var onNextFrame = window.cancelAnimationFrame; onNextFrame(4);')\n// so we bind window as context in dev modes\n\n\nvar _ref = isBrowser && window.requestAnimationFrame ? [window.requestAnimationFrame.bind(window), window.cancelAnimationFrame.bind(window)] : [setTimeout, clearTimeout];\nvar onNextFrame = _ref[0];\nvar clearNextFrameAction = _ref[1];\n\nvar TextareaAutosize =\n/*#__PURE__*/\nfunction (_React$Component) {\n  _inheritsLoose(TextareaAutosize, _React$Component);\n\n  function TextareaAutosize(props) {\n    var _this;\n\n    _this = _React$Component.call(this, props) || this;\n    _this._resizeLock = false;\n    _this._style = null;\n\n    _this._onRootDOMNode = function (node) {\n      _this._rootDOMNode = node;\n\n      _this.props.inputRef(node);\n    };\n\n    _this._onChange = function (event) {\n      if (!_this._controlled) {\n        _this._resizeComponent();\n      }\n\n      _this.props.onChange(event);\n    };\n\n    _this._resizeComponent = function (callback) {\n      if (callback === void 0) {\n        callback = noop;\n      }\n\n      if (typeof _this._rootDOMNode === 'undefined') {\n        callback();\n        return;\n      }\n\n      var nodeHeight = calculateNodeHeight(_this._rootDOMNode, _this._uid, _this.props.useCacheForDOMMeasurements, _this.props.minRows, _this.props.maxRows);\n\n      if (nodeHeight === null) {\n        callback();\n        return;\n      }\n\n      var height = nodeHeight.height,\n          minHeight = nodeHeight.minHeight,\n          maxHeight = nodeHeight.maxHeight,\n          rowCount = nodeHeight.rowCount;\n      _this.rowCount = rowCount;\n\n      if (_this.state.height !== height || _this.state.minHeight !== minHeight || _this.state.maxHeight !== maxHeight) {\n        _this.setState({\n          height: height,\n          minHeight: minHeight,\n          maxHeight: maxHeight\n        }, callback);\n\n        return;\n      }\n\n      callback();\n    };\n\n    _this.state = {\n      height: props.style && props.style.height || 0,\n      minHeight: -Infinity,\n      maxHeight: Infinity\n    };\n    _this._uid = uid();\n    _this._controlled = typeof props.value === 'string';\n    return _this;\n  }\n\n  var _proto = TextareaAutosize.prototype;\n\n  _proto.render = function render() {\n    var _props = this.props,\n        _inputRef = _props.inputRef,\n        _maxRows = _props.maxRows,\n        _minRows = _props.minRows,\n        _onHeightChange = _props.onHeightChange,\n        _useCacheForDOMMeasurements = _props.useCacheForDOMMeasurements,\n        props = _objectWithoutProperties(_props, [\"inputRef\", \"maxRows\", \"minRows\", \"onHeightChange\", \"useCacheForDOMMeasurements\"]);\n\n    var newStyle = _extends({}, props.style, {\n      height: this.state.height\n    });\n\n    var maxHeight = Math.max(newStyle.maxHeight || Infinity, this.state.maxHeight);\n\n    if (maxHeight < this.state.height) {\n      newStyle.overflow = 'hidden';\n    }\n\n    if (!shallowequal(this._style, newStyle)) {\n      this._style = newStyle;\n    }\n\n    props.style = this._style;\n    return React.createElement(\"textarea\", _extends({}, props, {\n      onChange: this._onChange,\n      ref: this._onRootDOMNode\n    }));\n  };\n\n  _proto.componentDidMount = function componentDidMount() {\n    var _this2 = this;\n\n    this._resizeComponent(); // Working around Firefox bug which runs resize listeners even when other JS is running at the same moment\n    // causing competing rerenders (due to setState in the listener) in React.\n    // More can be found here - facebook/react#6324\n\n\n    this._resizeListener = function () {\n      if (_this2._resizeLock) {\n        return;\n      }\n\n      _this2._resizeLock = true;\n\n      _this2._resizeComponent(function () {\n        return _this2._resizeLock = false;\n      });\n    };\n\n    window.addEventListener('resize', this._resizeListener);\n  };\n\n  _proto.componentDidUpdate = function componentDidUpdate(prevProps, prevState) {\n    var _this3 = this;\n\n    if (prevProps !== this.props) {\n      this._clearNextFrame();\n\n      this._onNextFrameActionId = onNextFrame(function () {\n        return _this3._resizeComponent();\n      });\n    }\n\n    if (this.state.height !== prevState.height) {\n      this.props.onHeightChange(this.state.height, this);\n    }\n  };\n\n  _proto.componentWillUnmount = function componentWillUnmount() {\n    this._clearNextFrame();\n\n    window.removeEventListener('resize', this._resizeListener);\n    purgeCache(this._uid);\n  };\n\n  _proto._clearNextFrame = function _clearNextFrame() {\n    clearNextFrameAction(this._onNextFrameActionId);\n  };\n\n  return TextareaAutosize;\n}(React.Component);\n\nTextareaAutosize.propTypes = {\n  inputRef: PropTypes.func,\n  maxRows: PropTypes.number,\n  minRows: PropTypes.number,\n  onChange: PropTypes.func,\n  onHeightChange: PropTypes.func,\n  useCacheForDOMMeasurements: PropTypes.bool,\n  value: PropTypes.string\n};\nTextareaAutosize.defaultProps = {\n  inputRef: noop,\n  onChange: noop,\n  onHeightChange: noop,\n  useCacheForDOMMeasurements: false\n};\n\nexports['default'] = TextareaAutosize;\n"]}