fix: empêcher toggle sélection card au clic sur checkbox/label en ajoutant INPUT tagName et closest('label') aux exclusions event handler, en plus des actions/links existants
This commit is contained in:
parent
801e406710
commit
10af62dd6c
@ -1331,10 +1331,12 @@ document.addEventListener('DOMContentLoaded', () => {
|
|||||||
|
|
||||||
const card = e.target.closest('.link-outer');
|
const card = e.target.closest('.link-outer');
|
||||||
if (card && card.dataset.id) {
|
if (card && card.dataset.id) {
|
||||||
// Don't toggle if clicking on actions or links
|
// Don't toggle if clicking on actions or links or the checkbox itself
|
||||||
if (e.target.closest('.link-actions') ||
|
if (e.target.closest('.link-actions') ||
|
||||||
e.target.closest('.link-hover-actions') ||
|
e.target.closest('.link-hover-actions') ||
|
||||||
e.target.tagName === 'A') {
|
e.target.tagName === 'A' ||
|
||||||
|
e.target.tagName === 'INPUT' ||
|
||||||
|
e.target.closest('label')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
toggleSelection(card.dataset.id);
|
toggleSelection(card.dataset.id);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user