Update to server download subscription changes

This commit is contained in:
schroda
2024-08-21 21:29:01 +02:00
parent 61ae717e9a
commit a819d45489
9 changed files with 217 additions and 42 deletions

View File

@@ -8,27 +8,52 @@
import gql from 'graphql-tag';
const DOWNLOAD_TYPE_FIELDS = gql`
fragment DOWNLOAD_TYPE_FIELDS on DownloadType {
chapter {
id
name
sourceOrder
isDownloaded
}
manga {
id
title
downloadCount
}
progress
state
tries
}
`;
export const DOWNLOAD_STATUS_FIELDS = gql`
${DOWNLOAD_TYPE_FIELDS}
fragment DOWNLOAD_STATUS_FIELDS on DownloadStatus {
state
queue {
chapter {
id
name
sourceOrder
isDownloaded
}
manga {
id
title
downloadCount
}
progress
state
tries
...DOWNLOAD_TYPE_FIELDS
}
}
`;
export const DOWNLOAD_UPDATES_FIELDS = gql`
${DOWNLOAD_TYPE_FIELDS}
fragment DOWNLOAD_UPDATES_FIELDS on DownloadUpdates {
state
omittedUpdates
updates {
type
download {
...DOWNLOAD_TYPE_FIELDS
position
}
}
}
`;