aboutsummaryrefslogtreecommitdiff
path: root/less
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2013-12-19 19:40:08 -0800
committerMark Otto <[email protected]>2013-12-19 19:40:08 -0800
commit2854c5c3fb65b709fbf32d05faccf7a294626cca (patch)
tree4cb9ef9d2b7f54cf0721a32a6a87ca8ee5414b2d /less
parent81b1e6801faf71705a06e8e039a98b79b6c478c5 (diff)
downloadbootstrap-2854c5c3fb65b709fbf32d05faccf7a294626cca.tar.xz
bootstrap-2854c5c3fb65b709fbf32d05faccf7a294626cca.zip
Fixes #11952: Refactor blockquote styles
* Deprecate .pull-right class for .blockquote-reverse * Move font-size change to the parent, blockquote, instead of setting on the p element to allow more flexible content
Diffstat (limited to 'less')
-rw-r--r--less/type.less55
1 files changed, 30 insertions, 25 deletions
diff --git a/less/type.less b/less/type.less
index 1d01b9a71..585584470 100644
--- a/less/type.less
+++ b/less/type.less
@@ -263,12 +263,15 @@ abbr[data-original-title] {
blockquote {
padding: (@line-height-computed / 2) @line-height-computed;
margin: 0 0 @line-height-computed;
+ font-size: (@font-size-base * 1.25);
border-left: 5px solid @blockquote-border-color;
- p {
- font-size: (@font-size-base * 1.25);
- }
- p:last-child {
- margin-bottom: 0;
+
+ p,
+ ul,
+ ol {
+ &:last-child {
+ margin-bottom: 0;
+ }
}
// Deprecating small and .small for v3.1
@@ -277,32 +280,34 @@ blockquote {
small,
.small {
display: block;
+ font-size: 80%; // back to default font-size
line-height: @line-height-base;
color: @blockquote-small-color;
+
&:before {
- content: '\2014 \00A0'; // EM DASH, NBSP
+ content: '\2014 \00A0'; // em dash, nbsp
}
}
+}
- // Float right with text-align: right
- &.pull-right {
- padding-right: 15px;
- padding-left: 0;
- border-right: 5px solid @blockquote-border-color;
- border-left: 0;
- p,
- small,
- .small {
- text-align: right;
- }
- small,
- .small {
- &:before {
- content: '';
- }
- &:after {
- content: '\00A0 \2014'; // NBSP, EM DASH
- }
+// Opposite alignment of blockquote
+//
+// Heads up: `blockquote.pull-right` has been deprecated as of v3.1.
+.blockquote-reverse,
+blockquote.pull-right {
+ padding-right: 15px;
+ padding-left: 0;
+ border-right: 5px solid @blockquote-border-color;
+ border-left: 0;
+ text-align: right;
+
+ // Account for citation
+ footer,
+ small,
+ .small {
+ &:before { content: ''; }
+ &:after {
+ content: '\00A0 \2014'; // nbsp, em dash
}
}
}