UNPKG

1.14 kBJavaScriptView Raw
1"use strict";
2
3require("core-js/modules/es.object.assign");
4
5Object.defineProperty(exports, "__esModule", {
6 value: true
7});
8exports["default"] = void 0;
9
10var _mithril = _interopRequireDefault(require("mithril"));
11
12var _addons = require("@storybook/addons");
13
14var _parameters = _interopRequireDefault(require("./parameters"));
15
16var _styles = _interopRequireDefault(require("./styles"));
17
18function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
19
20/** @jsx m */
21
22/* eslint-disable import/no-extraneous-dependencies */
23function centered(storyFn) {
24 return {
25 view: function view() {
26 return (0, _mithril["default"])("div", {
27 style: _styles["default"].style
28 }, (0, _mithril["default"])("div", {
29 style: _styles["default"].innerStyle
30 }, (0, _mithril["default"])(storyFn())));
31 }
32 };
33}
34
35var _default = (0, _addons.makeDecorator)(Object.assign({}, _parameters["default"], {
36 wrapper: function wrapper(getStory) {
37 return centered(getStory);
38 }
39}));
40
41exports["default"] = _default;
42
43if (module && module.hot && module.hot.decline) {
44 module.hot.decline();
45}
\No newline at end of file