Merge pull request #4965 from dataease/pr@dev@fix_tab-scoll-change

fix(仪表板): 选项卡组件tab页过多时,轮播标题被遮挡,看不见部分标题了 #4956
This commit is contained in:
王嘉豪
2023-04-04 18:28:37 +08:00
committed by GitHub

View File

@@ -478,7 +478,7 @@ export default {
methods: {
calcTabLength(){
this.$nextTick(()=>{
if(this.element.options.tabList.length>0){
if(this.element.options.tabList.length>1){
const containerDom = document.getElementById("tab-"+this.element.options.tabList[this.element.options.tabList.length -1].name)
this.tabsAreaScroll = containerDom.parentNode.scrollWidth > containerDom.parentNode.parentNode.scrollWidth
}else{