@@ -3,6 +3,8 @@ import styled from "styled-components";
33
44import { Group } from "consts/disputeFeature" ;
55
6+ import LightButton from "../LightButton" ;
7+
68const Container = styled . div `
79 width: 100%;
810 display: flex;
@@ -18,9 +20,12 @@ const HeaderContainer = styled.div`
1820` ;
1921
2022const Header = styled . h2 `
23+ display: flex;
2124 font-size: 16px;
2225 font-weight: 600;
2326 margin: 0;
27+ align-items: center;
28+ gap: 8px;
2429` ;
2530
2631const SubTitle = styled . p `
@@ -30,21 +35,39 @@ const SubTitle = styled.p`
3035 margin: 0;
3136` ;
3237
33- export type GroupUI = ( props : { children : JSX . Element } ) => JSX . Element ;
38+ const StyledLightButton = styled ( LightButton ) `
39+ padding: 0 !important;
40+ .button-text {
41+ color: ${ ( { theme } ) => theme . primaryBlue } ;
42+ font-size: 14px;
43+ }
44+ :hover {
45+ background-color: transparent !important;
46+ .button-text {
47+ color: ${ ( { theme } ) => theme . secondaryBlue } ;
48+ }
49+ }
50+ ` ;
51+
52+ export type GroupUI = ( props : { children : JSX . Element ; clearAll : ( ) => void } ) => JSX . Element ;
3453export const GroupsUI : Record < Group , GroupUI > = {
35- [ Group . Voting ] : ( { children } ) => (
54+ [ Group . Voting ] : ( { children, clearAll } ) => (
3655 < Container key = { Group . Voting } >
3756 < HeaderContainer >
38- < Header > Shielded Voting</ Header >
57+ < Header >
58+ Shielded Voting < StyledLightButton text = "Clear" onClick = { clearAll } />
59+ </ Header >
3960 < SubTitle > This feature hides the jurors votes until the end of the voting period.</ SubTitle >
4061 </ HeaderContainer >
4162 { children }
4263 </ Container >
4364 ) ,
44- [ Group . Eligibility ] : ( { children } ) => (
65+ [ Group . Eligibility ] : ( { children, clearAll } ) => (
4566 < Container key = { Group . Eligibility } >
4667 < HeaderContainer >
47- < Header > Jurors Eligibility</ Header >
68+ < Header >
69+ Jurors Eligibility < StyledLightButton text = "Clear" onClick = { clearAll } />
70+ </ Header >
4871 < SubTitle > This feature determines who can be selected as a juror.</ SubTitle >
4972 </ HeaderContainer >
5073 { children }
0 commit comments