aboutsummaryrefslogtreecommitdiff
path: root/test/command/chap1
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2021-05-24 10:17:37 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2021-05-27 10:38:25 -0700
commit834da53058069fe50da510fa86e0807a7ff7868f (patch)
tree791cdc1a5a2e459efac2b68a97285e2a5e737b70 /test/command/chap1
parent0226d2320f5a57475ec260b9d0ad3ad4260ecf38 (diff)
downloadpandoc-834da53058069fe50da510fa86e0807a7ff7868f.tar.gz
Add `rebase_relative_paths` extension.
- Add manual entry for (non-default) extension `rebase_relative_paths`. - Add constructor `Ext_rebase_relative_paths` to `Extensions` in Text.Pandoc.Extensions [API change]. When enabled, this extension rewrites relative image and link paths by prepending the (relative) directory of the containing file. - Make Markdown reader sensitive to the new extension. - Add tests for #3752. Closes #3752. NB. currently the extension applies to markdown and associated readers but not commonmark/gfm.
Diffstat (limited to 'test/command/chap1')
-rw-r--r--test/command/chap1/spider.pngbin0 -> 63531 bytes
-rw-r--r--test/command/chap1/text.md11
2 files changed, 11 insertions, 0 deletions
diff --git a/test/command/chap1/spider.png b/test/command/chap1/spider.png
new file mode 100644
index 000000000..7ee9fe339
--- /dev/null
+++ b/test/command/chap1/spider.png
Binary files differ
diff --git a/test/command/chap1/text.md b/test/command/chap1/text.md
new file mode 100644
index 000000000..88b30313d
--- /dev/null
+++ b/test/command/chap1/text.md
@@ -0,0 +1,11 @@
+# Chapter one
+
+A spider: ![spider](spider.png)
+
+The moon: ![moon](../../lalune.jpg)
+
+Link to [spider picture](spider.png).
+
+URL left alone: [manual](https://pandoc.org/MANUAL.html).
+
+Absolute path left alone: [absolute](/foo/bar/baz.png).