aboutsummaryrefslogtreecommitdiff
path: root/test/command
AgeCommit message (Collapse)Author
2020-10-10LaTeX reader: allow blank lines inside `\author`.John MacFarlane
2020-10-08LaTeX reader: Fix parsing of "show name" in newtheorem.John MacFarlane
Previously we were just treating it as a string and ignoring accents and formatting. See #6734.
2020-10-08Extend fix to #6719 to JATS readerJohn MacFarlane
2020-10-08DocBook reader: don't squelch space at end of emphasis element.John MacFarlane
Instead, include it after the emphasis. Closes #6719. Same fix was made for other inline elements, e.g. strikethrough.
2020-10-08Fixed some bibtex comments in tests (closing }).John MacFarlane
2020-10-08Be less aggressive about using quotes for YAML values.John MacFarlane
We need quotes if `[` or `{` or `'` is at the beginning of the line, but not otherwise.
2020-10-07Use double quotes for YAML metadata.John MacFarlane
Closes #6727.
2020-10-07Fix URL prefixes in citations also when they occur in notes.John MacFarlane
Update chicago-fullnote-bibliography.csl and adjust tests. Closes #6723.
2020-10-06Unescape entities in writing CSL JSON.John MacFarlane
The renderCslJson function escapes `<`, `>`, and `&` as entities. This is appropriate when generating HTML, but in CSL JSON these are supposed to appear unescaped. Closes jgm/citeproc#17.
2020-10-03Use latest citeproc.John MacFarlane
Update chicago-fullnute-bibliography test, which is now correct.
2020-10-01Update to lastest citeprocJohn MacFarlane
2020-09-27OpenDocument Writer: Implement table cell alignment (#6700)Nils Carlson
Co-authored-by: Mauro Bieg <[email protected]>
2020-09-26Fix short-title.John MacFarlane
We were getting null short-titles generated, and that was creating wrong citations in some cases. Close #6702.
2020-09-25RST reader: apply `.. class::` directly to following Header.John MacFarlane
rather than creating a surrounding Div. Closes #6699.
2020-09-24DocBook reader: Implement table cell alignment (#6698)Nils Carlson
2020-09-24Citeproc: Insert space after csl-left-margin span contents...John MacFarlane
if they come before csl-right-inline. This ensures that the citation number or label will be separated from the rest by a space, even in formats (like plain) that don't yet have special handling for the display spans.
2020-09-24OpenDocument writer: New table cell support with row and column spans (#6682)Nils Carlson
Unit tests only verify column spans at this point. Co-authored-by: Nils Carlson <[email protected]>
2020-09-21Add built-in citation support using new citeproc library.John MacFarlane
This deprecates the use of the external pandoc-citeproc filter; citation processing is now built in to pandoc. * Add dependency on citeproc library. * Add Text.Pandoc.Citeproc module (and some associated unexported modules under Text.Pandoc.Citeproc). Exports `processCitations`. [API change] * Add data files needed for Text.Pandoc.Citeproc: default.csl in the data directory, and a citeproc directory that is just used at compile-time. Note that we've added file-embed as a mandatory rather than a conditional depedency, because of the biblatex localization files. We might eventually want to use readDataFile for this, but it would take some code reorganization. * Text.Pandoc.Loging: Add `CiteprocWarning` to `LogMessage` and use it in `processCitations`. [API change] * Add tests from the pandoc-citeproc package as command tests (including some tests pandoc-citeproc did not pass). * Remove instructions for building pandoc-citeproc from CI and release binary build instructions. We will no longer distribute pandoc-citeproc. * Markdown reader: tweak abbreviation support. Don't insert a nonbreaking space after a potential abbreviation if it comes right before a note or citation. This messes up several things, including citeproc's moving of note citations. * Add `csljson` as and input and output format. This allows pandoc to convert between `csljson` and other bibliography formats, and to generate formatted versions of CSL JSON bibliographies. * Add module Text.Pandoc.Writers.CslJson, exporting `writeCslJson`. [API change] * Add module Text.Pandoc.Readers.CslJson, exporting `readCslJson`. [API change] * Added `bibtex`, `biblatex` as input formats. This allows pandoc to convert between BibLaTeX and BibTeX and other bibliography formats, and to generated formatted versions of BibTeX/BibLaTeX bibliographies. * Add module Text.Pandoc.Readers.BibTeX, exporting `readBibTeX` and `readBibLaTeX`. [API change] * Make "standalone" implicit if output format is a bibliography format. This is needed because pandoc readers for bibliography formats put the bibliographic information in the `references` field of metadata; and unless standalone is specified, metadata gets ignored. (TODO: This needs improvement. We should trigger standalone for the reader when the input format is bibliographic, and for the writer when the output format is markdown.) * Carry over `citationNoteNum` to `citationNoteNumber`. This was just ignored in pandoc-citeproc. * Text.Pandoc.Filter: Add `CiteprocFilter` constructor to Filter. [API change] This runs the processCitations transformation. We need to treat it like a filter so it can be placed in the sequence of filter runs (after some, before others). In FromYAML, this is parsed from `citeproc` or `{type: citeproc}`, so this special filter may be specified either way in a defaults file (or by `citeproc: true`, though this gives no control of positioning relative to other filters). TODO: we need to add something to the manual section on defaults files for this. * Add deprecation warning if `upandoc-citeproc` filter is used. * Add `--citeproc/-C` option to trigger citation processing. This behaves like a filter and will be positioned relative to filters as they appear on the command line. * Rewrote the manual on citatations, adding a dedicated Citations section which also includes some information formerly found in the pandoc-citeproc man page. * Look for CSL styles in the `csl` subdirectory of the pandoc user data directory. This changes the old pandoc-citeproc behavior, which looked in `~/.csl`. Users can simply symlink `~/.csl` to the `csl` subdirectory of their pandoc user data directory if they want the old behavior. * Add support for CSL bibliography entry formatting to LaTeX, HTML, Ms writers. Added CSL-related CSS to styles.html.
2020-09-21Markdown reader: Set citationNoteNum accurately in citations.John MacFarlane
This also changes stateLastNoteNumber -> stateNoteNumber.
2020-09-15LaTeX writer: fix spacing issue with list in definition list.John MacFarlane
When a list occurs at the beginning of a definition list definition, it can start on the same line as the label, which looks bad. Fix that by starting such lists with an `\item[]`.
2020-09-10Changed default link state to invisible (#6676)Leonard Rosenthol
2020-09-10Improved uncertainty handling in slunitx.John MacFarlane
2020-09-10LaTeX reader: support parenthesized uncertainties in siunitx.John MacFarlane
2020-09-10Implement support for internal document links in ICML (#6606)Leonard Rosenthol
Closes #5541.
2020-09-10docbook reader: Implement column span support for tables (#6492)Nils Carlson
Implement column span support for tables in the DocBook reader. Co-authored-by: Nils Carlson <[email protected]>
2020-09-02LaTeX reader: Support squared, cubed, tothe in siunitx.John MacFarlane
Closes #6657.
2020-08-31Fix tests for skylighting 0.10Albert Krewinkel
2020-08-14Change SIRange to SIrange (#6617)Emerson Harkin
2020-07-23Minimal support for SIRange in LaTeX reader (#6418)Emerson Harkin
Add support for `\SIRange{firstnumber}{secondnumber}{unit}` provided by siunitx. An en-dash is used instead of localized "to".
2020-07-23Further improvements to ams theorem support, and a test.John MacFarlane
See #1608.
2020-07-21RST reader: fix csv tables with multiline cells.John MacFarlane
Closes #6549.
2020-07-19Remove use of cmark-gfm for commonmark/gfm rendering.John MacFarlane
Instead rely on the markdown writer with appropriate extensions. Export writeCommonMark variant from Markdown writer. This changes a few small things in rendering markdown, e.g. w/r/t requiring backslashes before spaces inside super/subscripts.
2020-07-01HTML writer: improve alt-text/caption handling for HTML5Albert Krewinkel
Screen readers read an image's `alt` attribute and the figure caption, both of which come from the same source in pandoc. The figure caption is hidden from screen readers with the `aria-hidden` attribute. This improves accessibility. For HTML4, where `aria-hidden` is not allowed, pandoc still uses an empty `alt` attribute to avoid duplicate contents. Closes: #6491
2020-06-23LaTeX reader: Retain the Div around tables with attributes.John MacFarlane
We'll need this to store table attributes until all writers are adjusted to react to attributes on the Table element.
2020-06-23Add test for #6481.John MacFarlane
2020-05-20Add "summary" to list of block-level HTML tags.John MacFarlane
Closes #6385. (The summary element needs to be the first child of details and should not be enclosed by p tags.) NOTE: you need to include a blank line before the closing `</details>`, if you want the last part of the content to be parsed as a paragraph.
2020-05-18Use CSS in favor of <br> for display math (#6372)Lila
Some CSS to ensure that display math is displayed centered and on a new line is now included in the default HTML-based templates; this may be overridden if the user wants a different behavior.
2020-05-12LaTeX writer: create hypertarget for links with identifier.John MacFarlane
Closes #6360.
2020-05-12Use latest skylighting.John MacFarlane
This adds `aria-hidden="true"` to the empty a elements, which helps people who use screen readers.
2020-05-02LaTeX Writer: Add support for customizable alignment of columns in beamer ↵andrebauer
(#6331) Add support for customizable alignment of columns in beamer. Closes #4805, closes #4150.
2020-04-24RST writer: properly handle images with same alt text.John MacFarlane
Previously we created duplicate references for these in rendering RST. Closes #6194.
2020-04-22AsciiDoc writer: add blank line after Div.John MacFarlane
Closes #6308.
2020-04-17Markdown writer: avoid unnecessary escapes before intraword `_`John MacFarlane
when `intraword_underscores` extension is enabled. Closes #6296.
2020-04-17LaTeX reader: don't put surrounding Div around Table.John MacFarlane
This reverts a change in the last release; the Div is no longer needed, because we can now put the id right in the Table's attributes. However, writers may still need to be modified to do something with the id in a Table (e.g. create an anchor), so in the short term we may lose the ability to link to tables in some writers.
2020-04-15Use the new builders, modify readers to preserve empty headersdespresc
The Builder.simpleTable now only adds a row to the TableHead when the given header row is not null. This uncovered an inconsistency in the readers: some would unconditionally emit a header filled with empty cells, even if the header was not present. Now every reader has the conditional behaviour. Only the XWiki writer depended on the header row being always present; it now pads its head as necessary.
2020-04-15Adapt to the removal of the RowSpan, ColSpan, RowHeadColumns accessorsdespresc
2020-04-15Adapt to the newest Table type, fix some previous adaptation issuesdespresc
- Writers.Native is now adapted to the new Table type. - Inline captions should now be conditionally wrapped in a Plain, not a Para block. - The toLegacyTable function now lives in Writers.Shared.
2020-04-15Implement the new Table typedespresc
2020-04-15JATS reader: handle "label" element in section title.John MacFarlane
Closes #6288.
2020-04-11LaTeX writer: ensure that `-M csquotes` works even in fragment mode.John MacFarlane
Closes #6265.