aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared
diff options
context:
space:
mode:
authorRigel Kent <sendmemail@rigelk.eu>2021-01-26 01:53:13 +0100
committerChocobozzz <chocobozzz@cpy.re>2021-01-28 15:55:34 +0100
commit3da68f0a781ebd893521e2e6fa200280c92ae815 (patch)
tree11bddf841118703c725a96851318603407fd581d /shared
parent28eeb811c40325a28208231324f66f4032e5cf67 (diff)
downloadPeerTube-3da68f0a781ebd893521e2e6fa200280c92ae815.tar.gz
PeerTube-3da68f0a781ebd893521e2e6fa200280c92ae815.tar.zst
PeerTube-3da68f0a781ebd893521e2e6fa200280c92ae815.zip
add default trending page choice, revert comments count for hot strategy
Diffstat (limited to 'shared')
-rw-r--r--shared/extra-utils/server/config.ts10
-rw-r--r--shared/models/server/custom-config.model.ts10
-rw-r--r--shared/models/server/server-config.model.ts8
3 files changed, 25 insertions, 3 deletions
diff --git a/shared/extra-utils/server/config.ts b/shared/extra-utils/server/config.ts
index f7c488c0b..5152ec693 100644
--- a/shared/extra-utils/server/config.ts
+++ b/shared/extra-utils/server/config.ts
@@ -65,9 +65,17 @@ function updateCustomSubConfig (url: string, token: string, newConfig: DeepParti
65 languages: [ 'en', 'es' ], 65 languages: [ 'en', 'es' ],
66 categories: [ 1, 2 ], 66 categories: [ 1, 2 ],
67 67
68 defaultClientRoute: '/videos/recently-added',
69 isNSFW: true, 68 isNSFW: true,
70 defaultNSFWPolicy: 'blur', 69 defaultNSFWPolicy: 'blur',
70
71 defaultClientRoute: '/videos/recently-added',
72 defaultTrendingRoute: '/videos/trending',
73 pages: {
74 hot: {
75 enabled: true
76 }
77 },
78
71 customizations: { 79 customizations: {
72 javascript: 'alert("coucou")', 80 javascript: 'alert("coucou")',
73 css: 'body { background-color: red; }' 81 css: 'body { background-color: red; }'
diff --git a/shared/models/server/custom-config.model.ts b/shared/models/server/custom-config.model.ts
index 9a6a24923..fcc29e5d7 100644
--- a/shared/models/server/custom-config.model.ts
+++ b/shared/models/server/custom-config.model.ts
@@ -30,8 +30,16 @@ export interface CustomConfig {
30 categories: number[] 30 categories: number[]
31 31
32 isNSFW: boolean 32 isNSFW: boolean
33 defaultClientRoute: string
34 defaultNSFWPolicy: NSFWPolicyType 33 defaultNSFWPolicy: NSFWPolicyType
34
35 defaultClientRoute: string
36 defaultTrendingRoute: string
37 pages: {
38 hot: {
39 enabled: boolean
40 }
41 }
42
35 customizations: { 43 customizations: {
36 javascript?: string 44 javascript?: string
37 css?: string 45 css?: string
diff --git a/shared/models/server/server-config.model.ts b/shared/models/server/server-config.model.ts
index 2dcf98f4f..a2d93ce73 100644
--- a/shared/models/server/server-config.model.ts
+++ b/shared/models/server/server-config.model.ts
@@ -36,9 +36,15 @@ export interface ServerConfig {
36 instance: { 36 instance: {
37 name: string 37 name: string
38 shortDescription: string 38 shortDescription: string
39 defaultClientRoute: string
40 isNSFW: boolean 39 isNSFW: boolean
41 defaultNSFWPolicy: NSFWPolicyType 40 defaultNSFWPolicy: NSFWPolicyType
41 defaultClientRoute: string
42 defaultTrendingRoute: string
43 pages: {
44 hot: {
45 enabled: boolean
46 }
47 }
42 customizations: { 48 customizations: {
43 javascript: string 49 javascript: string
44 css: string 50 css: string