Show description above image in the web interface
This commit is contained in:
parent
d63292b8fa
commit
7901e4aa40
|
@ -268,13 +268,14 @@ class BServer:
|
||||||
""")
|
""")
|
||||||
no_img_msg = _('There is no image yet. Please donate an image of your project on <a href="https://github.com/florianfesti/boxes/issues/140">GitHub</a>!')
|
no_img_msg = _('There is no image yet. Please donate an image of your project on <a href="https://github.com/florianfesti/boxes/issues/140">GitHub</a>!')
|
||||||
|
|
||||||
|
if box.description:
|
||||||
|
result.append(markdown.markdown(_(box.description)))
|
||||||
|
|
||||||
result.append(f'''<div>
|
result.append(f'''<div>
|
||||||
<img src="static/samples/{box.__class__.__name__}.jpg" width="100%" onerror="this.parentElement.innerHTML = '{no_img_msg}';"/>
|
<img src="static/samples/{box.__class__.__name__}.jpg" width="100%" onerror="this.parentElement.innerHTML = '{no_img_msg}';"/>
|
||||||
</div>
|
</div>
|
||||||
''')
|
''')
|
||||||
|
|
||||||
if box.description:
|
|
||||||
result.append(markdown.markdown(_(box.description)))
|
|
||||||
result.append("""
|
result.append("""
|
||||||
</div>
|
</div>
|
||||||
""" + self.footer(lang) + """</body>
|
""" + self.footer(lang) + """</body>
|
||||||
|
|
Loading…
Reference in New Issue