forked from extern/slate
move background definitions to site config file
This commit is contained in:
parent
1edc87c441
commit
0e878f04b2
@ -1,22 +1,17 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>slate</title>
|
||||
<title>{{ .Title }}</title>
|
||||
<link rel="stylesheet" href="css/slate.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<body{{ if .Site.Params.BackgroundStyle }} style='{{ .Site.Params.BackgroundStyle | safeCSS }}'{{ end }}
|
||||
{{- if .Site.Params.BackgroundImages }} data-backgrounds='{{ range .Site.Params.BackgroundImages }}{{ . }},{{ end }}'{{- end }}>
|
||||
|
||||
{{ partial "nav.html" . }}
|
||||
|
||||
<div class="container">{{ partial "tile_slate.html" . }}
|
||||
</div>
|
||||
|
||||
{{ if .Site.Data.page.backgrounds -}}
|
||||
<background data-backgrounds='{{ range .Site.Data.page.backgrounds }}
|
||||
{{ . }},{{ end }}
|
||||
'>
|
||||
{{- end }}
|
||||
|
||||
</body>
|
||||
<link href="https://fonts.googleapis.com/css?family=Exo" rel="stylesheet">
|
||||
<script src="js/slate.js"></script>
|
||||
|
@ -262,7 +262,7 @@ var renderTiles = function() {
|
||||
renderTiles();
|
||||
|
||||
var getBackgroundImages = function() {
|
||||
var backgrounds = document.getElementsByTagName("background");
|
||||
var backgrounds = document.getElementsByTagName("body");
|
||||
var images = [];
|
||||
if (backgrounds.length > 0) {
|
||||
var imgString = backgrounds[0].getAttribute("data-backgrounds");
|
||||
|
@ -3463,7 +3463,7 @@ var renderTiles = function() {
|
||||
renderTiles();
|
||||
|
||||
var getBackgroundImages = function() {
|
||||
var backgrounds = document.getElementsByTagName("background");
|
||||
var backgrounds = document.getElementsByTagName("body");
|
||||
var images = [];
|
||||
if (backgrounds.length > 0) {
|
||||
var imgString = backgrounds[0].getAttribute("data-backgrounds");
|
||||
|
Loading…
Reference in New Issue
Block a user