0
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-01-18 10:52:19 +01:00
Gleb Mazovetskiy c7d8e7a077 Accept elements as the tooltip / popover content
When a DOM node is passed to an HTML tooltip, the `title` node is only
moved if it is not already in the tooltip. Otherwise, `empty()` is used
instead of `detach()` before appending the `title` to avoid memory
leaks. If a DOM node is passed to a plain text tooltip, its text is
copied via jQuery `.text()`.

Replaces `.detach()` with `.empty()`, as `.detach()` is almost never
useful but instead leaks memory. The difference between `empty` and
`detach` is that the latter keeps all the attached jQuery events/data.
However, since we do not return the previous children, the user would
have to keep these themselves, thus they can `detach()` if necessary.

This is a port of https://github.com/twbs/bootstrap/pull/14552 to v4.
2015-08-31 01:06:13 +01:00
..
2015-08-23 21:34:47 -07:00
2015-08-17 21:16:09 -07:00
2015-08-29 18:50:20 +03:00
2015-08-23 23:03:58 -07:00
2015-08-30 00:01:30 +03:00
2015-08-26 20:22:37 +02:00
2015-08-14 22:45:55 -07:00
2015-08-29 18:50:20 +03:00
2015-08-21 02:15:17 +02:00
2015-08-25 14:16:49 -07:00
2014-08-01 19:45:11 +03:00
2015-08-30 00:05:02 +03:00