import { ChevronDownIcon, MoveLeftIcon, MoveRightIcon, RefreshIcon, ThreadIcon, TrashIcon, } from "@lume/icons"; import * as DropdownMenu from "@radix-ui/react-dropdown-menu"; import { useQueryClient } from "@tanstack/react-query"; import { ReactNode } from "react"; import { InterestModal } from "./interestModal"; import { useColumnContext } from "./provider"; export function ColumnHeader({ id, title, queryKey, icon, }: { id: number; title: string; queryKey?: string[]; icon?: ReactNode; }) { const queryClient = useQueryClient(); const { moveColumn, removeColumn } = useColumnContext(); const refresh = async () => { if (queryKey) await queryClient.refetchQueries({ queryKey }); }; const moveLeft = async () => { moveColumn(id, "left"); }; const moveRight = async () => { moveColumn(id, "right"); }; const deleteWidget = async () => { await removeColumn(id); }; return (
{title}
{queryKey?.[0] === "foryou-9998" ? ( ) : null}
); }