citra-emu
/
citra-web
Archived
1
0
Fork 0
This repository has been archived on 2024-03-23. You can view files and clone it, but cannot push or open issues or pull requests.
citra-web/site/themes/citra-bs-theme/layouts/game/list.html

65 lines
2.3 KiB
HTML

{{ define "main" }}
<h1>Game Compatibility List</h1>
<p>The Citra Emulator compatibility list contains all the games we tested, sorted by how well they work on the emulator.</p>
<table class="table table-striped table-bordered">
<tbody>
{{ range .Site.Data.compatibility }}
<tr>
<td style="width: 120px;"><div class="square-icon" style="background-color: {{ .color }}"></div> {{ .name }}</td>
<td class="row-compat-desc">{{ .description }}</td>
</tr>
{{ end }}
</tbody>
</table>
<div id="highchart-container" style="height: 100px; margin: 0 auto"></div>
<table class="table table-responsive">
<thead>
<tr>
<th></th>
<th>Title</th>
<th>Compatibility</th>
<th>Date Tested</th>
</tr>
</thead>
<tbody>
{{ range .Data.Pages }}
{{- $rating := index .Site.Data.compatibility .Params.compatibility }}
<tr>
<td style="width: 55px;"><img class="img-responsive game-icon-list" src="{{ .Site.BaseURL }}images/game/icons/{{ default (print .File.BaseFileName ".png") }}" /></td>
<td><a href="{{ .Permalink }}">{{ .Params.title }}</a></td>
<td class="compatibility-row"><div class="square-icon" style="background-color: {{ $rating.color }}"></div> {{ $rating.name }}</td>
<td>{{ dateFormat "January 2, 2006" .Params.testcase_date }}</td>
</tr>
{{ end }}
</tbody>
</table>
{{ end }}
{{ define "scripts" }}
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<script type="text/javascript">
Highcharts.chart('highchart-container', {
chart: { type: 'bar' },
colors: [{{ range .Site.Data.compatibility }}"{{ .color }}", {{- end }}],
credits: { enabled: false },
exporting: { enabled: false },
title: { text: '' },
xAxis: { categories: [''] },
yAxis: { min: 0, max: {{ len .Data.Pages }}, title: { text: '' } },
legend: { enabled: false },
plotOptions: { series: { stacking: 'normal' } },
series: [
{{- $dataPages := .Data.Pages }}
{{- range .Site.Data.compatibility }}
{{- $dataPagesFiltered := where $dataPages ".Params.compatibility" .key }}
{ "name": "{{ .name }}", "data": [ {{ len $dataPagesFiltered }} ] },
{{- end }}
]
});
</script>
{{ end }}