赞
踩
import { Icon } from 'ant-design-vue';
import Vue from 'vue'
const JihaoIcon = Icon.createFromIconfontCN({
scriptUrl:'//at.alicdn.com/t/xxxxxxxxxxxxxxxx.js'
})
Vue.component('jihao-icon', JihaoIcon)
export default JihaoIcon
renderIcon (icon) {
if (icon === 'none' || icon === undefined) {
return null
}
const props = {}
typeof (icon) === 'object' ? props.component = icon : props.type = icon
if (props.type && props.type.startsWith('icon_')) {
return (
<JihaoIcon type={props.type}/>
)
}
return (
<Icon {... { props } }/>
)
},
<a-button @click="handleRemove(record)" style="padding: 0 6px;font-size: 12px;height: 26px;">
<jihao-icon style="font-size: 13px;" title="删除" type="icon_delete_device"></jihao-icon>
<span style="font-size: 12px;">删除</span>
</a-button>
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。