mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Add wordsCount and better center new grid cards
This commit is contained in:
parent
c14550f14f
commit
e9ae311559
2 changed files with 8 additions and 1 deletions
|
|
@ -161,7 +161,12 @@ export function LibraryGridCard(props: LinkedItemCardProps): JSX.Element {
|
|||
fontFamily: 'SF Pro Display',
|
||||
}}
|
||||
>
|
||||
15 min read
|
||||
{props.item.wordsCount ?? 0 > 0
|
||||
? `${Math.max(
|
||||
1,
|
||||
Math.round(props.item.wordsCount / 235)
|
||||
)} min read`
|
||||
: null}
|
||||
</Box>
|
||||
)}
|
||||
</HStack>
|
||||
|
|
|
|||
|
|
@ -83,6 +83,7 @@ export type LibraryItemNode = {
|
|||
subscription?: string
|
||||
readAt?: string
|
||||
savedAt?: string
|
||||
wordsCount?: number
|
||||
recommendations?: Recommendation[]
|
||||
}
|
||||
|
||||
|
|
@ -168,6 +169,7 @@ export function useGetLibraryItemsQuery({
|
|||
subscription
|
||||
readAt
|
||||
savedAt
|
||||
wordsCount
|
||||
recommendations {
|
||||
id
|
||||
name
|
||||
|
|
|
|||
Loading…
Reference in a new issue