Posted by mshepherd on October 26, 2011 at 3:19pm
3 followers
| Project: | Calendar |
| Version: | 7.x-3.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (fixed) |
Issue Summary
I've got this problem where the time labels in the left column of the calendar in a day or week display get mangled in my theme (a fusion subtheme):

I can get round this somewhat by changing the line-height of the elements in question, but actually, I'd much prefer to change the format of this text like this:
Before 1:00 am to Before 1am or even <1am
So, removing the minutes altogether (they don't need to be there) and removing the space between the hour and the am or pm, which shouldn't be there.
Can this be changed in the module - I can't find where this gets defined. I'd happily make a patch if I could see where this gets defined.
Or can I change it with a theme function?
Comments
#1
I've just spotted why the time and am/pm get space between them:
<span class="calendar-hour">Before 1:00</span><span class="calendar-ampm">am</span>
There's a line break between the 2 span tags which browsers treat as a space, regardless of the html specs - see http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.1
#2
A patch to remove the space between the time & apm/pm on week, week-overlap, day and day-overlap views.
#3
#4
I moved my issue with removing minutes from these same displays to #1323280: Remove minutes for day and week calendar views and provided a patch.
#5
Looks reasonable. Committed. Thanks!
#6
Automatically closed -- issue fixed for 2 weeks with no activity.