fix: resolve vue-tsc type errors in SqlPreviewPanel and DataGrid

This commit is contained in:
t8y2
2026-06-10 12:41:24 +08:00
parent 42a7ecdbed
commit 500d7c614b
2 changed files with 2 additions and 4 deletions
@@ -24,7 +24,6 @@ const { t } = useI18n();
const { isDark } = useTheme();
const { toast } = useToast();
const codeContainerRef = ref<HTMLDivElement>();
const isFormatted = ref(false);
const formattedSql = ref("");
const formatting = ref(false);
@@ -183,7 +182,7 @@ onBeforeUnmount(() => {
</div>
<!-- Shiki highlighted SQL -->
<div v-else-if="highlightedHtml" ref="codeContainerRef" class="p-3 text-xs leading-relaxed [&_pre]:!bg-transparent [&_pre]:!p-0 [&_code]:!font-mono [&_code]:text-xs" v-html="highlightedHtml" />
<div v-else-if="highlightedHtml" class="p-3 text-xs leading-relaxed [&_pre]:!bg-transparent [&_pre]:!p-0 [&_code]:!font-mono [&_code]:text-xs" v-html="highlightedHtml" />
<!-- Plain text fallback -->
<pre v-else class="p-3 text-xs font-mono whitespace-pre-wrap select-text">{{ displaySql }}</pre>
@@ -4,7 +4,7 @@ const globalDdlOpen = ref(false);
</script>
<script setup lang="ts">
import { computed, nextTick, onMounted, onUnmounted, onActivated, onDeactivated, useSlots, watch, ref, defineAsyncComponent, type Component } from "vue";
import { computed, nextTick, onMounted, onUnmounted, onActivated, onDeactivated, useSlots, watch, defineAsyncComponent, type Component } from "vue";
import { useI18n } from "vue-i18n";
import {
ArrowUp,
@@ -1997,7 +1997,6 @@ const {
clearResetScrollAfterResult,
cleanupFrames,
recordScrollPosition,
previewStatements,
isPreviewLoading,
previewChanges,
} = editor;