From a3a02d92b864320b56ff209c2ad69cbdab95a13f Mon Sep 17 00:00:00 2001 From: "Jake Nabasny, PhD" Date: Mon, 4 Mar 2024 12:04:52 -0500 Subject: [PATCH] Add option for local HTML files (#2245) Add option to link HTML local files from publications page. --------- Co-authored-by: Jake Nabasny --- _bibliography/papers.bib | 8 ++++++++ _layouts/bib.liquid | 6 +++++- assets/html/relativity.html | 10 ++++++++++ 3 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 assets/html/relativity.html diff --git a/_bibliography/papers.bib b/_bibliography/papers.bib index a3ed37574e8a..f6d8b6bc4505 100644 --- a/_bibliography/papers.bib +++ b/_bibliography/papers.bib @@ -3,6 +3,14 @@ @string{aps = {American Physical Society,}} +@book{einstein1920relativity, + title={Relativity: the Special and General Theory}, + author={Einstein, Albert}, + year={1920}, + publisher={Methuen & Co Ltd}, + html={relativity.html} +} + @book{einstein1956investigations, bibtex_show={true}, title={Investigations on the Theory of the Brownian Movement}, diff --git a/_layouts/bib.liquid b/_layouts/bib.liquid index 5f6218e35948..aca79fbeb86d 100644 --- a/_layouts/bib.liquid +++ b/_layouts/bib.liquid @@ -166,7 +166,11 @@ Bib {% endif %} {% if entry.html %} - HTML + {% if entry.html contains '://' %} + HTML + {% else %} + HTML + {% endif %} {% endif %} {% if entry.pdf %} {% if entry.pdf contains '://' %} diff --git a/assets/html/relativity.html b/assets/html/relativity.html new file mode 100644 index 000000000000..7d3472acc569 --- /dev/null +++ b/assets/html/relativity.html @@ -0,0 +1,10 @@ + + +
+

Relativity: the Special and General Theory

+
Albert Einstein
+
+ Insert HTML document here. +
+ +