Skip to content

Commit

Permalink
added zoomify for zooming images
Browse files Browse the repository at this point in the history
  • Loading branch information
bboc committed Feb 21, 2022
1 parent 1f585b4 commit bb07c88
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs-src/templates/website/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<script type="text/javascript" src="{{ "/js/popper.min-1.16.1.js" | prepend: site.baseurl }}"></script>
<script type="text/javascript" src="{{ "/js/bootstrap-4.5.3.min.js" | prepend: site.baseurl }}"></script>
<script type="text/javascript" src="{{ "/js/mousetrap.1.6.5.min.js" | prepend: site.baseurl }}"></script>
<script type="text/javascript" src="{{ "/js/zoomify-0.2.5.min.js" | prepend: site.baseurl }}"></script>
{% include smartmenus.html %}
{% include keyboard-nav.html %}

Expand Down Expand Up @@ -63,8 +64,7 @@
} else {
$("#prev-page").hide()
}
<!-- Go: Previous Page

$('.post-content img').zoomify();
});
</script>
</body>
Expand Down
5 changes: 4 additions & 1 deletion docs/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<script type="text/javascript" src="{{ "/js/popper.min-1.16.1.js" | prepend: site.baseurl }}"></script>
<script type="text/javascript" src="{{ "/js/bootstrap-4.5.3.min.js" | prepend: site.baseurl }}"></script>
<script type="text/javascript" src="{{ "/js/mousetrap.1.6.5.min.js" | prepend: site.baseurl }}"></script>
<script type="text/javascript" src="{{ "/js/zoomify-0.2.5.min.js" | prepend: site.baseurl }}"></script>
{% include smartmenus.html %}
{% include keyboard-nav.html %}

Expand Down Expand Up @@ -63,8 +64,10 @@
} else {
$("#prev-page").hide()
}
<!-- Go: Previous Page

$('.post-content img').zoomify();


});
</script>
</body>
Expand Down
4 changes: 4 additions & 0 deletions docs/_sass/zoomify.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
.zoomify { cursor: pointer; cursor: -webkit-zoom-in; cursor: zoom-in; }
.zoomify.zoomed { cursor: -webkit-zoom-out; cursor: zoom-out; padding: 0; margin: 0; border: none; border-radius: 0; box-shadow: none; position: relative; z-index: 1501; }
.zoomify-shadow { position: fixed; top: 0; left: 0; right: 0; bottom: 0; width: 100%; height: 100%; display: block; z-index: 1500; background: rgba(0, 0, 0 , .3); opacity: 0; }
.zoomify-shadow.zoomed { opacity: 1; cursor: pointer; cursor: -webkit-zoom-out; cursor: zoom-out; }
4 changes: 3 additions & 1 deletion docs/css/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ $headline-color: $grey-color-dark;
// --- special styles for the homepage
"homepage",
// --- syntax highlightling:
"syntax-highlighting"
"syntax-highlighting",
// --- zoomifiy
"zoomify"
;

//Responsive containers: 100% wide until specified breakpoint is reached, after that max-widths
Expand Down
3 changes: 3 additions & 0 deletions docs/js/zoomify-0.2.5.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit bb07c88

Please sign in to comment.