mirror of
https://github.com/storybookjs/storybook.git
synced 2025-03-31 05:03:21 +08:00
Merge pull request #18775 from storybookjs/feat/addons-actions-tsup
Build addons-actions with ts-up
This commit is contained in:
commit
b42f0edea7
@ -1 +1 @@
|
||||
import './dist/esm/manager';
|
||||
import './dist/manager';
|
||||
|
@ -21,9 +21,32 @@
|
||||
"url": "https://opencollective.com/storybook"
|
||||
},
|
||||
"license": "MIT",
|
||||
"main": "dist/cjs/index.js",
|
||||
"module": "dist/esm/index.js",
|
||||
"types": "dist/types/index.d.ts",
|
||||
"exports": {
|
||||
".": {
|
||||
"require": "./dist/index.js",
|
||||
"import": "./dist/index.mjs",
|
||||
"types": "./dist/index.d.ts"
|
||||
},
|
||||
"./manager": {
|
||||
"require": "./dist/manager.js",
|
||||
"import": "./dist/manager.mjs",
|
||||
"types": "./dist/manager.d.ts"
|
||||
},
|
||||
"./preview": {
|
||||
"require": "./dist/preview.js",
|
||||
"import": "./dist/preview.mjs",
|
||||
"types": "./dist/preview.d.ts"
|
||||
},
|
||||
"./register.js": {
|
||||
"require": "./dist/manager.js",
|
||||
"import": "./dist/manager.mjs",
|
||||
"types": "./dist/manager.d.ts"
|
||||
},
|
||||
"./package.json": "./package.json"
|
||||
},
|
||||
"main": "dist/index.js",
|
||||
"module": "dist/index.mjs",
|
||||
"types": "dist/index.d.ts",
|
||||
"files": [
|
||||
"dist/**/*",
|
||||
"README.md",
|
||||
@ -32,7 +55,7 @@
|
||||
],
|
||||
"scripts": {
|
||||
"check": "../../../scripts/node_modules/.bin/tsc --noEmit",
|
||||
"prep": "node ../../../scripts/prepare.js"
|
||||
"prep": "../../../scripts/prepare/bundle.ts"
|
||||
},
|
||||
"dependencies": {
|
||||
"@storybook/addons": "7.0.0-alpha.34",
|
||||
@ -72,6 +95,13 @@
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
},
|
||||
"bundler": {
|
||||
"entries": [
|
||||
"./src/index.ts",
|
||||
"./src/manager.tsx",
|
||||
"./src/preview.ts"
|
||||
]
|
||||
},
|
||||
"gitHead": "fc90fc875462421c1faa35862ac4bc436de8e75f",
|
||||
"storybook": {
|
||||
"displayName": "Actions",
|
||||
|
@ -1 +1 @@
|
||||
export * from './dist/esm/preset/preview';
|
||||
export * from './dist/preview';
|
||||
|
@ -1,5 +1,5 @@
|
||||
import type { Args, AnyFramework, ArgsEnhancer } from '@storybook/csf';
|
||||
import { action } from '../index';
|
||||
import { action } from './runtime/action';
|
||||
|
||||
// interface ActionsParameter {
|
||||
// disable?: boolean;
|
3
code/addons/actions/src/addDecorator.ts
Normal file
3
code/addons/actions/src/addDecorator.ts
Normal file
@ -0,0 +1,3 @@
|
||||
import { withActions } from './runtime/withActions';
|
||||
|
||||
export const decorators = [withActions];
|
@ -2,7 +2,7 @@
|
||||
|
||||
export * from './constants';
|
||||
export * from './models';
|
||||
export * from './preview';
|
||||
export * from './runtime';
|
||||
|
||||
if (module && module.hot && module.hot.decline) {
|
||||
module.hot.decline();
|
||||
|
@ -1,3 +0,0 @@
|
||||
import { withActions } from '../index';
|
||||
|
||||
export const decorators = [withActions];
|
@ -98,11 +98,6 @@ export class PostmsgTransport {
|
||||
...eventOptions,
|
||||
};
|
||||
|
||||
// backwards compat: convert depth to maxDepth
|
||||
if (options && Number.isInteger(options.depth)) {
|
||||
stringifyOptions.maxDepth = options.depth;
|
||||
}
|
||||
|
||||
const frames = this.getFrames(target);
|
||||
|
||||
const query = qs.parse(location.search, { ignoreQueryPrefix: true });
|
||||
|
Loading…
x
Reference in New Issue
Block a user