Browse Source

Refactor border-radius CSS variable handling for improved clarity

codecalm 5 tháng trước cách đây
mục cha
commit
ffdf712f8a
1 tập tin đã thay đổi với 5 bổ sung1 xóa
  1. 5 1
      core/scss/_props.scss

+ 5 - 1
core/scss/_props.scss

@@ -73,7 +73,11 @@
   /** Border radiuses */
   --#{$prefix}border-radius-scale: 1;
   @each $name, $value in $border-radiuses {
-    --#{$prefix}border-radius#{if($name, '-#{$name}', '')}: calc(#{$value} * var(--#{$prefix}border-radius-scale, 1));
+    @if $name {
+      --#{$prefix}border-radius-#{$name}: calc(#{$value} * var(--#{$prefix}border-radius-scale, 1));
+    } @else {
+      --#{$prefix}border-radius: #{$value};
+    }
   }
 
   /** Backdrops */