18 lines
479 B
TypeScript
18 lines
479 B
TypeScript
import { IonCol } from '@ionic/react';
|
|
import styles from './Button.module.scss';
|
|
|
|
const Button = (props): React.JSX.Element => {
|
|
const { value, special, clickEvent } = props;
|
|
|
|
return (
|
|
<IonCol
|
|
className={`${special ? styles.specialButton : styles.button} animate__animated animate__faster`}
|
|
onClick={(e) => clickEvent(e, value)}
|
|
>
|
|
{value === '/' ? <>÷</> : value === '*' ? <>×</> : value}
|
|
</IonCol>
|
|
);
|
|
};
|
|
|
|
export default Button;
|