diff options
Diffstat (limited to 'shared/models')
-rw-r--r-- | shared/models/activitypub/activity.ts | 2 | ||||
-rw-r--r-- | shared/models/activitypub/objects/video-abuse-object.ts | 2 | ||||
-rw-r--r-- | shared/models/i18n/i18n.ts | 4 | ||||
-rw-r--r-- | shared/models/server/about.model.ts | 12 | ||||
-rw-r--r-- | shared/models/server/custom-config.model.ts | 24 | ||||
-rw-r--r-- | shared/models/users/user-notification-setting.model.ts | 1 | ||||
-rw-r--r-- | shared/models/users/user-notification.model.ts | 8 | ||||
-rw-r--r-- | shared/models/users/user-update-me.model.ts | 3 | ||||
-rw-r--r-- | shared/models/users/user.model.ts | 10 |
9 files changed, 59 insertions, 7 deletions
diff --git a/shared/models/activitypub/activity.ts b/shared/models/activitypub/activity.ts index 95801190d..492b672c7 100644 --- a/shared/models/activitypub/activity.ts +++ b/shared/models/activitypub/activity.ts | |||
@@ -91,5 +91,5 @@ export interface ActivityDislike extends BaseActivity { | |||
91 | export interface ActivityFlag extends BaseActivity { | 91 | export interface ActivityFlag extends BaseActivity { |
92 | type: 'Flag', | 92 | type: 'Flag', |
93 | content: string, | 93 | content: string, |
94 | object: APObject | 94 | object: APObject | APObject[] |
95 | } | 95 | } |
diff --git a/shared/models/activitypub/objects/video-abuse-object.ts b/shared/models/activitypub/objects/video-abuse-object.ts index 40e7abd57..5f1264a76 100644 --- a/shared/models/activitypub/objects/video-abuse-object.ts +++ b/shared/models/activitypub/objects/video-abuse-object.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | export interface VideoAbuseObject { | 1 | export interface VideoAbuseObject { |
2 | type: 'Flag', | 2 | type: 'Flag', |
3 | content: string | 3 | content: string |
4 | object: string | 4 | object: string | string[] |
5 | } | 5 | } |
diff --git a/shared/models/i18n/i18n.ts b/shared/models/i18n/i18n.ts index 218fd09ba..03a5d858a 100644 --- a/shared/models/i18n/i18n.ts +++ b/shared/models/i18n/i18n.ts | |||
@@ -39,7 +39,9 @@ const I18N_LOCALE_ALIAS = { | |||
39 | 'pl': 'pl-PL', | 39 | 'pl': 'pl-PL', |
40 | 'ru': 'ru-RU', | 40 | 'ru': 'ru-RU', |
41 | 'nl': 'nl-NL', | 41 | 'nl': 'nl-NL', |
42 | 'zh': 'zh-Hans-CN' | 42 | 'zh': 'zh-Hans-CN', |
43 | 'zh-CN': 'zh-Hans-CN', | ||
44 | 'zh-TW': 'zh-Hant-TW' | ||
43 | } | 45 | } |
44 | 46 | ||
45 | export const POSSIBLE_LOCALES = Object.keys(I18N_LOCALES) | 47 | export const POSSIBLE_LOCALES = Object.keys(I18N_LOCALES) |
diff --git a/shared/models/server/about.model.ts b/shared/models/server/about.model.ts index 10dff8b8f..6d4ba63c4 100644 --- a/shared/models/server/about.model.ts +++ b/shared/models/server/about.model.ts | |||
@@ -4,5 +4,17 @@ export interface About { | |||
4 | shortDescription: string | 4 | shortDescription: string |
5 | description: string | 5 | description: string |
6 | terms: string | 6 | terms: string |
7 | |||
8 | codeOfConduct: string | ||
9 | hardwareInformation: string | ||
10 | |||
11 | creationReason: string | ||
12 | moderationInformation: string | ||
13 | administrator: string | ||
14 | maintenanceLifetime: string | ||
15 | businessModel: string | ||
16 | |||
17 | languages: string[] | ||
18 | categories: number[] | ||
7 | } | 19 | } |
8 | } | 20 | } |
diff --git a/shared/models/server/custom-config.model.ts b/shared/models/server/custom-config.model.ts index a0541f5b6..c9957f825 100644 --- a/shared/models/server/custom-config.model.ts +++ b/shared/models/server/custom-config.model.ts | |||
@@ -6,6 +6,18 @@ export interface CustomConfig { | |||
6 | shortDescription: string | 6 | shortDescription: string |
7 | description: string | 7 | description: string |
8 | terms: string | 8 | terms: string |
9 | codeOfConduct: string | ||
10 | |||
11 | creationReason: string | ||
12 | moderationInformation: string | ||
13 | administrator: string | ||
14 | maintenanceLifetime: string | ||
15 | businessModel: string | ||
16 | hardwareInformation: string | ||
17 | |||
18 | languages: string[] | ||
19 | categories: number[] | ||
20 | |||
9 | isNSFW: boolean | 21 | isNSFW: boolean |
10 | defaultClientRoute: string | 22 | defaultClientRoute: string |
11 | defaultNSFWPolicy: NSFWPolicyType | 23 | defaultNSFWPolicy: NSFWPolicyType |
@@ -99,4 +111,16 @@ export interface CustomConfig { | |||
99 | } | 111 | } |
100 | } | 112 | } |
101 | 113 | ||
114 | followings: { | ||
115 | instance: { | ||
116 | autoFollowBack: { | ||
117 | enabled: boolean | ||
118 | } | ||
119 | |||
120 | autoFollowIndex: { | ||
121 | enabled: boolean | ||
122 | indexUrl: string | ||
123 | } | ||
124 | } | ||
125 | } | ||
102 | } | 126 | } |
diff --git a/shared/models/users/user-notification-setting.model.ts b/shared/models/users/user-notification-setting.model.ts index e2a882b69..451f40d58 100644 --- a/shared/models/users/user-notification-setting.model.ts +++ b/shared/models/users/user-notification-setting.model.ts | |||
@@ -16,4 +16,5 @@ export interface UserNotificationSetting { | |||
16 | newFollow: UserNotificationSettingValue | 16 | newFollow: UserNotificationSettingValue |
17 | commentMention: UserNotificationSettingValue | 17 | commentMention: UserNotificationSettingValue |
18 | newInstanceFollower: UserNotificationSettingValue | 18 | newInstanceFollower: UserNotificationSettingValue |
19 | autoInstanceFollowing: UserNotificationSettingValue | ||
19 | } | 20 | } |
diff --git a/shared/models/users/user-notification.model.ts b/shared/models/users/user-notification.model.ts index fafc2b7d7..e9be1ca7f 100644 --- a/shared/models/users/user-notification.model.ts +++ b/shared/models/users/user-notification.model.ts | |||
@@ -19,7 +19,9 @@ export enum UserNotificationType { | |||
19 | 19 | ||
20 | VIDEO_AUTO_BLACKLIST_FOR_MODERATORS = 12, | 20 | VIDEO_AUTO_BLACKLIST_FOR_MODERATORS = 12, |
21 | 21 | ||
22 | NEW_INSTANCE_FOLLOWER = 13 | 22 | NEW_INSTANCE_FOLLOWER = 13, |
23 | |||
24 | AUTO_INSTANCE_FOLLOWING = 14 | ||
23 | } | 25 | } |
24 | 26 | ||
25 | export interface VideoInfo { | 27 | export interface VideoInfo { |
@@ -78,10 +80,12 @@ export interface UserNotification { | |||
78 | id: number | 80 | id: number |
79 | follower: ActorInfo | 81 | follower: ActorInfo |
80 | state: FollowState | 82 | state: FollowState |
83 | |||
81 | following: { | 84 | following: { |
82 | type: 'account' | 'channel' | 85 | type: 'account' | 'channel' | 'instance' |
83 | name: string | 86 | name: string |
84 | displayName: string | 87 | displayName: string |
88 | host: string | ||
85 | } | 89 | } |
86 | } | 90 | } |
87 | 91 | ||
diff --git a/shared/models/users/user-update-me.model.ts b/shared/models/users/user-update-me.model.ts index b6c0002e5..99b9a65bd 100644 --- a/shared/models/users/user-update-me.model.ts +++ b/shared/models/users/user-update-me.model.ts | |||
@@ -15,4 +15,7 @@ export interface UserUpdateMe { | |||
15 | password?: string | 15 | password?: string |
16 | 16 | ||
17 | theme?: string | 17 | theme?: string |
18 | |||
19 | noInstanceConfigWarningModal?: boolean | ||
20 | noWelcomeModal?: boolean | ||
18 | } | 21 | } |
diff --git a/shared/models/users/user.model.ts b/shared/models/users/user.model.ts index de9825e1f..f67d262b0 100644 --- a/shared/models/users/user.model.ts +++ b/shared/models/users/user.model.ts | |||
@@ -10,6 +10,7 @@ export interface User { | |||
10 | username: string | 10 | username: string |
11 | email: string | 11 | email: string |
12 | pendingEmail: string | null | 12 | pendingEmail: string | null |
13 | |||
13 | emailVerified: boolean | 14 | emailVerified: boolean |
14 | nsfwPolicy: NSFWPolicyType | 15 | nsfwPolicy: NSFWPolicyType |
15 | 16 | ||
@@ -18,13 +19,15 @@ export interface User { | |||
18 | autoPlayVideo: boolean | 19 | autoPlayVideo: boolean |
19 | webTorrentEnabled: boolean | 20 | webTorrentEnabled: boolean |
20 | videosHistoryEnabled: boolean | 21 | videosHistoryEnabled: boolean |
22 | videoLanguages: string[] | ||
21 | 23 | ||
22 | role: UserRole | 24 | role: UserRole |
23 | roleLabel: string | 25 | roleLabel: string |
24 | 26 | ||
25 | videoQuota: number | 27 | videoQuota: number |
26 | videoQuotaDaily: number | 28 | videoQuotaDaily: number |
27 | createdAt: Date | 29 | videoQuotaUsed?: number |
30 | videoQuotaUsedDaily?: number | ||
28 | 31 | ||
29 | theme: string | 32 | theme: string |
30 | 33 | ||
@@ -35,5 +38,8 @@ export interface User { | |||
35 | blocked: boolean | 38 | blocked: boolean |
36 | blockedReason?: string | 39 | blockedReason?: string |
37 | 40 | ||
38 | videoQuotaUsed?: number | 41 | noInstanceConfigWarningModal: boolean |
42 | noWelcomeModal: boolean | ||
43 | |||
44 | createdAt: Date | ||
39 | } | 45 | } |