Speakr is a personal, self-hosted web application designed for transcribing audio recordings
Python
Add collapsible video toggle as inline icon button in player controls
Murtaza Nasir946f73cd1c02
diff --git a/static/js/app.modular.js b/static/js/app.modular.jsindex 68dc2cf4..b71e32e9 100644--- a/static/js/app.modular.js+++ b/static/js/app.modular.js@@ -537,6 +537,7 @@ document.addEventListener('DOMContentLoaded', async () => {const showVolumeSlider = ref(false);const showModalVolumeSlider = ref(false);const showDuplicatesModal = ref(false);+ const videoCollapsed = ref(false);const duplicatesModalData = ref(null);// --- Modal Audio Player State (Independent from main) ---@@ -2433,6 +2434,7 @@ document.addEventListener('DOMContentLoaded', async () => {retryProgressItem,hasSpeakerNames,showDuplicatesModal,+ videoCollapsed,duplicatesModalData,openDuplicatesModal,navigateToDuplicate,diff --git a/templates/components/detail/audio-player.html b/templates/components/detail/audio-player.htmlindex 1d02aa10..2dc86d08 100644--- a/templates/components/detail/audio-player.html+++ b/templates/components/detail/audio-player.html@@ -28,7 +28,7 @@@waiting="handleAudioWaiting"@canplay="handleAudioCanPlay"@click="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/') && toggleAudioPlayback()"- :class="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/') ? 'w-full rounded-lg mb-2 cursor-pointer' : 'hidden'">+ :class="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/') ? (videoCollapsed ? 'hidden' : 'w-full rounded-lg mb-2 cursor-pointer') : 'hidden'"></component><!-- Progress Bar (draggable, touch support) -->@@ -126,6 +126,15 @@:title="t('buttons.downloadAudio') || 'Download audio'"><i class="fas fa-download text-sm"></i></a>++ <!-- Video Toggle Button -->+ <button v-if="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/')"+ @click="videoCollapsed = !videoCollapsed"+ class="w-8 h-8 flex items-center justify-center rounded-lg hover:bg-[var(--bg-primary)] transition-all flex-shrink-0"+ :class="videoCollapsed ? 'text-[var(--text-muted)]' : 'text-[var(--text-accent)]'"+ :title="videoCollapsed ? 'Show video' : 'Hide video'">+ <i :class="videoCollapsed ? 'fas fa-eye-slash' : 'fas fa-eye'" class="text-sm"></i>+ </button></div></div></div>diff --git a/templates/components/detail/desktop-right-panel.html b/templates/components/detail/desktop-right-panel.htmlindex a5f43c18..8c52da14 100644--- a/templates/components/detail/desktop-right-panel.html+++ b/templates/components/detail/desktop-right-panel.html@@ -30,7 +30,7 @@@waiting="handleAudioWaiting"@canplay="handleAudioCanPlay"@click="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/') && toggleAudioPlayback()"- :class="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/') ? 'w-full rounded-lg mb-3 cursor-pointer' : 'hidden'">+ :class="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/') ? (videoCollapsed ? 'hidden' : 'w-full rounded-lg mb-3 cursor-pointer') : 'hidden'"></component><!-- Progress Bar (now on top, full width, draggable) -->@@ -115,6 +115,15 @@:title="t('buttons.downloadAudio') || 'Download audio'"><i class="fas fa-download text-sm"></i></a>++ <!-- Video Toggle Button -->+ <button v-if="selectedRecording.mime_type && selectedRecording.mime_type.startsWith('video/')"+ @click="videoCollapsed = !videoCollapsed"+ class="w-8 h-8 flex items-center justify-center rounded-lg hover:bg-[var(--bg-primary)] transition-all flex-shrink-0"+ :class="videoCollapsed ? 'text-[var(--text-muted)]' : 'text-[var(--text-accent)]'"+ :title="videoCollapsed ? 'Show video' : 'Hide video'">+ <i :class="videoCollapsed ? 'fas fa-eye-slash' : 'fas fa-eye'" class="text-sm"></i>+ </button></div></div></div>