Difference between revisions of "Team:NKU China/test"

Line 150: Line 150:
 
         }
 
         }
  
         //This event is triggered by <img>, which is 100% embed in its parent.
+
         //element is $(<img>), which is 100% embed in its parent.
 
         //So automatically adjust the parent can simultaneously automatically adjust the <img>
 
         //So automatically adjust the parent can simultaneously automatically adjust the <img>
         var auto_adjust_parent = function (event) {
+
         var auto_adjust_parent = function (element) {
 
+
             var impl = function () {
             window.addEventListener('resize', function () {
+
                 var parent = $(element).parent();
                alert("resize")
+
                 var parent = $(event.target).parent();
+
                console.log(parent.html())
+
                console.log('div-width:' + parent().width())
+
                console.log('main-width:' + parent().parent().width())
+
 
                 parent.width(parent.parent().width());
 
                 parent.width(parent.parent().width());
 
                 parent.height(parent.parent().width() * 9 / 16);
 
                 parent.height(parent.parent().width() * 9 / 16);
                console.log('div-width:' + parent().width())
+
            }
                console.log('main-width:' + parent().parent().width())
+
 
            })
+
            impl();
 +
            window.addEventListener('resize', impl)
 
         }
 
         }
 
         //var adjust_group_gallery = function () {
 
         //var adjust_group_gallery = function () {
Line 189: Line 185:
 
         //}
 
         //}
 
         $(function () {
 
         $(function () {
 +
            auto_adjust_parent($('#group-gallery img:first-child'))
 +
 
             var img = new Image();
 
             var img = new Image();
 
             //document.querySelector('#group-gallery img:first-child').src = 'image/whole-group-1366.jpg';
 
             //document.querySelector('#group-gallery img:first-child').src = 'image/whole-group-1366.jpg';
Line 214: Line 212:
 
         </div>
 
         </div>
 
         <div id="group-gallery">
 
         <div id="group-gallery">
             <img src="whole-group-1366.jpg" width="1366" height="770" alt="Please wait, loading image..." onerror="auto_adjust_parent(event)" onload="auto_adjust_parent(event)"/>     
+
             <img src="whole-group-1366.jpg" width="1366" height="770" alt="Please wait, loading image..."/>     
 
         </div>
 
         </div>
  

Revision as of 16:01, 4 August 2016

Team Introduction

Team NKU_China consists of faculty members and students from Nankai University, Tianjin. Located in the east coast of Asia and one of the most developed and prosperous cities in mainland China, Nankai University is making groundbreaking progress in both natural and social sciences while holding fast to the orthodox beliefs that inspire us to dedicate to the interest of the public and the nation.

17 undergraduate students from College of Life Science consist of the absolute main force of Team NKU_China. Sharing “iGEMer” as our common title, the team members work closely together from brainstorming solutions for experimental problems to discussing the future prospect of synthetic biology with great enthusiasm and creation. In the meantime, we frequently adjust the project design and experiment plans under the advice and instructions of three experienced graduate instructors and three distinguished PIs.

All of the team members are looking forward to presenting our project and sharing the story of the great science adventure of Team NKU_China to iGEMers all over the globe at Giant Jamboree. Do meet us at our presentation and poster stand!