Make scroll to top better, improve clarity on redirect page
This commit is contained in:
@@ -4,14 +4,14 @@
|
|||||||
<div class="inner">
|
<div class="inner">
|
||||||
<div class="title-area">
|
<div class="title-area">
|
||||||
{% if page.url == '/' %}
|
{% if page.url == '/' %}
|
||||||
<h1 class="site-title">
|
<h1 class="site-title" id="start">
|
||||||
<a href="{{ '/' | relative_url }}">
|
<a href="{{ '/' | relative_url }}">
|
||||||
{% if site.logo %}<img src="{{ site_logo }}" alt="" class="site-logo">{% endif %}
|
{% if site.logo %}<img src="{{ site_logo }}" alt="" class="site-logo">{% endif %}
|
||||||
<span>{{ site.title | escape }}</span>
|
<span>{{ site.title | escape }}</span>
|
||||||
</a>
|
</a>
|
||||||
</h1>
|
</h1>
|
||||||
{% else %}
|
{% else %}
|
||||||
<p class="site-title">
|
<p class="site-title" id="start">
|
||||||
<a href="{{ '/' | relative_url }}">
|
<a href="{{ '/' | relative_url }}">
|
||||||
{% if site.logo %}<img src="{{ site_logo }}" alt="" class="site-logo">{% endif %}
|
{% if site.logo %}<img src="{{ site_logo }}" alt="" class="site-logo">{% endif %}
|
||||||
<span>{{ site.title | escape }}</span>
|
<span>{{ site.title | escape }}</span>
|
||||||
|
|||||||
+3
-3
@@ -1,9 +1,9 @@
|
|||||||
---
|
---
|
||||||
layout: page
|
layout: page
|
||||||
---
|
---
|
||||||
|
<h1>Redirecting...</h1>
|
||||||
<p id="cat">{{page.class}}</p>
|
<p style="display: none;" id="cat">{{page.class}}</p>
|
||||||
<p id="cat2">{{page.title | uri_escape }}</p>
|
<p style="display: none;" id="cat2">{{page.title | uri_escape }}</p>
|
||||||
<script>
|
<script>
|
||||||
window.location.replace("/projects/" + document.getElementById("cat").innerText.toLowerCase() + "#" + document.getElementById("cat2").innerText);
|
window.location.replace("/projects/" + document.getElementById("cat").innerText.toLowerCase() + "#" + document.getElementById("cat2").innerText);
|
||||||
</script>
|
</script>
|
||||||
+1
-1
@@ -14,7 +14,7 @@ layout: page
|
|||||||
{% include entry.html %}
|
{% include entry.html %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
<a href="#page-title" class="back-to-top">{{ site.data.text[site.locale].back_to_top | default: 'Back to Top' }} ↑</a>
|
<a href="#start" class="back-to-top">{{ site.data.text[site.locale].back_to_top | default: 'Back to Top' }} ↑</a>
|
||||||
</section>
|
</section>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
|
|
||||||
html {
|
html {
|
||||||
@include fluid-type($min-vw, $max-vw, $min-font-size, $max-font-size);
|
@include fluid-type($min-vw, $max-vw, $min-font-size, $max-font-size);
|
||||||
|
scroll-behavior: smooth;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
|
|||||||
Reference in New Issue
Block a user