We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c0140f9 commit c509c87Copy full SHA for c509c87
apps/question-service/src/components/Header/header.tsx
@@ -1,8 +1,10 @@
1
import { Menu } from "antd";
2
import { Header as AntdHeader } from "antd/es/layout/layout";
3
+import { useRouter } from "next/navigation";
4
import "./styles.scss";
5
6
const Header = (): JSX.Element => {
7
+ const { push } = useRouter();
8
// Stores the details for the header buttons
9
const items = [
10
{
@@ -28,6 +30,9 @@ const Header = (): JSX.Element => {
28
30
defaultSelectedKeys={["0"]}
29
31
items={items}
32
style={{ flex: 1, minWidth: 0 }}
33
+ onClick={(info) => {
34
+ push("/");
35
+ }}
36
/>
37
</AntdHeader>
38
);
0 commit comments