Team:Heidelberg/Team
From 2013.igem.org
(Difference between revisions)
m |
m |
||
Line 7: | Line 7: | ||
<!-- Teammembers --> | <!-- Teammembers --> | ||
- | <div class="container" id="picscontainer" style="height:500px;position:relative;padding: 170px 150px 170px 150px"> | + | <div class="container" id="picscontainer" style="height:500px;position:relative;padding: 170px 150px 170px 150px;max-width:99%;"> |
<div id="memberdesc" class="panel panel-danger" style="margin:3%; max-width:100%; max-height:100%;display:none"> | <div id="memberdesc" class="panel panel-danger" style="margin:3%; max-width:100%; max-height:100%;display:none"> | ||
<div class="panel-heading"><h3></h3></div> | <div class="panel-heading"><h3></h3></div> | ||
Line 110: | Line 110: | ||
var images = $('.teamimage'); | var images = $('.teamimage'); | ||
var picsperside = getPicsPerSide(); | var picsperside = getPicsPerSide(); | ||
- | var height = picsperside. | + | var height = picsperside.v * 170; |
var width = $('#picscontainer').height(height).width(); | var width = $('#picscontainer').height(height).width(); | ||
images.click(function(e){ | images.click(function(e){ | ||
- | stopAnimation(); | + | if (animated) |
+ | stopAnimation(); | ||
var panel = $('#memberdesc'); | var panel = $('#memberdesc'); | ||
panel.find("h3").empty().text($(e.delegateTarget).attr("data-name")); | panel.find("h3").empty().text($(e.delegateTarget).attr("data-name")); | ||
Line 160: | Line 161: | ||
var w = $("#picscontainer").innerWidth(); | var w = $("#picscontainer").innerWidth(); | ||
var currpic = 0; | var currpic = 0; | ||
- | var wdiff = (w - picsperside. | + | var wdiff = (w - picsperside.h * 150) / (picsperside.h - 1) |
- | var rightmost = (picsperside. | + | var rightmost = (picsperside.h - 1) * (150 + wdiff); |
- | for (var i = 0; i < picsperside. | + | for (var i = 0; i < picsperside.h; ++i, ++currpic) { |
$(images[currpic]).css({"left": '', "top": '', "right": '', "bottom": ''}); | $(images[currpic]).css({"left": '', "top": '', "right": '', "bottom": ''}); | ||
$(images[currpic]).animate({"left": i * (150 + wdiff), "top": 0}); | $(images[currpic]).animate({"left": i * (150 + wdiff), "top": 0}); | ||
} | } | ||
- | for (var i = 1; i < picsperside. | + | for (var i = 1; i < picsperside.v - 1; ++i, ++currpic) { |
$(images[currpic]).css({"left": '', "top": '', "right": '', "bottom": ''}); | $(images[currpic]).css({"left": '', "top": '', "right": '', "bottom": ''}); | ||
$(images[currpic]).animate({"left": 0, "top": i * 170}); | $(images[currpic]).animate({"left": 0, "top": i * 170}); | ||
} | } | ||
- | for (var i = 1; i < picsperside. | + | for (var i = 1; i < picsperside.v - 1; ++i, ++currpic){ |
$(images[currpic]).css({"left": '', "top": '', "right": '', "bottom": ''}); | $(images[currpic]).css({"left": '', "top": '', "right": '', "bottom": ''}); | ||
$(images[currpic]).animate({"left": rightmost, "top": i * 170}); | $(images[currpic]).animate({"left": rightmost, "top": i * 170}); |
Revision as of 19:42, 4 October 2013
![](https://static.igem.org/mediawiki/2013/a/a6/Heidelberg_go_up2.png)
![](https://static.igem.org/mediawiki/2013/a/ae/Heidelberg_tour2_btn.png)