Surface game website links alongside YouTube in cards/results
This commit is contained in:
@@ -168,6 +168,7 @@ function renderResults() {
|
|||||||
<td>${r.average.toFixed(1)}</td>
|
<td>${r.average.toFixed(1)}</td>
|
||||||
<td>${r.total}</td>
|
<td>${r.total}</td>
|
||||||
<td>
|
<td>
|
||||||
|
${r.gameUrl ? `<a class="link compact" href="${r.gameUrl}" target="_blank" rel="noopener">Site ↗</a><br>` : ''}
|
||||||
${r.youtubeUrl ? `<a class="link compact" href="${r.youtubeUrl}" target="_blank" rel="noopener">YouTube ↗</a>` : ''}
|
${r.youtubeUrl ? `<a class="link compact" href="${r.youtubeUrl}" target="_blank" rel="noopener">YouTube ↗</a>` : ''}
|
||||||
</td>
|
</td>
|
||||||
`;
|
`;
|
||||||
@@ -279,6 +280,7 @@ function buildCard(s, { showAuthor = false, allowDelete = false }) {
|
|||||||
<div class="card-title-row">
|
<div class="card-title-row">
|
||||||
<h3>${s.name}</h3>
|
<h3>${s.name}</h3>
|
||||||
<div class="title-meta">
|
<div class="title-meta">
|
||||||
|
${s.gameUrl ? `<a class="link compact" href="${s.gameUrl}" target="_blank" rel="noopener">Site ↗</a>` : ""}
|
||||||
${s.youtubeUrl ? `<a class="link compact" href="${s.youtubeUrl}" target="_blank" rel="noopener">YouTube ↗</a>` : ""}
|
${s.youtubeUrl ? `<a class="link compact" href="${s.youtubeUrl}" target="_blank" rel="noopener">YouTube ↗</a>` : ""}
|
||||||
${showAuthor && s.author ? `<span class="chip">${s.author}</span>` : ""}
|
${showAuthor && s.author ? `<span class="chip">${s.author}</span>` : ""}
|
||||||
${allowDelete ? `<button class="chip danger-chip" data-delete="${s.id}" type="button">Delete</button>` : ""}
|
${allowDelete ? `<button class="chip danger-chip" data-delete="${s.id}" type="button">Delete</button>` : ""}
|
||||||
|
|||||||
Reference in New Issue
Block a user