Skip to content

Commit 823d564

Browse files
authored
fix: prevent calendar from jumping on small screen heights (#2192)
1 parent 63a233e commit 823d564

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

client/src/components/UI/DateRangePicker.jsx

+20
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,16 @@ const DateRangePicker = ({
6464
dateFormat="yyyy-MM-dd"
6565
placeholderText={startDatePlaceholder || ""}
6666
popperPlacement="bottom-start"
67+
popperModifiers={[
68+
{
69+
name: "flip",
70+
enabled: false
71+
},
72+
{
73+
name: "hide",
74+
enabled: false
75+
}
76+
]}
6777
onCalendarOpen={handleCalendarOpen}
6878
onCalendarClose={handleCalendarClose}
6979
onClick={e => {
@@ -87,6 +97,16 @@ const DateRangePicker = ({
8797
dateFormat="yyyy-MM-dd"
8898
placeholderText={endDatePlaceholder || ""}
8999
popperPlacement="bottom-end"
100+
popperModifiers={[
101+
{
102+
name: "flip",
103+
enabled: false
104+
},
105+
{
106+
name: "hide",
107+
enabled: false
108+
}
109+
]}
90110
onCalendarOpen={handleCalendarOpen}
91111
onCalendarClose={handleCalendarClose}
92112
// withPortal

0 commit comments

Comments
 (0)