feat: 优化 AuditView 样式与交互细节
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { computed, ref } from 'vue'
|
||||
import { computed, ref, watch } from 'vue'
|
||||
|
||||
const TYPE_META = {
|
||||
skills: {
|
||||
@@ -545,7 +545,8 @@ const assets = [
|
||||
|
||||
export default {
|
||||
name: 'AuditView',
|
||||
setup() {
|
||||
emits: ['detail-open-change'],
|
||||
setup(props, { emit }) {
|
||||
const tabs = [
|
||||
{ id: 'skills', label: 'Skills' },
|
||||
{ id: 'mcp', label: 'MCP' },
|
||||
@@ -562,6 +563,14 @@ export default {
|
||||
const tableColumns = computed(() => activeMeta.value.tableColumns)
|
||||
const visibleSkills = computed(() => assets.filter((item) => item.type === activeType.value))
|
||||
|
||||
watch(
|
||||
selectedSkill,
|
||||
(value) => {
|
||||
emit('detail-open-change', Boolean(value))
|
||||
},
|
||||
{ immediate: true }
|
||||
)
|
||||
|
||||
function openVersionSwitch(version) {
|
||||
if (!selectedSkill.value || version.version === selectedSkill.value.version) {
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user