From 5ab39aee24c0d48b0833b770e88257e29a7de7b8 Mon Sep 17 00:00:00 2001 From: Legendword Date: Sun, 6 Nov 2022 12:13:52 -0800 Subject: [PATCH 1/6] Fix typo in TapestryMedia css --- templates/vue/src/components/Lightbox/media/TapestryMedia.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/vue/src/components/Lightbox/media/TapestryMedia.vue b/templates/vue/src/components/Lightbox/media/TapestryMedia.vue index 85d0e33db..d26b1922c 100644 --- a/templates/vue/src/components/Lightbox/media/TapestryMedia.vue +++ b/templates/vue/src/components/Lightbox/media/TapestryMedia.vue @@ -175,7 +175,7 @@ export default { .media-wrapper { overflow: auto; height: 100%; - widows: 100%; + width: 100%; padding: 0; &:not(.context-multi-content) { From baa1cd39df6f71d583b592094f439ac045fe8fa6 Mon Sep 17 00:00:00 2001 From: Legendword Date: Sun, 6 Nov 2022 14:59:26 -0800 Subject: [PATCH 2/6] Add button to show node information in lightbox --- .../vue/src/components/Lightbox/index.vue | 84 +++++++++++++++++ .../vue/src/components/Sidebar/index.vue | 50 +--------- .../vue/src/components/common/NodeLicense.vue | 92 +++++++++++++++++++ 3 files changed, 179 insertions(+), 47 deletions(-) create mode 100644 templates/vue/src/components/common/NodeLicense.vue diff --git a/templates/vue/src/components/Lightbox/index.vue b/templates/vue/src/components/Lightbox/index.vue index 1e035186e..46a5a5e6f 100644 --- a/templates/vue/src/components/Lightbox/index.vue +++ b/templates/vue/src/components/Lightbox/index.vue @@ -41,6 +41,16 @@ tabindex="0" @clicked="toggleFavourite(node.id)" /> +
+
+

{{ node.title }}

+
+

About

+
+
+ +
+

References

+
+
+
-
-

- License -

-

- - - {{ license.name }} - - - - - - - - {{ license.name }} - -

-
-
+

References

@@ -119,8 +92,8 @@ import { mapGetters } from "vuex" import { names } from "@/config/routes" import Helpers from "@/utils/Helpers" import { nodeStatus } from "@/utils/constants" -import { licenseTypes, licenses } from "@/utils/constants" import * as wp from "@/services/wp" +import NodeLicense from "@/components/common/NodeLicense" import TapestryIcon from "@/components/common/TapestryIcon" import NodeReview from "./NodeReview" @@ -132,6 +105,7 @@ export default { components: { NodeReview, TapestryIcon, + NodeLicense, }, computed: { ...mapGetters(["getNode"]), @@ -160,15 +134,6 @@ export default { canEdit() { return Helpers.hasPermission(this.node, "edit") }, - licenseTypes() { - return licenseTypes - }, - license() { - return { - ...this.node.license, - ...licenses[this.node.license.type], - } - }, isReviewParticipant() { if (wp.canEditTapestry()) { return this.node.reviewStatus @@ -486,15 +451,6 @@ export default { color: #fff; } } - - .license-link { - color: white; - text-transform: capitalize; - font-weight: 600; - i { - margin-right: 4px; - } - } } } } diff --git a/templates/vue/src/components/common/NodeLicense.vue b/templates/vue/src/components/common/NodeLicense.vue new file mode 100644 index 000000000..cf542616d --- /dev/null +++ b/templates/vue/src/components/common/NodeLicense.vue @@ -0,0 +1,92 @@ + + + + + From 263b761c3282ac6deca54be7d46053f2a7318cdc Mon Sep 17 00:00:00 2001 From: Legendword Date: Thu, 10 Nov 2022 09:51:41 -0800 Subject: [PATCH 3/6] Remove unused data-name attributes in Sidebar --- templates/vue/src/components/Sidebar/index.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/vue/src/components/Sidebar/index.vue b/templates/vue/src/components/Sidebar/index.vue index 49da71083..91c4f9f96 100644 --- a/templates/vue/src/components/Sidebar/index.vue +++ b/templates/vue/src/components/Sidebar/index.vue @@ -49,7 +49,7 @@ tabindex="0" :class="['sidebar', { closed: closed }]" > -
-
+

References

-
+

Review

From dcfacc1b7f6302935435e0842de700ae95de241b Mon Sep 17 00:00:00 2001 From: Legendword Date: Thu, 10 Nov 2022 13:25:01 -0800 Subject: [PATCH 4/6] Revert "Remove unused data-name attributes in Sidebar" This reverts commit 263b761c3282ac6deca54be7d46053f2a7318cdc. --- templates/vue/src/components/Sidebar/index.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/vue/src/components/Sidebar/index.vue b/templates/vue/src/components/Sidebar/index.vue index 91c4f9f96..49da71083 100644 --- a/templates/vue/src/components/Sidebar/index.vue +++ b/templates/vue/src/components/Sidebar/index.vue @@ -49,7 +49,7 @@ tabindex="0" :class="['sidebar', { closed: closed }]" > -
-
+

References

-
+

Review

From 9c9dbd5e7bdebc6298be1141b9904924433f182d Mon Sep 17 00:00:00 2001 From: Legendword Date: Sat, 26 Nov 2022 19:18:08 -0800 Subject: [PATCH 5/6] Fix tests by using vue transition for node information sheet --- .../vue/src/components/Lightbox/index.vue | 42 +++++++++---------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/templates/vue/src/components/Lightbox/index.vue b/templates/vue/src/components/Lightbox/index.vue index 46a5a5e6f..1f9c09931 100644 --- a/templates/vue/src/components/Lightbox/index.vue +++ b/templates/vue/src/components/Lightbox/index.vue @@ -62,23 +62,20 @@ />
-
-

{{ node.title }}

-
-

About

-
-
- -
-

References

-
-
-
+ +
+

{{ node.title }}

+
+

About

+
+
+ +
+

References

+
+
+
+
Date: Sat, 26 Nov 2022 19:26:40 -0800 Subject: [PATCH 6/6] Fix tests by using v-if to display information sheet --- templates/vue/src/components/Lightbox/index.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/vue/src/components/Lightbox/index.vue b/templates/vue/src/components/Lightbox/index.vue index 1f9c09931..c6c076649 100644 --- a/templates/vue/src/components/Lightbox/index.vue +++ b/templates/vue/src/components/Lightbox/index.vue @@ -63,7 +63,7 @@
-
+

{{ node.title }}

About