chore: Cache the dashboard app on the first load (#6774)

This commit is contained in:
Pranav Raj S
2023-04-18 19:44:57 -07:00
committed by GitHub
parent c5c36af529
commit e6505fc7a4
2 changed files with 19 additions and 5 deletions

View File

@@ -23,7 +23,7 @@
:show-badge="false"
/>
</woot-tabs>
<div v-if="!activeIndex" class="messages-and-sidebar">
<div v-show="!activeIndex" class="messages-and-sidebar">
<messages-view
v-if="currentChat.id"
:inbox-id="inboxId"
@@ -41,9 +41,11 @@
</div>
</div>
<dashboard-app-frame
v-else
:key="currentChat.id + '-' + activeIndex"
:config="dashboardApps[activeIndex - 1].content"
v-for="(dashboardApp, index) in dashboardApps"
v-show="activeIndex - 1 === index"
:key="currentChat.id + '-' + dashboardApp.id"
:is-visible="activeIndex - 1 === index"
:config="dashboardApps[index].content"
:current-chat="currentChat"
/>
</div>