From ea956f2c6cac8f1a298db6685d1bbf89b50e6ada Mon Sep 17 00:00:00 2001 From: Lizandro Guarnizo <77708265+lizandrogd@users.noreply.github.com> Date: Mon, 27 Jul 2026 06:44:36 -0500 Subject: [PATCH] fix(display_global): convertir nombre a Title Case antes del TTS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Los nombres en MAYÚSCULAS son deletreados por el motor de voz. Convertir a Title Case para que se lean como palabras normales. Co-Authored-By: Claude Sonnet 4.6 --- modules/turnero/views/display_global.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/turnero/views/display_global.php b/modules/turnero/views/display_global.php index f1b6425..67795f9 100644 --- a/modules/turnero/views/display_global.php +++ b/modules/turnero/views/display_global.php @@ -525,8 +525,9 @@ function anunciarTurno(codigo, destino, paciente) { playBeep(); if (!sonidoActivo || !('speechSynthesis' in window)) return null; const letras = codigo.split('').join(' '); + const nomVoz = paciente ? paciente.toLowerCase().replace(/\b\w/g, c => c.toUpperCase()) : null; let texto = `Turno ${letras}`; - if (paciente) texto += `, ${paciente}`; + if (nomVoz) texto += `, ${nomVoz}`; texto += `, pase a ${destino}`; const utt = new SpeechSynthesisUtterance(texto); utt.lang = 'es-CO';