Fix: Navbar admin

Deskripsi:
- Fix bug navbar yang terpotong bagian atasnya
This commit is contained in:
2024-11-18 15:18:35 +08:00
parent 1f8bfcbed9
commit 5fcb09b889
111 changed files with 284 additions and 2930 deletions

View File

@@ -1,79 +0,0 @@
"use client";
import { Header, Group, ActionIcon, Text, Title } from "@mantine/core";
import { IconArrowLeft, IconChevronLeft } from "@tabler/icons-react";
import { useRouter } from "next/navigation";
import { useState } from "react";
export default function ComponentVote_HeaderTamplate({
hideBack,
changeIconBack,
route,
route2,
title,
icon,
bg,
}: {
hideBack?: boolean;
changeIconBack?: any;
route?: any;
route2?: any;
title: string;
icon?: any;
bg?: any;
}) {
const router = useRouter();
const [isLoading, setIsLoading] = useState(false);
const [isRightLoading, setRightLoading] = useState(false);
return (
<>
<Header
height={50}
sx={{ borderStyle: "none" }}
bg={bg === null ? "" : bg}
>
<Group h={50} position="apart" px={"md"}>
{hideBack ? (
<ActionIcon variant="transparent" disabled></ActionIcon>
) : (
<ActionIcon
loading={isLoading ? true : false}
variant="transparent"
onClick={() => {
setIsLoading(true);
if (route === null || route === undefined) {
return router.back();
} else {
return router.push(route);
}
}}
>
{changeIconBack ? changeIconBack : <IconChevronLeft />}
</ActionIcon>
)}
<Title order={5}>{title}</Title>
{(() => {
if (route2 === null || route2 === undefined) {
return <ActionIcon disabled variant="transparent"></ActionIcon>;
} else {
return (
<ActionIcon
loading={isRightLoading ? true : false}
variant="transparent"
onClick={() => {
setRightLoading;
true;
router.push(route2);
}}
>
{icon}
</ActionIcon>
);
}
})()}
</Group>
</Header>
</>
);
}

View File

@@ -1,14 +1,12 @@
"use client";
import { ActionIcon, AppShell } from "@mantine/core";
import React, { useState } from "react";
import ComponentVote_HeaderTamplate from "../../component/header_tamplate";
import { IconDotsVertical, IconEdit } from "@tabler/icons-react";
import { RouterVote } from "@/app/lib/router_hipmi/router_vote";
import AppComponentGlobal_LayoutTamplate from "@/app_modules/_global/component_layout_tamplate";
import UIGlobal_LayoutTamplate from "@/app_modules/_global/ui/ui_layout_tamplate";
import UIGlobal_LayoutHeaderTamplate from "@/app_modules/_global/ui/ui_header_tamplate";
import UIGlobal_Drawer from "@/app_modules/_global/ui/ui_drawer";
import UIGlobal_LayoutHeaderTamplate from "@/app_modules/_global/ui/ui_header_tamplate";
import UIGlobal_LayoutTamplate from "@/app_modules/_global/ui/ui_layout_tamplate";
import { ActionIcon } from "@mantine/core";
import { IconDotsVertical, IconEdit } from "@tabler/icons-react";
import React, { useState } from "react";
export default function LayoutVote_DetailDraft({
children,