forked from tastytea/userscripts
rbb24_expand_comments: Match every page on rbb24.de.
This commit is contained in:
parent
e04526fd69
commit
722127779a
|
@ -2,7 +2,7 @@
|
|||
// @name Expand rbb24.de comments
|
||||
// @description Loads all comments under articles on rbb24.de and expands them.
|
||||
// @description:de Lädt alle kommentare unter artikeln auf rbb24.de und klappt sie aus.
|
||||
// @version 2019.06.07.3
|
||||
// @version 2019.06.07.4
|
||||
// @author tastytea
|
||||
// @copyright 2019, tastytea (https://tastytea.de/)
|
||||
// @license GPL-3.0-only
|
||||
|
@ -11,14 +11,20 @@
|
|||
// @supportURL https://schlomp.space/tastytea/userscripts/issues
|
||||
// @downloadURL https://schlomp.space/tastytea/userscripts/raw/branch/main/comment-sections/rbb24_expand_comments.user.js
|
||||
// @grant none
|
||||
// @match https://*.rbb24.de/*/beitrag/*
|
||||
// @match https://*.rbb24.de/*
|
||||
// @run-at document-end
|
||||
// @inject-into content
|
||||
// ==/UserScript==
|
||||
|
||||
function expand_comments()
|
||||
{
|
||||
document.getElementsByClassName("load_more_comments")[0].click();
|
||||
const loadmore = document.getElementsByClassName("load_more_comments")[0];
|
||||
if (loadmore === undefined) // Cancel if we are not on an article page.
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
loadmore.click();
|
||||
setTimeout(function() // Wait for comments to load.
|
||||
{
|
||||
document.getElementsByClassName("show_all")[0].click();
|
||||
|
|
Loading…
Reference in New Issue