File tree 12 files changed +72
-104
lines changed
web/src/pages/Home/TopJurors
12 files changed +72
-104
lines changed Original file line number Diff line number Diff line change @@ -5,23 +5,20 @@ import { useWindowSize } from "react-use";
5
5
import WithHelpTooltip from "pages/Dashboard/WithHelpTooltip" ;
6
6
7
7
const Container = styled . div `
8
- label {
9
- font-size: 12px !important;
10
- &::before {
11
- content: "Votes";
12
- }
8
+ display: flex;
9
+ font-size: 12px !important;
10
+ &::before {
11
+ content: "Votes";
13
12
}
13
+ color: ${ ( { theme } ) => theme . secondaryText } ;
14
+ align-items: center;
14
15
15
16
${ landscapeStyle (
16
17
( ) =>
17
18
css `
18
- display: flex;
19
-
20
- label {
21
- font-size: 14px !important;
22
- &::before {
23
- content: "Coherent Votes";
24
- }
19
+ font-size: 14px !important;
20
+ &::before {
21
+ content: "Coherent Votes";
25
22
}
26
23
`
27
24
) }
@@ -37,9 +34,10 @@ const Coherency: React.FC = () => {
37
34
const { width } = useWindowSize ( ) ;
38
35
return (
39
36
< Container >
40
- < WithHelpTooltip place = { width > BREAKPOINT_LANDSCAPE ? "top" : "left" } tooltipMsg = { coherentVotesTooltipMsg } >
41
- < label > </ label >
42
- </ WithHelpTooltip >
37
+ < WithHelpTooltip
38
+ place = { width > BREAKPOINT_LANDSCAPE ? "top" : "left" }
39
+ tooltipMsg = { coherentVotesTooltipMsg }
40
+ > </ WithHelpTooltip >
43
41
</ Container >
44
42
) ;
45
43
} ;
Original file line number Diff line number Diff line change @@ -14,24 +14,24 @@ const Container = styled.div`
14
14
cursor: pointer;
15
15
}
16
16
17
- label {
18
- color: ${ ( { theme } ) => theme . primaryBlue } ;
19
- }
20
-
21
17
svg {
22
18
path {
23
19
fill: ${ ( { theme } ) => theme . primaryBlue } ;
24
20
}
25
21
}
26
22
` ;
27
23
24
+ const StyledLabel = styled . label `
25
+ color: ${ ( { theme } ) => theme . primaryBlue } ;
26
+ ` ;
27
+
28
28
const HowItWorks : React . FC = ( ) => {
29
29
const [ isLevelMiniGuidesOpen , toggleIsLevelMiniGuidesOpen ] = useToggle ( false ) ;
30
30
return (
31
31
< >
32
32
< Container onClick = { ( ) => toggleIsLevelMiniGuidesOpen ( ) } >
33
33
< BookOpenIcon />
34
- < label > How it works </ label >
34
+ < StyledLabel > How it works </ StyledLabel >
35
35
</ Container >
36
36
{ isLevelMiniGuidesOpen && < Level { ...{ toggleIsLevelMiniGuidesOpen } } /> }
37
37
</ >
Original file line number Diff line number Diff line change 1
1
import React from "react" ;
2
2
import styled from "styled-components" ;
3
3
4
- const Container = styled . div `
5
- display: flex;
6
- align-items: center;
4
+ const StyledLabel = styled . label `
7
5
width: calc(40px + (220 - 40) * (min(max(100vw, 375px), 1250px) - 375px) / 875);
8
- gap: 36px;
9
-
10
- label {
11
- font-weight: 400;
12
- font-size: 14px;
13
- line-height: 19px;
14
- color: ${ ( { theme } ) => theme . secondaryText } !important;
15
- }
16
6
` ;
17
7
18
- const JurorTitle : React . FC = ( ) => (
19
- < Container >
20
- < label > Juror</ label >
21
- </ Container >
22
- ) ;
8
+ const JurorTitle : React . FC = ( ) => < StyledLabel > Juror</ StyledLabel > ;
23
9
export default JurorTitle ;
Original file line number Diff line number Diff line change 1
1
import React from "react" ;
2
2
import styled from "styled-components" ;
3
3
4
- const Container = styled . div `
4
+ const StyledLabel = styled . label `
5
5
width: calc(16px + (24 - 16) * (min(max(100vw, 375px), 1250px) - 375px) / 875);
6
-
7
- label {
8
- &::before {
9
- content: "#";
10
- }
11
- }
12
6
` ;
13
7
14
- const Rank : React . FC = ( ) => (
15
- < Container >
16
- < label > </ label >
17
- </ Container >
18
- ) ;
8
+ const Rank : React . FC = ( ) => < StyledLabel > #</ StyledLabel > ;
9
+
19
10
export default Rank ;
Original file line number Diff line number Diff line change @@ -4,24 +4,22 @@ import { landscapeStyle } from "styles/landscapeStyle";
4
4
import WithHelpTooltip from "pages/Dashboard/WithHelpTooltip" ;
5
5
6
6
const Container = styled . div `
7
- label {
8
- font-size: 12px !important;
9
- &::before {
10
- content: "Rewards";
11
- }
7
+ display: flex;
8
+ font-size: 12px !important;
9
+ &::before {
10
+ content: "Rewards";
12
11
}
12
+ color: ${ ( { theme } ) => theme . secondaryText } ;
13
+ align-items: center;
13
14
14
15
${ landscapeStyle (
15
16
( ) =>
16
17
css `
17
- display: flex;
18
18
width: calc(60px + (240 - 60) * (min(max(100vw, 375px), 1250px) - 375px) / 875);
19
19
20
- label {
21
- font-size: 14px !important;
22
- &::before {
23
- content: "Total Rewards";
24
- }
20
+ font-size: 14px !important;
21
+ &::before {
22
+ content: "Total Rewards";
25
23
}
26
24
`
27
25
) }
@@ -35,9 +33,8 @@ const totalRewardsTooltipMsg =
35
33
36
34
const Rewards : React . FC = ( ) => (
37
35
< Container >
38
- < WithHelpTooltip place = "top" tooltipMsg = { totalRewardsTooltipMsg } >
39
- < label > </ label >
40
- </ WithHelpTooltip >
36
+ < WithHelpTooltip place = "top" tooltipMsg = { totalRewardsTooltipMsg } > </ WithHelpTooltip >
41
37
</ Container >
42
38
) ;
39
+
43
40
export default Rewards ;
Original file line number Diff line number Diff line change @@ -37,6 +37,7 @@ const PlaceAndTitleAndRewardsAndCoherency = styled.div`
37
37
display: flex;
38
38
flex-direction: row;
39
39
gap: calc(20px + (28 - 20) * (min(max(100vw, 375px), 1250px) - 375px) / 875);
40
+ align-items: center;
40
41
`
41
42
) }
42
43
` ;
Original file line number Diff line number Diff line change @@ -4,10 +4,8 @@ import styled from "styled-components";
4
4
const Container = styled . div `
5
5
display: flex;
6
6
align-items: center;
7
- label {
8
- font-weight: 600;
9
- color: ${ ( { theme } ) => theme . primaryText } ;
10
- }
7
+ font-weight: 600;
8
+ color: ${ ( { theme } ) => theme . primaryText } ;
11
9
flex-wrap: wrap;
12
10
` ;
13
11
@@ -19,10 +17,7 @@ interface ICoherency {
19
17
const Coherency : React . FC < ICoherency > = ( { totalCoherent, totalResolvedDisputes } ) => {
20
18
const coherenceRatio = `${ totalCoherent } /${ totalResolvedDisputes } ` ;
21
19
22
- return (
23
- < Container >
24
- < label > { coherenceRatio } </ label >
25
- </ Container >
26
- ) ;
20
+ return < Container > { coherenceRatio } </ Container > ;
27
21
} ;
22
+
28
23
export default Coherency ;
Original file line number Diff line number Diff line change @@ -9,23 +9,26 @@ const Container = styled.div`
9
9
align-items: center;
10
10
gap: 8px;
11
11
12
- label {
13
- font-size: 12px !important;
12
+ ${ landscapeStyle (
13
+ ( ) => css `
14
+ gap: 16px;
15
+ `
16
+ ) }
17
+ ` ;
14
18
15
- &::before {
16
- content: "Lv. ";
17
- }
19
+ const StyledLabel = styled . label `
20
+ font-size: 12px !important;
21
+
22
+ &::before {
23
+ content: "Lv. ";
18
24
}
19
25
20
26
${ landscapeStyle (
21
27
( ) => css `
22
- gap: 16px;
23
- label {
24
- font-size: 16px !important;
28
+ font-size: 16px !important;
25
29
26
- &::before {
27
- content: "Level ";
28
- }
30
+ &::before {
31
+ content: "Level ";
29
32
}
30
33
`
31
34
) }
@@ -41,7 +44,7 @@ const HowItWorks: React.FC<IHowItWorks> = ({ coherenceScore }) => {
41
44
42
45
return (
43
46
< Container >
44
- < label > { level } </ label >
47
+ < StyledLabel > { level } </ StyledLabel >
45
48
< PixelArt width = "32px" height = "32px" level = { level } />
46
49
</ Container >
47
50
) ;
Original file line number Diff line number Diff line change @@ -8,6 +8,10 @@ const Container = styled.div`
8
8
gap: 8px;
9
9
align-items: center;
10
10
11
+ label {
12
+ font-size: 16px;
13
+ }
14
+
11
15
canvas {
12
16
width: 20px;
13
17
height: 20px;
Original file line number Diff line number Diff line change @@ -21,10 +21,6 @@ const Container = styled.div`
21
21
align-items: center;
22
22
gap: 20px;
23
23
24
- label {
25
- font-size: 16px;
26
- }
27
-
28
24
${ landscapeStyle (
29
25
( ) => css `
30
26
display: none;
Original file line number Diff line number Diff line change @@ -3,18 +3,17 @@ import styled, { css } from "styled-components";
3
3
import { landscapeStyle } from "styles/landscapeStyle" ;
4
4
5
5
const Container = styled . div `
6
- label {
7
- color: ${ ( { theme } ) => theme . primaryText } ;
8
- }
9
- label::before {
6
+ color: ${ ( { theme } ) => theme . primaryText } ;
7
+
8
+ &::before {
10
9
content: "#";
11
10
display: inline;
12
11
}
13
12
14
13
${ landscapeStyle (
15
14
( ) => css `
16
15
width: calc(16px + (24 - 16) * (min(max(100vw, 375px), 1250px) - 375px) / 875);
17
- label ::before {
16
+ & ::before {
18
17
display: none;
19
18
}
20
19
`
@@ -26,10 +25,6 @@ interface IRank {
26
25
}
27
26
28
27
const Rank : React . FC < IRank > = ( { rank } ) => {
29
- return (
30
- < Container >
31
- < label > { rank } </ label >
32
- </ Container >
33
- ) ;
28
+ return < Container > { rank } </ Container > ;
34
29
} ;
35
30
export default Rank ;
Original file line number Diff line number Diff line change @@ -10,10 +10,6 @@ const Container = styled.div`
10
10
display: flex;
11
11
gap: 8px;
12
12
align-items: center;
13
- label {
14
- font-weight: 600;
15
- color: ${ ( { theme } ) => theme . primaryText } ;
16
- }
17
13
flex-wrap: wrap;
18
14
19
15
${ landscapeStyle (
@@ -33,6 +29,12 @@ const StyledIcon = styled.div`
33
29
}
34
30
` ;
35
31
32
+ const StyledLabel = styled . label `
33
+ font-size: 16px;
34
+ font-weight: 600;
35
+ color: ${ ( { theme } ) => theme . primaryText } ;
36
+ ` ;
37
+
36
38
interface IRewards {
37
39
address : string ;
38
40
}
@@ -45,10 +47,10 @@ const Rewards: React.FC<IRewards> = ({ address }) => {
45
47
46
48
return (
47
49
< Container >
48
- < label > { ethReward } </ label >
50
+ < StyledLabel > { ethReward } </ StyledLabel >
49
51
< StyledIcon as = { EthIcon } />
50
- < label > +</ label >
51
- < label > { pnkReward } </ label >
52
+ < StyledLabel > +</ StyledLabel >
53
+ < StyledLabel > { pnkReward } </ StyledLabel >
52
54
< StyledIcon as = { PnkIcon } />
53
55
</ Container >
54
56
) ;
You can’t perform that action at this time.
0 commit comments