"use client";

import { usePathname, useRouter } from "next/navigation";

export function EditDashboardButton() {
  const router = useRouter();
  const pathname = usePathname();

  return (
    <button type="button" onClick={() => router.push(`${pathname}?edit=1`)} className="btn btn-sm">
      Edit dashboard
    </button>
  );
}
