Skip to content

πŸ”₯ πŸ”₯ πŸ”₯ A Free & Self-hostable Airtable Alternative

fix: show loading while loading projects

Ramesh Mane4c1e57f6783a
diff --git a/packages/nc-gui/components/workspace/BaseListModal/index.vue b/packages/nc-gui/components/workspace/BaseListModal/index.vue
index 66906a61a6..8f1efbdeae 100644
--- a/packages/nc-gui/components/workspace/BaseListModal/index.vue
+++ b/packages/nc-gui/components/workspace/BaseListModal/index.vue
@@ -17,7 +17,7 @@ const basesStore = useBases()
const { workspacesList, activeWorkspaceId } = storeToRefs(workspaceStore)
-const { basesList } = storeToRefs(basesStore)
+const { basesList, isProjectsLoading } = storeToRefs(basesStore)
const { isMobileMode } = useGlobal()
@@ -205,7 +205,7 @@ const hasNoSearchResults = computed(() => {
</WorkspaceBaseListModalBasesHeader>
<!-- Bases Content - Loop-based rendering -->
- <div class="flex-1 overflow-y-auto nc-scrollbar-thin p-4 flex flex-col">
+ <div class="flex-1 overflow-y-auto nc-scrollbar-thin p-4 flex flex-col relative">
<WorkspaceBaseListModalBasesSection
v-for="section in displayedSections"
:key="section.type"
@@ -216,8 +216,23 @@ const hasNoSearchResults = computed(() => {
:is-base-private="baseCheckers.private"
/>
+ <GeneralOverlay
+ v-if="isProjectsLoading && emptyFilterResult"
+ :model-value="true"
+ inline
+ transition
+ class="!bg-opacity-15"
+ >
+ <div class="flex flex-col items-center justify-center h-full w-full">
+ <a-spin size="large" />
+ </div>
+ </GeneralOverlay>
+
<!-- Empty State -->
- <div v-if="emptyFilterResult" class="flex flex-col items-center justify-center h-full text-nc-content-gray-muted">
+ <div
+ v-else-if="emptyFilterResult"
+ class="flex flex-col items-center justify-center h-full text-nc-content-gray-muted"
+ >
<a-empty :image="Empty.PRESENTED_IMAGE_SIMPLE" :description="$t('activity.noBases')" />
</div>