Skip to content

Commit caec57e

Browse files
authored
Merge pull request #32571 from storybookjs/version-patch-from-9.1.8
Release: Patch 9.1.9
2 parents f3925a2 + 76c8f30 commit caec57e

File tree

10 files changed

+71
-26
lines changed

10 files changed

+71
-26
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## 9.1.9
2+
3+
- Angular: Enable experimental zoneless detection on Angular v21 - [#32580](https://github.com/storybookjs/storybook/pull/32580), thanks @yannbf!
4+
- Svelte: Ignore inherited `HTMLAttributes` docgen when using utility types - [#32173](https://github.com/storybookjs/storybook/pull/32173), thanks @steciuk!
5+
16
## 9.1.8
27

38
- PreactVite: Add `node` entry point - [#32534](https://github.com/storybookjs/storybook/pull/32534), thanks @ndelangen!

code/frameworks/angular/build-schema.json

Lines changed: 26 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -67,18 +67,27 @@
6767
"compodocArgs": {
6868
"type": "array",
6969
"description": "Compodoc options : https://compodoc.app/guides/options.html. Options `-p` with tsconfig path and `-d` with workspace root is always given.",
70-
"default": ["-e", "json"],
70+
"default": [
71+
"-e",
72+
"json"
73+
],
7174
"items": {
7275
"type": "string"
7376
}
7477
},
7578
"webpackStatsJson": {
76-
"type": ["boolean", "string"],
79+
"type": [
80+
"boolean",
81+
"string"
82+
],
7783
"description": "Write Webpack Stats JSON to disk",
7884
"default": false
7985
},
8086
"statsJson": {
81-
"type": ["boolean", "string"],
87+
"type": [
88+
"boolean",
89+
"string"
90+
],
8291
"description": "Write stats JSON to disk",
8392
"default": false
8493
},
@@ -116,14 +125,16 @@
116125
}
117126
},
118127
"sourceMap": {
119-
"type": ["boolean", "object"],
128+
"type": [
129+
"boolean",
130+
"object"
131+
],
120132
"description": "Configure sourcemaps. See: https://angular.io/guide/workspace-config#source-map-configuration",
121133
"default": false
122134
},
123135
"experimentalZoneless": {
124136
"type": "boolean",
125-
"description": "Experimental: Use zoneless change detection.",
126-
"default": false
137+
"description": "Experimental: Use zoneless change detection."
127138
}
128139
},
129140
"additionalProperties": false,
@@ -159,7 +170,11 @@
159170
}
160171
},
161172
"additionalProperties": false,
162-
"required": ["glob", "input", "output"]
173+
"required": [
174+
"glob",
175+
"input",
176+
"output"
177+
]
163178
},
164179
{
165180
"type": "string"
@@ -187,7 +202,9 @@
187202
}
188203
},
189204
"additionalProperties": false,
190-
"required": ["input"]
205+
"required": [
206+
"input"
207+
]
191208
},
192209
{
193210
"type": "string",
@@ -196,4 +213,4 @@
196213
]
197214
}
198215
}
199-
}
216+
}

code/frameworks/angular/src/builders/build-storybook/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ import { catchError, map, mapTo, switchMap } from 'rxjs/operators';
3030
import { errorSummary, printErrorDetails } from '../utils/error-handler';
3131
import { runCompodoc } from '../utils/run-compodoc';
3232
import type { StandaloneOptions } from '../utils/standalone-options';
33+
import { VERSION } from '@angular/core';
3334

3435
addToGlobalContext('cliVersion', versions.storybook);
3536

@@ -111,7 +112,7 @@ const commandBuilder: BuilderHandlerFn<StorybookBuilderOptions> = (
111112
previewUrl,
112113
sourceMap = false,
113114
preserveSymlinks = false,
114-
experimentalZoneless = false,
115+
experimentalZoneless = !!(VERSION.major && Number(VERSION.major) >= 21),
115116
} = options;
116117

