From 3f21d10338afe8eab699aaaea060556579e4b3c3 Mon Sep 17 00:00:00 2001
From: Zero~Informatique
Date: Sat, 21 Dec 2019 10:33:21 +0100
Subject: viewer: Some renaming for better clarity Implemented a basic display
 of filenames with basic navigation

---
 viewer/src/views/MainLayout.vue | 100 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 100 insertions(+)
 create mode 100644 viewer/src/views/MainLayout.vue

(limited to 'viewer/src/views/MainLayout.vue')

diff --git a/viewer/src/views/MainLayout.vue b/viewer/src/views/MainLayout.vue
new file mode 100644
index 0000000..9f3a17b
--- /dev/null
+++ b/viewer/src/views/MainLayout.vue
@@ -0,0 +1,100 @@
+<template>
+  <div :class="{fullscreen: $uiStore.fullscreen}">
+    <div class="layout layout-top">header</div>
+    <div class="layout layout-left">panel</div>
+    <router-view class="layout layout-content" />
+    <ld-button-fullscreen />
+    <b-loading :active="isLoading" is-full-page />
+  </div>
+</template>
+
+<script lang="ts">
+import { Component, Vue } from "vue-property-decorator";
+
+@Component
+export default class MainLayout extends Vue {
+  isLoading: boolean = false;
+
+  mounted() {
+    this.fetchGalleryItems();
+  }
+
+  fetchGalleryItems() {
+    this.isLoading = true;
+    this.$galleryStore
+      .fetchGalleryItems("/gallery/index.json")
+      .finally(() => (this.isLoading = false))
+      .catch(this.displayError);
+  }
+
+  displayError(reason: any) {
+    this.$buefy.snackbar.open({
+      message: `Error ${reason}`,
+      actionText: "Retry",
+      position: "is-top",
+      type: "is-danger",
+      indefinite: true,
+      onAction: this.fetchGalleryItems,
+    });
+  }
+}
+</script>
+
+<style lang="scss">
+$layout-top: 30px;
+$layout-left: 250px;
+
+body,
+html {
+  height: 100%;
+  overflow: hidden;
+  --layout-top: #{$layout-top};
+  --layout-left: #{$layout-left};
+}
+.layout {
+  position: fixed;
+  transition: all 0.1s linear;
+  top: 0;
+  bottom: 0;
+  left: 0;
+  right: 0;
+  &.layout-top {
+    height: $layout-top;
+    z-index: 1;
+  }
+  &.layout-left {
+    top: $layout-top;
+    width: $layout-left;
+    z-index: 2;
+  }
+  &.layout-content {
+    top: var(--layout-top);
+    left: var(--layout-left);
+    z-index: 3;
+  }
+}
+.fullscreen {
+  --layout-left: 0px;
+  --layout-top: 0px;
+  .layout {
+    &.layout-left {
+      transform: translate(-$layout-left, 0);
+    }
+  }
+}
+
+// temp colors
+.layout {
+  &.layout-top {
+    background-color: darkslategray;
+    color: white;
+  }
+  &.layout-left {
+    background-color: darkblue;
+    color: white;
+  }
+  &.layout-content {
+    background-color: lightcyan;
+  }
+}
+</style>
\ No newline at end of file
-- 
cgit v1.2.3


From e34be1261d9219e5b2b92ebe271f609f11d55f63 Mon Sep 17 00:00:00 2001
From: Zero~Informatique
Date: Sun, 22 Dec 2019 03:50:40 +0100
Subject: vewer: Tags indexing and search input

---
 viewer/src/views/MainLayout.vue | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

(limited to 'viewer/src/views/MainLayout.vue')

diff --git a/viewer/src/views/MainLayout.vue b/viewer/src/views/MainLayout.vue
index 9f3a17b..2afd4b9 100644
--- a/viewer/src/views/MainLayout.vue
+++ b/viewer/src/views/MainLayout.vue
@@ -1,7 +1,7 @@
 <template>
   <div :class="{fullscreen: $uiStore.fullscreen}">
     <div class="layout layout-top">header</div>
-    <div class="layout layout-left">panel</div>
+    <panel-left class="layout layout-left" />
     <router-view class="layout layout-content" />
     <ld-button-fullscreen />
     <b-loading :active="isLoading" is-full-page />
@@ -10,8 +10,11 @@
 
 <script lang="ts">
 import { Component, Vue } from "vue-property-decorator";
+import PanelLeft from "./PanelLeft.vue";
 
-@Component
+@Component({
+  components: { PanelLeft },
+})
 export default class MainLayout extends Vue {
   isLoading: boolean = false;
 
-- 
cgit v1.2.3


From dc251fffc2998f1cf4f8e9631928c4b92ac0d90e Mon Sep 17 00:00:00 2001
From: Zero~Informatique
Date: Sun, 22 Dec 2019 07:40:55 +0100
Subject: viewer: Implemented the search by tags. Pushed the special urls to
 ENV.

---
 viewer/src/views/MainLayout.vue | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'viewer/src/views/MainLayout.vue')

