[Notice] Announcing the End of Demo Server [Read me]
notification:fixed default line height and add ellipsis string
@82bc35ba7bad7aa8f4d98354adfac3aab22007f6
--- app/assets/stylesheets/less/_page.less
+++ app/assets/stylesheets/less/_page.less
... | ... | @@ -1090,11 +1090,8 @@ |
1090 | 1090 |
color:#666; |
1091 | 1091 |
font-weight:bold; |
1092 | 1092 |
&:hover {color:@link-hover-color;} |
1093 |
- |
|
1094 | 1093 |
} |
1095 |
- |
|
1096 | 1094 |
} |
1097 |
- |
|
1098 | 1095 |
|
1099 | 1096 |
.message-wrap { |
1100 | 1097 |
margin-top:3px; |
... | ... | @@ -1102,19 +1099,24 @@ |
1102 | 1099 |
color:#888; |
1103 | 1100 |
padding-left:12px; |
1104 | 1101 |
overflow:hidden; |
1105 |
- max-height:40px; |
|
1102 |
+ line-height:20px; |
|
1106 | 1103 |
.transition(all 0.3s ease); |
1104 |
+ min-height:20px; |
|
1107 | 1105 |
|
1108 | 1106 |
.message { |
1109 | 1107 |
word-break : break-all; |
1108 |
+ line-height:20px; |
|
1110 | 1109 |
} |
1111 |
- } |
|
1112 | 1110 |
|
1113 |
- .learn-more { |
|
1114 |
- margin-top:5px; |
|
1115 |
- font-size:13px; |
|
1116 |
- color:#bbb; |
|
1117 |
- padding-left:50px; |
|
1111 |
+ &.nowrap { |
|
1112 |
+ min-height:20px; |
|
1113 |
+ height:20px; |
|
1114 |
+ .message { |
|
1115 |
+ text-overflow: ellipsis; |
|
1116 |
+ white-space: nowrap; |
|
1117 |
+ overflow: hidden; |
|
1118 |
+ } |
|
1119 |
+ } |
|
1118 | 1120 |
} |
1119 | 1121 |
} |
1120 | 1122 |
} |
--- app/views/index/index.scala.html
+++ app/views/index/index.scala.html
... | ... | @@ -81,9 +81,8 @@ |
81 | 81 |
welMessage.toggleClass('nowrap'); |
82 | 82 |
|
83 | 83 |
nHeight = (welMessage.hasClass('nowrap')) ? '' : $(welMessage).find('.message').height(); |
84 |
- |
|
85 |
- $(welMessage).css('max-height',nHeight); |
|
86 |
- |
|
84 |
+ |
|
85 |
+ $(welMessage).css('min-height',nHeight); |
|
87 | 86 |
}); |
88 | 87 |
|
89 | 88 |
}); |
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?