mirror of https://github.com/ElemeFE/element
Tabs: use paneName instead of name (#13733)
parent
c8839b8022
commit
e5a38eaebe
|
@ -14,7 +14,6 @@
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
barStyle: {
|
barStyle: {
|
||||||
cache: false,
|
|
||||||
get() {
|
get() {
|
||||||
if (!this.$parent.$refs.tabs) return {};
|
if (!this.$parent.$refs.tabs) return {};
|
||||||
let style = {};
|
let style = {};
|
||||||
|
@ -26,7 +25,7 @@
|
||||||
return str.toLowerCase().replace(/( |^)[a-z]/g, (L) => L.toUpperCase());
|
return str.toLowerCase().replace(/( |^)[a-z]/g, (L) => L.toUpperCase());
|
||||||
};
|
};
|
||||||
this.tabs.every((tab, index) => {
|
this.tabs.every((tab, index) => {
|
||||||
let $el = arrayFind(this.$parent.$refs.tabs, t => t.id.replace('tab-', '') === tab.name);
|
let $el = arrayFind(this.$parent.$refs.tabs, t => t.id.replace('tab-', '') === tab.paneName);
|
||||||
if (!$el) { return false; }
|
if (!$el) { return false; }
|
||||||
|
|
||||||
if (!tab.active) {
|
if (!tab.active) {
|
||||||
|
|
Loading…
Reference in New Issue