Sha256: 064bf83f0122a83a4ec2ccbfa880318b2b529d0e0871cce47e716a5063b8cb88

Contents?: true

Size: 1004 Bytes

Versions: 1

Compression:

Stored size: 1004 Bytes

Contents

//= require jquery
//= require jquery_ujs
//= require ./bootstrap
//= require ./prettify

$(function() {
  if($('#first-focus').length > 0) {
    $('#first-focus').focus();
  }

  $('.dropdown-toggle').dropdown()
});

var JABE = function() {
  return {
    updateSortables: function(parent) {
      var elems = $(parent + ' ul li .position'), i = 1
      elems.each(function() {
        this.value = i++
      })
    },

    sizeTehToolbars: function() {
      $('.textile-toolbar').each(function() {
        box_id = this.id.replace('textile-toolbar-', '')
        $(this).css('width', $('#' + box_id).css('width'))
      })
    },

    load_gat: function(code) {
      if (code) {
        var host = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
        jQuery.getScript(host + "google-analytics.com/ga.js", function(){
          var tracker = _gat._getTracker(code);
          tracker._initData();
          tracker._trackPageview();
        });
      }
    }
  };
}();

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jabe-0.8.0 app/assets/javascripts/jabe/application.js