Verbeter anatomie en plaatsing van avataraccessoires (v0.4.46-beta) #1
4 changed files with 67 additions and 4 deletions
2
VERSION
2
VERSION
|
|
@ -1 +1 @@
|
||||||
0.3.19-beta
|
0.3.20-beta
|
||||||
|
|
|
||||||
|
|
@ -234,7 +234,10 @@
|
||||||
.bp-board .bpb-x{border:none; background:transparent; color:var(--red); font-weight:900;
|
.bp-board .bpb-x{border:none; background:transparent; color:var(--red); font-weight:900;
|
||||||
cursor:pointer; padding:0; font-size:11px; opacity:.8;}
|
cursor:pointer; padding:0; font-size:11px; opacity:.8;}
|
||||||
.bp-board:hover .bpb-x{opacity:1;}
|
.bp-board:hover .bpb-x{opacity:1;}
|
||||||
|
.bp-board .bpb-mv{color:var(--muted); font-weight:400;}
|
||||||
|
.bp-board .bpb-mv-sel{font:inherit; max-width:150px;}
|
||||||
.bp-board input{border:none; outline:none; font:inherit; width:80px; background:transparent;}
|
.bp-board input{border:none; outline:none; font:inherit; width:80px; background:transparent;}
|
||||||
|
.bp-folder input{border:none; outline:none; font:inherit; width:110px; background:transparent; border-bottom:1px solid var(--line);}
|
||||||
.bp-new{display:flex; gap:6px; margin-top:6px;}
|
.bp-new{display:flex; gap:6px; margin-top:6px;}
|
||||||
.bp-new input{
|
.bp-new input{
|
||||||
flex:1; min-width:0; border:1px solid var(--line); border-radius:10px; padding:7px 9px;
|
flex:1; min-width:0; border:1px solid var(--line); border-radius:10px; padding:7px 9px;
|
||||||
|
|
|
||||||
|
|
@ -1142,6 +1142,24 @@ function renderBoardsPanel(){
|
||||||
fr.className = "bp-folder";
|
fr.className = "bp-folder";
|
||||||
const nm = document.createElement("span");
|
const nm = document.createElement("span");
|
||||||
nm.className = "bpf-name"; nm.textContent = "📁 " + fo.name;
|
nm.className = "bpf-name"; nm.textContent = "📁 " + fo.name;
|
||||||
|
/* map hernoemen: zelfde dblclick-inline-input-patroon als bord hernoemen */
|
||||||
|
nm.addEventListener("dblclick", ()=>{
|
||||||
|
if(fr.querySelector("input")) return;
|
||||||
|
const inp = document.createElement("input");
|
||||||
|
inp.value = fo.name; inp.maxLength = 20;
|
||||||
|
fr.replaceChild(inp, nm);
|
||||||
|
inp.focus(); inp.select();
|
||||||
|
let done = false;
|
||||||
|
const commit = ()=>{
|
||||||
|
if(done) return; done = true;
|
||||||
|
fo.name = inp.value.trim() || fo.name;
|
||||||
|
markBoardChange();
|
||||||
|
renderBoardsPanel(); updateBoardsUI();
|
||||||
|
};
|
||||||
|
inp.addEventListener("keydown", ev=>{ ev.stopPropagation(); if(ev.key==="Enter") commit(); });
|
||||||
|
inp.addEventListener("blur", commit);
|
||||||
|
inp.addEventListener("pointerdown", ev=>ev.stopPropagation());
|
||||||
|
});
|
||||||
fr.appendChild(nm);
|
fr.appendChild(nm);
|
||||||
const add = document.createElement("button");
|
const add = document.createElement("button");
|
||||||
add.textContent = T("newBoard");
|
add.textContent = T("newBoard");
|
||||||
|
|
@ -1194,6 +1212,46 @@ function renderBoardsPanel(){
|
||||||
inp.addEventListener("blur", commit);
|
inp.addEventListener("blur", commit);
|
||||||
inp.addEventListener("pointerdown", ev=>ev.stopPropagation());
|
inp.addEventListener("pointerdown", ev=>ev.stopPropagation());
|
||||||
});
|
});
|
||||||
|
/* bord verplaatsen naar een andere map: klik toont een inline select
|
||||||
|
met de overige mappen; het actieve bord verhuist mee (indices volgen) */
|
||||||
|
if(BS.folders.length > 1){
|
||||||
|
const mv = document.createElement("button");
|
||||||
|
mv.className = "bpb-x bpb-mv"; mv.textContent = "📁";
|
||||||
|
mv.title = T("moveBoardTip");
|
||||||
|
mv.addEventListener("click", ev=>{
|
||||||
|
ev.stopPropagation();
|
||||||
|
if(chip.querySelector("select")) return;
|
||||||
|
const sel = document.createElement("select");
|
||||||
|
sel.className = "bpb-mv-sel";
|
||||||
|
const ph = document.createElement("option");
|
||||||
|
ph.value = ""; ph.textContent = T("moveBoardTip");
|
||||||
|
sel.appendChild(ph);
|
||||||
|
BS.folders.forEach((f2, f2i)=>{
|
||||||
|
if(f2i === fi) return;
|
||||||
|
const o = document.createElement("option");
|
||||||
|
o.value = String(f2i); o.textContent = "📁 " + f2.name;
|
||||||
|
sel.appendChild(o);
|
||||||
|
});
|
||||||
|
sel.addEventListener("click", e2=>e2.stopPropagation());
|
||||||
|
sel.addEventListener("pointerdown", e2=>e2.stopPropagation());
|
||||||
|
sel.addEventListener("blur", ()=>sel.remove());
|
||||||
|
sel.addEventListener("change", ()=>{
|
||||||
|
if(sel.value === "") return;
|
||||||
|
const ti = +sel.value;
|
||||||
|
const wasCur = (fi===BS.f && bi===BS.b);
|
||||||
|
fo.boards.splice(bi,1);
|
||||||
|
BS.folders[ti].boards.push(bo);
|
||||||
|
if(!fo.boards.length) fo.boards.push(newBoardEntry(T("boardName")+" 1"));
|
||||||
|
if(wasCur){ BS.f = ti; BS.b = BS.folders[ti].boards.length-1; }
|
||||||
|
else if(fi===BS.f && bi < BS.b) BS.b--;
|
||||||
|
markBoardChange();
|
||||||
|
renderBoardsPanel(); updateBoardsUI();
|
||||||
|
});
|
||||||
|
chip.appendChild(sel);
|
||||||
|
sel.focus();
|
||||||
|
});
|
||||||
|
chip.appendChild(mv);
|
||||||
|
}
|
||||||
if(fo.boards.length > 1 || BS.folders.length > 1){
|
if(fo.boards.length > 1 || BS.folders.length > 1){
|
||||||
const x = document.createElement("button");
|
const x = document.createElement("button");
|
||||||
x.className = "bpb-x"; x.textContent = "✕";
|
x.className = "bpb-x"; x.textContent = "✕";
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
"use strict";
|
"use strict";
|
||||||
/* version — shown until /api/version resolves (or if the fetch fails, e.g. offline).
|
/* version — shown until /api/version resolves (or if the fetch fails, e.g. offline).
|
||||||
Kept in sync by hand with the VERSION file at the repo root on every release. */
|
Kept in sync by hand with the VERSION file at the repo root on every release. */
|
||||||
const VERSION = "0.3.19-beta";
|
const VERSION = "0.3.20-beta";
|
||||||
(function(){
|
(function(){
|
||||||
const tag = document.getElementById("verTag");
|
const tag = document.getElementById("verTag");
|
||||||
tag.textContent = "v"+VERSION;
|
tag.textContent = "v"+VERSION;
|
||||||
|
|
@ -74,7 +74,8 @@ const I18N = {
|
||||||
boardsNav:"Borden en mappen", newBoard:"+ Bord", newFolder:"+ Map",
|
boardsNav:"Borden en mappen", newBoard:"+ Bord", newFolder:"+ Map",
|
||||||
folderPh:"naam nieuwe map…", boardName:"Bord", folderName:"Map",
|
folderPh:"naam nieuwe map…", boardName:"Bord", folderName:"Map",
|
||||||
delBoard:"Bord verwijderen (2× tikken)",
|
delBoard:"Bord verwijderen (2× tikken)",
|
||||||
renameTip:"Dubbelklik op een bord om het te hernoemen",
|
renameTip:"Dubbelklik op een bord of map om te hernoemen",
|
||||||
|
moveBoardTip:"verplaats naar map…",
|
||||||
hudMin:"Menu inklappen/uitklappen", hudOrient:"Horizontaal of verticaal",
|
hudMin:"Menu inklappen/uitklappen", hudOrient:"Horizontaal of verticaal",
|
||||||
wFull:"Maximaliseren", wUnfull:"Terugzetten",
|
wFull:"Maximaliseren", wUnfull:"Terugzetten",
|
||||||
wZoom:"Inhoud groter of kleiner (voor slechtzienden)",
|
wZoom:"Inhoud groter of kleiner (voor slechtzienden)",
|
||||||
|
|
@ -240,7 +241,8 @@ const I18N = {
|
||||||
boardsNav:"Boards and folders", newBoard:"+ Board", newFolder:"+ Folder",
|
boardsNav:"Boards and folders", newBoard:"+ Board", newFolder:"+ Folder",
|
||||||
folderPh:"name of new folder…", boardName:"Board", folderName:"Folder",
|
folderPh:"name of new folder…", boardName:"Board", folderName:"Folder",
|
||||||
delBoard:"Delete board (tap twice)",
|
delBoard:"Delete board (tap twice)",
|
||||||
renameTip:"Double-click a board to rename it",
|
renameTip:"Double-click a board or folder to rename it",
|
||||||
|
moveBoardTip:"move to folder…",
|
||||||
hudMin:"Collapse/expand menu", hudOrient:"Horizontal or vertical",
|
hudMin:"Collapse/expand menu", hudOrient:"Horizontal or vertical",
|
||||||
wFull:"Maximize", wUnfull:"Restore",
|
wFull:"Maximize", wUnfull:"Restore",
|
||||||
wZoom:"Content bigger or smaller (low vision)",
|
wZoom:"Content bigger or smaller (low vision)",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue