luci-theme-luci: Match css to implement related styles 2306/head
authorYanlan Shen <yanlan.shen.@rosinson.com>
Mon, 19 Nov 2018 05:37:36 +0000 (13:37 +0800)
committerYanlan Shen <yanlan.shen.@rosinson.com>
Mon, 19 Nov 2018 06:09:15 +0000 (14:09 +0800)
Signed-off-by: Yanlan Shen <yanlan.shen.@rosinson.com>
themes/luci-theme-rosy/htdocs/luci-static/rosy/js/script.js

index 11d3cd68ae6a03041789a5095abc52b41d9a7c72..8985834eff1f62982d15eb172ed644afb387330d 100755 (executable)
         
     })
 
-    if(  $(window).width() > 992 ){
-        $('.logged-in .main-right').width( $(window).width() - $('.logged-in .main-left').width() - 50 );
-    }
-    
     $('body.logged-in').css('min-height', $(window).height());
     
+    $(function(){
+        if(  $(window).width() > 992 ){
+            $('.logged-in .main-right').outerWidth( $(window).width() - $('.logged-in .main-left').width() - 50 );
+        }
+        var a = window.getComputedStyle($(".cbi-section .table .tr:first-child")[0], ':before').getPropertyValue('content');
+        var b = window.getComputedStyle($('.cbi-section .table .tr:last-child')[0], ':before').getPropertyValue('content');
+        console.log(typeof a);
+        
+        if( a != 'none' || b != 'none' ){
+            $('.cbi-section .table .tr:first-child .td:first-child').css('border-top-left-radius', '0');
+            $('.cbi-section .table .tr:last-child .td:first-child').css('border-bottom-left-radius', '0');
+            $('.cbi-section .table .tr:first-child .th:first-child').css('border-top-left-radius', '0');
+            console.log($('.cbi-section .table .tr:last-child .td:first-child'));
+            
+        }
+    });
+
 })(jQuery);