-
Notifications
You must be signed in to change notification settings - Fork 381
Expand file tree
/
Copy pathInputGroupItems.figma.tsx
More file actions
49 lines (48 loc) · 1.45 KB
/
InputGroupItems.figma.tsx
File metadata and controls
49 lines (48 loc) · 1.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
import figma from '@figma/code-connect';
import { InputGroupItem, InputGroupText, TextInput } from '@patternfly/react-core';
import OutlinedClockIcon from '@patternfly/react-icons/dist/esm/icons/outlined-clock-icon';
// Documentation for InputGroupItem can be found at https://www.patternfly.org/components/input-group
figma.connect(
InputGroupItem,
'https://www.figma.com/design/VMEX8Xg2nzhBX8rfBx53jp/PatternFly-6--Components?node-id=176-2806',
{
props: {
type: figma.enum('Type', {
Icon: (
<InputGroupText id="username">
<OutlinedClockIcon />
</InputGroupText>
),
Text: (
<TextInput
validated={validated}
id="textInput-basic-2"
type="email"
aria-label="Error state username example"
/>
),
Dropdown: figma.children('*'),
Button: figma.children('*')
}),
state: figma.enum('State', {
Disabled: 'disabled',
ReadOnly: 'readOnly',
Success: 'success',
Warning: 'warning',
Error: 'error',
Selected: 'selected'
}),
textInput: figma.enum('Type', {
Text: (
<TextInput
validated={props.state}
id="textInput-basic-2"
type="email"
aria-label="Error state username example"
/>
)
})
},
example: (props) => <InputGroupItem>{props.type}</InputGroupItem>
}
);