Skip to content

Commit 7998ff6

Browse files
author
Kubit
committed
An example to modify value visual on Input
An example to modify value visual on Input using CTV props
1 parent 973d844 commit 7998ff6

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

src/components/input/stories/input.stories.tsx

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { themesObject, variantsObject } from '@/designSystem/themesObject';
77
import { additionalInfoAction, labelSecondary } from '../components/stories/stories';
88
import { InputUnControlled as Story } from '../inputUnControlled';
99
import { IInputUnControlled, InputTitleComponentType } from '../types';
10-
import { InputIconPosition } from '../types/inputTheme';
10+
import { InputIconPosition, InputState } from '../types/inputTheme';
1111
import { argtypes } from './argtypes';
1212

1313
const themeSelected = localStorage.getItem('themeSelected') || 'kubit';
@@ -77,3 +77,21 @@ export const InputWithCtv: Story = {
7777
},
7878
},
7979
};
80+
81+
const TEXT_TRANSFORM = {
82+
input: {
83+
text_transform: 'uppercase',
84+
},
85+
placeholder: {
86+
text_transform: 'capitalize',
87+
},
88+
};
89+
90+
export const InputAutoCapitalize: Story = {
91+
args: {
92+
...commonArgs,
93+
ctv: {
94+
[InputState.FILLED]: TEXT_TRANSFORM,
95+
},
96+
},
97+
};

0 commit comments

Comments
 (0)