tested.html 883 B

123456789101112131415161718192021222324
  1. {{ $tested := replace (.Get "using") ", " "," }}
  2. {{ $tested := replace $tested " + " "+" }}
  3. {{ $tested := split $tested "," }}
  4. <table class="tested">
  5. <tr>
  6. <th scope="row">Tested using</th>
  7. {{ range $tested }}
  8. <td>
  9. {{ if in . "+" }}
  10. {{ $parts := split . "+" }}
  11. {{ $browser := index $parts 0 }}
  12. {{ $additional := index $parts 1 }}
  13. <img src="{{ $.Site.BaseURL }}images/browser-{{ replace $browser " " "-" }}.svg" alt="">
  14. <span><strong>{{ $browser }}</strong></span>
  15. <span class="additional">with <strong>{{ $additional }}</strong></span>
  16. {{ else }}
  17. {{ $browser := . }}
  18. <img src="{{ $.Site.BaseURL }}images/browser-{{ replace $browser " " "-" }}.svg" alt="">
  19. <span><strong>{{ $browser }}</strong></span>
  20. {{ end }}
  21. </td>
  22. {{ end }}
  23. </tr>
  24. </table>