mirror of
https://github.com/zadam/trilium.git
synced 2025-11-05 04:45:47 +01:00
fix(calendar): becomes invisible if resizing while not visible
This commit is contained in:
@@ -165,6 +165,7 @@ export default class CalendarView extends ViewMode {
|
||||
locale: await CalendarView.#getLocale(),
|
||||
height: "100%",
|
||||
nowIndicator: true,
|
||||
handleWindowResize: false,
|
||||
eventDidMount: (e) => {
|
||||
const { iconClass, promotedAttributes } = e.event.extendedProps;
|
||||
|
||||
@@ -233,6 +234,9 @@ export default class CalendarView extends ViewMode {
|
||||
calendar.render();
|
||||
this.calendar = calendar;
|
||||
|
||||
new ResizeObserver(() => calendar.updateSize())
|
||||
.observe(this.$calendarContainer[0]);
|
||||
|
||||
return this.$root;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user