Skip to content

Instantly share code, notes, and snippets.

@NateWr
Created September 21, 2020 10:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NateWr/fd51949fd3998d2307b9d0732c95136c to your computer and use it in GitHub Desktop.
Save NateWr/fd51949fd3998d2307b9d0732c95136c to your computer and use it in GitHub Desktop.
JATS tags that a web-based editor deployed with PKP applications should support.

JATS Editor Tag Support

This document describes the JATS tags that should be supported by a web-based editor in PKP applications. This is a limited set of JATS tags that PKP considers valuable for writing and publishing full-text articles online using OJS.

The tags described here are those that are necessary for generating the full text of an article. It does not include tags related to frontmatter or backmatter that are not used in the article body, and which can be generated from OJS's existing metadata features.

MVP

The following tags are necessary for most of our community to be able to use the editor. The goal is to achieve parity with something like a regular HTML rich-text editor, such as TinyMCE, by supporting text, tables and images.

Tag Definition
inline The following inline elements: bold, italic, sup, sub, ext-link, xref
sec A section in an article. A sec should always include a <title> and these should map to the <h*> HTML tags, so that sec tags may not be nested more than 6 deep.
p A text paragraph.
list List of ordered or unordered items. Must support nested lists.
fig Graphic or text identified as a figure, usually bearing a caption and a label such as "Figure 3" or "Figure". Uses <label>, <caption> and <graphic>. See example below.
disp-quote Extract or extended quoted passage from another work. Uses <p> and <attrib>.
table-wrap Wrapper element for a complete table. Uses <label>, <caption> and <table>. Content in <td> and <th> elements should always be wrapped in a <p> for consistency. See example below.

<fig> example

An example of the <fig> markup that the editor should produce.

<fig id="fig1">
	<label>Figure 1</label>
	<caption>
		<title>Figure title.</title>
		<p>More detailed explanation of the figure. Can include link to the reference and formatted text as usual paragraph.</p>
	</caption>
	<graphic xlink:href="fig1.jpg"/>
</fig>

<table-wrap> example

An example of the <table-wrap> markup that the editor should produce.

<table-wrap id="tbl1">
	<label>Table 2</label>
	<caption>
		<title>Table title</title>
		<p>More detailed explanation of the table. Can include link to the reference and formatted text as usual paragraph.</p>
	</caption>
	<table>
		<thead>
			<tr>
				<th>
					<p>Name</p>
				</th>
				<th>
					<p>Value</p>
				</th>
			</tr>
		<thead>
		<tbody>
			<tr>
				<td>
					<p>Sample 1</p>
				</td>
				<td>
					<p>21.34</p>
				</td>
			</tr>
		<tbody>
	</table>
</table-wrap>

Citations

Although citations are stored as backmatter, the web-based editor must be able to link to existing references, and create, edit and delete references from within the editor.

Required

The following tags are necessary for some of our community to use the editor. Portions of our community may not be able to adopt it until these tags are supported.

Tag Definition
code A container element for technical content such as programming language code, pseudo-code, schemas, or a markup fragment.
disp-formula Mathematical equation, expression, or formula that is to be displayed as a block (callout) within the narrative flow.
disp-formula-group Container element for equations or other mathematical expressions.
fig-group Container element for figures that are to be displayed together.
preformat Text in which spaces, tabs, and line feeds must be preserved. Content is typically displayed in monofont to preserve character alignment.
tex-math Used to hold encoded math, expressed in TeX or LaTeX.
chem-struct-wrap Wrapper element for a chemical expression, reaction, equation, etc. that is set apart from the text; includes any number, label, or caption that accompanies the chemical expression.
media Description of and pointer to an external file that holds a media object (for example, an animation, a movie).
table-wrap-group Container element for tables ( elements) that are to be displayed together.

Nice to have

Support for the following tags would be nice to have but we believe most of our community can use the editor without them.

Tag Definition
ack Textual material that names the parties who the author wishes to thank or recognize for their assistance in/contributions toward the article, for example, producing the work, funding the work, inspiring the work, or assisting in the research on which the work is based.
def-list List in which each item consists of two parts: 1) a word, phrase, term, graphic,chemical structure, or equation, that is paired with 2) one or more descriptions, discussions, explanations, or definitions of it.
inline-graphic A graphic that is inline with the text, often used to render unusual characters.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment