'use strict';

require('core-js/modules/es.symbol.js');
require('core-js/modules/es.symbol.description.js');
var React = require('react');
var PropTypes = require('prop-types');
var Settings = require('../../constants/Settings.js');

function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }

var React__default = /*#__PURE__*/_interopDefault(React);
var PropTypes__default = /*#__PURE__*/_interopDefault(PropTypes);

var iotPrefix = Settings.settings.iotPrefix;
var propTypes = {
  /** optional icon to visually describe catalog item */
  icon: PropTypes__default.default.node,
  title: PropTypes__default.default.string.isRequired,
  description: PropTypes__default.default.node
};
var defaultProps = {
  icon: null,
  description: null
};
/** Reusable widget to show Catalog contents in a tile catalog */
var CatalogContent = function CatalogContent(_ref) {
  var icon = _ref.icon,
    title = _ref.title,
    description = _ref.description;
  return /*#__PURE__*/React__default.default.createElement("div", {
    className: "".concat(iotPrefix, "--sample-tile")
  }, icon ? /*#__PURE__*/React__default.default.createElement("div", {
    className: "".concat(iotPrefix, "--sample-tile-icon")
  }, icon) : null, /*#__PURE__*/React__default.default.createElement("div", {
    className: "".concat(iotPrefix, "--sample-tile-contents")
  }, /*#__PURE__*/React__default.default.createElement("div", {
    className: "".concat(iotPrefix, "--sample-tile-title")
  }, /*#__PURE__*/React__default.default.createElement("span", {
    title: title
  }, title)), /*#__PURE__*/React__default.default.createElement("div", {
    className: "".concat(iotPrefix, "--sample-tile-description")
  }, description)));
};
CatalogContent.propTypes = propTypes;
CatalogContent.defaultProps = defaultProps;
CatalogContent.__docgenInfo = {
  "description": "Reusable widget to show Catalog contents in a tile catalog",
  "methods": [],
  "displayName": "CatalogContent",
  "props": {
    "icon": {
      "defaultValue": {
        "value": "null",
        "computed": false
      },
      "description": "optional icon to visually describe catalog item",
      "type": {
        "name": "node"
      },
      "required": false
    },
    "description": {
      "defaultValue": {
        "value": "null",
        "computed": false
      },
      "description": "",
      "type": {
        "name": "node"
      },
      "required": false
    },
    "title": {
      "description": "",
      "type": {
        "name": "string"
      },
      "required": true
    }
  }
};
var CatalogContent$1 = CatalogContent;

module.exports = CatalogContent$1;
