ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dma...@apache.org
Subject svn commit: r1819101 - in /ignite/site/trunk: includes/scripts.html index.html
Date Fri, 22 Dec 2017 23:44:24 GMT
Author: dmagda
Date: Fri Dec 22 23:44:24 2017
New Revision: 1819101

URL: http://svn.apache.org/viewvc?rev=1819101&view=rev
Log:
loading youtube lazily

Modified:
    ignite/site/trunk/includes/scripts.html
    ignite/site/trunk/index.html

Modified: ignite/site/trunk/includes/scripts.html
URL: http://svn.apache.org/viewvc/ignite/site/trunk/includes/scripts.html?rev=1819101&r1=1819100&r2=1819101&view=diff
==============================================================================
--- ignite/site/trunk/includes/scripts.html (original)
+++ ignite/site/trunk/includes/scripts.html Fri Dec 22 23:44:24 2017
@@ -127,15 +127,16 @@ $(document).ready(function() {
 });
 </script>
 
+
 <!--Launch YouTube video in Bootstrap modal-->
 <script type="text/javascript">
 $(document).ready(function(){
     /* Get iframe src attribute value i.e. YouTube video url
     and store it in a variable */
-    var sqldbUrl = $("#sql-db").attr('src');
+    var sqldbUrl = $("#sql-db").attr('data-src-lazy');
     var sqlUrl = $("#sql").attr('src');
-    var dataGridUrl = $("#data-grid").attr('src');
-    var clusteringUrl = $("#clustering").attr('src');
+    var dataGridUrl = $("#data-grid").attr('data-src-lazy');
+    var clusteringUrl = $("#clustering").attr('data-src-lazy');
     var databaseImportUrl = $("#database-import").attr('src');
     var dataLoadingUrl = $("#data-loading").attr('src');
     var webconsoleSqlUrl = $("#webconsole-sql").attr('src');
@@ -173,7 +174,9 @@ $(document).ready(function(){
     /* Assign the initially stored url back to the iframe src
     attribute when modal is displayed again */
     $("#sql-db-modal").on('show.bs.modal', function(){
-        $("#sql-db").attr('src', sqldbUrl);
+        $('.lazy_load').each(function(){
+            $("#sql-db").attr('src', sqldbUrl);
+          });
     });
 
     $("#sql-modal").on('show.bs.modal', function(){
@@ -181,11 +184,15 @@ $(document).ready(function(){
     });
 
     $("#data-grid-modal").on('show.bs.modal', function(){
-        $("#data-grid").attr('src', dataGridUrl);
+        $('.lazy_load').each(function(){
+            $("#data-grid").attr('src', dataGridUrl);
+        });
     });
 
     $("#clustering-modal").on('show.bs.modal', function(){
-        $("#clustering").attr('src', clusteringUrl);
+        $('.lazy_load').each(function(){
+            $("#clustering").attr('src', clusteringUrl);
+        });
     });
 
     $("#database-import-modal").on('show.bs.modal', function(){

Modified: ignite/site/trunk/index.html
URL: http://svn.apache.org/viewvc/ignite/site/trunk/index.html?rev=1819101&r1=1819100&r2=1819101&view=diff
==============================================================================
Binary files - no diff available.



Mime
View raw message