fix favico on page

This commit is contained in:
Til Schmitter 2026-04-14 23:41:16 +02:00
parent 4a51d292f1
commit 9aadd5032e
4 changed files with 8 additions and 4 deletions

View file

@ -10,6 +10,10 @@
--fg-max: #fff;
--bg-max: #080808;
--a: #fc5;
/* --fg-max: #d1d7e9;
--bg-max: #0a0b0e;
--a: #27efc9; */
--fg: color-mix(var(--fg-max) 90%, var(--bg-max) 10%);
--fg-weak: color-mix(var(--fg-max) 70%, var(--bg-max) 30%);

View file

@ -19,7 +19,7 @@
<div id="topBar">
<div id="headerArea">
<div href="#" id="treeToggleBtn" class="tgl btn"><div class="hamburger_line"></div><div class="hamburger_line"></div><div class="hamburger_line"></div></div>
<a href="/" id="srv_name">{{ srv_name }}</a>
<a href="/" id="srv_name"><span id="favico_onpage"></span>{{ srv_name }}</a>
</div>
<div id="ops"></div>
</div>

View file

@ -7765,6 +7765,7 @@ var treectl = (function () {
if (res.ufavico && (!favico.en || !ebi('icot').value)) {
while (qsr('head>link[rel~="icon"]')) { }
document.head.insertAdjacentHTML('beforeend', res.ufavico);
ebi('favico_onpage').innerHTML = res.ufavico;
}
if (this.hpush && !showfile.active())

View file

@ -2269,6 +2269,8 @@ var favico = (function () {
document.head.appendChild(r.tag);
}
r.tag.href = 'data:image/svg+xml;base64,' + b64;
ebi('favico_onpage').innerHTML = r.txt;
};
r.init = function () {
@ -2277,9 +2279,6 @@ var favico = (function () {
fg = dv.length < 2 ? 'fc5' : dv[1].toLowerCase() == 'none' ? '' : dv[1],
bg = dv.length < 3 ? '222' : dv[2].toLowerCase() == 'none' ? '' : dv[2];
if(dv.length > 0)
ebi('srv_name')?.prepend(dv[0] + ' ');
scfg_bind(r, 'txt', 'icot', dv[0], r.upd);
scfg_bind(r, 'fg', 'icof', fg, r.upd);
scfg_bind(r, 'bg', 'icob', bg, r.upd);