Commit fc822fe8 authored by Geass's avatar Geass Committed by hetech

RadioGroup: not produce invalid HTML in table if "is" attribute is specify (#17070)

parent 77c77efb
<template> <template>
<div <component
:is="_elTag"
class="el-radio-group" class="el-radio-group"
role="radiogroup" role="radiogroup"
@keydown="handleKeydown" @keydown="handleKeydown"
> >
<slot></slot> <slot></slot>
</div> </component>
</template> </template>
<script> <script>
import Emitter from 'element-ui/src/mixins/emitter'; import Emitter from 'element-ui/src/mixins/emitter';
...@@ -41,6 +42,9 @@ ...@@ -41,6 +42,9 @@
_elFormItemSize() { _elFormItemSize() {
return (this.elFormItem || {}).elFormItemSize; return (this.elFormItem || {}).elFormItemSize;
}, },
_elTag() {
return (this.$vnode.data || {}).tag || 'div';
},
radioGroupSize() { radioGroupSize() {
return this.size || this._elFormItemSize || (this.$ELEMENT || {}).size; return this.size || this._elFormItemSize || (this.$ELEMENT || {}).size;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment