import './_commonjsHelpers-0c4b6f40.js';
import './_to-object-ded78eb9.js';
import './es6.string.iterator-9b2af4a5.js';
import './_library-528f1934.js';
import './core.get-iterator-method-54d2e411.js';
import './_object-pie-71ac75a4.js';
import './extends-cc5da797.js';
import './web.dom.iterable-8956f9a5.js';
import './typeof-08f2c380.js';
import './_is-array-49698029.js';
import React__default from 'react';
import 'prop-types';
import 'react-dom';
import './index-73819142.js';
import './index-5f9f807a.js';
import './slicedToArray-7021e5df.js';
import './smoothscroll-4b699764.js';
import './YoutubeGroup.js';
import ArticleCarousel from './ArticleCarousel.js';

function BrowseVideosListing(_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__default.createElement(
    'div',
    null,
    data && data.map(function (taxonomy, index) {
      return React__default.createElement(
        'div',
        { key: 'articleCarousel_' + taxonomy.identifier + '_' + index, className: 'mb-5' },
        React__default.createElement(
          'div',
          { style: { borderBottom: '3px solid ' + color } },
          React__default.createElement(
            'h3',
            { style: { color: color, marginBottom: '.25rem' } },
            taxonomy.name
          ),
          taxonomy.identifier && React__default.createElement(
            'p',
            { style: { width: 'fit-content', marginBottom: '.25rem' } },
            React__default.createElement(
              'a',
              { href: '/' + taxonomy.identifier },
              'View All >'
            )
          )
        ),
        taxonomy.data && React__default.createElement(
          'div',
          null,
          React__default.createElement(ArticleCarousel, { articles: taxonomy.data, client: client })
        )
      );
    })
  );
}

export default BrowseVideosListing;
