home-landing.html 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. {{ with .Params.landing }}
  2. {{ $landing := . }}
  3. <div class="divider">
  4. <div class="lmr">
  5. {{ with .backgroundImage }}
  6. <div style="background-image: url('{{ .src | relURL }}'); background-position: center; background-repeat: no-repeat; background-size: cover; position: absolute; top: -50px; left: 0; width: 100%; height: {{ .height }}px;"></div>
  7. {{ end }}
  8. <div class="home__landing" style="height: {{ .height }}px;">
  9. {{ if .image }}
  10. <div class="home__landing--img">
  11. <img src="{{ .image | relURL }}" alt="Site Landing Page image">
  12. </div>
  13. <div class="home__landing--txt">
  14. {{ if .title }}
  15. {{ range .title }}
  16. <div class="title" style="{{ with $landing.titleColor }}color:{{ . }}{{ end }};">
  17. {{ . }}
  18. </div>
  19. {{ end }}
  20. {{ end }}
  21. {{ if .spaceBetweenTitleText }}
  22. <div style="height: {{ .spaceBetweenTitleText }}px"></div>
  23. {{ end }}
  24. {{ if .text }}
  25. {{ range .text }}
  26. <div class="text" style="{{ with $landing.textColor }}color:{{ . }}{{ end }};">
  27. {{ . }}
  28. </div>
  29. {{ end }}
  30. {{ end }}
  31. {{ range .buttons }}
  32. <a href="{{ .link }}" target="{{ if in .link "http" }}_blank{{ else }}_self{{ end }}" rel="noreferrer" class="home__landing--link">
  33. <button class="button home__landing--btn" aria-label="{{ .text }}" data-color="{{ with .color }}{{ . }}{{ end }}">
  34. {{ .text }}
  35. </button>
  36. </a>
  37. {{ end }}
  38. </div>
  39. {{ else }}
  40. <div class="home__landing--txt">
  41. {{ if .title }}
  42. {{ range .title }}
  43. <div class="title" style="{{ with $landing.titleColor }}color:{{ . }}{{ end }};">
  44. {{ . }}
  45. </div>
  46. {{ end }}
  47. {{ end }}
  48. {{ if .spaceBetweenTitleText }}
  49. <div style="height: {{ .spaceBetweenTitleText }}px"></div>
  50. {{ end }}
  51. {{ if .text }}
  52. {{ range .text }}
  53. <div class="text" style="{{ with $landing.textColor }}color:{{ . }}{{ end }};">
  54. {{ . }}
  55. </div>
  56. {{ end }}
  57. {{ end }}
  58. </div>
  59. <div class="flexcolumn">
  60. {{ range .buttons }}
  61. <a href="{{ .link }}" target="{{ if in .link "http" }}_blank{{ else }}_self{{ end }}" rel="noreferrer" class="home__landing--link">
  62. <button class="button home__landing--btn2" aria-label="{{ .text }}" data-color="{{ with .color }}{{ . }}{{ end }}">
  63. {{ .text }}
  64. </button>
  65. </a>
  66. {{ end }}
  67. </div>
  68. {{ end }}
  69. </div>
  70. </div>
  71. </div>
  72. {{ end }}