$newline never
<div .container #snapshot-home .content :isDeprecated:.deprecated>
    <div .row>
        <div .span12>
            $if isDeprecated
              <h1 .package-deprecation-warning>
                Deprecated
              $if (not $ null inFavourOf)
                <div .in-favour-of>
                  In favour of
                  <div .in-favour-of-list>
                    $forall (i, pn) <- enumerate inFavourOf
                      $if i /= 0
                        , #
                      <a href="@{PackageR pn}">
                        #{pn}
            <h1>
               #{pname}
            <p .synopsis>
                #{piSynopsis}
            $maybe url <- piHomepage
                <p><a href="#{url}">#{url}</a>

            <table>
              $maybe displayedVersion <- mdisplayedVersion
                <tr>
                  <td align=right>Version on this page:
                  <td>
                    <span .version>#{displayedVersion}
              $maybe sppi <- msppi
                $forall li <- sppiLatestInfo sppi
                   <tr>
                     <td align="right">
                       <a href=@{SnapshotR (liSnapName li) StackageHomeR}>
                          #{snapshotPrettyNameShort (liSnapName li)}
                       :
                     <td>
                       <span .version>
                         <a href=@{SnapshotR (liSnapName li) (StackageSdistR (PNVName pname))}>#{liVersionRev li}
              $maybe hciLatest <- mhciLatest
                  <tr>
                    <td align="right">Latest on Hackage:
                    <td>
                      <a href="https://hackage.haskell.org/package/#{hciPackageName hciLatest}">
                        <span .version>#{hciVersionRev hciLatest}

            $if isNothing msppi
                <p .add-to-nightly>
                    This package is not currently in any snapshots. If you're interested in using it, we recommend #
                    <a href="https://github.com/commercialhaskell/stackage/#add-your-package">adding it to Stackage Nightly
                    . Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.
            $else
                <p>
                  <a href=@{PackageSnapshotsR pname}>See all snapshots <code>#{pname}</code> appears in

    <div .row>
        <div .span12>
            <div .authorship>
                <span .license>
                    #{piLicenseName} licensed #
                    $if null maintainers
                        and maintained #
                $if not (null authors)
                   by #
                   $forall (i,identity) <- authors
                      <strong .author>
                          $case identity
                              $of PlainText name
                                  $if i /= 0
                                      , #
                                  #{name}
                              $of Contact name email
                                  $if i /= 0
                                      , #
                                  <a href="mailto:#{renderEmail email}">
                                      #{name}
                              $of _

            <div .maintainer>
                $if not (null maintainers)
                     Maintained by #
                     $forall (i,identity) <- maintainers
                          <strong .author>
                              $case identity
                                 $of PlainText name
                                     $if i /= 0
                                         , #
                                     #{name}
                                 $of Contact name email
                                     $if i /= 0
                                         , #
                                     <a href="mailto:#{renderEmail email}">
                                         #{name}
                                 $of EmailOnly email
                                     $if i /= 0
                                         , #
                                     <a href="mailto:#{renderEmail email}">
                                         #{renderEmail email}

            $maybe sppi <- msppi
                $with spi <- sppiSnapshotPackageInfo sppi
                    $maybe pantryCabal <- sppiPantryCabal sppi
                        <div .pantry-version>
                            This version can be pinned in stack with:
                            <code>#{pantryCabal}
                    <div .docs>
                        <h4>
                            Module documentation for #{spiVersion spi}
                        $if null (sppiModuleNames sppi)
                            <p>There are no documented modules for this package.
                        $else
                            ^{hoogleForm (spiSnapName spi)}
                            ^{renderModules sppi}

<div .container #snapshot-home .content>
    <div .row>
        <div .span12>
            $maybe sppi <- msppi
                $with spi <- sppiSnapshotPackageInfo sppi
                    $if (sppiForwardDepsCount sppi > 0)
                      <div .dependencies #dependencies>
                        Depends on #{renderNumPackages (sppiForwardDepsCount sppi)}
                        \<em>(<a href=@{makeDepsLink spi SnapshotPackageDepsR}>full list with versions</a>)</em>:
                        <div .dep-list>
                            $forall (i, (name, range)) <- enumerate (sppiForwardDeps sppi)
                                $if i /= 0
                                    , #
                                <a href=@{PackageR name} title=#{range}>
                                    #{name}
                            $if (sppiForwardDepsCount sppi > maxDisplayedDeps)
                              , <em>and many more</em>
                    $if (sppiReverseDepsCount sppi > 0)
                        <div .reverse-dependencies #reverse-dependencies>
                          Used by #{renderNumPackages (sppiReverseDepsCount sppi)} in <b>#{spiSnapName spi}</b>
                          \<em>(<a href=@{makeDepsLink spi SnapshotPackageRevDepsR}>full list with versions</a>)</em>:
                          <div .dep-list>
                              $forall (i, (name, range)) <- enumerate (sppiReverseDeps sppi)
                                  $if i /= 0
                                      , #
                                  <a href=@{PackageR name} title=#{range}>
                                      #{name}
                              $if (sppiReverseDepsCount sppi > maxDisplayedDeps)
                                , <em>and many more</em>

$if not (LT.null (LT.renderHtml piReadme))
    <div .markdown-container .readme-container>
        <div .container .content>
            <div .row>
                <div .span12 .expanding>
                    #{piReadme}
                    <div .bottom-gradient>
                        <i class="fa fa-angle-down">
$elseif not (LT.null (LT.renderHtml piDescription))
    <div .markdown-container .readme-container>
        <div .container .content>
            <div .row>
                <div .span12 .expanding>
                    #{piDescription}
                    <div .bottom-gradient>
                        <i class="fa fa-angle-down">

$if not (LT.null (LT.renderHtml piChangelog))
    <div .container .content id=changes>
       <div .row>
           <div .span12>
               <h2 .changes-title>Changes
    <div .markdown-container .changelog-container .content>
        <div .container>
            <div .row>
                <div .span12 .expanding>
                    #{piChangelog}
                    <div .bottom-gradient>
                        <i class="fa fa-angle-down">
