From 0ec2843b0f660a0442ee0d82fa4879c86c8d06ec Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Sat, 29 Sep 2012 09:20:05 -0700 Subject: [PATCH] Eliminate interpolation in edit JS --- app/views/site/edit.html.erb | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/app/views/site/edit.html.erb b/app/views/site/edit.html.erb index f99f17f1e..abbb5918f 100644 --- a/app/views/site/edit.html.erb +++ b/app/views/site/edit.html.erb @@ -22,11 +22,11 @@ $("#tabnav").hide(); $("#content").css("top", "0px"); - <% if t('html.dir') == "ltr" -%> - $("#content").css("left", "0px"); - <% else -%> - $("#content").css("right", "0px"); - <% end -%> + if ($("html").attr("dir") == "ltr") { + $("#content").css("left", "0px"); + } else { + $("#content").css("right", "0px"); + } handleResize(); } @@ -37,11 +37,11 @@ $("#tabnav").show(); $("#content").css("top", "30px"); - <% if t('html.dir') == "ltr" -%> - $("#content").css("left", "185px"); - <% else -%> - $("#content").css("right", "185px"); - <% end -%> + if ($("html").attr("dir") == "ltr") { + $("#content").css("left", "185px"); + } else { + $("#content").css("right", "185px"); + } handleResize(); } -- 2.43.2