mirror of
https://codeberg.org/SafeTwitch/safetwitch.git
synced 2024-12-21 21:03:00 -05:00
feat(action-buttons): added new component for all action buttons
This commit is contained in:
parent
ca7b639a45
commit
43739a3537
1 changed files with 28 additions and 0 deletions
28
src/components/ActionButtons.vue
Normal file
28
src/components/ActionButtons.vue
Normal file
|
@ -0,0 +1,28 @@
|
|||
<template>
|
||||
<div class="space-x-1">
|
||||
<a v-if="showDownload" :href="downloadUrl" download>
|
||||
<button class="px-2 py-1.5 rounded-lg bg-purple">
|
||||
<v-icon name="md-download-round"></v-icon>
|
||||
</button>
|
||||
</a>
|
||||
<button v-if="showTheatreMode" @click="$emit('toggleTheatreMode')" class="invisible xl:visible px-2 py-1.5 rounded-lg bg-purple">
|
||||
<v-icon name="fa-expand"></v-icon>
|
||||
</button>
|
||||
<button v-if="showShare" @click="$emit('toggleShareModal')" class="px-2 py-1.5 rounded-lg bg-purple">
|
||||
<v-icon name="fa-share-alt"></v-icon>
|
||||
</button>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
export default {
|
||||
props: {
|
||||
showDownload: Boolean,
|
||||
showTheatreMode: Boolean,
|
||||
showShare: Boolean,
|
||||
downloadUrl: String
|
||||
},
|
||||
emits: ['toggleTheatreMode', 'toggleShareModal']
|
||||
}
|
||||
</script>
|
||||
|
Loading…
Reference in a new issue