Skip to content

Commit

Permalink
ui: folder loading indicator stole focus
Browse files Browse the repository at this point in the history
show a spinning halfcircle around the +/- instead of
moving the focus to the selected folder in the sidebar,
since that could mess with keyboard scrolling
  • Loading branch information
9001 committed Nov 2, 2024
1 parent 119e88d commit d9962f6
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
12 changes: 12 additions & 0 deletions copyparty/web/browser.css
Original file line number Diff line number Diff line change
Expand Up @@ -1710,6 +1710,18 @@ html.dz .btn {
background: var(--btn-1-bg);
text-shadow: none;
}
#tree ul a.ld::before {
font-weight: bold;
font-family: sans-serif;
display: inline-block;
text-align: center;
width: 1em;
margin: 0 .3em 0 -1.3em;
color: var(--fg-max);
opacity: 0;
content: '◠';
animation: .5s linear infinite forwards spin, ease .25s 1 forwards fadein;
}
#tree ul a.par {
color: var(--fg-max);
}
Expand Down
3 changes: 1 addition & 2 deletions copyparty/web/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -6140,8 +6140,6 @@ function tree_neigh(n) {
links[act].click();
else
treectl.treego.call(links[act]);

links[act].focus();
}


Expand Down Expand Up @@ -7246,6 +7244,7 @@ var treectl = (function () {
r.reqls(href, true);
r.dir_cb = tree_scrollto;
thegrid.setvis(true);
clmod(this, 'ld', 1);
}

r.reqls = function (url, hpush, back, hydrate) {
Expand Down

0 comments on commit d9962f6

Please sign in to comment.