diff options
| author | 2021-09-13 14:45:33 +0200 | |
|---|---|---|
| committer | 2021-09-13 14:45:33 +0200 | |
| commit | 026674bc2c4eb5f53bcb38e7efce2fe2dfebe974 (patch) | |
| tree | aeb8d5a884379b86597bc530f0375fc5dbe5357d /web/template/status.tmpl | |
| parent | update my personal library versions (#220) (diff) | |
| download | gotosocial-026674bc2c4eb5f53bcb38e7efce2fe2dfebe974.tar.xz | |
Thread views on the web (#207)
* Webviews for status threads
* fix up templates
* add ForkAwesome and gotosocial-styling into repo
* clean up gotosocial-styling, old styling
* update CONTRIBUTING with new css building, and nodemon recommendation
* update Dockerfile with new css bundling
* those weren't supposed to make it in
* upgrade gotosocial-styling deps
* update authorize template with main wrapper
* update css pipeline
* abstract status from thread to avoid copy-pasting
* basic CW implementation
* fix PR review suggestions
* fix no-image-desc icon alignment
* remove template loading println
* remove println
* remove changes to testmodels
* reset changes to testmodels
Diffstat (limited to 'web/template/status.tmpl')
| -rw-r--r-- | web/template/status.tmpl | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/web/template/status.tmpl b/web/template/status.tmpl new file mode 100644 index 000000000..343eb2d0a --- /dev/null +++ b/web/template/status.tmpl @@ -0,0 +1,36 @@ +<a href="{{.Account.URL}}" class="avatar"><img src="{{.Account.Avatar}}"></a> +<a href="{{.Account.URL}}" class="displayname">{{if .Account.DisplayName}}{{.Account.DisplayName}}{{else}}{{.Account.Username}}{{end}}</a> +<a href="{{.Account.URL}}" class="username">@{{.Account.Username}}</a> +<div class="text"> + {{if .SpoilerText}} + <input class="spoiler" id="hideSpoiler-{{.ID}}" type="checkbox" style="display: none" aria-hidden="true" checked="true" /> + <div class="spoiler"> + <span>{{.SpoilerText}}</span><label class="spoiler-label" for="hideSpoiler-{{.ID}}">Toggle visibility</label> + </div> + {{end}} + <div class="content"> + {{.Content |noescape}} + </div> +</div> +{{with .MediaAttachments}} + <div class="media {{(len .) | oddOrEven }}{{if eq (len .) 1}} single{{end}}{{if eq (len .) 2}} double{{end}}"> + {{range .}} + <a href="{{.URL}}" target="_blank" title="{{.Description}}"> + {{if not .Description}} + <div class="no-image-desc" aria-hidden="true" ><i class="fa fa-info-circle"></i><span>Missing image description</span></div> + {{end}} + <img src="{{.PreviewURL}}" alt="{{.Description}}"/> + </a> + {{end}} + </div> +{{end}} +<div class="info"> + <div id="date">{{.CreatedAt | timestamp}}</div> + <div class="stats"> + <div id="visibility">{{.Visibility | visibilityIcon}}</div> + <div id="replies"><i aria-label="Replies" class="fa fa-reply-all"></i> {{.RepliesCount}}</div> + <div id="boosts"><i aria-label="Boosts" class="fa fa-retweet"></i> {{.ReblogsCount}}</div> + <div id="favorites"><i aria-label="Favorites" class="fa fa-star"></i> {{.FavouritesCount}}</div> + </div> +</div> +<a href="{{.URL}}" class="toot-link">View toot</a>
\ No newline at end of file |
