Révision ec2b0e7b
Ajouté par Assos Assos il y a presque 7 ans
drupal7/sites/all/themes/bootstrap/js/bootstrap.js | ||
---|---|---|
76 | 76 |
*/ |
77 | 77 |
Drupal.behaviors.bootstrapPopovers = { |
78 | 78 |
attach: function (context, settings) { |
79 |
if (!settings.bootstrap || !settings.bootstrap.popoverEnabled) { |
|
79 |
// Immediately return if popovers are not available. |
|
80 |
if (!settings.bootstrap || !settings.bootstrap.popoverEnabled || !$.fn.popover) { |
|
80 | 81 |
return; |
81 | 82 |
} |
82 | 83 |
|
... | ... | |
145 | 146 |
} |
146 | 147 |
} |
147 | 148 |
}, |
148 |
detach: function (context) { |
|
149 |
detach: function (context, settings) { |
|
150 |
// Immediately return if popovers are not available. |
|
151 |
if (!settings.bootstrap || !settings.bootstrap.popoverEnabled || !$.fn.popover) { |
|
152 |
return; |
|
153 |
} |
|
154 |
|
|
149 | 155 |
// Destroy all popovers. |
150 | 156 |
$(context).find('[data-toggle="popover"]') |
151 | 157 |
.off('click.drupal.bootstrap.popover') |
Formats disponibles : Unified diff
Weekly update of contrib modules