Skip to content

Instantly share code, notes, and snippets.

@alili
Created November 24, 2021 08:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alili/4649422a85204399b2523c8b6c18ea1a to your computer and use it in GitHub Desktop.
Save alili/4649422a85204399b2523c8b6c18ea1a to your computer and use it in GitHub Desktop.
B站 弹幕管理 油猴脚本
setTimeout(() => {
let 时间数组 = document.querySelectorAll('td:nth-child(3) .colum-content')
let 链接数组 = document.querySelectorAll('a.danmu-content')
链接数组.forEach((链接, 序号) => {
let [s=0,m=0,h=0] = 时间数组[序号].textContent.split(':').reverse()
链接.href = 链接.href + `?t=${h}h${m}m${s}s`
})
}, 1000)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment