-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature : CSS class names and attributes for days, hours #405
Comments
Hi! Weekday names will already be added as a part of another issue: #309
Can you help me understand your use case for the week grid hours though? Currently those are only 1px lines, you won't be able to style the background of an hour or anything |
For the hours I wanted to mark off zones during the day to not schedule work, or to make work hours. I was thinking of adding psudo :before elements to the hours, but thinking about it might be better to add a slot for each day, so I can add some background divs behind the events. |
Update to this, I might not need a slot or CSS for weekday hours to block out times. If we could turn off draggable and resize per event (previously discussed) I could include some special events that can not be moved, I can style these however I want. However would need to turn off the width resize for overlapping events. But long term, what would be better is to include background events, background events would be:
I can see several use cases here:
It would be up to the developer to add these in, but I can see preloading 20 holidays for the year as background events helpful. To implement, either set a property in the event
or but by a separate list in the config.
eventsServicePlugin.background.get() Having background Events as its own array could be easy from a code point of view, you just draw two lists of events background[] + events[] with different default classes and options OR Layers!!! Like CalendarID, Perhaps a better solution to setting special props per Event, You can create seperate layers with different props
When drawing the calendar.
|
Is your feature request related to a problem? Please describe.
I want to use CSS to highlight certain days, highlight selected day, highlight certain hour ranges.
Describe the solution you'd like
Add in class names related to the to a lot of the elements in, these are additional class names not used by the schedule-x but there for the dev to use
Also add a selected class to sx__time-grid-day.selected_day and sx__week-grid__date.selected_day for the selected day so I can CSS style the selected day.
Additional context
For a lot of these I can add in direct styling or sudo :before :after classes to highlight zones
Things that could speed up the process
The text was updated successfully, but these errors were encountered: