tripal_feature.js 676 B

12345678910111213141516171819
  1. (function($) {
  2. Drupal.behaviors.tripal_featureBehavior = {
  3. attach: function (context, settings){
  4. // the following function is used when viewing sequence alignments
  5. // on the feature page. When mousing over the feature type legend
  6. // it should highlight regions in the sequence
  7. $('.tripal_feature-legend-item').bind("mouseover", function(){
  8. var classes = $(this).attr('class').split(" ");
  9. var type_class = classes[1];
  10. $("." + type_class).css("border", "1px solid red");
  11. $(this).bind("mouseout", function(){
  12. $("." + type_class).css("border", "0px");
  13. })
  14. });
  15. }
  16. };
  17. })(jQuery);