Улучшение парсинга описания/комментариев в формате JSON

This commit is contained in:
lost+skunk 2024-07-09 17:24:56 +03:00
parent 0f528ee9fa
commit 8391cc34a9
3 changed files with 68 additions and 40 deletions

View file

@ -3,6 +3,7 @@
<head>
<title>SkunkyArt | {{.Templates.Deviation.Post.Deviation.Author.Username}} - {{.Templates.Deviation.Post.Deviation.Title}}</title>
<link rel="stylesheet" href="{{.BasePath}}gui/css/skunky.css">
<meta name="referrer" content="no-referrer" />
</head>
<main>
<header>
@ -33,10 +34,15 @@
{{if (ne .Templates.Deviation.Tags "")}}
{{.Templates.Deviation.Tags}}<br>
{{end}}
<span>Published: <strong>{{.Templates.Deviation.StringTime}}</strong>; Views: <strong>{{.Templates.Deviation.Post.Deviation.Stats.Views}}</strong>; Favourites: <strong>{{.Templates.Deviation.Post.Deviation.Stats.Favourites}}</strong>; Downloads: <strong>{{.Templates.Deviation.Post.Deviation.Stats.Downloads}}</strong></span>
<span>Published: <strong>{{.Templates.Deviation.StringTime}}</strong>; Views: <strong>{{.Templates.Deviation.Post.Deviation.Stats.Views}}</strong>; Favourites: <strong>{{.Templates.Deviation.Post.Deviation.Stats.Favourites}}</strong>; Downloads: <strong>{{.Templates.Deviation.Post.Deviation.Stats.Downloads}}</strong><span>
<br><a target="_blank" href="https://www.deviantart.com/{{.Templates.Deviation.Post.Deviation.Author.Username}}/art/art-{{.Templates.Deviation.Post.Deviation.ID}}">Redirect to original</a>
</span>
{{if (ne .Templates.Deviation.Post.Description "")}}
<figcaption>
{{.Templates.Deviation.Post.Description}}
<details>
<summary>Description</summary>
{{.Templates.Deviation.Post.Description}}
</details>
</figcaption>
{{end}}
{{if ne .Templates.Deviation.Related ""}}