From eeea666ba3a309e080d8f50d1d46c4bed8158c21 Mon Sep 17 00:00:00 2001 From: zhuangtongfa Date: Thu, 20 Jul 2017 16:08:14 +0800 Subject: [PATCH] improve docs --- README-EN.md | 2 ++ README.md | 1 + src/app.js | 7 ++++--- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/README-EN.md b/README-EN.md index bfd9dbe..ed1c9eb 100644 --- a/README-EN.md +++ b/README-EN.md @@ -182,6 +182,8 @@ The browser will go to [http://localhost:8080](http://localhost:8080) ### multi-language In the [i18n.json](https://github.com/Binaryify/vue-tetris/blob/master/src/i18n.json)is the configuration for the multi-language environment. You can change the language by passing the url parameter `lan` like this: `https://Binaryify.github.io/vue-tetris/?lan=en` + +`http://binaryify.github.io/vue-tetris/?lan=zh` ### Build ``` npm run build diff --git a/README.md b/README.md index 90c0ba1..fa9fc26 100644 --- a/README.md +++ b/README.md @@ -189,6 +189,7 @@ npm run dev ### 多语言 在 [i18n.json](https://github.com/Binaryify/vue-tetris/blob/master/src/i18n.json) 配置多语言环境,使用"lan"参数匹配语言如:`https://Binaryify.github.io/vue-tetris/?lan=en` +`http://binaryify.github.io/vue-tetris/?lan=zh` ### 打包编译 ``` npm run build diff --git a/src/app.js b/src/app.js index 795d9d6..f9587cc 100644 --- a/src/app.js +++ b/src/app.js @@ -112,9 +112,10 @@ export default { const speedRun = this.$store.state.speedRun let timeout = speeds[speedRun - 1] / 2 // 继续时, 给予当前下落速度一半的停留时间 // 停留时间不小于最快速的速度 - timeout = speedRun < speeds[speeds.length - 1] - ? speeds[speeds.length - 1] - : speedRun + timeout = + speedRun < speeds[speeds.length - 1] + ? speeds[speeds.length - 1] + : speedRun states.auto(timeout) }