提交 e4b29733 编写于 作者: H hdx

swiper-list: 处理代码警告

上级 46d92574
...@@ -87,10 +87,10 @@ ...@@ -87,10 +87,10 @@
}, },
onReady() { onReady() {
this.$pageScrollView = this.$refs['pageScrollView'] as INode; this.$pageScrollView = this.$refs['pageScrollView'] as INode;
this.$headerHeight = (this.$refs["header"] as INode).offsetHeight this.$headerHeight = (this.$refs['header'] as INode).offsetHeight
this.$swiperWidth = (this.$refs["swiper"] as INode).getBoundingClientRect().width this.$swiperWidth = (this.$refs['swiper'] as INode).getBoundingClientRect().width
this.$tabScrollView = this.$refs.get('tabScroll') as INode this.$tabScrollView = this.$refs['tabScroll'] as INode
this.$indicatorNode = this.$refs.get('indicator') as INode this.$indicatorNode = this.$refs['indicator'] as INode
this.cacheTabItemsSize() this.cacheTabItemsSize()
this.setSwiperIndex(0, true) this.setSwiperIndex(0, true)
}, },
......
...@@ -61,8 +61,8 @@ ...@@ -61,8 +61,8 @@
} }
}, },
onReady() { onReady() {
this.$tabScrollView = this.$refs.get('tabScroll') as INode this.$tabScrollView = this.$refs['tabScroll'] as INode
this.$indicatorNode = this.$refs.get('indicator') as INode this.$indicatorNode = this.$refs['indicator'] as INode
this.$swiperWidth = (this.$refs["swiper"] as INode).getBoundingClientRect().width this.$swiperWidth = (this.$refs["swiper"] as INode).getBoundingClientRect().width
this.cacheTabItemsSize() this.cacheTabItemsSize()
this.setSwiperIndex(0, true) this.setSwiperIndex(0, true)
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
} }
}, },
onReady() { onReady() {
this.$tabScrollView = this.$refs.get('tabScroll') as INode this.$tabScrollView = this.$refs['tabScroll'] as INode
this.$swiperWidth = (this.$refs["swiper"] as INode).getBoundingClientRect().width this.$swiperWidth = (this.$refs["swiper"] as INode).getBoundingClientRect().width
this.setSwiperIndex(0, true) this.setSwiperIndex(0, true)
}, },
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
const min_ratio = 1 const min_ratio = 1
const max_ratio = 1.3 const max_ratio = 1.3
const tabs = this.$refs["swipertab"] as INode[] const tabs = this.$refs['swipertab'] as INode[]
const current_node = tabs[current_index]! const current_node = tabs[current_index]!
const move_to_node = tabs[move_to_index]! const move_to_node = tabs[move_to_index]!
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册