// export interface UserContextModel {
// 	// getAvailablePlans: () => PlanModel[] | null;
// 	// loggedInUser: UserModel;
// 	// getDemoUserData: () => void;
// 	// isCorrectUser: boolean;
// }

export interface ReportingFor {
	id: number;
	title: string;
	max: number;
	cost: number;
}

export type PlanModel = {
	cost: number;
	discountedCost?: number;
	description: string;
	id: number;
	title: string;
	updated?: Date;
};

export type UserModel = {
	_id?: string;
	cognito_username: string;
	cognito_groups?: string;
	cognito_record_created?: Date;
	plan: PlanModel;
	reporting_for?: ReportingFor[];
	annual_cost?: number;
	username?: string; // needed only for local dev accounts
	password?: string; // needed only for local dev accounts
	email: string;
	name: string;
	phone: string;
	role: 'CEO' | 'CTO' | 'WORKER' | 'MANAGER';
	owner?: UserModel;
	permissions?: 'readOnly' | 'editor' | 'admin' | 'advisory';
	selectedCharts?: string[];
	lastLogin: string;
	hasPermanentlyDeletedCompanies?: boolean; // true if at least one company has been permanently deleted for this user
} | null;

export const demoCompanyId: { company_id: string } = {
	company_id: '10.256186555363892.7774246090232158'
};

export const accountTypes = [
	{
		id: 0,
		title: 'Single Company',
		description: 'Tool suite with reporting for a single company',
		cost: 0.0
	},
	{
		id: 1,
		title: 'Advisor',
		description: 'Tool suite with reporting for multiple companies',
		cost: 0.0
	}
];
