mirror of https://github.com/lxndrblz/anatole.git

Ondřej Morávek
27.48.2022 3685a7dfa6d3f62670f0d2cd57cc80dbfcca00fe
layouts/portfolio/list.html
@@ -9,7 +9,8 @@
      {{ end }}"
    >
      <h2 class="portfolio__title">{{ title .title }}</h2>
      {{ $anchorTitle := delimit (split .title " ") "" }}
      <h2 class="portfolio__title" id="{{ $anchorTitle | lower }}">{{ title .title }}</h2>
      {{ range $i, $p := .portfolioitem }}
        <div class="portfolio">
          {{ if .image }}
@@ -22,9 +23,15 @@
              {{ end }}"
            >
              <a href="{{ .link | safeURL }}" target="_blank" rel="noopener">
              {{ if .link }}
                <a href="{{ .link | safeURL }}" target="_blank" rel="noopener">
                  <img class="portfolio__image" src="{{ .image | relURL }}" alt="{{ .name | markdownify }}" />
                </a>
              {{ else }}
                <img class="portfolio__image" src="{{ .image | relURL }}" alt="{{ .name | markdownify }}" />
              </a>
              {{ end }}
            </div>
          {{ end }}
@@ -82,7 +89,15 @@
            <p>{{ .description | markdownify }}</p>
            {{ if .link }}
              <div class="portfolio__button-wrapper">
                <a class="portfolio__button" href="{{ .link | safeURL }}" target="_blank" rel="noopener">Visit Site</a>
                <a class="portfolio__button" href="{{ .link | safeURL }}" target="_blank" rel="noopener">
                  {{- if .linktext -}}
                    {{ .linktext | markdownify }}
                  {{- else -}}
                    Visit Site
                  {{- end -}}
                </a>
              </div>
            {{ end }}