aboutsummaryrefslogtreecommitdiff
path: root/viewer/src/components
diff options
context:
space:
mode:
Diffstat (limited to 'viewer/src/components')
-rw-r--r--viewer/src/components/LdBreadcrumb.vue7
-rw-r--r--viewer/src/components/LdCommand.vue5
-rw-r--r--viewer/src/components/LdCommandSort.vue2
-rw-r--r--viewer/src/components/LdGallery.vue6
-rw-r--r--viewer/src/components/LdInformation.vue5
-rw-r--r--viewer/src/components/LdKeyPress.vue2
-rw-r--r--viewer/src/components/LdProposition.vue9
-rw-r--r--viewer/src/components/LdTagInput.vue4
-rw-r--r--viewer/src/components/LdThumbnail.vue5
-rw-r--r--viewer/src/components/LdTitle.vue5
-rw-r--r--viewer/src/components/item_handlers/LdAudioViewer.vue5
-rw-r--r--viewer/src/components/item_handlers/LdDirectoryViewer.vue (renamed from viewer/src/components/item_handlers/LdDirectory.vue)7
-rw-r--r--viewer/src/components/item_handlers/LdDownloadViewer.vue (renamed from viewer/src/components/item_handlers/LdDownload.vue)7
-rw-r--r--viewer/src/components/item_handlers/LdPdfViewer.vue3
-rw-r--r--viewer/src/components/item_handlers/LdPictureViewer.vue (renamed from viewer/src/components/item_handlers/LdPicture.vue)9
-rw-r--r--viewer/src/components/item_handlers/LdPlainTextViewer.vue3
-rw-r--r--viewer/src/components/item_handlers/LdVideoViewer.vue3
17 files changed, 49 insertions, 38 deletions
diff --git a/viewer/src/components/LdBreadcrumb.vue b/viewer/src/components/LdBreadcrumb.vue
index 618b15a..2c17554 100644
--- a/viewer/src/components/LdBreadcrumb.vue
+++ b/viewer/src/components/LdBreadcrumb.vue
@@ -47,13 +47,14 @@
47</template> 47</template>
48 48
49<script lang="ts"> 49<script lang="ts">
50import { Component, Vue, Ref, Watch, Prop } from "vue-property-decorator"; 50import { Item } from "@/@types/gallery";
51import DragScrollClickFix from "@/services/dragscrollclickfix"; 51import DragScrollClickFix from "@/services/dragscrollclickfix";
52import Navigation from "@/services/navigation"; 52import Navigation from "@/services/navigation";
53import { Component, Prop, Ref, Vue, Watch } from "vue-property-decorator";
53 54
54@Component 55@Component
55export default class LdBreadcrumb extends Vue { 56export default class LdBreadcrumb extends Vue {
56 @Prop({ type: Array, required: true }) readonly currentItemPath!: Gallery.Item[]; 57 @Prop({ type: Array, required: true }) readonly currentItemPath!: Item[];
57 @Prop(Boolean) readonly searchMode!: boolean; 58 @Prop(Boolean) readonly searchMode!: boolean;
58 @Ref() readonly breadcrumb!: HTMLUListElement; 59 @Ref() readonly breadcrumb!: HTMLUListElement;
59 60
@@ -82,7 +83,7 @@ export default class LdBreadcrumb extends Vue {
82 }); 83 });
83 } 84 }
84 85
85 getIcon(item: Gallery.Item) { 86 getIcon(item: Item) {
86 return Navigation.getIcon(item); 87 return Navigation.getIcon(item);
87 } 88 }
88} 89}
diff --git a/viewer/src/components/LdCommand.vue b/viewer/src/components/LdCommand.vue
index 5ba8266..7ffa670 100644
--- a/viewer/src/components/LdCommand.vue
+++ b/viewer/src/components/LdCommand.vue
@@ -40,12 +40,13 @@
40</template> 40</template>
41 41
42<script lang="ts"> 42<script lang="ts">
43import { Component, Vue, Prop } from "vue-property-decorator"; 43import { Item } from "@/@types/gallery";
44import { Component, Prop, Vue } from "vue-property-decorator";
44import { RawLocation } from "vue-router"; 45import { RawLocation } from "vue-router";
45 46
46@Component 47@Component
47export default class LdCommand extends Vue { 48export default class LdCommand extends Vue {
48 @Prop({ type: Array, required: true }) readonly currentItemPath!: Gallery.Item[]; 49 @Prop({ type: Array, required: true }) readonly currentItemPath!: Item[];
49 50
50 get commandToggleSearchPanelIcon(): string { 51 get commandToggleSearchPanelIcon(): string {
51 return this.$uiStore.fullWidth ? "search" : "angle-double-left"; 52 return this.$uiStore.fullWidth ? "search" : "angle-double-left";
diff --git a/viewer/src/components/LdCommandSort.vue b/viewer/src/components/LdCommandSort.vue
index 4c246e6..c8a822e 100644
--- a/viewer/src/components/LdCommandSort.vue
+++ b/viewer/src/components/LdCommandSort.vue
@@ -32,8 +32,8 @@
32</template> 32</template>
33 33
34<script lang="ts"> 34<script lang="ts">
35import { Component, Vue, Prop } from "vue-property-decorator";
36import ItemComparators, { ItemSort } from "@/services/itemComparators"; 35import ItemComparators, { ItemSort } from "@/services/itemComparators";
36import { Component, Vue } from "vue-property-decorator";
37 37
38@Component 38@Component
39export default class LdCommandSort extends Vue { 39export default class LdCommandSort extends Vue {
diff --git a/viewer/src/components/LdGallery.vue b/viewer/src/components/LdGallery.vue
index edd479c..1443927 100644
--- a/viewer/src/components/LdGallery.vue
+++ b/viewer/src/components/LdGallery.vue
@@ -27,12 +27,12 @@
27</template> 27</template>
28 28
29<script lang="ts"> 29<script lang="ts">
30import { Component, Vue, Prop, Model } from "vue-property-decorator"; 30import { Item } from "@/@types/gallery";
31import DragScrollClickFix from "@/services/dragscrollclickfix"; 31import { Component, Prop, Vue } from "vue-property-decorator";
32 32
33@Component 33@Component
34export default class LdPicture extends Vue { 34export default class LdPicture extends Vue {
35 @Prop({ type: Array, required: true }) readonly items!: Gallery.Item[]; 35 @Prop({ type: Array, required: true }) readonly items!: Item[];
36 @Prop(String) readonly noresult?: string; 36 @Prop(String) readonly noresult?: string;
37 37
38 get sortedItems() { 38 get sortedItems() {
diff --git a/viewer/src/components/LdInformation.vue b/viewer/src/components/LdInformation.vue
index 66ccc80..b161485 100644
--- a/viewer/src/components/LdInformation.vue
+++ b/viewer/src/components/LdInformation.vue
@@ -26,12 +26,13 @@
26</template> 26</template>
27 27
28<script lang="ts"> 28<script lang="ts">
29import { Component, Vue, Prop } from "vue-property-decorator"; 29import { Item } from "@/@types/gallery";
30import marked from "marked"; 30import marked from "marked";
31import { Component, Prop, Vue } from "vue-property-decorator";
31 32
32@Component 33@Component
33export default class LdInformation extends Vue { 34export default class LdInformation extends Vue {
34 @Prop({ required: true }) readonly item!: Gallery.Item; 35 @Prop({ required: true }) readonly item!: Item;
35 36
36 get formatDate() { 37 get formatDate() {
37 const date = this.item.datetime.substr(0, 10); 38 const date = this.item.datetime.substr(0, 10);
diff --git a/viewer/src/components/LdKeyPress.vue b/viewer/src/components/LdKeyPress.vue
index c507b33..151d6c6 100644
--- a/viewer/src/components/LdKeyPress.vue
+++ b/viewer/src/components/LdKeyPress.vue
@@ -18,7 +18,7 @@
18--> 18-->
19 19
20<script lang="ts"> 20<script lang="ts">
21import { Component, Vue, Prop, Emit } from "vue-property-decorator"; 21import { Component, Emit, Prop, Vue } from "vue-property-decorator";
22 22
23@Component 23@Component
24export default class LdKeyPress extends Vue { 24export default class LdKeyPress extends Vue {
diff --git a/viewer/src/components/LdProposition.vue b/viewer/src/components/LdProposition.vue
index aa44943..2396d1f 100644
--- a/viewer/src/components/LdProposition.vue
+++ b/viewer/src/components/LdProposition.vue
@@ -54,8 +54,9 @@
54</template> 54</template>
55 55
56<script lang="ts"> 56<script lang="ts">
57import { Component, Vue, Prop, PropSync, Watch } from "vue-property-decorator"; 57import { Item, RawTag } from "@/@types/gallery";
58import { Operation } from "@/@types/Operation"; 58import { Operation } from "@/@types/Operation";
59import { Component, Prop, PropSync, Vue, Watch } from "vue-property-decorator";
59 60
60@Component 61@Component
61export default class LdProposition extends Vue { 62export default class LdProposition extends Vue {
@@ -118,16 +119,16 @@ export default class LdProposition extends Vue {
118 return this.category?.tag ?? this.$t("panelLeft.propositions.other"); 119 return this.category?.tag ?? this.$t("panelLeft.propositions.other");
119 } 120 }
120 121
121 extractDistinctItems(currentTags: Tag.Search[]): Gallery.Item[] { 122 extractDistinctItems(currentTags: Tag.Search[]): Item[] {
122 return [...new Set(currentTags.flatMap(tag => tag.items))]; 123 return [...new Set(currentTags.flatMap(tag => tag.items))];
123 } 124 }
124 125
125 rightmost(tag: Gallery.RawTag): Gallery.RawTag { 126 rightmost(tag: RawTag): RawTag {
126 const dot = tag.lastIndexOf(":"); 127 const dot = tag.lastIndexOf(":");
127 return dot <= 0 ? tag : tag.substr(dot + 1); 128 return dot <= 0 ? tag : tag.substr(dot + 1);
128 } 129 }
129 130
130 add(operation: Operation, rawTag: Gallery.RawTag) { 131 add(operation: Operation, rawTag: RawTag) {
131 const node = this.tagsIndex[rawTag]; 132 const node = this.tagsIndex[rawTag];
132 const display = this.category ? `${operation}${this.category.tag}:${node.tag}` : `${operation}${node.tag}`; 133 const display = this.category ? `${operation}${this.category.tag}:${node.tag}` : `${operation}${node.tag}`;
133 this.model.push({ ...node, parent: this.category, operation, display }); 134 this.model.push({ ...node, parent: this.category, operation, display });
diff --git a/viewer/src/components/LdTagInput.vue b/viewer/src/components/LdTagInput.vue
index ce83ba8..ef585f0 100644
--- a/viewer/src/components/LdTagInput.vue
+++ b/viewer/src/components/LdTagInput.vue
@@ -40,10 +40,8 @@
40</template> 40</template>
41 41
42<script lang="ts"> 42<script lang="ts">
43import { Component, Vue, Prop, PropSync, Emit } from "vue-property-decorator";
44import { Operation } from "@/@types/Operation";
45import Navigation from "@/services/navigation";
46import IndexFactory from "@/services/indexfactory"; 43import IndexFactory from "@/services/indexfactory";
44import { Component, Emit, Prop, PropSync, Vue } from "vue-property-decorator";
47 45
48@Component 46@Component
49export default class LdTagInput extends Vue { 47export default class LdTagInput extends Vue {
diff --git a/viewer/src/components/LdThumbnail.vue b/viewer/src/components/LdThumbnail.vue
index 5b1bc82..3f67a43 100644
--- a/viewer/src/components/LdThumbnail.vue
+++ b/viewer/src/components/LdThumbnail.vue
@@ -37,12 +37,13 @@
37</template> 37</template>
38 38
39<script lang="ts"> 39<script lang="ts">
<