mirror of
https://github.com/commercialhaskell/stackage-server.git
synced 2026-01-12 04:08:29 +01:00
Move liked classes into template
Per discussion with @DanBurton
This commit is contained in:
parent
444b09c6fe
commit
d5989c8fbf
@ -44,8 +44,7 @@ getPackageR pn = do
|
||||
|
||||
return (packages, downloads, recentDownloads, nLikes, liked, metadata)
|
||||
|
||||
let likedClass = if liked then "fa-thumbs-up" else "fa-thumbs-o-up" :: Text
|
||||
likeTitle = if liked
|
||||
let likeTitle = if liked
|
||||
then "You liked this!"
|
||||
else "I like this!" :: Text
|
||||
|
||||
|
||||
@ -34,7 +34,7 @@ $newline never
|
||||
<span #likes>
|
||||
#{nLikes}
|
||||
\ likes #
|
||||
<i .fa .#{likedClass} #like title="#{likeTitle}">
|
||||
<i .fa :liked:.fa-thumbs-up :not liked:.fa-thumbs-o-up #like title="#{likeTitle}">
|
||||
$if downloads /= 0
|
||||
<span .downloads>
|
||||
$if downloads /= recentDownloads
|
||||
|
||||
Loading…
Reference in New Issue
Block a user