import _extends from "@babel/runtime/helpers/extends";
var _jsxFileName = "/home/builduser/work/57e038ea7326c1ec/packages/wix-design-system/dist/esm/SelectableAccordion/test/SelectableAccordion.visual.jsx",
  _this = this;
import React from 'react';
import { storiesOf } from '@storybook/react';
import SelectableAccordion from '../SelectableAccordion';
import { TYPES, VERTICAL_PADDING } from '../constants';
var types = Object.values(TYPES);
var verticalPaddingOptions = Object.values(VERTICAL_PADDING);
var items = [{
  title: 'Title1',
  content: 'Content1'
}, {
  title: 'Title2',
  content: 'Content2'
}, {
  title: 'Title3',
  content: 'Content3'
}];
var commonProps = {
  items: items
};
var tests = [{
  describe: 'Sanity',
  its: [{
    it: 'default',
    props: {}
  }, {
    it: 'initiallyOpen',
    props: {
      items: [{
        title: 'Title1',
        content: 'Content1',
        initiallyOpen: true
      }, {
        title: 'Title2',
        content: 'Content2'
      }]
    }
  }]
}, {
  describe: 'type',
  its: types.map(function (type) {
    return {
      it: type,
      props: {
        type: type
      }
    };
  })
}, {
  describe: 'verticalPadding',
  its: verticalPaddingOptions.map(function (verticalPadding) {
    return {
      it: verticalPadding,
      props: {
        verticalPadding: verticalPadding
      }
    };
  })
}, {
  describe: 'Content',
  its: [{
    it: 'no content',
    props: {
      type: TYPES.CHECKBOX,
      items: [{
        title: 'Title1',
        open: true
      }, {
        title: 'Title2',
        content: 'Content',
        open: true
      }]
    }
  }]
}];
tests.forEach(function (_ref) {
  var describe = _ref.describe,
    its = _ref.its;
  its.forEach(function (_ref2) {
    var it = _ref2.it,
      props = _ref2.props;
    storiesOf("".concat(SelectableAccordion.displayName).concat(describe ? '/' + describe : ''), module).add(it, function () {
      return /*#__PURE__*/React.createElement(SelectableAccordion, _extends({}, commonProps, props, {
        __self: _this,
        __source: {
          fileName: _jsxFileName,
          lineNumber: 66,
          columnNumber: 21
        }
      }));
    });
  });
});