'use strict';

var _defineProperty = require('@babel/runtime/helpers/defineProperty');
var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProperties');
var classnames = require('classnames');
var injectCss = require('./inject-css-B6qYtOJe.js');
var jsxRuntime = require('react/jsx-runtime');

var SIZES = {
  nano: "nano",
  small: "small",
  medium: "medium",
  large: "large",
  viewport: "viewport"
};

var css = ".neeto-molecules-scrollable{flex-grow:1;overflow-y:auto}.neeto-molecules-scrollable.neeto-molecules-scrollable--nano,.neeto-molecules-scrollable.neeto-molecules-scrollable--small{height:calc(100vh - var(--neeto-molecules-effective-header-height) - var(--neeto-molecules-effective-subheader-height) - var(--neeto-molecules-sub-header-bottom-margin));height:calc(100dvh - var(--neeto-molecules-effective-header-height) - var(--neeto-molecules-effective-subheader-height) - var(--neeto-molecules-sub-header-bottom-margin))}.neeto-molecules-scrollable.neeto-molecules-scrollable--large,.neeto-molecules-scrollable.neeto-molecules-scrollable--medium{height:calc(100vh - var(--neeto-molecules-effective-header-height));height:calc(100dvh - var(--neeto-molecules-effective-header-height))}.neeto-molecules-scrollable.neeto-molecules-scrollable--viewport{height:100vh;height:100dvh}";
injectCss.n(css,{});

var _excluded = ["children", "className", "size"];
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), true).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
var Scrollable = function Scrollable(_ref) {
  var children = _ref.children,
    _ref$className = _ref.className,
    className = _ref$className === void 0 ? "" : _ref$className,
    _ref$size = _ref.size,
    size = _ref$size === void 0 ? "small" : _ref$size,
    otherProps = _objectWithoutProperties(_ref, _excluded);
  return /*#__PURE__*/jsxRuntime.jsx("div", _objectSpread(_objectSpread({
    className: classnames(["neeto-molecules-scrollable", _defineProperty({
      "neeto-molecules-scrollable--nano": size === SIZES.nano,
      "neeto-molecules-scrollable--small": size === SIZES.small,
      "neeto-molecules-scrollable--medium": size === SIZES.medium,
      "neeto-molecules-scrollable--large": size === SIZES.large,
      "neeto-molecules-scrollable--viewport": size === SIZES.viewport
    }, className, className)])
  }, otherProps), {}, {
    children: children
  }));
};

module.exports = Scrollable;
//# sourceMappingURL=Scrollable.js.map
