aboutsummaryrefslogtreecommitdiff
path: root/javascript.html
diff options
context:
space:
mode:
authorJulian Thilo <[email protected]>2013-07-10 22:57:19 +0200
committerJulian Thilo <[email protected]>2013-07-24 09:08:19 +0200
commit7936f1478028fb759781014a2c93884f5f90a598 (patch)
tree9e465d4fa9ee66b3fa7d9187519158277d86e591 /javascript.html
parent930c75e5dd0f2ae861a505bda740f289570c9b8a (diff)
downloadbootstrap-7936f1478028fb759781014a2c93884f5f90a598.tar.xz
bootstrap-7936f1478028fb759781014a2c93884f5f90a598.zip
Fix #8428 - Document tooltip/popover events
Diffstat (limited to 'javascript.html')
-rw-r--r--javascript.html66
1 files changed, 66 insertions, 0 deletions
diff --git a/javascript.html b/javascript.html
index 72b37d4fb..5d94d3f2d 100644
--- a/javascript.html
+++ b/javascript.html
@@ -867,6 +867,39 @@ $('#example').tooltip(options)
<h4>.tooltip('destroy')</h4>
<p>Hides and destroys an element's tooltip.</p>
{% highlight js %}$('#element').tooltip('destroy'){% endhighlight %}
+
+ <h3>Events</h3>
+ <table class="table table-bordered table-striped">
+ <thead>
+ <tr>
+ <th style="width: 150px;">Event Type</th>
+ <th>Description</th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>show</td>
+ <td>This event fires immediately when the <code>show</code> instance method is called.</td>
+ </tr>
+ <tr>
+ <td>shown</td>
+ <td>This event is fired when the tooltip has been made visible to the user (will wait for CSS transitions to complete).</td>
+ </tr>
+ <tr>
+ <td>hide</td>
+ <td>This event is fired immediately when the <code>hide</code> instance method has been called.</td>
+ </tr>
+ <tr>
+ <td>hidden</td>
+ <td>This event is fired when the tooltip has finished being hidden from the user (will wait for CSS transitions to complete).</td>
+ </tr>
+ </tbody>
+ </table>
+{% highlight js %}
+$('#myTooltip').on('hidden.bs.tooltip', function () {
+ // do something…
+})
+{% endhighlight %}
</section>
@@ -1052,6 +1085,39 @@ $('#example').tooltip(options)
<h4>.popover('destroy')</h4>
<p>Hides and destroys an element's popover.</p>
{% highlight js %}$('#element').popover('destroy'){% endhighlight %}
+
+ <h3>Events</h3>
+ <table class="table table-bordered table-striped">
+ <thead>
+ <tr>
+ <th style="width: 150px;">Event Type</th>
+ <th>Description</th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>show</td>
+ <td>This event fires immediately when the <code>show</code> instance method is called.</td>
+ </tr>
+ <tr>
+ <td>shown</td>
+ <td>This event is fired when the popover has been made visible to the user (will wait for CSS transitions to complete).</td>
+ </tr>
+ <tr>
+ <td>hide</td>
+ <td>This event is fired immediately when the <code>hide</code> instance method has been called.</td>
+ </tr>
+ <tr>
+ <td>hidden</td>
+ <td>This event is fired when the popover has finished being hidden from the user (will wait for CSS transitions to complete).</td>
+ </tr>
+ </tbody>
+ </table>
+{% highlight js %}
+$('#myPopover').on('hidden.bs.popover', function () {
+ // do something…
+})
+{% endhighlight %}
</section>