Add sync link to import page

pull/5215/head
Chocobozzz 2022-08-17 11:55:29 +02:00
parent 6a02dd1c3d
commit 97eba003a9
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
4 changed files with 16 additions and 10 deletions

View File

@ -2,11 +2,3 @@
margin-top: 15px;
}
.peertube-radio-container {
width: 250px;
.form-group-description {
white-space: nowrap;
}
}

View File

@ -16,6 +16,10 @@
</my-help>
<input type="text" id="targetUrl" [(ngModel)]="targetUrl" class="form-control" />
<div *ngIf="isChannelSyncEnabled()" class="form-group-description" i18n>
You can also synchronize a remote channel in <a routerLink="/my-library/video-channel-syncs">your library</a>
</div>
</div>
<div class="form-group">

View File

@ -64,6 +64,10 @@ export class VideoImportUrlComponent extends VideoSend implements OnInit, AfterV
return this.targetUrl?.match(/https?:\/\//)
}
isChannelSyncEnabled () {
return this.serverConfig.import.videoChannelSynchronization.enabled
}
importVideo () {
this.isImportingVideo = true

View File

@ -1,7 +1,7 @@
@use '_variables' as *;
@use '_mixins' as *;
$width-size: 250px;
$width-size: 275px;
.alert.alert-danger {
text-align: center;
@ -27,7 +27,9 @@ $width-size: 250px;
@include peertube-select-container($width-size);
}
my-select-options ::ng-deep ng-select,
my-select-channel ::ng-deep ng-select {
my-select-channel ::ng-deep ng-select,
.peertube-radio-container,
.form-group-description {
width: $width-size;
@media screen and (max-width: $width-size) {
@ -35,6 +37,10 @@ $width-size: 250px;
}
}
.form-group-description {
white-space: nowrap;
}
input[type=text] {
@include peertube-input-text($width-size);
display: block;