117118
const standaloneOptions: StandaloneBuildOptions = {

code/frameworks/angular/src/builders/start-storybook/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ import { map, mapTo, switchMap } from 'rxjs/operators';
2929
import { errorSummary, printErrorDetails } from '../utils/error-handler';
3030
import { runCompodoc } from '../utils/run-compodoc';
3131
import type { StandaloneOptions } from '../utils/standalone-options';
32+
import { VERSION } from '@angular/core';
3233

3334
addToGlobalContext('cliVersion', versions.storybook);
3435

@@ -128,7 +129,7 @@ const commandBuilder: BuilderHandlerFn<StorybookBuilderOptions> = (options, cont
128129
previewUrl,
129130
sourceMap = false,
130131
preserveSymlinks = false,
131-
experimentalZoneless = false,
132+
experimentalZoneless = !!(VERSION.major && Number(VERSION.major) >= 21),
132133
} = options;
133134

134135
const standaloneOptions: StandaloneOptions = {

code/frameworks/angular/src/server/framework-preset-angular-cli.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,8 @@ export async function getBuilderOptions(options: PresetOptions, builderContext:
147147

148148
logger.info(`=> Using angular project with "tsConfig:${builderOptions.tsConfig}"`);
149149

150+
builderOptions.experimentalZoneless = options.angularBuilderOptions?.experimentalZoneless;
151+
150152
return builderOptions;
151153
}
152154

code/frameworks/angular/start-schema.json

Lines changed: 26 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,10 @@
9393
"compodocArgs": {
9494
"type": "array",
9595
"description": "Compodoc options : https://compodoc.app/guides/options.html. Options `-p` with tsconfig path and `-d` with workspace root is always given.",
96-
"default": ["-e", "json"],
96+
"default": [
97+
"-e",
98+
"json"
99+
],
97100
"items": {
98101
"type": "string"
99102
}
@@ -132,12 +135,18 @@
132135
"description": "URL path to be appended when visiting Storybook for the first time"
133136
},
134137
"webpackStatsJson": {
135-
"type": ["boolean", "string"],
138+
"type": [
139+
"boolean",
140+
"string"
141+
],
136142
"description": "Write Webpack Stats JSON to disk",
137143
"default": false
138144
},
139145
"statsJson": {
140-
"type": ["boolean", "string"],
146+
"type": [
147+
"boolean",
148+
"string"
149+
],
141150
"description": "Write stats JSON to disk",
142151
"default": false
143152
},
@@ -151,14 +160,16 @@
151160
"pattern": "(silly|verbose|info|warn|silent)"
152161
},
153162
"sourceMap": {
154-
"type": ["boolean", "object"],
163+
"type": [
164+
"boolean",
165+
"object"
166+
],
155167
"description": "Configure sourcemaps. See: https://angular.io/guide/workspace-config#source-map-configuration",
156168
"default": false
157169
},
158170
"experimentalZoneless": {
159171
"type": "boolean",
160-
"description": "Experimental: Use zoneless change detection.",
161-
"default": false
172+
"description": "Experimental: Use zoneless change detection."
162173
}
163174
},
164175
"additionalProperties": false,
@@ -194,7 +205,11 @@
194205
}
195206
},
196207
"additionalProperties": false,
197-
"required": ["glob", "input", "output"]
208+
"required": [
209+
"glob",
210+
"input",
211+
"output"
212+
]
198213
},
199214
{
200215
"type": "string"
@@ -222,7 +237,9 @@
222237
}
223238
},
224239
"additionalProperties": false,
225-
"required": ["input"]
240+
"required": [
241+
"input"
242+
]
226243
},
227244
{
228245
"type": "string",
@@ -231,4 +248,4 @@
231248
]
232249
}
233250
}
234-
}
251+
}

code/frameworks/svelte-vite/src/plugins/generateDocgen.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ export function generateDocgen(targetFileName: string, cache: DocgenCache): Docg
450450
// Ignore props from svelte/elements.d.ts (HTMLAttributes, AriaAttributes and DOMAttributes).
451451
// Some libraries use these for {...$$restProps}
452452
if (
453-
prop.valueDeclaration
453+
(prop.valueDeclaration ?? (prop as any)?.links?.syntheticOrigin?.valueDeclaration)
454454
?.getSourceFile()
455455
.fileName.includes('node_modules/svelte/elements.d.ts')
456456
) {

code/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,5 +285,6 @@
285285
"Dependency Upgrades"
286286
]
287287
]
288-
}
288+
},
289+
"deferredNextVersion": "9.1.9"
289290
}

docs/get-started/frameworks/angular.mdx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -367,12 +367,13 @@ These are common options you may need for the Angular builder:
367367
| `"webpackStatsJson"` | Write Webpack Stats JSON to disk. <br /> `"webpackStatsJson": true` |
368368
| `"previewUrl"` | Disables the default storybook preview and lets you use your own. <br /> `"previewUrl": "iframe.html"` |
369369
| `"loglevel"` | Controls level of logging during build. Can be one of: [silly, verbose, info (default), warn, error, silent]. <br /> `"loglevel": "info"` |
370-
| `"sourceMap"` | Configure [sourcemaps](https://angular.io/guide/workspace-config#source-map-configuration.). <br /> `"sourceMap": true` |
370+
| `"sourceMap"` | Configure [sourcemaps](https://angular.dev/reference/configs/workspace-config#source-map-configuration.). <br /> `"sourceMap": true` |
371+
| `"experimentalZoneless"` | Configure [zoneless change detection](https://angular.dev/guide/zoneless). <br /> `"experimentalZoneless": true` |
371372

372373
The full list of options can be found in the Angular builder schemas:
373374

374-
* [Build Storybook](https://github.com/storybookjs/storybook/blob/main/code/frameworks/angular/src/builders/build-storybook/schema.json)
375-
* [Start Storybook](https://github.com/storybookjs/storybook/blob/main/code/frameworks/angular/src/builders/start-storybook/schema.json)
375+
* [Build Storybook](https://github.com/storybookjs/storybook/blob/main/code/frameworks/angular/build-schema.json)
376+
* [Start Storybook](https://github.com/storybookjs/storybook/blob/main/code/frameworks/angular/start-schema.json)
376377

377378
## API
378379

docs/versions/latest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"version":"9.1.7","info":{"plain":"- Dependencies: Update `vite-plugin-storybook-nextjs` to 2.0.7 - [#32331](https://github.com/storybookjs/storybook/pull/32331), thanks @k35o!\n- React: Preserve `@ts-expect-error` in preview - [#32442](https://github.com/storybookjs/storybook/pull/32442), thanks @mrginglymus!\n- Telemetry: Queue error reporting & filter browser-extention - [#32499](https://github.com/storybookjs/storybook/pull/32499), thanks @ndelangen!"}}
1+
{"version":"9.1.9","info":{"plain":"- Angular: Enable experimental zoneless detection on Angular v21 - [#32580](https://github.com/storybookjs/storybook/pull/32580), thanks @yannbf!\n- Svelte: Ignore inherited `HTMLAttributes` docgen when using utility types - [#32173](https://github.com/storybookjs/storybook/pull/32173), thanks @steciuk!"}}

0 commit comments

Comments
 (0)