-
Notifications
You must be signed in to change notification settings - Fork 61
Description
Hi,
I'm testing out features with the Calendar and I noticed I can't control the event colors when specifying it directly in the events.
The only way to change the color is using the calendar's event_color property. This sets all the events to have the same color, which isn't really desired in this case.
While I'm at it, I thought I could use the type='category' and group by the available categories from my events to distinguish them, but with type='category', the widget doesn't actually render a calendar.
Appreciate any help to get this working.
Example:
import ipyvuetify as v
Define events with different types/colors
events = [
{'name': 'Weekly Sync', 'start': '2024-01-27 09:00', 'end': '2024-01-27 10:00', 'color': 'blue',"category":"A"},
{'name': 'Lunch', 'start': '2024-01-27 12:00', 'color': 'green',"category":"B"},
{'name': 'Project Phase 1', 'start': '2024-01-28', 'end': '2024-01-30', 'color': 'red', "category":"B"},
]
Create calendar
calendar = v.Calendar(
events=events,
event_color='yellow',
type='week',
value='2024-01-27'
)
calendar_categories = v.Calendar(
events=events,
categories =["A", "B"],
categories_show_all=True,
type='category',
value='2024-01-27'
)