Skip to content

Commit 708e544

Browse files
committed
chore(@clayui/form): LPD-53483 Add storybook example of ClayInput.InlineText
1 parent e6e165b commit 708e544

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

packages/clay-form/stories/Input.stories.tsx

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
* SPDX-License-Identifier: BSD-3-Clause
44
*/
55

6+
import classNames from 'classnames';
67
import React from 'react';
78

89
import {ClayInput} from '../src';
@@ -86,3 +87,29 @@ Textarea.args = {
8687
readOnly: false,
8788
sizing: undefined,
8889
};
90+
91+
export const InlineText = (args: any) => (
92+
<div className="sheet">
93+
<ClayForm.Group
94+
className={classNames({
95+
['has-error']: args.hasError,
96+
['has-success']: args.hasSuccess,
97+
['has-warning']: args.hasWarning,
98+
})}
99+
>
100+
<label htmlFor="inlineText">Inline Text Example</label>
101+
<ClayInput.InlineText
102+
id="inlineText"
103+
placeholder="Untitled Case Study"
104+
readOnly={args.readOnly}
105+
/>
106+
</ClayForm.Group>
107+
</div>
108+
);
109+
110+
InlineText.args = {
111+
hasError: false,
112+
hasSuccess: false,
113+
hasWarning: false,
114+
readOnly: false,
115+
};

0 commit comments

Comments
 (0)