Skip to content

EditionOpenAccess/eoa_makestatic

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 

Make static version

A wrapper for creating a static version using wget.

Problem

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">&#8220;Pergamon,&#8221;</a>

will be rewritten to

<a data-hilayer="Fig11pergamon" class="HILink" href="index.html#Fig11">&#8220;Pergamon,&#8221;</a>

which will de-activate the link.

Solution

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.

Releases

No releases published

Languages