annotate service/announce/index.html @ 1754:92999dfbf321 default tip

add shelly support
author drewp@bigasterisk.com
date Tue, 04 Jun 2024 13:03:43 -0700
parents f70514b127d2
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
670
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
1 <!doctype html>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
2 <html>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
3 <head>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
4 <title></title>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
5 <meta charset="utf-8" />
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
6 </head>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
7 <body>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
8 <style>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
9 input { width: 50em; }
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
10 </style>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
11 <input type="text" id="msg">
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
12 <button id="demo">speak</button>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
13 <script>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
14 document.querySelector('#msg').value = 'ding! <prosody rate="100%" pitch="+0%"> normal speech! </prosody>';
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
15 document.querySelector('#demo').addEventListener('click', () => {
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
16 fetch('announcement?text=' + encodeURIComponent(document.querySelector('#msg').value), {
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
17 method: 'POST',
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
18 });
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
19 });
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
20 </script>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
21 </body>
f70514b127d2 service that calls for TTS audio then serves it to chromecasts and to playAudio services
drewp@bigasterisk.com
parents:
diff changeset
22 </html>