Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(components): add breadcrumb to pool id page #468

Merged
merged 3 commits into from
Aug 8, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Improvements

- [#468](https://github.com/alleslabs/celatone-frontend/pull/468) Add breadcrumb to pool id page
- [#457](https://github.com/alleslabs/celatone-frontend/pull/457) Add alert for proposal forum review
- [#389](https://github.com/alleslabs/celatone-frontend/pull/389) Fix modal consistency
- [#381](https://github.com/alleslabs/celatone-frontend/pull/381) Correctly infer output type from snake-camel utils
Expand Down
9 changes: 8 additions & 1 deletion src/lib/pages/pools/components/pool-details/header/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { Button, Flex } from "@chakra-ui/react";

import { PoolHeader } from "../../PoolHeader";
import { useBaseApiRoute, usePoolConfig } from "lib/app-provider";
import { Breadcrumb } from "lib/components/Breadcrumb";
import { CustomIcon } from "lib/components/icon";
import { AmpTrackViewJson, AmpTrackWebsite } from "lib/services/amplitude";
import type { PoolDetail } from "lib/types";
Expand Down Expand Up @@ -29,7 +30,13 @@ export const PoolTopSection = ({ pool }: PoolTopSectionProps) => {
};
return (
<>
<Flex justifyContent="space-between" align="center" w="full">
<Breadcrumb
items={[
{ text: "Pools", href: "/pools" },
{ text: `#${pool.id.toString()}` },
]}
/>
<Flex justifyContent="space-between" align="center" w="full" mt={4}>
<PoolHeader
poolId={pool.id}
isSuperfluid={pool.isSuperfluid}
Expand Down
2 changes: 0 additions & 2 deletions src/lib/pages/pools/poolId.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { useRouter } from "next/router";
import { useEffect } from "react";

import { useInternalNavigate } from "lib/app-provider";
import { BackButton } from "lib/components/button";
import { Loading } from "lib/components/Loading";
import PageContainer from "lib/components/PageContainer";
import { AmpEvent, AmpTrack } from "lib/services/amplitude";
Expand All @@ -29,7 +28,6 @@ export const PoolId = () => {
if (!pool) return navigate({ pathname: `/pools` });
return (
<PageContainer>
<BackButton />
<PoolTopSection pool={pool} />
<PoolAssets pool={pool} />
<PoolRelatedTxs pool={pool} />
Expand Down
Loading