diff --git a/docs/index.html b/docs/index.html
index 7e7b3f7..379e530 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -90,7 +90,7 @@
Friday
diff --git a/docs/index.js b/docs/index.js
index a647231..016617c 100644
--- a/docs/index.js
+++ b/docs/index.js
@@ -111,7 +111,7 @@ function populate() {
for (const event of data[level].common.events) {
if (event.not && event.not.includes(plan.code)) continue;
const day = planSect.querySelector(`article[data-day="${event.day}"]`);
- console.log('planning: ' + JSON.stringify(event));
+// console.log('planning: ' + JSON.stringify(event));
populateEvent(day, event);
}
}
@@ -172,6 +172,15 @@ function populateEvent(day, event) {
} else {
eventElem.querySelector('.building').textContent = `${event.building} Building`;
eventElem.querySelector('.room').textContent = event.room;
+ if (event.building) {
+ // lookup the building url in data.buildings
+ const [building] = data.buildings.filter( br => br.name == event.building );
+ const mapElem = eventElem.querySelector('.map');
+ if (building?.url) {
+ mapElem.innerHTML = `(map)`;
+ mapElem.classList.remove('hidden');
+ }
+ }
}
eventElem.dataset.time = event.time;
diff --git a/docs/style.css b/docs/style.css
index 0d8beab..1d2e49a 100644
--- a/docs/style.css
+++ b/docs/style.css
@@ -136,7 +136,8 @@ article[data-day]>* {
}
.building,
-.room {
+.room,
+.map {
font-size: 80%;
color: #369;
font-weight: bold;