Skip to content

Commit 8b1468c

Browse files
committed
refactor TextArea story
1 parent 7355a95 commit 8b1468c

File tree

2 files changed

+49
-42
lines changed

2 files changed

+49
-42
lines changed
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
import { Meta, Story, Canvas, ArgsTable } from '@storybook/addon-docs/blocks';
2+
import { TextArea } from '@ui5/webcomponents-react/lib/TextArea';
3+
import { ValueState } from '@ui5/webcomponents-react/lib/ValueState';
4+
import { CSSProperties, Ref } from 'react';
5+
6+
import { createSelectArgTypes } from '@shared/stories/createSelectArgTypes';
7+
import { DocsHeader } from '@shared/stories/DocsHeader';
8+
9+
<Meta
10+
title="UI5 Web Components / TextArea"
11+
component={TextArea}
12+
argTypes={{
13+
...createSelectArgTypes({ valueState: ValueState }),
14+
valueStateMessage: { control: { disable: true } },
15+
slot: { control: { disable: true } },
16+
ref: { control: { disable: true } },
17+
style: {
18+
type: CSSProperties,
19+
description:
20+
'Element style which will be appended to the most outer element of a component. Use this prop carefully, some css properties might break the component.'
21+
},
22+
className: {
23+
type: 'string',
24+
description:
25+
'CSS Class Name which will be appended to the most outer element of a component. Use this prop carefully, overwriting CSS rules might break the component.'
26+
},
27+
tooltip: { type: 'string', description: 'A tooltip which will be shown on hover' }
28+
}}
29+
args={{
30+
valueState: ValueState.None,
31+
style: {},
32+
className: '',
33+
tooltip: '',
34+
slot: '',
35+
ref: null
36+
}}
37+
/>
38+
39+
<DocsHeader />
40+
41+
<Canvas>
42+
<Story name="Default">
43+
{(args) => {
44+
return <TextArea {...args} />;
45+
}}
46+
</Story>
47+
</Canvas>
48+
49+
<ArgsTable story="." />

packages/main/src/webComponents/TextArea/TextArea.stories.tsx

Lines changed: 0 additions & 42 deletions
This file was deleted.

0 commit comments

Comments
 (0)