[bugfix] Tab: line width can be zero (#2081)
This commit is contained in:
@@ -256,7 +256,7 @@ export default create({
|
|||||||
}
|
}
|
||||||
|
|
||||||
const tab = this.$refs.tabs[this.curActive];
|
const tab = this.$refs.tabs[this.curActive];
|
||||||
const width = this.lineWidth || (tab.offsetWidth / 2);
|
const width = this.isDef(this.lineWidth) ? this.lineWidth : (tab.offsetWidth / 2);
|
||||||
const left = tab.offsetLeft + (tab.offsetWidth - width) / 2;
|
const left = tab.offsetLeft + (tab.offsetWidth - width) / 2;
|
||||||
|
|
||||||
this.lineStyle = {
|
this.lineStyle = {
|
||||||
|
|||||||
Reference in New Issue
Block a user