feat: ajouter support background images + filtres CSS overlay sur note cards avec classes .note-has-bg (background-image cover/center), 7 filtres ::after pseudo (glass backdrop-blur 2px, vignette radial-gradient dark edges, lined repeating 28px horizontal, grid 28px squared, noise SVG fractalNoise 0.06 opacity, dots radial 14px, stripes diagonal -45deg), z-index layering .note-inner/hover-actions au-dessus overlay, et sync panel dataset (color/background/filter/fontColor) après chaque action set
This commit is contained in:
@@ -1358,8 +1358,12 @@ function ensureBackgroundStudioPanel() {
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else if (mode === "modal") {
|
||||
setModalNoteColor(key);
|
||||
panelEl.dataset.color = key;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else {
|
||||
setNoteColor(entityId, key, editUrl);
|
||||
panelEl.dataset.color = key;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -1372,23 +1376,31 @@ function ensureBackgroundStudioPanel() {
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else if (mode === "modal") {
|
||||
setModalNoteBackground(key);
|
||||
panelEl.dataset.background = key;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else {
|
||||
setNoteBackground(entityId, key, editUrl);
|
||||
panelEl.dataset.background = key;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (action === "set-filter") {
|
||||
const filterKey = actionBtn.dataset.filter || "none";
|
||||
const normalizedFilter = normalizeFilterKey(filterKey || "") || "none";
|
||||
if (mode === "draft") {
|
||||
const normalized = normalizeFilterKey(filterKey || "") || "none";
|
||||
panelEl.dataset.filter = normalized;
|
||||
applyDraft({ filter: normalized });
|
||||
panelEl.dataset.filter = normalizedFilter;
|
||||
applyDraft({ filter: normalizedFilter });
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else if (mode === "modal") {
|
||||
setModalNoteFilter(filterKey);
|
||||
panelEl.dataset.filter = normalizedFilter;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else {
|
||||
setNoteFilter(entityId, filterKey, editUrl);
|
||||
panelEl.dataset.filter = normalizedFilter;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -1404,12 +1416,19 @@ function ensureBackgroundStudioPanel() {
|
||||
if (action === "set-defaults") {
|
||||
if (mode === "draft") {
|
||||
panelEl.dataset.color = "default";
|
||||
applyDraft({ color: "default" });
|
||||
panelEl.dataset.background = "none";
|
||||
applyDraft({ color: "default", background: "none" });
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else if (mode === "modal") {
|
||||
setModalNoteColor("default");
|
||||
panelEl.dataset.color = "default";
|
||||
panelEl.dataset.background = "none";
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else {
|
||||
setNoteColor(entityId, "default", editUrl);
|
||||
panelEl.dataset.color = "default";
|
||||
panelEl.dataset.background = "none";
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -1421,8 +1440,12 @@ function ensureBackgroundStudioPanel() {
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else if (mode === "modal") {
|
||||
setModalNoteFontColor("auto");
|
||||
panelEl.dataset.fontColor = "auto";
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else {
|
||||
setNoteFontColor(entityId, "auto", editUrl);
|
||||
panelEl.dataset.fontColor = "auto";
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -1445,8 +1468,12 @@ function ensureBackgroundStudioPanel() {
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else if (mode === "modal") {
|
||||
setModalNoteFontColor(fontColorKey);
|
||||
panelEl.dataset.fontColor = fontColorKey;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
} else {
|
||||
setNoteFontColor(entityId, fontColorKey, editUrl);
|
||||
panelEl.dataset.fontColor = fontColorKey;
|
||||
renderBackgroundStudioPanel(panelEl);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user