36 lines
674 B
Vue
36 lines
674 B
Vue
<template>
|
|
<section class="AiMore">
|
|
<u-icon :name="icon" color="#ddd" :label="value||placeholder" label-pos="left" :label-color="labelColor"
|
|
:label-size="size" :size="size" @click="$emit('click')"/>
|
|
</section>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: "AiMore",
|
|
model: {
|
|
prop: "value",
|
|
event: "change"
|
|
},
|
|
props: {
|
|
placeholder: {default: "请选择"},
|
|
value: String,
|
|
icon: {default: "arrow-right"},
|
|
size: {default: 30}
|
|
},
|
|
computed: {
|
|
isEmpty() {
|
|
return !this.value
|
|
},
|
|
labelColor() {
|
|
return this.isEmpty ? "#999" : "#333"
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
.AiMore {
|
|
}
|
|
</style>
|