Browse Source

chore(nc-gui): lint

pull/3563/head
Wing-Kam Wong 2 years ago
parent
commit
9945838a2e
  1. 2
      packages/nc-gui/components.d.ts
  2. 9
      packages/nc-gui/components/general/TruncateText.vue
  3. 1
      packages/nc-gui/components/smartsheet/Gallery.vue
  4. 4
      packages/nc-gui/components/smartsheet/column/SelectOptions.vue
  5. 1
      packages/nc-gui/components/tabs/Smartsheet.vue
  6. 4
      packages/nc-gui/composables/useExpandedFormStore.ts
  7. 2
      packages/nc-gui/composables/useSharedView.ts

2
packages/nc-gui/components.d.ts vendored

@ -114,7 +114,9 @@ declare module '@vue/runtime-core' {
MdiAlpha: typeof import('~icons/mdi/alpha')['default']
MdiAlphaA: typeof import('~icons/mdi/alpha-a')['default']
MdiApi: typeof import('~icons/mdi/api')['default']
MdiArrowCollapse: typeof import('~icons/mdi/arrow-collapse')['default']
MdiArrowDownDropCircle: typeof import('~icons/mdi/arrow-down-drop-circle')['default']
MdiArrowDownDropCircleOutline: typeof import('~icons/mdi/arrow-down-drop-circle-outline')['default']
MdiArrowExpand: typeof import('~icons/mdi/arrow-expand')['default']
MdiArrowLeftBold: typeof import('~icons/mdi/arrow-left-bold')['default']
MdiAt: typeof import('~icons/mdi/at')['default']

9
packages/nc-gui/components/general/TruncateText.vue

@ -39,12 +39,3 @@ const shortName = computed(() =>
<div v-else class="w-full"><slot></slot></div>
<div ref="text" class="hidden"><slot></slot></div>
</template>
<div v-else>
<slot />
</div>
<div ref="text" class="hidden">
<slot />
</div>
</template>

1
packages/nc-gui/components/smartsheet/Gallery.vue

@ -1,5 +1,4 @@
<script lang="ts" setup>
import type { ColumnType } from 'nocodb-sdk'
import { isVirtualCol } from 'nocodb-sdk'
import {
ActiveViewInj,

4
packages/nc-gui/components/smartsheet/column/SelectOptions.vue

@ -1,7 +1,7 @@
<script setup lang="ts">
import Draggable from 'vuedraggable'
import { UITypes } from 'nocodb-sdk'
import { enumColor, onMounted, useColumnCreateStoreOrThrow, useVModel, watch, IsKanbanInj } from '#imports'
import { IsKanbanInj, enumColor, onMounted, useColumnCreateStoreOrThrow, useVModel, watch } from '#imports'
const props = defineProps<{
value: any
@ -97,7 +97,7 @@ watch(inputs, () => {
<Draggable :list="options" item-key="id" handle=".nc-child-draggable-icon">
<template #item="{ element, index }">
<div class="flex py-1 items-center nc-select-option">
<MdiDragIcon v-if="!isKanban" small class="nc-child-draggable-icon handle" />
<MdiDragVertical v-if="!isKanban" small class="nc-child-draggable-icon handle" />
<a-dropdown
v-model:visible="colorMenus[index]"
:trigger="['click']"

1
packages/nc-gui/components/tabs/Smartsheet.vue

@ -76,6 +76,7 @@ watch(isLocked, (nextValue) => (treeViewIsLockedInj.value = nextValue), { immedi
<LazySmartsheetForm v-else-if="isForm && !$route.query.reload" />
<LazySmartsheetKanban v-else-if="isKanban" />
</div>
</div>
</template>
</Transition>

4
packages/nc-gui/composables/useExpandedFormStore.ts

@ -39,9 +39,11 @@ const [useProvideExpandedFormStore, useExpandedFormStore] = useInjectionState((m
const changedColumns = ref(new Set<string>())
const { project } = useProject()
const rowStore = useProvideSmartsheetRowStore(meta, row)
const { sharedView } = useSharedView() as Record<string, any>
const activeView = inject(ActiveViewInj, ref())
const { addRowToStack } = useKanbanViewStoreOrThrow()
const { sharedView } = useSharedView()

2
packages/nc-gui/composables/useSharedView.ts

@ -31,7 +31,7 @@ export function useSharedView() {
const password = useState<string | undefined>('password', () => undefined)
const allowCSVDownload = useState<boolean>('allowCSVDownload', () => false)
const meta = useState<TableType | KanbanType | undefined>('meta', () => undefined)
const formColumns = computed(

Loading…
Cancel
Save