From da8005a8cbd847b62ed1e22f3c7e3e922ee34db7 Mon Sep 17 00:00:00 2001 From: matevip Date: Wed, 13 May 2026 11:30:28 +0800 Subject: [PATCH] release: v1.3.0 (pnpm build fix) --- mateclaw-ui/src/views/Enterprise/AccountIntel.vue | 11 +++++++---- mateclaw-ui/src/views/Enterprise/Approvals.vue | 5 +++-- mateclaw-ui/src/views/Enterprise/Audit.vue | 5 +++-- mateclaw-ui/src/views/Enterprise/ContractReview.vue | 5 +++-- mateclaw-ui/src/views/Enterprise/Overview.vue | 5 +++-- mateclaw-ui/src/views/Enterprise/index.vue | 9 +++++---- 6 files changed, 24 insertions(+), 16 deletions(-) diff --git a/mateclaw-ui/src/views/Enterprise/AccountIntel.vue b/mateclaw-ui/src/views/Enterprise/AccountIntel.vue index 6c7ecb22..1689e39c 100644 --- a/mateclaw-ui/src/views/Enterprise/AccountIntel.vue +++ b/mateclaw-ui/src/views/Enterprise/AccountIntel.vue @@ -123,16 +123,19 @@ import { computed, ref } from 'vue' import { useI18n } from 'vue-i18n' const { t } = useI18n() -const listFilter = ref<'all' | 'hot' | 'cooling'>('all') -const tlFilter = ref<'all' | 'public' | 'meeting' | 'doc'>('all') +type ListFilterKey = 'all' | 'hot' | 'cooling' +type TlFilterKey = 'all' | 'public' | 'meeting' | 'doc' -const listFilters = computed(() => [ +const listFilter = ref('all') +const tlFilter = ref('all') + +const listFilters = computed<{ key: ListFilterKey; label: string; count: number }[]>(() => [ { key: 'all', label: t('enterprise.account.filterAll'), count: 14 }, { key: 'hot', label: t('enterprise.account.filterHot'), count: 4 }, { key: 'cooling', label: t('enterprise.account.filterCooling'), count: 3 }, ]) -const tlFilters = computed(() => [ +const tlFilters = computed<{ key: TlFilterKey; label: string }[]>(() => [ { key: 'all', label: t('enterprise.account.tlAll') }, { key: 'public', label: t('enterprise.account.tlPublic') }, { key: 'meeting', label: t('enterprise.account.tlMeeting') }, diff --git a/mateclaw-ui/src/views/Enterprise/Approvals.vue b/mateclaw-ui/src/views/Enterprise/Approvals.vue index 97c08aeb..c41bf73f 100644 --- a/mateclaw-ui/src/views/Enterprise/Approvals.vue +++ b/mateclaw-ui/src/views/Enterprise/Approvals.vue @@ -84,9 +84,10 @@ import { computed, ref } from 'vue' import { useI18n } from 'vue-i18n' const { t } = useI18n() -const filter = ref<'mine' | 'all' | 'high'>('mine') +type FilterKey = 'mine' | 'all' | 'high' +const filter = ref('mine') -const filters = computed(() => [ +const filters = computed<{ key: FilterKey; label: string; count: number }[]>(() => [ { key: 'mine', label: t('enterprise.approvals.filterMine'), count: 3 }, { key: 'all', label: t('enterprise.approvals.filterAll'), count: 5 }, { key: 'high', label: t('enterprise.approvals.filterHigh'), count: 2 }, diff --git a/mateclaw-ui/src/views/Enterprise/Audit.vue b/mateclaw-ui/src/views/Enterprise/Audit.vue index d1a49057..c6c130b2 100644 --- a/mateclaw-ui/src/views/Enterprise/Audit.vue +++ b/mateclaw-ui/src/views/Enterprise/Audit.vue @@ -43,9 +43,10 @@ import { computed, ref } from 'vue' import { useI18n } from 'vue-i18n' const { t } = useI18n() -const scope = ref<'all' | 'contract' | 'account' | 'tool'>('all') +type ScopeKey = 'all' | 'contract' | 'account' | 'tool' +const scope = ref('all') -const scopeFilters = computed(() => [ +const scopeFilters = computed<{ key: ScopeKey; label: string }[]>(() => [ { key: 'all', label: t('enterprise.audit.scopeAll') }, { key: 'contract', label: t('enterprise.audit.scopeContract') }, { key: 'account', label: t('enterprise.audit.scopeAccount') }, diff --git a/mateclaw-ui/src/views/Enterprise/ContractReview.vue b/mateclaw-ui/src/views/Enterprise/ContractReview.vue index 83e850ca..190703af 100644 --- a/mateclaw-ui/src/views/Enterprise/ContractReview.vue +++ b/mateclaw-ui/src/views/Enterprise/ContractReview.vue @@ -144,9 +144,10 @@ import { useI18n } from 'vue-i18n' const { t } = useI18n() const props = defineProps<{ focus: string | null }>() -const listFilter = ref<'all' | 'high' | 'pending'>('all') +type ListFilterKey = 'all' | 'high' | 'pending' +const listFilter = ref('all') -const listFilters = computed(() => [ +const listFilters = computed<{ key: ListFilterKey; label: string; count: number }[]>(() => [ { key: 'all', label: t('enterprise.contract.filterAll'), count: 23 }, { key: 'high', label: t('enterprise.contract.filterHigh'), count: 7 }, { key: 'pending', label: t('enterprise.contract.filterPending'), count: 12 }, diff --git a/mateclaw-ui/src/views/Enterprise/Overview.vue b/mateclaw-ui/src/views/Enterprise/Overview.vue index c6e79950..910b2c1b 100644 --- a/mateclaw-ui/src/views/Enterprise/Overview.vue +++ b/mateclaw-ui/src/views/Enterprise/Overview.vue @@ -109,7 +109,8 @@ import { useI18n } from 'vue-i18n' const { t } = useI18n() const emit = defineEmits<{ (e: 'open-case', id: string): void }>() -const activeFilter = ref<'all' | 'high' | 'pending' | 'today'>('all') +type QueueFilterKey = 'all' | 'high' | 'pending' | 'today' +const activeFilter = ref('all') const metrics = computed(() => [ { key: 'pending', label: t('enterprise.overview.metricPending'), value: '23', delta: '+4', deltaTone: 'up', tone: '' }, @@ -118,7 +119,7 @@ const metrics = computed(() => [ { key: 'cited', label: t('enterprise.overview.metricCited'), value: '98%', delta: '+3pp', deltaTone: 'up', tone: 'tone-good' }, ]) -const queueFilters = computed(() => [ +const queueFilters = computed<{ key: QueueFilterKey; label: string; count: number }[]>(() => [ { key: 'all', label: t('enterprise.overview.filterAll'), count: 23 }, { key: 'high', label: t('enterprise.overview.filterHighRisk'), count: 7 }, { key: 'pending', label: t('enterprise.overview.filterPending'), count: 12 }, diff --git a/mateclaw-ui/src/views/Enterprise/index.vue b/mateclaw-ui/src/views/Enterprise/index.vue index b61b2739..5c020202 100644 --- a/mateclaw-ui/src/views/Enterprise/index.vue +++ b/mateclaw-ui/src/views/Enterprise/index.vue @@ -37,15 +37,16 @@ import Approvals from './Approvals.vue' import Audit from './Audit.vue' const { t } = useI18n() -const activeTab = ref<'overview' | 'contract' | 'account' | 'approvals' | 'audit'>('overview') +type TabKey = 'overview' | 'contract' | 'account' | 'approvals' | 'audit' +const activeTab = ref('overview') const caseFocus = ref(null) -const tabs = computed(() => [ - { key: 'overview', label: t('enterprise.tabs.overview'), count: null as number | null }, +const tabs = computed<{ key: TabKey; label: string; count: number | null }[]>(() => [ + { key: 'overview', label: t('enterprise.tabs.overview'), count: null }, { key: 'contract', label: t('enterprise.tabs.contract'), count: 23 }, { key: 'account', label: t('enterprise.tabs.account'), count: 14 }, { key: 'approvals', label: t('enterprise.tabs.approvals'), count: 5 }, - { key: 'audit', label: t('enterprise.tabs.audit'), count: null as number | null }, + { key: 'audit', label: t('enterprise.tabs.audit'), count: null }, ]) function onOpenCase(id: string) {