Skip to content

Commit beb3ffa

Browse files
authored
Upgrade FontAwesome to v6 (#1694)
1 parent 9d3a894 commit beb3ffa

12 files changed

+33
-819
lines changed

home/static/css/fontawesome/css/fontawesome.min.css

+6-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

home/static/css/fontawesome/css/regular.min.css

-5
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/*!
2+
* Font Awesome Free 6.5.2 by @fontawesome - https://fontawesome.com
3+
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
4+
* Copyright 2024 Fonticons, Inc.
5+
*/
6+
:host,:root{--fa-style-family-classic:"Font Awesome 6 Free";--fa-font-solid:normal 900 1em/1 "Font Awesome 6 Free"}@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:900;font-display:block;src:url(../webfonts/fa-solid-900.woff2) format("woff2"),url(../webfonts/fa-solid-900.ttf) format("truetype")}.fa-solid,.fas{font-weight:900}
Binary file not shown.

home/static/css/fontawesome/webfonts/fa-regular-400.svg

-801
This file was deleted.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

home/wagtail_hooks.py

+13-11
Original file line numberDiff line numberDiff line change
@@ -88,17 +88,19 @@ def global_admin_css():
8888
)
8989

9090
@hooks.register("insert_global_admin_css")
91-
def import_fontawesome_stylesheet():
92-
return "\n".join([
93-
format_html(
94-
'<link rel="stylesheet" href="{}">',
95-
static("css/fontawesome/css/fontawesome.min.css"),
96-
),
97-
format_html(
98-
'<link rel="stylesheet" href="{}">',
99-
static("css/fontawesome/css/regular.min.css"),
100-
),
101-
])
91+
def import_fontawesome_stylesheets():
92+
return "\n".join(
93+
[
94+
format_html(
95+
'<link rel="stylesheet" href="{}">',
96+
static("css/fontawesome/css/fontawesome.min.css"),
97+
),
98+
format_html(
99+
'<link rel="stylesheet" href="{}">',
100+
static("css/fontawesome/css/solid.min.css"),
101+
),
102+
]
103+
)
102104

103105

104106
@hooks.register('insert_global_admin_js', order=100)

iogt/static/js/admin.js

+8
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ function customizeUI() {
4141
'The descriptive text displayed underneath a headline in search engine results, and automatically loaded ' +
4242
'as a description into shares on social media eg Facebook Posts or shared links in WhatsApp.'
4343
);
44+
45+
configureEasyMDE();
4446
}
4547

4648
function validateFileUpload(fileInput, file_size_threshold) {
@@ -70,4 +72,10 @@ function validateFreeBasicsFileUpload(fileInput, file_size_threshold) {
7072
return true;
7173
}
7274

75+
function configureEasyMDE() {
76+
window.wagtailMarkdown = window.wagtailMarkdown || {};
77+
window.wagtailMarkdown.options = window.wagtailMarkdown.options || {};
78+
window.wagtailMarkdown.options.spellChecker = false;
79+
}
80+
7381
$(document).ready(customizeUI);

0 commit comments

Comments
 (0)