diff --git a/static/js/timeline.js b/static/js/timeline.js new file mode 100644 index 0000000..67d99a3 --- /dev/null +++ b/static/js/timeline.js @@ -0,0 +1,13 @@ +function toggleTimeline(id, dot) { + const el = document.getElementById(id); + + if (el.style.display === "none") { + el.style.display = "block"; + dot.textContent = ""; + dot.classList.remove("collapsed"); + } else { + el.style.display = "none"; + dot.textContent = "+"; + dot.classList.add("collapsed"); + } +} diff --git a/templates/base.html b/templates/base.html index 94e7c2c..c5dc6b4 100644 --- a/templates/base.html +++ b/templates/base.html @@ -21,7 +21,15 @@ href="{{ url_for('static', filename='css/blog.css') }}" rel="stylesheet" /> + +