1
1
import Box from "@material-ui/core/Box"
2
+ import Chip from "@material-ui/core/Chip"
2
3
import { makeStyles } from "@material-ui/core/styles"
3
4
import Typography from "@material-ui/core/Typography"
5
+ import { Stack } from "components/Stack/Stack"
4
6
import { FC , ReactNode } from "react"
5
- import { MONOSPACE_FONT_FAMILY } from "../../theme/constants"
6
7
7
8
export interface PaywallProps {
8
9
message : string
@@ -17,9 +18,18 @@ export const Paywall: FC<React.PropsWithChildren<PaywallProps>> = (props) => {
17
18
return (
18
19
< Box className = { styles . root } >
19
20
< div className = { styles . header } >
20
- < Typography variant = "h5" className = { styles . title } >
21
- { message }
22
- </ Typography >
21
+ < Stack direction = "row" alignItems = "center" justifyContent = "center" >
22
+ < Typography variant = "h5" className = { styles . title } >
23
+ { message }
24
+ </ Typography >
25
+ < Chip
26
+ className = { styles . enterpriseChip }
27
+ label = "Enterprise"
28
+ size = "small"
29
+ color = "primary"
30
+ />
31
+ </ Stack >
32
+
23
33
{ description && (
24
34
< Typography
25
35
variant = "body2"
@@ -35,33 +45,36 @@ export const Paywall: FC<React.PropsWithChildren<PaywallProps>> = (props) => {
35
45
)
36
46
}
37
47
38
- const useStyles = makeStyles (
39
- ( theme ) => ( {
40
- root : {
41
- display : "flex" ,
42
- flexDirection : "column" ,
43
- justifyContent : "center" ,
44
- alignItems : "center" ,
45
- textAlign : "center" ,
46
- minHeight : 300 ,
47
- padding : theme . spacing ( 3 ) ,
48
- fontFamily : MONOSPACE_FONT_FAMILY ,
49
- backgroundColor : theme . palette . background . paper ,
50
- border : `1px solid ${ theme . palette . divider } ` ,
51
- borderRadius : theme . shape . borderRadius ,
52
- } ,
53
- header : {
54
- marginBottom : theme . spacing ( 3 ) ,
55
- } ,
56
- title : {
57
- fontWeight : 600 ,
58
- fontFamily : "inherit" ,
59
- } ,
60
- description : {
61
- marginTop : theme . spacing ( 1 ) ,
62
- fontFamily : "inherit" ,
63
- maxWidth : 420 ,
64
- } ,
65
- } ) ,
66
- { name : "Paywall" } ,
67
- )
48
+ const useStyles = makeStyles ( ( theme ) => ( {
49
+ root : {
50
+ display : "flex" ,
51
+ flexDirection : "column" ,
52
+ justifyContent : "center" ,
53
+ alignItems : "center" ,
54
+ textAlign : "center" ,
55
+ minHeight : 300 ,
56
+ padding : theme . spacing ( 3 ) ,
57
+ backgroundColor : theme . palette . background . paper ,
58
+ border : `1px solid ${ theme . palette . divider } ` ,
59
+ borderRadius : theme . shape . borderRadius ,
60
+ } ,
61
+ header : {
62
+ marginBottom : theme . spacing ( 3 ) ,
63
+ } ,
64
+ title : {
65
+ fontWeight : 600 ,
66
+ fontFamily : "inherit" ,
67
+ } ,
68
+ description : {
69
+ marginTop : theme . spacing ( 1 ) ,
70
+ fontFamily : "inherit" ,
71
+ maxWidth : 420 ,
72
+ lineHeight : "160%" ,
73
+ } ,
74
+ enterpriseChip : {
75
+ background : theme . palette . success . dark ,
76
+ color : theme . palette . success . contrastText ,
77
+ border : `1px solid ${ theme . palette . success . light } ` ,
78
+ fontSize : 13 ,
79
+ } ,
80
+ } ) )
0 commit comments