Lovelace Google Calendar

I’m sorry but I made a big mistake. I wrote in this post about my changes, now I see I was making changes not to this calendar, there are two (at least):

  • calendar-car made by rdehuyss (https://github.com/rdehuyss/homeassistant-lovelace-google-calendar-card) - this post is about this one, but it’s not being updated last months
  • calendar-card created by ljmerza (https://github.com/ljmerza/calendar-card). Updated few days ago, different fonts, but progress bar is not working.
    They are similar, but not the same. Now I see progress is not working im my version, but works in original rdehuyss one. I need to check it. I would like to make it more customizable but now I have to decide which one I should use:)

Is there a way with any of these calendars to colour-code the events on a per-calendar basis?

Currently not possible, but I’m thinking about it - it’s one of reasons why I started to edit the code

OH okay :). Well I switched from rdehuyss to the ljmerza one because I thought that was the one you talked about. For now, that one seem to run quite good (except from the progress bar). I don’t think rdehuyss have time to update his own one. Been some time since last update and no response tonwother post or issues on github.

But please keep us posted on your choice :slight_smile:

Thanks, had to clear the cash and open the desktopsite for a moment on my phone. It works since.

I like how the card includes a link to Google Maps for the location of the event, however, it’s only creating a link with the city, state, and zip. It’s missing the street address. Does anyone have a fix for this?

Try now, I made a change here, now the link is pointing to whole address. I’m not sure what to show in link text, now it’s the first part of address (street and number in this case, or city when you don’t add street in event).
EDIT: made some experimental changes.

  1. only event title is clickable (move you to google calendar) to make possible clicking on location
  2. added experimental progress bar:
  • if only showProgressBar: true there shouldn’t be any difference, progress bar works like before
  • if you set showProgressBar: true and showCurrentProgress: true - if the event is currently running, the little dot wil move throught the bar and it will be red. Even multiple events supported. If no event running right now, the standart blue one will be visible.
    It’s not fully tested so please make it on your own risk :slight_smile: cal-new
    The next things I’ll work are colors (for different calendars) and font sizes (those are too big in my opinion I’ll add some percentage change in config)

And while you are taking requests…:slightly_smiling_face:

Could you add the month (in short form at least) above the date. This was discussed up thread and I made the change but it then screwed up all my formatting/alignment as seen in my screen shots and I don;'t know how to fix it again…yet.

Thanks!

So, now I have a hyperlink that takes me to Google maps with the correct address, however, the event time is the link and the location is blank.

Some big changes.

  1. Now you can add calendars as configurable entities, with custom colors:
entities:
  - calendar.ljmerzagmailcom
  - entity: calendar.with_red_color_title
    color: red
  - calendar.atomic7777 

If color is not set, it will show default color of text in HA. I can’t use Google Calendar’s colors, because colors are not retrieved by HA’s calendar component.
2. You can change text sizes (because calendar should have smaller font imho)
textSizeSummary: 100
textSizeTime: 90
textSizeLocation: 90
3. New setting: showMonth = true will show month - requested by finity (please tell me if it works as it should), default disabled

martamoonpie: I broke links yesterday but fixed it already, try to reload, it’s working for me - click on title to move to calendar, click on location links to gmaps

Please be aware that this is experimental version, adding one thing and breaking another :slight_smile: Trying to fit it to my needs, but make it configurable for others. There are a lot of changes and additions comparing to original ljmerza’s code.

Today ljmerza uploaded a new version 2.0 - he is rewriting calendar-cards. I think I will keep on github my version and make it more configurable.

1 Like

Looks great! Thank you!

That’s much better now.Thanks! Once I re-modified the marker icon & the link colors it looks really good.

Still having a small problem with the event title alignment but someone mentioned it could be due to the multi-line location.

ex

In a couple of days those entries will go away and then I can verify if that is the cause or not. But it already looks much better now.

It’s not just the multiline location. If the event title is multi line with no location it’ll cause the formatting issue as well. You can shrink your window to force it to happen.

edit:
I switched to the version of the card that @atomic77 based their’s on. Here’s the github:

It removes most of the configuration options, so may not meet your needs. But it does eliminate the formatting issue with the other card. It also seems to load a lot faster than any of the other versions of the card.

Hi,
I saw that there was a card update the other night and I updated it.
But as for today, I can’t add the colors on each calendar entity.

Do I need to downgrade the calendar-card?

Important notice. To be clear:

  • I think the original author is rdehuyss. But he’s not maitaining the code.
  • ljmerza made his version of rdehuyss code (I think, it’s 95% same), but now he rewrites the calendar code from scratch, and he changed version to 2.0. I should be a bit faster, because loads moments.js directly from js file. But it don’t have so many options. It’s on his github. No colors (it had no right to work even if there was a setting for it) it’s here: GitHub - ljmerza/calendar-card: Home Assistant Lovelace UI Custom Google Calendar Card
  • I made a fork of the code, version 1.x.x. It’s the old ljmerza code, but I added many functions, colors, fixes.
    If you want to be faster download moment.min.js or moment-with-locales.min.js to /www directiory and point it in config (- url: /local/moment-with-locales.min.js) it’s a good idea both for my version and for new jlmerza code.

If you want to have a bit faster version maitained by a professional, go to 2.0 version ljmerza github.
I’m not a professional js coder (just a hobbyist), js is new to me, and I’m fixing the 1.x.x version for my own needs. My version is on my github GitHub - atomic7777/calendar-card: Home Assistant Lovelace UI Custom Google Calendar Card
In free time I write my own calendar from scratch too :slight_smile: There will be 164 versions of HA calendar :smiley:

Now I think I fixed the aligment problem, and added colors of link and location icon:

        linkColor: red
        mapIconColor: red

they are default if not set.

1 Like

Yeah now it all makes sense. Thanks for clearing it out - again I think :smile:.

Let us know when we can add yours to the custom_updater as well.
I personally think you add some nice features!

1 Like

Now it’s pretty much perfect! Thanks!

ex

And I only say “mostly” because I’m sure there is something that can still be fiddled around with. :smile:

Ok, @atomic77, I may have spoken too quickly…

In the quest to try to get the display correct I completely missed that the calendar isn’t updating at all. I guess I didn’t really think too much about it because my “start date” for the stay in PA was Feb 3rd and it didn’t end until yesterday so it didn’t register that it might not be updating but that event ended yesterday and it’s still being displayed.

I’ve tried refreshing lovelace and restarting HA but it didn’t help.

If I go to the calendar sensor itself in the dev-states it says the next event is the “…in memphis” event.

Do you have any idea how I can troubleshoot to see why it isn’t updating or is it some kind of fluke of multi-day events?

I’ll try to investigate it, I think it’s not my fault, because I didn’t do anything with events code, just some cosmetic changes. At first glance I can’t see any code, which is responsible for multiday events, and I never checked it.
Now I’m writing my own calendar and I’m trying to consider different scenarios, but it’s still a lot of work to do.

I have a “morning notice” where I get temperature, travel time etc. I would also like to get todays activitites from the calender card. Anybody know if thats possible?