Liferay.Loader.define("layout-content-page-editor-web@2.0.110/page_editor/common/components/Textarea", ['module', 'exports', 'require', 'frontend-js-react-web$classnames', 'frontend-js-react-web$prop-types', 'frontend-js-react-web$react'], function (module, exports, require) {
  var define = undefined;
  var global = window;
  {
    Object.defineProperty(exports, "__esModule", {
      value: true
    });
    exports.default = Textarea;

    var _classnames = _interopRequireDefault(require("frontend-js-react-web$classnames"));

    var _propTypes = _interopRequireDefault(require("frontend-js-react-web$prop-types"));

    var _react = _interopRequireDefault(require("frontend-js-react-web$react"));

    function _interopRequireDefault(obj) {
      return obj && obj.__esModule ? obj : { default: obj };
    }

    function _extends() {
      _extends = Object.assign || function (target) {
        for (var i = 1; i < arguments.length; i++) {
          var source = arguments[i];for (var key in source) {
            if (Object.prototype.hasOwnProperty.call(source, key)) {
              target[key] = source[key];
            }
          }
        }return target;
      };return _extends.apply(this, arguments);
    }

    function _objectWithoutProperties(source, excluded) {
      if (source == null) return {};var target = _objectWithoutPropertiesLoose(source, excluded);var key, i;if (Object.getOwnPropertySymbols) {
        var sourceSymbolKeys = Object.getOwnPropertySymbols(source);for (i = 0; i < sourceSymbolKeys.length; i++) {
          key = sourceSymbolKeys[i];if (excluded.indexOf(key) >= 0) continue;if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;target[key] = source[key];
        }
      }return target;
    }

    function _objectWithoutPropertiesLoose(source, excluded) {
      if (source == null) return {};var target = {};var sourceKeys = Object.keys(source);var key, i;for (i = 0; i < sourceKeys.length; i++) {
        key = sourceKeys[i];if (excluded.indexOf(key) >= 0) continue;target[key] = source[key];
      }return target;
    }

    function Textarea(_ref) {
      var _ref$autoFocus = _ref.autoFocus,
          autoFocus = _ref$autoFocus === void 0 ? false : _ref$autoFocus,
          _ref$value = _ref.value,
          value = _ref$value === void 0 ? '' : _ref$value,
          props = _objectWithoutProperties(_ref, ["autoFocus", "value"]);

      return (/*#__PURE__*/_react.default.createElement("textarea", _extends({
          className: (0, _classnames.default)('form-control', 'page-editor__textarea', {
            'page-editor__textarea--empty': !value
          }),
          ref: function ref(textarea) {
            return autoFocus && textarea && textarea.focus();
          }
        }, props))
      );
    }
    //# sourceMappingURL=Textarea.js.map
  }
});
//# sourceMappingURL=Textarea.js.map