@storybook/cli 7.0.0-alpha.1 → 7.0.0-alpha.4
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.
- package/dist/cjs/automigrate/index.js +9 -3
- package/dist/cjs/babel-config.js +5 -4
- package/dist/cjs/frameworks/angular/Button.stories.ts +5 -3
- package/dist/cjs/generate.js +1 -1
- package/dist/cjs/generators/ANGULAR/index.js +24 -1
- package/dist/cjs/generators/baseGenerator.js +36 -36
- package/dist/cjs/generators/configure.js +16 -18
- package/dist/cjs/generators/types.js +5 -0
- package/dist/cjs/helpers.js +10 -12
- package/dist/cjs/initiate.js +2 -1
- package/dist/cjs/js-package-manager/JsPackageManager.js +2 -2
- package/dist/cjs/repro-generators/configs.js +22 -24
- package/dist/cjs/repro-generators/scripts.js +23 -13
- package/dist/cjs/versions.js +73 -73
- package/dist/esm/automigrate/index.js +9 -3
- package/dist/esm/babel-config.js +5 -4
- package/dist/esm/frameworks/angular/Button.stories.ts +5 -3
- package/dist/esm/generate.js +1 -1
- package/dist/esm/generators/ANGULAR/index.js +24 -1
- package/dist/esm/generators/baseGenerator.js +36 -36
- package/dist/esm/generators/configure.js +16 -18
- package/dist/esm/generators/types.js +5 -0
- package/dist/esm/helpers.js +10 -12
- package/dist/esm/initiate.js +2 -1
- package/dist/esm/js-package-manager/JsPackageManager.js +2 -2
- package/dist/esm/repro-generators/configs.js +22 -24
- package/dist/esm/repro-generators/scripts.js +23 -13
- package/dist/esm/versions.js +73 -73
- package/dist/types/generators/ANGULAR/index.d.ts +1 -1
- package/dist/types/generators/AURELIA/index.d.ts +1 -1
- package/dist/types/generators/EMBER/index.d.ts +1 -1
- package/dist/types/generators/HTML/index.d.ts +1 -1
- package/dist/types/generators/MARIONETTE/index.d.ts +1 -1
- package/dist/types/generators/MARKO/index.d.ts +1 -1
- package/dist/types/generators/MITHRIL/index.d.ts +1 -1
- package/dist/types/generators/PREACT/index.d.ts +1 -1
- package/dist/types/generators/RAX/index.d.ts +1 -1
- package/dist/types/generators/REACT/index.d.ts +1 -1
- package/dist/types/generators/REACT_SCRIPTS/index.d.ts +1 -1
- package/dist/types/generators/RIOT/index.d.ts +1 -1
- package/dist/types/generators/SERVER/index.d.ts +1 -1
- package/dist/types/generators/SFC_VUE/index.d.ts +1 -1
- package/dist/types/generators/SVELTE/index.d.ts +1 -1
- package/dist/types/generators/VUE/index.d.ts +1 -1
- package/dist/types/generators/VUE3/index.d.ts +1 -1
- package/dist/types/generators/WEB-COMPONENTS/index.d.ts +1 -1
- package/dist/types/generators/WEBPACK_REACT/index.d.ts +1 -1
- package/dist/types/generators/baseGenerator.d.ts +3 -20
- package/dist/types/generators/configure.d.ts +2 -1
- package/dist/types/generators/types.d.ts +36 -0
- package/dist/types/helpers.d.ts +1 -1
- package/dist/types/initiate.d.ts +1 -15
- package/dist/types/repro-generators/configs.d.ts +1 -4
- package/dist/types/repro-generators/scripts.d.ts +1 -1
- package/package.json +9 -9
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.web_components_typescript = exports.web_components_lit2 = exports.web_components = exports.vue3 = exports.vue = exports.
|
|
6
|
+
exports.web_components_typescript = exports.web_components_lit2 = exports.web_components = exports.vue3 = exports.vue = exports.svelte = exports.sfcVue = exports.react_typescript = exports.react_legacy_root_api = exports.react_in_yarn_workspace = exports.react = exports.preact = exports.html = exports.cra_typescript = exports.cra = exports.angular_modern_inline_rendering = exports.angular130 = exports.angular13 = exports.angular12 = exports.angular = void 0;
|
|
7
7
|
|
|
8
8
|
/* eslint-disable camelcase */
|
|
9
9
|
const fromDeps = (...args) => ['mkdir {{appName}}', 'cd {{appName}}', // Create `yarn.lock` to force Yarn to consider adding deps in this directory
|
|
@@ -67,15 +67,14 @@ const react_typescript = {
|
|
|
67
67
|
path: '.babelrc',
|
|
68
68
|
contents: '{ "presets": ["@babel/preset-react", "@babel/preset-typescript"] }'
|
|
69
69
|
}]
|
|
70
|
-
};
|
|
70
|
+
}; // export const vite_react: Parameters = {
|
|
71
|
+
// renderer: 'react',
|
|
72
|
+
// name: 'vite_react',
|
|
73
|
+
// version: 'latest',
|
|
74
|
+
// generator: 'npx -p create-vite@{{version}} create-vite {{appName}} --template react-ts',
|
|
75
|
+
// };
|
|
76
|
+
|
|
71
77
|
exports.react_typescript = react_typescript;
|
|
72
|
-
const vite_react = {
|
|
73
|
-
renderer: 'react',
|
|
74
|
-
name: 'vite_react',
|
|
75
|
-
version: 'latest',
|
|
76
|
-
generator: 'npx -p create-vite@{{version}} create-vite {{appName}} --template react-ts'
|
|
77
|
-
};
|
|
78
|
-
exports.vite_react = vite_react;
|
|
79
78
|
const react_in_yarn_workspace = {
|
|
80
79
|
renderer: 'react',
|
|
81
80
|
name: 'react_in_yarn_workspace',
|
|
@@ -89,18 +88,8 @@ const baseAngular = {
|
|
|
89
88
|
renderer: 'angular',
|
|
90
89
|
name: 'angular',
|
|
91
90
|
version: 'latest',
|
|
92
|
-
generator: `npx -p @angular/cli@{{version}} ng new {{appName}} --routing=true --minimal=true --style=scss --
|
|
91
|
+
generator: `npx -p @angular/cli@{{version}} ng new {{appName}} --routing=true --minimal=true --style=scss --skip-install=true --strict`
|
|
93
92
|
};
|
|
94
|
-
const angular10 = Object.assign({}, baseAngular, {
|
|
95
|
-
name: 'angular10',
|
|
96
|
-
version: 'v10-lts'
|
|
97
|
-
});
|
|
98
|
-
exports.angular10 = angular10;
|
|
99
|
-
const angular11 = Object.assign({}, baseAngular, {
|
|
100
|
-
name: 'angular11',
|
|
101
|
-
version: 'v11-lts'
|
|
102
|
-
});
|
|
103
|
-
exports.angular11 = angular11;
|
|
104
93
|
const angular12 = Object.assign({}, baseAngular, {
|
|
105
94
|
name: 'angular12',
|
|
106
95
|
version: 'v12-lts'
|
|
@@ -121,8 +110,7 @@ const angular_modern_inline_rendering = Object.assign({}, baseAngular, {
|
|
|
121
110
|
additionalDeps: ['jest@27', '@storybook/test-runner'],
|
|
122
111
|
mainOverrides: {
|
|
123
112
|
features: {
|
|
124
|
-
storyStoreV7: true
|
|
125
|
-
modernInlineRender: true
|
|
113
|
+
storyStoreV7: true
|
|
126
114
|
}
|
|
127
115
|
}
|
|
128
116
|
});
|
|
@@ -140,14 +128,24 @@ const web_components = {
|
|
|
140
128
|
exports.web_components = web_components;
|
|
141
129
|
const web_components_typescript = Object.assign({}, web_components, {
|
|
142
130
|
name: 'web_components_typescript',
|
|
143
|
-
typescript: true
|
|
131
|
+
typescript: true,
|
|
132
|
+
additionalDeps: ['@babel/preset-typescript'],
|
|
133
|
+
additionalFiles: [{
|
|
134
|
+
path: '.babelrc',
|
|
135
|
+
contents: '{ "presets": ["@babel/preset-typescript"] }'
|
|
136
|
+
}]
|
|
144
137
|
});
|
|
145
138
|
exports.web_components_typescript = web_components_typescript;
|
|
146
139
|
const web_components_lit2 = Object.assign({}, web_components, {
|
|
147
140
|
version: 'next',
|
|
148
141
|
name: 'web_components_lit2',
|
|
149
142
|
generator: fromDeps('lit'),
|
|
150
|
-
typescript: true
|
|
143
|
+
typescript: true,
|
|
144
|
+
additionalDeps: ['@babel/preset-typescript'],
|
|
145
|
+
additionalFiles: [{
|
|
146
|
+
path: '.babelrc',
|
|
147
|
+
contents: '{ "presets": ["@babel/preset-typescript"] }'
|
|
148
|
+
}]
|
|
151
149
|
}); // #endregion
|
|
152
150
|
// #region vue
|
|
153
151
|
|
|
@@ -41,11 +41,12 @@ const exec = async (command, options = {}, {
|
|
|
41
41
|
logger.debug(command);
|
|
42
42
|
return new Promise((resolve, reject) => {
|
|
43
43
|
const defaultOptions = {
|
|
44
|
-
silent:
|
|
44
|
+
silent: false
|
|
45
45
|
};
|
|
46
46
|
|
|
47
47
|
const child = _shelljs.default.exec(command, Object.assign({}, defaultOptions, options, {
|
|
48
|
-
async: true
|
|
48
|
+
async: true,
|
|
49
|
+
silent: false
|
|
49
50
|
}));
|
|
50
51
|
|
|
51
52
|
child.stderr.pipe(process.stderr);
|
|
@@ -170,28 +171,37 @@ const addAdditionalFiles = async ({
|
|
|
170
171
|
additionalFiles,
|
|
171
172
|
cwd
|
|
172
173
|
}) => {
|
|
173
|
-
if (!additionalFiles || additionalFiles.length === 0) {
|
|
174
|
-
return;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
174
|
logger.info(`⤵️ Adding required files`);
|
|
178
|
-
additionalFiles.
|
|
175
|
+
await Promise.all(additionalFiles.map(async file => {
|
|
179
176
|
await (0, _fsExtra.outputFile)(_path.default.resolve(cwd, file.path), file.contents, {
|
|
180
177
|
encoding: 'UTF-8'
|
|
181
178
|
});
|
|
182
|
-
});
|
|
179
|
+
}));
|
|
183
180
|
};
|
|
184
181
|
|
|
185
182
|
const initStorybook = async ({
|
|
186
183
|
cwd,
|
|
187
184
|
autoDetect = true,
|
|
188
185
|
name,
|
|
189
|
-
e2e
|
|
186
|
+
e2e,
|
|
187
|
+
pnp
|
|
190
188
|
}) => {
|
|
191
|
-
const
|
|
192
|
-
|
|
189
|
+
const flags = ['--yes'];
|
|
190
|
+
|
|
191
|
+
if (!autoDetect) {
|
|
192
|
+
flags.push(`--type ${name}`);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
if (e2e) {
|
|
196
|
+
flags.push('--linkable');
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
if (pnp) {
|
|
200
|
+
flags.push('--use-pnp');
|
|
201
|
+
}
|
|
202
|
+
|
|
193
203
|
const sbCLICommand = useLocalSbCli ? `node ${_path.default.join(__dirname, '../../esm/generate')}` : `yarn dlx -p @storybook/cli sb`;
|
|
194
|
-
const command = `${sbCLICommand} init
|
|
204
|
+
const command = `${sbCLICommand} init ${flags.join(' ')}`;
|
|
195
205
|
await exec(command, {
|
|
196
206
|
cwd
|
|
197
207
|
}, {
|
|
@@ -283,7 +293,7 @@ const createAndInit = async (cwd, _ref, {
|
|
|
283
293
|
}));
|
|
284
294
|
await doTask(addAdditionalFiles, Object.assign({}, options, {
|
|
285
295
|
cwd
|
|
286
|
-
}));
|
|
296
|
+
}), !!options.additionalFiles);
|
|
287
297
|
|
|
288
298
|
if (e2e) {
|
|
289
299
|
await doTask(addPackageResolutions, options);
|
package/dist/esm/versions.js
CHANGED
|
@@ -6,78 +6,78 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
// auto generated file, do not edit
|
|
8
8
|
var _default = {
|
|
9
|
-
'@storybook/addon-a11y': '7.0.0-alpha.
|
|
10
|
-
'@storybook/addon-actions': '7.0.0-alpha.
|
|
11
|
-
'@storybook/addon-backgrounds': '7.0.0-alpha.
|
|
12
|
-
'@storybook/addon-controls': '7.0.0-alpha.
|
|
13
|
-
'@storybook/addon-docs': '7.0.0-alpha.
|
|
14
|
-
'@storybook/addon-essentials': '7.0.0-alpha.
|
|
15
|
-
'@storybook/addon-interactions': '7.0.0-alpha.
|
|
16
|
-
'@storybook/addon-jest': '7.0.0-alpha.
|
|
17
|
-
'@storybook/addon-links': '7.0.0-alpha.
|
|
18
|
-
'@storybook/addon-measure': '7.0.0-alpha.
|
|
19
|
-
'@storybook/addon-outline': '7.0.0-alpha.
|
|
20
|
-
'@storybook/addon-storyshots': '7.0.0-alpha.
|
|
21
|
-
'@storybook/addon-storyshots-puppeteer': '7.0.0-alpha.
|
|
22
|
-
'@storybook/addon-storysource': '7.0.0-alpha.
|
|
23
|
-
'@storybook/addon-toolbars': '7.0.0-alpha.
|
|
24
|
-
'@storybook/addon-viewport': '7.0.0-alpha.
|
|
25
|
-
'@storybook/addons': '7.0.0-alpha.
|
|
26
|
-
'@storybook/angular': '7.0.0-alpha.
|
|
27
|
-
'@storybook/api': '7.0.0-alpha.
|
|
28
|
-
'@storybook/builder-webpack5': '7.0.0-alpha.
|
|
29
|
-
'@storybook/channel-postmessage': '7.0.0-alpha.
|
|
30
|
-
'@storybook/channel-websocket': '7.0.0-alpha.
|
|
31
|
-
'@storybook/channels': '7.0.0-alpha.
|
|
32
|
-
'@storybook/cli': '7.0.0-alpha.
|
|
33
|
-
'@storybook/client-api': '7.0.0-alpha.
|
|
34
|
-
'@storybook/client-logger': '7.0.0-alpha.
|
|
35
|
-
'@storybook/codemod': '7.0.0-alpha.
|
|
36
|
-
'@storybook/components': '7.0.0-alpha.
|
|
37
|
-
'@storybook/core-client': '7.0.0-alpha.
|
|
38
|
-
'@storybook/core-common': '7.0.0-alpha.
|
|
39
|
-
'@storybook/core-events': '7.0.0-alpha.
|
|
40
|
-
'@storybook/core-server': '7.0.0-alpha.
|
|
41
|
-
'@storybook/core-webpack': '7.0.0-alpha.
|
|
42
|
-
'@storybook/csf-tools': '7.0.0-alpha.
|
|
43
|
-
'@storybook/docs-tools': '7.0.0-alpha.
|
|
44
|
-
'@storybook/ember': '7.0.0-alpha.
|
|
45
|
-
'@storybook/html': '7.0.0-alpha.
|
|
46
|
-
'@storybook/html-webpack5': '7.0.0-alpha.
|
|
47
|
-
'@storybook/instrumenter': '7.0.0-alpha.
|
|
48
|
-
'@storybook/manager-webpack5': '7.0.0-alpha.
|
|
49
|
-
'@storybook/node-logger': '7.0.0-alpha.
|
|
50
|
-
'@storybook/postinstall': '7.0.0-alpha.
|
|
51
|
-
'@storybook/preact': '7.0.0-alpha.
|
|
52
|
-
'@storybook/preact-webpack5': '7.0.0-alpha.
|
|
53
|
-
'@storybook/preset-html-webpack': '7.0.0-alpha.
|
|
54
|
-
'@storybook/preset-preact-webpack': '7.0.0-alpha.
|
|
55
|
-
'@storybook/preset-react-webpack': '7.0.0-alpha.
|
|
56
|
-
'@storybook/preset-server-webpack': '7.0.0-alpha.
|
|
57
|
-
'@storybook/preset-svelte-webpack': '7.0.0-alpha.
|
|
58
|
-
'@storybook/preset-vue-webpack': '7.0.0-alpha.
|
|
59
|
-
'@storybook/preset-vue3-webpack': '7.0.0-alpha.
|
|
60
|
-
'@storybook/preset-web-components-webpack': '7.0.0-alpha.
|
|
61
|
-
'@storybook/preview-web': '7.0.0-alpha.
|
|
62
|
-
'@storybook/react': '7.0.0-alpha.
|
|
63
|
-
'@storybook/react-webpack5': '7.0.0-alpha.
|
|
64
|
-
'@storybook/router': '7.0.0-alpha.
|
|
65
|
-
'@storybook/server': '7.0.0-alpha.
|
|
66
|
-
'@storybook/server-webpack5': '7.0.0-alpha.
|
|
67
|
-
'@storybook/source-loader': '7.0.0-alpha.
|
|
68
|
-
'@storybook/store': '7.0.0-alpha.
|
|
69
|
-
'@storybook/svelte': '7.0.0-alpha.
|
|
70
|
-
'@storybook/svelte-webpack5': '7.0.0-alpha.
|
|
71
|
-
'@storybook/telemetry': '7.0.0-alpha.
|
|
72
|
-
'@storybook/theming': '7.0.0-alpha.
|
|
73
|
-
'@storybook/ui': '7.0.0-alpha.
|
|
74
|
-
'@storybook/vue': '7.0.0-alpha.
|
|
75
|
-
'@storybook/vue-webpack5': '7.0.0-alpha.
|
|
76
|
-
'@storybook/vue3': '7.0.0-alpha.
|
|
77
|
-
'@storybook/vue3-webpack5': '7.0.0-alpha.
|
|
78
|
-
'@storybook/web-components': '7.0.0-alpha.
|
|
79
|
-
'@storybook/web-components-webpack5': '7.0.0-alpha.
|
|
80
|
-
sb: '7.0.0-alpha.
|
|
81
|
-
storybook: '7.0.0-alpha.
|
|
9
|
+
'@storybook/addon-a11y': '7.0.0-alpha.4',
|
|
10
|
+
'@storybook/addon-actions': '7.0.0-alpha.4',
|
|
11
|
+
'@storybook/addon-backgrounds': '7.0.0-alpha.4',
|
|
12
|
+
'@storybook/addon-controls': '7.0.0-alpha.4',
|
|
13
|
+
'@storybook/addon-docs': '7.0.0-alpha.4',
|
|
14
|
+
'@storybook/addon-essentials': '7.0.0-alpha.4',
|
|
15
|
+
'@storybook/addon-interactions': '7.0.0-alpha.4',
|
|
16
|
+
'@storybook/addon-jest': '7.0.0-alpha.4',
|
|
17
|
+
'@storybook/addon-links': '7.0.0-alpha.4',
|
|
18
|
+
'@storybook/addon-measure': '7.0.0-alpha.4',
|
|
19
|
+
'@storybook/addon-outline': '7.0.0-alpha.4',
|
|
20
|
+
'@storybook/addon-storyshots': '7.0.0-alpha.4',
|
|
21
|
+
'@storybook/addon-storyshots-puppeteer': '7.0.0-alpha.4',
|
|
22
|
+
'@storybook/addon-storysource': '7.0.0-alpha.4',
|
|
23
|
+
'@storybook/addon-toolbars': '7.0.0-alpha.4',
|
|
24
|
+
'@storybook/addon-viewport': '7.0.0-alpha.4',
|
|
25
|
+
'@storybook/addons': '7.0.0-alpha.4',
|
|
26
|
+
'@storybook/angular': '7.0.0-alpha.4',
|
|
27
|
+
'@storybook/api': '7.0.0-alpha.4',
|
|
28
|
+
'@storybook/builder-webpack5': '7.0.0-alpha.4',
|
|
29
|
+
'@storybook/channel-postmessage': '7.0.0-alpha.4',
|
|
30
|
+
'@storybook/channel-websocket': '7.0.0-alpha.4',
|
|
31
|
+
'@storybook/channels': '7.0.0-alpha.4',
|
|
32
|
+
'@storybook/cli': '7.0.0-alpha.4',
|
|
33
|
+
'@storybook/client-api': '7.0.0-alpha.4',
|
|
34
|
+
'@storybook/client-logger': '7.0.0-alpha.4',
|
|
35
|
+
'@storybook/codemod': '7.0.0-alpha.4',
|
|
36
|
+
'@storybook/components': '7.0.0-alpha.4',
|
|
37
|
+
'@storybook/core-client': '7.0.0-alpha.4',
|
|
38
|
+
'@storybook/core-common': '7.0.0-alpha.4',
|
|
39
|
+
'@storybook/core-events': '7.0.0-alpha.4',
|
|
40
|
+
'@storybook/core-server': '7.0.0-alpha.4',
|
|
41
|
+
'@storybook/core-webpack': '7.0.0-alpha.4',
|
|
42
|
+
'@storybook/csf-tools': '7.0.0-alpha.4',
|
|
43
|
+
'@storybook/docs-tools': '7.0.0-alpha.4',
|
|
44
|
+
'@storybook/ember': '7.0.0-alpha.4',
|
|
45
|
+
'@storybook/html': '7.0.0-alpha.4',
|
|
46
|
+
'@storybook/html-webpack5': '7.0.0-alpha.4',
|
|
47
|
+
'@storybook/instrumenter': '7.0.0-alpha.4',
|
|
48
|
+
'@storybook/manager-webpack5': '7.0.0-alpha.4',
|
|
49
|
+
'@storybook/node-logger': '7.0.0-alpha.4',
|
|
50
|
+
'@storybook/postinstall': '7.0.0-alpha.4',
|
|
51
|
+
'@storybook/preact': '7.0.0-alpha.4',
|
|
52
|
+
'@storybook/preact-webpack5': '7.0.0-alpha.4',
|
|
53
|
+
'@storybook/preset-html-webpack': '7.0.0-alpha.4',
|
|
54
|
+
'@storybook/preset-preact-webpack': '7.0.0-alpha.4',
|
|
55
|
+
'@storybook/preset-react-webpack': '7.0.0-alpha.4',
|
|
56
|
+
'@storybook/preset-server-webpack': '7.0.0-alpha.4',
|
|
57
|
+
'@storybook/preset-svelte-webpack': '7.0.0-alpha.4',
|
|
58
|
+
'@storybook/preset-vue-webpack': '7.0.0-alpha.4',
|
|
59
|
+
'@storybook/preset-vue3-webpack': '7.0.0-alpha.4',
|
|
60
|
+
'@storybook/preset-web-components-webpack': '7.0.0-alpha.4',
|
|
61
|
+
'@storybook/preview-web': '7.0.0-alpha.4',
|
|
62
|
+
'@storybook/react': '7.0.0-alpha.4',
|
|
63
|
+
'@storybook/react-webpack5': '7.0.0-alpha.4',
|
|
64
|
+
'@storybook/router': '7.0.0-alpha.4',
|
|
65
|
+
'@storybook/server': '7.0.0-alpha.4',
|
|
66
|
+
'@storybook/server-webpack5': '7.0.0-alpha.4',
|
|
67
|
+
'@storybook/source-loader': '7.0.0-alpha.4',
|
|
68
|
+
'@storybook/store': '7.0.0-alpha.4',
|
|
69
|
+
'@storybook/svelte': '7.0.0-alpha.4',
|
|
70
|
+
'@storybook/svelte-webpack5': '7.0.0-alpha.4',
|
|
71
|
+
'@storybook/telemetry': '7.0.0-alpha.4',
|
|
72
|
+
'@storybook/theming': '7.0.0-alpha.4',
|
|
73
|
+
'@storybook/ui': '7.0.0-alpha.4',
|
|
74
|
+
'@storybook/vue': '7.0.0-alpha.4',
|
|
75
|
+
'@storybook/vue-webpack5': '7.0.0-alpha.4',
|
|
76
|
+
'@storybook/vue3': '7.0.0-alpha.4',
|
|
77
|
+
'@storybook/vue3-webpack5': '7.0.0-alpha.4',
|
|
78
|
+
'@storybook/web-components': '7.0.0-alpha.4',
|
|
79
|
+
'@storybook/web-components-webpack5': '7.0.0-alpha.4',
|
|
80
|
+
sb: '7.0.0-alpha.4',
|
|
81
|
+
storybook: '7.0.0-alpha.4'
|
|
82
82
|
};
|
|
83
83
|
exports.default = _default;
|
|
@@ -1,22 +1,5 @@
|
|
|
1
1
|
import { NpmOptions } from '../NpmOptions';
|
|
2
|
-
import {
|
|
2
|
+
import { SupportedRenderers } from '../project_types';
|
|
3
3
|
import { JsPackageManager } from '../js-package-manager';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
builder: Builder;
|
|
7
|
-
linkable: boolean;
|
|
8
|
-
};
|
|
9
|
-
export interface FrameworkOptions {
|
|
10
|
-
extraPackages?: string[];
|
|
11
|
-
extraAddons?: string[];
|
|
12
|
-
staticDir?: string;
|
|
13
|
-
addScripts?: boolean;
|
|
14
|
-
addComponents?: boolean;
|
|
15
|
-
addBabel?: boolean;
|
|
16
|
-
addESLint?: boolean;
|
|
17
|
-
extraMain?: any;
|
|
18
|
-
extensions?: string[];
|
|
19
|
-
commonJs?: boolean;
|
|
20
|
-
}
|
|
21
|
-
export declare type Generator = (packageManager: JsPackageManager, npmOptions: NpmOptions, options: GeneratorOptions) => Promise<void>;
|
|
22
|
-
export declare function baseGenerator(packageManager: JsPackageManager, npmOptions: NpmOptions, { language, builder }: GeneratorOptions, renderer: SupportedRenderers, options?: FrameworkOptions): Promise<void>;
|
|
4
|
+
import { FrameworkOptions, GeneratorOptions } from './types';
|
|
5
|
+
export declare function baseGenerator(packageManager: JsPackageManager, npmOptions: NpmOptions, { language, builder, pnp }: GeneratorOptions, renderer: SupportedRenderers, options?: FrameworkOptions): Promise<void>;
|
|
@@ -14,5 +14,6 @@ interface ConfigureMainOptions {
|
|
|
14
14
|
*/
|
|
15
15
|
[key: string]: any;
|
|
16
16
|
}
|
|
17
|
-
export declare function
|
|
17
|
+
export declare function configureMain({ addons, extensions, commonJs, ...custom }: ConfigureMainOptions): Promise<void>;
|
|
18
|
+
export declare function configurePreview(framework: SupportedRenderers, commonJs: boolean): Promise<void>;
|
|
18
19
|
export {};
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { NpmOptions } from '../NpmOptions';
|
|
2
|
+
import { SupportedLanguage, Builder, ProjectType } from '../project_types';
|
|
3
|
+
import { JsPackageManager } from '../js-package-manager/JsPackageManager';
|
|
4
|
+
export declare type GeneratorOptions = {
|
|
5
|
+
language: SupportedLanguage;
|
|
6
|
+
builder: Builder;
|
|
7
|
+
linkable: boolean;
|
|
8
|
+
pnp: boolean;
|
|
9
|
+
};
|
|
10
|
+
export interface FrameworkOptions {
|
|
11
|
+
extraPackages?: string[];
|
|
12
|
+
extraAddons?: string[];
|
|
13
|
+
staticDir?: string;
|
|
14
|
+
addScripts?: boolean;
|
|
15
|
+
addComponents?: boolean;
|
|
16
|
+
addBabel?: boolean;
|
|
17
|
+
addESLint?: boolean;
|
|
18
|
+
extraMain?: any;
|
|
19
|
+
extensions?: string[];
|
|
20
|
+
commonJs?: boolean;
|
|
21
|
+
}
|
|
22
|
+
export declare type Generator = (packageManagerInstance: JsPackageManager, npmOptions: NpmOptions, generatorOptions: GeneratorOptions) => Promise<void>;
|
|
23
|
+
export declare type CommandOptions = {
|
|
24
|
+
useNpm?: boolean;
|
|
25
|
+
usePnp?: boolean;
|
|
26
|
+
type?: ProjectType;
|
|
27
|
+
force?: any;
|
|
28
|
+
html?: boolean;
|
|
29
|
+
skipInstall?: boolean;
|
|
30
|
+
parser?: string;
|
|
31
|
+
yes?: boolean;
|
|
32
|
+
builder?: Builder;
|
|
33
|
+
linkable?: boolean;
|
|
34
|
+
commonJs?: boolean;
|
|
35
|
+
disableTelemetry?: boolean;
|
|
36
|
+
};
|
package/dist/types/helpers.d.ts
CHANGED
|
@@ -22,4 +22,4 @@ export declare function codeLog(codeLines: string[], leftPadAmount?: number): vo
|
|
|
22
22
|
export declare function getBabelDependencies(packageManager: JsPackageManager, packageJson: PackageJsonWithDepsAndDevDeps): Promise<string[]>;
|
|
23
23
|
export declare function addToDevDependenciesIfNotPresent(packageJson: PackageJson, name: string, packageVersion: string): void;
|
|
24
24
|
export declare function copyTemplate(templateRoot: string): void;
|
|
25
|
-
export declare function copyComponents(framework: SupportedRenderers, language: SupportedLanguage): void
|
|
25
|
+
export declare function copyComponents(framework: SupportedRenderers, language: SupportedLanguage): Promise<void>;
|
package/dist/types/initiate.d.ts
CHANGED
|
@@ -1,17 +1,3 @@
|
|
|
1
1
|
import { Package } from 'update-notifier';
|
|
2
|
-
import {
|
|
3
|
-
declare type CommandOptions = {
|
|
4
|
-
useNpm?: boolean;
|
|
5
|
-
type?: ProjectType;
|
|
6
|
-
force?: any;
|
|
7
|
-
html?: boolean;
|
|
8
|
-
skipInstall?: boolean;
|
|
9
|
-
parser?: string;
|
|
10
|
-
yes?: boolean;
|
|
11
|
-
builder?: Builder;
|
|
12
|
-
linkable?: boolean;
|
|
13
|
-
commonJs?: boolean;
|
|
14
|
-
disableTelemetry?: boolean;
|
|
15
|
-
};
|
|
2
|
+
import { CommandOptions } from './generators/types';
|
|
16
3
|
export declare function initiate(options: CommandOptions, pkg: Package): Promise<void>;
|
|
17
|
-
export {};
|
|
@@ -12,7 +12,7 @@ export interface Parameters {
|
|
|
12
12
|
autoDetect?: boolean;
|
|
13
13
|
/** Dependencies to add before building Storybook */
|
|
14
14
|
additionalDeps?: string[];
|
|
15
|
-
/** Files to add before
|
|
15
|
+
/** Files to add before installing Storybook */
|
|
16
16
|
additionalFiles?: {
|
|
17
17
|
path: string;
|
|
18
18
|
contents: string;
|
|
@@ -27,10 +27,7 @@ export declare const cra_typescript: Parameters;
|
|
|
27
27
|
export declare const react: Parameters;
|
|
28
28
|
export declare const react_legacy_root_api: Parameters;
|
|
29
29
|
export declare const react_typescript: Parameters;
|
|
30
|
-
export declare const vite_react: Parameters;
|
|
31
30
|
export declare const react_in_yarn_workspace: Parameters;
|
|
32
|
-
export declare const angular10: Parameters;
|
|
33
|
-
export declare const angular11: Parameters;
|
|
34
31
|
export declare const angular12: Parameters;
|
|
35
32
|
export declare const angular130: Parameters;
|
|
36
33
|
export declare const angular13: Parameters;
|
|
@@ -14,7 +14,7 @@ export interface Parameters {
|
|
|
14
14
|
ensureDir?: boolean;
|
|
15
15
|
/** Dependencies to add before building Storybook */
|
|
16
16
|
additionalDeps?: string[];
|
|
17
|
-
/** Files to add before
|
|
17
|
+
/** Files to add before installing Storybook */
|
|
18
18
|
additionalFiles?: {
|
|
19
19
|
path: string;
|
|
20
20
|
contents: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/cli",
|
|
3
|
-
"version": "7.0.0-alpha.
|
|
3
|
+
"version": "7.0.0-alpha.4",
|
|
4
4
|
"description": "Storybook's CLI - easiest method of adding storybook to your projects",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cli",
|
|
@@ -47,13 +47,13 @@
|
|
|
47
47
|
"dependencies": {
|
|
48
48
|
"@babel/core": "^7.12.10",
|
|
49
49
|
"@babel/preset-env": "^7.12.11",
|
|
50
|
-
"@storybook/codemod": "7.0.0-alpha.
|
|
51
|
-
"@storybook/core-common": "7.0.0-alpha.
|
|
52
|
-
"@storybook/core-server": "7.0.0-alpha.
|
|
53
|
-
"@storybook/csf-tools": "7.0.0-alpha.
|
|
54
|
-
"@storybook/node-logger": "7.0.0-alpha.
|
|
50
|
+
"@storybook/codemod": "7.0.0-alpha.4",
|
|
51
|
+
"@storybook/core-common": "7.0.0-alpha.4",
|
|
52
|
+
"@storybook/core-server": "7.0.0-alpha.4",
|
|
53
|
+
"@storybook/csf-tools": "7.0.0-alpha.4",
|
|
54
|
+
"@storybook/node-logger": "7.0.0-alpha.4",
|
|
55
55
|
"@storybook/semver": "^7.3.2",
|
|
56
|
-
"@storybook/telemetry": "7.0.0-alpha.
|
|
56
|
+
"@storybook/telemetry": "7.0.0-alpha.4",
|
|
57
57
|
"boxen": "^5.1.2",
|
|
58
58
|
"chalk": "^4.1.0",
|
|
59
59
|
"commander": "^6.2.1",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"update-notifier": "^5.0.1"
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
|
-
"@storybook/client-api": "7.0.0-alpha.
|
|
81
|
+
"@storybook/client-api": "7.0.0-alpha.4",
|
|
82
82
|
"@types/cross-spawn": "^6.0.2",
|
|
83
83
|
"@types/prompts": "^2.0.9",
|
|
84
84
|
"@types/puppeteer-core": "^2.1.0",
|
|
@@ -91,5 +91,5 @@
|
|
|
91
91
|
"publishConfig": {
|
|
92
92
|
"access": "public"
|
|
93
93
|
},
|
|
94
|
-
"gitHead": "
|
|
94
|
+
"gitHead": "006ed54452dd7c37a8cbe91a84f5312182f7ca00"
|
|
95
95
|
}
|