style: 优化设备接入网关编辑样式

This commit is contained in:
xieyonghong 2023-04-10 18:19:04 +08:00
parent 92c1b48887
commit 8480df4f4d
2 changed files with 9 additions and 0 deletions

View File

@ -5,6 +5,7 @@
'card-render',
`access-${data.type || 'network'}`,
checked === data.id ? 'checked' : '',
disabled ? 'disabled' : ''
]"
@click="checkedChange(data.id)"
>
@ -40,6 +41,10 @@ const props = defineProps({
type: Object,
default: () => {},
},
disabled: {
type: Boolean,
default: false
}
});
const checkedChange = (id: string) => {
@ -105,6 +110,9 @@ const checkedChange = (id: string) => {
display: block;
}
}
&.disabled {
cursor: not-allowed;
}
}
.access-media {
background: url('/public/images/access-media.png') no-repeat;

View File

@ -134,6 +134,7 @@
<AccessCard
@checkedChange="procotolChange"
:checked="procotolCurrent"
:disabled='id !== ":id"'
:data="{ ...item, type: 'protocol' }"
>
</AccessCard>