We have a use case in which a Calendar block appears in the sidebar of an Event node (Figure 1). Each node has a specific date set in a Date field (as highlighted in red box).

The purpose of the Calendar block is to allow the user to navigate to a different Event date. The current date (April 28, 2016 in the case of Figure 1) has a distinct style. We would like to apply a CSS style to indicate the date of the node. The problem we see is that there is no class to indicate the day link that corresponds to the active page (e.g. example.com/2016-04-24)

Is there any setting in the module or in the calendar block view display that could accomplish this functionality?

Any help would be appreciated.

Figure 1
Calendar block

CommentFileSizeAuthor
#2 calendar-block-active-date-style.jpg106.68 KBmikebrooks
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mithesh created an issue. See original summary.

mikebrooks’s picture

Title: Distinct style for active date. » Distinct style for active date in calendar block
Issue summary: View changes
FileSize
106.68 KB
Anonymous’s picture

As for now, there is not. I think the easiest way to accomplish this, is by adding a custom preprocessor that adds the class before rendering the template. I haven't tested this though.

mikebrooks’s picture

Thanks pjonckiere.

Yes, a preprocessor would probably be easier.

This issue is a relatively low priority in our customer backlog. We'll post a solution if and when it gets into a sprint. I am sorry that I cannot be more specific with the commitment at this time.

Neslee Canil Pinto’s picture

Status: Active » Closed (outdated)