Commit ff1251f0 authored by iamkun's avatar iamkun

Tabs: fix error tab bar style

parent af8267f9
......@@ -15,7 +15,6 @@
computed: {
barStyle: {
get() {
if (!this.$parent.$refs.tabs) return {};
let style = {};
let offset = 0;
let tabSize = 0;
......@@ -25,7 +24,7 @@
return str.toLowerCase().replace(/( |^)[a-z]/g, (L) => L.toUpperCase());
};
this.tabs.every((tab, index) => {
let $el = arrayFind(this.$parent.$refs.tabs, t => t.id.replace('tab-', '') === tab.paneName);
let $el = arrayFind(this.$parent.$refs.tabs || [], t => t.id.replace('tab-', '') === tab.paneName);
if (!$el) { return false; }
if (!tab.active) {
......
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