diff --git a/site/assets/js/calendar.js b/site/assets/js/calendar.js index ed5d7cf..061cf37 100644 --- a/site/assets/js/calendar.js +++ b/site/assets/js/calendar.js @@ -24,7 +24,26 @@ document.addEventListener('DOMContentLoaded', function () { multiMonthYear: { // Dots keep the year grid readable when a day holds several deadlines. eventDisplay: 'list-item', - multiMonthMinWidth: 260 + multiMonthMinWidth: 260, + // The view hardcodes dayMaxEvents to "fit the cell", so the only way to + // show more than one deadline per day is to make the weeks taller. Month + // table height is width / aspectRatio over six rows: at three columns + // that leaves ~50px a week, enough for the day number plus the two + // deadlines a day carries when an abstract and a paper share a date. + aspectRatio: 1.1, + // A day cell in the year grid is ~50px wide, so the full + // "OSDI — abstract deadline" title only ever renders as a cropped + // fragment. Keep the venue, which is the part that identifies the dot, + // and leave the rest to the hover text and the month and list views. + eventContent: function (arg) { + var dot = document.createElement('div') + dot.className = 'fc-daygrid-event-dot' + dot.style.borderColor = arg.borderColor || arg.backgroundColor + var title = document.createElement('div') + title.className = 'fc-event-title' + title.textContent = arg.event.title.split(' — ')[0] + return { domNodes: [dot, title] } + } } }, eventClick: function (info) { diff --git a/site/layouts/partials/extend_head.html b/site/layouts/partials/extend_head.html index d88b99c..0a2ddbf 100644 --- a/site/layouts/partials/extend_head.html +++ b/site/layouts/partials/extend_head.html @@ -1,5 +1,9 @@ {{- if eq .Layout "calendar" }} {{- end }}