so://phie

verbal

A mobile app for listening to radio stations from around the globe
git clone git://soophie.de/verbal

blob: 6bb4efb2fc97210c38d4ad40b191f21b9a6bcffd (1730 bytes)[doc][blame][raw]

1import {$lang, $route} from '../utils.js';

2import VButton from '../element/button.js';

3

4export default {

5 props: ['state'],

6 components: {

7 VButton

8 },

9 methods: {

10 $lang,

11 $route

12 },

13 template: `

14 <div v-if="state.tab !== 'auth'" class="sticky top-0 z-30 -mb-2">

15 <div class="flex bg-black py-6 gap-4">

16 <div class="flex flex-1 gap-4">

17 <v-button

18 icon="search"

19 :title="$lang('global.search')"

20 :active="state.tab === 'search'"

21 @click="$route('/search')"

22 ></v-button>

23 <v-button

24 icon="bookmarks"

25 :title="$lang('global.favorites')"

26 :active="state.tab === 'favorites'"

27 @click="$route('/favorites')"

28 ></v-button>

29 </div>

30 <v-button

31 v-if="state.authenticated"

32 :text="state.account?.name"

33 icon="user"

34 :title="$lang('global.account')"

35 :active="state.tab === 'account'"

36 @click="$route('/account')"

37 ></v-button>

38 <v-button

39 v-else

40 :text="$lang('global.register')"

41 icon="login"

42 active="true"

43 @click="$route('/auth')"

44 class="btn-icon-rotate"

45 ></v-button>

46 </div>

47 <div class="w-full h-2 bg-gradient-to-b from-black to-transparent"></div>

48 </div>

49 `

50}