@storybook/angular 6.4.0-alpha.32 → 6.4.0-alpha.36
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/ts3.4/builders/build-storybook/index.d.ts +2 -1
- package/dist/ts3.4/builders/start-storybook/index.d.ts +2 -1
- package/dist/ts3.4/client/preview/angular/helpers.d.ts +3 -3
- package/dist/ts3.4/client/preview/angular-beta/AbstractRenderer.d.ts +3 -1
- package/dist/ts3.4/client/preview/angular-beta/CanvasRenderer.d.ts +1 -0
- package/dist/ts3.4/client/preview/angular-beta/DocsRenderer.d.ts +1 -0
- package/dist/ts3.4/client/preview/angular-beta/ElementRendererService.d.ts +2 -1
- package/dist/ts3.4/client/preview/angular-beta/RendererService.d.ts +3 -2
- package/dist/ts3.4/client/preview/angular-beta/StorybookModule.d.ts +2 -3
- package/dist/ts3.4/client/preview/config.d.ts +4 -0
- package/dist/ts3.4/client/preview/decorateStory.d.ts +3 -3
- package/dist/ts3.4/client/preview/decorators.d.ts +5 -4
- package/dist/ts3.4/client/preview/index.d.ts +3 -2
- package/dist/ts3.4/client/preview/render.d.ts +5 -11
- package/dist/ts3.4/client/preview/types-6-0.d.ts +9 -8
- package/dist/ts3.4/client/preview/types.d.ts +1 -1
- package/dist/ts3.4/server/__mocks-ng-workspace__/with-lib/projects/pattern-lib/src/main.d.ts +1 -0
- package/dist/ts3.4/server/__mocks-ng-workspace__/without-projects-entry/projects/pattern-lib/src/main.d.ts +1 -0
- package/dist/ts3.4/server/__mocks-ng-workspace__/without-tsConfig/src/main.d.ts +1 -0
- package/dist/ts3.4/server/framework-preset-angular-cli.d.ts +1 -0
- package/dist/ts3.9/builders/build-storybook/index.d.ts +2 -1
- package/dist/ts3.9/builders/build-storybook/index.js +33 -15
- package/dist/ts3.9/builders/build-storybook/schema.json +14 -2
- package/dist/ts3.9/builders/start-storybook/index.d.ts +2 -1
- package/dist/ts3.9/builders/start-storybook/index.js +33 -15
- package/dist/ts3.9/builders/start-storybook/schema.json +14 -2
- package/dist/ts3.9/client/preview/angular/helpers.d.ts +3 -3
- package/dist/ts3.9/client/preview/angular-beta/AbstractRenderer.d.ts +3 -1
- package/dist/ts3.9/client/preview/angular-beta/AbstractRenderer.js +3 -2
- package/dist/ts3.9/client/preview/angular-beta/CanvasRenderer.d.ts +1 -0
- package/dist/ts3.9/client/preview/angular-beta/DocsRenderer.d.ts +1 -0
- package/dist/ts3.9/client/preview/angular-beta/ElementRendererService.d.ts +2 -1
- package/dist/ts3.9/client/preview/angular-beta/ElementRendererService.js +2 -2
- package/dist/ts3.9/client/preview/angular-beta/RendererService.d.ts +3 -2
- package/dist/ts3.9/client/preview/angular-beta/RendererService.js +3 -3
- package/dist/ts3.9/client/preview/angular-beta/StorybookModule.d.ts +2 -3
- package/dist/ts3.9/client/preview/angular-beta/StorybookModule.js +2 -2
- package/dist/ts3.9/client/preview/config.d.ts +4 -0
- package/dist/ts3.9/client/preview/config.js +7 -0
- package/dist/ts3.9/client/preview/decorateStory.d.ts +3 -3
- package/dist/ts3.9/client/preview/decorateStory.js +4 -26
- package/dist/ts3.9/client/preview/decorators.d.ts +5 -4
- package/dist/ts3.9/client/preview/index.d.ts +3 -2
- package/dist/ts3.9/client/preview/index.js +3 -5
- package/dist/ts3.9/client/preview/render.d.ts +5 -11
- package/dist/ts3.9/client/preview/render.js +10 -9
- package/dist/ts3.9/client/preview/types-6-0.d.ts +9 -8
- package/dist/ts3.9/client/preview/types.d.ts +1 -1
- package/dist/ts3.9/server/__mocks-ng-workspace__/with-lib/angular.json +28 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/with-lib/projects/pattern-lib/src/main.d.ts +1 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/with-lib/projects/pattern-lib/src/main.js +5 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/with-lib/projects/pattern-lib/tsconfig.lib.json +25 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/with-lib/tsconfig.json +13 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-projects-entry/projects/pattern-lib/src/main.d.ts +1 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-projects-entry/projects/pattern-lib/src/main.js +5 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-projects-entry/projects/pattern-lib/tsconfig.lib.json +25 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-projects-entry/tsconfig.json +13 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-tsConfig/angular.json +16 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-tsConfig/src/main.d.ts +1 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-tsConfig/src/main.js +5 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-tsConfig/src/tsconfig.app.json +9 -0
- package/dist/ts3.9/server/__mocks-ng-workspace__/without-tsConfig/tsconfig.json +13 -0
- package/dist/ts3.9/server/angular-devkit-build-webpack.js +2 -2
- package/dist/ts3.9/server/framework-preset-angular-cli.d.ts +1 -0
- package/dist/ts3.9/server/framework-preset-angular-cli.js +20 -11
- package/package.json +11 -9
- package/preset.js +7 -0
- package/standalone.d.ts +2 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"sourceMap": true,
|
|
4
|
+
"moduleResolution": "node",
|
|
5
|
+
"emitDecoratorMetadata": true,
|
|
6
|
+
"experimentalDecorators": true,
|
|
7
|
+
"allowSyntheticDefaultImports": true,
|
|
8
|
+
"esModuleInterop": true,
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
"target": "es5",
|
|
11
|
+
"lib": ["es2017", "dom"]
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const not = "empty";
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
|
|
2
|
+
{
|
|
3
|
+
"extends": "../../tsconfig.json",
|
|
4
|
+
"compilerOptions": {
|
|
5
|
+
"outDir": "../../out-tsc/lib",
|
|
6
|
+
"target": "es2015",
|
|
7
|
+
"declaration": true,
|
|
8
|
+
"declarationMap": true,
|
|
9
|
+
"inlineSources": true,
|
|
10
|
+
"types": [],
|
|
11
|
+
"lib": [
|
|
12
|
+
"dom",
|
|
13
|
+
"es2018"
|
|
14
|
+
]
|
|
15
|
+
},
|
|
16
|
+
"angularCompilerOptions": {
|
|
17
|
+
"skipTemplateCodegen": true,
|
|
18
|
+
"strictMetadataEmit": true,
|
|
19
|
+
"enableResourceInlining": true
|
|
20
|
+
},
|
|
21
|
+
"exclude": [
|
|
22
|
+
"src/test.ts",
|
|
23
|
+
"**/*.spec.ts"
|
|
24
|
+
]
|
|
25
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"sourceMap": true,
|
|
4
|
+
"moduleResolution": "node",
|
|
5
|
+
"emitDecoratorMetadata": true,
|
|
6
|
+
"experimentalDecorators": true,
|
|
7
|
+
"allowSyntheticDefaultImports": true,
|
|
8
|
+
"esModuleInterop": true,
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
"target": "es5",
|
|
11
|
+
"lib": ["es2017", "dom"]
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const not = "empty";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"sourceMap": true,
|
|
4
|
+
"moduleResolution": "node",
|
|
5
|
+
"emitDecoratorMetadata": true,
|
|
6
|
+
"experimentalDecorators": true,
|
|
7
|
+
"allowSyntheticDefaultImports": true,
|
|
8
|
+
"esModuleInterop": true,
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
"target": "es5",
|
|
11
|
+
"lib": ["es2017", "dom"]
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -128,8 +128,8 @@ var buildWebpackConfigOptions = function (dirToSearch, project, target) { return
|
|
|
128
128
|
switch (_b.label) {
|
|
129
129
|
case 0:
|
|
130
130
|
_a = target.options, projectBuildOptions = _a === void 0 ? {} : _a;
|
|
131
|
-
requiredOptions = ['tsConfig'
|
|
132
|
-
if (!requiredOptions.every(function (key) { return key
|
|
131
|
+
requiredOptions = ['tsConfig'];
|
|
132
|
+
if (!requiredOptions.every(function (key) { return !!projectBuildOptions[key]; })) {
|
|
133
133
|
throw new Error("Missing required options in project target. Check \"" + requiredOptions.join(', ') + "\"");
|
|
134
134
|
}
|
|
135
135
|
workspaceRootNormalized = core_1.normalize(dirToSearch);
|
|
@@ -3,6 +3,7 @@ import TsconfigPathsPlugin from 'tsconfig-paths-webpack-plugin';
|
|
|
3
3
|
import { Options as CoreOptions } from '@storybook/core-common';
|
|
4
4
|
export declare type Options = CoreOptions & {
|
|
5
5
|
angularBrowserTarget?: string;
|
|
6
|
+
tsConfig?: string;
|
|
6
7
|
};
|
|
7
8
|
export declare function webpackFinal(baseConfig: webpack.Configuration, options: Options): Promise<webpack.Configuration | {
|
|
8
9
|
entry: any[];
|
|
@@ -91,17 +91,26 @@ function webpackFinal(baseConfig, options) {
|
|
|
91
91
|
return [2 /*return*/, baseConfig];
|
|
92
92
|
case 4:
|
|
93
93
|
try {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
94
|
+
// Default behavior when `angularBrowserTarget` are not explicitly defined to null
|
|
95
|
+
if (options.angularBrowserTarget !== null) {
|
|
96
|
+
browserTarget = options.angularBrowserTarget
|
|
97
|
+
? architect_1.targetFromTargetString(options.angularBrowserTarget)
|
|
98
|
+
: {
|
|
99
|
+
configuration: undefined,
|
|
100
|
+
project: angular_read_workspace_1.getDefaultProjectName(workspaceConfig),
|
|
101
|
+
target: 'build',
|
|
102
|
+
};
|
|
103
|
+
fondProject = angular_read_workspace_1.findAngularProjectTarget(workspaceConfig, browserTarget.project, browserTarget.target);
|
|
104
|
+
project = fondProject.project;
|
|
105
|
+
target = fondProject.target;
|
|
106
|
+
node_logger_1.logger.info("=> Using angular project \"" + browserTarget.project + ":" + browserTarget.target + "\" for configuring Storybook");
|
|
107
|
+
}
|
|
108
|
+
// Start storybook when only tsConfig is provided.
|
|
109
|
+
if (options.angularBrowserTarget === null && options.tsConfig) {
|
|
110
|
+
node_logger_1.logger.info("=> Using default angular project with \"tsConfig:" + options.tsConfig + "\"");
|
|
111
|
+
project = { root: '', extensions: {}, targets: undefined };
|
|
112
|
+
target = { builder: '', options: { tsConfig: options.tsConfig } };
|
|
113
|
+
}
|
|
105
114
|
}
|
|
106
115
|
catch (error) {
|
|
107
116
|
node_logger_1.logger.error("=> Could not find angular project: " + error.message);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/angular",
|
|
3
|
-
"version": "6.4.0-alpha.
|
|
3
|
+
"version": "6.4.0-alpha.36",
|
|
4
4
|
"description": "Storybook for Angular: Develop Angular Components in isolation with Hot Reloading.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook"
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"types": "dist/ts3.9/client/index.d.ts",
|
|
25
25
|
"typesVersions": {
|
|
26
26
|
"<3.8": {
|
|
27
|
-
"
|
|
27
|
+
"dist/ts3.9/*": [
|
|
28
28
|
"dist/ts3.4/*"
|
|
29
29
|
]
|
|
30
30
|
}
|
|
@@ -45,12 +45,14 @@
|
|
|
45
45
|
"prepare": "node ../../scripts/prepare.js"
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@storybook/addons": "6.4.0-alpha.
|
|
49
|
-
"@storybook/api": "6.4.0-alpha.
|
|
50
|
-
"@storybook/core": "6.4.0-alpha.
|
|
51
|
-
"@storybook/core-common": "6.4.0-alpha.
|
|
52
|
-
"@storybook/core-events": "6.4.0-alpha.
|
|
53
|
-
"@storybook/
|
|
48
|
+
"@storybook/addons": "6.4.0-alpha.36",
|
|
49
|
+
"@storybook/api": "6.4.0-alpha.36",
|
|
50
|
+
"@storybook/core": "6.4.0-alpha.36",
|
|
51
|
+
"@storybook/core-common": "6.4.0-alpha.36",
|
|
52
|
+
"@storybook/core-events": "6.4.0-alpha.36",
|
|
53
|
+
"@storybook/csf": "0.0.2--canary.68887a1.0",
|
|
54
|
+
"@storybook/node-logger": "6.4.0-alpha.36",
|
|
55
|
+
"@storybook/store": "6.4.0-alpha.36",
|
|
54
56
|
"@types/webpack-env": "^1.16.0",
|
|
55
57
|
"autoprefixer": "^9.8.6",
|
|
56
58
|
"core-js": "^3.8.2",
|
|
@@ -129,5 +131,5 @@
|
|
|
129
131
|
"access": "public"
|
|
130
132
|
},
|
|
131
133
|
"builders": "dist/ts3.9/builders/builders.json",
|
|
132
|
-
"gitHead": "
|
|
134
|
+
"gitHead": "cc13af28a7ea2042d63075ff94e542c99fdc4aad"
|
|
133
135
|
}
|
package/preset.js
ADDED