Skip to content

Commit cf1e803

Browse files
committed
demo chat app clean up
1 parent a48ea35 commit cf1e803

File tree

2 files changed

+1
-8
lines changed

2 files changed

+1
-8
lines changed

functional-samples/ai.gemini-on-device-audio-scribe/demo-chat-app/index.html

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,6 @@ <h3 id="current-chat-name">Alice</h3>
3535
</div>
3636
<div class="message-list" id="message-list">
3737
<!-- Messages will be loaded here by JavaScript -->
38-
<div class="message sent">Hello!</div>
39-
<div class="message received">Hi there!</div>
4038
</div>
4139
<div class="message-input">
4240
<input

functional-samples/ai.gemini-on-device-audio-scribe/demo-chat-app/script.js

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ document.addEventListener('DOMContentLoaded', () => {
102102
audioElement.addEventListener('timeupdate', () => {
103103
progressBar.value = audioElement.currentTime;
104104
// Update duration display to show current time while playing (optional)
105-
// durationDisplay.textContent = `${formatTime(audioElement.currentTime)} / ${formatTime(audioElement.duration)}`;
105+
durationDisplay.textContent = `${formatTime(audioElement.currentTime)} / ${formatTime(audioElement.duration)}`;
106106
});
107107

108108
// Seek audio when progress bar is changed
@@ -215,11 +215,6 @@ document.addEventListener('DOMContentLoaded', () => {
215215

216216
currentChatName.textContent = chatName;
217217
currentChatAvatar.textContent = avatarEmoji; // Set emoji in header avatar span
218-
219-
// TODO: In a real app, load messages for the selected chat here
220-
// For now, we just update the header
221-
// You could clear the messageList and load new sampleMessages based on chatName
222-
// renderMessages(); // Re-render if messages change
223218
});
224219
});
225220
});

0 commit comments

Comments
 (0)