feat: Define User GraphQL types and user profile query
This commit is contained in:
@@ -129,6 +129,19 @@ export const typeDefs = /* GraphQL */ `
|
||||
url: String!
|
||||
}
|
||||
|
||||
type User {
|
||||
name: String!
|
||||
avatar: Image!
|
||||
statistics: UserAnimeStatistics!
|
||||
}
|
||||
|
||||
type UserAnimeStatistics {
|
||||
count: Int!
|
||||
meanScore: Float!
|
||||
minutesWatched: Int!
|
||||
episodesWatched: Int!
|
||||
}
|
||||
|
||||
# ====================
|
||||
# Input Types
|
||||
# ====================
|
||||
@@ -181,6 +194,11 @@ export const typeDefs = /* GraphQL */ `
|
||||
page: Int = 1
|
||||
limit: Int = 10
|
||||
): PopularResult!
|
||||
|
||||
"""
|
||||
Fetch the authenticated user's profile
|
||||
"""
|
||||
user: User!
|
||||
}
|
||||
|
||||
# ====================
|
||||
|
||||
Reference in New Issue
Block a user