Change const to var in utilities
In order to make these mappings also available when the script is used with `loadSubScript` from outside we have to use `var` instead of `const`, `let`. See https://github.com/aurimasv/z2csl/issues/6
This commit is contained in:
parent
954677636e
commit
f6da7bb8d4
1 changed files with 4 additions and 4 deletions
|
@ -31,7 +31,7 @@
|
||||||
* Note that this is the reverse of the text variable map, since all mappings should be one to one
|
* Note that this is the reverse of the text variable map, since all mappings should be one to one
|
||||||
* and it makes the code cleaner
|
* and it makes the code cleaner
|
||||||
*/
|
*/
|
||||||
const CSL_NAMES_MAPPINGS = {
|
var CSL_NAMES_MAPPINGS = {
|
||||||
"author":"author",
|
"author":"author",
|
||||||
"editor":"editor",
|
"editor":"editor",
|
||||||
"bookAuthor":"container-author",
|
"bookAuthor":"container-author",
|
||||||
|
@ -47,7 +47,7 @@ const CSL_NAMES_MAPPINGS = {
|
||||||
/*
|
/*
|
||||||
* Mappings for text variables
|
* Mappings for text variables
|
||||||
*/
|
*/
|
||||||
const CSL_TEXT_MAPPINGS = {
|
var CSL_TEXT_MAPPINGS = {
|
||||||
"title":["title"],
|
"title":["title"],
|
||||||
"container-title":["publicationTitle", "reporter", "code"], /* reporter and code should move to SQL mapping tables */
|
"container-title":["publicationTitle", "reporter", "code"], /* reporter and code should move to SQL mapping tables */
|
||||||
"collection-title":["seriesTitle", "series"],
|
"collection-title":["seriesTitle", "series"],
|
||||||
|
@ -91,7 +91,7 @@ const CSL_TEXT_MAPPINGS = {
|
||||||
/*
|
/*
|
||||||
* Mappings for dates
|
* Mappings for dates
|
||||||
*/
|
*/
|
||||||
const CSL_DATE_MAPPINGS = {
|
var CSL_DATE_MAPPINGS = {
|
||||||
"issued":"date",
|
"issued":"date",
|
||||||
"accessed":"accessDate",
|
"accessed":"accessDate",
|
||||||
"submitted":"filingDate"
|
"submitted":"filingDate"
|
||||||
|
@ -101,7 +101,7 @@ const CSL_DATE_MAPPINGS = {
|
||||||
* Mappings for types
|
* Mappings for types
|
||||||
* Also see itemFromCSLJSON
|
* Also see itemFromCSLJSON
|
||||||
*/
|
*/
|
||||||
const CSL_TYPE_MAPPINGS = {
|
var CSL_TYPE_MAPPINGS = {
|
||||||
'book':"book",
|
'book':"book",
|
||||||
'bookSection':'chapter',
|
'bookSection':'chapter',
|
||||||
'journalArticle':"article-journal",
|
'journalArticle':"article-journal",
|
||||||
|
|
Loading…
Reference in a new issue