aboutsummaryrefslogtreecommitdiffhomepage
path: root/app/Resources/static
diff options
context:
space:
mode:
authorSimounet <contact@simounet.net>2020-01-19 12:50:08 +0100
committerSimounet <contact@simounet.net>2020-01-21 12:00:21 +0100
commitcfd77d1c2abca28c346af4697fb92db98a42f40a (patch)
tree3506d8fa22da5926b2ca8f3088162aab9caa09de /app/Resources/static
parent996b2ec17070bb33ce9cd2ec570289565fd66306 (diff)
downloadwallabag-cfd77d1c2abca28c346af4697fb92db98a42f40a.tar.gz
wallabag-cfd77d1c2abca28c346af4697fb92db98a42f40a.tar.zst
wallabag-cfd77d1c2abca28c346af4697fb92db98a42f40a.zip
Sticky nav on entry action button click
Diffstat (limited to 'app/Resources/static')
-rw-r--r--app/Resources/static/themes/material/css/nav.scss5
-rwxr-xr-xapp/Resources/static/themes/material/index.js8
2 files changed, 13 insertions, 0 deletions
diff --git a/app/Resources/static/themes/material/css/nav.scss b/app/Resources/static/themes/material/css/nav.scss
index 147f163f..b7288278 100644
--- a/app/Resources/static/themes/material/css/nav.scss
+++ b/app/Resources/static/themes/material/css/nav.scss
@@ -131,6 +131,11 @@ nav {
131 display: none; 131 display: none;
132} 132}
133 133
134.entry-nav-top--sticky {
135 position: sticky;
136 top: 0;
137}
138
134@media (min-width: 993px) { 139@media (min-width: 993px) {
135 .button-collapse { 140 .button-collapse {
136 display: none; 141 display: none;
diff --git a/app/Resources/static/themes/material/index.js b/app/Resources/static/themes/material/index.js
index 2926cad1..4b194d00 100755
--- a/app/Resources/static/themes/material/index.js
+++ b/app/Resources/static/themes/material/index.js
@@ -17,6 +17,13 @@ import './js/shortcuts/entry';
17/* Theme style */ 17/* Theme style */
18import './css/index.scss'; 18import './css/index.scss';
19 19
20const stickyNav = () => {
21 const nav = $('.js-entry-nav-top');
22 $('[data-toggle="actions"]').click(() => {
23 nav.toggleClass('entry-nav-top--sticky');
24 });
25};
26
20$(document).ready(() => { 27$(document).ready(() => {
21 // sideNav 28 // sideNav
22 $('.button-collapse').sideNav(); 29 $('.button-collapse').sideNav();
@@ -36,6 +43,7 @@ $(document).ready(() => {
36 initFilters(); 43 initFilters();
37 initExport(); 44 initExport();
38 initRandom(); 45 initRandom();
46 stickyNav();
39 47
40 const toggleNav = (toShow, toFocus) => { 48 const toggleNav = (toShow, toFocus) => {
41 $('.nav-panel-actions').hide(100); 49 $('.nav-panel-actions').hide(100);