Specify location of jstree css and improve menu-editing theme
authorColeman Watts <coleman@civicrm.org>
Tue, 12 Mar 2013 04:29:16 +0000 (21:29 -0700)
committerColeman Watts <coleman@civicrm.org>
Tue, 12 Mar 2013 04:29:16 +0000 (21:29 -0700)
js/view/crm.designer.js
templates/CRM/Admin/Page/Navigation.tpl
templates/CRM/Tag/Form/Tag.tpl

index 542f16f4fa0342b0dee4c68609232635596a019b..8d1509c3f15222a2bcf19c441e1fccccbf2eea20 100644 (file)
         themes: {
           "theme": 'classic',
           "dots": false,
-          "icons": false
+          "icons": false,
+          "url": CRM.config.resourceBase + 'packages/jquery/plugins/jstree/themes/classic/style.css'
         },
         'plugins': ['themes', 'json_data', 'ui', 'search']
       }).bind('loaded.jstree', function () {
index 76a25950a2c8af58f26ca3d338575a1ac25e48a5..c0dbfff70b251d39be7946f5d035b2a8015b2489 100644 (file)
     <div class="spacer"></div>
   </div>
   {literal}
+  <style type="text/css">
+    #navigation-tree li {
+      font-weight: normal;
+    }
+    #navigation-tree > ul > li {
+      font-weight: bold;
+    }
+  </style>
   <script type="text/javascript">
     cj(function () {
     cj("#navigation-tree").jstree({
         url : {/literal}"{crmURL p='civicrm/ajax/menu' h=0 q='key='}{crmKey name='civicrm/ajax/menu'}"{literal}
       }
     },
+    themes: {
+      "theme": 'classic',
+      "dots": true,
+      "icons": false,
+      "url": CRM.config.resourceBase + 'packages/jquery/plugins/jstree/themes/classic/style.css'
+    },
     rules : {
       droppable : [ "tree-drop" ],
       multiple : true,
@@ -64,7 +78,6 @@
       move: {
         check_move: function(m) {
           var homeMenuId = {/literal}"{$homeMenuId}"{literal};
-
           if ( cj( m.r[0] ).attr('id').replace("node_","") == homeMenuId ||
             cj( m.o[0] ).attr('id').replace("node_","") == homeMenuId ) {
             return false;
index 3129241867138e20aa2a2f276853f3976a80accd..92001c959c492417f2ed3737869d8890aa08610a 100644 (file)
       });
 
       //load js tree.
-      cj("#tagtree").jstree({"plugins" : ["themes", "html_data"]});
+      cj("#tagtree").jstree({
+        "plugins" : ["themes", "html_data"],
+        "themes": {"url": CRM.config.resourceBase + 'packages/jquery/plugins/jstree/themes/default/style.css'}
+      });
 
       {/literal}
       {if $permission neq 'edit'}