Replaced remaining parts of app to use Redux.
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import { useApolloClient } from "@apollo/react-hooks";
|
||||
import { Col, Icon, Menu, Row } from "antd";
|
||||
import React from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
@@ -7,21 +6,15 @@ import CurrentUserDropdown from "../current-user-dropdown/current-user-dropdown.
|
||||
import GlobalSearch from "../global-search/global-search.component";
|
||||
import ManageSignInButton from "../manage-sign-in-button/manage-sign-in-button.component";
|
||||
|
||||
export default ({ landingHeader, navItems, selectedNavItem }) => {
|
||||
const apolloClient = useApolloClient();
|
||||
export default ({ landingHeader, selectedNavItem }) => {
|
||||
const { t } = useTranslation();
|
||||
|
||||
const handleClick = e => {
|
||||
apolloClient.writeData({ data: { selectedNavItem: e.key } });
|
||||
};
|
||||
|
||||
return (
|
||||
<Row type="flex" justify="space-around">
|
||||
<Col span={16}>
|
||||
<Menu
|
||||
theme="dark"
|
||||
className="header"
|
||||
onClick={handleClick}
|
||||
selectedKeys={selectedNavItem}
|
||||
mode="horizontal"
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user