Skip to content

Commit

Permalink
feature: 昨日重现快捷键
Browse files Browse the repository at this point in the history
  • Loading branch information
Benature committed May 14, 2020
1 parent 70caddb commit da329af
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ python manage.py migrate
| 不认识 | <kbd>Shift</kbd>+<kbd>←</kbd> | 复习页面 | 复习状态 |
| 复制`WordSand`助记法 | <kbd>C</kbd> (Copy) | 复习页面 | 安装Chrome插件 |
| 跳转到日历页面 | <kbd>C</kbd> (Calendar) | 主页 | - |
| 跳转到昨日重现 | <kbd>R</kbd> (Review) | 主页 | - |

### 词根词缀词源拆词渲染

Expand Down
5 changes: 3 additions & 2 deletions WordReview/apps/review/templates/homepage.pug
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ div.container.flex-column

#tmpl-qotd

div.list-block(href="/review/review?review=1/" style="width: 35%!important; align-self: center;")
div#yesterday-mode.list-block(href="/review/review?review=1/" style="width: 35%!important; align-self: center;")
a 昨日重现

{% for d in data%}
Expand Down Expand Up @@ -91,7 +91,8 @@ div.container.flex-column
a(style="text-align:end;margin-top:30px" href="/import/") 我要导入新的单词书
hr
div.text-center(style="margin-bottom: 130px;")
a(style="color:black;" href="https://github.com/Benature/WordReview/issues")
p(style="color:black;" href="https://github.com/Benature/WordReview/issues")
i.icon-github
| &nbsp;意见反馈
a.text-center(style="color:grey; font-size:10px;" href="https://github.com/Benature/WordReview") 如果能帮到您,希望可以在 GitHub 点个 Star🌟 不胜感激🙇‍♂️
{% endblock %}
9 changes: 8 additions & 1 deletion WordReview/static/js/homepage.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,11 @@ $.ajax({
let latest = response[0].commit;
let date = latest.committer.date.replace('T', ' ').replace('Z', '');
$('#github-commit').text('上一次源码更新于' + date + ',更新附言为「' + latest.message + '」');
})
})

$(document).keyup(function (e) {
console.log(e.keyCode);
if (82 == e.keyCode) {
$('#yesterday-mode').click();
}
});

0 comments on commit da329af

Please sign in to comment.