filebrowser/frontend/src/components/prompts/Download.vue
Kloon ImKloon 7c91ba03b7
Migration to vue3 continued
Replace vuex with pinia
Fix some routing issues
Fix most vue3 breaking changes
2023-08-28 17:48:55 +02:00

46 lines
920 B
Vue

<template>
<div class="card floating" id="download">
<div class="card-title">
<h2>{{ $t("prompts.download") }}</h2>
</div>
<div class="card-content">
<p>{{ $t("prompts.downloadMessage") }}</p>
<button
v-for="(ext, format) in formats"
:key="format"
class="button button--block"
@click="showConfirm(format)"
v-focus
>
{{ ext }}
</button>
</div>
</div>
</template>
<script>
import { mapState } from "pinia";
import { useLayoutStore } from "@/stores/layout";
export default {
name: "download",
data: function () {
return {
formats: {
zip: "zip",
tar: "tar",
targz: "tar.gz",
tarbz2: "tar.bz2",
tarxz: "tar.xz",
tarlz4: "tar.lz4",
tarsz: "tar.sz",
},
};
},
computed: mapState(useLayoutStore, ["showConfirm"]),
};
</script>
@/stores/layout