From cbb9267259ea564367b2db7265f1712a320b655a Mon Sep 17 00:00:00 2001 From: Henrik Askjer <henrik.askjer@uib.no> Date: Mon, 13 Dec 2021 14:05:14 +0100 Subject: [PATCH] check parent name --- src/components/Article.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/Article.vue b/src/components/Article.vue index 3cfe1338..e468fcbc 100644 --- a/src/components/Article.vue +++ b/src/components/Article.vue @@ -76,13 +76,14 @@ export default { }, data: function() { return { - collapsed: this.$parent.results_bm.length > 1 || this.$parent.results_bm.length > 1 + collapsed: this.$parent.$options.name == 'SearchResults' && (this.$parent.results_bm.length + this.$parent.results_nn.length > 2) } }, computed: { collapsable: function() { - return this.$parent.results_bm.length > 1 || this.$parent.results_bm.length > 1 + console.log(this.$parent.$options.name) + return this.$parent.$options.name == 'SearchResults' && (this.$parent.results_bm.length + this.$parent.results_nn.length > 2) }, link_to_self: function() { -- GitLab