mirror of
https://github.com/zadam/trilium.git
synced 2025-12-06 07:24:25 +01:00
fix(launch_bar): calendar month selector not actually working
This commit is contained in:
parent
66620aabe2
commit
83838bbe76
@ -134,9 +134,7 @@ function CalendarMonthSelector({ date, setDate }: CalendarHeaderProps) {
|
||||
<FormDropdownList
|
||||
values={months} currentValue={date.month().toString()}
|
||||
keyProperty="index" titleProperty="text"
|
||||
onChange={value => {
|
||||
|
||||
}}
|
||||
onChange={(index) => setDate(date.set("month", parseInt(index, 10)))}
|
||||
buttonProps={{ "data-calendar-input": "month" }}
|
||||
dropdownOptions={{ popperConfig: { placement: "bottom" } }}
|
||||
/>
|
||||
|
||||
@ -75,7 +75,11 @@ export default function Dropdown({ id, className, buttonClassName, isStatic, chi
|
||||
if (externalContainerRef) externalContainerRef.current = containerRef.current;
|
||||
|
||||
const $dropdown = $(containerRef.current);
|
||||
$dropdown.on("show.bs.dropdown", onShown);
|
||||
$dropdown.on("show.bs.dropdown", (e) => {
|
||||
// Stop propagation causing multiple shows for nested dropdowns.
|
||||
e.stopPropagation();
|
||||
onShown();
|
||||
});
|
||||
$dropdown.on("hide.bs.dropdown", (e) => {
|
||||
// Stop propagation causing multiple hides for nested dropdowns.
|
||||
e.stopPropagation();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user