import { AXStyleColorType, AXStyleLookType, AXLocation, MXBaseComponent } from '@acorex/cdk/common';
import { AXOverlayRef } from '@acorex/cdk/overlay';
import * as _angular_core from '@angular/core';
import { TemplateRef, Type, OnInit, InjectionToken } from '@angular/core';

type AXNotificationContentType = string | TemplateRef<unknown> | Type<unknown>;
interface AXNotificationButtonItem {
    color?: AXStyleColorType;
    look?: AXStyleLookType;
    text: string;
    disabled?: boolean;
    loading?: boolean;
    onClick?: (e?: {
        source: AXNotificationButtonItem;
        handled?: boolean;
    }) => void;
}
interface AXNotificationOptions {
    buttons?: AXNotificationButtonItem[];
    icon?: string;
    title?: string;
    content?: AXNotificationContentType;
    location: AXLocation;
    closeButton?: boolean;
    color: AXStyleColorType;
    timeOut?: number;
    timeOutProgress?: boolean;
    pauseOnHover?: boolean;
}
interface AXNotificationData {
    buttons?: AXNotificationButtonItem[];
    icon?: string;
    title?: string;
    content?: AXNotificationContentType;
    location: AXLocation;
    closeButton: boolean;
    color: AXStyleColorType;
    timeOut?: number;
    timeOutProgress: boolean;
    pauseOnHover?: boolean;
}
interface AXNotificationRef {
    close(): void;
}
/**
 * @internal
 * Internal reference used by notification service to manage overlay instances
 */
interface AXNotificationInternalRef {
    id: string;
    overlayRef: AXOverlayRef<unknown>;
    config: AXNotificationData;
    close: () => void;
}

/**
 * The Button is a component which detects user interaction and triggers a corresponding event
 *
 * @category Components
 */
declare class AXNotificationComponent extends MXBaseComponent implements OnInit {
    /** Notification configuration data */
    config: _angular_core.InputSignal<AXNotificationData>;
    /** @internal Callback function to close the notification */
    onClose: _angular_core.InputSignal<() => void>;
    private notificationService;
    /** @ignore */
    protected _icon: string;
    private intervalId;
    private isPaused;
    protected remainingTime: _angular_core.WritableSignal<number>;
    protected transitionDuration: _angular_core.WritableSignal<number>;
    /** Template content if config.content is a TemplateRef */
    protected templateContent: _angular_core.Signal<TemplateRef<unknown>>;
    /** Component content if config.content is a component Type */
    protected componentContent: _angular_core.Signal<Type<unknown>>;
    /** String content if config.content is a string */
    protected stringContent: _angular_core.Signal<string>;
    ngOnInit(): void;
    private pauseAnimation;
    private _handleTimeOut;
    /** @ignore */
    private _initIcon;
    /** @ignore */
    protected _handleButtonClick(button: AXNotificationButtonItem): void;
    /**
     * Closes the notification.
     */
    close(): void;
    /**
     * Closes all notifications.
     */
    closeAll(): void;
    static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXNotificationComponent, never>;
    static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXNotificationComponent, "ax-notification", never, { "config": { "alias": "config"; "required": true; "isSignal": true; }; "onClose": { "alias": "onClose"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
}

interface AXNotificationConfig {
    gap: number;
    timeOut: number;
    timeOutProgress: boolean;
    location: AXLocation;
    closeButton: boolean;
    limit: number;
    pauseOnHover: boolean;
}
declare const AX_NOTIFICATION_CONFIG: InjectionToken<AXNotificationConfig>;
declare const AXNotificationDefaultConfig: AXNotificationConfig;
type PartialNotificationConfig = Partial<AXNotificationConfig>;
declare function notificationConfig(config?: PartialNotificationConfig): AXNotificationConfig;

declare class AXNotificationModule {
    static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXNotificationModule, never>;
    static ɵmod: _angular_core.ɵɵNgModuleDeclaration<AXNotificationModule, never, [typeof AXNotificationComponent], [typeof AXNotificationComponent]>;
    static ɵinj: _angular_core.ɵɵInjectorDeclaration<AXNotificationModule>;
}

declare class AXNotificationService {
    private overlayService;
    private translationService;
    private defaultConfig;
    private activeNotifications;
    private reservedNotifications;
    private notificationCounterRef;
    private moreNotificationsColor;
    private moreNotificationsLocation;
    private reserveCounter;
    show(config: AXNotificationOptions): AXNotificationRef;
    private displayNotification;
    hideAll(): void;
    private handleShowReservedNotification;
    private handleReservedNotificationCounter;
    private createReservedCounterNotification;
    private positionNotification;
    private reposition;
    private getRepositionPosition;
    private applyRepositionPosition;
    private getPosition;
    static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXNotificationService, never>;
    static ɵprov: _angular_core.ɵɵInjectableDeclaration<AXNotificationService>;
}

export { AXNotificationComponent, AXNotificationDefaultConfig, AXNotificationModule, AXNotificationService, AX_NOTIFICATION_CONFIG, notificationConfig };
export type { AXNotificationButtonItem, AXNotificationConfig, AXNotificationContentType, AXNotificationData, AXNotificationInternalRef, AXNotificationOptions, AXNotificationRef, PartialNotificationConfig };
