]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/shared/video/video-miniature.component.scss
Use default nsfw instance policy for search index
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / video / video-miniature.component.scss
index d665ce021ccb45b7536207990e3ff0203e1c7c95..99bd9c15b850b9c3486cc2a8a819dd70d07891b5 100644 (file)
@@ -2,15 +2,13 @@
 @import '_mixins';
 @import '_miniature';
 
-$more-button-width: 41px;
-$more-margin-right: 10px;
+$more-button-width: 40px;
+$more-margin-right: 15px;
 
 .video-miniature {
-  width: $video-miniature-width;
   display: inline-flex;
   flex-direction: column;
-  margin-bottom: 30px;
-  height: 195px;
+  padding-bottom: $video-miniature-margin-bottom;
   vertical-align: top;
 
   .video-bottom {
@@ -20,10 +18,23 @@ $more-margin-right: 10px;
       width: $video-miniature-width - $more-button-width - $more-margin-right;
       line-height: normal;
 
+      .avatar {
+        margin: 10px 10px 0 0;
+
+        img {
+          @include avatar(40px);
+        }
+      }
+
       .video-miniature-name {
         @include miniature-name;
       }
 
+      .video-miniature-meta {
+        width: calc(100% + #{$more-button-width});
+        overflow: hidden;
+      }
+
       .video-miniature-created-at-views {
         display: block;
         font-size: 13px;
@@ -36,7 +47,7 @@ $more-margin-right: 10px;
 
         display: block;
         font-size: 13px;
-        color: $grey-foreground-color;
+        color: pvar(--greyForegroundColor);
 
         &:hover {
           color: $grey-foreground-hover-color;
@@ -44,15 +55,15 @@ $more-margin-right: 10px;
       }
 
       .video-info-privacy,
-      .video-info-blacklisted .blacklisted-label,
+      .video-info-blocked .blocked-label,
       .video-info-nsfw {
         font-weight: $font-semibold;
       }
 
-      .video-info-blacklisted {
+      .video-info-blocked {
         color: red;
 
-        .blacklisted-reason::before {
+        .blocked-reason::before {
           content: ' - ';
         }
       }
@@ -64,44 +75,69 @@ $more-margin-right: 10px;
 
     .video-actions {
       margin-top: 3px;
-      margin-right: $more-margin-right;
       width: $more-button-width;
       height: 30px;
 
-      /deep/ .dropdown-root:not(.show) {
+      ::ng-deep .dropdown-root:not(.show) {
         opacity: 0;
       }
 
-      /deep/ .playlist-dropdown.show + my-action-dropdown .dropdown-root {
+      ::ng-deep .playlist-dropdown.show + my-action-dropdown .dropdown-root {
         opacity: 1;
       }
-    }
 
-    &:hover .video-actions /deep/ .dropdown-root {
-      opacity: 1;
+      ::ng-deep .more-icon {
+        opacity: .6;
+
+        &:hover {
+          opacity: 1;
+        }
+      }
     }
 
     @media screen and (max-width: $small-view) {
-      .video-miniature-information .video-miniature-name {
-        margin-top: 0;
+      .video-miniature-information {
+        margin: 0 10px;
       }
 
       .video-actions {
         margin: 0;
         top: -3px;
 
-        /deep/ .dropdown-root {
+        ::ng-deep .dropdown-root {
           opacity: 1 !important;
         }
       }
     }
   }
 
+  &:hover ::ng-deep .video-thumbnail .video-thumbnail-actions-overlay,
+  &:hover .video-bottom .video-actions ::ng-deep .dropdown-root {
+    opacity: 1;
+  }
+
+  &.fit-width {
+    width: 100%;
+
+    .video-bottom {
+      width: 100% !important;
+
+      .video-miniature-information {
+        width: calc(100% - #{$more-button-width}) !important;
+      }
+    }
+
+    my-video-thumbnail {
+      @include large-screen-ratio($selector: '::ng-deep .video-thumbnail');
+    }
+  }
+
   &.display-as-row {
     flex-direction: row;
-    margin-bottom: 0;
+    padding-bottom: 0;
     height: auto;
-    width: 100%;
+    display: flex;
+    flex-grow: 1;
 
     my-video-thumbnail {
       margin-right: 10px;
@@ -109,8 +145,10 @@ $more-margin-right: 10px;
 
     .video-bottom {
       .video-miniature-information {
-        width: auto;
-        min-width: 500px;
+        @media screen and (min-width: $small-view) {
+          width: auto;
+          min-width: 500px;
+        }
 
         .video-miniature-name {
           @include ellipsis-multiline(1.3em, 2);
@@ -122,7 +160,7 @@ $more-margin-right: 10px;
         .video-miniature-created-at-views,
         .video-miniature-account,
         .video-miniature-channel {
-          font-size: 14px;
+          font-size: 95%;
           width: fit-content;
         }
 
@@ -130,7 +168,7 @@ $more-margin-right: 10px;
           margin-top: 5px;
         }
 
-        .video-info-blacklisted {
+        .video-info-blocked {
           margin-top: 3px;
         }
       }