import { EventEmitter, OnInit } from '@angular/core';
import { ControlValueAccessor, NgControl } from '@angular/forms';
import { NtFileSizeError, NtFileTypeError, NtUploadError, NtUploadHandler, NtUploadRef } from '@ng-tangram/components/core';
import { NtFormFieldControl } from '@ng-tangram/components/forms';
import { NtAttachmentIcons } from './attachment-icons';
export declare type NtAttachmentError = NtFileTypeError | NtFileSizeError | NtUploadError;
export declare class NtAttachmentRef<T> extends NtUploadRef<T> {
    file: File;
    id: string;
    category?: string;
    constructor(file: File, id?: string);
}
export declare class NtAttachmentComponent<T> extends NtFormFieldControl<NtAttachmentRef<T>[]> implements OnInit, ControlValueAccessor {
    private _uploadHandler;
    ngControl: NgControl;
    icons: NtAttachmentIcons;
    private readonly _destroy;
    _displayAttachmentRefs: NtAttachmentRef<T>[];
    private _attachmentRefs;
    readonly value: NtAttachmentRef<T>[];
    private _disabled;
    disabled: boolean;
    private _readonly;
    readonly: boolean;
    private _notrigger;
    notrigger: boolean;
    private _required;
    required: boolean;
    private _accept;
    accept: string | Array<string>;
    private _multiple;
    multiple: boolean;
    private _limitSize;
    limitSize: number;
    url: string;
    name: string;
    errors: EventEmitter<NtFileTypeError | NtFileSizeError | NtUploadError | NtAttachmentError[]>;
    private _onChange;
    private _onTouched;
    constructor(_uploadHandler: NtUploadHandler, ngControl: NgControl, icons: NtAttachmentIcons);
    ngOnInit(): void;
    ngOnDestroy(): void;
    writeValue(value: NtAttachmentRef<T>[]): void;
    registerOnChange(fn: (_: any) => {}): void;
    registerOnTouched(fn: () => {}): void;
    setDisabledState(isDisabled: boolean): void;
    _select(files: File[]): void;
    _remove(attachmentRef: NtAttachmentRef<T>): void;
    private _createAttachmentRef;
    private _removeAttachmentRef;
    private _resolveUploadedResult;
    private _initValueCategoies;
}
