Skip to content

Commit

Permalink
fix: type error, lint warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
nounspaceryan committed Jul 29, 2024
1 parent 7697860 commit eb7dc6d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 20 deletions.
21 changes: 7 additions & 14 deletions src/common/components/organisms/Navigation.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
import React, {
useCallback,
useEffect,
useMemo,
useState,
useRef,
} from "react";
import React, { useCallback, useMemo, useState, useRef } from "react";
import { useRouter } from "next/router";
import { mergeClasses } from "@/common/lib/utils/mergeClasses";
import BrandHeader from "../molecules/BrandHeader";
Expand All @@ -14,13 +8,11 @@ import Modal from "../molecules/Modal";
import CreateCast from "@/fidgets/farcaster/components/CreateCast";
import Link from "next/link";
import { useFarcasterSigner } from "@/fidgets/farcaster";
import { CgLogIn, CgLogOut, CgProfile } from "react-icons/cg";
import { CgProfile } from "react-icons/cg";
import { useLoadFarcasterUser } from "@/common/data/queries/farcaster";
import { first } from "lodash";
import { IoMdRocket } from "react-icons/io";
import { Button } from "../atoms/button";
import { FaPaintbrush, FaDiscord } from "react-icons/fa6";
import { PiGlobeHemisphereEastBold } from "react-icons/pi";
import { NOUNISH_LOWFI_URL } from "@/constants/nounishLowfi";
import { UserTheme } from "@/common/lib/theme";
import { useUserTheme } from "@/common/lib/theme/UserThemeProvider";
Expand All @@ -34,12 +26,14 @@ type NavItemProps = {
label: string;
active?: boolean;
Icon: React.FC;
href?: string;
href: string;
disable?: boolean;
openInNewTab?: boolean;
onClick?: () => void;
};

type NavButtonProps = Omit<NavItemProps, "href" | "openInNewTab">;

type NavProps = {
isEditable: boolean;
enterEditMode: () => void;
Expand Down Expand Up @@ -115,17 +109,16 @@ const Navigation: React.FC<NavProps> = ({ isEditable, enterEditMode }) => {
);
};

const NavButton: React.FC<NavItemProps> = ({
const NavButton: React.FC<NavButtonProps> = ({
label,
Icon,
href,
onClick,
disable = false,
openInNewTab = false,
}) => {
return (
<li>
<button
disabled={disable}
className={mergeClasses(
"flex items-center p-2 text-gray-900 rounded-lg dark:text-white hover:bg-gray-100 dark:hover:bg-gray-700 group w-full",
)}
Expand Down
1 change: 0 additions & 1 deletion src/common/components/organisms/SearchModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import React, {
useState,
useEffect,
useCallback,
useRef,
useImperativeHandle,
} from "react";
import { Dialog, DialogContent } from "@/common/components/atoms/dialog";
Expand Down
6 changes: 1 addition & 5 deletions src/pages/explore/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,7 @@ export default function Explore({ posts }) {
<div className="flex w-full h-full">
{/* Sidebar */}
<div className="flex mx-auto transition-all duration-100 ease-out z-10">
<Navigation
isEditable={false}
enterEditMode={() => {}}
theme={homebaseConfig?.theme}
/>
<Navigation isEditable={false} enterEditMode={() => {}} />
</div>

{/* Main Content */}
Expand Down

0 comments on commit eb7dc6d

Please sign in to comment.