-
Notifications
You must be signed in to change notification settings - Fork 0
/
Cta.tsx
41 lines (36 loc) · 896 Bytes
/
Cta.tsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import * as React from 'react';
import Button from './Button';
interface Props {
onClick: () => void;
disabled?: boolean;
children: JSX.Element | JSX.Element[] | string;
transparent?: boolean;
className?: string;
}
const Cta = (props: Props) => {
const style = {
backgroundColor: props.transparent ? 'rgba(0,0,0,0)' : '#31363b',
};
return (
<Button.Primary
className={`${props.className} text-xl h-fit px-24 py-4 w-full`}
style={style}
disabled={props.disabled}
onClick={props.onClick}
>
{props.children}
</Button.Primary>
);
};
export const Alternative = (props: Props) => {
return (
<Button.Alternative
className={`${props.className} text-lg h-fit px-24 py-4 w-full`}
disabled={props.disabled}
onClick={props.onClick}
>
{props.children}
</Button.Alternative>
);
};
export default Cta;