Bluesky Image/Video Download Button

Adds a download button to Bluesky images and videos. Built off coredumperror's script with a few improvements.

< 脚本 Bluesky Image/Video Download Button 的反馈

评价:好评 - 脚本运行良好

§
发布于:2025-05-19
编辑于:2025-05-19

Suddenly stopped working but was able to get it work again by adding this to line 240:

let dBtnDupe = downloadBtnParent.getElementsByClassName('download-button')[1];
if (!!dBtnDupe) {dBtnDupe.remove(); return;} 
KanashiiWolf作者
§
发布于:2025-05-19

Thank you for the solution, it made it quick to isolate the cause!

§
发布于:2025-05-20

Thanks for the quick update!

§
发布于:2025-05-22

Alternatively, it's also possible to check for the "processed" attribute when looking at the added nodes (at lines 83 and 89), as that attribute is added by the script when processing nodes and then never used again. I changed line 83 to the following. Similar thing for line 89, but with vid instead of img.

if (img && !img.hasAttribute("processed")) {

I think it may be a little more efficient? Though, I am no expert in Javascript…
Anyways, thank you for maintaining this script!

KanashiiWolf作者
§
发布于:2025-05-22

You are correct, it would reduce the size of the DOM queries. I'll swap to your suggestion.

I had originally gone with: if (downloadBtnParent.getElementsByClassName('download-button').length) return; at L230 in order to do a quick fix and partially skip the double processing. Gonna do a couple other changes with that suggestion to try and reduce the script's load.

发布留言

登录(不可用)以发布留言。

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址