UNPKG

@churchapps/apphelper

Version:

Library of helper functions for React and NextJS ChurchApps

15 lines 920 B
import { UserInterface, UserContextInterface, IApiPermission, PersonInterface, LoginUserChurchInterface } from "@churchapps/helpers"; export declare class UserHelper { static currentUserChurch: LoginUserChurchInterface; static userChurches: LoginUserChurchInterface[]; static user: UserInterface; static churchChanged: boolean; static person: PersonInterface; static selectChurch: (context?: UserContextInterface, churchId?: string, keyName?: string) => Promise<void>; static setupApiHelper(userChurch: LoginUserChurchInterface): void; static setupApiHelperNoChurch(user: LoginUserChurchInterface): void; static checkAccess({ api, contentType, action }: IApiPermission): boolean; static createAppUrl(appUrl: string, returnUrl: string): string; static redirectToLogin(returnUrl?: string, handleRedirect?: (url: string) => void): void; } //# sourceMappingURL=UserHelper.d.ts.map