Restyle "recommended snapshots" list on homepage (closes #19)

This commit is contained in:
Chris Done 2014-11-13 14:52:22 +01:00
parent de2fb0f12f
commit d705d63073
3 changed files with 15 additions and 14 deletions

View File

@ -44,14 +44,16 @@ getHomeR = do
min' <- handlerToWidget $ linkFor $ name "inclusive" min' <- handlerToWidget $ linkFor $ name "inclusive"
when (isJust mex || isJust min') when (isJust mex || isJust min')
[whamlet| [whamlet|
<dt>#{asHtml title} <tr>
<dd> <td>
$maybe ex <- mex #{asHtml title}
<a href=@{StackageHomeR ex}>exclusive <td>
$if isJust mex && isJust min' $maybe ex <- mex
\ | # <a href=@{StackageHomeR ex}>exclusive
$maybe in <- min' $if isJust mex && isJust min'
<a href=@{StackageHomeR in}>inclusive <td>
$maybe in <- min'
<a href=@{StackageHomeR in}>inclusive
|] |]
where where
name suffix = concat ["unstable-", short, "-", suffix] name suffix = concat ["unstable-", short, "-", suffix]

View File

@ -3,7 +3,7 @@
Stackage is an infrastructure to create stable builds Stackage is an infrastructure to create stable builds
of complete package sets. Think “stable Hackage”. of complete package sets. Think “stable Hackage”.
<h2 .recommended-snapshots>Recommended Snapshots <h2 .recommended-snapshots>Recommended Snapshots
<dl .snapshots> <table .snapshots>
^{addSnapshot "GHC 7.8" "ghc78"} ^{addSnapshot "GHC 7.8" "ghc78"}
^{addSnapshot "GHC 7.8 + Haskell Platform" "ghc78hp"} ^{addSnapshot "GHC 7.8 + Haskell Platform" "ghc78hp"}
^{addSnapshot "GHC 7.6" "ghc76"} ^{addSnapshot "GHC 7.6" "ghc76"}

View File

@ -5,6 +5,7 @@ h2 {
.recommended-snapshots { .recommended-snapshots {
margin-top: 30px; margin-top: 30px;
margin-bottom: 20px;
} }
.how-stackage-works { .how-stackage-works {
@ -14,11 +15,9 @@ h2 {
.snapshots { .snapshots {
margin-left: 0; margin-left: 0;
padding-left: 0; padding-left: 0;
li { td {
list-style-type: none; padding: 0 0.25em 0.25em 0.25em;
margin-left: 0; a { font-weight: bold }
padding-left: 0;
font-weight: bold;
} }
} }