From c864d3b638fffdb22a1897507595d666fb16784a Mon Sep 17 00:00:00 2001 From: Andrew Jakubowicz Date: Tue, 5 Sep 2023 16:23:28 -0700 Subject: [PATCH] fix(circularprogress)!: make default width 4px PiperOrigin-RevId: 562924358 --- progress/internal/_circular-progress.scss | 2 ++ tokens/_md-comp-circular-progress.scss | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/progress/internal/_circular-progress.scss b/progress/internal/_circular-progress.scss index 59b66885db..f40e49d17b 100644 --- a/progress/internal/_circular-progress.scss +++ b/progress/internal/_circular-progress.scss @@ -26,6 +26,8 @@ @mixin styles() { $tokens: tokens.md-comp-circular-progress-values(); + // If changing this value, make sure to change $size-without-padding in the + // circular-progress tokens. $container-padding: 4px; // note, these value come from the m2 version but match current gm3 values. diff --git a/tokens/_md-comp-circular-progress.scss b/tokens/_md-comp-circular-progress.scss index 33f7cc0486..381c305f89 100644 --- a/tokens/_md-comp-circular-progress.scss +++ b/tokens/_md-comp-circular-progress.scss @@ -52,10 +52,12 @@ $_default: ( // must be set as a raw % for compatibility between rendering border or svg. $width: map.get($tokens, 'active-indicator-width'); $size: map.get($tokens, 'size'); + $container-padding: 4px; + $size-without-padding: $size - $container-padding - $container-padding; $tokens: map.set( $tokens, 'active-indicator-width', - math.div($width, $size) * 100 + math.div($width, $size-without-padding) * 100 ); }