Skip to content

Commit 271155e

Browse files
committed
fix(utils): use unicode arrows with wider OS support
1 parent a510cd2 commit 271155e

File tree

6 files changed

+34
-34
lines changed

6 files changed

+34
-34
lines changed

e2e/cli-e2e/tests/__snapshots__/compare.report-diff.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
|🏷️ Category|⭐ Current score|⭐ Previous score|🔄 Score change|
88
|:--|:--:|:--:|:--:|
9-
|Code style|🟡 **77**|🟡 54|![🠉 +23](https://img.shields.io/badge/%F0%9F%A0%89%20%2B23-green)|
9+
|Code style|🟡 **77**|🟡 54|![ +23](https://img.shields.io/badge/%E2%86%91%20%2B23-green)|
1010
|Bug prevention|🟡 **68**|🟡 68||
1111

1212
## 🎗️ Groups
@@ -16,7 +16,7 @@
1616

1717
|🔌 Plugin|🗃️ Group|⭐ Current score|⭐ Previous score|🔄 Score change|
1818
|:--|:--|:--:|:--:|:--:|
19-
|ESLint|Suggestions|🟡 **71**|🟡 50|![🠉 +21](https://img.shields.io/badge/%F0%9F%A0%89%20%2B21-green)|
19+
|ESLint|Suggestions|🟡 **71**|🟡 50|![ +21](https://img.shields.io/badge/%E2%86%91%20%2B21-green)|
2020

2121
3 other groups are unchanged.
2222

@@ -30,9 +30,9 @@
3030

3131
|🔌 Plugin|🛡️ Audit|📏 Current value|📏 Previous value|🔄 Value change|
3232
|:--|:--|:--:|:--:|:--:|
33-
|ESLint|Require or disallow method and property shorthand syntax for object literals|🟩 **passed**|🟥 3 warnings|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
34-
|ESLint|Require braces around arrow function bodies|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
35-
|ESLint|Require `const` declarations for variables that are never reassigned after declared|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
33+
|ESLint|Require or disallow method and property shorthand syntax for object literals|🟩 **passed**|🟥 3 warnings|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
34+
|ESLint|Require braces around arrow function bodies|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
35+
|ESLint|Require `const` declarations for variables that are never reassigned after declared|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
3636

3737
44 other audits are unchanged.
3838

packages/utils/src/lib/reports/__snapshots__/report-diff-added.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
|🏷️ Category|⭐ Current score|⭐ Previous score|🔄 Score change|
88
|:--|:--:|:--:|:--:|
9-
|Bug prevention|🟡 **63**|🟡 68|![🠋 −5](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%925-red)|
9+
|Bug prevention|🟡 **63**|🟡 68|![ −5](https://img.shields.io/badge/%E2%86%93%20%E2%88%925-red)|
1010
|Performance|🟢 **94**|_n/a (\*)_|_n/a (\*)_|
1111
|Code style|🟡 **54**|🟡 54||
1212

@@ -23,7 +23,7 @@ All of 1 group is unchanged.
2323

2424
|🔌 Plugin|🛡️ Audit|📏 Current value|📏 Previous value|🔄 Value change|
2525
|:--|:--|:--:|:--:|:--:|
26-
|ESLint|Disallow unused variables|🟥 **1 error**|🟩 passed|![🠉 +∞ %](https://img.shields.io/badge/%F0%9F%A0%89%20%2B%E2%88%9E%E2%80%89%25-red)|
26+
|ESLint|Disallow unused variables|🟥 **1 error**|🟩 passed|![ +∞ %](https://img.shields.io/badge/%E2%86%91%20%2B%E2%88%9E%E2%80%89%25-red)|
2727

2828
48 other audits are unchanged.
2929

packages/utils/src/lib/reports/__snapshots__/report-diff-improved.md

+17-17
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66

77
|🏷️ Category|⭐ Current score|⭐ Previous score|🔄 Score change|
88
|:--|:--:|:--:|:--:|
9-
|Code style|🟢 **100**|🟡 54|![🠉 +46](https://img.shields.io/badge/%F0%9F%A0%89%20%2B46-green)|
10-
|Bug prevention|🟢 **95**|🟡 68|![🠉 +27](https://img.shields.io/badge/%F0%9F%A0%89%20%2B27-green)|
11-
|Performance|🟢 **94**|🟢 92|![🠉 +2](https://img.shields.io/badge/%F0%9F%A0%89%20%2B2-green)|
9+
|Code style|🟢 **100**|🟡 54|![ +46](https://img.shields.io/badge/%E2%86%91%20%2B46-green)|
10+
|Bug prevention|🟢 **95**|🟡 68|![ +27](https://img.shields.io/badge/%E2%86%91%20%2B27-green)|
11+
|Performance|🟢 **94**|🟢 92|![ +2](https://img.shields.io/badge/%E2%86%91%20%2B2-green)|
1212

1313
## 🎗️ Groups
1414

@@ -17,8 +17,8 @@
1717

1818
|🔌 Plugin|🗃️ Group|⭐ Current score|⭐ Previous score|🔄 Score change|
1919
|:--|:--|:--:|:--:|:--:|
20-
|ESLint|Maximum lines limitation|🟢 **100**|🟡 50|![🠉 +50](https://img.shields.io/badge/%F0%9F%A0%89%20%2B50-green)|
21-
|Lighthouse|Performance|🟢 **94**|🟢 92|![🠉 +2](https://img.shields.io/badge/%F0%9F%A0%89%20%2B2-green)|
20+
|ESLint|Maximum lines limitation|🟢 **100**|🟡 50|![ +50](https://img.shields.io/badge/%E2%86%91%20%2B50-green)|
21+
|Lighthouse|Performance|🟢 **94**|🟢 92|![ +2](https://img.shields.io/badge/%E2%86%91%20%2B2-green)|
2222

2323
</details>
2424

@@ -30,18 +30,18 @@
3030

3131
|🔌 Plugin|🛡️ Audit|📏 Current value|📏 Previous value|🔄 Value change|
3232
|:--|:--|:--:|:--:|:--:|
33-
|ESLint|Disallow variable declarations from shadowing variables declared in the outer scope|🟩 **passed**|🟥 3 warnings|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
34-
|ESLint|Require or disallow method and property shorthand syntax for object literals|🟩 **passed**|🟥 3 warnings|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
35-
|ESLint|verifies the list of dependencies for Hooks like useEffect and similar|🟩 **passed**|🟥 2 warnings|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
36-
|ESLint|Disallow unused variables|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
37-
|ESLint|Require braces around arrow function bodies|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
38-
|ESLint|Require the use of `===` and `!==`|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
39-
|ESLint|Enforce a maximum number of lines of code in a function|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
40-
|ESLint|Require `const` declarations for variables that are never reassigned after declared|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
41-
|ESLint|Disallow missing `key` props in iterators/collection literals|🟩 **passed**|🟥 1 warning|![🠋 −100 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%92100%E2%80%89%25-green)|
42-
|Lighthouse|Largest Contentful Paint|🟨 **1.4 s**|🟨 1.5 s|![🠋 −8 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%928%E2%80%89%25-green)|
43-
|Lighthouse|First Contentful Paint|🟨 **1.1 s**|🟨 1.2 s|![🠋 −4 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%924%E2%80%89%25-green)|
44-
|Lighthouse|Speed Index|🟩 **1.1 s**|🟩 1.2 s|![🠋 −4 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%924%E2%80%89%25-green)|
33+
|ESLint|Disallow variable declarations from shadowing variables declared in the outer scope|🟩 **passed**|🟥 3 warnings|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
34+
|ESLint|Require or disallow method and property shorthand syntax for object literals|🟩 **passed**|🟥 3 warnings|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
35+
|ESLint|verifies the list of dependencies for Hooks like useEffect and similar|🟩 **passed**|🟥 2 warnings|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
36+
|ESLint|Disallow unused variables|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
37+
|ESLint|Require braces around arrow function bodies|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
38+
|ESLint|Require the use of `===` and `!==`|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
39+
|ESLint|Enforce a maximum number of lines of code in a function|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
40+
|ESLint|Require `const` declarations for variables that are never reassigned after declared|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
41+
|ESLint|Disallow missing `key` props in iterators/collection literals|🟩 **passed**|🟥 1 warning|![ −100 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%92100%E2%80%89%25-green)|
42+
|Lighthouse|Largest Contentful Paint|🟨 **1.4 s**|🟨 1.5 s|![ −8 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%928%E2%80%89%25-green)|
43+
|Lighthouse|First Contentful Paint|🟨 **1.1 s**|🟨 1.2 s|![ −4 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%924%E2%80%89%25-green)|
44+
|Lighthouse|Speed Index|🟩 **1.1 s**|🟩 1.2 s|![ −4 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%924%E2%80%89%25-green)|
4545

4646
40 other audits are unchanged.
4747

packages/utils/src/lib/reports/__snapshots__/report-diff-minimal.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99

1010
|🔌 Plugin|🛡️ Audit|📏 Current value|📏 Previous value|🔄 Value change|
1111
|:--|:--|:--:|:--:|:--:|
12-
|NPM|Check for outdates NPM packages|🟨 **3 packages are out of date**|🟩 1 package is out of date|![🠉 +200 %](https://img.shields.io/badge/%F0%9F%A0%89%20%2B200%E2%80%89%25-red)|
12+
|NPM|Check for outdates NPM packages|🟨 **3 packages are out of date**|🟩 1 package is out of date|![ +200 %](https://img.shields.io/badge/%E2%86%91%20%2B200%E2%80%89%25-red)|
1313

1414
</details>

packages/utils/src/lib/reports/__snapshots__/report-diff-mixed.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
|🏷️ Category|⭐ Current score|⭐ Previous score|🔄 Score change|
88
|:--|:--:|:--:|:--:|
9-
|Bug prevention|🟡 **63**|🟡 68|![🠋 −5](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%925-red)|
10-
|Performance|🟢 **94**|🟢 92|![🠉 +2](https://img.shields.io/badge/%F0%9F%A0%89%20%2B2-green)|
9+
|Bug prevention|🟡 **63**|🟡 68|![ −5](https://img.shields.io/badge/%E2%86%93%20%E2%88%925-red)|
10+
|Performance|🟢 **94**|🟢 92|![ +2](https://img.shields.io/badge/%E2%86%91%20%2B2-green)|
1111
|Code style|🟡 **54**|🟡 54||
1212

1313
## 🎗️ Groups
@@ -17,7 +17,7 @@
1717

1818
|🔌 Plugin|🗃️ Group|⭐ Current score|⭐ Previous score|🔄 Score change|
1919
|:--|:--|:--:|:--:|:--:|
20-
|Lighthouse|Performance|🟢 **94**|🟢 92|![🠉 +2](https://img.shields.io/badge/%F0%9F%A0%89%20%2B2-green)|
20+
|Lighthouse|Performance|🟢 **94**|🟢 92|![ +2](https://img.shields.io/badge/%E2%86%91%20%2B2-green)|
2121

2222
1 other group is unchanged.
2323

@@ -31,10 +31,10 @@
3131

3232
|🔌 Plugin|🛡️ Audit|📏 Current value|📏 Previous value|🔄 Value change|
3333
|:--|:--|:--:|:--:|:--:|
34-
|ESLint|Disallow unused variables|🟥 **1 error**|🟩 passed|![🠉 +∞ %](https://img.shields.io/badge/%F0%9F%A0%89%20%2B%E2%88%9E%E2%80%89%25-red)|
35-
|Lighthouse|Largest Contentful Paint|🟨 **1.4 s**|🟨 1.5 s|![🠋 −8 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%928%E2%80%89%25-green)|
36-
|Lighthouse|First Contentful Paint|🟨 **1.1 s**|🟨 1.2 s|![🠋 −4 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%924%E2%80%89%25-green)|
37-
|Lighthouse|Speed Index|🟩 **1.1 s**|🟩 1.2 s|![🠋 −4 %](https://img.shields.io/badge/%F0%9F%A0%8B%20%E2%88%924%E2%80%89%25-green)|
34+
|ESLint|Disallow unused variables|🟥 **1 error**|🟩 passed|![ +∞ %](https://img.shields.io/badge/%E2%86%91%20%2B%E2%88%9E%E2%80%89%25-red)|
35+
|Lighthouse|Largest Contentful Paint|🟨 **1.4 s**|🟨 1.5 s|![ −8 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%928%E2%80%89%25-green)|
36+
|Lighthouse|First Contentful Paint|🟨 **1.1 s**|🟨 1.2 s|![ −4 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%924%E2%80%89%25-green)|
37+
|Lighthouse|Speed Index|🟩 **1.1 s**|🟩 1.2 s|![ −4 %](https://img.shields.io/badge/%E2%86%93%20%E2%88%924%E2%80%89%25-green)|
3838

3939
48 other audits are unchanged.
4040

packages/utils/src/lib/reports/utils.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ export function getSquaredScoreMarker(score: number): string {
5555

5656
export function getDiffMarker(diff: number): string {
5757
if (diff > 0) {
58-
return '🠉';
58+
return '';
5959
}
6060
if (diff < 0) {
61-
return '🠋';
61+
return '';
6262
}
6363
return '';
6464
}

0 commit comments

Comments
 (0)