@storybook/html-webpack5 7.0.0-alpha.4 → 7.0.0-alpha.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,4 @@
1
+ export * from '@storybook/html';
2
+ export { F as FrameworkOptions, S as StorybookConfig } from './types-7999a258.js';
3
+ import '@storybook/preset-html-webpack';
4
+ import '@storybook/builder-webpack5';
package/dist/index.js ADDED
@@ -0,0 +1 @@
1
+ var a=Object.defineProperty;var b=Object.getOwnPropertyDescriptor;var c=Object.getOwnPropertyNames;var d=Object.prototype.hasOwnProperty;var f=(r,o,x,m)=>{if(o&&typeof o=="object"||typeof o=="function")for(let p of c(o))!d.call(r,p)&&p!==x&&a(r,p,{get:()=>o[p],enumerable:!(m=b(o,p))||m.enumerable});return r},t=(r,o,x)=>(f(r,o,"default"),x&&f(x,o,"default"));var g=r=>f(a({},"__esModule",{value:!0}),r);var e={};module.exports=g(e);t(e,require("@storybook/html"),module.exports);
package/dist/index.mjs ADDED
@@ -0,0 +1 @@
1
+ export*from"@storybook/html";
@@ -0,0 +1,9 @@
1
+ import { PresetProperty } from '@storybook/core-common';
2
+ import { S as StorybookConfig } from './types-7999a258.js';
3
+ import '@storybook/preset-html-webpack';
4
+ import '@storybook/builder-webpack5';
5
+
6
+ declare const addons: PresetProperty<'addons', StorybookConfig>;
7
+ declare const core: PresetProperty<'core', StorybookConfig>;
8
+
9
+ export { addons, core };
package/dist/preset.js ADDED
@@ -0,0 +1 @@
1
+ var d=Object.create;var s=Object.defineProperty,u=Object.defineProperties,j=Object.getOwnPropertyDescriptor,y=Object.getOwnPropertyDescriptors,w=Object.getOwnPropertyNames,i=Object.getOwnPropertySymbols,f=Object.getPrototypeOf,c=Object.prototype.hasOwnProperty,g=Object.prototype.propertyIsEnumerable;var p=(e,o,r)=>o in e?s(e,o,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[o]=r,k=(e,o)=>{for(var r in o||(o={}))c.call(o,r)&&p(e,r,o[r]);if(i)for(var r of i(o))g.call(o,r)&&p(e,r,o[r]);return e},m=(e,o)=>u(e,y(o)),l=(e,o)=>s(e,"name",{value:o,configurable:!0});var h=(e,o)=>{for(var r in o)s(e,r,{get:o[r],enumerable:!0})},b=(e,o,r,n)=>{if(o&&typeof o=="object"||typeof o=="function")for(let t of w(o))!c.call(e,t)&&t!==r&&s(e,t,{get:()=>o[t],enumerable:!(n=j(o,t))||n.enumerable});return e};var q=(e,o,r)=>(r=e!=null?d(f(e)):{},b(o||!e||!e.__esModule?s(r,"default",{value:e,enumerable:!0}):r,e)),v=e=>b(s({},"__esModule",{value:!0}),e);var A={};h(A,{addons:()=>x,core:()=>z});module.exports=v(A);var a=q(require("path")),x=[a.default.dirname(require.resolve(a.default.join("@storybook/preset-html-webpack","package.json"))),a.default.dirname(require.resolve(a.default.join("@storybook/html","package.json")))],z=l(async(e,o)=>{let r=await o.presets.apply("framework");return m(k({},e),{builder:{name:a.default.dirname(require.resolve(a.default.join("@storybook/builder-webpack5","package.json"))),options:typeof r=="string"?{}:r.options.builder||{}}})},"core");0&&(module.exports={addons,core});
@@ -0,0 +1 @@
1
+ var i=Object.defineProperty,m=Object.defineProperties;var l=Object.getOwnPropertyDescriptors;var t=Object.getOwnPropertySymbols;var b=Object.prototype.hasOwnProperty,d=Object.prototype.propertyIsEnumerable;var n=(e,o,r)=>o in e?i(e,o,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[o]=r,p=(e,o)=>{for(var r in o||(o={}))b.call(o,r)&&n(e,r,o[r]);if(t)for(var r of t(o))d.call(o,r)&&n(e,r,o[r]);return e},c=(e,o)=>m(e,l(o)),k=(e,o)=>i(e,"name",{value:o,configurable:!0}),s=(e=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(e,{get:(o,r)=>(typeof require!="undefined"?require:o)[r]}):e)(function(e){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});import a from"path";var f=[a.dirname(s.resolve(a.join("@storybook/preset-html-webpack","package.json"))),a.dirname(s.resolve(a.join("@storybook/html","package.json")))],g=k(async(e,o)=>{let r=await o.presets.apply("framework");return c(p({},e),{builder:{name:a.dirname(s.resolve(a.join("@storybook/builder-webpack5","package.json"))),options:typeof r=="string"?{}:r.options.builder||{}}})},"core");export{f as addons,g as core};
@@ -0,0 +1,27 @@
1
+ import { StorybookConfig as StorybookConfig$1, TypescriptOptions as TypescriptOptions$1 } from '@storybook/preset-html-webpack';
2
+ import { BuilderOptions, StorybookConfigWebpack, TypescriptOptions } from '@storybook/builder-webpack5';
3
+
4
+ declare type FrameworkName = '@storybook/html-webpack5';
5
+ declare type BuilderName = '@storybook/builder-webpack5';
6
+ declare type FrameworkOptions = {
7
+ builder?: BuilderOptions;
8
+ };
9
+ declare type StorybookConfigFramework = {
10
+ framework: FrameworkName | {
11
+ name: FrameworkName;
12
+ options: FrameworkOptions;
13
+ };
14
+ core?: StorybookConfig$1['core'] & {
15
+ builder?: BuilderName | {
16
+ name: BuilderName;
17
+ options: BuilderOptions;
18
+ };
19
+ };
20
+ typescript?: Partial<TypescriptOptions & TypescriptOptions$1> & StorybookConfig$1['typescript'];
21
+ };
22
+ /**
23
+ * The interface for Storybook configuration in `main.ts` files.
24
+ */
25
+ declare type StorybookConfig = Omit<StorybookConfig$1, keyof StorybookConfigWebpack | keyof StorybookConfigFramework> & StorybookConfigWebpack & StorybookConfigFramework;
26
+
27
+ export { FrameworkOptions as F, StorybookConfig as S };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/html-webpack5",
3
- "version": "7.0.0-alpha.4",
3
+ "version": "7.0.0-alpha.7",
4
4
  "description": "Storybook for HTML: View HTML snippets in isolation with Hot Reloading.",
5
5
  "keywords": [
6
6
  "storybook"
@@ -19,9 +19,26 @@
19
19
  "url": "https://opencollective.com/storybook"
20
20
  },
21
21
  "license": "MIT",
22
- "main": "dist/cjs/index.js",
23
- "module": "dist/esm/index.js",
24
- "types": "dist/types/index.d.ts",
22
+ "exports": {
23
+ ".": {
24
+ "require": "./dist/index.js",
25
+ "import": "./dist/index.mjs",
26
+ "types": "./dist/index.d.ts"
27
+ },
28
+ "./preset": {
29
+ "require": "./dist/preset.js",
30
+ "import": "./dist/preset.mjs",
31
+ "types": "./dist/preset.d.ts"
32
+ },
33
+ "./package.json": {
34
+ "require": "./package.json",
35
+ "import": "./package.json",
36
+ "types": "./package.json"
37
+ }
38
+ },
39
+ "main": "dist/index.js",
40
+ "module": "dist/index.mjs",
41
+ "types": "dist/index.d.ts",
25
42
  "files": [
26
43
  "dist/**/*",
27
44
  "README.md",
@@ -29,19 +46,22 @@
29
46
  "*.d.ts"
30
47
  ],
31
48
  "scripts": {
32
- "prepare": "node ../../scripts/prepare.js"
49
+ "prepare": "esrun ../../scripts/prepare/bundle.ts"
33
50
  },
34
51
  "dependencies": {
35
- "@storybook/builder-webpack5": "7.0.0-alpha.4",
36
- "@storybook/core-common": "7.0.0-alpha.4",
37
- "@storybook/html": "7.0.0-alpha.4",
38
- "@storybook/preset-html-webpack": "7.0.0-alpha.4",
52
+ "@storybook/builder-webpack5": "7.0.0-alpha.7",
53
+ "@storybook/core-common": "7.0.0-alpha.7",
54
+ "@storybook/html": "7.0.0-alpha.7",
55
+ "@storybook/preset-html-webpack": "7.0.0-alpha.7",
39
56
  "@types/node": "^14.14.20 || ^16.0.0",
40
57
  "core-js": "^3.8.2",
41
58
  "global": "^4.4.0",
42
59
  "react": "16.14.0",
43
60
  "react-dom": "16.14.0"
44
61
  },
62
+ "devDependencies": {
63
+ "@digitak/esrun": "^3.2.2"
64
+ },
45
65
  "peerDependencies": {
46
66
  "@babel/core": "*"
47
67
  },
@@ -51,5 +71,9 @@
51
71
  "publishConfig": {
52
72
  "access": "public"
53
73
  },
54
- "gitHead": "006ed54452dd7c37a8cbe91a84f5312182f7ca00"
74
+ "bundlerEntrypoint": [
75
+ "./src/index.ts",
76
+ "./src/preset.ts"
77
+ ],
78
+ "gitHead": "d334cabd251cd0ed8b845a87707dc84f007d4074"
55
79
  }
package/preset.js CHANGED
@@ -1 +1 @@
1
- module.exports = require('./dist/cjs/preset');
1
+ module.exports = require('./dist/preset');
package/dist/cjs/index.js DELETED
@@ -1,18 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
-
7
- var _html = require("@storybook/html");
8
-
9
- Object.keys(_html).forEach(function (key) {
10
- if (key === "default" || key === "__esModule") return;
11
- if (key in exports && exports[key] === _html[key]) return;
12
- Object.defineProperty(exports, key, {
13
- enumerable: true,
14
- get: function () {
15
- return _html[key];
16
- }
17
- });
18
- });
@@ -1,16 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.core = exports.addons = void 0;
7
- const addons = ['@storybook/preset-html-webpack', '@storybook/html'];
8
- exports.addons = addons;
9
-
10
- const core = async config => {
11
- return Object.assign({}, config, {
12
- builder: require.resolve('@storybook/builder-webpack5')
13
- });
14
- };
15
-
16
- exports.core = core;
package/dist/esm/index.js DELETED
@@ -1 +0,0 @@
1
- export * from '@storybook/html';
@@ -1,6 +0,0 @@
1
- export const addons = ['@storybook/preset-html-webpack', '@storybook/html'];
2
- export const core = async config => {
3
- return Object.assign({}, config, {
4
- builder: require.resolve('@storybook/builder-webpack5')
5
- });
6
- };
@@ -1 +0,0 @@
1
- export * from '@storybook/html';
@@ -1,11 +0,0 @@
1
- import type { StorybookConfig } from '@storybook/core-common';
2
- export declare const addons: StorybookConfig['addons'];
3
- export declare const core: (config: StorybookConfig['core']) => Promise<{
4
- builder: string;
5
- disableWebpackDefaults?: boolean | undefined;
6
- channelOptions?: Partial<import("telejson").Options> | undefined;
7
- disableProjectJson?: boolean | undefined;
8
- disableTelemetry?: boolean | undefined;
9
- enableCrashReports?: boolean | undefined;
10
- crossOriginIsolated?: boolean | undefined;
11
- }>;
package/types-7-0.d.ts DELETED
@@ -1 +0,0 @@
1
- export * from './dist/types/client/preview/types-7-0.d';