style: format web apps with prettier and sort imports
Apply repo-wide Prettier/lint normalization across admin-web, desktop-client and ops-web: single quotes, no semicolons, trailing commas, consistent line wrapping, and import ordering. Also drop an unused brand-logo import in DesktopShell.vue. No behavior changes — formatting only. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -178,9 +178,12 @@ watch(
|
||||
return
|
||||
}
|
||||
|
||||
const timer = window.setInterval(() => {
|
||||
void refreshArticleData()
|
||||
}, streamFeatureEnabled ? 5000 : 2000)
|
||||
const timer = window.setInterval(
|
||||
() => {
|
||||
void refreshArticleData()
|
||||
},
|
||||
streamFeatureEnabled ? 5000 : 2000,
|
||||
)
|
||||
|
||||
onCleanup(() => {
|
||||
window.clearInterval(timer)
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<script setup lang="ts">
|
||||
import type { ComplianceViolation } from '@geo/shared-types'
|
||||
import {
|
||||
AlignCenterOutlined,
|
||||
AlignLeftOutlined,
|
||||
@@ -20,6 +19,7 @@ import {
|
||||
TableOutlined,
|
||||
UnorderedListOutlined,
|
||||
} from '@ant-design/icons-vue'
|
||||
import type { ComplianceViolation } from '@geo/shared-types'
|
||||
import { Crepe, CrepeFeature } from '@milkdown/crepe'
|
||||
import { commandsCtx, editorViewCtx, parserCtx, prosePluginsCtx } from '@milkdown/kit/core'
|
||||
import type { Ctx } from '@milkdown/kit/ctx'
|
||||
@@ -108,19 +108,22 @@ import {
|
||||
type RichImageAlign,
|
||||
} from '@/lib/milkdown/richImageBlock'
|
||||
|
||||
const props = withDefaults(defineProps<{
|
||||
articleId?: number | null
|
||||
title: string
|
||||
modelValue: string
|
||||
disabled?: boolean
|
||||
toolbar?: boolean
|
||||
aiOptimizeEnabled?: boolean
|
||||
complianceViolations?: ComplianceViolation[]
|
||||
uploadImage?: (file: File) => Promise<string>
|
||||
}>(), {
|
||||
toolbar: true,
|
||||
aiOptimizeEnabled: true,
|
||||
})
|
||||
const props = withDefaults(
|
||||
defineProps<{
|
||||
articleId?: number | null
|
||||
title: string
|
||||
modelValue: string
|
||||
disabled?: boolean
|
||||
toolbar?: boolean
|
||||
aiOptimizeEnabled?: boolean
|
||||
complianceViolations?: ComplianceViolation[]
|
||||
uploadImage?: (file: File) => Promise<string>
|
||||
}>(),
|
||||
{
|
||||
toolbar: true,
|
||||
aiOptimizeEnabled: true,
|
||||
},
|
||||
)
|
||||
|
||||
const emit = defineEmits<{
|
||||
'update:title': [value: string]
|
||||
@@ -432,9 +435,7 @@ function findComplianceHighlightRange(
|
||||
if (a.used !== b.used) {
|
||||
return a.used ? 1 : -1
|
||||
}
|
||||
return (
|
||||
Math.abs(a.textIndex - request.startOffset) - Math.abs(b.textIndex - request.startOffset)
|
||||
)
|
||||
return Math.abs(a.textIndex - request.startOffset) - Math.abs(b.textIndex - request.startOffset)
|
||||
})
|
||||
|
||||
const selected = candidates[0]
|
||||
|
||||
@@ -309,10 +309,7 @@ onBeforeUnmount(() => {
|
||||
</template>
|
||||
</a-table>
|
||||
|
||||
<GeneratedArticleLinksDrawer
|
||||
v-model:open="articleLinksOpen"
|
||||
:articles="selectedTaskArticles"
|
||||
/>
|
||||
<GeneratedArticleLinksDrawer v-model:open="articleLinksOpen" :articles="selectedTaskArticles" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -51,7 +51,12 @@ const ruleListParams = computed(() => {
|
||||
})
|
||||
|
||||
const rulesQuery = useQuery({
|
||||
queryKey: computed(() => ['promptRules', 'list', companyStore.currentBrandId, ruleListParams.value]),
|
||||
queryKey: computed(() => [
|
||||
'promptRules',
|
||||
'list',
|
||||
companyStore.currentBrandId,
|
||||
ruleListParams.value,
|
||||
]),
|
||||
enabled: computed(() => Boolean(companyStore.currentBrandId)),
|
||||
queryFn: () => promptRulesApi.list(ruleListParams.value),
|
||||
})
|
||||
|
||||
@@ -877,7 +877,8 @@ async function handleEnterprisePublishSuccess(
|
||||
notification.error({
|
||||
message: '企业站发布失败',
|
||||
description:
|
||||
formatStoredErrorMessage(failed[0]?.error_message) || '请检查插件、栏目和 PBootCMS API 配置。',
|
||||
formatStoredErrorMessage(failed[0]?.error_message) ||
|
||||
'请检查插件、栏目和 PBootCMS API 配置。',
|
||||
placement: 'topRight',
|
||||
duration: 6,
|
||||
})
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script setup lang="ts">
|
||||
import { useQuery } from '@tanstack/vue-query'
|
||||
import type { CreateKolPromptRequest } from '@geo/shared-types'
|
||||
import { useQuery } from '@tanstack/vue-query'
|
||||
import { computed, reactive, watch } from 'vue'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user