Migrate components to typescript
This commit is contained in:
7
src/core/domain/users/index.ts
Normal file
7
src/core/domain/users/index.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
import {User} from './user'
|
||||
import {Profile} from './profile'
|
||||
|
||||
export {
|
||||
User,
|
||||
Profile
|
||||
}
|
||||
45
src/core/domain/users/profile.ts
Normal file
45
src/core/domain/users/profile.ts
Normal file
@@ -0,0 +1,45 @@
|
||||
import { BaseDomain } from 'core/domain/common'
|
||||
|
||||
export class Profile extends BaseDomain {
|
||||
|
||||
/**
|
||||
* User avatar address
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof Profile
|
||||
*/
|
||||
public avatar: string
|
||||
|
||||
/**
|
||||
* User email
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof Profile
|
||||
*/
|
||||
public email?: string | null
|
||||
|
||||
/**
|
||||
* User full name
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof Profile
|
||||
*/
|
||||
public fullName: string
|
||||
|
||||
/**
|
||||
* The banner address of user profile
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof Profile
|
||||
*/
|
||||
public banner: string
|
||||
|
||||
/**
|
||||
* User tag line
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof Profile
|
||||
*/
|
||||
public tagLine: string
|
||||
|
||||
}
|
||||
53
src/core/domain/users/user.ts
Normal file
53
src/core/domain/users/user.ts
Normal file
@@ -0,0 +1,53 @@
|
||||
import { BaseDomain } from 'core/domain/common'
|
||||
|
||||
export class User extends BaseDomain {
|
||||
|
||||
/**
|
||||
* Full name of user
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof User
|
||||
*/
|
||||
public fullName: string
|
||||
|
||||
/**
|
||||
* User avatar address
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof User
|
||||
*/
|
||||
public avatar: string
|
||||
|
||||
/**
|
||||
* Email of the user
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof User
|
||||
*/
|
||||
public email?: string | null
|
||||
|
||||
/**
|
||||
* Password of the user
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof User
|
||||
*/
|
||||
public password?: string | null
|
||||
|
||||
/**
|
||||
* User identifier
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof User
|
||||
*/
|
||||
public userId?: string | null
|
||||
|
||||
/**
|
||||
* User creation date
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof User
|
||||
*/
|
||||
public creationDate: number
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user