var _____WB$wombat$assign$function_____ = function(name) {return (self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init(name)) || self[name]; };
if (!self.__WB_pmw) { self.__WB_pmw = function(obj) { this.__WB_source = obj; return this; } }
{
  let window = _____WB$wombat$assign$function_____("window");
  let self = _____WB$wombat$assign$function_____("self");
  let document = _____WB$wombat$assign$function_____("document");
  let location = _____WB$wombat$assign$function_____("location");
  let top = _____WB$wombat$assign$function_____("top");
  let parent = _____WB$wombat$assign$function_____("parent");
  let frames = _____WB$wombat$assign$function_____("frames");
  let opener = _____WB$wombat$assign$function_____("opener");

$('document').ready(function () {
	var autoScroll = localStorage['autoScroll'] ? true : false;
	if (window.Options && Options.get_tab('general')){
		Options.extend_tab('general','<label id=\'autoScroll\'><input type=\'checkbox\' />' + ' Scroll to new posts' + '</label>');
		$('#autoScroll').find('input').prop('checked', autoScroll);
	}
	$('#autoScroll').on('change', function() {
		if(autoScroll) {
			delete localStorage.autoScroll;
		} else {
			localStorage.autoScroll = true;
		}
		autoScroll =! autoScroll
		if(active_page == 'thread')
			$('input.auto-scroll').prop('checked', autoScroll);
	});
	if (active_page == 'thread') {
		$('span[id="updater"]').children('a').after(' (<input class="auto-scroll" type="checkbox"></input> Scroll to New posts)');
		$('input.auto-scroll').prop('checked', autoScroll);
		$(document).on('new_post', function (e, post) {
			if ($('input.auto-scroll').prop('checked')) 
			{
				scrollTo(0, $(post).offset().top - window.innerHeight + $(post).outerHeight(true)); 
			}
		});
	}
});


}
/*
     FILE ARCHIVED ON 21:47:16 Mar 23, 2022 AND RETRIEVED FROM THE
     INTERNET ARCHIVE ON 03:51:22 Mar 03, 2024.
     JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE.

     ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C.
     SECTION 108(a)(3)).
*/
/*
playback timings (ms):
  exclusion.robots: 0.065
  exclusion.robots.policy: 0.055
  cdx.remote: 0.085
  esindex: 0.008
  LoadShardBlock: 495.369 (6)
  PetaboxLoader3.resolve: 217.557 (4)
  PetaboxLoader3.datanode: 439.475 (8)
  load_resource: 264.015 (2)
*/