Read the statement by Michael Teeuw here.
Default Calendar Module | Countdown until full day events
-
Hi,
i’m using the default calendar module to give me an overview of upcoming public holidays.
I’m not interested in the actual date, but rather more how many more days until the next public holiday.I cannot for the life of me get this to work.
This is my config.js{ module: "calendar", position: "bottom_left", header: "Public Holidays", config: { colored: false, coloredSymbolOnly: false, maximumEntries: 10, maximumNumberOfDays: 180, timeFormat: "relative", getRelative: 90, urgency: 90, calendars: [ { url: 'https://calendar.google.com/calendar/ical/en.german%23holiday%40group.v.calendar.google.com/public/basic.ics', symbol: 'calendar', // GERMAN HOLIDAYS }, ], }, },
The leads to the following calendar showing up:
I does not seem to make a difference if I change
timeFormat: "relative",
to
timeFormat: "absolute",
I am sure this can be achieved, because another instance of the default calendar gives me infos on upcoming events such as “in 2 Days”, “Tomorrow” etc.
Any ideas why this doesn’t work on my Public Holiday Calendar ?
Thanks
-
-
@sdetweil
Thanks for your help.
I edited it tomodule: "calendar", position: "bottom_left", header: "Public Holidays", config: { colored: false, coloredSymbolOnly: false, maximumEntries: 10, maximumNumberOfDays: 180, timeFormat: "relative", getRelative: 90 * 24, urgency: 90, calendars: [
which unfortunately didn’t make any difference.
https://forum.magicmirror.builders/topic/13278/calendar-how-to-change-in-2-days
Covers my issue, and here the author mentions issues with full day events. Any chance this could be the culprit ? -
@p1lspeda there is a bug in the code
for 2.21 do this
edit ~/MagicMirror/modules/default/calendar/calendar.js
comment out line 383
//if (event.fullDayEvent) { // Full days events within the next two days
and change line 394 like this (comment out the close of the IF above and the else
/*} else*/ if (event.startDate - now
-
@sdetweil
Thank you so much.
Looks like we’re getting there.
If the current Public Holiday could be described with “Today/now”, it would be the cherry on the cake. -
@p1lspeda no mechanism to create special formatting