Skip to content

Commit 8cc96a1

Browse files
committed
feat: feedback and styling/functionalities sync
1 parent 7c63a75 commit 8cc96a1

69 files changed

Lines changed: 210 additions & 208 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

web/src/app.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import "react-toastify/dist/ReactToastify.css";
99
import "ethereum-identity-kit/css";
1010
import "@kleros/ui-components-library/style.css";
1111
import "@kleros/ui-components-library/theme.css";
12+
import "./styles/base-elements.css";
1213
import "./i18n";
1314

1415
import AtlasProvider from "context/AtlasProvider";

web/src/components/CaseStarButton.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,7 @@ const CaseStarButton: React.FC<{ id: string }> = ({ id }) => {
4949
starred={starred}
5050
aria-label={text}
5151
aria-checked={starred}
52-
onClick={(e) => {
53-
e.stopPropagation();
52+
onPress={() => {
5453
starCase(id);
5554
}}
5655
/>

web/src/components/CasesDisplay/Filters.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ const Filters: React.FC = () => {
105105
dot: theme.primaryPurple,
106106
},
107107
]}
108-
defaultValue={JSON.stringify({ ruled, period })}
108+
defaultSelectedKey={JSON.stringify({ ruled, period })}
109109
callback={handleStatusChange}
110110
/>
111111
<DropdownSelect
@@ -115,7 +115,7 @@ const Filters: React.FC = () => {
115115
{ id: "desc", itemValue: "desc", text: t("filters.newest") },
116116
{ id: "asc", itemValue: "asc", text: t("filters.oldest") },
117117
]}
118-
defaultValue={order}
118+
defaultSelectedKey={order}
119119
callback={handleOrderChange}
120120
/>
121121
{isDesktop ? (

web/src/components/ClaimPnkButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ const ClaimPnkButton: React.FC = () => {
7171
<Button
7272
variant="primary"
7373
text={faucetCheck ? t("buttons.claim_pnk") : t("buttons.empty_faucet")}
74-
onClick={handleRequest}
74+
onPress={handleRequest}
7575
isLoading={isSending}
7676
isDisabled={isSending || claimed || !faucetCheck || isUndefined(address)}
7777
Icon={faucetCheck ? FaucetIcon : undefined}

web/src/components/ConnectWallet/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export const SwitchChainButton: React.FC<{ className?: string }> = ({ className
3131
isLoading={isLoading}
3232
isDisabled={isLoading}
3333
text={t("buttons.switch_to_chain", { chainName: DEFAULT_CHAIN.name })}
34-
onClick={handleSwitch}
34+
onPress={handleSwitch}
3535
/>
3636
);
3737
};
@@ -46,7 +46,7 @@ const ConnectButton: React.FC<{ className?: string }> = ({ className }) => {
4646
isDisabled={isOpen}
4747
small
4848
text={t("buttons.connect")}
49-
onClick={async () => open({ view: "Connect" })}
49+
onPress={async () => open({ view: "Connect" })}
5050
/>
5151
);
5252
};

web/src/components/DisputeFeatures/GroupsUI.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ const VotingGroup: React.FC<{ children: JSX.Element; clearAll: () => void }> = (
5959
<Container key={Group.Voting}>
6060
<HeaderContainer>
6161
<Header>
62-
{t("misc.shielded_voting")} <StyledLightButton text={t("buttons.clear")} onClick={clearAll} />
62+
{t("misc.shielded_voting")} <StyledLightButton text={t("buttons.clear")} onPress={clearAll} />
6363
</Header>
6464
<SubTitle>{t("tooltips.shielded_voting_description")}</SubTitle>
6565
</HeaderContainer>
@@ -74,7 +74,7 @@ const EligibilityGroup: React.FC<{ children: JSX.Element; clearAll: () => void }
7474
<Container key={Group.Eligibility}>
7575
<HeaderContainer>
7676
<Header>
77-
{t("misc.jurors_eligibility")} <StyledLightButton text={t("buttons.clear")} onClick={clearAll} />
77+
{t("misc.jurors_eligibility")} <StyledLightButton text={t("buttons.clear")} onPress={clearAll} />
7878
</Header>
7979
<SubTitle>{t("tooltips.jurors_eligibility_description")}</SubTitle>
8080
</HeaderContainer>

web/src/components/EnsureAuth.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ const EnsureAuth: React.FC<IEnsureAuth> = ({ children, message, buttonText, clas
5151
{message ? <StyledInfo>{message}</StyledInfo> : null}
5252
<Button
5353
text={buttonText ?? t("wallet.sign_in")}
54-
onClick={handleClick}
54+
onPress={handleClick}
5555
isDisabled={isSigningIn || !address}
5656
isLoading={isSigningIn}
5757
{...{ className }}

web/src/components/ErrorFallback.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ const ErrorFallback: React.FC<FallbackProps> = ({ error, resetErrorBoundary }) =
113113
<Header>{t("errors.something_went_wrong")}</Header>
114114
<Subtitle>{t("errors.reload_or_contact")}</Subtitle>
115115
<ButtonsContainer>
116-
<Button text={t("buttons.reload")} onClick={resetErrorBoundary} />
116+
<Button text={t("buttons.reload")} onPress={resetErrorBoundary} />
117117
<a href={"https://t.me/kleros"} target="_blank" rel="noreferrer">
118118
<Button text={t("buttons.contact_us")} />
119119
</a>

web/src/components/ExternalLinkWarning.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,8 +160,8 @@ const ExternalLinkWarning: React.FC<IExternalLinkWarning> = ({ isOpen, url, onCo
160160
</Message>
161161

162162
<ButtonContainer>
163-
<CancelButton text={t("buttons.cancel")} onClick={onCancel} />
164-
<ConfirmButton text={t("buttons.continue_to_external_site")} onClick={onConfirm} />
163+
<CancelButton text={t("buttons.cancel")} onPress={onCancel} />
164+
<ConfirmButton text={t("buttons.continue_to_external_site")} onPress={onConfirm} />
165165
</ButtonContainer>
166166
</StyledModal>
167167
);

web/src/components/Field.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ const LinkContainer = styled.div`
6565
`;
6666

6767
const StyledInternalLink = styled(InternalLink)`
68+
display: flex;
6869
text-wrap: auto;
6970
justify-content: end;
7071
line-height: 1.25;

0 commit comments

Comments
 (0)