import { u as useViewHandler } from './index-bbdfb97a.js';
import { observer } from 'mobx-react-lite';
import 'react';
import { t as tabgroupWrapper, a as tablet, m as mobile, b as tabgroupTitle, o as optionWrapper, O as OptionItem } from './index-4dcb67ed.js';
import classnames from 'classnames';
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
import '@babel/runtime/helpers/defineProperty';
import 'react-dynamic-multi-render';
import '@crystaldesign/diva-core';
import '@babel/runtime/helpers/asyncToGenerator';
import '@babel/runtime/helpers/slicedToArray';
import '@babel/runtime/helpers/objectWithoutProperties';
import '@babel/runtime/regenerator';
import '@babel/runtime/helpers/classCallCheck';
import '@babel/runtime/helpers/createClass';
import '@babel/runtime/helpers/toConsumableArray';
import '@crystaldesign/diva-utils';
import 'mobx';
import '@crystaldesign/web-planner-logic';
import 'qrcode.react';
import '@babel/runtime/helpers/typeof';
import 'flat';
import 'react-switch';
import 'react-countup';
import './index-04a7a9b4.js';
import './index-ea5e3e90.js';

var Summary = function Summary(_ref) {
  var itemP = _ref.item;
  var viewHandler = useViewHandler();
  var item = itemP;
  if (!item.isTabGroup) return /*#__PURE__*/jsx(Fragment, {});
  if (item.isTabGroup) {
    var _item$summaryItems;
    return /*#__PURE__*/jsxs("div", {
      className: classnames(tabgroupWrapper, viewHandler.uiState.isTablet ? tablet : undefined, viewHandler.uiState.isInMobileView ? mobile : undefined),
      children: [/*#__PURE__*/jsx("div", {
        className: tabgroupTitle,
        children: item.title
      }), /*#__PURE__*/jsx("div", {
        className: optionWrapper,
        children: Object.values((_item$summaryItems = item.summaryItems) !== null && _item$summaryItems !== void 0 ? _item$summaryItems : {}).map(function (option, index) {
          return /*#__PURE__*/jsx(OptionItem, {
            option: option
          }, index);
        })
      })]
    });
  }
  return /*#__PURE__*/jsx(Fragment, {});
};
var index = observer(Summary);

export { index as default };
