mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 18:16:38 +08:00
19 lines
481 B
JavaScript
19 lines
481 B
JavaScript
const RadioButton = ( { id, name, value, currentValue, handleRdbState } ) => {
|
|
return (
|
|
<div className="ppcp-r__radio">
|
|
{ /* todo: Can we remove the wrapper div? */ }
|
|
<input
|
|
className="ppcp-r__radio-value"
|
|
type="radio"
|
|
id={ id }
|
|
checked={ value === currentValue }
|
|
name={ name }
|
|
value={ value }
|
|
onChange={ () => handleRdbState( value ) }
|
|
/>
|
|
<span className="ppcp-r__radio-presentation"></span>
|
|
</div>
|
|
);
|
|
};
|
|
|
|
export default RadioButton;
|