import { EventEmitter, OnChanges, SimpleChanges } from '@angular/core'; import { ControlValueAccessor } from '@angular/forms'; import * as i0 from "@angular/core"; /** Strapi file object interface */ export interface StrapiFile { id?: number; name: string; url: string; mime?: string; size?: number; width?: number; height?: number; ext?: string; alternativeText?: string; caption?: string; } export declare class FileUploadComponent implements OnChanges, ControlValueAccessor { /** Display mode of the uploader ('basic' | 'advanced') */ mode: 'basic' | 'advanced'; /** Allow multiple file selection */ multiple: boolean; /** Accepted file types (e.g., 'image/*') */ accept: string; /** Maximum file size in bytes */ maxFileSize: number; /** Disable the upload component */ disabled: boolean; /** Label for the choose button */ chooseLabel: string; /** Label for the upload button */ uploadLabel: string; /** Label for the cancel button */ cancelLabel: string; /** Files array for two-way binding */ files: (File | string | StrapiFile)[]; placeholder: string; /** For Strapi integration - if true, this field is a linked field and should return only IDs */ isLinkedField: boolean; /** View model for template: { name, size, type, src, status } */ fileViewModels: Array<{ name: string; size: number | null; type: string | null; src: string; status: 'cloud' | 'local'; }>; label: string; labelPosition: 'top' | 'left'; /** Emits when files are changed */ filesChange: EventEmitter; imageUrls: string[]; ngOnChanges(changes: SimpleChanges): void; onFileSelected(event: Event): void; removeFile(index: number): void; /** * Get the form value - returns Strapi IDs for linked fields, File objects for local files */ private getFormValue; onChange: (files: any[]) => void; onTouched: () => void; writeValue(files: (File | string | StrapiFile)[] | null): void; registerOnChange(fn: (files: any[]) => void): void; registerOnTouched(fn: () => void): void; setDisabledState(isDisabled: boolean): void; isImage(file: File | StrapiFile): boolean; formatSize(size: number): string; private updateFileViewModels; private extractFileName; downloadFile(fileViewModel: { src: string; name: string; status: 'cloud' | 'local'; }): Promise; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; }