@open-tender/store
Version:
A library of hooks, reducers, utility functions, and types for use with Open Tender applications that utilize our in-store POS API
35 lines (34 loc) • 1.43 kB
TypeScript
import { ErrorAlerts, RequestError, RequestStatus } from '@open-tender/types';
import { AppState } from '../app';
export interface ErrorAlertsState {
entities: ErrorAlerts;
loading: RequestStatus;
error: RequestError;
}
export declare enum ErrorAlertsActionType {
FetchErrorAlerts = "errorAlerts/fetchErrorAlerts",
DismissErrorAlert = "errorAlerts/dismissErrorAlert"
}
export declare const fetchErrorAlerts: import("@reduxjs/toolkit").AsyncThunk<ErrorAlerts, void, {
state: AppState;
rejectValue: RequestError;
dispatch?: import("redux").Dispatch<import("redux").UnknownAction> | undefined;
extra?: unknown;
serializedErrorType?: unknown;
pendingMeta?: unknown;
fulfilledMeta?: unknown;
rejectedMeta?: unknown;
}>;
export declare const dismissErrorAlert: import("@reduxjs/toolkit").AsyncThunk<void, number, {
state: AppState;
rejectValue: RequestError;
dispatch?: import("redux").Dispatch<import("redux").UnknownAction> | undefined;
extra?: unknown;
serializedErrorType?: unknown;
pendingMeta?: unknown;
fulfilledMeta?: unknown;
rejectedMeta?: unknown;
}>;
export declare const resetErrorAlerts: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"errorAlerts/resetErrorAlerts">;
export declare const selectErrorAlerts: (state: AppState) => ErrorAlertsState;
export declare const errorAlertsReducer: import("redux").Reducer<ErrorAlertsState>;