@hostlink/nuxt-light 1.12.6 → 1.12.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/module.json
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
<script setup>
|
|
2
|
-
import { format } from "quasar"
|
|
2
|
+
import { format, useQuasar } from "quasar"
|
|
3
|
+
import { computed } from 'vue'
|
|
3
4
|
import { q } from '../';
|
|
4
5
|
const { humanStorageSize } = format
|
|
5
6
|
|
|
6
7
|
const props = defineProps(["modelValue"]);
|
|
8
|
+
const quasar = useQuasar()
|
|
7
9
|
|
|
8
10
|
|
|
9
11
|
const file = await q("fsFile", {
|
|
@@ -12,7 +14,27 @@ const file = await q("fsFile", {
|
|
|
12
14
|
|
|
13
15
|
const size = humanStorageSize(props.modelValue.size)
|
|
14
16
|
|
|
15
|
-
|
|
17
|
+
const full_url = computed(() => {
|
|
18
|
+
let url = window.location.protocol + '//' + window.location.hostname + (window.location.port ? ':' + window.location.port : '');
|
|
19
|
+
return url + props.modelValue.imagePath;
|
|
20
|
+
})
|
|
21
|
+
|
|
22
|
+
const copyToClipboard = (text) => {
|
|
23
|
+
navigator.clipboard.writeText(text).then(() => {
|
|
24
|
+
|
|
25
|
+
quasar.notify({
|
|
26
|
+
message: 'URL copied to clipboard',
|
|
27
|
+
color: 'positive',
|
|
28
|
+
position: 'top',
|
|
29
|
+
timeout: 1000,
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
}, (err) => {
|
|
33
|
+
console.error('Could not copy text: ', err);
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
</script>
|
|
16
38
|
<template>
|
|
17
39
|
<template v-if="file.canPreview">
|
|
18
40
|
<q-img :src="file.imagePath"></q-img>
|
|
@@ -48,6 +70,18 @@ const size = humanStorageSize(props.modelValue.size)
|
|
|
48
70
|
</q-item-section>
|
|
49
71
|
<q-item-section side>{{ modelValue.lastModifiedHuman }}</q-item-section>
|
|
50
72
|
</q-item>
|
|
73
|
+
<q-item>
|
|
74
|
+
<q-item-section>
|
|
75
|
+
<q-item-label>URL</q-item-label>
|
|
76
|
+
</q-item-section>
|
|
77
|
+
<q-item-section side>
|
|
78
|
+
<q-item-label lines="1">{{ full_url }}</q-item-label>
|
|
79
|
+
</q-item-section>
|
|
80
|
+
|
|
81
|
+
<q-item-section top side>
|
|
82
|
+
<q-btn size="md" flat danse round icon="sym_o_content_copy" @click="copyToClipboard(full_url)"></q-btn>
|
|
83
|
+
</q-item-section>
|
|
84
|
+
</q-item>
|
|
51
85
|
</q-list>
|
|
52
86
|
</template>
|
|
53
87
|
|
|
@@ -78,7 +78,7 @@ const columns = ref([
|
|
|
78
78
|
]);
|
|
79
79
|
|
|
80
80
|
const localSearch = ref(null);
|
|
81
|
-
|
|
81
|
+
const rightDrawerOpen = ref(false);
|
|
82
82
|
const leftDrawerOpen = ref(false);
|
|
83
83
|
const showDateOptions = ref(false);
|
|
84
84
|
const exactPhrase = ref("");
|
|
@@ -488,6 +488,11 @@ const onPreviewPDF = async (row) => {
|
|
|
488
488
|
})
|
|
489
489
|
}
|
|
490
490
|
|
|
491
|
+
const onClickInfo = async (row) => {
|
|
492
|
+
rightDrawerOpen.value = true;
|
|
493
|
+
|
|
494
|
+
}
|
|
495
|
+
|
|
491
496
|
</script>
|
|
492
497
|
<template>
|
|
493
498
|
<q-layout view="hHh lpR fFf" :class="isDark ? '' : 'bg-white'" container :style="{ 'min-height': height }">
|
|
@@ -569,7 +574,7 @@ const onPreviewPDF = async (row) => {
|
|
|
569
574
|
</q-scroll-area>
|
|
570
575
|
</q-drawer>
|
|
571
576
|
|
|
572
|
-
<q-drawer side="right" show-if-above bordered>
|
|
577
|
+
<q-drawer v-model="rightDrawerOpen" side="right" show-if-above bordered>
|
|
573
578
|
<l-file-manager-preview v-model="preview" v-if="preview" :key="preview.path" />
|
|
574
579
|
</q-drawer>
|
|
575
580
|
|
|
@@ -723,6 +728,13 @@ const onPreviewPDF = async (row) => {
|
|
|
723
728
|
<q-item-section>{{ $t('Preview') }}</q-item-section>
|
|
724
729
|
</q-item>
|
|
725
730
|
|
|
731
|
+
<q-item clickable v-close-popup @click="onClickInfo(props.row)" class="lt-lg">
|
|
732
|
+
<q-item-section avatar>
|
|
733
|
+
<q-icon name="sym_o_info"></q-icon>
|
|
734
|
+
</q-item-section>
|
|
735
|
+
<q-item-section>{{ $t('Info') }}</q-item-section>
|
|
736
|
+
</q-item>
|
|
737
|
+
|
|
726
738
|
</q-list>
|
|
727
739
|
</q-menu>
|
|
728
740
|
</q-btn>
|