Update browser.js

Signed-off-by: ed <s@ocv.me>
This commit is contained in:
ed 2026-01-23 00:04:56 +00:00 committed by GitHub
parent 153239a99e
commit d0652264f7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -5570,7 +5570,6 @@ var thegrid = (function () {
var ths = QSA('#ggrid>a'); var ths = QSA('#ggrid>a');
for (var a = 0, aa = ths.length; a < aa; a++) { for (var a = 0, aa = ths.length; a < aa; a++) {
if(ths[a].id == 'temp') continue;
var tr = ebi(ths[a].getAttribute('ref')).closest('tr'), var tr = ebi(ths[a].getAttribute('ref')).closest('tr'),
cl = tr.className || ''; cl = tr.className || '';
@ -9515,26 +9514,21 @@ var rcm = (function () {
var selFile = jcp(nsFile); var selFile = jcp(nsFile);
function mktemp(is_dir) { function mktemp(is_dir) {
if(!thegrid.en) { qsr('#rcm_tmp');
var row = mknod('tr', 'temp', if (!thegrid.en) {
'<td>-new-</td>' + var row = mknod('tr', 'rcm_tmp',
'<td colspan="' + (QSA("#files thead th").length - 1) + '"><input id="tempname" class="i" type="text" placeholder="' + (is_dir ? 'Folder' : "File") + ' Name"></td>' '<td>-new-</td><td colspan="' + (QSA("#files thead th").length - 1) + '"><input id="tempname" class="i" type="text" placeholder="' + (is_dir ? 'Folder' : 'File') + ' Name"></td>');
);
QS("#files tbody").appendChild(row); QS("#files tbody").appendChild(row);
} }
else{ else {
var row = mknod('a', 'temp', var row = mknod('a', 'rcm_tmp',
'<span class="dir" style="align-self: end;"><input id="tempname" class="dir" type="text" placeholder="' + (is_dir ? 'Folder' : "File") + ' Name"></span>' '<span class="dir" style="align-self:end"><input id="tempname" class="dir" type="text" placeholder="' + (is_dir ? 'Folder' : 'File') + ' Name"></span>');
); if (is_dir)
// TODO: using some inline theming here. not good? row.className = 'dir';
if(is_dir) { row.style.display = 'flex';
row.className = 'dir'; // add folder icon
}
row.style = "display: flex;"; // lets us align text entry box to the bottom
QS("#ggrid").appendChild(row); QS("#ggrid").appendChild(row);
} }
function sendit(name) { function sendit(name) {
name = ('' + name).trim(); name = ('' + name).trim();
if (!name) if (!name)