diff --git a/NEWS.md b/NEWS.md index b4373bec8..923333435 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,6 +1,7 @@ rticles 0.20 --------------------------------------------------------------------- +- fix an issue with `rjournal_article()` template to insert newline in author's block only if a field exist (thanks, @huizezhang-sherry, #387) rticles 0.19 --------------------------------------------------------------------- diff --git a/inst/rmarkdown/templates/rjournal/resources/template.tex b/inst/rmarkdown/templates/rjournal/resources/template.tex index 1267c918b..49e42eb0a 100644 --- a/inst/rmarkdown/templates/rjournal/resources/template.tex +++ b/inst/rmarkdown/templates/rjournal/resources/template.tex @@ -25,9 +25,9 @@ $author.affiliation2$\\% $for(author.address2)$$author.address2$$sep$\\ $endfor$\\ $endif$% -$if(author.url)$$author.url$$endif$% -$if(author.orcid)$\\\textit{ORCiD: \href{https://orcid.org/$author.orcid$}{$author.orcid$}}$endif$% -$if(author.email)$\\$author.email$$endif$ +$if(author.url)$$author.url$\\$endif$% +$if(author.orcid)$\textit{ORCiD: \href{https://orcid.org/$author.orcid$}{$author.orcid$}}\\$endif$% +$if(author.email)$$author.email$$endif$% } $endfor$