WIP mapViewStore

This commit is contained in:
flisowna
2022-10-31 12:55:06 +04:00
parent 6eeec60963
commit 9e6271dd4e
2 changed files with 27 additions and 16 deletions

View File

@@ -1,13 +1,14 @@
import type { ComputedRef, Ref } from 'vue'
import type { MapType, TableType, ViewType } from 'nocodb-sdk'
import { ref, useApi, useInjectionState } from '#imports'
import type { Row } from '~/lib'
const [useProvideMapViewStore, useMapViewStore] = useInjectionState(
(
meta: Ref<TableType | MapType | undefined>,
viewMeta: Ref<ViewType | MapType | undefined> | ComputedRef<(ViewType & { id: string }) | undefined>,
) => {
const formattedData = ref<string[]>()
const formattedData = ref<Row[]>()
const { api } = useApi()
const { project } = useProject()