Selaa lähdekoodia

Merge branch '7.x-2.x-ds' of github.com:tripal/tripal into 7.x-2.x-ds

Stephen Ficklin 8 vuotta sitten
vanhempi
commit
aff71675e1
1 muutettua tiedostoa jossa 14 lisäystä ja 19 poistoa
  1. 14 19
      tripal_ds/theme/js/tripal_ds.js

+ 14 - 19
tripal_ds/theme/js/tripal_ds.js

@@ -30,25 +30,20 @@
           var id = '.tripal_pane-fieldset-' + $(this).attr('id');
           var prevObj = $(id).prev().attr('class');
             // If the user clicks on other TOC item, move its fieldset to the top 
-              $(id + ' fieldset').removeClass('collapsed');
-              $(id + ' fieldset .fieldset-wrapper').show();
-              // Hightlight the fieldset instead of moving if it's already at the top
-              if (prevObj.indexOf('group-tripal-pane-content-top') == 0) {
-                $(id + ' fieldset').fadeTo(10, 0.3, function() {});
-                $(id + ' fieldset').fadeTo(200, 1, function() {});
-              }
-              if ($(id).hasClass('hideTripalPane')) {
-                $(id).removeClass('hideTripalPane');
-                $(id).addClass('showTripalPane');
-                $(id + ' fieldset .fieldset-wrapper').hide();
-                var obj = $(id).detach();
-                $('.group-tripal-pane-content-top').after(obj);
-              }
-              else {
-                $(id + ' fieldset .fieldset-wrapper').hide();
-                var obj = $(id).detach();
-                $('.group-tripal-pane-content-top').after(obj);
-              }
+            $(id + ' fieldset').removeClass('collapsed');
+            $(id + ' fieldset .fieldset-wrapper').show();
+            // Hightlight the fieldset instead of moving if it's already at the top
+            if (prevObj.indexOf('group-tripal-pane-content-top') == 0) {
+              $(id + ' fieldset').fadeTo(10, 0.3, function() {});
+              $(id + ' fieldset').fadeTo(200, 1, function() {});
+            }
+            if ($(id).hasClass('hideTripalPane')) {
+              $(id).removeClass('hideTripalPane');
+              $(id).addClass('showTripalPane');
+            }
+            $(id + ' fieldset .fieldset-wrapper').hide();
+            var obj = $(id).detach();
+            $('.group-tripal-pane-content-top').after(obj);
             $(id + ' fieldset .fieldset-wrapper').show(300);
           return false;
         });