mirror of
https://github.com/internetarchive/brozzler.git
synced 2025-07-25 15:55:41 -04:00
Merge pull request #145 from galgeek/no-skipIframes
no skipIframes for umbraBehavior
This commit is contained in:
commit
0a08c01461
2 changed files with 9 additions and 18 deletions
|
@ -25,8 +25,6 @@
|
|||
url_regex: '^https?://(?:www\.)?instagram\.com/.*$'
|
||||
behavior_js_template: umbraBehavior.js.j2
|
||||
default_parameters:
|
||||
interval: 500
|
||||
skip_iframes: true
|
||||
actions:
|
||||
- selector: button.coreSpriteDismissLarge
|
||||
- selector: 'a>.eLAPa>.KL4Bh'
|
||||
|
|
|
@ -26,11 +26,6 @@ class UmbraBehavior {
|
|||
this.idleSince = null;
|
||||
this.intervalId = null;
|
||||
this.intervalTimeMs = {{interval or 300}};
|
||||
{% if skip_iframes %}
|
||||
this.skipIframes = true;
|
||||
{% else %}
|
||||
this.skipIframes = false;
|
||||
{% endif %}
|
||||
this.index = 0;
|
||||
}
|
||||
|
||||
|
@ -48,7 +43,6 @@ class UmbraBehavior {
|
|||
|
||||
var documents = [];
|
||||
documents[0] = document;
|
||||
if (!(this.skipIframes)) {
|
||||
var iframes = document.querySelectorAll("iframe");
|
||||
var iframesLength = iframes.length;
|
||||
for (var i = 0; i < iframesLength; i++) {
|
||||
|
@ -60,7 +54,6 @@ class UmbraBehavior {
|
|||
// console.log("exception looking at iframe" + iframes[i] + ": " + e);
|
||||
}
|
||||
}
|
||||
}
|
||||
var documentsLength = documents.length;
|
||||
for (var j = 0; j < documentsLength; j++) {
|
||||
if (closeSelector) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue