From da22d19fb45b5504f4191ad06d4e7637bfbc3916 Mon Sep 17 00:00:00 2001 From: r Date: Sun, 27 Sep 2020 09:29:17 +0000 Subject: Add bookmarks - Add bookmark/unbookmark link on mouse hover - Add bookmarks section on user profile page --- templates/status.tmpl | 13 +++++++++++++ templates/user.tmpl | 17 +++++++++++++++++ 2 files changed, 30 insertions(+) (limited to 'templates') diff --git a/templates/status.tmpl b/templates/status.tmpl index 1e3d514..6c255a0 100644 --- a/templates/status.tmpl +++ b/templates/status.tmpl @@ -46,6 +46,19 @@ {{end}} + {{if .Bookmarked}} +
+ + + +
+ {{else}} +
+ + + +
+ {{end}} {{if eq $.Ctx.UserID .Account.ID}}
diff --git a/templates/user.tmpl b/templates/user.tmpl index cb21b8a..3bb7523 100644 --- a/templates/user.tmpl +++ b/templates/user.tmpl @@ -97,6 +97,11 @@ followers ({{.User.FollowersCount}}) - media + {{if .IsCurrent}} +
+ bookmarks +
+ {{end}}
search statuses
@@ -111,6 +116,8 @@
Statuses
{{range .Statuses}} {{template "status.tmpl" (WithContext . $.Ctx)}} +{{else}} +
No data found
{{end}} {{else if eq .Type "following"}} @@ -125,6 +132,16 @@
Statuses with media
{{range .Statuses}} {{template "status.tmpl" (WithContext . $.Ctx)}} +{{else}} +
No data found
+{{end}} + +{{else if eq .Type "bookmarks"}} +
Bookmarks
+{{range .Statuses}} +{{template "status.tmpl" (WithContext . $.Ctx)}} +{{else}} +
No data found
{{end}} {{end}} -- cgit v1.2.3