MCPcopy Create free account
hub / github.com/coder/coder / handleOpenChange

Function handleOpenChange

site/src/components/DateRangePicker/DateRangePicker.tsx:159–164  ·  view source on GitHub ↗
(next: boolean)

Source from the content-addressed store, hash-verified

157 // latest committed value. Reverse the boundary normalization so
158 // the calendar highlights the correct inclusive dates.
159 const handleOpenChange = (next: boolean) => {
160 if (next) {
161 setSelection(fromBoundary(value));
162 }
163 setOpen(next);
164 };
165
166 // Compare in the same coordinate space (raw calendar dates) so
167 // re-selecting the identical range doesn't enable Apply.

Callers 2

AutocompleteFunction · 0.50
handleInlineKeyDownFunction · 0.50

Calls 1

fromBoundaryFunction · 0.85

Tested by

no test coverage detected