import { User as BaseUser } from './user';

export type NodeExtraFields = {
  chartColor: boolean;
  orientation: string;
  orientationIndex: number;
  currentNodeId: number;
  showEmail: boolean;
  showDepartment: boolean;
  showHireDate: boolean;
};

export type UserNode = Partial<NodeExtraFields> &
  Pick<
    User,
    | 'id'
    | 'firstName'
    | 'lastName'
    | 'email'
    | 'hiringDate'
    | 'profilePicture'
    | 'subordinatesCount'
    | 'departmentName'
  > & {
    parentId: number | string;
  };

export type User = Pick<
  BaseUser,
  | 'id'
  | 'createdAt'
  | 'deleted'
  | 'email'
  | 'firstName'
  | 'lastName'
  | 'profilePicture'
  | 'hiringDate'
  | 'isAgent'
  | 'employeeInternalId'
  | 'bossId'
> & {
  subordinatesCount: number;
  departmentName: string;
};
