import { InjectionToken, Injector } from '@angular/core'; import { ActivatedRoute, Route, UrlSegment, UrlSegmentGroup } from '@angular/router'; import { Observable } from 'rxjs'; /** * * set up a handle for injector * to be used to inject services without the contructor */ export declare let injector: Injector; export declare function setInjector(anInjector: Injector): void; /** * * Useful in places where the official angular `inject` cannot be use * i.e outside injection context */ export declare function outject(service: T): any; export declare function keys(obj: Object): string[]; export declare function cut(oldStr: string, fullStr: string): string; export declare function titleCase(words: string, seperator?: string, joiner?: string): string; export declare function camelCase(words: string, seperator?: string, joiner?: string): string; export declare function merge(...objects: Object[]): Object; export declare function recursiveMerge(target: any, ...sources: any[]): any; export declare function mergeToArray(...items: any[]): any[]; export declare function hash(input?: string): string; export declare function plural(word: string): string; export declare function singular(word: string): string; export declare function snakeCase(words: string, seperator?: string, joiner?: string): string; export declare function isNumeric(str: string): boolean; export declare function isNullOrUndefined(value: any): boolean; export declare function isUndefined(value: any): boolean; export declare function isBlankString(value: any): boolean; export declare function isFunction(value: any): boolean; export declare function isObject(x: any): boolean; export declare function isArray(x: any): boolean; export declare function toJSON(mayBeJSON: string, returnJSON?: boolean): any; export declare function routeGroupMatcher(haystack: string[]): (segments: UrlSegment[], segmentGroup: UrlSegmentGroup, route: Route) => { consumed: UrlSegment[]; } | null; export declare function numberWithCommas(number: number): string; export declare function randomString(length?: number): string; export declare function isObservable(mayBeObservable: any): boolean; export declare function copy(obj: Object): Object; export declare const catchRxErrors: (onError?: (e: any) => void, toReturn?: any) => import("rxjs").OperatorFunction; export declare const get: (store: any, path: string) => any; export declare const set: (store: any, path: string, value: any) => any; export declare const leftMerge: (store: any, updates: any) => any; export declare const ROUTE_LIST: InjectionToken; export declare const mergeRouteList: (routeList: any[]) => any; export declare const router: () => any; export declare const route: () => any; export declare const data: (key?: string) => any; export declare const state: (key?: string) => any; export declare const query: (key?: string) => any; export declare const param: (key?: string) => any; export declare const navigate: (path: string[], state?: any) => any; export declare const navigateRelativelly: (path: string[], relativeTo?: ActivatedRoute, state?: any) => any; export declare const navigateExternal: (url: string, inNewTab?: boolean) => void; export declare const reload: (force?: boolean, stripQuery?: boolean) => void; export declare const using: (next?: (value: any) => void, error?: (err: any) => void, complete?: () => void) => { next: (value: any) => void; error: ((err: any) => void) | undefined; complete: (() => void) | undefined; }; export declare const getValueByDottedString: (dottedString: string, data: any) => any; /** * @deprecated * * Use tzHuman instead */ export declare const prettyTime: (input: string | Date) => string; export declare const deepCopy: (input: any | any[]) => any; export interface StartConfig { clientId: string; guardBaseUrl: string; dashboardPath: string[]; } export declare const X_START_CONFIG: InjectionToken; export interface Action { type: string; payload?: any; } export declare enum DefaultActionType { INIT_STORE = "default_store_init", EMPTY_STORE = "default_store_empty" } export declare enum CommonActionType { USER_LOGIN = "x_user_login", USER_LOGOUT = "x_user_logout", USER_SWITCH = "x_user_switch", NOTIFICATION_TOAST = "x_notification_toast", THEME_SWITCH = "x_theme_toggle", APP_CONFIG = "x_app_config", USER_SESSION = "x_user_sessions", USER_ATTRIBUTES = "x_user_attributes", SEARCH_RESULT = "x_search_result" } export interface WsSubscribePayload { namespace?: string; event: string; } export declare const pretty: (value: string) => string; export declare const getClientId: () => string; export declare const getClientName: () => string; export declare const isUrl: (value: string) => boolean; export declare const clone: (obj: any) => any; export declare const recursiveMergeWithArray: (target: any, ...sources: any[]) => any; export declare enum StoreType { Local = "local", Session = "session" } export declare const asyncCache$: (obs: Observable, key: string) => Observable; export declare const toBase64: (file: File) => Promise; export declare const splitIntoTwo: (value: string, separator?: string) => string[]; export declare const fetchRouteInfo: (route: ActivatedRoute) => { [x: string]: any; }[]; export declare const onlyUnique: (array: T[]) => T[]; export declare const isEmoji: (value: string) => boolean; export declare const getPublicIp: () => Promise;