* src/client/conversation-viewer/conversation-message.vala: (ConversationMessage::create_quote_container): Fix unwanted whitespace at the top of quote containers by removing newlines from the inner HTML used to construct them. (ConversationMessage::unset_controllable_quotes): Replace using absolute pxiel value for determining whether a quote should be unhidden with a percentage of the parent container. * ui/conversation-web-view.css: Polish and simplify quote container CSS.
174 lines
3.1 KiB
CSS
174 lines
3.1 KiB
CSS
/**
|
|
* Style that is inserted into the message after it is loaded.
|
|
*/
|
|
|
|
/*
|
|
* General HTML style.
|
|
*/
|
|
|
|
html {
|
|
/* Trigger CSS 2.1 § 10.6.7 to get a shrink-wrapped height. */
|
|
position: absolute !important;
|
|
top: 0 !important;
|
|
left: 0 !important;
|
|
bottom: auto !important;
|
|
width: 100% !important;
|
|
height: auto !important;
|
|
|
|
/* Lock down the box enough so we don't get an incrementally
|
|
expanding web view */
|
|
box-sizing: border-box !important;
|
|
margin: 0 !important;
|
|
border: 0 !important;
|
|
padding: 0;
|
|
|
|
/* Never show scroll bars */
|
|
overflow: hidden;
|
|
}
|
|
|
|
body {
|
|
margin: 0;
|
|
border: 0;
|
|
padding: 12px;
|
|
overflow-wrap: break-word !important;
|
|
}
|
|
|
|
table {
|
|
/* By default, tables reset the font properties to "normal" */
|
|
font-size: inherit;
|
|
}
|
|
|
|
a {
|
|
color: #08c;
|
|
}
|
|
|
|
hr {
|
|
background-color: #999;
|
|
height: 1px;
|
|
border: 0;
|
|
margin-top: 15px;
|
|
margin-bottom: 15px;
|
|
}
|
|
|
|
blockquote {
|
|
margin: 1em 16px;
|
|
border: 0;
|
|
border-left: 3px #aaa solid;
|
|
padding: 0 8px;
|
|
}
|
|
|
|
|
|
pre {
|
|
white-space: pre-wrap;
|
|
}
|
|
|
|
/**
|
|
* Message chrome style.
|
|
*/
|
|
|
|
.signature {
|
|
color: #777;
|
|
display: inline;
|
|
}
|
|
|
|
.signature a,
|
|
.quote_container a {
|
|
color: #5fb2e7;
|
|
}
|
|
|
|
@media screen {
|
|
|
|
.replaced_inline_image {
|
|
display: block;
|
|
max-width: 100%;
|
|
margin-top: 1em;
|
|
}
|
|
|
|
/* Inline collapsable quote blocks */
|
|
|
|
.quote_container {
|
|
position: relative;
|
|
margin: 0.5em 0;
|
|
border-radius: 4px;
|
|
padding: 0;
|
|
color: #303030;
|
|
background-color: #e8e8e8;/* recv-quoted */
|
|
}
|
|
.sent .quote_container {
|
|
background-color: #e8e8e8;/* sent-quoted */
|
|
}
|
|
|
|
.quote_container > .quote {
|
|
position: relative;
|
|
margin: 0;
|
|
border: 0;
|
|
padding: 0;
|
|
overflow: hidden;
|
|
z-index: 0;
|
|
}
|
|
.quote_container.controllable.hide > .quote {
|
|
/* Use a fraction value to cut the last visible line off half way. */
|
|
max-height: 7.75em;
|
|
}
|
|
|
|
.quote_container.controllable > .quote > blockquote {
|
|
/* Add space between the quote and the hider button */
|
|
margin-bottom: 18px;
|
|
}
|
|
|
|
.quote_container > .shower,
|
|
.quote_container > .hider {
|
|
position: absolute;
|
|
display: none;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: -8px;
|
|
z-index: 1;
|
|
-webkit-user-select: none;
|
|
-webkit-user-drag: none;
|
|
}
|
|
|
|
.quote_container > .shower > input,
|
|
.quote_container > .hider > input {
|
|
width: 100%;
|
|
height: 16px;
|
|
padding: 0;
|
|
font-size: 8px; /* Absolute size in pixels for graphics */
|
|
color: #888;
|
|
}
|
|
.quote_container > .shower:hover > input,
|
|
.quote_container > .hider:hover > input {
|
|
color: #000;
|
|
}
|
|
|
|
.quote_container.controllable.hide > .hider {
|
|
display: none;
|
|
}
|
|
.quote_container.controllable.hide > .shower,
|
|
.quote_container.controllable > .hider {
|
|
display: block;
|
|
}
|
|
|
|
/* Highlight search terms */
|
|
|
|
.search_coloring *::selection {
|
|
background-color: #00ddff;
|
|
}
|
|
}
|
|
|
|
@media print {
|
|
body {
|
|
background-color: white !important;
|
|
}
|
|
|
|
#part_container {
|
|
display: none !important;
|
|
}
|
|
#print_container {
|
|
display: inline-block !important;
|
|
background-color: white !important;
|
|
}
|
|
#print_container .preview {
|
|
display: none !important;
|
|
}
|
|
}
|