feat: recent displayed on front page
This commit is contained in:
@@ -7,7 +7,11 @@ import {
|
||||
createResource,
|
||||
useContext,
|
||||
} from "solid-js";
|
||||
import { CategoryUnion, getUserImages } from "../network";
|
||||
import {
|
||||
CategoryUnion,
|
||||
getUserImages,
|
||||
JustTheImageWhatAreTheseNames,
|
||||
} from "../network";
|
||||
import { groupPropertiesWithImage } from "../utils/groupPropertiesWithImage";
|
||||
|
||||
export type ImageWithRawData = Awaited<
|
||||
@@ -28,6 +32,8 @@ type CategoriesSpecificData = {
|
||||
export type SearchImageStore = {
|
||||
images: Accessor<ImageWithRawData[]>;
|
||||
|
||||
userImages: Accessor<JustTheImageWhatAreTheseNames>;
|
||||
|
||||
imagesWithProperties: Accessor<ReturnType<typeof groupPropertiesWithImage>>;
|
||||
processingImages: Accessor<
|
||||
Awaited<ReturnType<typeof getUserImages>>["ProcessingImages"] | undefined
|
||||
@@ -122,6 +128,7 @@ export const SearchImageContextProvider: Component<ParentProps> = (props) => {
|
||||
value={{
|
||||
images: imageData,
|
||||
imagesWithProperties: imagesWithProperties,
|
||||
userImages: () => data()?.UserImages ?? [],
|
||||
processingImages,
|
||||
onRefetchImages: refetch,
|
||||
categories,
|
||||
|
||||
Reference in New Issue
Block a user