import './_commonjsHelpers-0c4b6f40.js';
import './_to-object-a4107da3.js';
import './es6.string.iterator-c990c18c.js';
import './_library-528f1934.js';
import './_iter-detect-5d49a330.js';
import './toConsumableArray-43aa614d.js';
import './core.get-iterator-method-e1de7503.js';
import './_object-pie-33c40e79.js';
import { _ as _extends } from './extends-6f2fcc99.js';
import './_object-sap-964b6feb.js';
import './inherits-75d45541.js';
import './define-property-8af5f002.js';
import './web.dom.iterable-4439f05a.js';
import './typeof-af9c50d8.js';
import './_is-array-58e95429.js';
import React from 'react';
import './index-acfb8079.js';
import 'prop-types';
import 'react-bootstrap/Row';
import 'react-bootstrap/Col';
import './moment-b6f49411.js';
import 'next/router';
import './isSymbol-1981418f.js';
import './debounce-9207d8ee.js';
import './toNumber-2f7a84cd.js';
import 'react-dom';
import './index-51a80699.js';
import './index-6c12bdd5.js';
import './main-747e7d25.js';
import './entities-7cc3bf45.js';
import './slicedToArray-641f241f.js';
import './stringify-4330ccdc.js';
import './asyncToGenerator-fc1c2e29.js';
import './Segment.js';
import './Beam.js';
import './AdSlot.js';
import { B as BlockContent } from './BlockContent-d05b5b23.js';
import './index-c7e2ac95.js';
import './smoothscroll-0cd4c7a6.js';
import './GroupDeck.js';
import './YoutubeGroup.js';
import 'react-bootstrap';
import './iconBase-602d52fe.js';
import { I as IoIosArrowForward } from './index.esm-3fdda599.js';
import ArticleCarousel from './ArticleCarousel.js';
import { g as getSerializers } from './index-52068e2b.js';
import './util-7700fc59.js';
import './brightcove-react-player-loader.es-4abff0b1.js';
import 'next/head';
import 'react-share';
import './SocialShare.js';
import './_object-to-array-7e804fce.js';
import 'react-bootstrap/Pagination';
import 'react-bootstrap/Button';
import 'react-bootstrap/Figure';

function HorizontalArticleListing(_ref) {
  var _ref$data = _ref.data,
      data = _ref$data === undefined ? null : _ref$data,
      _ref$client = _ref.client,
      client = _ref$client === undefined ? null : _ref$client,
      _ref$color = _ref.color,
      color = _ref$color === undefined ? '#FFFFFF' : _ref$color;

  // Look at AJMC for query setup
  // Data format = Array of Objects based on Taxonomies with videos and latest videos
  // {
  // name: ...,
  // identifier: ...,
  // data: Array of latest articles with videos
  // }
  return React.createElement(
    'div',
    null,
    data.length > 0 ? data.map(function (taxonomy, index) {
      return React.createElement(
        React.Fragment,
        null,
        React.createElement(
          'div',
          { key: 'articleCarousel_' + taxonomy.identifier + '_' + index, className: 'mb-3 horizontal-article' },
          React.createElement(
            'div',
            { className: 'horizontal-article-header', style: { borderBottom: '2px solid ' + color } },
            React.createElement(
              'div',
              { className: 'horizontal-article-title-wrapper' },
              React.createElement(
                'a',
                { href: '/' + taxonomy.identifier },
                React.createElement(
                  'h4',
                  { className: 'article-title-banner', style: { fontWeight: 'bold', color: 'var(--primary)', padding: '.25rem 0', margin: '0' } },
                  taxonomy.name
                )
              ),
              taxonomy.identifier && React.createElement(
                'div',
                { style: { width: 'fit-content', whiteSpace: 'nowrap' } },
                React.createElement(
                  'a',
                  { href: '/' + taxonomy.identifier },
                  'View All ',
                  React.createElement(IoIosArrowForward, null)
                )
              )
            ),
            taxonomy.summary && React.createElement(
              'div',
              { className: 'horizontal-article-summary' },
              React.createElement(BlockContent, _extends({ serializers: getSerializers(client), blocks: taxonomy.summary, imageOptions: { w: 320, h: 240, fit: 'max' } }, client.config()))
            )
          ),
          taxonomy.data.length > 0 ? React.createElement(
            'div',
            { className: 'article-carousel' },
            React.createElement(ArticleCarousel, { articles: taxonomy.data, client: client })
          ) : React.createElement(
            'div',
            null,
            React.createElement(
              'h5',
              { className: 'mt-2' },
              React.createElement(
                'em',
                { className: 'pl-3' },
                'New content coming soon, please check back later.'
              )
            )
          )
        ),
        React.createElement(
          'style',
          { jsx: 'true' },
          '\n                .article-carousel {\n                  display: flex;\n                  align-items: center;\n                  justify-content: center;\n                }\n                .horizontal-article-title-wrapper {\n                  display: flex;\n                  flex-wrap: no-wrap;\n                  align-items: center;\n                  justify-content: space-between;\n                }\n              '
        )
      );
    }) : React.createElement(
      'div',
      null,
      React.createElement(
        'h5',
        null,
        React.createElement(
          'em',
          { className: 'pl-3' },
          'New content coming soon, please check back later.'
        )
      )
    )
  );
}

export default HorizontalArticleListing;
