@storybook/addon-vitest 0.0.0-pr-31557-sha-435676bb → 0.0.0-pr-31557-sha-c3d9912f
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 +3 -17
- package/dist/index.js +2 -2
- package/dist/index.mjs +2 -2
- package/dist/postinstall.js +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,19 +1,5 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as storybook_internal_csf from 'storybook/internal/csf';
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Test addon configuration
|
|
6
|
-
*
|
|
7
|
-
* @see https://storybook.js.org/docs/next/writing-tests/integrations/vitest-addon
|
|
8
|
-
*/
|
|
9
|
-
test: {
|
|
10
|
-
/** Ignore unhandled errors during test execution */
|
|
11
|
-
dangerouslyIgnoreUnhandledErrors?: boolean;
|
|
12
|
-
/** Whether to throw exceptions coming from the play function */
|
|
13
|
-
throwPlayFunctionExceptions?: boolean;
|
|
14
|
-
};
|
|
15
|
-
}
|
|
3
|
+
declare const _default: () => storybook_internal_csf.PreviewAddon<storybook_internal_csf.AddonTypes>;
|
|
16
4
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
export { TestParameters, _default as default };
|
|
5
|
+
export { _default as default };
|
package/dist/index.js
CHANGED
package/dist/index.mjs
CHANGED
package/dist/postinstall.js
CHANGED
|
@@ -58,7 +58,7 @@ ${error2.message}`:execaMessage,message=[shortMessage,stderr,stdout].filter(Bool
|
|
|
58
58
|
https://storybook.js.org/docs/next/${DOCUMENTATION_LINK2}#install-and-set-up
|
|
59
59
|
|
|
60
60
|
Do you want to migrate?
|
|
61
|
-
`,initial:!0})).migrateToNextjsVite&&(await packageManager.addDependencies({type:"devDependencies",skipInstall:!0},[
|
|
61
|
+
`,initial:!0})).migrateToNextjsVite&&(await packageManager.addDependencies({type:"devDependencies",skipInstall:!0},["@storybook/nextjs-vite"]),await packageManager.removeDependencies(["@storybook/nextjs"]),babel.traverse(config._ast,{StringLiteral(path6){path6.node.value==="@storybook/nextjs"&&(path6.node.value="@storybook/nextjs-vite");}}),await csfTools.writeConfig(config,mainJsPath),info2.frameworkPackageName="@storybook/nextjs-vite",info2.builderPackageName="@storybook/builder-vite",await common.scanAndTransformFiles({promptMessage:"Enter a glob to scan for all @storybook/nextjs imports to substitute with @storybook/nextjs-vite:",force:options.yes,dryRun:!1,transformFn:(files,options2,dryRun)=>common.transformImportFiles(files,options2,dryRun),transformOptions:{"@storybook/nextjs":"@storybook/nextjs-vite"}}));let annotationsImport=SUPPORTED_FRAMEWORKS.includes(info2.frameworkPackageName)?info2.frameworkPackageName==="@storybook/nextjs"?"@storybook/nextjs-vite":info2.frameworkPackageName:null,isRendererSupported=!!annotationsImport,result=await(async()=>{let reasons=[];hasCustomWebpackConfig&&reasons.push("\u2022 The addon can not be used with a custom Webpack configuration."),info2.frameworkPackageName!=="@storybook/nextjs"&&info2.builderPackageName!=="@storybook/builder-vite"&&reasons.push("\u2022 The addon can only be used with a Vite-based Storybook framework or Next.js."),isRendererSupported||reasons.push(tsDedent.dedent`
|
|
62
62
|
• The addon cannot yet be used with ${import_picocolors.default.bold(nodeLogger.colors.pink(info2.frameworkPackageName))}
|
|
63
63
|
`),coercedVitestVersion&&!(0, import_semver.satisfies)(coercedVitestVersion,">=3.0.0")&&reasons.push(tsDedent.dedent`
|
|
64
64
|
• The addon requires Vitest 3.0.0 or higher. You are currently using ${import_picocolors.default.bold(vitestVersionSpecifier)}.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/addon-vitest",
|
|
3
|
-
"version": "0.0.0-pr-31557-sha-
|
|
3
|
+
"version": "0.0.0-pr-31557-sha-c3d9912f",
|
|
4
4
|
"description": "Storybook addon for testing components",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook-addons",
|
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
"peerDependencies": {
|
|
125
125
|
"@vitest/browser": "^3.0.0",
|
|
126
126
|
"@vitest/runner": "^3.0.0",
|
|
127
|
-
"storybook": "^0.0.0-pr-31557-sha-
|
|
127
|
+
"storybook": "^0.0.0-pr-31557-sha-c3d9912f",
|
|
128
128
|
"vitest": "^3.0.0"
|
|
129
129
|
},
|
|
130
130
|
"peerDependenciesMeta": {
|