-
+
diff --git a/copyparty/web/browser.js b/copyparty/web/browser.js
index 28462aa8..010ebaaa 100644
--- a/copyparty/web/browser.js
+++ b/copyparty/web/browser.js
@@ -755,7 +755,6 @@ ebi('ops').innerHTML = (
'
📂 +
' +
'
📝' +
'
📟' +
- '
🎺' +
'
⚙️' +
(IE ? '
' + L.ot_noie + '' : '') +
'
'
@@ -913,6 +912,62 @@ x.parentNode.insertBefore(mknod('div', null,
})();
// config panel
+
+var musicSettings = (
+ '
' +
+
+ '
' +
+ '
' +
+ '
' +
+ '');
+
ebi('op_cfg').innerHTML = (
'
\n' +
'
\n' +
+ musicSettings +
'
\n' +
- (!MOBILE ? '
'
);
@@ -1023,12 +1079,12 @@ ebi('op_cfg').innerHTML = (
var section = `
${sName}
`;
for (var ii = 0; ii < subSettings.children.length; ii++){
var s = subSettings.children[ii];
- var tt = s.getAttribute('tt')?.replace(/\$N/g, "
");
+ var info = tt.parse(s.getAttribute('tt'));
s.removeAttribute('tt');
s.href = '#' + sId;
section += `
` +
s.outerHTML +
- (tt?.length > 0 ? `
${tt}
` : '') +
+ (info?.length > 0 ? `
${info}
` : '') +
'
';
}
section += '
'
@@ -1332,61 +1388,6 @@ ebi('hsortn').oninput = function (e) {
var mpl = (function () {
var have_mctl = 'mediaSession' in navigator && window.MediaMetadata;
- ebi('op_player').innerHTML = (
- '
' +
-
- '
' +
- '
' +
- '
' +
- '');
-
var r = {
"pb_mode": (sread('pb_mode', ['loop', 'next', 'stop']) || 'next').split('-')[0],
"os_ctl": bcfg_get('au_os_ctl', have_mctl) && have_mctl,
@@ -1545,9 +1546,9 @@ var mpl = (function () {
btns.push(btn);
}
if (!IPHONE)
- btns[1].style.display = btns[2].style.display = 'none';
- btns[4].style.display = have_c2flac ? '' : 'none';
- btns[5].style.display = have_c2wav ? '' : 'none';
+ btns[1].parentElement.style.display = btns[2].parentElement.style.display = 'none';
+ btns[4].parentElement.style.display = have_c2flac ? '' : 'none';
+ btns[5].parentElement.style.display = have_c2wav ? '' : 'none';
if (v)
swrite('acode2', v);
@@ -1559,9 +1560,9 @@ var mpl = (function () {
clmod(btns[a], 'on', fmts[a] == v)
r.ac2 = v;
- ebi('ac_flac').setAttribute('tt', L.mt_cflac.split('"')[0].format(v));
- ebi('ac_aac').setAttribute('tt', L.mt_caac.split('"')[0].format(v));
- ebi('ac_oth').setAttribute('tt', L.mt_coth.split('"')[0].format(v));
+ ebi('ac_flac').nextSibling.innerHTML = L.mt_cflac.split('"')[0].format(v);
+ ebi('ac_aac').nextSibling.innerHTML = L.mt_caac.split('"')[0].format(v);
+ ebi('ac_oth').nextSibling.innerHTML = L.mt_coth.split('"')[0].format(v);
};
r.pp = function () {
@@ -2865,8 +2866,10 @@ var afilt = (function () {
for (var a = 0; a < r.bands.length; a++)
gains[a + gains.length / 2].value = gains[a].value = r.gains[a].toFixed(1);
- QS('input.eq_gain[band="amp"]').value = r.amp;
- QS('input.eq_gain[band="chw"]').value = r.chw;
+ var amps = QSA('input.eq_gain[band="amp"]');
+ amps[0].value = amps[1].value = r.amp;
+ var chws = QSA('input.eq_gain[band="chw"]');
+ chws[0].value = chws[1].value = r.chw;
};
r.stop = function () {
@@ -3138,8 +3141,10 @@ var afilt = (function () {
ebi('h_drc').textContent = f2f(r.drcn.reduction, 1);
}
- var html = ['
| ',
- '' + L.enable + ' | '],
+ ebi('audio_eq').innerHTML = '' + L.enable +
+ '' + tt.parse(L.mt_eq) + '
';
+
+ var html = [''],
h2 = [], h3 = [], h4 = [], h5 = [];
var vs = [];
@@ -3167,11 +3172,12 @@ var afilt = (function () {
html += h3.join('\n') + '
';
html += h4.join('\n') + '
';
html += h5.join('\n') + '
';
- ebi('audio_eq').innerHTML = html;
+ ebi('audio_eq').innerHTML += html;
+ ebi('audio_drc').innerHTML = '' + L.enable +
+ '' + tt.parse(L.mt_drc) + '
';
h2 = [];
- html = ['| ',
- '' + L.enable + ' | '];
+ html = [''];
for (var a = 0; a < r.drch.length; a++) {
html.push('| ' + r.drch[a] + ' | ');
@@ -3179,11 +3185,12 @@ var afilt = (function () {
}
html = html.join('\n') + '
';
html += h2.join('\n') + '
';
- ebi('audio_drc').innerHTML = html;
+ ebi('audio_drc').innerHTML += html;
+ ebi('audio_ss').innerHTML = '' + L.enable +
+ '' + tt.parse(L.mt_ss) + '
';
h2 = [];
- html = ['| ',
- '' + L.enable + ' | '];
+ html = [''];
for (var a = 0; a < r.sscl.length; a++) {
html.push(' | ");
+ }
+
r.show = function () {
clearTimeout(tev);
if (r.skip) {
@@ -1561,12 +1573,7 @@ var tt = (function () {
if (!msg)
return;
- if (msg.startsWith('`')) {
- var x = false;
- msg = msg.slice(1);
- while (msg.indexOf('`') + 1)
- msg = msg.replace('`', (x = !x) ? '' : '')
- }
+
r.el = this;
var pos = this.getBoundingClientRect(),
@@ -1583,7 +1590,7 @@ var tt = (function () {
r.tt.style.left = '0';
r.tt.style.top = '0';
- r.tt.innerHTML = msg.replace(/\$N/g, "
");
+ r.tt.innerHTML = r.parse(msg);
r.el.addEventListener('mouseleave', r.hide);
window.addEventListener('scroll', r.hide);
clmod(r.tt, 'show', 1);