Add pagination to featured events

Closes #811

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2021-08-09 17:53:46 +02:00
parent 887ac38b96
commit bbc5ba323d
2 changed files with 62 additions and 21 deletions

View File

@@ -209,8 +209,18 @@ export const FETCH_EVENT_BASIC = gql`
`;
export const FETCH_EVENTS = gql`
query FetchEvents($orderBy: EventOrderBy, $direction: SortDirection) {
events(orderBy: $orderBy, direction: $direction) {
query FetchEvents(
$orderBy: EventOrderBy
$direction: SortDirection
$page: Int
$limit: Int
) {
events(
orderBy: $orderBy
direction: $direction
page: $page
limit: $limit
) {
total
elements {
id
@@ -246,14 +256,14 @@ export const FETCH_EVENTS = gql`
domain
name
}
# attributedTo {
# avatar {
# id
# url
# },
# preferredUsername,
# name,
# },
attributedTo {
avatar {
id
url
}
preferredUsername
name
}
category
tags {
...TagFragment