Sha256: 90da7d62276d3d622b1d5a773c51a57ccb3497e5c242bfc8558e4bbf5c366a3e

Contents?: true

Size: 1.84 KB

Versions: 3

Compression:

Stored size: 1.84 KB

Contents

o: ActiveSupport::Cache::Entry	:@compressedF:@expires_in0:@created_atf1358560041.326785:@value"ð{I"
class:EFI"BundledAsset;FI"logical_path;FI"&showboat/plugins/slide_heading.js;FI"
pathname;FI"]/Users/mkitt/Sites/showboat/app/assets/javascripts/showboat/plugins/slide_heading.coffee;FI"content_type;FI"application/javascript;FI"
mtime;FI"2013-01-18T18:47:16-07:00;FI"length;FiI"digest;F"%25876709b803a2ce985362462b20de31I"source;FI"(function() {

  window.SlideHeading = (function() {

    function SlideHeading(reveal) {
      var _this = this;
      this.reveal = reveal;
      this.header = document.querySelector('#main_heading');
      this.heading = this.header.querySelector('h1');
      this.reveal.addEventListener('slidechanged', function() {
        return _this.render.apply(_this, arguments);
      });
      this.render({
        currentSlide: _.last(document.querySelectorAll('.present'))
      });
    }

    SlideHeading.prototype.render = function(e) {
      var markup, method, slide;
      slide = e.currentSlide;
      markup = this.title(slide);
      markup += this.link(slide);
      method = _.isEmpty(markup) ? 'remove' : 'add';
      this.heading.innerHTML = markup;
      return this.header.classList[method]('in');
    };

    SlideHeading.prototype.title = function(slide) {
      return slide.getAttribute('data-heading') || '';
    };

    SlideHeading.prototype.link = function(slide) {
      var link, src;
      link = slide.getAttribute('data-link');
      if (!link) {
        return '';
      }
      src = slide.getAttribute('data-src') || "#";
      return "<a href='" + src + "' target='_blank'>" + link + "</a>";
    };

    return SlideHeading;

  })();

}).call(this);
;FI"required_assets_digest;F"%9b7f093259ffd7a8e27febc238054d41I"
_version;F"%6776f581a4329e299531e1d52aa59832

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
showboat-0.0.3 spec/dummy/tmp/cache/assets/D65/BD0/sprockets%2F1373ff33c888f034e03a9cbe3050fdba
showboat-0.0.2 spec/dummy/tmp/cache/assets/D65/BD0/sprockets%2F1373ff33c888f034e03a9cbe3050fdba
showboat-0.0.1 spec/dummy/tmp/cache/assets/D65/BD0/sprockets%2F1373ff33c888f034e03a9cbe3050fdba