2019-11-15 14:59:14 +08:00
|
|
|
// tslint:disable-next-line:no-submodule-imports
|
|
|
|
import { addParameters, configure } from '@storybook/react';
|
2019-10-08 19:20:12 +08:00
|
|
|
import { create } from '@storybook/theming';
|
2019-11-15 14:59:14 +08:00
|
|
|
|
2019-10-08 19:20:12 +08:00
|
|
|
addParameters({
|
|
|
|
options: {
|
|
|
|
isFullscreen: false,
|
2019-12-17 11:14:31 +08:00
|
|
|
showAddonsPanel: false,
|
2019-10-08 19:20:12 +08:00
|
|
|
showSearchBox: false,
|
|
|
|
panelPosition: 'bottom',
|
|
|
|
hierarchySeparator: /\./,
|
2019-10-29 17:33:37 +08:00
|
|
|
// hierarchyRootSeparator: /\|/,
|
2019-10-08 19:20:12 +08:00
|
|
|
enableShortcuts: true,
|
|
|
|
theme: create({
|
|
|
|
base: 'light',
|
2019-12-07 01:43:18 +08:00
|
|
|
brandTitle: 'L7 for new architecture',
|
2019-12-07 23:14:59 +08:00
|
|
|
brandUrl: 'https://github.com/antvis/L7',
|
2019-10-08 19:20:12 +08:00
|
|
|
gridCellSize: 12,
|
2019-11-15 14:59:14 +08:00
|
|
|
}),
|
2019-10-08 19:20:12 +08:00
|
|
|
},
|
|
|
|
});
|
|
|
|
|
|
|
|
// automatically import all files ending in *.stories.tsx
|
2022-08-02 19:05:27 +08:00
|
|
|
|
2022-07-28 19:05:51 +08:00
|
|
|
// const req = require.context('../stories', true, /\.stories\.tsx$/);
|
2022-08-03 19:08:46 +08:00
|
|
|
// const req = require.context('../stories/layerbuild', true, /\.stories\.tsx$/);
|
2022-08-08 16:32:50 +08:00
|
|
|
// const req = require.context('../stories/Map', true, /\.stories\.tsx$/);
|
|
|
|
const req = require.context('../stories/template', true, /\.stories\.tsx$/);
|
2022-08-02 19:05:27 +08:00
|
|
|
// const req = require.context('../stories/MapPerformance', true, /\.stories\.tsx$/);
|
2022-07-29 14:19:57 +08:00
|
|
|
// const req = require.context('../stories/tile', true, /\.stories\.tsx$/);
|
2019-10-08 19:20:12 +08:00
|
|
|
|
|
|
|
function loadStories() {
|
|
|
|
req.keys().forEach(req);
|
|
|
|
}
|
|
|
|
|
|
|
|
configure(loadStories, module);
|