mirror of
https://gitdab.com/cadence/breezewiki.git
synced 2026-04-22 22:34:36 -04:00
Fix used in links that have a namespace in file pages
Example: /ben10/wiki/File:OS_Timespan.png https://github.com/Wikia/app/blob/fe60579a53f16816d65dad1644363160a63206a6/includes/Title.php#L1266
This commit is contained in:
+3
-4
@@ -31,8 +31,7 @@
|
|||||||
(rawImageUrl . "https://static.wikia.nocookie.net/examplefile")
|
(rawImageUrl . "https://static.wikia.nocookie.net/examplefile")
|
||||||
(userName . "blankie")
|
(userName . "blankie")
|
||||||
(isPostedIn . #t)
|
(isPostedIn . #t)
|
||||||
(smallerArticleList . (#hasheq((title . "Example_article")
|
(smallerArticleList . (#hasheq((titleText . "Test:Example article"))))
|
||||||
(titleText . "Example article"))))
|
|
||||||
(articleListIsSmaller . 0)
|
(articleListIsSmaller . 0)
|
||||||
(exists . #t)
|
(exists . #t)
|
||||||
(imageDescription . #f))))
|
(imageDescription . #f))))
|
||||||
@@ -89,8 +88,8 @@
|
|||||||
,(if is-posted-in
|
,(if is-posted-in
|
||||||
`(p "This file is used in "
|
`(p "This file is used in "
|
||||||
,@(map (λ (article)
|
,@(map (λ (article)
|
||||||
(define page-path (jp "/title" article))
|
(define title (jp "/titleText" article))
|
||||||
(define title (jp "/titleText" article page-path))
|
(define page-path (regexp-replace* #rx" " title "_"))
|
||||||
`(span ,(if (eq? (car smaller-article-list) article) "" ", ")
|
`(span ,(if (eq? (car smaller-article-list) article) "" ", ")
|
||||||
(a (@ (href ,(format "/~a/wiki/~a" wikiname page-path)))
|
(a (@ (href ,(format "/~a/wiki/~a" wikiname page-path)))
|
||||||
,title)))
|
,title)))
|
||||||
|
|||||||
Reference in New Issue
Block a user