Skip to content

Commit b406fe9

Browse files
committed
Fix issues found by Biome
1 parent 7338c54 commit b406fe9

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

packages/react-date-picker/src/DateInput/Input.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ export default function Input({
148148
value,
149149
}: InputProps): React.ReactElement {
150150
useIsomorphicLayoutEffect(() => {
151-
if (!inputRef || !inputRef.current) {
151+
if (!inputRef?.current) {
152152
return;
153153
}
154154

packages/react-date-picker/src/DatePicker.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -474,7 +474,7 @@ export default function DatePicker(props: DatePickerProps): React.ReactElement {
474474
target &&
475475
wrapperEl &&
476476
!wrapperEl.contains(target) &&
477-
(!calendarWrapperEl || !calendarWrapperEl.contains(target))
477+
!calendarWrapperEl?.contains(target)
478478
) {
479479
closeCalendar({ reason: 'outsideAction' });
480480
}

0 commit comments

Comments
 (0)