[Improvement] Checkbox: add label-position prop (#1394)

This commit is contained in:
neverland
2018-07-04 00:42:58 +08:00
committed by GitHub
parent 4fd891ac29
commit 60fcfd4d46
4 changed files with 11 additions and 3 deletions

View File

@@ -10,7 +10,7 @@
}]"
@click="onClick"
/>
<span v-if="$slots.default" :class="b('label')" @click="onClick('label')">
<span v-if="$slots.default" :class="b('label', labelPosition)" @click="onClick('label')">
<slot />
</span>
</div>
@@ -29,6 +29,7 @@ export default create({
name: null,
value: null,
disabled: Boolean,
labelPosition: String,
labelDisabled: {
type: Boolean,
default: false