diff --git a/packages/nc-gui-v2/components/smartsheet/sidebar/menu/ApiSnippet.vue b/packages/nc-gui-v2/components/smartsheet/sidebar/menu/ApiSnippet.vue
index 3e3aed7159..3a061ab159 100644
--- a/packages/nc-gui-v2/components/smartsheet/sidebar/menu/ApiSnippet.vue
+++ b/packages/nc-gui-v2/components/smartsheet/sidebar/menu/ApiSnippet.vue
@@ -3,6 +3,7 @@ import HTTPSnippet from 'httpsnippet'
import { useClipboard } from '@vueuse/core'
import { message } from 'ant-design-vue'
import { ActiveViewInj, MetaInj } from '~/context'
+import { inject, useGlobal, useProject, useSmartsheetStoreOrThrow, useVModel, useViewData } from '#imports'
const props = defineProps
()
@@ -13,11 +14,17 @@ interface Props {
}
const { project } = $(useProject())
+
const { appInfo, token } = $(useGlobal())
-const meta = $(inject(MetaInj))
-const view = $(inject(ActiveViewInj))
+
+const meta = $(inject(MetaInj)!)
+
+const view = $(inject(ActiveViewInj)!)
+
const { xWhere } = useSmartsheetStoreOrThrow()
-const { queryParams } = $(useViewData(meta, view as any, xWhere))
+
+const { queryParams } = $(useViewData($$(meta), view as any, xWhere))
+
const { copy } = useClipboard()
let vModel = $(useVModel(props, 'modelValue', emits))
diff --git a/packages/nc-gui-v2/components/virtual-cell/components/ItemChip.vue b/packages/nc-gui-v2/components/virtual-cell/components/ItemChip.vue
index f4be7fbad0..6283b90536 100644
--- a/packages/nc-gui-v2/components/virtual-cell/components/ItemChip.vue
+++ b/packages/nc-gui-v2/components/virtual-cell/components/ItemChip.vue
@@ -1,5 +1,5 @@
@@ -29,6 +29,7 @@ const expandedFormDlg = ref(false)
@click="expandedFormDlg = true"
>
{{ value }}
+
diff --git a/packages/nc-gui-v2/composables/useSmartsheetRowStore.ts b/packages/nc-gui-v2/composables/useSmartsheetRowStore.ts
index bc9a59aa37..8bb3135a89 100644
--- a/packages/nc-gui-v2/composables/useSmartsheetRowStore.ts
+++ b/packages/nc-gui-v2/composables/useSmartsheetRowStore.ts
@@ -2,9 +2,8 @@ import { message } from 'ant-design-vue'
import { UITypes } from 'nocodb-sdk'
import type { ColumnType, LinkToAnotherRecordType, RelationTypes, TableType } from 'nocodb-sdk'
import type { Ref } from 'vue'
-import { useNuxtApp } from '#app'
-import { useInjectionState, useMetas, useProject, useVirtualCell } from '#imports'
-import type { Row } from '~/composables/useViewData'
+import type { Row } from './useViewData'
+import { useInjectionState, useMetas, useNuxtApp, useProject, useVirtualCell } from '#imports'
import { NOCO } from '~/lib'
import { extractPkFromRow, extractSdkResponseErrorMsg } from '~/utils'
@@ -47,7 +46,7 @@ const [useProvideSmartsheetRowStore, useSmartsheetRowStore] = useInjectionState(
project.value.title as string,
meta.value.title as string,
rowId,
- type,
+ type as 'mm' | 'hm',
column.title as string,
relatedRowId,
)
@@ -69,14 +68,19 @@ const [useProvideSmartsheetRowStore, useSmartsheetRowStore] = useInjectionState(
if (isHm || isMm) {
const relatedRows = (state.value?.[column.title!] ?? []) as Record[]
for (const relatedRow of relatedRows) {
- await linkRecord(id, extractPkFromRow(relatedRow, relatedTableMeta.columns as ColumnType[]), column, colOptions.type)
+ await linkRecord(
+ id,
+ extractPkFromRow(relatedRow, relatedTableMeta.columns as ColumnType[]),
+ column,
+ colOptions.type as RelationTypes,
+ )
}
} else if (isBt && state?.value?.[column.title!]) {
await linkRecord(
id,
extractPkFromRow(state.value?.[column.title!] as Record, relatedTableMeta.columns as ColumnType[]),
column,
- colOptions.type,
+ colOptions.type as RelationTypes,
)
}
}
diff --git a/packages/nc-gui-v2/composables/useViewData.ts b/packages/nc-gui-v2/composables/useViewData.ts
index c2c10fd8c1..c57293922c 100644
--- a/packages/nc-gui-v2/composables/useViewData.ts
+++ b/packages/nc-gui-v2/composables/useViewData.ts
@@ -1,8 +1,7 @@
import type { Api, ColumnType, FormType, GalleryType, PaginatedType, TableType, ViewType } from 'nocodb-sdk'
import type { ComputedRef, Ref } from 'vue'
import { message } from 'ant-design-vue'
-import { useNuxtApp } from '#app'
-import { useProject } from '#imports'
+import { ref, useNuxtApp, useProject } from '#imports'
import { NOCO } from '~/lib'
import { extractPkFromRow, extractSdkResponseErrorMsg } from '~/utils'
diff --git a/packages/nc-gui-v2/httpsnippet-shims.d.ts b/packages/nc-gui-v2/httpsnippet-shims.d.ts
new file mode 100644
index 0000000000..a06664f07b
--- /dev/null
+++ b/packages/nc-gui-v2/httpsnippet-shims.d.ts
@@ -0,0 +1,3 @@
+declare module 'httpsnippet' {
+ export default new ((): any => {})()
+}
diff --git a/packages/nc-gui-v2/vue-color-shims.d.ts b/packages/nc-gui-v2/vue-color-shims.d.ts
index 63fe35c76e..75f77909c4 100644
--- a/packages/nc-gui-v2/vue-color-shims.d.ts
+++ b/packages/nc-gui-v2/vue-color-shims.d.ts
@@ -1,4 +1,5 @@
declare module '@ckpack/vue-color' {
import type { Component } from '@vue/runtime-core'
const Sketch: Component
+ const Chrome: Component
}