aboutsummaryrefslogblamecommitdiffhomepage
path: root/client/src/app/shared/shared-moderation/video-block.component.html
blob: e5793f2cab09380547d6422467b5b92a67ecbb75 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11

                            








                                                                                                                  
                                                                                                        



                          
                                                             
                              
                 
                                                                                               

                                                                                  




                                                          
                                                 

                                                             
                                               

                                                  

                                                                                                        

                               

            

                                                                     

               
                                     
              
                                                                                                   

                                               
 
                                                                                                                       




              
<ng-template #modal>
  <div class="modal-header">
    <ng-container *ngIf="isMultiple()">
      <h4 i18n class="modal-title">Block {{ videos.length }} videos</h4>
    </ng-container>

    <ng-container *ngIf="!isMultiple()">
      <h4 i18n class="modal-title" *ngIf="!getSingleVideo().isLive">Block video "{{ getSingleVideo().name }}"</h4>
      <h4 i18n class="modal-title" *ngIf="getSingleVideo().isLive">Block live "{{ getSingleVideo().name }}"</h4>
    </ng-container>

    <my-global-icon iconName="cross" aria-label="Close" role="button" (click)="hide()"></my-global-icon>
  </div>

  <div class="modal-body">

    <form novalidate [formGroup]="form" (ngSubmit)="block()">
      <div class="form-group">
        <textarea
          i18n-placeholder placeholder="Please describe the reason..." formControlName="reason"
          [ngClass]="{ 'input-error': formErrors['reason'] }" class="form-control"
        ></textarea>
        <div *ngIf="formErrors.reason" class="form-error">
          {{ formErrors.reason }}
        </div>
      </div>

      <div class="form-group" *ngIf="hasLocal()">
        <my-peertube-checkbox
          inputName="unfederate" formControlName="unfederate"
          i18n-labelText labelText="Unfederate"
        >
          <ng-container ngProjectAs="description">
            <span *ngIf="isMultiple()" i18n>This will ask remote instances to delete local videos</span>
            <span *ngIf="!isMultiple()" i18n>This will ask remote instances to delete this video</span>
          </ng-container>
        </my-peertube-checkbox>
      </div>

      <strong class="live-info" *ngIf="hasLive()" i18n>
        Blocking a live will automatically terminate the live stream.
      </strong>

      <div class="form-group inputs">
        <input
          type="button" role="button" i18n-value value="Cancel" class="peertube-button grey-button"
          (click)="hide()" (key.enter)="hide()"
        >

        <input type="submit" i18n-value value="Block" class="peertube-button orange-button" [disabled]="!form.valid" />
      </div>
    </form>

  </div>
</ng-template>