From c9eb07317e75950f5cc9c5e09db41727928e36f2 Mon Sep 17 00:00:00 2001 From: Henrik Askjer <henrik.askjer@uib.no> Date: Wed, 12 Jan 2022 10:57:49 +0100 Subject: [PATCH] fix collapse bug --- src/components/Article.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/Article.vue b/src/components/Article.vue index a510e351..aba6fa12 100644 --- a/src/components/Article.vue +++ b/src/components/Article.vue @@ -100,8 +100,10 @@ export default { if (collapsable == 'auto') { this.is_collapsed = this.$parent.$options.name == 'SearchResults' && (this.$parent.results_bm.length + this.$parent.results_nn.length > 2) } + console.log(this.$parent.$options.name == 'SearchResults' && (this.$parent.results_bm.length + this.$parent.results_nn.length > 2)) - return this.$store.state.collapseArticles == 'always' || this.is_collapsed//getters.collapsable(this.$parent.$options.name, this.$parent.results_bm.length + this.$parent.results_nn.length) + + return this.$store.state.collapseArticles == 'always' || this.$parent.$options.name == 'SearchResults' && (this.$parent.results_bm.length + this.$parent.results_nn.length > 2)//getters.collapsable(this.$parent.$options.name, this.$parent.results_bm.length + this.$parent.results_nn.length) }, collapsed: { get() { -- GitLab