fix: storybook with typescript (#2926)
* fix storybook for typescript * fix babel
This commit is contained in:
1 parent
1b30ff83a5
commit
f9449e97df
38 files changed
+153
-130
No files matched your search
@@ -1,22 +1,22 @@
|
||||
import Viewport from "../Viewport";
|
||||
import Viewport from '../Viewport';
|
||||
|
||||
import { ArgsTable, Story, Canvas, Meta } from "@storybook/addon-docs";
|
||||
import { createComponentTemplate } from "../../../storybook/functions/create-component-story";
|
||||
import { ArgsTable, Story, Canvas, Meta } from '@storybook/addon-docs';
|
||||
import { createComponentTemplate } from '../../../storybook/functions/create-component-story';
|
||||
|
||||
export const argTypes = {
|
||||
component: Viewport,
|
||||
title: "Components/Viewport",
|
||||
title: 'Components/Viewport',
|
||||
};
|
||||
|
||||
<Meta title="Components/Viewport" component={Viewport} />
|
||||
|
||||
export const ViewportTemplate = (args) => (
|
||||
export const ViewportTemplate = args => (
|
||||
<div className="h-40 bg-primary-dark">
|
||||
<Viewport {...args} />
|
||||
</div>
|
||||
);
|
||||
|
||||
<Heading title="Viewport" componentRelativePath="Viewport/Viewport.jsx" />
|
||||
<Heading title="Viewport" componentRelativePath="Viewport/Viewport.tsx" />
|
||||
|
||||
- [Overview](#overview)
|
||||
- [Props](#props)
|
||||
@@ -31,25 +31,25 @@ Viewport is a component that renders the Viewport action bar.
|
||||
name="Overview"
|
||||
args={{
|
||||
viewportIndex: 0,
|
||||
onSeriesChange: (direction) => alert(`Annotation ${direction}`),
|
||||
onSeriesChange: direction => alert(`Annotation ${direction}`),
|
||||
studyData: {
|
||||
label: "A",
|
||||
label: 'A',
|
||||
isTracked: true,
|
||||
isLocked: false,
|
||||
isRehydratable: false,
|
||||
studyDate: "07-Sep-2011",
|
||||
studyDate: '07-Sep-2011',
|
||||
currentSeries: 1,
|
||||
seriesDescription:
|
||||
"Series description lorem ipsum dolor sit Series description lorem ipsum dolor sit Series description lorem ipsum dolor sit ",
|
||||
modality: "CT",
|
||||
'Series description lorem ipsum dolor sit Series description lorem ipsum dolor sit Series description lorem ipsum dolor sit ',
|
||||
modality: 'CT',
|
||||
patientInformation: {
|
||||
patientName: "Smith, Jane",
|
||||
patientSex: "F",
|
||||
patientAge: "59",
|
||||
MRN: "10000001",
|
||||
thickness: "5.0mm",
|
||||
spacing: "1.25mm",
|
||||
scanner: "Aquilion",
|
||||
patientName: 'Smith, Jane',
|
||||
patientSex: 'F',
|
||||
patientAge: '59',
|
||||
MRN: '10000001',
|
||||
thickness: '5.0mm',
|
||||
spacing: '1.25mm',
|
||||
scanner: 'Aquilion',
|
||||
},
|
||||
},
|
||||
}}
|
||||
|
||||
Reference in new issue
Block a user