MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. chadjohn2
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    C
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 0
    • Posts 1
    • Groups 0

    chadjohn2

    @chadjohn2

    0
    Reputation
    1
    Profile views
    1
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    chadjohn2 Unfollow Follow

    Latest posts made by chadjohn2

    • RE: MMM-CalendarExt3

      First off, I’m a complete and utter noob with coding. I’m capable enough to get MagicMirror installed and start adding in some of the 3rd party modules. I’m now trying to get into the space of modifying CSS and such for a little added customization.

      I’m trying to something that I think should be simple but I cannot get it work for the life of me. I’ve searched the forum and this topic and found a couple pieces but I’m still struggling. Finally got frustrated enough to create an account and post.

      I’m trying to change the color of events based on the title of an event coming from a google calendar. The events are coming in fine, just not changing color.

      Based on what I have read, I need to use the eventTransformer function. I have put the following into the config.js file (including the full module for total information).

      { 
      module: "MMM-CalendarExt3",
      position: "bottom_bar",
      config: {
      			mode: "week",
      			weekIndex: "0",
      			weeksInView: "2",
      			firstDayOfWeek: "1",
      			maxEventLines: "8",
      			fontSize: "25px",
      			eventHeight: "16px"
      		},
      eventTransformer: function(event) {
      if (event.title.search('Daycare') > -1) {
      event.className = 'Daycare'
      				}
      			}	
      		}
      

      then in the custom.css file (Trying hot pink hex so it pops out):

      .CX3 .Daycare {
      background-color:#FF69B4;
      color:#FF69B4;
      }
      

      For all I know, that’s completely wrong so any help you can provide will be appreciated!

      posted in Utilities
      C
      chadjohn2