From 29a43aee105293faef6ba365a4fe28bff20ea3f2 Mon Sep 17 00:00:00 2001 From: Pranav C Date: Sun, 12 Mar 2023 10:53:08 +0530 Subject: [PATCH] fix: wrap store with `storeToRefs` wherever missing Signed-off-by: Pranav C --- packages/nc-gui/components/cell/SingleSelect.vue | 4 ++-- .../components/dashboard/settings/DataSources.vue | 4 ++-- .../nc-gui/components/dashboard/settings/Misc.vue | 4 ++-- .../dashboard/settings/data-sources/CreateBase.vue | 3 ++- .../dashboard/settings/data-sources/EditBase.vue | 3 ++- packages/nc-gui/components/dlg/AirtableImport.vue | 3 ++- packages/nc-gui/components/dlg/TableRename.vue | 3 ++- packages/nc-gui/components/erd/View.vue | 4 ++-- .../nc-gui/components/general/HelpAndSupport.vue | 4 ++-- packages/nc-gui/components/general/MiniSidebar.vue | 4 ++-- .../nc-gui/components/smartsheet/ApiSnippet.vue | 3 ++- .../column/LinkedToAnotherRecordOptions.vue | 4 ++-- .../components/smartsheet/column/LookupOptions.vue | 4 ++-- .../components/smartsheet/column/RollupOptions.vue | 4 ++-- .../smartsheet/toolbar/ExportSubActions.vue | 3 ++- .../components/smartsheet/toolbar/FilterInput.vue | 4 +++- .../components/smartsheet/toolbar/MoreActions.vue | 3 ++- .../components/smartsheet/toolbar/RowHeight.vue | 4 ++-- .../components/smartsheet/toolbar/ShareView.vue | 3 ++- .../components/smartsheet/toolbar/ViewActions.vue | 3 ++- .../components/tabs/auth/ApiTokenManagement.vue | 4 ++-- .../nc-gui/components/tabs/auth/UserManagement.vue | 3 ++- .../tabs/auth/user-management/ShareBase.vue | 14 ++++++++++++-- .../tabs/auth/user-management/UsersModal.vue | 3 ++- packages/nc-gui/components/template/Editor.vue | 5 ++++- .../nc-gui/composables/useColumnCreateStore.ts | 5 ++++- .../nc-gui/composables/useExpandedFormStore.ts | 3 ++- packages/nc-gui/composables/useLTARStore.ts | 3 ++- packages/nc-gui/composables/useMapViewDataStore.ts | 4 ++-- 29 files changed, 73 insertions(+), 42 deletions(-) diff --git a/packages/nc-gui/components/cell/SingleSelect.vue b/packages/nc-gui/components/cell/SingleSelect.vue index b41f53fed6..dcdb5b3b28 100644 --- a/packages/nc-gui/components/cell/SingleSelect.vue +++ b/packages/nc-gui/components/cell/SingleSelect.vue @@ -18,8 +18,8 @@ import { inject, isDrawerOrModalExist, ref, - storeToRefs, useEventListener, + useProject, useRoles, useSelectedCellKeyupListener, watch, @@ -61,7 +61,7 @@ const { getMeta } = useMetas() const { hasRole } = useRoles() -const { isPg, isMysql } = storeToRefs(useProject()) +const { isPg, isMysql } = useProject() // a variable to keep newly created option value // temporary until it's add the option to column meta diff --git a/packages/nc-gui/components/dashboard/settings/DataSources.vue b/packages/nc-gui/components/dashboard/settings/DataSources.vue index 47d259c326..d59e3aa932 100644 --- a/packages/nc-gui/components/dashboard/settings/DataSources.vue +++ b/packages/nc-gui/components/dashboard/settings/DataSources.vue @@ -7,7 +7,7 @@ import Metadata from './Metadata.vue' import UIAcl from './UIAcl.vue' import Erd from './Erd.vue' import { ClientType, DataSourcesSubTab } from '~/lib' -import { useNuxtApp, useProject } from '#imports' +import { storeToRefs, useNuxtApp, useProject } from '#imports' interface Props { state: string @@ -24,7 +24,7 @@ const vReload = useVModel(props, 'reload', emits) const { $api, $e } = useNuxtApp() const projectStore = useProject() const { loadProject } = projectStore -const { project } = projectStore +const { project } = storeToRefs(projectStore) let sources = $ref([]) let activeBaseId = $ref('') diff --git a/packages/nc-gui/components/dashboard/settings/Misc.vue b/packages/nc-gui/components/dashboard/settings/Misc.vue index af6b07fcfe..803bb62ee2 100644 --- a/packages/nc-gui/components/dashboard/settings/Misc.vue +++ b/packages/nc-gui/components/dashboard/settings/Misc.vue @@ -1,12 +1,12 @@