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
diff options
context:
space:
mode:
authorChris Rebert <code@chrisrebert.com>2016-01-18 09:23:29 +0300
committerChris Rebert <code@chrisrebert.com>2016-01-18 09:23:29 +0300
commit032adf13242e701acece5bbfe6bfebc4f77707ee (patch)
treec62e73914eda91a592687f23a0b7d3245bc5accb
parent27596f48f4c84f823a2b4cb6ff3e4fc55ced6344 (diff)
Apply word-wrap:break-word to Tooltips and Popovers
Fixes #16871 for v4
-rw-r--r--scss/_popover.scss2
-rw-r--r--scss/_tooltip.scss2
-rw-r--r--scss/mixins/_reset-text.scss3
3 files changed, 5 insertions, 2 deletions
diff --git a/scss/_popover.scss b/scss/_popover.scss
index 303850cc0c..9ea8c14758 100644
--- a/scss/_popover.scss
+++ b/scss/_popover.scss
@@ -10,6 +10,8 @@
// So reset our font and text properties to avoid inheriting weird values.
@include reset-text();
font-size: $font-size-sm;
+ // Allow breaking very long words so they don't overflow the popover's bounds
+ word-wrap: break-word;
background-color: $popover-bg;
background-clip: padding-box;
border: $popover-border-width solid $popover-border-color;
diff --git a/scss/_tooltip.scss b/scss/_tooltip.scss
index a17aefc0ae..e8151af07d 100644
--- a/scss/_tooltip.scss
+++ b/scss/_tooltip.scss
@@ -7,6 +7,8 @@
// So reset our font and text properties to avoid inheriting weird values.
@include reset-text();
font-size: $font-size-sm;
+ // Allow breaking very long words so they don't overflow the tooltip's bounds
+ word-wrap: break-word;
opacity: 0;
&.in { opacity: $tooltip-opacity; }
diff --git a/scss/mixins/_reset-text.scss b/scss/mixins/_reset-text.scss
index 014dff5665..e1d1725fad 100644
--- a/scss/mixins/_reset-text.scss
+++ b/scss/mixins/_reset-text.scss
@@ -1,6 +1,6 @@
@mixin reset-text {
font-family: $font-family-base;
- // We deliberately do NOT reset font-size.
+ // We deliberately do NOT reset font-size or word-wrap.
font-style: normal;
font-weight: normal;
letter-spacing: normal;
@@ -14,5 +14,4 @@
white-space: normal;
word-break: normal;
word-spacing: normal;
- word-wrap: normal;
}