Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

497 B
Raw Blame
import type { NotificationAttributes } from "ente-base/components/Notification";
import { createContext, useContext } from "react";

export interface AlbumsAppContextT {
    showLoadingBar: () => void;
    hideLoadingBar: () => void;
    showNotification: (attributes: NotificationAttributes) => void;
}

export const AlbumsAppContext = createContext<AlbumsAppContextT | undefined>(
    undefined,
);

export const useAlbumsAppContext = (): AlbumsAppContextT =>
    useContext(AlbumsAppContext)!;