import { SessionUser } from "@/app/api/auth/[...nextauth]/models/types";
import { UserPermissions } from "@/models/permissions";
import { Session } from "next-auth";

type Status = "authenticated" | "loading" | "unauthenticated";

type SessionData = Session & { user: SessionUser };

type AppSession = {
  data: SessionData;
  status: Status;
  update: UpdateSession;
};

type ActiveSession = {
  user: SessionUser;
  permissions: UserPermissions;
};

type SideNavLink = {
  id: number;
  link: string;
  icon: IconDefinition;
  tooltip: string;
};

type SideNavLinksProps = {
  dict: Dictionary;
  canViewUserList?: boolean;
};

type CardInfo = {
  title: string;
  icon: IconDefinition;
  color: string;
};

type CardsInfoProps = {
  dict: Dictionary;
};

type SummaryCardProps = {
  title: string;
  value: string | number;
  icon: IconDefinition;
  color: string;
  isPending: boolean;
};

type StatusCode = {
  title: string;
  message: string;
};

type StatusCodesProps = { code: string; dict: Dictionary };
