Fix #4058: FontAwesome CDN is slow/blocking.
Switch to the free self-hosted version of FontAwesome. We're not using any Pro icons, so the Pro version isn't necessary.
This commit is contained in:
@@ -25,6 +25,9 @@ require("jquery-ui/themes/base/draggable.css");
|
||||
require("jquery-ui/themes/base/resizable.css");
|
||||
require("jquery-ui/themes/base/theme.css");
|
||||
|
||||
require("@fortawesome/fontawesome-free/css/all.css");
|
||||
require("@fortawesome/fontawesome-free/js/all.js");
|
||||
|
||||
importAll(require.context('../src/javascripts', true, /\.js(\.erb)?$/));
|
||||
importAll(require.context('../src/styles', true, /\.s?css(?:\.erb)?$/));
|
||||
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
<%= auto_discovery_link_tag :atom, posts_path(:format => "atom", :tags => params[:tags]) %>
|
||||
<%= raw Danbooru.config.custom_html_header_content %>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
|
||||
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
|
||||
<%= javascript_pack_tag "application" %>
|
||||
<%= stylesheet_pack_tag "application" %>
|
||||
<%= yield :html_header %>
|
||||
|
||||
@@ -68,12 +68,6 @@
|
||||
"url" : "<%= root_url %>"
|
||||
}
|
||||
</script>
|
||||
<% if request.domain =~ /donmai\.us/ %>
|
||||
<!-- this is only usable on danbooru.donmai.us -->
|
||||
<link rel="stylesheet" href="https://pro.fontawesome.com/releases/v5.7.1/css/all.css" integrity="sha384-6jHF7Z3XI3fF4XZixAuSu0gGKrXwoX/w3uFPxC56OtjChio7wtTGJWRW53Nhx6Ev" crossorigin="anonymous">
|
||||
<% else %>
|
||||
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.1/css/all.css" integrity="sha384-fnmOCqbTlWIlj8LyTjo7mOUStjsKC4pOpQbqyi7RrhN7udi9RwhKkMHpvLbHG9Sr" crossorigin="anonymous">
|
||||
<% end %>
|
||||
<script>
|
||||
if (typeof window.Danbooru !== "object") {
|
||||
window.Danbooru = {};
|
||||
|
||||
Reference in New Issue
Block a user