Skip to content

Commit

Permalink
fix: some fixes added to Header
Browse files Browse the repository at this point in the history
  • Loading branch information
yuriassuncx committed Jul 19, 2024
1 parent 35ec8f7 commit 2e3f199
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 5 deletions.
2 changes: 1 addition & 1 deletion components/header/Alert.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ function Alert({ benefit, backgroundColor, dropdown }: Props) {

<ul
tabIndex={0}
class="dropdown-content z-[1] menu p-2 shadow bg-base-100 rounded-box w-52"
class="dropdown-content z-[10000] menu p-2 shadow bg-base-100 rounded-box w-52"
>
{dropdown?.links?.map((item) => (
<li class="text-black">
Expand Down
1 change: 1 addition & 0 deletions components/header/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ function Header({
</header>

<script
type="module"
dangerouslySetInnerHTML={{ __html: useScript(handleScroll) }}
/>
</>
Expand Down
8 changes: 4 additions & 4 deletions components/header/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ import Image from "apps/website/components/Image.tsx";
import NavItem from "./NavItem.tsx";
import { navbarHeight } from "./constants.ts";
import { Logo } from "$store/components/header/Header.tsx";
import LoginElement from "deco-sites/maconequiio/islands/LoginElement.tsx";
import Icon from "deco-sites/maconequiio/components/ui/Icon.tsx";
import { useDevice } from "deco/hooks/useDevice.ts";
import { useScript } from "deco/hooks/useScript.ts";
import User from "deco-sites/maconequiio/components/user/User.tsx";

function Navbar({ items, searchbar, logo }: {
items?: SiteNavigationElement[];
Expand Down Expand Up @@ -112,10 +112,10 @@ function Navbar({ items, searchbar, logo }: {
<Searchbar searchbar={searchbar} />
</div>

<div class="flex-none flex items-center justify-end gap-6 col-span-1">
<LoginElement />
<div class="flex-none flex items-center justify-end gap-1.5 col-span-1">
<User />
<div class="flex items-center text-xs font-thin">
{platform === "vtex" && <CartButtonVTEX type="completed" />}
{platform === "vtex" && <CartButtonVTEX type="icon" />}
{platform === "vnda" && <CartButtonVDNA />}
{platform === "wake" && <CartButtonWake />}
{platform === "linx" && <CartButtonLinx />}
Expand Down
9 changes: 9 additions & 0 deletions components/user/User.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import Icon from "deco-sites/maconequiio/components/ui/Icon.tsx";

export default function User() {
return (
<a href="/account">
<Icon id="User" size={20} strokeWidth={0.4} class="text-red" />
</a>
);
}

0 comments on commit 2e3f199

Please sign in to comment.