mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 09:46:36 +00:00
fix height issue calendar, make default on mobile list (#18394)
This commit is contained in:
parent
f6fddbc6ec
commit
a745539c33
@ -259,6 +259,7 @@ export class HAFullCalendar extends LitElement {
|
||||
|
||||
protected firstUpdated(): void {
|
||||
this._loadCalendar(this.initialView);
|
||||
this._activeView = this.initialView;
|
||||
}
|
||||
|
||||
private async _loadCalendar(initialView: FullCalendarView) {
|
||||
@ -512,7 +513,7 @@ export class HAFullCalendar extends LitElement {
|
||||
--ha-card-background,
|
||||
var(--card-background-color, white)
|
||||
);
|
||||
min-height: 400px;
|
||||
height: var(--calendar-height);
|
||||
--fc-neutral-bg-color: var(
|
||||
--ha-card-background,
|
||||
var(--card-background-color, white)
|
||||
|
@ -178,6 +178,7 @@ class PanelCalendar extends LitElement {
|
||||
.events=${this._events}
|
||||
.calendars=${this._calendars}
|
||||
.narrow=${this.narrow}
|
||||
.initialView=${this.narrow ? "listWeek" : "dayGridMonth"}
|
||||
.hass=${this.hass}
|
||||
.error=${this._error}
|
||||
@view-changed=${this._handleViewChanged}
|
||||
|
@ -242,6 +242,10 @@ export class HuiCalendarCard extends LitElement implements LovelaceCard {
|
||||
padding-inline-start: 8px;
|
||||
direction: var(--direction);
|
||||
}
|
||||
|
||||
ha-full-calendar {
|
||||
--calendar-height: 400px;
|
||||
}
|
||||
`;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user