mirror of
https://github.com/morris/vanilla-todo.git
synced 2025-08-08 23:26:58 +02:00
fix pick date event misfiring
This commit is contained in:
@@ -2,7 +2,7 @@ import { AppIcon } from './AppIcon.js';
|
|||||||
import { formatMonth } from './util.js';
|
import { formatMonth } from './util.js';
|
||||||
|
|
||||||
const datesCell = /* html */ `
|
const datesCell = /* html */ `
|
||||||
<td><button class="app-button"></button></td>
|
<td><button class="app-button pick"></button></td>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
const datesRow = /* html */ `
|
const datesRow = /* html */ `
|
||||||
@@ -71,7 +71,7 @@ export function AppDatePicker(el) {
|
|||||||
el.querySelector('.nextmonth').addEventListener('click', nextMonth);
|
el.querySelector('.nextmonth').addEventListener('click', nextMonth);
|
||||||
|
|
||||||
el.addEventListener('click', (e) => {
|
el.addEventListener('click', (e) => {
|
||||||
if (!e.target.matches('.app-button')) return;
|
if (!e.target.matches('.pick')) return;
|
||||||
|
|
||||||
show = false;
|
show = false;
|
||||||
update();
|
update();
|
||||||
|
Reference in New Issue
Block a user