added mappers, updated models

This commit is contained in:
lnn0q 2025-05-17 17:16:26 +03:00
parent 6ada519e06
commit a8375b99c2
11 changed files with 306 additions and 120 deletions

View file

@ -32,16 +32,16 @@ function RouteComponent() {
return (
<Stack justifyContent="center" alignItems="center">
<Stack width="90%">
<WorkingListSearch
value={workingSearchValue}
onSubmit={value => {
alert(value);
}}
onChange={value => setWorkingSearchValue(value)}
/>
{data != null ? (
<>
<WorkingListSearch
value={workingSearchValue}
onSubmit={value => {
alert(value);
}}
onChange={value => setWorkingSearchValue(value)}
/>
<WorkingList
workingsList={data.workingMany.items.map(item => ({
...item,
@ -58,7 +58,15 @@ function RouteComponent() {
/>
</>
) : (
<Skeleton />
<>
<Stack direction="row" justifyContent="center" alignItems="center" gap={2}>
<Skeleton height={10} width="80%" />
<Skeleton height={10} width="calc(20% - 6px)" />
</Stack>
<Skeleton height={20} />
<Skeleton height={20} />
<Skeleton height={20} />
</>
)}
</Stack>
</Stack>
@ -70,21 +78,21 @@ const query = gql`
workingMany(input: $input) {
items {
id
type
title
description
author {
id
username
}
progressStatus
updatedAt
chapters {
total
}
wordsTotal
progressStatus
ratingTotal
reviews {
total
reviewsTotal
book {
id
chaptersTotal
wordsTotal
}
}
total