Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
d06ad98e
Commit
d06ad98e
authored
Oct 29, 2018
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert to sync loading of css, sometimes js loaded before css which caused issues
parent
1f6df77a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
public/views/index.template.html
+4
-8
No files found.
public/views/index.template.html
View file @
d06ad98e
...
...
@@ -14,6 +14,9 @@
<link
rel=
"icon"
type=
"image/png"
href=
"public/img/fav32.png"
>
<link
rel=
"mask-icon"
href=
"public/img/grafana_mask_icon.svg"
color=
"#F05A28"
>
<link
rel=
"apple-touch-icon"
sizes=
"180x180"
href=
"public/img/apple-touch-icon.png"
>
<link
rel=
"stylesheet"
href=
"public/build/grafana.[[ .Theme ]].css?v[[ .BuildVersion ]]+[[ .BuildCommit ]]"
>
<meta
name=
"apple-mobile-web-app-capable"
content=
"yes"
>
<meta
name=
"apple-mobile-web-app-status-bar-style"
content=
"black"
>
<meta
name=
"msapplication-TileColor"
content=
"#2b5797"
>
...
...
@@ -253,14 +256,7 @@
navTree
:
[[.
NavTree
]]
};
// load css async
var
myCSS
=
document
.
createElement
(
"link"
);
myCSS
.
rel
=
"stylesheet"
;
myCSS
.
href
=
"public/build/grafana.[[ .Theme ]].css?v[[ .BuildVersion ]]+[[ .BuildCommit ]]"
;
// insert it at the end of the head in a legacy-friendly manner
document
.
head
.
insertBefore
(
myCSS
,
document
.
head
.
childNodes
[
document
.
head
.
childNodes
.
length
-
1
].
nextSibling
);
// switch loader to show all has loaded
// In case the js files fails to load the code below will show an info message.
window
.
onload
=
function
()
{
var
preloader
=
document
.
getElementsByClassName
(
"preloader"
);
if
(
preloader
.
length
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment