]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/sass/include/_mixins.scss
Merge branch 'release/5.0.0' into develop
[github/Chocobozzz/PeerTube.git] / client / src / sass / include / _mixins.scss
index 4738d130554ff514e7d5f9b7ca4ba86e750edd4e..8816437d933b9bff77b214e80441fbfdc53378fc 100644 (file)
   max-height: $font-size * $number-of-lines;
 }
 
+@mixin muted {
+  color: pvar(--greyForegroundColor) !important;
+}
+
 @mixin fade-text ($fade-after, $background-color) {
   position: relative;
   overflow: hidden;
   [type=radio]:checked,
   [type=radio]:not(:checked) {
     position: absolute;
-    left: -9999px;
+    opacity: 0;
+    cursor: pointer;
+    height: 0;
+    width: 0;
   }
 
   [type=radio]:checked + label,
 }
 
 @mixin chip {
-  --chip-radius: 5rem;
-  --chip-padding: .2rem .4rem;
-  $avatar-height: 1.2rem;
+  --avatar-size: 1.2rem;
 
-  align-items: center;
-  border-radius: var(--chip-radius);
   display: inline-flex;
-  font-size: 90%;
   color: pvar(--mainForegroundColor);
-  height: $avatar-height;
-  line-height: 1rem;
-  margin: .1rem;
+  height: var(--avatar-size);
   max-width: 320px;
   overflow: hidden;
-  padding: var(--chip-padding);
   text-decoration: none;
   text-overflow: ellipsis;
   vertical-align: middle;
   white-space: nowrap;
 
-  &.rectangular {
-    --chip-radius: .2rem;
-    --chip-padding: .2rem .3rem;
-  }
-
   my-actor-avatar {
-    @include margin-left(-.4rem);
     @include margin-right(.2rem);
+
+    border-radius: 5rem;
+    width: var(--avatar-size);
+    height: var(--avatar-size);
   }
 
   &.two-lines {
-    $avatar-height: 2rem;
+    --avatar-size: 2rem;
 
-    height: $avatar-height;
+    font-size: 14px;
+    line-height: 1rem;
 
     my-actor-avatar {
       display: inline-block;
     }
 
-    div {
-      margin: 0 .1rem;
-
+    > div {
       display: flex;
       flex-direction: column;
-      height: $avatar-height;
       justify-content: center;
     }
   }