Difference between revisions of "Team:Amsterdam/js/init"

Line 124: Line 124:
 
})(jQuery);
 
})(jQuery);
  
<!--http://stackoverflow.com/questions/27800753/set-image-size-based-on-browser-size-->
 
jQuery(document).ready(function($) {
 
  
    //Initial load of page
 
$(document).ready(sizeContent);
 
//Every resize of window
 
$(window).resize(sizeContent);
 
//Dynamically assign height
 
function sizeContent() {
 
  var newHeight = $(window).height() * 0.6  + "px";
 
    $(".full_image").css("height", newHeight);
 
}
 
 
      
 
      
 
      
 
      

Revision as of 10:57, 15 September 2015

/* Ion by TEMPLATED templated.co @templatedco Released for free under the Creative Commons Attribution 3.0 license (templated.co/license)

  • /

(function($) {

skel.init({ reset: 'full', breakpoints: {

// Global. global: { range: '*', href: 'https://2015.igem.org/Team:Amsterdam/css/styleCss?action=raw&ctype=text/css', /*containers: 1400,*/

                   containers: '100%',

grid: { gutters: { vertical: '4em', horizontal: 0 } } },

// XLarge. xlarge: { range: '-1680', href: 'https://2015.igem.org/Team:Amsterdam/css/stylexLargeCss?action=raw&ctype=text/css', containers: 1200 },

// Large. large: { range: '-1280', href: 'https://2015.igem.org/Team:Amsterdam/css/styleLargeCss?action=raw&ctype=text/css', /*containers: 960,*/

                   containers: 960,

grid: { gutters: { vertical: '2.5em' } }, viewport: { scalable: false } },

// Medium. medium: { range: '-980', href: 'https://2015.igem.org/Team:Amsterdam/css/styleMediumCss?action=raw&ctype=text/css', containers: '90%', grid: { collapse: 1 } },

// Small. small: { range: '-736', href: 'https://2015.igem.org/Team:Amsterdam/css/styleSmallCss?action=raw&ctype=text/css', containers: '90%', grid: { gutters: { vertical: '1.25em' } } },

// XSmall. xsmall: { range: '-480', href: 'https://2015.igem.org/Team:Amsterdam/css/stylexSmallCss?action=raw&ctype=text/css', grid: { collapse: 2 } }

}, plugins: { layers: {

// Config. config: { transform: true },

// Navigation Panel. navPanel: { animation: 'pushX', breakpoints: 'medium', clickToHide: true, height: '100%', hidden: true,

html: '
',

orientation: 'vertical', position: 'top-left', side: 'left', width: 250 },

// Navigation Button. navButton: { breakpoints: 'medium', height: '4em', html: '', position: 'top-left', side: 'top', width: '6em' }

} } });

$(function() {

// jQuery ready stuff.

});

})(jQuery);




});