Skip to content

Commit

Permalink
Need to scroll down at least 50 pixels to activate
Browse files Browse the repository at this point in the history
  • Loading branch information
Jaifroid committed Oct 28, 2023
1 parent 6c476cb commit 096c9e0
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion i18n/en.jsonp.js

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

2 changes: 1 addition & 1 deletion i18n/es.jsonp.js

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

2 changes: 1 addition & 1 deletion i18n/fr.jsonp.js

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

2 changes: 1 addition & 1 deletion www/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -500,7 +500,7 @@ <h3 data-i18n="configure-display-settings-title">Display settings</h3>
<div class="card-header" data-i18n="configure-display-panel-header">Display options:</div>
<div class="card-body">
<div class="checkbox">
<label data-i18n-tip="configure-display-slideaway-tip" title="Header and footer will slide away when scrolling down, and will slide back when you scroll up. The option is now on by default." >
<label data-i18n-tip="configure-display-slideaway-tip" title="Header and footer will slide away when scrolling down at least 50 pixels, and will slide back when you scroll up. The option is now on by default." >
<input type="checkbox" name="slideAway" id="slideAwayCheck" checked>
<span data-i18n="configure-display-slideaway"><strong>Hide header and footer when scrolling down</strong> (scroll up slightly to show again)</span>
</label>
Expand Down
2 changes: 1 addition & 1 deletion www/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ function slideAway () {
if (newScrollY === oldScrollY || document.activeElement === document.getElementById('prefix')) return;
if (newScrollY < oldScrollY) {
restoreUIElements();
} else if (newScrollY > 50 && /\(0p?x?\)/.test(header.style.transform)) {
} else if (newScrollY - oldScrollY > 50 && /\(0p?x?\)/.test(header.style.transform)) {
// Hide the toolbars if user has scrolled and not already hidden
const headerStyles = getComputedStyle(header);
const headerHeight = parseFloat(headerStyles.height) + parseFloat(headerStyles.marginBottom) - 2;
Expand Down

0 comments on commit 096c9e0

Please sign in to comment.