From d10e6a898765cf5945912497a3a49b7cb480ec5b Mon Sep 17 00:00:00 2001 From: Alicia Sykes Date: Sun, 9 Jan 2022 14:21:52 +0000 Subject: [PATCH] :bug: Fixes unable to add new app bug (#390) --- src/components/LinkItems/Section.vue | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/src/components/LinkItems/Section.vue b/src/components/LinkItems/Section.vue index 351bd60f..db3d73ee 100644 --- a/src/components/LinkItems/Section.vue +++ b/src/components/LinkItems/Section.vue @@ -12,11 +12,11 @@ @openContextMenu="openContextMenu" > -
+
{{ $t('home.no-items-section') }}
-
@@ -58,7 +58,7 @@ />
0) return 'widget'; - if (this.items && this.items.length > 0) return 'item'; - return 'empty'; + hasItems() { + if (this.isEditMode) return true; + return this.items && this.items.length > 0; + }, + hasWidgets() { + return this.widgets && this.widgets.length > 0; + }, + isEmpty() { + return !this.hasItems && !this.hasWidgets; }, /* If the sortBy attribute is specified, then return sorted data */ sortedItems() {