From 587a001dcce9f8dcf223a1f0c7dbefc58efbd6ad Mon Sep 17 00:00:00 2001 From: ggam Date: Mon, 12 Aug 2013 17:05:15 +0200 Subject: [PATCH] Added Dropdown JS plugin events (fixed #9375) --- javascript.html | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/javascript.html b/javascript.html index c3a6b0a323..c21842b077 100644 --- a/javascript.html +++ b/javascript.html @@ -478,10 +478,43 @@ $('.dropdown-toggle').dropdown()

Methods

$().dropdown('toggle')

Toggles the dropdown menu of a given navbar or tabbed navigation.

+ +

Events

+
+ + + + + + + + + + + + + + + + + + + + + + + + + +
Event TypeDescription
show.bs.dropdownThis event fires immediately when the show instance method is called.
shown.bs.dropdownThis event is fired when the dropdown has been made visible to the user (will wait for CSS transitions, to complete).
hide.bs.dropdownThis event is fired immediately when the hide instance method has been called.
hidden.bs.dropdownThis event is fired when the dropdown has finished being hidden from the user (will wait for CSS transitions, to complete).
+
+{% highlight js %} +$('#myDropdown').on('show.bs.dropdown', function () { + // do something… +}) +{% endhighlight %} - -