2016-11-06 18:28:37 +00:00
|
|
|
<template>
|
2020-11-24 10:32:42 +00:00
|
|
|
<label
|
2020-05-07 13:10:53 +00:00
|
|
|
class="media-upload"
|
|
|
|
:class="{ disabled: disabled }"
|
2020-11-24 10:32:42 +00:00
|
|
|
:title="$t('tool_tip.media_upload')"
|
2020-05-07 13:10:53 +00:00
|
|
|
>
|
2020-11-24 10:32:42 +00:00
|
|
|
<FAIcon
|
|
|
|
v-if="uploading"
|
|
|
|
class="progress-icon"
|
|
|
|
icon="circle-notch"
|
|
|
|
spin
|
|
|
|
/>
|
|
|
|
<FAIcon
|
|
|
|
v-if="!uploading"
|
|
|
|
class="new-icon"
|
|
|
|
icon="upload"
|
|
|
|
/>
|
|
|
|
<input
|
|
|
|
v-if="uploadReady"
|
|
|
|
:disabled="disabled"
|
|
|
|
type="file"
|
2022-04-19 19:22:16 +00:00
|
|
|
style="position: fixed; top: -100em; max-width: 0; max-height: 0"
|
2020-11-24 10:32:42 +00:00
|
|
|
multiple="true"
|
|
|
|
@change="change"
|
2019-07-05 07:17:44 +00:00
|
|
|
>
|
2020-11-24 10:32:42 +00:00
|
|
|
</label>
|
2016-11-06 18:28:37 +00:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<script src="./media_upload.js" ></script>
|
|
|
|
|
2019-11-11 19:45:40 +00:00
|
|
|
<style lang="scss">
|
2020-05-07 13:10:53 +00:00
|
|
|
@import '../../_variables.scss';
|
|
|
|
|
2019-09-15 09:28:52 +00:00
|
|
|
.media-upload {
|
2022-04-20 20:22:51 +00:00
|
|
|
cursor: pointer; // We use <label> for interactivity... i wonder if it's fine
|
2019-09-15 09:28:52 +00:00
|
|
|
}
|
2019-11-11 19:45:40 +00:00
|
|
|
</style>
|