Bilibili-Evolved/video/expand-danmaku.js
2018-10-15 20:23:32 +08:00

25 lines
596 B
JavaScript

(() =>
{
return () =>
{
// TODO: put danmaku selector below
Observer.subtree("", () =>
{
SpinQuery.any(
() => $(".bui-collapse-header"),
button =>
{
if (parseInt($(".bui-collapse-body").css("height")) === 0 &&
$(".bui-collapse-arrow-text").text() === "展开")
{
button.click();
}
}
);
});
return {
ajaxReload: true
};
};
})();