Projet

Général

Profil

Paste
Télécharger (556 octets) Statistiques
| Branche: | Révision:

root / drupal7 / modules / filter / filter.js @ 01dfd3b5

1
(function ($) {
2

    
3
/**
4
 * Automatically display the guidelines of the selected text format.
5
 */
6
Drupal.behaviors.filterGuidelines = {
7
  attach: function (context) {
8
    $('.filter-guidelines', context).once('filter-guidelines')
9
      .find(':header').hide()
10
      .closest('.filter-wrapper').find('select.filter-list')
11
      .bind('change', function () {
12
        $(this).closest('.filter-wrapper')
13
          .find('.filter-guidelines-item').hide()
14
          .siblings('.filter-guidelines-' + this.value).show();
15
      })
16
      .change();
17
  }
18
};
19

    
20
})(jQuery);