-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
107 lines (90 loc) · 3.22 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
---
title: Home
layout: default
---
{% assign events = site.data.timeline | sort: "date" %}
<h1>{{site.title}}</h1>
<div class="row">
<div class="col-md-8">
<div class="card">
<div class="card-header">
<h2>Upcoming Deadlines</h2>
</div>
<div class="card-body text-center">
<p></p>
<div class="ml-4">
<h3 id="deadline1"><a target="_blank" href=""></a>, DUE: <span></span></h3>
</div>
<div class="ml-4">
<h3 id="deadline1"><a target="_blank" href=""></a>, DUE: <span></span></h3>
</div>
<div class="ml-4">
<h3 id="deadline1"><a target="_blank" href=""></a>, DUE: <span></span></h3>
</div>
</div></div>
<hr />
<div class="card mt-2">
<div class="card-header">
<h2>Recent Meetings</h2>
</div>
<div class="card-body">
{%for post in site.posts limit: 2 %}
<div class="ml-4">
<h3><a target="_blank" href="{{post.url | relative_url}}">{{post.title}}</a></h3>
<p>{{post.date | date: "%b %-d, %Y" }}</p>
</div>
{%endfor%}
</div></div>
</div>
<div class="col-md-4">
<div class="card">
<div class="card-header">
<h2>Agreement Status</h2>
</div>
<div class="card-body text-center">
{%capture agreement_test%}
{%for answer in site.data.starter_answers%}{{answer.text}}{%endfor%}
{%endcapture%}
{% if agreement_test.size <= 20 %}
<a class="btn btn-lg btn-success my-2" href="{{'agreement/start.html' | relative_url}}">Start Agreement</a>
{%elsif site.agreement-final == true%}
<a class="btn btn-lg btn-primary my-2" href="{{'agreement/final.html' | relative_url}}">View Finalized Agreement</a>
{%else%}
<a class="btn btn-lg btn-warning my-2" href="{{'agreement/inprogress.html' | relative_url}}">Continue Agreement</a>
<br/>
<a href="{{'agreement/final.html' | relative_url}}">Print Version</a>
{%endif%}
</div>
</div>
<hr />
<div class="card mt-2">
<div class="card-header">
<h2>People</h2></div>
<div class="card-body text-center">
{% assign people = site.data.people | sort: "name" %}
{%for person in people%}
<img class="col-3 rounded-circle" src='{{person.image}}' />
<p><a href="{{person.link}}">{{person.name}}</a> | <a href="{{person.email}}"><i class="fas fa-envelope"></i></a>
</p>
{%endfor%}
</div>
</div>
</div>
</div>
<script>
/* add item data */
var items = { {% for event in events %} "event{{forloop.index}}" : { "type": "{{event.type}}", "date": "{{event.date}}", "title": "{{event.title}}", "location": "{{event.location}}", "link": "{{event.link}}", "priority": "{{event.priority}}", "people": "{{event.people}}"}{%unless forloop.last%},{%endunless%}
{%endfor%} };
const dates = [{%for d in site.data.timeline%}
'{{d.date}}'{%unless forloop.last%},{%endunless%}{%endfor%}
];
const now = new Date();
let closest = Infinity;
dates.forEach(function(d) {
const date = new Date(d);
if (date >= now && (date < new Date(closest) || date < closest)) {
closest = d;
}
});
console.log(closest);
</script>