2022-08-04 18:57:43 +00:00
|
|
|
import type {IAbstract} from './IAbstract'
|
|
|
|
import type {IUserSettings} from './IUserSettings'
|
|
|
|
|
2022-09-23 14:21:05 +00:00
|
|
|
export const AUTH_TYPES = {
|
|
|
|
'UNKNOWN': 0,
|
|
|
|
'USER': 1,
|
|
|
|
'LINK_SHARE': 2,
|
|
|
|
} as const
|
|
|
|
|
2022-10-16 17:36:50 +00:00
|
|
|
export type AuthType = typeof AUTH_TYPES[keyof typeof AUTH_TYPES]
|
2022-09-23 14:51:35 +00:00
|
|
|
|
2022-08-04 18:57:43 +00:00
|
|
|
export interface IUser extends IAbstract {
|
|
|
|
id: number
|
|
|
|
email: string
|
|
|
|
username: string
|
|
|
|
name: string
|
2022-09-23 14:21:05 +00:00
|
|
|
exp: number
|
2022-09-23 14:51:35 +00:00
|
|
|
type: AuthType
|
2022-08-04 18:57:43 +00:00
|
|
|
|
|
|
|
created: Date
|
|
|
|
updated: Date
|
|
|
|
settings: IUserSettings
|
2022-10-17 11:14:07 +00:00
|
|
|
|
|
|
|
isLocalUser: boolean
|
|
|
|
deletionScheduledAt: string | Date | null
|
2022-08-04 18:57:43 +00:00
|
|
|
}
|