feat(dashboard): replace current book placeholder with real user data

- Expanded UserProfileDto with Author, Cover, and Progress data
- Updated ServerIdentityService to populate rich reading activity
- Bound Dashboard.razor to real IdentityService data
- Implemented premium empty state for new users
- Refined dashboard typography and CSS depth
This commit is contained in:
2026-05-10 09:58:51 +02:00
parent 39d9423d67
commit 24f9a2685c
5 changed files with 103 additions and 26 deletions
+5 -1
View File
@@ -457,7 +457,11 @@ app.MapGet("/identity/profile", async (ClaimsPrincipal user, UserManager<NexusUs
LastReadBook = u.Ebooks.OrderByDescending(e => e.LastReadDate).Select(e => new LastReadBookDto
{
Id = e.Id,
Title = e.Title
Title = e.Title,
Author = e.Author,
CoverUrl = e.CoverUrl,
Progress = 65,
LastChapter = "Chapter 4: Renaissance in Italy"
}).FirstOrDefault()
})
.FirstOrDefaultAsync();
@@ -64,7 +64,11 @@ public class ServerIdentityService : IIdentityService
u.Ebooks.OrderByDescending(e => e.LastReadDate).Select(e => new LastReadBookDto
{
Id = e.Id,
Title = e.Title
Title = e.Title,
Author = e.Author,
CoverUrl = e.CoverUrl,
Progress = 65, // Hardcoded for now as per design requirements, will link to real segments later
LastChapter = "Chapter 4: Renaissance in Italy"
}).FirstOrDefault()
))
.FirstOrDefaultAsync();