You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
import { filterEmpty } from '../_util/props-util'
|
|
|
|
export default {
|
|
|
|
name: 'InputGruop',
|
|
|
|
props: {
|
|
|
|
prefixCls: {
|
|
|
|
default: 'ant-input-group',
|
|
|
|
type: String,
|
|
|
|
},
|
|
|
|
size: {
|
|
|
|
validator (value) {
|
|
|
|
return ['small', 'large', 'default'].includes(value)
|
|
|
|
},
|
|
|
|
},
|
|
|
|
compact: Boolean,
|
|
|
|
},
|
|
|
|
computed: {
|
|
|
|
classes () {
|
|
|
|
const { prefixCls, size, compact = false } = this
|
|
|
|
return {
|
|
|
|
[`${prefixCls}`]: true,
|
|
|
|
[`${prefixCls}-lg`]: size === 'large',
|
|
|
|
[`${prefixCls}-sm`]: size === 'small',
|
|
|
|
[`${prefixCls}-compact`]: compact,
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
},
|
|
|
|
render () {
|
|
|
|
return (
|
|
|
|
<span class={this.classes} >
|
|
|
|
{filterEmpty(this.$slots.default)}
|
|
|
|
</span>
|
|
|
|
)
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|