Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added button to go back up at the bottom of the work section #95

Open
wants to merge 1 commit into
base: gh-pages
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions _includes/work.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ <h3 id="work">Work</h3>
</label>
<h4 class="project-title"></h4>
<div class="project-load"></div>
<label for="return">
<div class="work-return-bottom">{% include icons/icon-back.html %}</div>
</label>

<noscript>
{% for project in site.data.settings.projects %}
Expand Down
12 changes: 12 additions & 0 deletions assets/css/3-sections/_work.sass
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,18 @@
&:hover
opacity: 1

.work-return-bottom
+size(40px)
cursor: pointer
opacity: 0.5
+position(relative, 0px null null 45%)

path
fill: rgba(0,0,0,0.4)

&:hover
opacity: 1



@media (max-width: 740px)
Expand Down
8 changes: 8 additions & 0 deletions assets/js/functions.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@ function workBelt() {
$('.work-container').hide(800);
});

$('.work-return-bottom').click(function() {
$('.work-belt').removeClass("slided");
$('.work-container').hide(800);
document.querySelector('#work').scrollIntoView({
behavior: 'smooth'
});
});

}


Expand Down