"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;

var _react = _interopRequireDefault(require("react"));

var _sidebarResource = _interopRequireDefault(require("./sidebar-resource"));

var _designSystem = require("../../design-system");

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

class SidebarParent extends _react.default.PureComponent {
  render() {
    const {
      parent
    } = this.props;
    const {
      icon,
      name,
      resources
    } = parent;
    return _react.default.createElement(_designSystem.NavGroup, {
      icon: icon,
      title: name
    }, resources.map(resource => _react.default.createElement(_sidebarResource.default, {
      resource: resource,
      key: resource.id
    })));
  }

}

var _default = SidebarParent;
exports.default = _default;