From 1344c94807bca68ac6d0d23d48c9f3d1f7fef407 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micka=C3=ABl=20V=C3=A9ril?= Date: Sat, 2 Nov 2019 15:10:57 +0100 Subject: [PATCH] Rename class doi to DOI --- content/multipledataset.html | 6 +++--- content/singledataset.html | 2 +- static/js/data.js | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/content/multipledataset.html b/content/multipledataset.html index f239ccb7..11538020 100644 --- a/content/multipledataset.html +++ b/content/multipledataset.html @@ -125,12 +125,12 @@ draft: false key = JSON.parse(keystr) key.shift() Reflect.setPrototypeOf(key[0], method.prototype) - Reflect.setPrototypeOf(key[1], doi.prototype) + Reflect.setPrototypeOf(key[1], DOI.prototype) for (const el of key) { var td = $("", { style: "white-space: nowrap;" }) - if (trueTypeOf(el) == "doi") { + if (trueTypeOf(el) == "DOI") { var publi = await window.Cite.async(el.string) $("", { href: el.url, @@ -227,7 +227,7 @@ draft: false }) for (const el of tableels) { td=$(tdtemp).clone() - if (trueTypeOf(el) == "doi") { + if (trueTypeOf(el) == "DOI") { var publi = await window.Cite.async(el.string) $("", { href: el.url, diff --git a/content/singledataset.html b/content/singledataset.html index 616358a3..21e0ef9a 100644 --- a/content/singledataset.html +++ b/content/singledataset.html @@ -99,7 +99,7 @@ draft: false case "string": $("

").text(element).appendTo(sec) break; - case "doi": + case "DOI": var publi = await Cite.async(element.string) var output = publi.format('bibliography', { format: 'html', diff --git a/static/js/data.js b/static/js/data.js index 94b39ac1..ac429dce 100644 --- a/static/js/data.js +++ b/static/js/data.js @@ -57,7 +57,7 @@ class state { return tex; }; } -class doi { +class DOI { constructor(doistring) { this.string = doistring }; @@ -139,7 +139,7 @@ class dataFileBase { dat.method = method.fromString(value) break; case "doi": - dat.DOI = new doi(value); + dat.DOI = new DOI(value); break; default: }