Skip to content

Commit

Permalink
fix(storybook): fix storybook break change
Browse files Browse the repository at this point in the history
  • Loading branch information
Kunduin committed Oct 9, 2019
1 parent b75a037 commit cd1cd01
Show file tree
Hide file tree
Showing 3 changed files with 4,997 additions and 4,785 deletions.
26 changes: 12 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,23 +35,21 @@
"react-dom": ">=16.0.0"
},
"devDependencies": {
"@babel/core": "^7.4.5",
"@babel/plugin-proposal-class-properties": "^7.4.4",
"@babel/plugin-proposal-object-rest-spread": "^7.4.4",
"@babel/preset-env": "^7.4.5",
"@babel/preset-typescript": "^7.3.3",
"@storybook/addon-a11y": "^5.1.1",
"@storybook/addon-actions": "^5.1.1",
"@storybook/addon-info": "^5.1.1",
"@storybook/addon-links": "^5.1.1",
"@storybook/addons": "^5.1.1",
"@storybook/react": "^5.1.1",
"@babel/core": "^7.6.3",
"@babel/plugin-proposal-class-properties": "^7.5.5",
"@babel/plugin-proposal-object-rest-spread": "^7.6.2",
"@babel/preset-env": "^7.6.3",
"@babel/preset-typescript": "^7.6.0",
"@storybook/addon-a11y": "^5.2.3",
"@storybook/addon-actions": "^5.2.3",
"@storybook/addon-info": "^5.2.3",
"@storybook/addon-links": "^5.2.3",
"@storybook/addons": "^5.2.3",
"@storybook/react": "^5.2.3",
"@svgr/rollup": "^4.2.0",
"@types/jest": "^24.0.12",
"@types/jest": "^24.0.18",
"@types/react-dom": "^16.9.1",
"@types/react": "^16.9.1",
"@types/storybook__addon-a11y": "^5.0.0",
"@types/storybook__addon-actions": "^3.4.3",
"@types/storybook__react": "^4.0.2",
"babel-loader": "^8.0.5",
"commitizen": "^4.0.0",
Expand Down
5 changes: 2 additions & 3 deletions stories/index.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
import { withA11y } from "@storybook/addon-a11y";
import { storiesOf, StoryDecorator } from "@storybook/react";
import { addDecorator, storiesOf } from "@storybook/react";
import React, { useEffect, useState } from "react";

import { ReactPictureAnnotation } from "../src";
import { IAnnotation } from "../src/Annotation";
import { IShapeData } from "../src/Shape";

const CenterDecorator: StoryDecorator = storyFn => <div>{storyFn()}</div>;
addDecorator(storyFn => <div>{storyFn()}</div>);

storiesOf("Hello World", module)
.addDecorator(withA11y)
.addDecorator(CenterDecorator)
.add("with text", () => {
const AnnotationComponent = () => {
const [size, setSize] = useState({
Expand Down
Loading

0 comments on commit cd1cd01

Please sign in to comment.