week-planner-card icon indicating copy to clipboard operation
week-planner-card copied to clipboard

Card mod filter for specific event

Open cofw2005 opened this issue 5 months ago • 0 comments

Excuse me! Could you please kindly help? I would like to set the event background card based on the name of the event. For example, this is the event list:

calendar.my_calender:
  events:
    - start: "2024-09-16T08:00:00+02:00"
      end: "2024-09-16T09:30:00+02:00"
      summary: Geographie
      location: 2. OG 210
    - start: "2024-09-16T09:45:00+02:00"
      end: "2024-09-16T11:15:00+02:00"
      summary: Sport
      location: Turnhalle links
    - start: "2024-09-16T11:30:00+02:00"
      end: "2024-09-16T12:15:00+02:00"
      summary: Informatik
      location: 1. OG 105

For example, if I want to apply background color: red for Geographie, green for Sport. How can I achieve this with the card mod? I tried with | selectattr() filter but didn't get success. Please kindly help. Thanks very much!

cofw2005 avatar Sep 16 '24 20:09 cofw2005