Browse Source

Merge pull request #639 from joseluis/patch-6

Definining function calc-percent()
Eddie Machado 11 năm trước cách đây
mục cha
commit
00ad23a09c
1 tập tin đã thay đổi với 4 bổ sung1 xóa
  1. 4 1
      library/scss/partials/_functions.scss

+ 4 - 1
library/scss/partials/_functions.scss

@@ -58,6 +58,9 @@ both compile to:
 width: 65%;
 *********************/
 
+@function calc-percent($target, $container) {
+  @return ($target / $container) * 100%;
+}
 @function cp($target, $container) {
   @return calc-percent($target, $container);
-}
+}