diff options
Diffstat (limited to 'shared/models/actors')
-rw-r--r-- | shared/models/actors/account.model.ts | 13 | ||||
-rw-r--r-- | shared/models/actors/follow.model.ts | 12 | ||||
-rw-r--r-- | shared/models/actors/index.ts | 2 |
3 files changed, 27 insertions, 0 deletions
diff --git a/shared/models/actors/account.model.ts b/shared/models/actors/account.model.ts new file mode 100644 index 000000000..d14701317 --- /dev/null +++ b/shared/models/actors/account.model.ts | |||
@@ -0,0 +1,13 @@ | |||
1 | import { Avatar } from '../avatars/avatar.model' | ||
2 | |||
3 | export interface Account { | ||
4 | id: number | ||
5 | uuid: string | ||
6 | name: string | ||
7 | host: string | ||
8 | followingCount: number | ||
9 | followersCount: number | ||
10 | createdAt: Date | ||
11 | updatedAt: Date | ||
12 | avatar: Avatar | ||
13 | } | ||
diff --git a/shared/models/actors/follow.model.ts b/shared/models/actors/follow.model.ts new file mode 100644 index 000000000..cdc3da560 --- /dev/null +++ b/shared/models/actors/follow.model.ts | |||
@@ -0,0 +1,12 @@ | |||
1 | import { Account } from './account.model' | ||
2 | |||
3 | export type FollowState = 'pending' | 'accepted' | ||
4 | |||
5 | export interface AccountFollow { | ||
6 | id: number | ||
7 | follower: Account | ||
8 | following: Account | ||
9 | state: FollowState | ||
10 | createdAt: Date | ||
11 | updatedAt: Date | ||
12 | } | ||
diff --git a/shared/models/actors/index.ts b/shared/models/actors/index.ts new file mode 100644 index 000000000..8fe437b81 --- /dev/null +++ b/shared/models/actors/index.ts | |||
@@ -0,0 +1,2 @@ | |||
1 | export * from './account.model' | ||
2 | export * from './follow.model' | ||