This commit is contained in:
@@ -17,7 +17,7 @@ class Index {
|
||||
this.getTagRecommend()
|
||||
this.getHomeHotData()
|
||||
this.getHomeListData()
|
||||
this.initSwiper()
|
||||
|
||||
this.event()
|
||||
}
|
||||
|
||||
@@ -39,8 +39,8 @@ class Index {
|
||||
$(".recommend-tag").innerHTML = res.maps(v => {
|
||||
return `
|
||||
<li>
|
||||
<div class="icon">${v.title.substr(0,1)}</div>
|
||||
<div class="title">${v.title}</div>
|
||||
<a class="icon" href="./tagListInfo.html?url=${v.url}&title=${v.title}">${v.title.substr(0,1)}</a>
|
||||
<a class="title" href="./tagListInfo.html?url=${v.url}&title=${v.title}">${v.title}</a>
|
||||
</li>
|
||||
`
|
||||
})
|
||||
@@ -56,14 +56,14 @@ class Index {
|
||||
</div>
|
||||
`
|
||||
})
|
||||
|
||||
this.initSwiper()
|
||||
}
|
||||
|
||||
|
||||
initSwiper() {
|
||||
var mySwiper = new Swiper('.banner', {
|
||||
loop: true, // 循环模式选项
|
||||
|
||||
// 如果需要分页器
|
||||
loop: true,
|
||||
pagination: {
|
||||
el: '.swiper-pagination',
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user