Commits

shl...@13c2ddb8-3aa7-4284-800b-8db07c650eef  committed a15d2a7

Extracted a variable.

  • Participants
  • Parent commits c710740
  • Branches css-tweaking-for-the-about-links

Comments (0)

Files changed (1)

File src/js/position_divs.js

 function position_divs() {
     var client_w = document.body.clientWidth ;
     var width = client_w - 780;
-    document.getElementById("js-site-name").style.left   = width / 2 + 20 + "px";
-    document.getElementById("js-site-slogan").style.left = width / 2 + 20 + "px";
+    var js_site_w_str = width / 2 + 20 + "px";
+
+    document.getElementById("js-site-name").style.left = js_site_w_str;
+    document.getElementById("js-site-slogan").style.left = js_site_w_str;
+
     // Commenting out because it no longer exists.
     // document.getElementById("js-nav-global").style.right = width / 2 - 20 + "px";
     if ( document.getElementById("right-sidebar") == null ) {