forked from cerebral/overmind
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathelements.tsx
More file actions
31 lines (30 loc) · 797 Bytes
/
elements.tsx
File metadata and controls
31 lines (30 loc) · 797 Bytes
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
import styled from '../../../styled-components'
export const ButtonElement = styled<
{
primary?: boolean
},
'button'
>('button')`
border: 0;
outline: 0;
text-transform: uppercase;
padding: ${({ theme }) => `${theme.padding.smaller} ${theme.padding.small}`};
border-radius: ${({ theme }) => theme.borderRadius.normal};
color: ${({ theme }) => theme.color.white};
background-color: ${({ primary, theme }) =>
primary ? theme.color.primary : theme.color.primary};
cursor: pointer;
:hover:enabled {
background-color: ${({ primary, theme }) =>
primary
? theme.color.fade(theme.color.primary, 0.1)
: theme.color.fade(theme.color.primary, 0.1)};
}
:hover i {
display: block;
}
:disabled {
opacity: 0.5;
cursor: default;
}
`