mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Revert font awesome 5 changes
We are still pushing ahead on this 100% just need a bit longer to prepare all plugins
This commit is contained in:
21
app/views/common/_special_font_face.html.erb
Normal file
21
app/views/common/_special_font_face.html.erb
Normal file
@@ -0,0 +1,21 @@
|
||||
<%#
|
||||
The fonts are loaded outside of the stylesheet so that we can dynamically change the path.
|
||||
This is to get around CDN caching on the Origin:
|
||||
|
||||
https://forums.aws.amazon.com/thread.jspa?threadID=114646
|
||||
|
||||
Also added a cache breaker there in case we have breaking config changes
|
||||
&1 was added last when the nginx sample config changed
|
||||
%>
|
||||
|
||||
<% font_domain = "#{Discourse.base_url_no_prefix}&2".html_safe %>
|
||||
<% woff2_url = "#{asset_path("fontawesome-webfont.woff2")}?#{font_domain}&v=4.7.0".html_safe %>
|
||||
|
||||
<link rel="preload" href="<%=woff2_url%>" as="font" type="font/woff2" crossorigin />
|
||||
<style>
|
||||
@font-face {
|
||||
font-family: 'FontAwesome';
|
||||
src: url('<%=woff2_url %>') format('woff2'),
|
||||
url('<%=asset_path "fontawesome-webfont.woff" %>?<%= font_domain %>&v=4.7.0') format('woff');
|
||||
}
|
||||
</style>
|
||||
@@ -48,6 +48,7 @@
|
||||
<%- end %>
|
||||
|
||||
<%= render partial: "common/discourse_stylesheet" %>
|
||||
<%= render partial: "common/special_font_face" %>
|
||||
|
||||
<%= yield :head %>
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
<html>
|
||||
<head>
|
||||
<%= discourse_stylesheet_link_tag 'wizard', theme_ids: nil %>
|
||||
<%= render partial: "common/special_font_face" %>
|
||||
<%= preload_script 'ember_jquery' %>
|
||||
<%= preload_script 'wizard-vendor' %>
|
||||
<%= render partial: "layouts/head" %>
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<title><%= content_for?(:title) ? yield(:title) : SiteSetting.title %></title>
|
||||
<meta name="description" content="">
|
||||
<%= render partial: "layouts/head" %>
|
||||
<%= render partial: "common/special_font_face" %>
|
||||
<%= render partial: "common/discourse_stylesheet" %>
|
||||
<%= discourse_csrf_tags %>
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<%= preload_script "locales/#{I18n.locale}" %>
|
||||
<%= preload_script 'wizard-vendor' %>
|
||||
<%= preload_script 'wizard-application' %>
|
||||
<%= render partial: "common/special_font_face" %>
|
||||
<script src="<%= ExtraLocalesController.url("wizard") %>"></script>
|
||||
<%= csrf_meta_tags %>
|
||||
|
||||
@@ -15,12 +16,5 @@
|
||||
<body class='wizard'>
|
||||
<div id='wizard-main'></div>
|
||||
<%= preload_script 'wizard-start' %>
|
||||
|
||||
<div id="svg-sprites" style="display:none;">
|
||||
<div class="fontawesome">
|
||||
<%= raw SvgSprite.bundle %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user