Answers.Body: <p>Within the context of <code>calendar.month</code>, if you check out the demo templates, we style the beginning and end of multi-day events with the following code:</p>
  
  <pre><code>{% if event.multiDay %}
      {% set classes = classes ~ " multi_day" %}
      {% set classes = classes ~ (day.containsDate(event.startDateLocalized) ? " first_day") %}
      {% set classes = classes ~ (day.containsDate(event.endDateLocalized) ? " last_day") %}
  {% endif %}
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-27T15:51:51.117Z
Answers.Text: Excellent! Thanks - I must've missed that in the demo templates.
Answers.UserDisplayName: A Herrera
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-27T21:57:05.483Z
Answers.Text: This is almost fully working. The bit that doesn't work is the "first_day" class per your example. Even in the demo templates the class for the first day isn't applied. Any ideas?
Answers.UserDisplayName: A Herrera
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-27T21:58:04.190Z
Answers.Text: Screenshot of the demo templates in my setup here: https://d.pr/i/a0T1BV
Answers.UserDisplayName: A Herrera
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-28T14:10:14.867Z
Answers.Text: Perhaps try reinstalling demo templates. Multi-day events appear to display correctly for me...
Answers.UserDisplayName: Solspace
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-01T17:09:40.457Z
Answers.Text: Hm, that didn't work.
Answers.UserDisplayName: A Herrera
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-02T20:24:23.403Z
Answers.Text: I'm going to guess your event is 2 days long? I am looking back at my test site and it appears this works smoothly for events 3 days or longer, but has trouble with the first of 2 days. Checking into that... EDIT, just saw your screenshot shows 3-day event...
Answers.UserDisplayName: Solspace
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-02T20:43:53.737Z
Answers.Text: Okay, it seems to only work correctly for multi-day events that are not All Day events. It would seem that this is acting as "intended", according to the docs, but obviously this is an oversight. I have made a note about this and we'll address it in the near future. :)
Answers.UserDisplayName: Solspace
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-03T16:38:42.573Z
Answers.Text: Okay cool, thank you!
Answers.UserDisplayName: A Herrera
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-03T20:18:39.250Z
Answers.Text: I've updated the solution... you'll want to just use `startDateLocalized` and `endDateLocalized` instead. This will work for you right now if you switch it. :)
Answers.UserDisplayName: Solspace
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-15T20:34:35.333Z
Answers.Text: Perfect, thanks!
Answers.UserDisplayName: A Herrera
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-27T03:49:44.817Z
Answers.LastActivityDate: 2019-04-03T20:18:54.480Z
Answers.LastEditDate: 2019-04-03T20:18:54.480Z
Answers.UserDisplayName: Solspace
Body: <p>Is there a way to get the first and last days of a multi-day event? I want to be able to style the first and last days differently. I don't see anything like this in the docs.</p>
  
  <p>This is in Craft 3 and Calendar 2.0.17</p>
  
Tags: <craft3><plugin-solspacecalendar><calendar><plugin-calendar>
Title: Getting the first and last days of a multi-day event - Solspace Calendar
ThreadText: # Getting the first and last days of a multi-day event - Solspace Calendar
  
  (Asked by: username_0 on 2019-03-26)
  
  Is there a way to get the first and last days of a multi-day event? I want to be able to style the first and last days differently. I don't see anything like this in the docs.
  
  This is in Craft 3 and Calendar 2.0.17
  
  **Tags:** craft3, plugin-solspacecalendar, calendar, plugin-calendar
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-03-27. Score: 1 | Accepted answer
  
  Within the context of `calendar.month`, if you check out the demo templates, we style the beginning and end of multi-day events with the following code:
  
  ```
  {% if event.multiDay %}
      {% set classes = classes ~ " multi_day" %}
      {% set classes = classes ~ (day.containsDate(event.startDateLocalized) ? " first_day") %}
      {% set classes = classes ~ (day.containsDate(event.endDateLocalized) ? " last_day") %}
  {% endif %}
  
  ```
  
  > **Comments:**
  > **username_0**: Excellent! Thanks - I must've missed that in the demo templates.  
  > **username_0**: This is almost fully working. The bit that doesn't work is the "first_day" class per your example. Even in the demo templates the class for the first day isn't applied. Any ideas?  
  > **username_0**: Screenshot of the demo templates in my setup here: https://d.pr/i/a0T1BV  
  > **username_1**: Perhaps try reinstalling demo templates. Multi-day events appear to display correctly for me...  
  > **username_0**: Hm, that didn't work.  
  > **username_1**: I'm going to guess your event is 2 days long? I am looking back at my test site and it appears this works smoothly for events 3 days or longer, but has trouble with the first of 2 days. Checking into that... EDIT, just saw your screenshot shows 3-day event...  
  > **username_1**: Okay, it seems to only work correctly for multi-day events that are not All Day events. It would seem that this is acting as "intended", according to the docs, but obviously this is an oversight. I have made a note about this and we'll address it in the near future. :)  
  > **username_0**: Okay cool, thank you!  
  > **username_1**: I've updated the solution... you'll want to just use `startDateLocalized` and `endDateLocalized` instead. This will work for you right now if you switch it. :)  
  > **username_0**: Perfect, thanks!  
  
  ---
  
  