Skip to content

Instantly share code, notes, and snippets.

@michael
Created May 26, 2015 13:35
Show Gist options
  • Save michael/343bb3696bfca2c3341b to your computer and use it in GitHub Desktop.
Save michael/343bb3696bfca2c3341b to your computer and use it in GitHub Desktop.
Tahi Data Spec
<html>
<head>
<!-- no title annotations possible with meta tags so moved into html body -->
<!-- no abstract annotations possible with meta tags so moved into html body -->
<meta name="doi" content="10.1234/myJournal.00001"/>
<meta name="status" content="in-review"/>
<meta name="creator" content="userx"/>
<meta name="created-at" content="2015-05-12T08:20:19.657Z"/>
<meta name="updated-at" content="2015-05-13T04:18:42.657Z"/>
</head>
<body>
<div data-type="meta">
<div data-type="title" id="title">The Tahi Article Format</div>
<div data-type="abstract" id="abstract">Article abstract that can be <strong>annotated</strong></div>
</div>
<div data-type="body">
<h2 id="h1">A heading</h2>
<p id="p1">
Some <em>annotated</em> content (<span data-type="ref" data-ref-type="bib" data-rid="bib1">Doe, 2010</span>).
</p>
<!-- external content is included by referencing the external id -->
<div data-type="include" data-include-type="fig" data-rid="fig1"/>
</div>
<!-- Resources have external ownership and are extracted from the DB. That means the
resources element is empty in the source file and gets populated on the fly (e.g. each
time when a doc is opened in the editor). That way we avoid storing content redundantly -->
<div data-type="resources">
<div data-type="fig" id="fig1">
<div data-type="doi">10.1234/myJournal.00001.001</div>
<div data-type="label">Figure 1.</div>
<div data-type="title">Figure title</div>
<div data-type="caption">
<em>Annotated</em> Figure caption
</div>
<!-- I did not choose the img tag here because the source format should only has an image
identifier, not the fully qualified url, so we can change where images are hosted without touching the source files -->
<div data-type="image" data-image-name="fig1_image_a"/>
</div>
<div data-type="bib" id="bib1">
<div data-type="contributors">
<div data-type="author" id="author1">
<div data-type="surname">Doe</div>
<div data-type="given-names">John</div>
</div>
</div>
<div data-type="year">2010</div>
<div data-type="title">Article <em>X</em></div>
<div data-type="source">Journal Y</div>
<div data-type="volume">1</div>
<div data-type="fpage">40</div>
<div data-type="lpage">45</div>
<div data-type="doi">10.1234/myJournal.00005</div>
</div>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment