Skip to content

Commit bf32eaf

Browse files
committed
fix: toggle play/pause icon for hold music and ringback preview
1 parent 97a87f7 commit bf32eaf

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

frontend/src/views/settings/SettingsView.vue

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '@
1212
import { PageHeader } from '@/components/shared'
1313
import LanguageSwitcher from '@/components/LanguageSwitcher.vue'
1414
import { toast } from 'vue-sonner'
15-
import { Settings, Bell, Loader2, Globe, Phone, Upload, Play, Music } from 'lucide-vue-next'
15+
import { Settings, Bell, Loader2, Globe, Phone, Upload, Play, Pause, Music } from 'lucide-vue-next'
1616
import { usersService, organizationService } from '@/services/api'
1717
1818
const { t } = useI18n()
@@ -400,7 +400,8 @@ function togglePlayAudio(type: 'hold_music' | 'ringback') {
400400
class="h-8 w-8 p-0 text-white/50 hover:text-white light:text-gray-500 light:hover:text-gray-900"
401401
@click="togglePlayAudio('hold_music')"
402402
>
403-
<Play class="h-4 w-4" />
403+
<Pause v-if="playingHoldMusic" class="h-4 w-4" />
404+
<Play v-else class="h-4 w-4" />
404405
</Button>
405406
</div>
406407
<div class="flex items-center gap-2">
@@ -433,7 +434,8 @@ function togglePlayAudio(type: 'hold_music' | 'ringback') {
433434
class="h-8 w-8 p-0 text-white/50 hover:text-white light:text-gray-500 light:hover:text-gray-900"
434435
@click="togglePlayAudio('ringback')"
435436
>
436-
<Play class="h-4 w-4" />
437+
<Pause v-if="playingRingback" class="h-4 w-4" />
438+
<Play v-else class="h-4 w-4" />
437439
</Button>
438440
</div>
439441
<div class="flex items-center gap-2">

0 commit comments

Comments
 (0)