'use strict';

var _react = require('react');

var _react2 = _interopRequireDefault(_react);

var _react3 = require('@storybook/react');

var _addonKnobs = require('@storybook/addon-knobs');

var _index = require('./index');

var _index2 = _interopRequireDefault(_index);

var _ListingTable = require('./ListingTable.md');

var _ListingTable2 = _interopRequireDefault(_ListingTable);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

(0, _react3.storiesOf)('molecules', module).addDecorator((0, _addonKnobs.withKnobs)({ escapeHTML: false })).add('ListingTable', function () {
  var props = {
    rows: (0, _addonKnobs.object)('Data Rows', [{
      label: 'Show 2 items',
      items: ['First item', 'Second item']
    }, {
      label: 'Four items, but only show 2 (default)',
      moreLabel: 'show more',
      lessLabel: 'show less',
      items: ['Item 1', 'Item 2', 'Item 3 (expand)', 'Item 4 (expand)']
    }, {
      label: 'Four items, show 3, default lables',
      visibleItems: 3,
      items: ['Item 1', 'Item 2', 'Item 3 (expand)', 'Item 4 (expand)']
    }, {
      label: 'Show all 4 items',
      visibleItems: 4,
      items: ['Item 1', 'Item 2', 'Item 3', 'Item 4']
    }])
  };
  return _react2.default.createElement(_index2.default, props);
}, { info: _ListingTable2.default });