Changing Look of Calendar

Changing Look of Calendar

by Laura ***** -
Number of replies: 5

I have included a picture of my calendar that is displaying in Moodle.  What I would like to change is the colors and the text size of the events shown at the bottom.

Does anyone know where this is located in the styles.php file? 

Thank you very much.

Attachment calendar.JPG
Average of ratings: -
In reply to Laura *****

Re: Changing Look of Calendar

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
The "events" Global events, Course events, etc. are in fact links. To change their color, background color, etc.
.block_calendar_month .filters td a {
  color:colorOfYourChoice;
  background-color::colorOfYourChoice
}
You may also wish to change the a:link, a:visited, a:hover properties:
.block_calendar_month .filters td a:link {...}
etc.
Or did you mean you want to change the colors of the cells to the immediate left of each event (green for Global events, orange-red for Course events, etc.) ?
Joseph

In reply to Joseph Rézeau

Re: Changing Look of Calendar

by Laura ***** -

Thank you very much.  This is exactly the information I was looking for.  I really appreciate your help again.

Also, you mentioned changing the colors of the cells to the left of each event too.  How would I do that?

In reply to Laura *****

Re: Changing Look of Calendar

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Hi Laura,
These colors are located in file \theme\stardard\styles_color.css:
/* colors for calendar events */
#calendar .event_global,
.minicalendar .event_global,
.block_calendar_month .event_global {
  border-color:#2EBA0E !important;
  background-color:#2EBA0E;
}

#calendar .event_course,
.minicalendar .event_course,
.block_calendar_month .event_course {
  border-color:#FF9966 !important;
  background-color:#FF9966;
}

#calendar .event_group,
.minicalendar .event_group,
.block_calendar_month .event_group {
  border-color:#FBBB23 !important;
  background-color:#FBBB23;
}

#calendar .event_user,
.minicalendar .event_user,
.block_calendar_month .event_user {
  border-color:#A1BECB !important;
  background-color:#A1BECB;
}

Joseph
In reply to Joseph Rézeau

Re: Changing Look of Calendar

by Laura ***** -

I don't have the file styles_color.css in my theme folder.  I used another theme and had it customized.

Can I copy the above into styles.php?  Would this work?

Thanks again.

In reply to Laura *****

Re: Changing Look of Calendar

by Joseph Rézeau -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Yes, you can copy those CSS lines into any stylesheet which is used by your customized theme.
Joseph