diff --git a/viewer/src/views/MainLayout.vue b/viewer/src/views/MainLayout.vue
index 2afd4b9..2a87ff1 100644
--- a/viewer/src/views/MainLayout.vue
+++ b/viewer/src/views/MainLayout.vue
@@ -25,7 +25,7 @@ export default class MainLayout extends Vue {
   fetchGalleryItems() {
     this.isLoading = true;
     this.$galleryStore
-      .fetchGalleryItems("/gallery/index.json")
+      .fetchGalleryItems(`${process.env.VUE_APP_DATA_URL}/index.json`)
       .finally(() => (this.isLoading = false))
       .catch(this.displayError);
   }
-- 
cgit v1.2.3


From 89bcb2dbe5b5e6eb8e8ba13ceecee2770dfe4cd4 Mon Sep 17 00:00:00 2001
From: Zero~Informatique
Date: Thu, 9 Jan 2020 02:10:35 +0100
Subject: viewer: Changed "image" type to "picture". Adapted the code to the
 current compiler output format. The currentItem and currentPath are
 calculated in the store for easier multi-component access. Breadcrumb for
 current's position and navigation.

---
 viewer/src/views/MainLayout.vue | 19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)

(limited to 'viewer/src/views/MainLayout.vue')

diff --git a/viewer/src/views/MainLayout.vue b/viewer/src/views/MainLayout.vue
index 2a87ff1..d643e66 100644
--- a/viewer/src/views/MainLayout.vue
+++ b/viewer/src/views/MainLayout.vue
@@ -1,6 +1,6 @@
 <template>
   <div :class="{fullscreen: $uiStore.fullscreen}">
-    <div class="layout layout-top">header</div>
+    <panel-top class="layout layout-top" />
     <panel-left class="layout layout-left" />
     <router-view class="layout layout-content" />
     <ld-button-fullscreen />
@@ -11,9 +11,10 @@
 <script lang="ts">
 import { Component, Vue } from "vue-property-decorator";
 import PanelLeft from "./PanelLeft.vue";
+import PanelTop from "./PanelTop.vue";
 
 @Component({
-  components: { PanelLeft },
+  components: { PanelLeft, PanelTop },
 })
 export default class MainLayout extends Vue {
   isLoading: boolean = false;
@@ -44,8 +45,7 @@ export default class MainLayout extends Vue {
 </script>
 
 <style lang="scss">
-$layout-top: 30px;
-$layout-left: 250px;
+@import "@/assets/scss/theme.scss";
 
 body,
 html {
@@ -86,18 +86,17 @@ html {
   }
 }
 
-// temp colors
 .layout {
   &.layout-top {
-    background-color: darkslategray;
-    color: white;
+    background-color: $panel-top-bgcolor;
+    color: $panel-top-txtcolor;
   }
   &.layout-left {
-    background-color: darkblue;
-    color: white;
+    background-color: $panel-left-bgcolor;
+    color: $panel-left-txtcolor;
   }
   &.layout-content {
-    background-color: lightcyan;
+    background-color: $content-bgcolor;
   }
 }
 </style>
\ No newline at end of file
-- 
cgit v1.2.3


From 27b51018525dbb7a6edb3073819d82245387ddd3 Mon Sep 17 00:00:00 2001
From: Zero~Informatique
Date: Fri, 10 Jan 2020 22:22:22 +0100
Subject: viewer: license headers

---
 viewer/src/views/MainLayout.vue | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

(limited to 'viewer/src/views/MainLayout.vue')

diff --git a/viewer/src/views/MainLayout.vue b/viewer/src/views/MainLayout.vue
index d643e66..5308205 100644
--- a/viewer/src/views/MainLayout.vue
+++ b/viewer/src/views/MainLayout.vue
@@ -1,3 +1,22 @@
+<!-- ldgallery - A static generator which turns a collection of tagged
+--             pictures into a searchable web gallery.
+--
+-- Copyright (C) 2019-2020  Guillaume FOUET
+--
+-- This program is free software: you can redistribute it and/or modify
+-- it under the terms of the GNU Affero General Public License as
+-- published by the Free Software Foundation, either version 3 of the
+-- License, or (at your option) any later version.
+--
+-- This program is distributed in the hope that it will be useful,
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+-- GNU Affero General Public License for more details.
+--
+-- You should have received a copy of the GNU Affero General Public License
+-- along with this program.  If not, see <https://www.gnu.org/licenses/>.
+-->
+
 <template>
   <div :class="{fullscreen: $uiStore.fullscreen}">
     <panel-top class="layout layout-top" />
-- 
cgit v1.2.3

