Refactor: centralize metadata sidecar helpers and custom-result builders

This commit is contained in:
Dariusz L
2026-07-18 09:43:27 +02:00
parent be12494953
commit 719b3b3f43
15 changed files with 477 additions and 459 deletions
+2 -3
View File
@@ -2,7 +2,7 @@ import { app } from "../../../../../scripts/app.js";
import { api } from "../../../../../scripts/api.js";
import { $el } from "../../../../../scripts/ui.js";
import { getSvgIcon } from "../../utils/icon_utils.js";
import { escapeHtml, escapeJsString, pollBackgroundTask } from "./html_utils.js";
import { escapeHtml, escapeJsString, getFilenameFromPath, pollBackgroundTask } from "./html_utils.js";
export const renderFormatMethods = {
encodeContextMenuModel(context = null) {
@@ -80,8 +80,7 @@ export const renderFormatMethods = {
},
getFilenameFromPath(path) {
if (!path) return '';
return path.split(/[\/\\]/).pop() || path;
return getFilenameFromPath(path);
},
/**