fix(client): quote breaking tooltips (fixes #1003)

This commit is contained in:
Elian Doran
2025-01-28 21:03:39 +02:00
parent a2b6504d9d
commit 5c31a0afeb
5 changed files with 35 additions and 29 deletions

View File

@@ -124,6 +124,10 @@ function escapeHtml(str: string) {
return str.replace(/[&<>"'`=\/]/g, (s) => entityMap[s]);
}
export function escapeQuotes(value: string) {
return value.replaceAll("\"", "&quot;");
}
function formatSize(size: number) {
size = Math.max(Math.round(size / 1024), 1);