Skip to content

Commit

Permalink
Convert locator to HTML-like tagged string (fix #78)
Browse files Browse the repository at this point in the history
  • Loading branch information
zepinglee committed Oct 4, 2024
1 parent 7495855 commit 243f803
Show file tree
Hide file tree
Showing 5 changed files with 1,768 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Fixed

- The locator in citation is converted to HTML-like tagged string ([#78](https://github.com/zepinglee/citeproc-lua/issues/78)).

## [0.6.4] - 2024-09-15

### Fixed
Expand Down
5 changes: 5 additions & 0 deletions citeproc/citeproc-manager.lua
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,11 @@ function CslCitationManager:_make_citation(citation_info)

for i, item in ipairs(citation.citationItems) do
local citation_item = parse_latex_prop(item)

if citation_item.locator and type(citation_item.locator) == "string" then
citation_item.locator = latex_parser.latex_to_pseudo_html(citation_item.locator, true, false)
end

if citation_item.prefix then
-- util.debug(citation_item.prefix)
citation_item.prefix = latex_parser.latex_to_pseudo_html(citation_item.prefix, true, false)
Expand Down
Loading

0 comments on commit 243f803

Please sign in to comment.