Skip to content

Commit e3699d2

Browse files
committed
fix(pf3): use default onChange
1 parent 6decd53 commit e3699d2

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

  • packages/pf3-component-mapper/src/files

packages/pf3-component-mapper/src/files/switch.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,7 @@ const Switch = (props) => {
3434
description={description}
3535
inputAddon={inputAddon}
3636
>
37-
<SwitchField
38-
{...rest}
39-
{...input}
40-
disabled={isDisabled}
41-
checked={input.checked}
42-
onChange={({ target: { checked } }) => input.onChange(checked)}
43-
/>
37+
<SwitchField {...rest} {...input} disabled={isDisabled} checked={input.checked} />
4438
</FormGroup>
4539
);
4640
};

0 commit comments

Comments
 (0)