kopia lustrzana https://github.com/bugout-dev/moonstream
footer only -> pagetype footer
rodzic
14bb4a2a0a
commit
afcab5d95c
|
@ -39,6 +39,7 @@ import {
|
|||
USER_NAV_PATHES,
|
||||
SITEMAP,
|
||||
WHITE_LOGO_W_TEXT_URL,
|
||||
PAGETYPE,
|
||||
} from "../core/constants";
|
||||
|
||||
const AppNavbar = () => {
|
||||
|
@ -111,7 +112,10 @@ const AppNavbar = () => {
|
|||
<Flex placeSelf="flex-end">
|
||||
<ButtonGroup variant="link" spacing={4} colorScheme="orange">
|
||||
{SITEMAP.map((item, idx) => {
|
||||
if (!item.children) {
|
||||
if (
|
||||
!item.children &&
|
||||
item.type !== PAGETYPE.FOOTER_CATEGORY
|
||||
) {
|
||||
return (
|
||||
<RouteButton
|
||||
key={`${idx}-${item.title}-landing-all-links`}
|
||||
|
|
|
@ -37,7 +37,12 @@ const _FeatureCard = ({
|
|||
>
|
||||
<GridItem order={1}>
|
||||
<VStack display="inline-grid">
|
||||
<Heading as={heading || "h1"} {...HEADING_PROPS} pb={[3, 12, null]} pt={0}>
|
||||
<Heading
|
||||
as={heading || "h1"}
|
||||
{...HEADING_PROPS}
|
||||
pb={[3, 12, null]}
|
||||
pt={0}
|
||||
>
|
||||
{headingText}
|
||||
</Heading>
|
||||
<chakra.span
|
||||
|
|
|
@ -19,7 +19,7 @@ import useModals from "../core/hooks/useModals";
|
|||
import UIContext from "../core/providers/UIProvider/context";
|
||||
import ChakraAccountIconButton from "./AccountIconButton";
|
||||
import RouteButton from "./RouteButton";
|
||||
import { SITEMAP, WHITE_LOGO_W_TEXT_URL } from "../core/constants";
|
||||
import { PAGETYPE, SITEMAP, WHITE_LOGO_W_TEXT_URL } from "../core/constants";
|
||||
import router from "next/router";
|
||||
import { MODAL_TYPES } from "../core/providers/OverlayProvider/constants";
|
||||
|
||||
|
@ -67,7 +67,7 @@ const LandingNavbar = () => {
|
|||
{SITEMAP.map((item, idx) => {
|
||||
return (
|
||||
<React.Fragment key={`Fragment-${idx}`}>
|
||||
{!item.children && (
|
||||
{!item.children && item.type !== PAGETYPE.FOOTER_CATEGORY && (
|
||||
<RouteButton
|
||||
key={`${idx}-${item.title}-landing-all-links`}
|
||||
variant="link"
|
||||
|
@ -78,7 +78,7 @@ const LandingNavbar = () => {
|
|||
{item.title}
|
||||
</RouteButton>
|
||||
)}
|
||||
{!item.footerOnly && item.children && (
|
||||
{item.type !== PAGETYPE.FOOTER_CATEGORY && item.children && (
|
||||
<Menu>
|
||||
<MenuButton as={Button} rightIcon={<ChevronDownIcon />}>
|
||||
{item.title}
|
||||
|
|
|
@ -25,7 +25,7 @@ import {
|
|||
LockIcon,
|
||||
} from "@chakra-ui/icons";
|
||||
import { MdSettings, MdDashboard, MdTimeline } from "react-icons/md";
|
||||
import { WHITE_LOGO_W_TEXT_URL, SITEMAP } from "../core/constants";
|
||||
import { WHITE_LOGO_W_TEXT_URL, SITEMAP, PAGETYPE } from "../core/constants";
|
||||
import useDashboard from "../core/hooks/useDashboard";
|
||||
import { MODAL_TYPES } from "../core/providers/OverlayProvider/constants";
|
||||
import OverlayContext from "../core/providers/OverlayProvider/context";
|
||||
|
@ -103,7 +103,7 @@ const Sidebar = () => {
|
|||
</MenuItem>
|
||||
{ui.isMobileView &&
|
||||
SITEMAP.map((item, idx) => {
|
||||
if (!item.footerOnly && item.children) {
|
||||
if (item.type !== PAGETYPE.FOOTER_CATEGORY && item.children) {
|
||||
return (
|
||||
<React.Fragment key={`Fragment-${idx}`}>
|
||||
{item.children.map((child, idx) => {
|
||||
|
|
|
@ -33,6 +33,7 @@ export const PAGETYPE = {
|
|||
EMPTY: 0,
|
||||
CONTENT: 1,
|
||||
EXTERNAL: 2,
|
||||
FOOTER_CATEGORY: 3,
|
||||
};
|
||||
|
||||
export const SITEMAP = [
|
||||
|
@ -97,8 +98,7 @@ export const SITEMAP = [
|
|||
{
|
||||
title: "Legal",
|
||||
path: "/legal",
|
||||
type: PAGETYPE.EMPTY,
|
||||
footerOnly: true,
|
||||
type: PAGETYPE.FOOTER_CATEGORY,
|
||||
children: [
|
||||
{
|
||||
title: "Privacy Policy",
|
||||
|
|
Ładowanie…
Reference in New Issue