v1.0.4
Overview
🔧 Bug Fixes
- useDate: add a fixedWeeks mode to getWeekArray (#797)
- useDragDrop: anchor the drop indicator to the slot and suppress no-op slots (#818)
- useDate: correct the first day of the week on Firefox and make week data consistent across browsers (#796)
Patch Changes
-
#797
5a9a388Thanks @johnleider! - fix(useDate): add a fixedWeeks mode to getWeekArraygetWeekArray(date, fixedWeeks?)can now pad the month matrix to a constant 6 rows (42 cells), so calendar grids keep a stable height across months instead of jumping between 4, 5, and 6 rows. Padding continues day-by-day into the next month; months that naturally span 6 rows are unchanged. Default behavior without the flag is identical to before. -
#818
a7334f8Thanks @johnleider! - fix(useDragDrop): anchor the drop indicator to the slot and suppress no-op slotsAn interior drop slot now always renders against the end edge of the rect above it. Previously the same slot anchored to the rect above or the rect below depending on which side the pointer approached from, so the indicator visibly jumped across the gap mid-drag — dragging a card down a column drew the line at the top of the next card instead of walking edge to edge.
A drag over its own zone also no longer proposes the two slots flanking the dragged element's current position: dropping in either puts it straight back where it sits, so the indicator stays hidden there — grabbing the first card and nudging the pointer above it no longer draws a line over its own head — and a drop on a suppressed slot resolves
position.indexto the element's current slot instead of0. -
#796
4a19d6cThanks @johnleider! - fix(useDate): correct the first day of the week on Firefox and make week data consistent across browsersCalendars rendered a Sunday-start week for every locale on Firefox —
de-DE,fr-FR, anden-GBall laid out incorrectly — and could disagree between server and client when Node and browser ICU versions differ. Week start andminimalDaysnow come from CLDR 48 data on every runtime, so the same locale always produces the same week layout in Chromium, Firefox, Safari, and Node. An explicit-u-fw-keyword on the locale (e.g.en-US-u-fw-mon) is honored everywhere, andminimalDaysfor bare language tags is now the correct value for the locale's likely region (affects week numbers for e.g.svandpt).