Skip to content

Commit

Permalink
Homepage|Fixed: Comparative alignment mismatch with news vs forum items
Browse files Browse the repository at this point in the history
When compositing news on the homepage insert a real line break after
the header rather than expanding the margin. Doing it this way has
several benefits:
- Ensure appropriate formatting in the absence of styling
- Line spacing is automatically correct
- Ensure empty content blocks are formatted consistently with those
containing content
  • Loading branch information
danij-deng committed Apr 21, 2014
1 parent 2145362 commit d506754
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
6 changes: 3 additions & 3 deletions web/plugins/z#home/home.php
Expand Up @@ -291,7 +291,7 @@ public function execute($args=NULL)
var niceDate = $.datepicker.formatDate('MM d, yy', d);
html += '<p><time datetime="' + d.toISOString() + '" pubdate>' + niceDate + '</time></p>';
html += '</header>';
html += '</header><br />';
html += t.atomSummary;
html += '</article>';
html += '<div class="links"><a href="' + n.feedUri + '" class="link-rss" title="Doomsday Engine build events are reported via RSS">All builds</a></div></div>';
Expand All @@ -312,7 +312,7 @@ public function execute($args=NULL)
var niceDate = $.datepicker.formatDate('MM d, yy', d);
html += '<p><time datetime="' + d.toISOString() + '" pubdate>' + niceDate + '</time></p>';

html += '</header>';
html += '</header><br />';
html += t.content;
html += '</article>';
html += '<div class="links"><a href="' + n.feedUri + '" class="link-rss" title="Doomsday Engine news via RSS">All news</a></div></div>';
Expand All @@ -333,7 +333,7 @@ public function execute($args=NULL)
var niceDate = $.datepicker.formatDate('MM d, yy', d);
html += '<p><time datetime="' + d.toISOString() + '" pubdate>' + niceDate + '</time></p>';

html += '</header>';
html += '</header><br />';
html += t.content;
html += '</article>';
html += '<div class="links"><a href="' + n.feedUri + '" class="link-rss" title="Doomsday Engine development blog via RSS">All blogs</a></div></div>';
Expand Down
6 changes: 1 addition & 5 deletions web/style.css
Expand Up @@ -228,10 +228,6 @@ hr.dashed {
margin-top: 0;
}

.block article header {
margin-bottom: .8em;
}

/* metadata */
.block article header p {
font-style: italic;
Expand Down Expand Up @@ -344,7 +340,7 @@ table.table1 tbody td {
.topiclist li.header {
border-width: 0;
color: white;
font-size: 1.2em;
font-size: 1em;
font-weight: 300;
text-shadow: 0px 1px 1px #666;
white-space: nowrap;
Expand Down

0 comments on commit d506754

Please sign in to comment.