Version 5.1 - All the GraphQL #32

Closed
timw4mail wants to merge 1160 commits from develop into master
3 changed files with 13 additions and 2 deletions
Showing only changes of commit ede69b6099 - Show all commits

File diff suppressed because one or more lines are too long

View File

@ -365,6 +365,15 @@
});
}
// Wire up mal checkbox
AnimeClient.on('main', 'change', '.big-check', (e) => {
const id = e.target.id;
AnimeClient.$('.mal-check').forEach(el => {
el.checked = false;
});
document.getElementById(`mal_${id}`).checked = true;
});
function renderAnimeSearchResults (data) {
const results = [];
@ -377,6 +386,7 @@
results.push(`
<article class="media search">
<div class="name">
<input type="checkbox" class="mal-check" id="mal_${item.slug}" name="mal_id" value="${x.mal_id}" />
<input type="radio" class="big-check" id="${item.slug}" name="id" value="${x.id}" />
<label for="${item.slug}">
<img src="/public/images/anime/${x.id}.jpg" alt="" width="220" />
@ -412,6 +422,7 @@
results.push(`
<article class="media search">
<div class="name">
<input type="checkbox" id="mal_${item.slug}" name="mal_id" value="${x.mal_id}" />
<input type="radio" class="big-check" id="${item.slug}" name="id" value="${x.id}" />
<label for="${item.slug}">
<img src="/public/images/manga/${x.id}.jpg" alt="" width="220" />

File diff suppressed because one or more lines are too long