Quitar URLs javascript: (React 19 las bloquea)

React 19 bloquea href="javascript:void(0)". SiteHeader: DESCONECTAR ahora enlaza
a /{locale}/log-out (ruta real), el menú hamburguesa y el logo pequeño usan
role/button o href real. PostActions (foro): editar/eliminar pasan a role=button.
Se elimina el logout por fetch del header (lo hace la ruta /log-out).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-14 14:46:17 +00:00
parent 0aed48db4b
commit 9e6a8f8231
2 changed files with 9 additions and 20 deletions
+2 -2
View File
@@ -120,11 +120,11 @@ export function PostActions({
return (
<div className="separate small-font">
<a href="javascript:void(0);" onClick={() => setEditing(true)} className="second-brown">
<a role="button" tabIndex={0} onClick={() => setEditing(true)} className="second-brown" style={{ cursor: 'pointer' }}>
{t('edit')}
</a>
{' '}
<a href="javascript:void(0);" onClick={() => { if (!busy) remove() }} className="second-brown">
<a role="button" tabIndex={0} onClick={() => { if (!busy) remove() }} className="second-brown" style={{ cursor: 'pointer' }}>
{t('delete')}
</a>
{error && <span className="red-info2"> {error}</span>}