From 170d7a61f720ece9dc4b347b19f5a8213f1d8984 Mon Sep 17 00:00:00 2001 From: Zero~Informatique Date: Sat, 20 Jun 2020 16:50:49 +0200 Subject: viewer: prettier formatting based on eslint-prettier plugin --- viewer/src/@types/Operation.ts | 2 +- viewer/src/@types/gallery.d.ts | 89 +++++++++++----------- viewer/src/@types/scrollposition.d.ts | 2 +- viewer/src/components/LdBreadcrumb.vue | 4 +- viewer/src/components/LdCommand.vue | 4 +- viewer/src/components/LdCommandSearch.vue | 4 +- viewer/src/components/LdError.vue | 3 +- viewer/src/components/LdProposition.vue | 7 +- viewer/src/components/LdTagInput.vue | 4 +- viewer/src/components/LdThumbnail.vue | 8 +- viewer/src/components/index.ts | 15 ++-- .../src/components/item_handlers/LdAudioViewer.vue | 5 +- .../src/components/item_handlers/LdDirectory.vue | 3 +- .../src/components/item_handlers/LdPdfViewer.vue | 3 +- viewer/src/components/item_handlers/LdPicture.vue | 2 +- .../src/components/item_handlers/LdVideoViewer.vue | 11 +-- viewer/src/main.ts | 6 +- viewer/src/plugins/router.ts | 2 +- viewer/src/services/dragscrollclickfix.ts | 3 +- viewer/src/services/indexfactory.ts | 21 +++-- viewer/src/services/indexsearch.ts | 1 - viewer/src/services/ldzoom.ts | 6 +- viewer/src/services/navigation.ts | 24 +++--- viewer/src/shims-tsx.d.ts | 4 +- viewer/src/store/galleryStore.ts | 8 +- viewer/src/store/index.ts | 16 ++-- viewer/src/store/uiStore.ts | 5 +- viewer/src/views/GalleryNavigation.vue | 3 +- viewer/src/views/GallerySearch.vue | 3 +- viewer/src/views/MainLayout.vue | 7 +- viewer/src/views/PanelLeft.vue | 4 +- viewer/src/views/PanelTop.vue | 8 +- 32 files changed, 139 insertions(+), 148 deletions(-) (limited to 'viewer/src') diff --git a/viewer/src/@types/Operation.ts b/viewer/src/@types/Operation.ts index e7aad27..e566f4b 100644 --- a/viewer/src/@types/Operation.ts +++ b/viewer/src/@types/Operation.ts @@ -21,4 +21,4 @@ export enum Operation { INTERSECTION = "", ADDITION = "+", SUBSTRACTION = "-", -}; +} diff --git a/viewer/src/@types/gallery.d.ts b/viewer/src/@types/gallery.d.ts index 151ae92..1342ff9 100644 --- a/viewer/src/@types/gallery.d.ts +++ b/viewer/src/@types/gallery.d.ts @@ -19,90 +19,91 @@ declare namespace Gallery { interface Config { - galleryRoot: string, + galleryRoot: string; } interface GalleryProperties { - galleryTitle: string, - tagCategories: RawTag[] + galleryTitle: string; + tagCategories: RawTag[]; } interface Index { - properties: GalleryProperties, - tree: Directory + properties: GalleryProperties; + tree: Directory; } interface Other extends Item { - properties: OtherProperties, + properties: OtherProperties; } interface Picture extends Item { - properties: PictureProperties, + properties: PictureProperties; } interface PlainText extends Item { - properties: PlainTextProperties, + properties: PlainTextProperties; } interface PDF extends Item { - properties: PDFProperties, + properties: PDFProperties; } interface Video extends Item { - properties: VideoProperties, + properties: VideoProperties; } interface Audio extends Item { - properties: AudioProperties, + properties: AudioProperties; } interface Directory extends Item { - properties: DirectoryProperties, + properties: DirectoryProperties; } interface Item { - title: string, - datetime: string, - description: string, - tags: RawTag[], - path: string, - thumbnail?: Thumbnail - properties: OtherProperties - | PictureProperties - | PlainTextProperties - | PDFProperties - | VideoProperties - | AudioProperties - | DirectoryProperties, + title: string; + datetime: string; + description: string; + tags: RawTag[]; + path: string; + thumbnail?: Thumbnail; + properties: + | OtherProperties + | PictureProperties + | PlainTextProperties + | PDFProperties + | VideoProperties + | AudioProperties + | DirectoryProperties; } interface Resolution { - width: number, - height: number, + width: number; + height: number; } interface OtherProperties { - type: import("./ItemType").ItemType.OTHER, - resource: string + type: import("./ItemType").ItemType.OTHER; + resource: string; } interface PictureProperties { - type: import("./ItemType").ItemType.PICTURE, - resource: string, - resolution: Resolution + type: import("./ItemType").ItemType.PICTURE; + resource: string; + resolution: Resolution; } interface PlainTextProperties { - type: import("./ItemType").ItemType.PLAINTEXT, - resource: string, + type: import("./ItemType").ItemType.PLAINTEXT; + resource: string; } interface PDFProperties { - type: import("./ItemType").ItemType.PDF, - resource: string, + type: import("./ItemType").ItemType.PDF; + resource: string; } interface VideoProperties { - type: import("./ItemType").ItemType.VIDEO, - resource: string, + type: import("./ItemType").ItemType.VIDEO; + resource: string; } interface AudioProperties { - type: import("./ItemType").ItemType.AUDIO, - resource: string, + type: import("./ItemType").ItemType.AUDIO; + resource: string; } interface DirectoryProperties { - type: import("./ItemType").ItemType.DIRECTORY, - items: Item[] + type: import("./ItemType").ItemType.DIRECTORY; + items: Item[]; } interface Thumbnail { - resource: string, - resolution: Resolution + resource: string; + resolution: Resolution; } type RawTag = string; } diff --git a/viewer/src/@types/scrollposition.d.ts b/viewer/src/@types/scrollposition.d.ts index cd393b3..2f17515 100644 --- a/viewer/src/@types/scrollposition.d.ts +++ b/viewer/src/@types/scrollposition.d.ts @@ -17,4 +17,4 @@ -- along with this program. If not, see . */ -type ScrollPosition = Record +type ScrollPosition = Record; diff --git a/viewer/src/components/LdBreadcrumb.vue b/viewer/src/components/LdBreadcrumb.vue index a8d8dcb..618b15a 100644 --- a/viewer/src/components/LdBreadcrumb.vue +++ b/viewer/src/components/LdBreadcrumb.vue @@ -29,11 +29,11 @@ >
    -
  • +
  • - {{item.title}} + {{ item.title }}
  • diff --git a/viewer/src/components/LdCommand.vue b/viewer/src/components/LdCommand.vue index 49d86bb..d3705de 100644 --- a/viewer/src/components/LdCommand.vue +++ b/viewer/src/components/LdCommand.vue @@ -24,14 +24,14 @@ - + diff --git a/viewer/src/components/LdCommandSearch.vue b/viewer/src/components/LdCommandSearch.vue index ef158ff..33ab804 100644 --- a/viewer/src/components/LdCommandSearch.vue +++ b/viewer/src/components/LdCommandSearch.vue @@ -21,11 +21,11 @@
    - {{$t('command.search.clear')}} + {{ $t("command.search.clear") }} - {{$t('command.search.search')}} + {{ $t("command.search.search") }}
    diff --git a/viewer/src/components/LdError.vue b/viewer/src/components/LdError.vue index a53942d..c71e2ad 100644 --- a/viewer/src/components/LdError.vue +++ b/viewer/src/components/LdError.vue @@ -30,7 +30,8 @@ - + diff --git a/viewer/src/components/item_handlers/LdPdfViewer.vue b/viewer/src/components/item_handlers/LdPdfViewer.vue index 6471aac..462c463 100644 --- a/viewer/src/components/item_handlers/LdPdfViewer.vue +++ b/viewer/src/components/item_handlers/LdPdfViewer.vue @@ -42,5 +42,4 @@ export default class LdPdfViewer extends Vue { } - + diff --git a/viewer/src/components/item_handlers/LdPicture.vue b/viewer/src/components/item_handlers/LdPicture.vue index 3809e4d..e652afc 100644 --- a/viewer/src/components/item_handlers/LdPicture.vue +++ b/viewer/src/components/item_handlers/LdPicture.vue @@ -33,7 +33,7 @@ ref="imageElement" :src="pictureSrc(item.properties.resource)" class="ld-picture-element" - :class="{'slow-loading': Boolean(slowLoadingStyle)}" + :class="{ 'slow-loading': Boolean(slowLoadingStyle) }" :style="slowLoadingStyle" @load="clearSlowLoading" /> diff --git a/viewer/src/components/item_handlers/LdVideoViewer.vue b/viewer/src/components/item_handlers/LdVideoViewer.vue index 67203a5..2e3a43c 100644 --- a/viewer/src/components/item_handlers/LdVideoViewer.vue +++ b/viewer/src/components/item_handlers/LdVideoViewer.vue @@ -21,13 +21,7 @@