mirror of
https://github.com/9001/copyparty.git
synced 2025-08-17 09:02:15 -06:00
optional navpane wordwrap diasble
This commit is contained in:
parent
7354b462e8
commit
ef60adf7e2
|
@ -791,6 +791,20 @@ input.eq_gain {
|
|||
width: calc(100% - 2em);
|
||||
line-height: 1em;
|
||||
}
|
||||
#tree.nowrap #treeul li {
|
||||
min-height: 1.4em;
|
||||
}
|
||||
#tree.nowrap #treeul a+a {
|
||||
white-space: nowrap;
|
||||
}
|
||||
#tree.nowrap #treeul a+a:hover {
|
||||
background: rgba(34, 34, 34, 0.67);
|
||||
position: fixed;
|
||||
}
|
||||
html.light #tree.nowrap #treeul a+a:hover {
|
||||
background: rgba(255, 255, 255, 0.67);
|
||||
color: #000;
|
||||
}
|
||||
#treeul a+a:hover {
|
||||
background: #222;
|
||||
color: #fff;
|
||||
|
|
|
@ -179,10 +179,11 @@ ebi('op_cfg').innerHTML = (
|
|||
ebi('tree').innerHTML = (
|
||||
'<div id="treeh">\n' +
|
||||
' <a href="#" id="detree" tt="show breadcrumbs$NHotkey: B">🍞...</a>\n' +
|
||||
' <a href="#" class="btn" step="2" id="twobytwo" tt="Hotkey: A">+</a>\n' +
|
||||
' <a href="#" class="btn" step="-2" id="twig" tt="Hotkey: D">–</a>\n' +
|
||||
' <a href="#" class="btn" step="2" id="twobytwo" tt="Hotkey: D">+</a>\n' +
|
||||
' <a href="#" class="btn" step="-2" id="twig" tt="Hotkey: A">–</a>\n' +
|
||||
' <a href="#" class="btn" id="visdir" tt="scroll to selected folder">🎯</a>\n' +
|
||||
' <a href="#" class="tgl btn" id="dyntree" tt="autogrow as tree expands">a</a>\n' +
|
||||
' <a href="#" class="btn" id="visdir" tt="scroll to selected folder">v</a>\n' +
|
||||
' <a href="#" class="tgl btn" id="wraptree" tt="word wrap">↵</a>\n' +
|
||||
'</div>\n' +
|
||||
'<ul id="treeul"></ul>\n' +
|
||||
'<div id="thx_ff"> </div>'
|
||||
|
@ -3019,6 +3020,11 @@ var treectl = (function () {
|
|||
bcfg_bind(treectl, 'dots', 'dotfiles', false, function (v) {
|
||||
treectl.goto(get_evpath());
|
||||
});
|
||||
setwrap(bcfg_bind(treectl, 'wtree', 'wraptree', true, setwrap));
|
||||
|
||||
function setwrap(v) {
|
||||
clmod(ebi('tree'), 'nowrap', !v);
|
||||
}
|
||||
|
||||
treectl.entree = function (e) {
|
||||
ev(e);
|
||||
|
|
Loading…
Reference in a new issue