wix-storybook-utils
Version:
Utilities for automated component documentation within Storybook
10 lines • 564 B
JavaScript
import * as React from 'react';
import { SectionType } from '../../typings/story-section';
import { getView } from './tab';
import TabbedView from '../../TabbedView';
var styles = require('./styles.scss');
export var tabs = function (_a, storyConfig) {
var tabsToShow = _a.tabs;
return (React.createElement(TabbedView, { tabs: tabsToShow.map(function (tab) { return tab.title; }), className: styles.tab, children: tabsToShow.map(function (tab) { return getView(SectionType.Tab)(tab, storyConfig); }), showTabs: true }));
};
//# sourceMappingURL=tabs.js.map