aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRohit Sharma <[email protected]>2021-04-21 10:45:22 +0530
committerGitHub <[email protected]>2021-04-21 08:15:22 +0300
commit4d973259f55834ef9c9543fbcc265f11219ba8b2 (patch)
tree1cfde59381c07910e0568d7f1fc1b4ff4f0ee3a1
parent079f2cd90c247225eb71dff4d514faf50f653416 (diff)
downloadbootstrap-4d973259f55834ef9c9543fbcc265f11219ba8b2.tar.xz
bootstrap-4d973259f55834ef9c9543fbcc265f11219ba8b2.zip
docs: fix the default value of Popper's `boundary` option (#33685)
`'scrollParent'` is no longer the default `boundary` value Co-authored-by: XhmikosR <[email protected]>
-rw-r--r--site/content/docs/5.0/components/tooltips.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/site/content/docs/5.0/components/tooltips.md b/site/content/docs/5.0/components/tooltips.md
index b56766dd5..61c6753a4 100644
--- a/site/content/docs/5.0/components/tooltips.md
+++ b/site/content/docs/5.0/components/tooltips.md
@@ -116,12 +116,12 @@ var tooltip = new bootstrap.Tooltip(exampleEl, options)
{{< callout warning >}}
##### Overflow `auto` and `scroll`
-Tooltip position attempts to automatically change when a parent container has `overflow: auto` or `overflow: scroll` like our `.table-responsive`, but still keeps the original placement's positioning. To resolve, set the `boundary` option to anything other than default value, `'scrollParent'`, such as `'window'`:
+Tooltip position attempts to automatically change when a **parent container** has `overflow: auto` or `overflow: scroll` like our `.table-responsive`, but still keeps the original placement's positioning. To resolve this, set the [`boundary` option](https://popper.js.org/docs/v2/modifiers/flip/#boundary) (for the flip modifier using the `popperConfig` option) to any HTMLElement to override the default value, `'clippingParents'`, such as `document.body`:
```js
var exampleEl = document.getElementById('example')
var tooltip = new bootstrap.Tooltip(exampleEl, {
- boundary: 'window'
+ boundary: document.body // or document.querySelector('#boundary')
})
```
{{< /callout >}}