Merge branch 'rootzlevel-master'
This commit is contained in:
commit
a241cf6a30
2 changed files with 5 additions and 1 deletions
|
@ -1093,7 +1093,7 @@ explicitOrImageLink = try $ do
|
|||
char ']'
|
||||
alt <- internalLink src title'
|
||||
return $
|
||||
(if isImageFilename src && isImageFilename title
|
||||
(if isImageFilename title
|
||||
then B.link src "" $ B.image title mempty mempty
|
||||
else fromMaybe alt (linkToInlines src title'))
|
||||
|
||||
|
|
|
@ -216,6 +216,10 @@ tests =
|
|||
"[[sunset.png][dusk.svg]]" =?>
|
||||
(para $ link "sunset.png" "" (image "dusk.svg" "" ""))
|
||||
|
||||
, "Image link with non-image target" =:
|
||||
"[[http://example.com][logo.png]]" =?>
|
||||
(para $ link "http://example.com" "" (image "logo.png" "" ""))
|
||||
|
||||
, "Plain link" =:
|
||||
"Posts on http://zeitlens.com/ can be funny at times." =?>
|
||||
(para $ spcSep [ "Posts", "on"
|
||||
|
|
Loading…
Add table
Reference in a new issue