Add feedback dialog for cloud dashboard (#293)

This commit is contained in:
KM Koushik
2025-11-29 10:22:12 +11:00
committed by GitHub
parent 357d561a8e
commit e1b64d0d7b
9 changed files with 247 additions and 25 deletions
@@ -0,0 +1,12 @@
export function escapeHtml(input: string) {
return input
.replace(/&/g, "&")
.replace(/</g, "&lt;")
.replace(/>/g, "&gt;")
.replace(/"/g, "&quot;")
.replace(/'/g, "&#39;");
}
export function toPlainHtml(text: string) {
return `<pre style="font-family: inherit; white-space: pre-wrap; margin: 0;">${escapeHtml(text)}</pre>`;
}