Skip to content

Commit 8d3ca08

Browse files
committed
Tweak schedule page for UI consistency
Try to avoid styling internal links as buttons Refer to abbreviated years with leading '
1 parent 25cd313 commit 8d3ca08

2 files changed

Lines changed: 15 additions & 9 deletions

File tree

_layouts/route.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ <h1 title="{{ page.id }}" class="mb-0 h2">{{ page.title }}</h1>
6363
</span>
6464
{%- endif -%}
6565
{%- endcapture -%}
66-
<h3 class="h5">{{ stats }}</h3>
66+
<div class="mb-3">{{ stats }}</div>
6767

6868

6969
{%- comment -%}

_layouts/schedule.html

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,17 @@
44
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/maplibre-gl@6.0.0-11/dist/maplibre-gl.css" crossorigin="anonymous">
55

66
<div class="schedule container">
7-
<h1 class="mb-0 h2">{{ page.label }}</h1>
7+
{%- assign schedule_label = page.season | append: " '" | append: page.year | capitalize -%}
8+
<h1 class="mb-0 h2">{{ schedule_label }}</h1>
89

910
{%- comment -%}
1011
========================================================================
1112
OVERVIEW
1213
========================================================================
1314
{%- endcomment -%}
14-
<div class="text-muted mb-3">
15+
<div class="mb-3">
1516
<span class="me-3">
16-
{{ page.start_date }} &rarr; {{ page.end_date }}
17+
{{ page.start_date }} to {{ page.end_date }}
1718
</span>
1819
<span class="me-3">
1920
{{ page.event_count }} events
@@ -47,11 +48,13 @@ <h2 class="visually-hidden">Quarter route map</h2>
4748
{%- assign prev_label = page.previous_id -%}
4849
{%- if all_schedules -%}
4950
{%- assign prev_schedule = all_schedules | where: "id", page.previous_id | first -%}
50-
{%- if prev_schedule and prev_schedule.label -%}
51+
{%- if prev_schedule and prev_schedule.season and prev_schedule.year -%}
52+
{%- assign prev_label = prev_schedule.season | append: " '" | append: prev_schedule.year | capitalize -%}
53+
{%- elsif prev_schedule and prev_schedule.label -%}
5154
{%- assign prev_label = prev_schedule.label -%}
5255
{%- endif -%}
5356
{%- endif -%}
54-
<a class="btn btn-outline-secondary"
57+
<a class="text-muted text-decoration-none fw-medium"
5558
href="{{ '/schedules/' | append: page.previous_id | append: '/' | relative_url }}">
5659
&larr; {{ prev_label }}
5760
</a>
@@ -63,9 +66,10 @@ <h2 class="visually-hidden">Quarter route map</h2>
6366
<select id="schedule-selector" class="form-select form-select-sm d-inline-block" style="max-width: 100%;">
6467
{%- assign schedule_list = site.data.schedules_table | sort: 'start_date' -%}
6568
{%- for sched in schedule_list -%}
69+
{%- assign sched_label = sched.season | append: " '" | append: sched.year | capitalize -%}
6670
<option value="{{ '/schedules/' | append: sched.id | append: '/' | relative_url }}"
6771
{% if sched.id == page.id %}selected{% endif %}>
68-
{{ sched.label }}
72+
{{ sched_label }}
6973
</option>
7074
{%- endfor -%}
7175
</select>
@@ -75,11 +79,13 @@ <h2 class="visually-hidden">Quarter route map</h2>
7579
{%- assign next_label = page.next_id -%}
7680
{%- if all_schedules -%}
7781
{%- assign next_schedule = all_schedules | where: "id", page.next_id | first -%}
78-
{%- if next_schedule and next_schedule.label -%}
82+
{%- if next_schedule and next_schedule.season and next_schedule.year -%}
83+
{%- assign next_label = next_schedule.season | append: " '" | append: next_schedule.year | capitalize -%}
84+
{%- elsif next_schedule and next_schedule.label -%}
7985
{%- assign next_label = next_schedule.label -%}
8086
{%- endif -%}
8187
{%- endif -%}
82-
<a class="btn btn-outline-secondary"
88+
<a class="text-muted text-decoration-none fw-medium"
8389
href="{{ '/schedules/' | append: page.next_id | append: '/' | relative_url }}">
8490
{{ next_label }} &rarr;
8591
</a>

0 commit comments

Comments
 (0)