Skip to content

ActivityPub-federated video streaming platform using P2P directly in your web browser

Refactor a little bit watch html

Chocobozzz8d64a72b4cbd
diff --git a/client/src/app/+videos/+video-watch/video-watch.component.html b/client/src/app/+videos/+video-watch/video-watch.component.html
index a84bafa2a7..09be2d0859 100644
--- a/client/src/app/+videos/+video-watch/video-watch.component.html
+++ b/client/src/app/+videos/+video-watch/video-watch.component.html
@@ -52,13 +52,17 @@
<div class="video-info">
<div class="video-info-first-row">
<div>
+ <ng-template #publishedTemplate>
+ <ng-container i18n>Published <my-date-toggle [date]="video.publishedAt"></my-date-toggle></ng-container>
+ •
+ <my-video-views-counter [video]="video"></my-video-views-counter>
+ </ng-template>
+
<div class="d-block d-md-none"> <!-- only shown on medium devices, has its counterpart for larger viewports below -->
<h1 class="video-info-name">{{ video.name }}</h1>
<div class="video-info-date-views">
- <ng-container i18n>Published <my-date-toggle [date]="video.publishedAt"></my-date-toggle></ng-container>
- •
- <my-video-views-counter [video]="video"></my-video-views-counter>
+ <ng-template *ngTemplateOutlet="publishedTemplate"></ng-template>
</div>
</div>
@@ -69,9 +73,7 @@
<div class="video-info-first-row-bottom">
<div class="d-none d-md-block video-info-date-views">
- <ng-container i18n>Published <my-date-toggle [date]="video.publishedAt"></my-date-toggle></ng-container>
- •
- <my-video-views-counter [video]="video"></my-video-views-counter>
+ <ng-template *ngTemplateOutlet="publishedTemplate"></ng-template>
</div>
<my-action-buttons