From a383b904309112c884d1d02c2f0fd399a4229cf8 Mon Sep 17 00:00:00 2001 From: Andrey Sobolev Date: Wed, 9 Feb 2022 16:06:53 +0700 Subject: [PATCH] Fix navigator extra space issue (#981) Signed-off-by: Andrey Sobolev --- .../workbench-resources/src/components/Navigator.svelte | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/workbench-resources/src/components/Navigator.svelte b/plugins/workbench-resources/src/components/Navigator.svelte index 21d6ac5c63..0d262e7991 100644 --- a/plugins/workbench-resources/src/components/Navigator.svelte +++ b/plugins/workbench-resources/src/components/Navigator.svelte @@ -55,10 +55,15 @@ specTopCount = topSpecials.length bottomSpecials = await getSpecials(model.specials, 'bottom', spaces) specBottomCount = bottomSpecials.length + } else { + topSpecials = [] + bottomSpecials = [] + specBottomCount = 0 + specTopCount = 0 } if (model.spaces) spModelCount = model.spaces.length shownSpaces = spaces.filter(sp => !sp.archived) - showDivider = (specTopCount > 0 && specBottomCount + spModelCount > 0) ? true : false + showDivider = !!((specTopCount > 0 && specBottomCount + spModelCount > 0)) } $: if (model) update(model, spaces)