{"id":16920,"date":"2025-10-26T12:20:33","date_gmt":"2025-10-26T10:20:33","guid":{"rendered":"https:\/\/www.beseit.net\/?p=16920"},"modified":"2025-10-26T13:43:26","modified_gmt":"2025-10-26T11:43:26","slug":"activar-el-lector-de-microsoft-edge-en-pagina-web-ctrl-shift-u","status":"publish","type":"post","link":"https:\/\/www.beseit.net\/?p=16920","title":{"rendered":"Activar mut el lector de microsoft Edge en p\u00e0gina web (Ctrl + Shift + U)"},"content":{"rendered":"\n<pre class=\"wp-block-code\"><code><br><br>El que veus amb <code>Ctrl + Shift + U<\/code> (la funci\u00f3 <strong>\u201cLlegeix en veu alta\u201d<\/strong> d\u2019Edge) fa servir les <strong>veus \u201cOnline (Natural)\u201d<\/strong> \u2014 com <em>Microsoft Jordi<\/em>, <em>Enric (Natural)<\/em>, <em>Joana (Natural)<\/em> \u2014 que tenen una qualitat molt superior (s\u00f3n <strong>neurals<\/strong>, de tipus <em>Azure Cognitive Services<\/em>).<\/code><\/pre>\n\n\n\n<p>Per\u00f2&#8230; ? aquestes <strong>no estan disponibles per a \u00fas directe amb JavaScript<\/strong> ni amb l\u2019API web <code>speechSynthesis<\/code>.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n<!-- \/wp:separator -SEPARADOR!!! -->\n\n\n\n\n<!DOCTYPE html>\n<html lang=\"ca\">\n<head>\n  <meta charset=\"UTF-8\">\n  <title>Conversor de text a veu<\/title>\n  <style>\n    body {\n      font-family: sans-serif;\n      padding: 2em;\n      background-color: lab(90.09% -0.67 -0.25);\n    }\n\n    textarea, select {\n      font-size: 1.2em;\n      padding: 0.5em;\n      margin-top: 1em;\n      width: 100%;\n      max-width: 500px;\n      resize: vertical;\n    }\n\n    #speakBtn {\n      font-size: 2em;\n      background: none;\n      border: none;\n      cursor: pointer;\n      margin-top: 1em;\n    }\n\n    #speakBtn:hover {\n      color: hsl(180, 1%, 72%);\n    }\n  <\/style>\n<\/head>\n<body>\n  <h2>? Conversor de text a veu<\/h2>\n\n  <!-- Camp de text de 10 files -->\n  <textarea id=\"cercar\" placeholder=\"Escriu el text que vols escoltar\" rows=\"10\"><\/textarea>\n\n  <!-- Selector d'idioma -->\n  <select id=\"voiceSelect\">\n    <option value=\"\">Selecciona idioma<\/option>\n    <option value=\"en-US\">?? Angl\u00e8s (US)<\/option>\n    <option value=\"en-GB\">?? Angl\u00e8s (UK)<\/option>\n    <option value=\"fr-FR\">?? Franc\u00e8s<\/option>\n    <option value=\"de-DE\">?? Alemany<\/option>\n    <option value=\"it-IT\">?? Itali\u00e0<\/option>\n    <option value=\"pt-PT\">?? Portugu\u00e8s<\/option>\n    <option value=\"es-ES\">?? Espanyol<\/option>\n    <option value=\"ca-ES\">?\ufe0f Catal\u00e0<\/option>\n  <\/select>\n\n  <!-- Bot\u00f3 d'activaci\u00f3 -->\n  <button id=\"speakBtn\" title=\"Escolta el text\">?<\/button>\n\n  <script>\n    document.addEventListener('DOMContentLoaded', () => {\n      const inputElement = document.getElementById('cercar');\n      const speakBtn = document.getElementById('speakBtn');\n      const voiceSelect = document.getElementById('voiceSelect');\n      let voices = [];\n\n      function loadVoices() {\n        voices = speechSynthesis.getVoices();\n      }\n\n      speechSynthesis.onvoiceschanged = loadVoices;\n      loadVoices();\n\n      function speakText() {\n        const text = inputElement.value.trim();\n        if (!text) return;\n\n        const selectedLang = voiceSelect.value;\n        const utterance = new SpeechSynthesisUtterance(text);\n        const voice = voices.find(v => v.lang === selectedLang);\n\n        if (voice) {\n          utterance.voice = voice;\n          utterance.lang = voice.lang;\n        } else {\n          console.log('No s\\'ha trobat cap veu per a ' + selectedLang);\n        }\n\n        utterance.rate = 1;\n        utterance.pitch = 1;\n\n        speechSynthesis.cancel();\n        speechSynthesis.speak(utterance);\n      }\n\n      speakBtn.addEventListener('click', speakText);\n\n      \/\/\u26a0\ufe0f Opcional: lectura autom\u00e0tica cada 30 segons\n       setInterval(speakText, 70000);\n    });\n  <\/script>\n<\/body>\n<\/html>\n","protected":false},"excerpt":{"rendered":"<p>Per\u00f2&#8230; ? aquestes no estan disponibles per a \u00fas directe amb JavaScript ni amb l\u2019API web speechSynthesis.<\/p>\n","protected":false},"author":2,"featured_media":3167,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[165,1],"tags":[],"class_list":["post-16920","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-edge","category-bloc-de-notes"],"_links":{"self":[{"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/posts\/16920","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.beseit.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=16920"}],"version-history":[{"count":15,"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/posts\/16920\/revisions"}],"predecessor-version":[{"id":16943,"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/posts\/16920\/revisions\/16943"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.beseit.net\/index.php?rest_route=\/wp\/v2\/media\/3167"}],"wp:attachment":[{"href":"https:\/\/www.beseit.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=16920"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.beseit.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=16920"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.beseit.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=16920"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}