Nahled pred uploadem
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
import FormWrapper from "components/FormWrapper.vue";
|
||||
import {reactive} from "vue";
|
||||
import ComboboxInput from "components/inputs/ComboboxInput.vue";
|
||||
import {roundWithPrecision} from "../../../composables/utils";
|
||||
|
||||
const props = defineProps({
|
||||
flight: {
|
||||
@@ -17,6 +18,10 @@ const props = defineProps({
|
||||
const formData = reactive({
|
||||
photos: []
|
||||
});
|
||||
|
||||
const inlinePreview = (photo) => {
|
||||
return URL.createObjectURL(photo);
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
@@ -26,6 +31,18 @@ const formData = reactive({
|
||||
align: "left"
|
||||
}'>
|
||||
|
||||
<div class="flex flex-center">
|
||||
<div v-for="photo in formData.photos" :key="photo.name" style="width: 70px" class="q-ma-sm">
|
||||
<q-img
|
||||
:src="inlinePreview(photo)"
|
||||
fit="fill"
|
||||
>
|
||||
<div class="absolute-top absolute-bottom text-center" v-if="isRequestPending">
|
||||
<q-spinner/>
|
||||
</div>
|
||||
</q-img>
|
||||
</div>
|
||||
</div>
|
||||
<q-file
|
||||
class="q-my-lg"
|
||||
outlined
|
||||
|
||||
Reference in New Issue
Block a user