kempo-ui 0.4.3 → 0.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/skills/get-icon/SKILL.md +144 -0
- package/.claude/skills/highlight-code/SKILL.md +62 -0
- package/.claude/skills/new-component/SKILL.md +362 -0
- package/.github/skills/get-icon/SKILL.md +4 -4
- package/.github/skills/highlight-code/SKILL.md +51 -20
- package/.github/skills/new-component/SKILL.md +183 -152
- package/AGENTS.md +2 -2
- package/dist/components/SpeechToText.js +60 -0
- package/dist/components/TextToSpeech.js +56 -0
- package/docs/components/accordion.html +8 -0
- package/docs/components/aside.html +8 -0
- package/docs/components/calendar.html +8 -0
- package/docs/components/card.html +8 -0
- package/docs/components/code-editor.html +8 -0
- package/docs/components/color-picker.html +8 -0
- package/docs/components/combobox.html +8 -0
- package/docs/components/content-slider.html +8 -0
- package/docs/components/context.html +8 -0
- package/docs/components/dialog.html +8 -0
- package/docs/components/dropdown.html +8 -0
- package/docs/components/filter-list.html +8 -0
- package/docs/components/focus-capture.html +8 -0
- package/docs/components/html-editor.html +8 -0
- package/docs/components/hybrid-component.html +8 -0
- package/docs/components/icon.html +8 -0
- package/docs/components/import.html +8 -0
- package/docs/components/light-component.html +8 -0
- package/docs/components/nav-spacer.html +8 -0
- package/docs/components/nav.html +8 -0
- package/docs/components/photo-viewer.html +8 -0
- package/docs/components/progress.html +8 -0
- package/docs/components/resize.html +8 -0
- package/docs/components/shadow-component.html +8 -0
- package/docs/components/show-more.html +8 -0
- package/docs/components/slider.html +8 -0
- package/docs/components/sortable.html +8 -0
- package/docs/components/speech-to-text.html +717 -0
- package/docs/components/spinner.html +8 -0
- package/docs/components/split.html +8 -0
- package/docs/components/table.html +8 -0
- package/docs/components/tableControls.html +8 -0
- package/docs/components/tableCustomFields.html +8 -0
- package/docs/components/tableFetchRecords.html +8 -0
- package/docs/components/tableFieldSortHide.html +8 -0
- package/docs/components/tablePagination.html +8 -0
- package/docs/components/tablePlaceholder.html +8 -0
- package/docs/components/tableRecordEditing.html +8 -0
- package/docs/components/tableRecordFiltering.html +8 -0
- package/docs/components/tableRecordHiding.html +8 -0
- package/docs/components/tableRecordSearching.html +8 -0
- package/docs/components/tableRecordSelection.html +8 -0
- package/docs/components/tableRowControls.html +8 -0
- package/docs/components/tableServerSync.html +8 -0
- package/docs/components/tableSorting.html +8 -0
- package/docs/components/tabs.html +8 -0
- package/docs/components/tags.html +8 -0
- package/docs/components/text-to-speech.html +668 -0
- package/docs/components/theme-select.html +8 -0
- package/docs/components/theme-switcher.html +8 -0
- package/docs/components/time.html +8 -0
- package/docs/components/timestamp.html +8 -0
- package/docs/components/toast.html +8 -0
- package/docs/components/toggle.html +8 -0
- package/docs/components/tree.html +8 -0
- package/docs/icons/mic.svg +1 -0
- package/docs/icons/record_voice_over.svg +1 -0
- package/docs/icons/stop.svg +1 -0
- package/docs/index.html +20 -0
- package/docs/src/components/SpeechToText.js +60 -0
- package/docs/src/components/TextToSpeech.js +56 -0
- package/docs/utils/context.html +8 -0
- package/docs/utils/cookie.html +8 -0
- package/docs/utils/debounce.html +8 -0
- package/docs/utils/drag.html +8 -0
- package/docs/utils/elevation.html +8 -0
- package/docs/utils/formatTimestamp.html +8 -0
- package/docs/utils/object.html +8 -0
- package/docs/utils/propConverters.html +8 -0
- package/docs/utils/string.html +8 -0
- package/docs/utils/theme.html +8 -0
- package/docs/utils/toTitleCase.html +8 -0
- package/docs/utils/type.html +8 -0
- package/docs/utils/wait.html +8 -0
- package/docs-src/components/speech-to-text.page.html +251 -0
- package/docs-src/components/text-to-speech.page.html +202 -0
- package/docs-src/index.page.html +12 -0
- package/docs-src/nav.fragment.html +8 -0
- package/icons/mic.svg +1 -0
- package/icons/record_voice_over.svg +1 -0
- package/icons/stop.svg +1 -0
- package/llms.txt +2 -0
- package/package.json +1 -1
- package/src/components/SpeechToText.js +252 -0
- package/src/components/TextToSpeech.js +194 -0
- package/tests/components/SpeechToText.browser-test.js +530 -0
- package/tests/components/TextToSpeech.browser-test.js +432 -0
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
package/docs/utils/object.html
CHANGED
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
package/docs/utils/string.html
CHANGED
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
package/docs/utils/theme.html
CHANGED
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
package/docs/utils/type.html
CHANGED
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
package/docs/utils/wait.html
CHANGED
|
@@ -120,6 +120,9 @@
|
|
|
120
120
|
<k-filter-item filter-keywords="sortable drag drop sort components"><a
|
|
121
121
|
href="../components/sortable.html"
|
|
122
122
|
>Sortable<br><small>Component</small></a></k-filter-item>
|
|
123
|
+
<k-filter-item filter-keywords="speech to text speechtotext microphone voice recognition transcription components"><a
|
|
124
|
+
href="../components/speech-to-text.html"
|
|
125
|
+
>Speech To Text<br><small>Component</small></a></k-filter-item>
|
|
123
126
|
<k-filter-item filter-keywords="spinner loading components"><a
|
|
124
127
|
href="../components/spinner.html">Spinner<br><small>Component</small></a></k-filter-item>
|
|
125
128
|
<k-filter-item filter-keywords="split pane components"><a
|
|
@@ -172,6 +175,9 @@
|
|
|
172
175
|
href="../components/tabs.html">Tabs<br><small>Component</small></a></k-filter-item>
|
|
173
176
|
<k-filter-item filter-keywords="tags tag input components"><a
|
|
174
177
|
href="../components/tags.html">Tags<br><small>Component</small></a></k-filter-item>
|
|
178
|
+
<k-filter-item filter-keywords="text to speech texttospeech tts speak voice synthesis components"><a
|
|
179
|
+
href="../components/text-to-speech.html"
|
|
180
|
+
>Text To Speech<br><small>Component</small></a></k-filter-item>
|
|
175
181
|
<k-filter-item filter-keywords="theme select dropdown dark light components"><a
|
|
176
182
|
href="../components/theme-select.html"
|
|
177
183
|
>Theme Select<br><small>Component</small></a></k-filter-item>
|
|
@@ -297,11 +303,13 @@
|
|
|
297
303
|
<a href="../components/show-more.html">Show More</a>
|
|
298
304
|
<a href="../components/slider.html">Slider</a>
|
|
299
305
|
<a href="../components/sortable.html">Sortable</a>
|
|
306
|
+
<a href="../components/speech-to-text.html">Speech To Text</a>
|
|
300
307
|
<a href="../components/spinner.html">Spinner</a>
|
|
301
308
|
<a href="../components/split.html">Split</a>
|
|
302
309
|
<a href="../components/table.html">Table</a>
|
|
303
310
|
<a href="../components/tabs.html">Tabs</a>
|
|
304
311
|
<a href="../components/tags.html">Tags</a>
|
|
312
|
+
<a href="../components/text-to-speech.html">Text To Speech</a>
|
|
305
313
|
<a href="../components/theme-select.html">Theme Select</a>
|
|
306
314
|
<a href="../components/theme-switcher.html">Theme Switcher</a>
|
|
307
315
|
<a href="../components/time.html">Time</a>
|
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
<page pageName="Speech To Text" title="Speech To Text - Components - Kempo Docs - A Web Components Solution">
|
|
2
|
+
<content>
|
|
3
|
+
<k-accordion persistent-id="toc" class="b r mb">
|
|
4
|
+
<k-accordion-header for-panel="toc-panel">Table of Contents</k-accordion-header>
|
|
5
|
+
<k-accordion-panel name="toc-panel">
|
|
6
|
+
<div class="m pl">
|
|
7
|
+
<h6>Examples</h6>
|
|
8
|
+
<a href="#basicUsage">Basic Usage</a><br />
|
|
9
|
+
<a href="#liveTranscript">Live Transcript</a><br />
|
|
10
|
+
<a href="#continuous">Continuous</a><br />
|
|
11
|
+
<a href="#language">Language</a><br />
|
|
12
|
+
<a href="#minConfidence">Min Confidence</a><br />
|
|
13
|
+
<a href="#timeout">Timeout</a><br />
|
|
14
|
+
<a href="#disabled">Disabled</a><br />
|
|
15
|
+
|
|
16
|
+
<h6 class="mt"><a href="#jsRef" class="no-link">JavaScript Reference</a></h6>
|
|
17
|
+
<a href="#constructor">Constructor</a><br />
|
|
18
|
+
<a href="#requirements">Requirements</a><br />
|
|
19
|
+
<a href="#properties">Properties</a><br />
|
|
20
|
+
<a href="#methods">Methods</a><br />
|
|
21
|
+
<a href="#cssVariables">CSS Variables</a><br />
|
|
22
|
+
<a href="#events">Events</a><br />
|
|
23
|
+
</div>
|
|
24
|
+
</k-accordion-panel>
|
|
25
|
+
</k-accordion>
|
|
26
|
+
|
|
27
|
+
<p>Wraps the browser's <a href="https://developer.mozilla.org/en-US/docs/Web/API/SpeechRecognition" target="_blank">Web Speech API</a> in a single microphone button. Click the button to start listening; the browser stops automatically when the user pauses (or click again to stop manually). Requires a secure context (HTTPS or <code>localhost</code>) and a Chromium-based browser at the time of writing.</p>
|
|
28
|
+
|
|
29
|
+
<h3 id="basicUsage"><a href="#basicUsage" class="no-link">Basic Usage</a></h3>
|
|
30
|
+
<p>The simplest setup — click the mic, speak, and the recognized text appears in the paragraph when you stop. The <code>end</code> event fires once with the full transcript.</p>
|
|
31
|
+
<div class="row -mx">
|
|
32
|
+
<div class="col m-span-12 px">
|
|
33
|
+
<k-card label="HTML">
|
|
34
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"basicSpeech"</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span><br><span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"basicSpeechOutput"</span>></span>(say something...)<span class="hljs-tag"></<span class="hljs-name">p</span>></span><br><span class="hljs-tag"><<span class="hljs-name">script</span>></span><span class="language-javascript"><br> <span class="hljs-keyword">const</span> $stt = <span class="hljs-variable language_">document</span>.<span class="hljs-title function_">getElementById</span>(<span class="hljs-string">'basicSpeech'</span>);<br> <span class="hljs-keyword">const</span> $out = <span class="hljs-variable language_">document</span>.<span class="hljs-title function_">getElementById</span>(<span class="hljs-string">'basicSpeechOutput'</span>);<br> $stt.<span class="hljs-title function_">addEventListener</span>(<span class="hljs-string">'end'</span>, <span class="hljs-function">(<span class="hljs-params">e</span>) =></span> {<br> $out.<span class="hljs-property">textContent</span> = e.<span class="hljs-property">detail</span>.<span class="hljs-property">text</span> || <span class="hljs-string">'(nothing heard)'</span>;<br> });<br></span><span class="hljs-tag"></<span class="hljs-name">script</span>></span></code></pre>
|
|
35
|
+
</k-card>
|
|
36
|
+
</div>
|
|
37
|
+
<div class="col m-span-12 px">
|
|
38
|
+
<k-card label="Output">
|
|
39
|
+
<k-speech-to-text id="basicSpeech"></k-speech-to-text>
|
|
40
|
+
<p id="basicSpeechOutput" class="mt">(say something...)</p>
|
|
41
|
+
<script>
|
|
42
|
+
const $stt = document.getElementById('basicSpeech');
|
|
43
|
+
const $out = document.getElementById('basicSpeechOutput');
|
|
44
|
+
$stt.addEventListener('end', (e) => {
|
|
45
|
+
$out.textContent = e.detail.text || '(nothing heard)';
|
|
46
|
+
});
|
|
47
|
+
</script>
|
|
48
|
+
</k-card>
|
|
49
|
+
</div>
|
|
50
|
+
</div>
|
|
51
|
+
|
|
52
|
+
<h3 id="liveTranscript"><a href="#liveTranscript" class="no-link">Live Transcript</a></h3>
|
|
53
|
+
<p>Add the <code>interim</code> attribute and listen for the <code>result</code> event to update the paragraph as the user speaks. <code>detail.isFinal</code> indicates whether the chunk is finalized.</p>
|
|
54
|
+
<div class="row -mx">
|
|
55
|
+
<div class="col m-span-12 px">
|
|
56
|
+
<k-card label="HTML">
|
|
57
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"liveSpeech"</span> <span class="hljs-attr">interim</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span><br><span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"liveSpeechOutput"</span>></span><span class="hljs-tag"></<span class="hljs-name">p</span>></span><br><span class="hljs-tag"><<span class="hljs-name">script</span>></span><span class="language-javascript"><br> <span class="hljs-keyword">const</span> $stt = <span class="hljs-variable language_">document</span>.<span class="hljs-title function_">getElementById</span>(<span class="hljs-string">'liveSpeech'</span>);<br> <span class="hljs-keyword">const</span> $out = <span class="hljs-variable language_">document</span>.<span class="hljs-title function_">getElementById</span>(<span class="hljs-string">'liveSpeechOutput'</span>);<br> $stt.<span class="hljs-title function_">addEventListener</span>(<span class="hljs-string">'result'</span>, <span class="hljs-function">(<span class="hljs-params">e</span>) =></span> {<br> $out.<span class="hljs-property">textContent</span> = e.<span class="hljs-property">detail</span>.<span class="hljs-property">text</span>;<br> });<br></span><span class="hljs-tag"></<span class="hljs-name">script</span>></span></code></pre>
|
|
58
|
+
</k-card>
|
|
59
|
+
</div>
|
|
60
|
+
<div class="col m-span-12 px">
|
|
61
|
+
<k-card label="Output">
|
|
62
|
+
<k-speech-to-text id="liveSpeech" interim></k-speech-to-text>
|
|
63
|
+
<p id="liveSpeechOutput" class="mt"> </p>
|
|
64
|
+
<script>
|
|
65
|
+
const $sttLive = document.getElementById('liveSpeech');
|
|
66
|
+
const $outLive = document.getElementById('liveSpeechOutput');
|
|
67
|
+
$sttLive.addEventListener('result', (e) => {
|
|
68
|
+
$outLive.textContent = e.detail.text;
|
|
69
|
+
});
|
|
70
|
+
</script>
|
|
71
|
+
</k-card>
|
|
72
|
+
</div>
|
|
73
|
+
</div>
|
|
74
|
+
|
|
75
|
+
<h3 id="continuous"><a href="#continuous" class="no-link">Continuous</a></h3>
|
|
76
|
+
<p>By default the recognizer stops automatically after a brief pause. Add <code>continuous</code> so it keeps listening until the user clicks the button a second time.</p>
|
|
77
|
+
<div class="row -mx">
|
|
78
|
+
<div class="col m-span-12 px">
|
|
79
|
+
<k-card label="HTML">
|
|
80
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">continuous</span> <span class="hljs-attr">interim</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"contSpeech"</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span><br><span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"contSpeechOutput"</span>></span><span class="hljs-tag"></<span class="hljs-name">p</span>></span></code></pre>
|
|
81
|
+
</k-card>
|
|
82
|
+
</div>
|
|
83
|
+
<div class="col m-span-12 px">
|
|
84
|
+
<k-card label="Output">
|
|
85
|
+
<k-speech-to-text id="contSpeech" continuous interim></k-speech-to-text>
|
|
86
|
+
<p id="contSpeechOutput" class="mt"> </p>
|
|
87
|
+
<script>
|
|
88
|
+
const $sttCont = document.getElementById('contSpeech');
|
|
89
|
+
const $outCont = document.getElementById('contSpeechOutput');
|
|
90
|
+
$sttCont.addEventListener('result', (e) => {
|
|
91
|
+
$outCont.textContent = e.detail.text;
|
|
92
|
+
});
|
|
93
|
+
</script>
|
|
94
|
+
</k-card>
|
|
95
|
+
</div>
|
|
96
|
+
</div>
|
|
97
|
+
|
|
98
|
+
<h3 id="language"><a href="#language" class="no-link">Language</a></h3>
|
|
99
|
+
<p>Set the recognition <code>language</code> using a BCP‑47 tag (e.g. <code>"es-ES"</code>, <code>"fr-FR"</code>, <code>"de-DE"</code>). Defaults to <code>"en-US"</code>.</p>
|
|
100
|
+
<div class="row -mx">
|
|
101
|
+
<div class="col m-span-12 px">
|
|
102
|
+
<k-card label="HTML">
|
|
103
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">language</span>=<span class="hljs-string">"es-ES"</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span></code></pre>
|
|
104
|
+
</k-card>
|
|
105
|
+
</div>
|
|
106
|
+
<div class="col m-span-12 px">
|
|
107
|
+
<k-card label="Output">
|
|
108
|
+
<k-speech-to-text language="es-ES"></k-speech-to-text>
|
|
109
|
+
</k-card>
|
|
110
|
+
</div>
|
|
111
|
+
</div>
|
|
112
|
+
|
|
113
|
+
<h3 id="minConfidence"><a href="#minConfidence" class="no-link">Min Confidence</a></h3>
|
|
114
|
+
<p>Set <code>min-confidence</code> to a number between <code>0</code> and <code>1</code> to drop low-confidence transcripts. Chrome's recognizer reports a confidence score on each finalized result; values below your threshold are skipped (they don't accumulate into <code>end.detail.text</code>). Interim chunks usually have <code>confidence === 0</code> in Chrome, so any positive threshold also filters those out — useful when you want to ignore background noise or ambient audio. Default is <code>0</code> (no filtering).</p>
|
|
115
|
+
<div class="row -mx">
|
|
116
|
+
<div class="col m-span-12 px">
|
|
117
|
+
<k-card label="HTML">
|
|
118
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"confSpeech"</span> <span class="hljs-attr">min-confidence</span>=<span class="hljs-string">"0.7"</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span><br><span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"confSpeechOutput"</span>></span>(only confident speech...)<span class="hljs-tag"></<span class="hljs-name">p</span>></span></code></pre>
|
|
119
|
+
</k-card>
|
|
120
|
+
</div>
|
|
121
|
+
<div class="col m-span-12 px">
|
|
122
|
+
<k-card label="Output">
|
|
123
|
+
<k-speech-to-text id="confSpeech" min-confidence="0.7"></k-speech-to-text>
|
|
124
|
+
<p id="confSpeechOutput" class="mt">(only confident speech...)</p>
|
|
125
|
+
<script>
|
|
126
|
+
const $sttConf = document.getElementById('confSpeech');
|
|
127
|
+
const $outConf = document.getElementById('confSpeechOutput');
|
|
128
|
+
$sttConf.addEventListener('end', (e) => {
|
|
129
|
+
$outConf.textContent = e.detail.text || '(no high-confidence speech detected)';
|
|
130
|
+
});
|
|
131
|
+
</script>
|
|
132
|
+
</k-card>
|
|
133
|
+
</div>
|
|
134
|
+
</div>
|
|
135
|
+
|
|
136
|
+
<h3 id="timeout"><a href="#timeout" class="no-link">Timeout</a></h3>
|
|
137
|
+
<p>Set <code>timeout</code> to the maximum number of seconds the component should listen before stopping itself. The recognition stops automatically and the <code>end</code> event fires with whatever transcript was captured. Default is <code>0</code> (no timeout — recognition runs until the user stops, or the browser auto-stops on a pause when <code>continuous</code> is unset).</p>
|
|
138
|
+
<div class="row -mx">
|
|
139
|
+
<div class="col m-span-12 px">
|
|
140
|
+
<k-card label="HTML">
|
|
141
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"timeoutSpeech"</span> <span class="hljs-attr">timeout</span>=<span class="hljs-string">"5"</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span><br><span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"timeoutSpeechOutput"</span>></span>(stops after 5 seconds...)<span class="hljs-tag"></<span class="hljs-name">p</span>></span></code></pre>
|
|
142
|
+
</k-card>
|
|
143
|
+
</div>
|
|
144
|
+
<div class="col m-span-12 px">
|
|
145
|
+
<k-card label="Output">
|
|
146
|
+
<k-speech-to-text id="timeoutSpeech" timeout="5" continuous interim></k-speech-to-text>
|
|
147
|
+
<p id="timeoutSpeechOutput" class="mt">(stops after 5 seconds...)</p>
|
|
148
|
+
<script>
|
|
149
|
+
const $sttTimeout = document.getElementById('timeoutSpeech');
|
|
150
|
+
const $outTimeout = document.getElementById('timeoutSpeechOutput');
|
|
151
|
+
$sttTimeout.addEventListener('result', (e) => {
|
|
152
|
+
$outTimeout.textContent = e.detail.text;
|
|
153
|
+
});
|
|
154
|
+
$sttTimeout.addEventListener('end', (e) => {
|
|
155
|
+
if(!e.detail.text) $outTimeout.textContent = '(no speech captured)';
|
|
156
|
+
});
|
|
157
|
+
</script>
|
|
158
|
+
</k-card>
|
|
159
|
+
</div>
|
|
160
|
+
</div>
|
|
161
|
+
|
|
162
|
+
<h3 id="disabled"><a href="#disabled" class="no-link">Disabled</a></h3>
|
|
163
|
+
<p>The <code>disabled</code> attribute prevents user interaction. The button also auto-disables when the browser doesn't support the Web Speech API.</p>
|
|
164
|
+
<div class="row -mx">
|
|
165
|
+
<div class="col m-span-12 px">
|
|
166
|
+
<k-card label="HTML">
|
|
167
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-speech-to-text</span> <span class="hljs-attr">disabled</span>></span><span class="hljs-tag"></<span class="hljs-name">k-speech-to-text</span>></span></code></pre>
|
|
168
|
+
</k-card>
|
|
169
|
+
</div>
|
|
170
|
+
<div class="col m-span-12 px">
|
|
171
|
+
<k-card label="Output">
|
|
172
|
+
<k-speech-to-text disabled></k-speech-to-text>
|
|
173
|
+
</k-card>
|
|
174
|
+
</div>
|
|
175
|
+
</div>
|
|
176
|
+
|
|
177
|
+
<h2 id="jsRef"><a href="#jsRef" class="no-link">JavaScript Reference</a></h2>
|
|
178
|
+
|
|
179
|
+
<h3 id="constructor"><a href="#constructor" class="no-link">Constructor</a></h3>
|
|
180
|
+
<h6>Extends <a href="./shadow-component.html">ShadowComponent</a></h6>
|
|
181
|
+
<h5><code>new SpeechToText()</code></h5>
|
|
182
|
+
|
|
183
|
+
<h3 id="requirements"><a href="#requirements" class="no-link">Requirements</a></h3>
|
|
184
|
+
<ul>
|
|
185
|
+
<li><a href="./shadow-component.html">ShadowComponent</a></li>
|
|
186
|
+
<li>A browser that supports <code>SpeechRecognition</code> (Chrome, Edge, Safari 14.1+, etc.) served over HTTPS or <code>localhost</code></li>
|
|
187
|
+
</ul>
|
|
188
|
+
|
|
189
|
+
<h3 id="properties"><a href="#properties" class="no-link">Properties</a></h3>
|
|
190
|
+
<h5><code>language<i>: String</i></code></h5>
|
|
191
|
+
<p>BCP‑47 language tag passed to the underlying <code>SpeechRecognition.lang</code> (e.g. <code>"en-US"</code>, <code>"es-ES"</code>). Default is <code>"en-US"</code>. Syncs to <code>language</code> attribute.</p>
|
|
192
|
+
|
|
193
|
+
<h5><code>continuous<i>: Boolean</i></code></h5>
|
|
194
|
+
<p>When <code>true</code>, recognition keeps listening past pauses until <code>stop()</code> is called. Default is <code>false</code>. Syncs to <code>continuous</code> attribute.</p>
|
|
195
|
+
|
|
196
|
+
<h5><code>interim<i>: Boolean</i></code></h5>
|
|
197
|
+
<p>When <code>true</code>, the recognizer emits unfinalized results as the user speaks (the <code>result</code> event fires for interim chunks too). Note that the underlying <code>SpeechRecognition.interimResults</code> is always <code>true</code> internally so the <code>end</code> event has a fallback transcript when the engine doesn't finalize; this attribute only controls public <code>result</code> dispatching. Default is <code>false</code>. Syncs to <code>interim</code> attribute.</p>
|
|
198
|
+
|
|
199
|
+
<h5><code>minConfidence<i>: Number</i></code></h5>
|
|
200
|
+
<p>A floor (<code>0</code>–<code>1</code>) on the confidence score Chrome reports for each result. Anything below the threshold is dropped. Useful for ignoring background noise: at <code>0.7</code> you'll only capture speech the engine is confident about. Default is <code>0</code> (accept everything). Syncs to <code>min-confidence</code> attribute.</p>
|
|
201
|
+
|
|
202
|
+
<h5><code>timeout<i>: Number</i></code></h5>
|
|
203
|
+
<p>Maximum recording duration in seconds. When non-zero, the component automatically calls <code>stop()</code> after this many seconds, firing the <code>end</code> event with the captured transcript. Default is <code>0</code> (no timeout). Syncs to <code>timeout</code> attribute.</p>
|
|
204
|
+
|
|
205
|
+
<h5><code>disabled<i>: Boolean</i></code></h5>
|
|
206
|
+
<p>When <code>true</code>, the button cannot be clicked. Syncs to <code>disabled</code> attribute.</p>
|
|
207
|
+
|
|
208
|
+
<h5><code>listening<i>: Boolean</i></code></h5>
|
|
209
|
+
<p>Read-only-ish state that reflects whether recognition is active. The button shows a pulsing red state while listening. Syncs to <code>listening</code> attribute.</p>
|
|
210
|
+
|
|
211
|
+
<h3 id="methods"><a href="#methods" class="no-link">Methods</a></h3>
|
|
212
|
+
<h5><code>start()<i>: void</i></code></h5>
|
|
213
|
+
<p>Begin listening. No-op if already listening, disabled, or unsupported.</p>
|
|
214
|
+
|
|
215
|
+
<h5><code>stop()<i>: void</i></code></h5>
|
|
216
|
+
<p>Stop listening and finalize the transcript.</p>
|
|
217
|
+
|
|
218
|
+
<h5><code>toggle()<i>: void</i></code></h5>
|
|
219
|
+
<p>Calls <code>start()</code> if idle, <code>stop()</code> if currently listening — the same behavior as clicking the button.</p>
|
|
220
|
+
|
|
221
|
+
<h3 id="cssVariables"><a href="#cssVariables" class="no-link">CSS Variables</a></h3>
|
|
222
|
+
<table class="b">
|
|
223
|
+
<thead><tr><th>Variable</th><th>Default</th><th>Description</th></tr></thead>
|
|
224
|
+
<tbody>
|
|
225
|
+
<tr><td><code>--btn_size</code></td><td><code>2.5rem</code></td><td>Diameter of the microphone button</td></tr>
|
|
226
|
+
<tr><td><code>--btn_bg</code></td><td><code>var(--c_bg)</code></td><td>Background of the idle button</td></tr>
|
|
227
|
+
<tr><td><code>--btn_bg__listening</code></td><td><code>var(--c_danger, #d32f2f)</code></td><td>Background while actively listening</td></tr>
|
|
228
|
+
<tr><td><code>--btn_tc__listening</code></td><td><code>white</code></td><td>Icon color while listening</td></tr>
|
|
229
|
+
</tbody>
|
|
230
|
+
</table>
|
|
231
|
+
|
|
232
|
+
<h3 id="events"><a href="#events" class="no-link">Events</a></h3>
|
|
233
|
+
<h5><code>start</code></h5>
|
|
234
|
+
<p>Fires when recognition begins.</p>
|
|
235
|
+
|
|
236
|
+
<h5><code>result</code></h5>
|
|
237
|
+
<p>Fires for each recognized chunk. <code>detail</code> contains <code>{ text: String, isFinal: Boolean }</code>. With <code>interim</code> enabled, this fires repeatedly as the user speaks.</p>
|
|
238
|
+
|
|
239
|
+
<h5><code>end</code></h5>
|
|
240
|
+
<p>Fires when recognition stops (auto pause, manual stop, or error). <code>detail</code> contains <code>{ text: String }</code> — the full final transcript.</p>
|
|
241
|
+
|
|
242
|
+
<h5><code>error</code></h5>
|
|
243
|
+
<p>Fires when the underlying <code>SpeechRecognition</code> reports an error. <code>detail</code> contains <code>{ error: String, message: String }</code>.</p>
|
|
244
|
+
</content>
|
|
245
|
+
<content location="scripts">
|
|
246
|
+
<script type="module" src="{{pathToRoot}}src/components/SpeechToText.js"></script>
|
|
247
|
+
<script type="module" src="{{pathToRoot}}src/components/Icon.js"></script>
|
|
248
|
+
<script type="module" src="{{pathToRoot}}src/components/Accordion.js"></script>
|
|
249
|
+
<script type="module" src="{{pathToRoot}}src/components/Card.js"></script>
|
|
250
|
+
</content>
|
|
251
|
+
</page>
|