Skip to content

Commit 61f653f

Browse files
committed
fix: add replace path *
1 parent ee9b73c commit 61f653f

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

web/src/components/DisputeCard/index.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ const DisputeCard: React.FC<CasesPageQuery["disputes"][number]> = ({
5454
const category = metaEvidence ? metaEvidence.category : undefined;
5555
const navigate = useNavigate();
5656
return (
57-
<StyledCard hover onClick={() => navigate(`/cases/${id.toString()}/overview`)}>
57+
<StyledCard hover onClick={() => navigate(`/cases/${id.toString()}`)}>
5858
<PeriodBanner id={parseInt(id)} period={currentPeriodIndex} />
5959
<Container>
6060
<h3>{title}</h3>

web/src/pages/Cases/CaseDetails/index.tsx

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React from "react";
22
import styled from "styled-components";
3-
import { Route, Routes, useParams } from "react-router-dom";
3+
import { Route, Routes, useParams, Navigate } from "react-router-dom";
44
import { Card } from "@kleros/ui-components-library";
55
import { Periods } from "consts/periods";
66
import { useDisputeDetailsQuery } from "queries/useDisputeDetailsQuery";
@@ -29,6 +29,7 @@ const CaseDetails: React.FC = () => {
2929
<Route path="evidence" element={<Evidence {...{ arbitrable }} />} />
3030
<Route path="voting" element={<Voting {...{ arbitrable, currentPeriodIndex }} />} />
3131
<Route path="appeal" element={<Appeal {...{ currentPeriodIndex }} />} />
32+
<Route path="*" element={<Navigate to="overview" replace />} />
3233
</Routes>
3334
</StyledCard>
3435
</Container>

0 commit comments

Comments
 (0)