mirror of
https://github.com/wallabag/wallabag.git
synced 2025-03-13 14:42:39 +00:00
Merge pull request #8040 from wallabag/remove-jquery-animations
Remove jQuery animations
This commit is contained in:
commit
ee534a2415
2 changed files with 9 additions and 6 deletions
|
@ -298,13 +298,13 @@ $(document).ready(() => {
|
||||||
initPreviewText();
|
initPreviewText();
|
||||||
|
|
||||||
const toggleNav = (toShow, toFocus) => {
|
const toggleNav = (toShow, toFocus) => {
|
||||||
$('.nav-panel-actions').hide(100);
|
$('.nav-panel-actions').hide();
|
||||||
$(toShow).show(100);
|
$(toShow).show();
|
||||||
$(toFocus).focus();
|
$(toFocus).focus();
|
||||||
};
|
};
|
||||||
|
|
||||||
$('#nav-btn-add-tag').on('click', () => {
|
$('#nav-btn-add-tag').on('click', () => {
|
||||||
$('.nav-panel-add-tag').toggle(100);
|
$('.nav-panel-add-tag').toggle();
|
||||||
$('.nav-panel-menu').addClass('hidden');
|
$('.nav-panel-menu').addClass('hidden');
|
||||||
if (window.innerWidth < mobileMaxWidth) {
|
if (window.innerWidth < mobileMaxWidth) {
|
||||||
$('.sidenav').sidenav('close');
|
$('.sidenav').sidenav('close');
|
||||||
|
@ -353,8 +353,8 @@ $(document).ready(() => {
|
||||||
});
|
});
|
||||||
|
|
||||||
$('.close').on('click', (e) => {
|
$('.close').on('click', (e) => {
|
||||||
$(e.target).parent('.nav-panel-item').hide(100);
|
$(e.target).parent('.nav-panel-item').hide();
|
||||||
$('.nav-panel-actions').show(100);
|
$('.nav-panel-actions').show();
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,10 @@ function retrievePercent(id, resized) {
|
||||||
const scroll = bheight * percent;
|
const scroll = bheight * percent;
|
||||||
|
|
||||||
if (!resized) {
|
if (!resized) {
|
||||||
$('html,body').animate({ scrollTop: scroll }, 'fast');
|
window.scrollTo({
|
||||||
|
top: scroll,
|
||||||
|
behavior: 'smooth',
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in a new issue