Fix minor issues

- fixed indentation
- moved navbars and policy popup to "partials"
- fixed broken image if website icon wasn't set
This commit is contained in:
Bea 2020-11-04 23:29:55 +01:00
parent 3cf0c72092
commit eefd3de659
13 changed files with 109 additions and 107 deletions

1
.gitignore vendored
View File

@ -23,3 +23,4 @@ projectFilesBackup
.DS_Store
dist/
install.ignore

View File

@ -9,9 +9,7 @@
</div>
<main>
<nav class="mind-global-navbar_secondary unselectable">
{{navigation type="secondary"}}
</nav>
{{!< navbar}}
<div class="mind-content_main">
<div class="mind-tag-content_main">
{{#get 'tags' limit='all' include='count.posts' order='count.posts desc'}}

View File

@ -14,12 +14,12 @@
<script src="{{asset "js/arrow-fade.js"}}" async></script>
<script src="{{asset "js/scroll-navbar-color.js"}}"></script>
<!-- TODO: REMOVE ON PRODUCTION! -->
{{!-- TODO: REMOVE ON PRODUCTION! --}}
<script type="text/javascript" src="http://livejs.com/live.js"></script>
<!-- Scripts End -->
{{!-- Scripts End --}}
<!-- Begin Page-specific code -->
{{!-- Begin Page-specific code --}}
{{#is "post"}}
<script src="{{asset "js/remark42-comments.js"}}"></script>
{{/is}}
@ -31,7 +31,7 @@
{{# is "post, page, tag"}}
<title>{{meta_title}} {{@site.title}}</title>
{{/is}}
<!-- End Page-specific code -->
{{!-- End Page-specific code --}}
{{ghost_head}}
{{!-- Outputs important meta data and settings, should always be in <head> --}}
@ -39,21 +39,9 @@
</head>
<body class="{{body_class}}" onload="openPolicyPopup()">
<nav id="mind-global-navbar_primary" class="mind-global-navbar_primary unselectable">
<a href="/">
<img src="{{img_url @site.icon size="xxs"}}" />
</a>
{{navigation}}
</nav>
{{> "navbar-primary"}}
<div class="mind-policy-popup" id="mind-policy-popup">
<h4>This website uses cookies.</h4>
<p>We use cookies to ensure you the best experience.
<br>
By visiting our website, you agree with our <a href="/policy" target="_blank">Privacy Policy</a>.
</p>
<button onclick="agreePolicyPopup()">Ok, understood</button>
</div>
{{> "policy-popup"}}
{{{body}}}
{{!-- All content gets inserted here, index.hbs, post.hbs, etc --}}

View File

@ -7,9 +7,7 @@
<main>
<nav class="mind-global-navbar_secondary unselectable">
{{navigation type="secondary"}}
</nav>
{{> "navbar-secondary"}}
<div class="mind-content_main">
<div class="mind-feed-content_main">

View File

@ -7,9 +7,7 @@
<main>
<nav class="mind-global-navbar_secondary unselectable">
{{navigation type="secondary"}}
</nav>
{{> "navbar-secondary"}}
<div class="mind-content_main">
<div class="mind-feed-content_main">

View File

@ -14,7 +14,7 @@
{{#post}}
<div class="mind-post_content">
<div class="mind-post_content-header">
<img class="mind-post_feature-image" src="{{img_url feature_image size="l"}}"/>
<img class="mind-post_feature-image" src="{{img_url feature_image size="l"}}" alt="Feature Image"/>
</div>
{{content}}
</div>

View File

@ -0,0 +1,8 @@
<nav id="mind-global-navbar_primary" class="mind-global-navbar_primary unselectable">
<a href="/">
{{#if @site.icon}}
<img src="{{img_url @site.icon size="xxs"}}" alt="Website Logo"/>
{{/if}}
</a>
{{navigation}}
</nav>

View File

@ -0,0 +1,3 @@
<nav class="mind-global-navbar_secondary unselectable">
{{navigation type="secondary"}}
</nav>

View File

@ -0,0 +1,8 @@
<div class="mind-policy-popup" id="mind-policy-popup">
<h4>This website uses cookies.</h4>
<p>We use cookies to ensure you the best experience.
<br>
By visiting our website, you agree with our <a href="/policy" target="_blank">Privacy Policy</a>.
</p>
<button onclick="agreePolicyPopup()">Ok, understood</button>
</div>

View File

@ -1,6 +1,6 @@
<article class="{{post_class}}">
<a class="mind-post-card-big_main" href="{{url}}">
<img class="mind-post-card-big_feature-image" src="{{img_url feature_image size="m"}}" />
<img class="mind-post-card-big_feature-image" src="{{img_url feature_image size="m"}}" alt="Feature Image"/>
<header class="mind-post-card-big_header">
<p class="mind-post-card-big_meta"><span class="mind-post-card-big_tag">{{primary_tag.name}}</span>
• <time class="post-date" datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMMM YYYY"}}</time></p>

View File

@ -3,7 +3,7 @@
{{#foreach related}}
<article class="{{post_class}}">
<a class="mind-post-card-sidebar_main" href="{{url}}">
<img class="mind-post-card-sidebar_feature-image" src="{{img_url feature_image size="s"}}" />
<img class="mind-post-card-sidebar_feature-image" src="{{img_url feature_image size="s"}}" alt="Feature Image"/>
<header class="mind-post-card-sidebar_header">
<p class="mind-post-card-sidebar_meta"><span class="mind-post-card-sidebar_tag">{{primary_tag.name}}</span> • <time class="post-date" datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMMM YYYY"}}</time></p>
<h5>{{title}}</h5>

View File

@ -1,6 +1,6 @@
<article class="{{post_class}}">
<a class="mind-tag-card_main" href="{{url}}">
<img class="mind-tag-card_feature-image" src="{{img_url feature_image size="s"}}" />
<img class="mind-tag-card_feature-image" src="{{img_url feature_image size="s"}}" alt="Feature Image"/>
<header class="mind-tag-card_header">
<h4>{{name}}</h4>
</header>

View File

@ -18,7 +18,7 @@
{{#post}}
<div class="mind-post_content">
<div class="mind-post_content-header">
<img class="mind-post_feature-image" src="{{img_url feature_image size="l"}}"/>
<img class="mind-post_feature-image" src="{{img_url feature_image size="l"}}" alt="Feature Image"/>
</div>
{{content}}
<hr>