UNPKG

mi-auth-client

Version:
26 lines (25 loc) 1.15 kB
import { Token } from './clientTool.interface'; import { StrapiRole, StrapiUser } from './strapi.interface'; export declare const isEmail: (email: string) => boolean; export declare const assignObject: <T extends object>(target: T, arg: Partial<T>) => T & Partial<T>; export declare const lastElement: <T extends object>(array: T[]) => T; export declare const roleNames: { root: string; superAdmin: string; admin: string; user: string; manager: string; }; export declare const roleNames2GUI: (role: string) => any; export declare const sortSetting: { 1: string; '-1': string; }; export declare const isValidKey: <T extends object>(key: string, object: T) => boolean; export declare const camelCase: (s: string) => string; export declare let serviceUrl: string; export declare const setUrl: (url: string) => string; export declare const roles: (token: Token) => Promise<StrapiRole[]>; export declare const users: (token: Token, params: URLSearchParams) => Promise<StrapiUser[]>; export declare const brands: (token: Token, params: URLSearchParams) => void; export declare const parseErrorMessage: (errorMessage: any) => any;