tested.html 1.1 KB

12345678910111213141516171819202122232425262728293031
  1. {{ $tested := replace (.Get "using") ", " "," }}
  2. {{ $tested := replace $tested " + " "+" }}
  3. {{ $tested := split $tested "," }}
  4. <table class="tested">
  5. <tr>
  6. <th scope="row">
  7. <svg viewBox="0 0 177.16535 177.16535" focusable="false" aria-hidden="true">
  8. <use xlink:href="#tick"></use>
  9. </svg>
  10. Tested using
  11. </th>
  12. {{ range $tested }}
  13. <td>
  14. {{ if in . "+" }}
  15. {{ $parts := split . "+" }}
  16. {{ $browser := index $parts 0 }}
  17. {{ $additional := index $parts 1 }}
  18. {{ $slug := replace $browser " " "-" | lower }}
  19. <img src="{{ (printf "images/browser-%s" $slug) | absURL }}.svg" alt="">
  20. <span><strong>{{ $browser }}</strong></span>
  21. <span class="additional">with <strong>{{ $additional }}</strong></span>
  22. {{ else }}
  23. {{ $browser := . }}
  24. {{ $slug := replace $browser " " "-" | lower }}
  25. <img src="{{ (printf "images/browser-%s" $slug) | absURL }}.svg" alt="">
  26. <span><strong>{{ $browser }}</strong></span>
  27. {{ end }}
  28. </td>
  29. {{ end }}
  30. </tr>
  31. </table>