mirror of
https://github.com/internetarchive/brozzler.git
synced 2025-04-21 08:06:27 -04:00
Merge branch 'ARI-5617' into qa
This commit is contained in:
commit
d371db8166
@ -264,7 +264,7 @@ def jinja2_environment(behaviors_dir=None):
|
||||
'js-templates'))
|
||||
else:
|
||||
_loader=jinja2.PackageLoader('brozzler', 'js-templates')
|
||||
_jinja2_env = jinja2.Environment(loader=_loader)
|
||||
_jinja2_env = jinja2.Environment(loader=_loader, auto_reload=False)
|
||||
_jinja2_env.filters['json'] = json.dumps
|
||||
return _jinja2_env
|
||||
|
||||
|
@ -21,6 +21,13 @@
|
||||
url_regex: '^https?://(?:www\.)?facebook\.com/.*$'
|
||||
behavior_js_template: facebook.js
|
||||
request_idle_timeout_sec: 30
|
||||
-
|
||||
url_regex: '^https?://americaspresidents\.si\.edu/gallery.*$'
|
||||
behavior_js_template: umbraBehavior.js.j2
|
||||
default_parameters:
|
||||
actions:
|
||||
- selector: div.see-more, li.next
|
||||
idcheck: false
|
||||
-
|
||||
url_regex: '^https?://(?:www\.)?marquette\.edu/.*$'
|
||||
behavior_js_template: marquette_edu.js
|
||||
|
@ -158,7 +158,7 @@ class Chrome:
|
||||
'--disable-background-networking',
|
||||
'--disable-renderer-backgrounding', '--disable-hang-monitor',
|
||||
'--disable-background-timer-throttling', '--mute-audio',
|
||||
'--disable-web-sockets', '--disable-cache',
|
||||
'--disable-web-sockets', '--disable-cache', '--single-process',
|
||||
'--window-size=1100,900', '--no-default-browser-check',
|
||||
'--disable-first-run-ui', '--no-first-run',
|
||||
'--homepage=about:blank', '--disable-direct-npapi-requests',
|
||||
|
@ -33,6 +33,7 @@ class UmbraBehavior {
|
||||
// should match older default and simpleclicks behavior, and more
|
||||
var k = this.index;
|
||||
var selector = this.actions[k].selector;
|
||||
var idCheck = this.actions[k].idcheck ? this.actions[k].idcheck : true;
|
||||
var action = this.actions[k].do ? this.actions[k].do : 'click';
|
||||
var closeSelector = this.actions[k].closeSelector ? this.actions[k].closeSelector : null;
|
||||
var didSomething = false;
|
||||
@ -62,7 +63,7 @@ class UmbraBehavior {
|
||||
continue;
|
||||
}
|
||||
for ( var i = 0; i < doTargetsLength; i++) {
|
||||
if (this.alreadyDone.indexOf(doTargets[i]) > -1) {
|
||||
if idCheck and (this.alreadyDone.indexOf(doTargets[i]) > -1) {
|
||||
continue;
|
||||
}
|
||||
if (!this.isVisible(doTargets[i])) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user