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/less
diff options
context:
space:
mode:
authorMark Otto <otto@github.com>2012-11-28 13:38:21 +0400
committerMark Otto <otto@github.com>2012-11-28 13:38:21 +0400
commitbfc97fdaf6cefceb4091e745977b5bac2ffda1c7 (patch)
tree3cde5df10dc96733ac2fe7a327d267ec3d4fbfb6 /less
parentfda5bb135e0a91f335f1e3bd4e5313070f6e0708 (diff)
Fixes #4852: IE8 popover carets fixed
* IE8 refused a negative z-index to place the previous :after behind the .arrow, so I had to flip the styles. * .arrow is the gray border/background, .arrow:after is now the white inner arrow * Added a hex IE8 fallback to ensure the arrow shows for <IE9 as rgba() isn't supported * Simplified some of the CSS for the popover carets
Diffstat (limited to 'less')
-rw-r--r--less/popovers.less82
1 files changed, 76 insertions, 6 deletions
diff --git a/less/popovers.less b/less/popovers.less
index 4a36db4e8d..9619e2d8d9 100644
--- a/less/popovers.less
+++ b/less/popovers.less
@@ -49,31 +49,101 @@
}
// Arrows
+//
+// .arrow is outer, .arrow:after is inner
+
.popover .arrow,
.popover .arrow:after {
position: absolute;
- display: inline-block;
+ display: block;
width: 0;
height: 0;
border-color: transparent;
border-style: solid;
}
+.popover .arrow {
+ border-width: @popoverArrowOuterWidth;
+}
.popover .arrow:after {
+ border-width: @popoverArrowWidth;
content: "";
- z-index: -1;
}
.popover {
&.top .arrow {
+ left: 50%;
+ margin-left: -@popoverArrowOuterWidth;
+ border-bottom-width: 0;
+ border-top-color: #999; // IE8 fallback
+ border-top-color: @popoverArrowOuterColor;
+ bottom: -@popoverArrowOuterWidth;
+ &:after {
+ bottom: 1px;
+ margin-left: -@popoverArrowWidth;
+ border-bottom-width: 0;
+ border-top-color: @popoverArrowColor;
+ }
+ }
+ &.right .arrow {
+ top: 50%;
+ left: -@popoverArrowOuterWidth;
+ margin-top: -@popoverArrowOuterWidth;
+ border-left-width: 0;
+ border-right-color: #999; // IE8 fallback
+ border-right-color: @popoverArrowOuterColor;
+ &:after {
+ left: 1px;
+ bottom: -@popoverArrowWidth;
+ border-left-width: 0;
+ border-right-color: @popoverArrowColor;
+ }
+ }
+ &.bottom .arrow {
+ left: 50%;
+ margin-left: -@popoverArrowOuterWidth;
+ border-top-width: 0;
+ border-bottom-color: #999; // IE8 fallback
+ border-bottom-color: @popoverArrowOuterColor;
+ top: -@popoverArrowOuterWidth;
+ &:after {
+ top: 1px;
+ margin-left: -@popoverArrowWidth;
+ border-top-width: 0;
+ border-bottom-color: @popoverArrowColor;
+ }
+ }
+
+ &.left .arrow {
+ top: 50%;
+ right: -@popoverArrowOuterWidth;
+ margin-top: -@popoverArrowOuterWidth;
+ border-right-width: 0;
+ border-left-color: #999; // IE8 fallback
+ border-left-color: @popoverArrowOuterColor;
+ &:after {
+ right: 1px;
+ border-right-width: 0;
+ border-left-color: @popoverArrowColor;
+ bottom: -@popoverArrowWidth;
+ }
+ }
+
+
+
+/*
+ &.top .arrow {
bottom: -@popoverArrowWidth;
left: 50%;
margin-left: -@popoverArrowWidth;
border-width: @popoverArrowWidth @popoverArrowWidth 0;
- border-top-color: @popoverArrowColor;
+ //border-top-color: @popoverArrowColor;
+ border-top-color: blue;
&:after {
border-width: @popoverArrowOuterWidth @popoverArrowOuterWidth 0;
- border-top-color: @popoverArrowOuterColor;
- bottom: -1px;
+ //border-top-color: @popoverArrowOuterColor;
+ border-top-color: red;
+ top: -@popoverArrowWidth;
+ //bottom: -1px;
left: -@popoverArrowOuterWidth;
}
}
@@ -115,5 +185,5 @@
bottom: -@popoverArrowOuterWidth;
right: -1px;
}
- }
+ }*/
}