diff --git a/src/main/java/org/operaton/fitpub/controller/ProfileViewController.java b/src/main/java/org/operaton/fitpub/controller/ProfileViewController.java index e8c3f93..0d376c5 100644 --- a/src/main/java/org/operaton/fitpub/controller/ProfileViewController.java +++ b/src/main/java/org/operaton/fitpub/controller/ProfileViewController.java @@ -64,4 +64,34 @@ public class ProfileViewController { model.addAttribute("username", username); return "profile/public"; } + + /** + * User followers page. + * Shows list of people who follow this user. + * + * @param username the username + * @param model the model + * @return followers template + */ + @GetMapping("/profile/{username}/followers") + public String userFollowers(@PathVariable String username, Model model) { + model.addAttribute("pageTitle", "Followers - @" + username); + model.addAttribute("username", username); + return "profile/followers"; + } + + /** + * User following page. + * Shows list of people this user follows. + * + * @param username the username + * @param model the model + * @return following template + */ + @GetMapping("/profile/{username}/following") + public String userFollowing(@PathVariable String username, Model model) { + model.addAttribute("pageTitle", "Following - @" + username); + model.addAttribute("username", username); + return "profile/following"; + } } diff --git a/src/main/resources/static/css/fitpub.css b/src/main/resources/static/css/fitpub.css index 20c557c..29c0792 100644 --- a/src/main/resources/static/css/fitpub.css +++ b/src/main/resources/static/css/fitpub.css @@ -199,6 +199,17 @@ body { padding: 1rem; } +.stat-card-hover { + transition: background-color 0.2s, transform 0.2s; + cursor: pointer; + border-radius: var(--border-radius); +} + +.stat-card-hover:hover { + background-color: var(--light-color); + transform: translateY(-2px); +} + .stat-value { font-size: 2rem; font-weight: 700; diff --git a/src/main/resources/templates/profile/followers.html b/src/main/resources/templates/profile/followers.html new file mode 100644 index 0000000..4188cd0 --- /dev/null +++ b/src/main/resources/templates/profile/followers.html @@ -0,0 +1,139 @@ + + + +
+Loading followers...
+People who follow @
+No followers yet
+Loading following...
+People that @ follows
+Not following anyone yet
+