-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: marketplace order book history (#3241)
- Loading branch information
Showing
20 changed files
with
1,261 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import MarketPlaceHistoryView from 'src/sections/history/view'; | ||
|
||
// ---------------------------------------------------------------------- | ||
|
||
export const metadata = { | ||
title: 'Market | History', | ||
}; | ||
|
||
export default function Page({ params }: { params: { tick: string } }) { | ||
return <MarketPlaceHistoryView tick={params.tick} />; | ||
} |
25 changes: 25 additions & 0 deletions
25
infra/rooch-portal-v2/src/components/iconify copy/iconify.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { forwardRef } from 'react'; | ||
import { Icon } from '@iconify/react'; | ||
|
||
import Box, { BoxProps } from '@mui/material/Box'; | ||
|
||
import { IconifyProps } from './types'; | ||
|
||
// ---------------------------------------------------------------------- | ||
|
||
interface Props extends BoxProps { | ||
icon: IconifyProps; | ||
} | ||
|
||
const Iconify = forwardRef<SVGElement, Props>(({ icon, width = 20, sx, ...other }, ref) => ( | ||
<Box | ||
ref={ref} | ||
component={Icon} | ||
className="component-iconify" | ||
icon={icon} | ||
sx={{ width, height: width, ...sx }} | ||
{...other} | ||
/> | ||
)); | ||
|
||
export default Iconify; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export * from './types'; | ||
|
||
export { default } from './iconify'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import { IconifyIcon } from '@iconify/react'; | ||
|
||
// ---------------------------------------------------------------------- | ||
|
||
export type IconifyProps = IconifyIcon | string; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
68 changes: 68 additions & 0 deletions
68
infra/rooch-portal-v2/src/sections/history/components/empty-content.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
import Box from '@mui/material/Box'; | ||
import { alpha } from '@mui/material/styles'; | ||
import Typography from '@mui/material/Typography'; | ||
import Stack, { StackProps } from '@mui/material/Stack'; | ||
|
||
// ---------------------------------------------------------------------- | ||
|
||
type EmptyContentProps = StackProps & { | ||
title?: string; | ||
imgUrl?: string; | ||
filled?: boolean; | ||
description?: string; | ||
action?: React.ReactNode; | ||
}; | ||
|
||
export default function EmptyContent({ | ||
title, | ||
imgUrl, | ||
action, | ||
filled, | ||
description, | ||
sx, | ||
...other | ||
}: EmptyContentProps) { | ||
return ( | ||
<Stack | ||
flexGrow={1} | ||
alignItems="center" | ||
justifyContent="center" | ||
sx={{ | ||
px: 3, | ||
height: 1, | ||
...(filled && { | ||
borderRadius: 2, | ||
bgcolor: (theme) => alpha(theme.palette.grey[500], 0.04), | ||
border: (theme) => `dashed 1px ${alpha(theme.palette.grey[500], 0.08)}`, | ||
}), | ||
...sx, | ||
}} | ||
{...other} | ||
> | ||
<Box | ||
component="img" | ||
alt="empty content" | ||
src={imgUrl || '/assets/icons/empty/ic_content.svg'} | ||
sx={{ width: 1, maxWidth: 160 }} | ||
/> | ||
|
||
{title && ( | ||
<Typography | ||
variant="h6" | ||
component="span" | ||
sx={{ mt: 1, color: 'text.disabled', textAlign: 'center' }} | ||
> | ||
{title} | ||
</Typography> | ||
)} | ||
|
||
{description && ( | ||
<Typography variant="caption" sx={{ mt: 1, color: 'text.disabled', textAlign: 'center' }}> | ||
{description} | ||
</Typography> | ||
)} | ||
|
||
{action && action} | ||
</Stack> | ||
); | ||
} |
Oops, something went wrong.