vite-plugin-storybook-nextjs 1.0.5 → 1.0.6

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/index.cjs CHANGED
@@ -472,7 +472,7 @@ function getBaseSWCOptions({
472
472
  esm,
473
473
  modularizeImports,
474
474
  swcPlugins,
475
- compilerOptions,
475
+ compiler,
476
476
  resolvedBaseUrl,
477
477
  jsConfig,
478
478
  swcCacheDir
@@ -508,7 +508,7 @@ function getBaseSWCOptions({
508
508
  decoratorMetadata: emitDecoratorMetadata,
509
509
  useDefineForClassFields,
510
510
  react: {
511
- importSource: jsConfig?.compilerOptions?.jsxImportSource ?? (compilerOptions?.emotion ? "@emotion/react" : "react"),
511
+ importSource: jsConfig?.compilerOptions?.jsxImportSource ?? (compiler?.emotion ? "@emotion/react" : "react"),
512
512
  runtime: "automatic",
513
513
  pragmaFrag: "React.Fragment",
514
514
  throwIfNamespace: true,
@@ -534,7 +534,7 @@ function getBaseSWCOptions({
534
534
  }
535
535
  },
536
536
  sourceMaps: true,
537
- removeConsole: compilerOptions?.removeConsole,
537
+ removeConsole: compiler?.removeConsole,
538
538
  reactRemoveProperties: false,
539
539
  // Map the k-v map to an array of pairs.
540
540
  modularizeImports: modularizeImports ? Object.fromEntries(
@@ -549,14 +549,14 @@ function getBaseSWCOptions({
549
549
  }
550
550
  ])
551
551
  ) : void 0,
552
- relay: compilerOptions?.relay,
552
+ relay: compiler?.relay,
553
553
  // Always transform styled-jsx and error when `client-only` condition is triggered
554
554
  styledJsx: {},
555
555
  // Disable css-in-js libs (without client-only integration) transform on server layer for server components
556
- emotion: getEmotionOptions(compilerOptions?.emotion, development),
556
+ emotion: getEmotionOptions(compiler?.emotion, development),
557
557
  // eslint-disable-next-line @typescript-eslint/no-use-before-define
558
558
  styledComponents: getStyledComponentsOptions(
559
- compilerOptions?.styledComponents,
559
+ compiler?.styledComponents,
560
560
  development
561
561
  ),
562
562
  serverComponents: void 0,
@@ -588,7 +588,7 @@ var getVitestSWCTransformConfig = ({
588
588
  jsConfig: loadedJSConfig.jsConfig,
589
589
  resolvedBaseUrl: loadedJSConfig.resolvedBaseUrl,
590
590
  swcPlugins: nextConfig.experimental.swcPlugins,
591
- compilerOptions: nextConfig?.compilerOptions,
591
+ compiler: nextConfig?.compiler,
592
592
  esm: isEsmProject,
593
593
  swcCacheDir: path__default.default.join(
594
594
  rootDir,
package/dist/index.js CHANGED
@@ -457,7 +457,7 @@ function getBaseSWCOptions({
457
457
  esm,
458
458
  modularizeImports,
459
459
  swcPlugins,
460
- compilerOptions,
460
+ compiler,
461
461
  resolvedBaseUrl,
462
462
  jsConfig,
463
463
  swcCacheDir
@@ -493,7 +493,7 @@ function getBaseSWCOptions({
493
493
  decoratorMetadata: emitDecoratorMetadata,
494
494
  useDefineForClassFields,
495
495
  react: {
496
- importSource: jsConfig?.compilerOptions?.jsxImportSource ?? (compilerOptions?.emotion ? "@emotion/react" : "react"),
496
+ importSource: jsConfig?.compilerOptions?.jsxImportSource ?? (compiler?.emotion ? "@emotion/react" : "react"),
497
497
  runtime: "automatic",
498
498
  pragmaFrag: "React.Fragment",
499
499
  throwIfNamespace: true,
@@ -519,7 +519,7 @@ function getBaseSWCOptions({
519
519
  }
520
520
  },
521
521
  sourceMaps: true,
522
- removeConsole: compilerOptions?.removeConsole,
522
+ removeConsole: compiler?.removeConsole,
523
523
  reactRemoveProperties: false,
524
524
  // Map the k-v map to an array of pairs.
525
525
  modularizeImports: modularizeImports ? Object.fromEntries(
@@ -534,14 +534,14 @@ function getBaseSWCOptions({
534
534
  }
535
535
  ])
536
536
  ) : void 0,
537
- relay: compilerOptions?.relay,
537
+ relay: compiler?.relay,
538
538
  // Always transform styled-jsx and error when `client-only` condition is triggered
539
539
  styledJsx: {},
540
540
  // Disable css-in-js libs (without client-only integration) transform on server layer for server components
541
- emotion: getEmotionOptions(compilerOptions?.emotion, development),
541
+ emotion: getEmotionOptions(compiler?.emotion, development),
542
542
  // eslint-disable-next-line @typescript-eslint/no-use-before-define
543
543
  styledComponents: getStyledComponentsOptions(
544
- compilerOptions?.styledComponents,
544
+ compiler?.styledComponents,
545
545
  development
546
546
  ),
547
547
  serverComponents: void 0,
@@ -573,7 +573,7 @@ var getVitestSWCTransformConfig = ({
573
573
  jsConfig: loadedJSConfig.jsConfig,
574
574
  resolvedBaseUrl: loadedJSConfig.resolvedBaseUrl,
575
575
  swcPlugins: nextConfig.experimental.swcPlugins,
576
- compilerOptions: nextConfig?.compilerOptions,
576
+ compiler: nextConfig?.compiler,
577
577
  esm: isEsmProject,
578
578
  swcCacheDir: path.join(
579
579
  rootDir,
@@ -4,7 +4,7 @@ import { RequestCookies } from 'next/dist/compiled/@edge-runtime/cookies/index.j
4
4
 
5
5
  declare class RequestCookiesMock extends RequestCookies {
6
6
  get: vitest.Mock<[name: string] | [next_dist_compiled__edge_runtime_cookies.RequestCookie], next_dist_compiled__edge_runtime_cookies.RequestCookie | undefined>;
7
- getAll: vitest.Mock<[] | [next_dist_compiled__edge_runtime_cookies.RequestCookie] | [name: string], next_dist_compiled__edge_runtime_cookies.RequestCookie[]>;
7
+ getAll: vitest.Mock<[next_dist_compiled__edge_runtime_cookies.RequestCookie] | [name: string] | [], next_dist_compiled__edge_runtime_cookies.RequestCookie[]>;
8
8
  has: vitest.Mock<[name: string], boolean>;
9
9
  set: vitest.Mock<[key: string, value: string] | [options: next_dist_compiled__edge_runtime_cookies.RequestCookie], this>;
10
10
  delete: vitest.Mock<[names: string | string[]], boolean | boolean[]>;
@@ -4,7 +4,7 @@ import { RequestCookies } from 'next/dist/compiled/@edge-runtime/cookies/index.j
4
4
 
5
5
  declare class RequestCookiesMock extends RequestCookies {
6
6
  get: vitest.Mock<[name: string] | [next_dist_compiled__edge_runtime_cookies.RequestCookie], next_dist_compiled__edge_runtime_cookies.RequestCookie | undefined>;
7
- getAll: vitest.Mock<[] | [next_dist_compiled__edge_runtime_cookies.RequestCookie] | [name: string], next_dist_compiled__edge_runtime_cookies.RequestCookie[]>;
7
+ getAll: vitest.Mock<[next_dist_compiled__edge_runtime_cookies.RequestCookie] | [name: string] | [], next_dist_compiled__edge_runtime_cookies.RequestCookie[]>;
8
8
  has: vitest.Mock<[name: string], boolean>;
9
9
  set: vitest.Mock<[key: string, value: string] | [options: next_dist_compiled__edge_runtime_cookies.RequestCookie], this>;
10
10
  delete: vitest.Mock<[names: string | string[]], boolean | boolean[]>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vite-plugin-storybook-nextjs",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "",
5
5
  "keywords": [
6
6
  "vite-plugin",