This repository was archived by the owner on Mar 1, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -158,15 +158,15 @@ function FormElements() {
158
158
< Form . Group label = "Input Group Buttons" >
159
159
< Form . InputGroup >
160
160
< Form . Input />
161
- < Form . InputGroupAppend >
161
+ < Form . InputGroup append >
162
162
< Button color = "primary" > Actions</ Button >
163
163
< Button . Dropdown color = "primary" >
164
164
< Dropdown . Item > News</ Dropdown . Item >
165
165
< Dropdown . Item > Messages</ Dropdown . Item >
166
166
< Dropdown . ItemDivider />
167
167
< Dropdown . Item > Edit Profile</ Dropdown . Item >
168
168
</ Button . Dropdown >
169
- </ Form . InputGroupAppend >
169
+ </ Form . InputGroup >
170
170
</ Form . InputGroup >
171
171
</ Form . Group >
172
172
</ ComponentDemo >
Original file line number Diff line number Diff line change @@ -27,6 +27,14 @@ function FormInputGroup(props: Props): React.Node {
27
27
const Component = RootComponent || "div" ;
28
28
const children = inputProps ? < Form . Input { ...inputProps } /> : props . children ;
29
29
30
+ if ( prepend === true ) {
31
+ return < FormInputGroupPrepend > { children } </ FormInputGroupPrepend > ;
32
+ }
33
+
34
+ if ( append === true ) {
35
+ return < FormInputGroupAppend > { children } </ FormInputGroupAppend > ;
36
+ }
37
+
30
38
return (
31
39
< Component className = { classes } >
32
40
{ prepend && < FormInputGroupPrepend > { prepend } </ FormInputGroupPrepend > }
You can’t perform that action at this time.
0 commit comments