fix: ensure f-string prefix on copy button onclick

This commit is contained in:
williams
2026-06-12 19:53:04 +02:00
parent fa4a687ce6
commit 373ae97d91
+1 -1
View File
@@ -311,7 +311,7 @@ def ui_index():
short_id = e["id"][:8] short_id = e["id"][:8]
card = ( card = (
f'<div class="entry-header"><span class="entry-id">{_html.escape(short_id)}</span>' f'<div class="entry-header"><span class="entry-id">{_html.escape(short_id)}</span>'
'<button class="copy-btn" type="button" onclick="return copyText(\'{_html.escape(e["id"])}\')">copy id</button>' f'<button class="copy-btn" type="button" onclick="return copyText(\'{_html.escape(e["id"])}\')">copy id</button>'
f'<form method="post" action="/-/delete/{_html.escape(e["id"])}" style="margin:0" onsubmit="return confirm(\'Delete this entry?\')">' f'<form method="post" action="/-/delete/{_html.escape(e["id"])}" style="margin:0" onsubmit="return confirm(\'Delete this entry?\')">'
'<button class="del-btn" type="submit">delete</button></form></div>' '<button class="del-btn" type="submit">delete</button></form></div>'
f'<div class="entry-text">{rendered}</div>' f'<div class="entry-text">{rendered}</div>'