forked from deriv-com/deriv-app
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d9f64ee
commit 5d09bba
Showing
4 changed files
with
29 additions
and
23 deletions.
There are no files selected for viewing
3 changes: 0 additions & 3 deletions
3
packages/components/src/components/popover-message-checkbox/index.js
This file was deleted.
Oops, something went wrong.
3 changes: 3 additions & 0 deletions
3
packages/components/src/components/popover-message-checkbox/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import PopoverMessageCheckbox from './popover-message-checkbox'; | ||
|
||
export default PopoverMessageCheckbox; |
20 changes: 0 additions & 20 deletions
20
packages/components/src/components/popover-message-checkbox/popover-message-checkbox.jsx
This file was deleted.
Oops, something went wrong.
26 changes: 26 additions & 0 deletions
26
packages/components/src/components/popover-message-checkbox/popover-message-checkbox.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from 'react'; | ||
import Checkbox from '../checkbox'; | ||
|
||
type TPopoverMessageCheckbox = { | ||
defaultChecked?: boolean; | ||
message: string; | ||
name?: string; | ||
onChange: React.FormEventHandler<HTMLInputElement> & | ||
((e: React.ChangeEvent<HTMLInputElement> | React.KeyboardEvent<HTMLSpanElement>) => void); | ||
checkboxLabel: string; | ||
}; | ||
|
||
const PopoverMessageCheckbox = ({ | ||
checkboxLabel, | ||
defaultChecked, | ||
onChange, | ||
message, | ||
name, | ||
}: TPopoverMessageCheckbox) => ( | ||
<React.Fragment> | ||
{message} | ||
<Checkbox defaultChecked={defaultChecked} onChange={onChange} name={name} label={checkboxLabel} /> | ||
</React.Fragment> | ||
); | ||
|
||
export default PopoverMessageCheckbox; |