This commit is contained in:
blankie 2022-10-08 17:56:56 +07:00
parent 7d8763b308
commit 940b6e01db
Signed by: blankie
GPG key ID: CC15FC822C7F61F5

View file

@ -38,7 +38,6 @@
(define raw-image-url (jp "/rawImageUrl" media-detail)) (define raw-image-url (jp "/rawImageUrl" media-detail))
(define image-url (jp "/imageUrl" media-detail raw-image-url)) (define image-url (jp "/imageUrl" media-detail raw-image-url))
(define username (jp "/userName" media-detail)) (define username (jp "/userName" media-detail))
(define user-page-url (jp "/userPageUrl" media-detail))
(define is-posted-in (jp "/isPostedIn" media-detail #f)) (define is-posted-in (jp "/isPostedIn" media-detail #f))
(define smaller-article-list (jp "/smallerArticleList" media-detail)) (define smaller-article-list (jp "/smallerArticleList" media-detail))
(define article-list-is-smaller (jp "/articleListIsSmaller" media-detail)) (define article-list-is-smaller (jp "/articleListIsSmaller" media-detail))
@ -54,7 +53,7 @@
`"" `""
`(span (a (@ (href ,(u-proxy-url raw-image-url))) "View original file") ". ")) `(span (a (@ (href ,(u-proxy-url raw-image-url))) "View original file") ". "))
"Added by " "Added by "
(a (@ (href ,(u-proxy-url user-page-url))) ,username) (a (@ (href ,(format "/~a/wiki/User:~a" wikiname username))) ,username)
"." "."
,(if is-posted-in ,(if is-posted-in
`(span " Posted in " `(span " Posted in "
@ -63,15 +62,16 @@
(define page-path (jp "/title" article)) (define page-path (jp "/title" article))
(define title (jp "/titleText" article page-path)) (define title (jp "/titleText" article page-path))
`(span `(span
(a (@ (href ,(format "/~a/wiki/~a" wikiname page-path))) ,(if (eq? (car smaller-article-list) article)
,title)
`(if (eq? (car smaller-article-list) article))
"" ""
", ")) ", ")
smaller-article-list)) (a (@ (href ,(format "/~a/wiki/~a" wikiname page-path)))
`(if (eq? article-list-is-smaller 1) ,title)))
smaller-article-list)
,(if (eq? article-list-is-smaller 1)
"" ""
".")))) "."))
`"")))
; ,(update-tree-wiki image-description wikiname) ; ,(update-tree-wiki image-description wikiname)
)) ))