Skip to content

Commit 99319b1

Browse files
committed
refactor: replace unquote() with string.unquote()
1 parent 9a9f4b1 commit 99319b1

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

scss/forms/_input-group.scss

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
@use "sass:string";
12
@use "../variables" as *;
23
@use "../mixins/border-radius" as *;
34
@use "../mixins/ltr-rtl" as *;
@@ -122,7 +123,7 @@
122123

123124
$validation-messages: "";
124125
@each $state in map-keys($form-validation-states) {
125-
$validation-messages: $validation-messages + ":not(." + unquote($state) + "-tooltip)" + ":not(." + unquote($state) + "-feedback)";
126+
$validation-messages: $validation-messages + ":not(." + string.unquote($state) + "-tooltip)" + ":not(." + string.unquote($state) + "-feedback)";
126127
}
127128

128129
> :not(:first-child):not(.dropdown-menu)#{$validation-messages} {

scss/functions/_math.scss

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
@use "sass:math";
22
@use "sass:meta";
3+
@use "sass:string";
34

45
// Return valid calc
56
@function add($value1, $value2, $return-calc: true) {
@@ -15,7 +16,7 @@
1516
@return $value1 + $value2;
1617
}
1718

18-
@return if($return-calc == true, calc(#{$value1} + #{$value2}), $value1 + unquote(" + ") + $value2);
19+
@return if($return-calc == true, calc(#{$value1} + #{$value2}), $value1 + string.unquote(" + ") + $value2);
1920
}
2021

2122
@function subtract($value1, $value2, $return-calc: true) {
@@ -36,10 +37,10 @@
3637
}
3738

3839
@if meta.type-of($value2) != number {
39-
$value2: unquote("(") + $value2 + unquote(")");
40+
$value2: string.unquote("(") + $value2 + string.unquote(")");
4041
}
4142

42-
@return if($return-calc == true, calc(#{$value1} - #{$value2}), $value1 + unquote(" - ") + $value2);
43+
@return if($return-calc == true, calc(#{$value1} - #{$value2}), $value1 + string.unquote(" - ") + $value2);
4344
}
4445

4546
@function divide($dividend, $divisor, $precision: 10) {

scss/mixins/_ltr-rtl.scss

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
@use "sass:string";
12
@use "../variables" as *;
23
@use "../functions/str-replace" as *;
34

@@ -26,7 +27,7 @@
2627
@return str-replace($string, "right", "left");
2728
}
2829

29-
@return unquote($string);
30+
@return string.unquote($string);
3031
}
3132

3233
@mixin ltr-rtl($property, $value, $property-rtl: null, $value-rtl: null, $important: null) {

0 commit comments

Comments
 (0)