storybook-addon-rslib 3.0.0-beta.3 → 3.0.0-beta.5

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.d.ts CHANGED
@@ -1,3 +1,40 @@
1
- // auto generated file from file:///Users/fi3ework/OSS/storybook-rsbuild/scripts/build/utils/generate-type-mappers.ts, do not edit
2
- export * from '../src/index.ts';
3
- export type * from '../src/index.ts';
1
+ import { RsbuildConfig } from '@rsbuild/core';
2
+ import { LibConfig } from '@rslib/core';
3
+
4
+ interface AddonOptions {
5
+ rslib?: {
6
+ /**
7
+ * `cwd` passed to loadConfig of Rslib
8
+ * @default undefined
9
+ */
10
+ cwd?: string;
11
+ /**
12
+ * `path` passed to loadConfig of Rslib
13
+ * @default undefined
14
+ */
15
+ configPath?: string;
16
+ /**
17
+ * The lib config index in `lib` field to use, will be merged with the other fields in the config.
18
+ * Set to a number to use the lib config at that index.
19
+ * Set to `false` to disable using the lib config.
20
+ * @default 0
21
+ */
22
+ libIndex?: number | false;
23
+ /**
24
+ * Modify the Rslib lib config before transforming it to Rsbuild config which will be merged
25
+ * with Storybook. You can modify the configuration in the config parameters in place.
26
+ * @experimental subject to change at any time
27
+ * @default undefined
28
+ */
29
+ modifyLibConfig?: (config: LibConfig) => void;
30
+ /**
31
+ * Modify the Rsbuild config transformed from lib config before merging with Storybook
32
+ * config. You can modify the configuration in the config parameters in place.
33
+ * @experimental subject to change at any time
34
+ * @default undefined
35
+ */
36
+ modifyLibRsbuildConfig?: (config: RsbuildConfig) => void;
37
+ };
38
+ }
39
+
40
+ export type { AddonOptions };
package/dist/index.js CHANGED
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_43e8bb895d7b8cff from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_43e8bb895d7b8cff from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_43e8bb895d7b8cff from "node:module";
1
+ import CJS_COMPAT_NODE_URL_05cdcfea86440ea1 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_05cdcfea86440ea1 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_05cdcfea86440ea1 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_43e8bb895d7b8cff.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_43e8bb895d7b8cff.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_43e8bb895d7b8cff.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_05cdcfea86440ea1.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_05cdcfea86440ea1.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_05cdcfea86440ea1.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
package/dist/preset.js CHANGED
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_43e8bb895d7b8cff from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_43e8bb895d7b8cff from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_43e8bb895d7b8cff from "node:module";
1
+ import CJS_COMPAT_NODE_URL_05cdcfea86440ea1 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_05cdcfea86440ea1 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_05cdcfea86440ea1 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_43e8bb895d7b8cff.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_43e8bb895d7b8cff.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_43e8bb895d7b8cff.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_05cdcfea86440ea1.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_05cdcfea86440ea1.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_05cdcfea86440ea1.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "storybook-addon-rslib",
3
- "version": "3.0.0-beta.3",
3
+ "version": "3.0.0-beta.5",
4
4
  "description": "Storybook addon for loading configuration of Rslib",
5
5
  "keywords": [
6
6
  "storybook",
@@ -43,7 +43,7 @@
43
43
  "@types/node": "^22.0.0",
44
44
  "storybook": "10.0.7",
45
45
  "typescript": "^5.9.3",
46
- "storybook-builder-rsbuild": "3.0.0-beta.3"
46
+ "storybook-builder-rsbuild": "3.0.0-beta.5"
47
47
  },
48
48
  "peerDependencies": {
49
49
  "@rsbuild/core": "^1.5.0",
@@ -66,7 +66,7 @@
66
66
  "platform": "node"
67
67
  },
68
68
  "scripts": {
69
- "build": "pnpm run prep",
69
+ "build": "pnpm run prep --production",
70
70
  "check": "jiti ../../scripts/check/check-package.ts",
71
71
  "prep": "jiti ../../scripts/build/build-package.ts"
72
72
  }