Skip to content

Commit 44138c7

Browse files
Fix dart sass 2.0 division deprecations (#3544)
* Fix dart sass 2.0 division deprecations The src/rails_admin/styles/base/theming.scss used division calculations which causes deprecation warnings with dart sass >= 2. The fontawesome-free version also has the same problem. Using calc() around the division math fixes the issue in theming.scss Upgrading fontawesome-free to the latest version fixies their issue * Update fontawesome vendor/assets for sprockets projects Fontawesome-free removed eot, svg and woff files and do not seem to be included anymore
1 parent ec83444 commit 44138c7

File tree

8 files changed

+4534
-7821
lines changed

8 files changed

+4534
-7821
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
},
1616
"dependencies": {
1717
"@babel/runtime": "^7.16.7",
18-
"@fortawesome/fontawesome-free": "^5.15.4",
18+
"@fortawesome/fontawesome-free": "^6.1.1",
1919
"@hotwired/turbo-rails": "^7.1.0",
2020
"@popperjs/core": "^2.11.0",
2121
"@rails/ujs": "^6.1.4-1",

src/rails_admin/styles/base/theming.scss

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ body.rails_admin {
1919

2020
img {
2121
position: absolute;
22-
top: ((40px - $avatar-size) / 2);
22+
top: calc((40px - $avatar-size) / 2);
2323

2424
& + span {
2525
margin-left: ($avatar-size + 5px);
@@ -33,14 +33,14 @@ body.rails_admin {
3333
padding: 0;
3434

3535
.dropdown-header {
36-
padding: ($grid-gutter-width / 2) ($grid-gutter-width / 2) 3px;
36+
padding: calc($grid-gutter-width / 2) calc($grid-gutter-width / 2) 3px;
3737
font-weight: bold;
3838
color: $gray-700;
3939
text-transform: uppercase;
4040
}
4141

4242
> li > a {
43-
padding: ($navbar-padding-y / 2) ($grid-gutter-width / 2);
43+
padding: calc($navbar-padding-y / 2) calc($grid-gutter-width / 2);
4444

4545
&.active {
4646
background-color: map-get($theme-colors, primary);
-198 KB
Binary file not shown.

vendor/assets/fonts/rails_admin/fa-solid-900.svg

-5,034
This file was deleted.
Binary file not shown.
-99.3 KB
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)