You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ranger.apache.org by ni...@apache.org on 2020/11/10 10:46:30 UTC

[ranger] 02/02: RANGER-3076 : [New UI] if service side bar expanded then include/exclude toggle button in hive policy gets shrink

This is an automated email from the ASF dual-hosted git repository.

ni3galave pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ranger.git

commit 587353f13f7626f5e0fd90ec89982bc4dbda86a4
Author: Nitin Galave <ni...@apache.org>
AuthorDate: Mon Nov 9 23:01:11 2020 +0530

    RANGER-3076 : [New UI] if service side bar expanded then include/exclude toggle button in hive policy gets shrink
---
 .../scripts/views/policies/RangerPolicyCreate.js   | 11 +++---
 security-admin/src/main/webapp/styles/xa.css       | 43 +++++++++++++++++++++-
 2 files changed, 48 insertions(+), 6 deletions(-)

diff --git a/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyCreate.js b/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyCreate.js
index f5ecc19..65c4f66 100644
--- a/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyCreate.js
+++ b/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyCreate.js
@@ -154,11 +154,12 @@ define(function(require){
 
 		/** on render callback */
 		onRender: function() {
-			// if(localStorage.getItem('setOldUI') == "false" || localStorage.getItem('setOldUI') == null) {
-			// 	App.rContent.$el.addClass('expanded-contant');
-			// } else {
-			// 	App.rContent.$el.removeClass('expanded-contant');
-			// }
+			if((localStorage.getItem('setOldUI') == "false" || localStorage.getItem('setOldUI') == null)
+				&& App.rSideBar.$el.hasClass('expanded')) {
+				App.rContent.$el.addClass('expanded-contant');
+			} else {
+				App.rContent.$el.removeClass('expanded-contant');
+			}
 			XAUtil.showAlerForDisabledPolicy(this);
 			this.rForm.show(this.form);
 			this.rForm.$el.dirtyFields();
diff --git a/security-admin/src/main/webapp/styles/xa.css b/security-admin/src/main/webapp/styles/xa.css
index c9edbfa..3c7a7b8 100644
--- a/security-admin/src/main/webapp/styles/xa.css
+++ b/security-admin/src/main/webapp/styles/xa.css
@@ -4461,7 +4461,48 @@ input.textFiledInputPadding:disabled {
   position: relative;
   bottom: 6px;
   cursor: pointer;
-}/*[fieldclass="resorces-css"] .control-label {
+}
+
+.recursive-toggle .toggle-off {
+  margin-left: -12px !important;
+}
+
+@media (min-width: 2000px){
+  .expanded-contant .include-toggle{
+    margin-left:400px;
+  }
+  .expanded-contant .recursive-toggle-2{
+    margin-left:500px;
+  }
+  .recursive-toggle-2 {
+    margin-left:600px;
+  }
+}
+
+@media (min-width: 2500px){
+  .expanded-contant .include-toggle{
+    margin-left:500px;
+  }
+  .expanded-contant .recursive-toggle-2{
+    margin-left:600px;
+  }
+  .recursive-toggle-2 {
+    margin-left:700px;
+  }
+}
+
+@media (min-width: 3000px){
+  .expanded-contant .include-toggle{
+    margin-left:550px;
+  }
+  .expanded-contant .recursive-toggle-2{
+    margin-left:650px;
+  }
+  .recursive-toggle-2 {
+    margin-left:750px;
+  }
+}
+/*[fieldclass="resorces-css"] .control-label {
   margin-top: 0px;
   margin-right: -15px
 }*/