浏览代码

avatar-image fix

Marco Volo 5 年之前
父节点
当前提交
2bb5a31fa4
共有 2 个文件被更改,包括 4 次插入0 次删除
  1. 2 0
      client/components/cards/cardDetails.styl
  2. 2 0
      client/components/users/userAvatar.styl

+ 2 - 0
client/components/cards/cardDetails.styl

@@ -37,6 +37,8 @@ avatar-radius = 50%
       position: absolute
       position: absolute
 
 
     &.avatar-image
     &.avatar-image
+      object-fit: cover;
+      object-position: center;
       height: 100%
       height: 100%
       width: @height
       width: @height
 
 

+ 2 - 0
client/components/users/userAvatar.styl

@@ -29,6 +29,8 @@ avatar-radius = 50%
       position: absolute
       position: absolute
 
 
     &.avatar-image
     &.avatar-image
+      object-fit: cover;
+      object-position: center;
       height: 100%
       height: 100%
       width: @height
       width: @height