streams page align

fix-text-color
Anton Mushnin 2022-11-11 14:19:39 +03:00
rodzic 3be9a0b190
commit f6c069cca8
1 zmienionych plików z 48 dodań i 45 usunięć

Wyświetl plik

@ -222,6 +222,9 @@ const EntriesNavigation = () => {
overflow="hidden" overflow="hidden"
direction="column" direction="column"
flexGrow={1} flexGrow={1}
mt="10px"
mr="5px"
ml="5px"
> >
{streamCache && !eventsIsLoading ? ( {streamCache && !eventsIsLoading ? (
<> <>
@ -433,7 +436,7 @@ const EntriesNavigation = () => {
w="100%" w="100%"
//onScroll={(e) => handleScroll(e)} //onScroll={(e) => handleScroll(e)}
> >
<Stack direction="row" justifyContent="space-between"> <Stack mt="5px" direction="row" justifyContent="space-around">
{!loadNewerEventsIsFetching && !nextEventIsFetching ? ( {!loadNewerEventsIsFetching && !nextEventIsFetching ? (
<Button <Button
onClick={() => { onClick={() => {
@ -452,53 +455,53 @@ const EntriesNavigation = () => {
colorScheme="green" colorScheme="green"
></Button> ></Button>
)} )}
</Stack> {streamCache
{streamCache .slice(
.slice( cursor,
cursor, streamCache.length <= cursor + PAGE_SIZE
streamCache.length <= cursor + PAGE_SIZE ? streamCache.length
? streamCache.length : cursor + PAGE_SIZE
: cursor + PAGE_SIZE )
) .map((entry, idx) => (
.map((entry, idx) => ( <StreamEntry
<StreamEntry showOnboardingTooltips={false}
showOnboardingTooltips={false} key={`entry-list-${idx}`}
key={`entry-list-${idx}`} entry={entry}
entry={entry} disableDelete={!canDelete}
disableDelete={!canDelete} disableCopy={!canCreate}
disableCopy={!canCreate} filterCallback={handleFilterStateCallback}
filterCallback={handleFilterStateCallback} filterConstants={{ DIRECTIONS, CONDITION, FILTER_TYPES }}
filterConstants={{ DIRECTIONS, CONDITION, FILTER_TYPES }} />
/> ))}
))} {previousEvent &&
{previousEvent && !loadOlderEventsIsFetching &&
!loadOlderEventsIsFetching && !previousEventIsFetching ? (
!previousEventIsFetching ? ( <Center>
<Center>
<Button
onClick={() => {
loadPreviousEventHandler();
}}
variant="outline"
colorScheme="green"
>
Load older events
</Button>
</Center>
) : (
<Center>
{!previousEventIsFetching && !loadOlderEventsIsFetching ? (
"Тransactions not found. You can subscribe to more addresses in Subscriptions menu."
) : (
<Button <Button
isLoading onClick={() => {
loadingText="Loading" loadPreviousEventHandler();
}}
variant="outline" variant="outline"
colorScheme="green" colorScheme="green"
></Button> >
)} Load older events
</Center> </Button>
)} </Center>
) : (
<Center>
{!previousEventIsFetching && !loadOlderEventsIsFetching ? (
"Тransactions not found. You can subscribe to more addresses in Subscriptions menu."
) : (
<Button
isLoading
loadingText="Loading"
variant="outline"
colorScheme="green"
></Button>
)}
</Center>
)}
</Stack>
</Flex> </Flex>
</Flex> </Flex>
</> </>