Last active
January 19, 2024 21:41
-
-
Save dofy/54caa572ad8eb87b446bf8a5f9dd77c9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Douban Hotkeys | |
// @description Show Hotkeys of douban.com in console | |
// @match *://www.douban.com/ | |
// ==/UserScript== | |
const tables = [] | |
function KEY(key, desc) { | |
this.key = key | |
this.desc = desc | |
} | |
const table = (key, desc) => { | |
tables.push(new KEY(key, desc)) | |
} | |
table('/', 'focus search input box') | |
table('j', 'next status') | |
table('k', 'prev status') | |
table('a', 'like') | |
table('t', 'reply') | |
table('r', 'relay') | |
table('i', 'focus reply input box') | |
table('n', 'new status') | |
table('gg', 'go to top of page') | |
table('shift + g', 'go to bottom of page') | |
table('\{', 'prev page') | |
table('\}', 'next page') | |
table('p1', 'first page') | |
console.group('Douban Hotkeys') | |
console.table(tables) | |
console.groupEnd() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment