Feature/refactor source mangas screen (#314)
* Refactor "SourceMangas" * Refactor "SourceMangas" - Show loading placeholder on filter reset or submit Due to the url being the same for all "filter requests" the loading state doesn't get changed by SWR. Instead, only the "isValidating" state gets updated. * Refactor "SourceMangas" - Update routing * Refactor "SourceMangas" - Prevent duplicated mangas in grid There is a possibility that the "latest" endpoint returns the same manga on different pages * Always set the toolbar content on the manga page "setAction" wasn't called on the manga page, thus, in case the previous page didn't unset the action, it never got unset * Rename source content type "Browse" to "Popular"
This commit is contained in:
@@ -57,9 +57,9 @@ type SWRInfiniteResponseLoadInfo = {
|
||||
isLoadMore: boolean;
|
||||
};
|
||||
type AbortableRequest = { abortRequest: AbortController['abort'] };
|
||||
type AbortableAxiosResponse<Data = any> = { response: Promise<AxiosResponse<Data>> } & AbortableRequest;
|
||||
type AbortableSWRResponse<Data = any, Error = any> = SWRResponse<Data, Error> & AbortableRequest;
|
||||
type AbortableSWRInfiniteResponse<Data = any, Error = any> = SWRInfiniteResponse<Data, Error> &
|
||||
export type AbortableAxiosResponse<Data = any> = { response: Promise<AxiosResponse<Data>> } & AbortableRequest;
|
||||
export type AbortableSWRResponse<Data = any, Error = any> = SWRResponse<Data, Error> & AbortableRequest;
|
||||
export type AbortableSWRInfiniteResponse<Data = any, Error = any> = SWRInfiniteResponse<Data, Error> &
|
||||
AbortableRequest &
|
||||
SWRInfiniteResponseLoadInfo;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user