A mobile app for listening to radio stations from around the globe
git clone git://soophie.de/verbal
135
<div136
v-if="station"137
ref="button"138
class="fixed w-[64px] h-[64px] bg-white rounded-full bottom-4 right-4 z-40 cursor-pointer shadow-xl"138
class="fixed w-[64px] h-[64px] bg-zinc-900 rounded-md bottom-5 right-4 z-40 cursor-pointer shadow-xl overflow-hidden"139
@click="state.open = !state.open"140
>141
<v-icon142
id="playlist"143
class="pointer-events-none"141
<img142
v-if="station.icon"143
:src="station.icon"144
:alt="station.name"145
class="w-full h-full object-contain select-none pointer-events-none"146
>145
</v-icon>147
<v-icon148
v-else149
id="access-point"150
size="38px"151
class="text-gray-400 pointer-events-none"152
></v-icon>153
</div>154
<div155
class="w-full flex flex-col bg-zinc-800 pb-6 rounded-t-2xl fixed left-0 right-0 bottom-0 px-4 pt-4 h-[70vh] transition-transform duration-300 ease-in-out"
1
import VIcon from '../element/icon.js';3
export default {4
props: ['id', 'value'],5
components: {6
VIcon,7
},8
methods: {9
onChange(event) {10
this.$emit('input', this.value);11
this.$emit('change', this.value);12
}13
},14
template: `15
<div class="relative w-full">16
<select17
v-model="value"18
:id="id"19
autocomplete="off"20
@change="onChange"21
class="rounded-md w-full h-[52px] px-4 text-md bg-zinc-900 text-white outline-none appearance-none cursor-pointer pr-[52px]"22
>23
<slot></slot>24
</select>25
<div class="absolute top-0 right-0 w-[52px] h-[52px] select-none pointer-events-none">26
<v-icon id="chevron-down" class="text-white"></v-icon>27
</div>28
</div>29
`30
}
19
v-if="icon"20
:id="icon"21
:class="[ active ? 'text-gray-100' : 'text-gray-400', text ? 'group-hover:text-gray-700' : '', animation ]"22
class="hover:text-gray-700"22
class="hover:text-gray-800"23
></v-icon>24
<slot v-else></slot>25
<p26
v-if="text"27
:class="[ active ? 'text-gray-100' : 'text-gray-400' ]"28
class="group-hover:text-gray-700 transition-colors -ml-[6px] pr-4 font-medium overflow-hidden text-ellipsis whitespace-nowrap"28
class="group-hover:text-gray-800 transition-colors -ml-[6px] pr-4 font-medium overflow-hidden text-ellipsis whitespace-nowrap"29
>30
{{text}}31
</p>
1
import {$lang, http} from '../utils.js';2
import VTab from '../component/tab.js';3
import VSelect from '../component/select.js';4
import VButton from '../element/button.js';6
export default {7
props: ['state'],
13
};14
},15
components: {14
VTab16
VTab,17
VSelect,18
VButton19
},20
methods: {21
$lang,
62
<div class="flex flex-col gap-2">63
<label for="language" class="text-white text-md">{{$lang('account.language')}}</label>64
<span class="text-gray-400 text-sm">{{$lang('account.language.info')}}</span>61
<select62
v-model="language"65
<v-select66
id="language"64
autocomplete="off"67
v-model="language"68
@change="updateAccount('language', language)"66
class="rounded-md w-full h-[52px] px-4 mt-2 text-md bg-zinc-900 text-white placeholder:text-gray-500 focus:placeholder:text-gray-600 outline-none appearance-none"69
class="mt-2"70
>71
<option value="en">English</option>72
<option value="de">Deutsch</option>70
</select>73
</v-select>74
</div>75
</div>76
</div>74
<div v-if="state.devices">77
<div v-if="state.devices" class="flex flex-col">78
<h3 class="text-white text-[24px] font-bold pb-6 pt-4 sm:pt-0">{{$lang('account.devices')}}</h3>79
<ul class="flex flex-col gap-4">77
<li v-for="device in state.devices" class="w-full rounded-md bg-zinc-900 p-5 flex flex-col gap-1">80
<li v-for="device in state.devices" class="w-full rounded-md bg-zinc-900 p-5 flex flex-col gap-1 cursor-pointer">81
<p class="text-md text-white flex justify-between items-center">82
{{device.name ?? $lang('account.devices.unknown')}}83
<span
90
<p class="text-sm text-gray-500">{{device.uid}}</p>91
</li>92
</ul>93
<v-button94
icon="plus"95
:text="$lang('account.devices.add')"96
class="mt-4 mx-auto"97
></v-button>98
</div>99
<div>92
<p class="text-md text-gray-400 text-center">Verbal</p>93
<p class="text-md text-gray-400 text-center">{{state.version}}</p>94
<p class="text-md text-gray-400 text-center pt-2">100
<p class="text-sm text-gray-400 text-center">Verbal - {{state.version}}</p>101
<p class="text-sm text-gray-400 text-center pt-1">102
Created by103
<a class="text-gray-200" href="https://github.com/typable" target="_blank">@typable</a>104
</p>
37
"account.player": "Player",38
"account.playback-history": "Show Playback History",39
"account.playback-history.info": "Displays the recently played songs for the current station",40
"account.devices": "Linked devices",40
"account.devices": "Devices",41
"account.devices.unknown": "Unknown device",42
"account.devices.current": "Current"42
"account.devices.current": "Current",43
"account.devices.add": "Add device"44
},45
"de": {46
"global.none": "-",
80
"account.player": "Wiedergabe",81
"account.playback-history": "Wiedergabeverlauf anzeigen",82
"account.playback-history.info": "Zeigt die zuletzt gespielten Songs für den aktuellen Sender an",82
"account.devices": "Verbundene Geräte",83
"account.devices": "Geräte",84
"account.devices.unknown": "Unbekanntes Gerät",84
"account.devices.current": "Aktuelles"85
"account.devices.current": "Aktuelles",86
"account.devices.add": "Gerät hinzufügen"87
}88
}