19 lines
785 B
Plaintext
19 lines
785 B
Plaintext
component Genre(genre string, animes []*arn.Anime, user *arn.User, userScore float64, userCompleted int)
|
|
h1(title=fmt.Sprint(len(animes)) + " anime")= strings.Title(genre)
|
|
|
|
GenreStatistics(user, userScore, userCompleted)
|
|
|
|
.corner-buttons-hide-on-mobile
|
|
if user != nil
|
|
button.action(data-trigger="click", data-action="toggleHideAddedAnime", title="Hide anime in my collection")
|
|
RawIcon("eye-slash")
|
|
|
|
a.button(href="/genres", title="View genres")
|
|
RawIcon("clone")
|
|
|
|
AnimeGrid(animes, user)
|
|
|
|
component GenreStatistics(user *arn.User, userScore float64, userCompleted int)
|
|
if user != nil
|
|
.average-score-total-completed
|
|
p= fmt.Sprintf("Average rating: %." + strconv.Itoa(user.Settings().Format.RatingsPrecision) + "f | Total completed: %d", userScore, userCompleted) |