mirror of
https://github.com/offen/website.git
synced 2024-11-22 09:00:28 +01:00
add body class for propagating chosen template
This commit is contained in:
parent
a553147a94
commit
b14493c911
@ -406,14 +406,13 @@ MENU
|
|||||||
.nav-bar {
|
.nav-bar {
|
||||||
height: 70px;
|
height: 70px;
|
||||||
}
|
}
|
||||||
.brand,
|
.brand {
|
||||||
.brand-index {
|
|
||||||
position: absolute;
|
position: absolute;
|
||||||
padding: 12px 0 0 20px;
|
padding: 12px 0 0 20px;
|
||||||
float: left;
|
float: left;
|
||||||
line-height: 70px;
|
line-height: 70px;
|
||||||
}
|
}
|
||||||
.brand-index {
|
body.index .brand {
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
}
|
}
|
||||||
.nav-container {
|
.nav-container {
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
$(window).scroll(function () {
|
$(window).scroll(function () {
|
||||||
var scrollProgress = parseInt($(window).scrollTop(), 10)
|
var scrollProgress = parseInt($(window).scrollTop(), 10)
|
||||||
$('.brand-index').css('opacity', Math.min(scrollProgress / 100, 1))
|
$('body.index .brand').css('opacity', Math.min(scrollProgress / 100, 1))
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
})(window.jQuery)
|
})(window.jQuery)
|
||||||
|
@ -1,11 +1,5 @@
|
|||||||
{% extends "base.html" %}
|
{% extends "base.html" %}
|
||||||
|
|
||||||
{% block brand %}
|
|
||||||
<div class="brand">
|
|
||||||
{{ super() }}
|
|
||||||
</div>
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<div class="container-full">
|
<div class="container-full">
|
||||||
|
@ -26,13 +26,13 @@
|
|||||||
<script async src="https://script-alpha.offen.dev/script.js" data-account-id="{{ OFFEN_ACCOUNT_ID }}"></script>
|
<script async src="https://script-alpha.offen.dev/script.js" data-account-id="{{ OFFEN_ACCOUNT_ID }}"></script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body class="{{page.template}}">
|
||||||
<div class="menu">
|
<div class="menu">
|
||||||
<section class="nav-bar">
|
<section class="nav-bar">
|
||||||
<div class="nav-container">
|
<div class="nav-container">
|
||||||
{% block brand %}
|
<div class="brand">
|
||||||
<a href="/"><img src="/theme/images/offen-brand-white.svg" alt="offen logo" width="42" height="46" class="logo"></a>
|
<a href="/"><img src="/theme/images/offen-brand-white.svg" alt="offen logo" width="42" height="46" class="logo"></a>
|
||||||
{% endblock %}
|
</div>
|
||||||
<nav>
|
<nav>
|
||||||
<div class="nav-mobile"><span id="nav-toggle"><span></span></span></div>
|
<div class="nav-mobile"><span id="nav-toggle"><span></span></span></div>
|
||||||
<ul class="nav-list">
|
<ul class="nav-list">
|
||||||
|
@ -1,11 +1,5 @@
|
|||||||
{% extends "base.html" %}
|
{% extends "base.html" %}
|
||||||
|
|
||||||
{% block brand %}
|
|
||||||
<div class="brand-index">
|
|
||||||
{{ super() }}
|
|
||||||
</div>
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<div class="intro">
|
<div class="intro">
|
||||||
<div class="bg" id="bg-intro">
|
<div class="bg" id="bg-intro">
|
||||||
|
@ -1,7 +1 @@
|
|||||||
{% extends "base.html" %}
|
{% extends "base.html" %}
|
||||||
|
|
||||||
{% block brand %}
|
|
||||||
<div class="brand">
|
|
||||||
{{ super() }}
|
|
||||||
</div>
|
|
||||||
{% endblock %}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user