Spaces:
Running
Running
Update index.html
Browse files- index.html +3 -12
index.html
CHANGED
|
@@ -84,20 +84,11 @@
|
|
| 84 |
return params;
|
| 85 |
}
|
| 86 |
|
| 87 |
-
|
| 88 |
-
window.onload = () => {
|
| 89 |
const params = getHashParams();
|
| 90 |
-
|
| 91 |
-
|
| 92 |
-
|
| 93 |
-
if (!params.apiKey || !params.apiBaseUrl) {
|
| 94 |
-
alert('Please provide both apiKey and apiBaseUrl in the URL hash.');
|
| 95 |
-
}
|
| 96 |
-
};
|
| 97 |
|
| 98 |
-
async function transcribeAudio() {
|
| 99 |
-
const apiKey = document.getElementById('apiKey').value;
|
| 100 |
-
const apiBaseUrl = document.getElementById('apiBaseUrl').value;
|
| 101 |
const audioFile = document.getElementById('audioFile').files[0];
|
| 102 |
const transcriptionDiv = document.getElementById('transcription');
|
| 103 |
|
|
|
|
| 84 |
return params;
|
| 85 |
}
|
| 86 |
|
| 87 |
+
async function transcribeAudio() {
|
|
|
|
| 88 |
const params = getHashParams();
|
| 89 |
+
const apiKey = params.apiKey || '';
|
| 90 |
+
const apiBaseUrl = params.apiBaseUrl || '';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 91 |
|
|
|
|
|
|
|
|
|
|
| 92 |
const audioFile = document.getElementById('audioFile').files[0];
|
| 93 |
const transcriptionDiv = document.getElementById('transcription');
|
| 94 |
|