Skip to content

Commit 96e5e83

Browse files
authored
fix: disabled tabPane can be actived #3575 (#3604)
1 parent e179ded commit 96e5e83

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Diff for: components/vc-tabs/src/Tabs.jsx

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import BaseMixin from '../../_util/BaseMixin';
33
import PropTypes from '../../_util/vue-types';
44
import raf from 'raf';
55
import KeyCode from './KeyCode';
6-
import { getOptionProps, getListeners } from '../../_util/props-util';
6+
import { getOptionProps, getListeners, getValueByProp } from '../../_util/props-util';
77
import { cloneElement } from '../../_util/vnode';
88
import Sentinel from './Sentinel';
99
import isValid from '../../_util/isValid';
@@ -154,7 +154,8 @@ export default {
154154
const activeKey = this.$data._activeKey;
155155
const children = [];
156156
this.$props.children.forEach(c => {
157-
if (c && !c.disabled && c.disabled !== '') {
157+
const disabled = getValueByProp(c, 'disabled');
158+
if (c && !disabled && disabled !== '') {
158159
if (next) {
159160
children.push(c);
160161
} else {

0 commit comments

Comments
 (0)