<commit_before>$(function() {

  // defining variables for later use since they will be hoisted anyway because they aren't inside a function
  var topOffset = 145,
        $window = $(window),
      $stickyEl = $('.navbar');

  // giving content padding when navbar changes to fixed and loses height  
  var elTop = $stickyEl.offset().top;

  $window.scroll(function() {
    var navBarTop = $window.scrollTop();
    $('.navbar').next().toggleClass('content-fixed-padding', navBarTop > topOffset);
    $('body').toggleClass('scroll-shadow', navBarTop > topOffset);
  });

  // bootstrap fixing top nav when offset is higher than topOffset
  $('.navbar').affix({ offset: { top: topOffset } });

  // tooltip sstuff
  $('a[rel=tooltip]').tooltip();

  $('.form-search').submit(function() {
    if($(this).find('input[type=text]').val() === "") {
      return false;
    }
  });

  // popovers 
  $('a[rel=popover]').popover({
    delay: { 
      show: 100, 
      hide: 0 
    },
    trigger: 'hover',
    placement: function() {
      if($(window).scrollTop() > 145) {
        return "bottom";
      } else {
        return "top";
      }
    },
    animation: true,
    html: true
  });

  // making links unclickable
  $('.unclickable').css({'cursor': 'default'});
  $('.unclickable').click(function(e) {
    e.preventDefault();
    return false;
  });

  // TAKE OUT IF USING REAL NAV
  $('.nav > li > a').click(function() {
    if($(this).attr('href') === "#") {<commit_msg>added prettyprint support + updated popover position change on offset<commit_after>$(function() {

  // initializing pretty print for entire site
  window.prettyPrint && prettyPrint(); 

  // defining variables for later use since they will be hoisted anyway because they aren't inside a function
  var topOffset = 145,
        $window = $(window),
      $stickyEl = $('.navbar');

  // giving content padding when navbar changes to fixed and loses height  
  var elTop = $stickyEl.offset().top;

  $window.scroll(function() {
    var navBarTop = $window.scrollTop();
    $('.navbar').next().toggleClass('content-fixed-padding', navBarTop > topOffset);
    $('body').toggleClass('scroll-shadow', navBarTop > topOffset);
  });

  // bootstrap fixing top nav when offset is higher than topOffset
  $('.navbar').affix({ offset: { top: topOffset } });

  // tooltip sstuff
  $('a[rel=tooltip]').tooltip();

  $('.form-search').submit(function() {
    if($(this).find('input[type=text]').val() === "") {
      return false;
    }
  });

  // popovers 
  $('a[rel=popover]').popover({
    delay: { 
      show: 100, 
      hide: 0 
    },
    trigger: 'hover',
    placement: function() {
      if($(window).scrollTop() > 120) {
        return "bottom";
      } else {
        return "top";
      }
    },
    animation: true,
    html: true
  });

  // making links unclickable
  $('.unclickable').css({'cursor': 'default'});
  $('.unclickable').click(function(e) {
    e.preventDefault();
    return false;
  });

  // TAKE OUT IF USING REAL NAV
  $('.nav > li > a').click(function() {
    if($(this).attr('href') === "#") {
{'fraction_non_alphanumeric': 0.18443152454780362, 'fraction_numerical': 0.006459948320413436, 'mean_word_length': 2.9152970922882426, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6011263', 'n_tokens_mistral': 1019, 'n_tokens_neox': 947, 'n_words': 238}