SCSS refactoring

SCSS refactoring

followup on c388cac

From 5b6c1b1670a9bd7a8291723296be5b1112f575f0 Mon Sep 17 00:00:00 2001
From: Penar Musaraj <pmusaraj@gmail.com>
Date: Thu, 29 Nov 2018 12:02:11 -0500
Subject: [PATCH] SCSS refactoring

followup on c388cac

diff --git a/app/assets/stylesheets/common/base/group.scss b/app/assets/stylesheets/common/base/group.scss
index 9c2e433..9003472 100644
--- a/app/assets/stylesheets/common/base/group.scss
+++ b/app/assets/stylesheets/common/base/group.scss
@@ -48,6 +48,7 @@
   }
 
   $size: 50px;
+  $icon-size: $size / 1.8;
 
   .avatar-flair-image {
     width: $size;
@@ -63,8 +64,8 @@
     justify-content: center;
 
     .d-icon {
-      height: $size / 1.8;
-      width: $size / 1.8;
+      height: $icon-size;
+      width: $icon-size;
     }
   }
 }
diff --git a/app/assets/stylesheets/common/base/groups.scss b/app/assets/stylesheets/common/base/groups.scss
index e02e919..373b8bf 100644
--- a/app/assets/stylesheets/common/base/groups.scss
+++ b/app/assets/stylesheets/common/base/groups.scss
@@ -218,6 +218,7 @@
     }
 
     $size: 40px;
+    $icon-size: $size / 1.8;
 
     .avatar-flair {
       background-size: $size;
@@ -229,8 +230,8 @@
       justify-content: center;
 
       .d-icon {
-        height: $size / 1.8;
-        width: $size / 1.8;
+        height: $icon-size;
+        width: $icon-size;
       }
     }

GitHub

2 Likes