夜间模式and移动端细节修正

This commit is contained in:
结发受长生
2019-05-20 13:54:00 +08:00
parent 75370c7cca
commit d3aba8d5ae
4 changed files with 48 additions and 14 deletions
+2 -1
View File
@@ -196,12 +196,13 @@ const waifuTools = {
},
"tools.eye"() {
// 切换到夜间模式
document.querySelector('.mid-col').classList.remove('hide')
let night = document.querySelector('body').classList.toggle('night')
localStorage.setItem('night', night)
},
"tools.chart"() {
// 一言
axios.get('https://www.colorfulsweet.site/hitokoto?length=40&format=json').then(res => {
axios.get('https://www.colorfulsweet.site/api/hitokoto?length=40&format=json').then(res => {
this.showMessage(res.data.hitokoto + (res.data.from?`  ——${res.data.from}`:''))
})
}