Skip to content

nocase nesting #104

@retorquere

Description

@retorquere

With this script:

const BibLatexParser = require('biblatex-csl-converter').BibLatexParser

const input = `
@article{Adams2001,
  title = {{The \\emph{physical} volcanology of the 1600 eruption of Huaynaputina, southern Peru}},
}
`

let parser = new BibLatexParser(input, {
    processUnexpected: true,
    processUnknown: { comment: 'f_verbatim' },
    processInvalidURIs: true,
});

let bib = parser.parse()
console.log(JSON.stringify(bib.entries['1'].fields.title, null, 2))

I'm getting

[
  {
    "type": "text",
    "text": "The ",
    "marks": [
      {
        "type": "nocase"
      }
    ]
  },
  {
    "type": "text",
    "text": "physical",
    "marks": [
      {
        "type": "em"
      }
    ]
  },
  {
    "type": "text",
    "text": " volcanology of the 1600 eruption of Huaynaputina, southern Peru"
  }
]

which leaves the part after the emph section unprotected. This isn't expected right?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions