import { OneSignalOptions } from '../interface'; interface OnsSignalSubscribed { isSubscribed: boolean; userId: string; registrationId: string; notificationPermission: string; optedOut: boolean; serviceWorkerActive: string; } export declare class OneSignalService { private readonly doc; private readonly options; private scriptinitalize; private readonly scriptURL; private readonly isSupportedSubject$; private readonly SubscribeStateSubject$; private readonly isOptedOutSubject$; private readonly isPushNotificationsEnabledSubject$; private readonly userIdSubject$; /** * @see {@link https://documentation.onesignal.com/docs/web-push-sdk#ispushnotificationssupported} */ readonly isSupported$: import("rxjs").Observable; /** * @see {@link https://documentation.onesignal.com/docs/web-push-sdk#ispushnotificationsenabled} */ readonly isPushNotificationsEnabled$: import("rxjs").Observable; /** * @see {@link https://documentation.onesignal.com/docs/troubleshooting-web-push#3-check-if-you-are-subscribed} */ readonly subscribeState$: import("rxjs").Observable; /** * @see {@link https://documentation.onesignal.com/docs/troubleshooting-web-push#3-check-if-you-are-subscribed} */ readonly isSubscribe$: import("rxjs").Observable; readonly userId$: import("rxjs").Observable; get isSupported(): boolean; get isSubscribe(): boolean; get isInitialized(): boolean; get isOptedOut(): boolean; get userId(): string; subscribe(): void; /** * call OneSignal.setSubscription(false) * @see {@link https://documentation.onesignal.com/docs/web-push-sdk#section--setsubscription-} */ unsubscribe(): void; /** * https://documentation.onesignal.com/docs/web-push-sdk#section-loading-sdk-asynchronously * @param items push(["functionName", param1, param2]); * @example * ngxOneSignal.push(['sendTag', 'key', 'value', function(tagsSent) { * // Callback called when tags have finished sending * }]); * // or * ngxOneSignal.push(['sendTag', 'key', 'value']).then((tagsSent) => { * // Callback called when tags have finished sending * }); */ push(items: any[]): Promise; constructor(doc: Document, options: OneSignalOptions); private init; private addScript; private initOneSignal; } export {};