A wrapper for creating a static version using wget
.
The wrapper is necessary because of the insertion of Hyperimage and the way it handles links.
Firstly, versioned file references such as
<link rel="stylesheet" href="../../../static/HI-Viewer/lib/fontawesome/web-fonts-with-css/css/fa-regular.min.css?v=1.0.css">
are escaped by wget
:
<link rel="stylesheet" href="../../../static/HI-Viewer/lib/fontawesome/web-fonts-with-css/css/fa-regular.min.css%3Fv=1.0.css">
Secondly, a link like
<a data-hilayer="Fig11pergamon" class="HILink" href="#Fig11">“Pergamon,”</a>
will be rewritten to
<a data-hilayer="Fig11pergamon" class="HILink" href="index.html#Fig11">“Pergamon,”</a>
which will de-activate the link.
A config file contains the chapters that require these modifications. The necessary replacements will only be made in these files.
To add another publication, open the ms.json
file and add another configuration snippet containing series
(lowercase), number
and an array of chapters
(or rather the URL parts that make up the chapters).
Example: Photo-Objects contains 8 chapters with Hyperimage. The last one being chapter 17. Chapter 1 in the online edition is the list of contributors, so every chapter number has to be increased by 1.