1 | "use strict";
|
2 |
|
3 | function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
4 |
|
5 | require("core-js/modules/es.array.iterator.js");
|
6 |
|
7 | require("core-js/modules/es.object.to-string.js");
|
8 |
|
9 | require("core-js/modules/es.string.iterator.js");
|
10 |
|
11 | require("core-js/modules/es.weak-map.js");
|
12 |
|
13 | require("core-js/modules/web.dom-collections.iterator.js");
|
14 |
|
15 | require("core-js/modules/es.object.get-own-property-descriptor.js");
|
16 |
|
17 | require("core-js/modules/es.symbol.js");
|
18 |
|
19 | require("core-js/modules/es.symbol.description.js");
|
20 |
|
21 | require("core-js/modules/es.symbol.iterator.js");
|
22 |
|
23 | require("core-js/modules/es.function.name.js");
|
24 |
|
25 | var _addons = require("@storybook/addons");
|
26 |
|
27 | var _constants = _interopRequireWildcard(require("./constants"));
|
28 |
|
29 | function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
30 |
|
31 | function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
32 |
|
33 | _addons.addons.register(_constants.ADDON_ID, function (api) {
|
34 | var channel = _addons.addons.getChannel();
|
35 |
|
36 | channel.on(_constants.default.REQUEST, function (_ref) {
|
37 | var kind = _ref.kind,
|
38 | name = _ref.name;
|
39 | var id = api.storyId(kind, name);
|
40 | api.emit(_constants.default.RECEIVE, id);
|
41 | });
|
42 | }); |
\ | No newline at end of file |