Chocobozzz/PeerTube

View on GitHub
client/src/app/+my-library/my-video-playlists/my-video-playlists.component.html

Summary

Maintainability
Test Coverage
<div class="sub-title-container">
  <div class="sub-title">
    <my-global-icon iconName="playlists" aria-hidden="true"></my-global-icon>
    <h1 i18n>My playlists</h1>
    <span *ngIf="pagination.totalItems" [title]="getTotalTitle()" class="pt-badge badge-secondary">{{ pagination.totalItems }}</span>
  </div>
</div>

<my-channels-setup-message></my-channels-setup-message>

<div class="video-playlists-header d-flex justify-content-between gap-2">
  <my-advanced-input-filter (search)="onSearch($event)"></my-advanced-input-filter>

  <a class="peertube-create-button" routerLink="create">
    <my-global-icon iconName="add" aria-hidden="true"></my-global-icon>
    <ng-container i18n>Create playlist</ng-container>
  </a>
</div>

<div class="video-playlists" myInfiniteScroller (nearOfBottom)="onNearOfBottom()" [dataObservable]="onDataSubject.asObservable()">
  <div *ngFor="let playlist of videoPlaylists" class="video-playlist">
    <my-video-playlist-miniature
      [playlist]="playlist" [toManage]="true" [displayChannel]="true"
      [displayDescription]="true" [displayPrivacy]="true" [displayAsRow]="true"
    ></my-video-playlist-miniature>

    <div *ngIf="isRegularPlaylist(playlist)" class="video-playlist-buttons">
      <my-delete-button label (click)="deleteVideoPlaylist(playlist)"></my-delete-button>

      <my-edit-button label [ptRouterLink]="[ 'update', playlist.shortUUID ]"></my-edit-button>
    </div>
  </div>
</div>