|
|
|
@ -3,6 +3,7 @@ import classNames from "classnames";
|
|
|
|
|
import { useEffect } from "react";
|
|
|
|
|
import { NavLink } from "react-router-dom";
|
|
|
|
|
import useCurrentUser from "@/hooks/useCurrentUser";
|
|
|
|
|
import { Routes } from "@/router";
|
|
|
|
|
import { useInboxStore } from "@/store/v1";
|
|
|
|
|
import { Inbox_Status } from "@/types/proto/api/v2/inbox_service";
|
|
|
|
|
import { useTranslate } from "@/utils/i18n";
|
|
|
|
@ -49,25 +50,25 @@ const Navigation = (props: Props) => {
|
|
|
|
|
|
|
|
|
|
const homeNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-home",
|
|
|
|
|
path: "/",
|
|
|
|
|
path: Routes.HOME,
|
|
|
|
|
title: t("common.home"),
|
|
|
|
|
icon: <Icon.Home className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|
const timelineNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-timeline",
|
|
|
|
|
path: "/timeline",
|
|
|
|
|
path: Routes.TIMELINE,
|
|
|
|
|
title: t("timeline.title"),
|
|
|
|
|
icon: <Icon.GanttChartSquare className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|
const resourcesNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-resources",
|
|
|
|
|
path: "/resources",
|
|
|
|
|
path: Routes.RESOURCES,
|
|
|
|
|
title: t("common.resources"),
|
|
|
|
|
icon: <Icon.Paperclip className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|
const exploreNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-explore",
|
|
|
|
|
path: "/explore",
|
|
|
|
|
path: Routes.EXPLORE,
|
|
|
|
|
title: t("common.explore"),
|
|
|
|
|
icon: <Icon.Globe2 className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
@ -79,7 +80,7 @@ const Navigation = (props: Props) => {
|
|
|
|
|
};
|
|
|
|
|
const inboxNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-inbox",
|
|
|
|
|
path: "/inbox",
|
|
|
|
|
path: Routes.INBOX,
|
|
|
|
|
title: t("common.inbox"),
|
|
|
|
|
icon: (
|
|
|
|
|
<>
|
|
|
|
@ -92,25 +93,25 @@ const Navigation = (props: Props) => {
|
|
|
|
|
};
|
|
|
|
|
const archivedNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-archived",
|
|
|
|
|
path: "/archived",
|
|
|
|
|
path: Routes.ARCHIVED,
|
|
|
|
|
title: t("common.archived"),
|
|
|
|
|
icon: <Icon.Archive className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|
const settingNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-setting",
|
|
|
|
|
path: "/setting",
|
|
|
|
|
path: Routes.SETTING,
|
|
|
|
|
title: t("common.settings"),
|
|
|
|
|
icon: <Icon.Settings className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|
const signInNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-auth",
|
|
|
|
|
path: "/auth",
|
|
|
|
|
path: Routes.AUTH,
|
|
|
|
|
title: t("common.sign-in"),
|
|
|
|
|
icon: <Icon.LogIn className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|
const aboutNavLink: NavLinkItem = {
|
|
|
|
|
id: "header-about",
|
|
|
|
|
path: "/about",
|
|
|
|
|
path: Routes.ABOUT,
|
|
|
|
|
title: t("common.about"),
|
|
|
|
|
icon: <Icon.Smile className="w-6 h-auto opacity-70" />,
|
|
|
|
|
};
|
|
|
|
|