Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorTroy Morehouse <troymore@nbnet.nb.ca>2017-12-12 12:36:54 +0300
committerXhmikosR <xhmikosr@gmail.com>2017-12-12 12:36:54 +0300
commit6f1e746d70649e17956b0db03f5cd127e5012fab (patch)
tree5fd34d9f143be2e9f153de2665448144f5246ed9 /js
parent8839c03865f02cf9c98443f4e07ac477985151ed (diff)
tooltip+popover: add boundary config option (#24979)
Diffstat (limited to 'js')
-rw-r--r--js/src/tooltip.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/js/src/tooltip.js b/js/src/tooltip.js
index 573997e7da..e348fdf208 100644
--- a/js/src/tooltip.js
+++ b/js/src/tooltip.js
@@ -38,7 +38,8 @@ const Tooltip = (($) => {
placement : '(string|function)',
offset : '(number|string)',
container : '(string|element|boolean)',
- fallbackPlacement : '(string|array)'
+ fallbackPlacement : '(string|array)',
+ boundary : '(string|element)'
}
const AttachmentMap = {
@@ -62,7 +63,8 @@ const Tooltip = (($) => {
placement : 'top',
offset : 0,
container : false,
- fallbackPlacement : 'flip'
+ fallbackPlacement : 'flip',
+ boundary : 'scrollParent'
}
const HoverState = {
@@ -301,6 +303,9 @@ const Tooltip = (($) => {
},
arrow: {
element: Selector.ARROW
+ },
+ preventOverflow: {
+ boundariesElement: this.config.boundary
}
},
onCreate: (data) => {