Changeset - 734a0b713d2d
[Not reviewed]
Joel Addison - 3 years ago 2021-01-24 02:03:00
joel@addison.net.au
Improve printed schedule

Show each day on a new page when printed.
Hide elements that do not assist with printed copy (current time, etc).
5 files changed with 9 insertions and 5 deletions:
0 comments (0 inline, 0 general)
pinaxcon/templates/symposion/schedule/schedule_conference.html
Show inline comments
...
 
@@ -43,13 +43,13 @@
 
        <div class="col-12">
 
          <h2 class="my-4">
 
            {{ section.schedule.section.name }}
 
            <span class="clearfix d-sm-block d-md-none"></span>
 
            <small class="text-muted">{{ timetable.day.date|date:"l" }}, {{ timetable.day.date }}</small>
 
          </h2>
 
          <p class="timezone-info small">Conference times are in {{ settings.LCA_START|date:'T' }} (UTC{{ settings.LCA_START|date:'O' }}). Current talks will be highlighted.</p>
 
          <p class="timezone-info small">Conference times are in {{ settings.LCA_START|date:'T' }} (UTC{{ settings.LCA_START|date:'O' }}). <span class="d-print-none">Current talks will be highlighted.</span></p>
 
          <div class="table-responsive d-none d-md-block">
 
            {% include "symposion/schedule/_grid.html" %}
 
          </div>
 
          <div class="mobile-schedule d-sm-block d-md-none">
 
            {% include "symposion/schedule/_mobile.html" %}
 
          </div>
pinaxcon/templates/symposion/schedule/schedule_detail.html
Show inline comments
...
 
@@ -8,18 +8,18 @@
 
{% block head_title %}{{ schedule.section.name }} Schedule{% endblock %}
 
{% block page_title %}{{ schedule.section.name }} Schedule{% endblock%}
 

	
 
{% block content %}
 
  {% cache 600 "schedule-detail-table" schedule.section %}
 
    {% for timetable in days %}
 
    <div class="row">
 
    <div class="row timetable-day">
 
      <div class="col-12">
 
        <h2 class="my-4">
 
          {{ timetable.day.date|date:"l" }}, {{ timetable.day.date }}
 
        </h2>
 
        <p class="timezone-info small">Conference times are in {{ settings.LCA_START|date:'T' }} (UTC{{ settings.LCA_START|date:'O' }}). Current talks will be highlighted.</p>
 
        <p class="timezone-info small">Conference times are in {{ settings.LCA_START|date:'T' }} (UTC{{ settings.LCA_START|date:'O' }}). <span class="d-print-none">Current talks will be highlighted.</span></p>
 
        <div class="table-responsive d-none d-md-block">
 
          {% include "symposion/schedule/_grid.html" %}
 
        </div>
 
        <div class="mobile-schedule d-sm-block d-md-none">
 
          {% include "symposion/schedule/_mobile.html" %}
 
        </div>
pinaxcon/templates/symposion/schedule/schedule_edit.html
Show inline comments
...
 
@@ -21,13 +21,13 @@
 
  {% for timetable in days %}
 
  <div class="row">
 
    <div class="col-12">
 
      <h2 class="my-4">
 
        {{ timetable.day.date|date:"l" }}, {{ timetable.day.date }}
 
      </h2>
 
      <p class="timezone-info small">Conference times are in {{ settings.LCA_START|date:'T' }} (UTC{{ settings.LCA_START|date:'O' }}). Current talks will be highlighted.</p>
 
      <p class="timezone-info small">Conference times are in {{ settings.LCA_START|date:'T' }} (UTC{{ settings.LCA_START|date:'O' }}). <span class="d-print-none">Current talks will be highlighted.</span></p>
 
      <div class="table-responsive d-none d-md-block">
 
        {% include "symposion/schedule/_grid.html" with edit_schedule=True %}
 
      </div>
 
      <div class="mobile-schedule d-sm-block d-md-none">
 
        {% include "symposion/schedule/_mobile.html" with edit_schedule=True %}
 
      </div>
static/src/js/schedule.js
Show inline comments
...
 
@@ -131,13 +131,13 @@ $(function() {
 
    }
 

	
 
    var updateClock = function() {
 
        var clock = $('div.conf-clock');
 
        if (clock.length === 0) {
 
            var template = document.createElement('template');
 
            template.innerHTML = '<div class="conf-clock"></div>';
 
            template.innerHTML = '<div class="conf-clock d-print-none"></div>';
 
            var clockDiv = template.content.firstChild;
 
            document.body.appendChild(clockDiv);
 
            clock = $(clockDiv);
 
        }
 

	
 
        var now = luxon.DateTime.local();
static/src/scss/app.scss
Show inline comments
...
 
@@ -119,7 +119,11 @@ label.label-required:after { content: ' *'; }
 
@media print {
 
    .fade {
 
        &:not(.show) {
 
            opacity: 100 !important;
 
        }
 
    }
 

	
 
    .timetable-day:not(:first-child) {
 
        break-before: page;
 
    }
 
}
0 comments (0 inline, 0 general)