visualfeature.html 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. {{ if isset .Site.Params "visualfeature" }}
  2. {{ if .Site.Params.visualfeature.enable }}
  3. {{ if gt (len .Site.Data.visualfeature) 0 }}
  4. <section class="bar background-white">
  5. <div class="container">
  6. <div class="heading text-center headingvf">
  7. <h2>視覺化行銷傳遞策略</h2>
  8. </div>
  9. <div class="text-center headingvf-sub">
  10. <h4>有價值的內容文案加上吸引人的視覺等於行銷成功的關鍵!<br>一張照片或 一段短影音就勝過千言萬字</h4>
  11. </div>
  12. {{ range $index, $element := sort .Site.Data.visualfeature "weight" }}
  13. {{ if eq (mod $index 3) 0 }}
  14. <div class="col-md-12">
  15. <div class="row">
  16. {{ end }}
  17. <div class="col-md-4">
  18. <div class="box-simple">
  19. {{ with $element.url }}
  20. <a href="{{ $element.url }}">
  21. {{ end }}
  22. <div class="icon icon-feature">
  23. <i class="{{ .icon }}"></i>
  24. </div>
  25. {{ with $element.url }}
  26. </a>
  27. {{ end }}
  28. <h3>{{ $element.name | markdownify }}</h3>
  29. <p>{{ $element.description | markdownify }}</p>
  30. </div>
  31. </div>
  32. {{ if or (eq (mod $index 3) 2) (eq $index (sub (len $.Site.Data.features) 1 )) }}
  33. </div>
  34. </div>
  35. {{ end }}
  36. {{ end }}
  37. </div>
  38. </section>
  39. {{ end }}
  40. {{ end }}
  41. {{ end }}