]>
Commit | Line | Data |
---|---|---|
5f46d28c C |
1 | <ng-container [formGroup]="form"> |
2 | <div class="form-row mt-5"> <!-- appearance grid --> | |
3 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
4 | <div i18n class="inner-form-title">APPEARANCE</div> | |
5 | <div i18n class="inner-form-description"> | |
6 | Use <a routerLink="/admin/plugins">plugins & themes</a> for more involved changes, or <a routerLink="/admin/config/edit-custom" fragment="advanced-configuration">add slight customizations</a>. | |
7 | </div> | |
8 | </div> | |
9 | ||
10 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
11 | ||
12 | <ng-container formGroupName="theme"> | |
13 | <div class="form-group"> | |
14 | <label i18n for="themeDefault">Theme</label> | |
15 | ||
16 | <div class="peertube-select-container"> | |
17 | <select formControlName="default" id="themeDefault" class="form-control"> | |
18 | <option i18n value="default">default</option> | |
19 | ||
20 | <option *ngFor="let theme of getAvailableThemes()" [value]="theme">{{ theme }}</option> | |
21 | </select> | |
22 | </div> | |
23 | </div> | |
24 | </ng-container> | |
25 | ||
26 | <div class="form-group" formGroupName="instance"> | |
27 | <label i18n for="instanceDefaultClientRoute">Landing page</label> | |
70e33515 | 28 | |
2539932e C |
29 | <my-select-custom-value |
30 | id="instanceDefaultClientRoute" | |
31 | [items]="defaultLandingPageOptions" | |
32 | formControlName="defaultClientRoute" | |
33 | inputType="text" | |
34 | [clearable]="false" | |
35 | ></my-select-custom-value> | |
70e33515 | 36 | |
5f46d28c C |
37 | <div *ngIf="formErrors.instance.defaultClientRoute" class="form-error">{{ formErrors.instance.defaultClientRoute }}</div> |
38 | </div> | |
39 | ||
40 | <div class="form-group" formGroupName="trending"> | |
41 | <ng-container formGroupName="videos"> | |
42 | <ng-container formGroupName="algorithms"> | |
43 | <label i18n for="trendingVideosAlgorithmsDefault">Default trending page</label> | |
70e33515 | 44 | |
5f46d28c C |
45 | <div class="peertube-select-container"> |
46 | <select id="trendingVideosAlgorithmsDefault" formControlName="default" class="form-control"> | |
47 | <option i18n value="best">Best videos</option> | |
48 | <option i18n value="hot">Hot videos</option> | |
49 | <option i18n value="most-viewed">Most viewed videos</option> | |
50 | <option i18n value="most-liked">Most liked videos</option> | |
51 | </select> | |
52 | </div> | |
70e33515 | 53 | |
5f46d28c C |
54 | <div *ngIf="formErrors.trending.videos.algorithms.default" class="form-error">{{ formErrors.trending.videos.algorithms.default }}</div> |
55 | </ng-container> | |
56 | </ng-container> | |
57 | </div> | |
58 | ||
59 | </div> | |
60 | </div> | |
61 | ||
62 | <div class="form-row mt-4"> <!-- broadcast grid --> | |
63 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
64 | <div i18n class="inner-form-title">BROADCAST MESSAGE</div> | |
65 | <div i18n class="inner-for-description"> | |
66 | Display a message on your instance | |
67 | </div> | |
68 | </div> | |
69 | ||
70 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
71 | ||
72 | <ng-container formGroupName="broadcastMessage"> | |
73 | ||
74 | <div class="form-group"> | |
75 | <my-peertube-checkbox | |
76 | inputName="broadcastMessageEnabled" formControlName="enabled" | |
77 | i18n-labelText labelText="Enable broadcast message" | |
78 | ></my-peertube-checkbox> | |
79 | </div> | |
80 | ||
81 | <div class="form-group"> | |
82 | <my-peertube-checkbox | |
83 | inputName="broadcastMessageDismissable" formControlName="dismissable" | |
84 | i18n-labelText labelText="Allow users to dismiss the broadcast message " | |
85 | ></my-peertube-checkbox> | |
86 | </div> | |
87 | ||
88 | <div class="form-group"> | |
89 | <label i18n for="broadcastMessageLevel">Broadcast message level</label> | |
70e33515 | 90 | |
5f46d28c C |
91 | <div class="peertube-select-container"> |
92 | <select id="broadcastMessageLevel" formControlName="level" class="form-control"> | |
93 | <option value="info">info</option> | |
2c2631e4 | 94 | <option value="warning">warning</option> |
5f46d28c C |
95 | <option value="error">error</option> |
96 | </select> | |
97 | </div> | |
70e33515 | 98 | |
5f46d28c C |
99 | <div *ngIf="formErrors.broadcastMessage.level" class="form-error">{{ formErrors.broadcastMessage.level }}</div> |
100 | </div> | |
101 | ||
102 | <div class="form-group"> | |
103 | <label i18n for="broadcastMessageMessage">Message</label><my-help helpType="markdownText"></my-help> | |
70e33515 | 104 | |
5f46d28c C |
105 | <my-markdown-textarea |
106 | name="broadcastMessageMessage" formControlName="message" textareaMaxWidth="500px" | |
107 | [classes]="{ 'input-error': formErrors['broadcastMessage.message'] }" | |
108 | ></my-markdown-textarea> | |
70e33515 | 109 | |
5f46d28c C |
110 | <div *ngIf="formErrors.broadcastMessage.message" class="form-error">{{ formErrors.broadcastMessage.message }}</div> |
111 | </div> | |
112 | ||
113 | </ng-container> | |
114 | ||
115 | </div> | |
116 | </div> | |
117 | ||
118 | <div class="form-row mt-4"> <!-- new users grid --> | |
119 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
120 | <div i18n class="inner-form-title">NEW USERS</div> | |
121 | <div i18n class="inner-for-description"> | |
122 | Manage <a routerLink="/admin/users">users</a> to set their quota individually. | |
123 | </div> | |
124 | </div> | |
125 | ||
126 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
127 | ||
128 | <ng-container formGroupName="signup"> | |
129 | <div class="form-group"> | |
130 | <my-peertube-checkbox | |
131 | inputName="signupEnabled" formControlName="enabled" | |
132 | i18n-labelText labelText="Enable Signup" | |
133 | > | |
134 | <ng-container ngProjectAs="description"> | |
135 | <span i18n>⚠️ This functionality requires a lot of attention and extra moderation.</span> | |
136 | ||
137 | <div class="alert alert-info alert-signup" *ngIf="signupAlertMessage">{{ signupAlertMessage }}</div> | |
138 | </ng-container> | |
139 | ||
140 | <ng-container ngProjectAs="extra"> | |
70e33515 | 141 | <my-peertube-checkbox [ngClass]="getDisabledSignupClass()" |
5f46d28c C |
142 | inputName="signupRequiresEmailVerification" formControlName="requiresEmailVerification" |
143 | i18n-labelText labelText="Signup requires email verification" | |
144 | ></my-peertube-checkbox> | |
145 | ||
70e33515 | 146 | <div [ngClass]="getDisabledSignupClass()" class="mt-3"> |
5f46d28c | 147 | <label i18n for="signupLimit">Signup limit</label> |
70e33515 | 148 | |
5f46d28c C |
149 | <div class="number-with-unit"> |
150 | <input | |
151 | type="number" min="-1" id="signupLimit" class="form-control" | |
152 | formControlName="limit" [ngClass]="{ 'input-error': formErrors['signup.limit'] }" | |
153 | > | |
154 | <span i18n>{form.value['signup']['limit'], plural, =1 {user} other {users}}</span> | |
155 | </div> | |
70e33515 | 156 | |
5f46d28c | 157 | <div *ngIf="formErrors.signup.limit" class="form-error">{{ formErrors.signup.limit }}</div> |
70e33515 C |
158 | |
159 | <small i18n *ngIf="hasUnlimitedSignup()" class="text-muted">Signup won't be limited to a fixed number of users.</small> | |
5f46d28c | 160 | </div> |
1f256e7d P |
161 | |
162 | <div [ngClass]="getDisabledSignupClass()" class="mt-3"> | |
163 | <label i18n for="signupMinimumAge">Minimum required age to create an account</label> | |
164 | ||
165 | <div class="number-with-unit"> | |
166 | <input | |
167 | type="number" min="1" id="signupMinimumAge" class="form-control" | |
168 | formControlName="minimumAge" [ngClass]="{ 'input-error': formErrors['signup.minimumAge'] }" | |
169 | > | |
170 | <span i18n>{form.value['signup']['minimumAge'], plural, =1 {year old} other {years old}}</span> | |
171 | </div> | |
172 | ||
173 | <div *ngIf="formErrors.signup.minimumAge" class="form-error">{{ formErrors.signup.minimumAge }}</div> | |
174 | </div> | |
5f46d28c C |
175 | </ng-container> |
176 | </my-peertube-checkbox> | |
177 | </div> | |
178 | </ng-container> | |
179 | ||
180 | <ng-container formGroupName="user"> | |
181 | <div class="form-group"> | |
182 | <label i18n for="userVideoQuota">Default video quota per user</label> | |
183 | ||
184 | <my-select-custom-value | |
185 | id="userVideoQuota" | |
186 | [items]="getVideoQuotaOptions()" | |
187 | formControlName="videoQuota" | |
188 | i18n-inputSuffix inputSuffix="bytes" inputType="number" | |
189 | [clearable]="false" | |
190 | ></my-select-custom-value> | |
191 | ||
192 | <div *ngIf="formErrors.user.videoQuota" class="form-error">{{ formErrors.user.videoQuota }}</div> | |
193 | </div> | |
194 | ||
195 | <div class="form-group"> | |
196 | <label i18n for="userVideoQuotaDaily">Default daily upload limit per user</label> | |
197 | ||
198 | <my-select-custom-value | |
199 | id="userVideoQuotaDaily" | |
200 | [items]="getVideoQuotaDailyOptions()" | |
201 | formControlName="videoQuotaDaily" | |
202 | i18n-inputSuffix inputSuffix="bytes" inputType="number" | |
203 | [clearable]="false" | |
204 | ></my-select-custom-value> | |
205 | ||
206 | <div *ngIf="formErrors.user.videoQuotaDaily" class="form-error">{{ formErrors.user.videoQuotaDaily }}</div> | |
207 | </div> | |
208 | </ng-container> | |
209 | ||
210 | </div> | |
211 | </div> | |
212 | ||
213 | <div class="form-row mt-4"> <!-- videos grid --> | |
214 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
215 | <div i18n class="inner-form-title">VIDEOS</div> | |
216 | </div> | |
217 | ||
218 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
219 | ||
220 | <ng-container formGroupName="import"> | |
221 | ||
222 | <ng-container formGroupName="videos"> | |
223 | ||
224 | <div class="form-group mt-4"> | |
225 | <label i18n for="importConcurrency">Import jobs concurrency</label> | |
70e33515 | 226 | <span i18n class="text-muted ml-1">allows to import multiple videos in parallel. ⚠️ Requires a PeerTube restart.</span> |
5f46d28c C |
227 | |
228 | <div class="number-with-unit"> | |
229 | <input type="number" name="importConcurrency" formControlName="concurrency" /> | |
230 | <span i18n>jobs in parallel</span> | |
231 | </div> | |
232 | ||
233 | <div *ngIf="formErrors.import.concurrency" class="form-error">{{ formErrors.import.concurrency }}</div> | |
234 | </div> | |
235 | ||
236 | <div class="form-group" formGroupName="http"> | |
237 | <my-peertube-checkbox | |
238 | inputName="importVideosHttpEnabled" formControlName="enabled" | |
239 | i18n-labelText labelText="Allow import with HTTP URL (e.g. YouTube)" | |
240 | ></my-peertube-checkbox> | |
241 | </div> | |
242 | ||
243 | <div class="form-group" formGroupName="torrent"> | |
244 | <my-peertube-checkbox | |
245 | inputName="importVideosTorrentEnabled" formControlName="enabled" | |
246 | i18n-labelText labelText="Allow import with a torrent file or a magnet URI" | |
247 | ></my-peertube-checkbox> | |
248 | </div> | |
249 | ||
250 | </ng-container> | |
251 | </ng-container> | |
252 | ||
253 | <ng-container formGroupName="autoBlacklist"> | |
254 | <ng-container formGroupName="videos"> | |
255 | <ng-container formGroupName="ofUsers"> | |
256 | ||
257 | <div class="form-group"> | |
258 | <my-peertube-checkbox | |
259 | inputName="autoBlacklistVideosOfUsersEnabled" formControlName="enabled" | |
260 | i18n-labelText labelText="Block new videos automatically" | |
261 | > | |
262 | <ng-container ngProjectAs="description"> | |
263 | <span i18n>Unless a user is marked as trusted, their videos will stay private until a moderator reviews them.</span> | |
264 | </ng-container> | |
265 | </my-peertube-checkbox> | |
266 | </div> | |
267 | ||
268 | </ng-container> | |
269 | </ng-container> | |
270 | </ng-container> | |
271 | ||
272 | </div> | |
273 | </div> | |
274 | ||
754b6f5f FC |
275 | <div class="form-row mt-4"> <!-- video channels grid --> |
276 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
277 | <div i18n class="inner-form-title">VIDEO CHANNELS</div> | |
278 | </div> | |
279 | ||
280 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
281 | <div class="form-group" formGroupName="videoChannels"> | |
282 | <label i18n for="videoChannelsMaxPerUser">Max video channels per user</label> | |
283 | ||
284 | <div class="number-with-unit"> | |
285 | <input | |
286 | type="number" min="1" id="videoChannelsMaxPerUser" class="form-control" | |
287 | formControlName="maxPerUser" [ngClass]="{ 'input-error': formErrors['videoChannels.maxPerUser'] }" | |
288 | > | |
289 | <span i18n>{form.value['videoChannels']['maxPerUser'], plural, =1 {channel} other {channels}}</span> | |
290 | </div> | |
291 | ||
292 | <div *ngIf="formErrors.videoChannels.maxPerUser" class="form-error">{{ formErrors.videoChannels.maxPerUser }}</div> | |
293 | </div> | |
294 | </div> | |
295 | </div> | |
296 | ||
5f46d28c C |
297 | <div class="form-row mt-4"> <!-- search grid --> |
298 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
299 | <div i18n class="inner-form-title">SEARCH</div> | |
300 | </div> | |
301 | ||
302 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
303 | ||
304 | <ng-container formGroupName="search"> | |
305 | <ng-container formGroupName="remoteUri"> | |
306 | ||
307 | <div class="form-group"> | |
308 | <my-peertube-checkbox | |
309 | inputName="searchRemoteUriUsers" formControlName="users" | |
310 | i18n-labelText labelText="Allow users to do remote URI/handle search" | |
311 | > | |
312 | <ng-container ngProjectAs="description"> | |
313 | <span i18n>Allow <strong>your users</strong> to look up remote videos/actors that may not be federated with your instance</span> | |
314 | </ng-container> | |
315 | </my-peertube-checkbox> | |
316 | </div> | |
317 | ||
318 | <div class="form-group"> | |
319 | <my-peertube-checkbox | |
320 | inputName="searchRemoteUriAnonymous" formControlName="anonymous" | |
321 | i18n-labelText labelText="Allow anonymous to do remote URI/handle search" | |
322 | > | |
323 | <ng-container ngProjectAs="description"> | |
324 | <span i18n>Allow <strong>anonymous users</strong> to look up remote videos/actors that may not be federated with your instance</span> | |
325 | </ng-container> | |
326 | </my-peertube-checkbox> | |
327 | </div> | |
328 | ||
329 | </ng-container> | |
330 | ||
331 | <ng-container formGroupName="searchIndex"> | |
332 | <div class="form-group"> | |
333 | <my-peertube-checkbox | |
334 | inputName="searchIndexEnabled" formControlName="enabled" | |
335 | i18n-labelText labelText="Enable global search" | |
336 | > | |
337 | <ng-container ngProjectAs="description"> | |
338 | <p i18n>⚠️ This functionality depends heavily on the moderation of instances followed by the search index you select.</p> | |
339 | ||
340 | <span i18n> | |
341 | You should only use moderated search indexes in production, or <a href="https://framagit.org/framasoft/peertube/search-index">host your own</a>. | |
342 | </span> | |
343 | </ng-container> | |
344 | ||
345 | <ng-container ngProjectAs="extra"> | |
70e33515 | 346 | <div [ngClass]="getDisabledSearchIndexClass()"> |
5f46d28c | 347 | <label i18n for="searchIndexUrl">Search index URL</label> |
70e33515 | 348 | |
5f46d28c C |
349 | <input |
350 | type="text" id="searchIndexUrl" class="form-control" | |
351 | formControlName="url" [ngClass]="{ 'input-error': formErrors['search.searchIndex.url'] }" | |
352 | > | |
70e33515 | 353 | |
5f46d28c C |
354 | <div *ngIf="formErrors.search.searchIndex.url" class="form-error">{{ formErrors.search.searchIndex.url }}</div> |
355 | </div> | |
356 | ||
357 | <div class="mt-3"> | |
70e33515 | 358 | <my-peertube-checkbox [ngClass]="getDisabledSearchIndexClass()" |
5f46d28c C |
359 | inputName="searchIndexDisableLocalSearch" formControlName="disableLocalSearch" |
360 | i18n-labelText labelText="Disable local search in search bar" | |
361 | ></my-peertube-checkbox> | |
362 | </div> | |
363 | ||
364 | <div class="mt-3"> | |
70e33515 | 365 | <my-peertube-checkbox [ngClass]="getDisabledSearchIndexClass()" |
5f46d28c C |
366 | inputName="searchIndexIsDefaultSearch" formControlName="isDefaultSearch" |
367 | i18n-labelText labelText="Search bar uses the global search index by default" | |
368 | > | |
369 | <ng-container ngProjectAs="description"> | |
370 | <span i18n>Otherwise the local search stays used by default</span> | |
371 | </ng-container> | |
372 | </my-peertube-checkbox> | |
373 | </div> | |
374 | ||
375 | </ng-container> | |
376 | </my-peertube-checkbox> | |
377 | </div> | |
378 | ||
379 | </ng-container> | |
380 | ||
381 | </ng-container> | |
382 | ||
383 | </div> | |
384 | </div> | |
385 | ||
386 | <div class="form-row mt-4"> <!-- federation grid --> | |
387 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
388 | <div i18n class="inner-form-title">FEDERATION</div> | |
389 | <div i18n class="inner-form-description"> | |
390 | Manage <a routerLink="/admin/follows">relations</a> with other instances. | |
391 | </div> | |
392 | </div> | |
393 | ||
394 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
395 | ||
396 | <ng-container formGroupName="followers"> | |
397 | <ng-container formGroupName="instance"> | |
398 | ||
399 | <div class="form-group"> | |
400 | <my-peertube-checkbox | |
401 | inputName="followersInstanceEnabled" formControlName="enabled" | |
402 | i18n-labelText labelText="Other instances can follow yours" | |
403 | ></my-peertube-checkbox> | |
404 | </div> | |
405 | ||
406 | <div class="form-group"> | |
407 | <my-peertube-checkbox | |
408 | inputName="followersInstanceManualApproval" formControlName="manualApproval" | |
409 | i18n-labelText labelText="Manually approve new instance followers" | |
410 | ></my-peertube-checkbox> | |
411 | </div> | |
412 | </ng-container> | |
413 | </ng-container> | |
414 | ||
415 | <ng-container formGroupName="followings"> | |
416 | <ng-container formGroupName="instance"> | |
417 | ||
418 | <ng-container formGroupName="autoFollowBack"> | |
419 | <div class="form-group"> | |
420 | <my-peertube-checkbox | |
421 | inputName="followingsInstanceAutoFollowBackEnabled" formControlName="enabled" | |
422 | i18n-labelText labelText="Automatically follow back instances" | |
423 | > | |
424 | <ng-container ngProjectAs="description"> | |
425 | <span i18n>⚠️ This functionality requires a lot of attention and extra moderation.</span> | |
426 | </ng-container> | |
427 | </my-peertube-checkbox> | |
428 | </div> | |
429 | </ng-container> | |
430 | ||
431 | <ng-container formGroupName="autoFollowIndex"> | |
432 | <div class="form-group"> | |
433 | <my-peertube-checkbox | |
434 | inputName="followingsInstanceAutoFollowIndexEnabled" formControlName="enabled" | |
435 | i18n-labelText labelText="Automatically follow instances of a public index" | |
436 | > | |
437 | <ng-container ngProjectAs="description"> | |
438 | <p i18n>⚠️ This functionality requires a lot of attention and extra moderation.</p> | |
439 | ||
440 | <span i18n> | |
4beda9e1 | 441 | See <a href="https://docs.joinpeertube.org/admin-following-instances?id=automatically-follow-other-instances" rel="noopener noreferrer" target="_blank">the documentation</a> for more information about the expected URL |
5f46d28c C |
442 | </span> |
443 | </ng-container> | |
444 | ||
445 | <ng-container ngProjectAs="extra"> | |
446 | <div [ngClass]="{ 'disabled-checkbox-extra': !isAutoFollowIndexEnabled() }"> | |
447 | <label i18n for="followingsInstanceAutoFollowIndexUrl">Index URL</label> | |
448 | <input | |
449 | type="text" id="followingsInstanceAutoFollowIndexUrl" class="form-control" | |
450 | formControlName="indexUrl" [ngClass]="{ 'input-error': formErrors['followings.instance.autoFollowIndex.indexUrl'] }" | |
451 | > | |
452 | <div *ngIf="formErrors.followings.instance.autoFollowIndex.indexUrl" class="form-error">{{ formErrors.followings.instance.autoFollowIndex.indexUrl }}</div> | |
453 | </div> | |
454 | </ng-container> | |
455 | </my-peertube-checkbox> | |
456 | </div> | |
457 | ||
458 | </ng-container> | |
459 | </ng-container> | |
460 | </ng-container> | |
461 | ||
462 | </div> | |
463 | </div> | |
464 | ||
465 | <div class="form-row mt-4"> <!-- administrators grid --> | |
466 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
467 | <div i18n class="inner-form-title">ADMINISTRATORS</div> | |
468 | </div> | |
469 | ||
470 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
471 | ||
472 | <div class="form-group" formGroupName="admin"> | |
473 | <label i18n for="adminEmail">Admin email</label> | |
70e33515 | 474 | |
5f46d28c C |
475 | <input |
476 | type="text" id="adminEmail" class="form-control" | |
477 | formControlName="email" [ngClass]="{ 'input-error': formErrors['admin.email'] }" | |
478 | > | |
70e33515 | 479 | |
5f46d28c C |
480 | <div *ngIf="formErrors.admin.email" class="form-error">{{ formErrors.admin.email }}</div> |
481 | </div> | |
482 | ||
483 | <div class="form-group" formGroupName="contactForm"> | |
484 | <my-peertube-checkbox | |
485 | inputName="enableContactForm" formControlName="enabled" | |
486 | i18n-labelText labelText="Enable contact form" | |
487 | ></my-peertube-checkbox> | |
488 | </div> | |
489 | ||
490 | </div> | |
491 | </div> | |
492 | ||
493 | <div class="form-row mt-4"> <!-- Twitter grid --> | |
494 | <div class="form-group col-12 col-lg-4 col-xl-3"> | |
495 | <div i18n class="inner-form-title">TWITTER</div> | |
496 | <div i18n class="inner-form-description"> | |
497 | Provide the Twitter account representing your instance to improve link previews. | |
498 | If you don't have a Twitter account, just leave the default value. | |
499 | </div> | |
500 | </div> | |
501 | ||
502 | <div class="form-group form-group-right col-12 col-lg-8 col-xl-9"> | |
503 | ||
504 | <ng-container formGroupName="services"> | |
505 | <ng-container formGroupName="twitter"> | |
506 | ||
507 | <div class="form-group"> | |
1f256e7d | 508 | <label for="servicesTwitterUsername" i18n>Your Twitter username</label> |
5f46d28c C |
509 | |
510 | <input | |
511 | type="text" id="servicesTwitterUsername" class="form-control" | |
512 | formControlName="username" [ngClass]="{ 'input-error': formErrors['services.twitter.username'] }" | |
513 | > | |
70e33515 | 514 | |
5f46d28c C |
515 | <div *ngIf="formErrors.services.twitter.username" class="form-error">{{ formErrors.services.twitter.username }}</div> |
516 | </div> | |
517 | ||
518 | <div class="form-group"> | |
519 | <my-peertube-checkbox inputName="servicesTwitterWhitelisted" formControlName="whitelisted"> | |
520 | <ng-template ptTemplate="label"> | |
521 | <ng-container i18n>Instance allowed by Twitter</ng-container> | |
522 | </ng-template> | |
523 | ||
524 | <ng-template ptTemplate="help"> | |
525 | <ng-container i18n> | |
526 | If your instance is explicitly allowed by Twitter, a video player will be embedded in the Twitter feed on PeerTube video share.<br /> | |
527 | If the instance is not, we use an image link card that will redirect to your PeerTube instance.<br /><br /> | |
a1eda903 | 528 | Check this checkbox, save the configuration and test with a video URL of your instance (https://example.com/w/blabla) on |
5f46d28c C |
529 | <a target='_blank' rel='noopener noreferrer' href='https://cards-dev.twitter.com/validator'>https://cards-dev.twitter.com/validator</a> |
530 | to see if you instance is allowed. | |
531 | </ng-container> | |
532 | </ng-template> | |
533 | </my-peertube-checkbox> | |
534 | </div> | |
535 | ||
536 | </ng-container> | |
537 | </ng-container> | |
538 | ||
539 | </div> | |
540 | </div> | |
541 | </ng-container> |