+
+
+
+
+
+
+ {
+ if (!day) return;
+ const next = new Date(day);
+ const carry = isValidDate(until) ? until : new Date();
+ next.setHours(
+ carry.getHours(),
+ carry.getMinutes(),
+ carry.getSeconds(),
+ 0,
+ );
+ setUntil(next);
+ setCalendarOpen(false);
+ }}
+ />
+
+
+
{
+ const [h, m] = e.target.value.split(":");
+ const hh = Number.parseInt(h ?? "", 10);
+ const mm = Number.parseInt(m ?? "", 10);
+ if (Number.isNaN(hh) || Number.isNaN(mm)) return;
+ const base = isValidDate(until) ? until : new Date();
+ const next = new Date(base);
+ next.setHours(hh, mm, 0, 0);
+ setUntil(next);
+ }}
+ />
+