Skip to content

Commit

Permalink
feat: wp
Browse files Browse the repository at this point in the history
  • Loading branch information
BLuEScioN committed Jan 31, 2025
1 parent f2fe554 commit b1d0018
Show file tree
Hide file tree
Showing 5 changed files with 80 additions and 64 deletions.
9 changes: 8 additions & 1 deletion src/app/_components/NewNavBar/NavBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,14 @@ import { SettingsPopover } from './SettingsPopover';

const DesktopNavBar = (props: any) => {
return (
<Flex width="full" h={10} alignItems="center" justifyContent="space-between" {...props} gap={15}>
<Flex
width="full"
h={10}
alignItems="center"
justifyContent="space-between"
{...props}
gap={15}
>
<Flex alignItems="center" gap={6}>
<Logo logoSize={10} />
<PagesSlidingMenu width={50} />
Expand Down
12 changes: 10 additions & 2 deletions src/app/_components/NewNavBar/NetworkSetting.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,11 @@ const DeleteNetworkMessage = ({
}}
bg="feedback.red-500"
>
<Text fontSize={isMobile ? 'sm' : 'xs'} fontWeight="medium" color="var(--stacks-colors-neutral-sand-50)">
<Text
fontSize={isMobile ? 'sm' : 'xs'}
fontWeight="medium"
color="var(--stacks-colors-neutral-sand-50)"
>
Delete
</Text>
</Button>
Expand All @@ -60,7 +64,11 @@ const DeleteNetworkMessage = ({
}}
bg="var(--stacks-colors-neutral-sand-500)"
>
<Text fontSize={isMobile ? 'sm' : 'xs'} fontWeight="medium" color="var(--stacks-colors-neutral-sand-50)">
<Text
fontSize={isMobile ? 'sm' : 'xs'}
fontWeight="medium"
color="var(--stacks-colors-neutral-sand-50)"
>
Cancel
</Text>
</Button>
Expand Down
3 changes: 2 additions & 1 deletion src/app/_components/NewNavBar/PagesSlidingMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { Box, Flex, Icon, Separator, Stack } from '@chakra-ui/react';
import { ArrowRight, CaretUpDown, List } from '@phosphor-icons/react';
import { usePathname, useRouter } from 'next/navigation';
import { useEffect, useRef, useState } from 'react';

import { primaryPages, secondaryPages } from './consts';

const getPageNameFromPath = (path: string) => {
Expand Down Expand Up @@ -115,7 +116,7 @@ const SlidingMenu = ({ width }: { width: number }) => {
<NextLink
key={page.id}
href={buildUrl(page.href, network)}
variant="noUnderline"
variant="noUnderline"
w="full"
>
<Flex justifyContent="space-between" alignItems="center">
Expand Down
2 changes: 1 addition & 1 deletion src/app/_components/NewNavBar/SettingsPopover.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { PopoverContent, PopoverRoot, PopoverTrigger } from '@/components/ui/popover';
import { CurvedCorner } from '@/ui/icons/CurvedCorner';
import { Box, Flex, Icon, Separator, Stack } from '@chakra-ui/react';
import { GearFine, X } from '@phosphor-icons/react';
import { useState } from 'react';

import { CurrencySetting } from './CurrencySetting';
import { NetworkSetting } from './NetworkSetting';
import { ThemeSetting } from './ThemeSetting';
import { CurvedCorner } from '@/ui/icons/CurvedCorner';

export const SettingsPopover = () => {
const [open, setOpen] = useState(false);
Expand Down
118 changes: 59 additions & 59 deletions src/app/_components/NewNavBar/consts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,63 +6,63 @@ export type Page = {
};

export const primaryPages: Page[] = [
{
id: 'blocks',
label: 'Blocks',
href: '/blocks',
},
{
id: 'transactions',
label: 'Transactions',
href: '/transactions',
},
{
id: 'mempool',
label: 'Mempool',
href: '/mempool',
},
{
id: 'stacking',
label: 'Stacking',
href: '/stacking',
},
{
id: 'signers',
label: 'Signers',
href: '/signers',
},
{
id: 'tokens',
label: 'Tokens',
href: '/tokens',
},
{
id: 'nfts',
label: 'NFTs',
href: '/nfts',
},
{
id: 'analytics',
label: 'Analytics',
href: '/analytics',
},
];
{
id: 'blocks',
label: 'Blocks',
href: '/blocks',
},
{
id: 'transactions',
label: 'Transactions',
href: '/transactions',
},
{
id: 'mempool',
label: 'Mempool',
href: '/mempool',
},
{
id: 'stacking',
label: 'Stacking',
href: '/stacking',
},
{
id: 'signers',
label: 'Signers',
href: '/signers',
},
{
id: 'tokens',
label: 'Tokens',
href: '/tokens',
},
{
id: 'nfts',
label: 'NFTs',
href: '/nfts',
},
{
id: 'analytics',
label: 'Analytics',
href: '/analytics',
},
];

export const secondaryPages = [
{
id: 'sandbox',
label: 'Sandbox',
href: '/sandbox',
shortcut: 'S',
},
{
id: 'status-center',
label: 'Status Center',
href: '/status-center',
},
{
id: 'support',
label: 'Support',
href: '/support',
},
];
{
id: 'sandbox',
label: 'Sandbox',
href: '/sandbox',
shortcut: 'S',
},
{
id: 'status-center',
label: 'Status Center',
href: '/status-center',
},
{
id: 'support',
label: 'Support',
href: '/support',
},
];

0 comments on commit b1d0018

Please sign in to comment.