import { LitElement, nothing, PropertyValues, TemplateResult } from 'lit'; import { Ref } from 'lit/directives/ref.js'; import './ix-file-chip.js'; import DataStorageUnit from './data-storage-unit.js'; import UploaderFile from './internal/uploader-file.js'; import '@digital-realty/ix-dialog/ix-dialog.js'; export declare class IxFileUploader extends LitElement { static readonly styles: import("lit").CSSResult[]; /** @nocollapse */ static readonly formAssociated = true; private readonly internals; dropzoneRef: Ref; fileRef: Ref; showTemplateFileLink: boolean; allowMultipleFiles: boolean; allowDuplicates: boolean; headerText: string; bodyText: string; hintText: string | undefined; ariaLabel: string; defaultFiles: Array; allowDeleteDefaultFiles: boolean; hideBody: boolean; extensions: string[]; maxFileCount: number; maxFileSizeUnit: DataStorageUnit; maxFileSizeValue: number; name: string; error: boolean; askConfirmationOnDeleteFile: boolean; deleteConfirmationDialogLabel: string; isDeleteBulkFileDialogOpen: boolean; pendingFileDeletion: UploaderFile | undefined; files: Array; errors: Array; /** * Alternating polite live regions used to announce non-error status * updates (successful uploads, removals). Two regions are toggled * between so that the DOM node hosting the message is fully replaced * on each announcement; this is more reliable across NVDA/JAWS than * mutating the text of a single node, especially for repeated * announcements with identical wording. */ private statusMessage; private statusMessageAlt; private statusRegionToggle; private statusAnnounceTimer; private maxFileSizeInBytes; /** * The associated form element with which this element's value will submit. */ get form(): HTMLFormElement | null; private onDrop; private onFileChange; get allowedMaxFileCount(): number; private process; private updateState; private onFilesUploaded; /** * Push a message to one of the two alternating polite live regions. * * Screen readers, particularly NVDA, sometimes miss updates to a * live region when consecutive announcements share the same wording * or arrive within the same microtask. Toggling between two regions * (and only populating the newly-active one after a short delay) * ensures each announcement is treated as a distinct change and is * reliably picked up. */ private announce; disconnectedCallback(): void; private onFileClick; private onFileDelete; handleDeleteBulkFile(): void; deleteLastFileWithoutConfirmation(): void; private openFileUploadDialog; protected firstUpdated(): void; protected update(changedProperties: PropertyValues): void; isFileDeletable(file: UploaderFile): boolean; private renderFileList; protected updated(_: PropertyValues): void; renderDeleteBulkFileConfirmationDialog(): TemplateResult<1> | typeof nothing; renderHintText(): TemplateResult<1> | typeof nothing; renderErrors(): TemplateResult<1>; /** * Visually hidden alternating polite live regions used to announce * non-error status updates (successful uploads, removals) without * stealing focus from the user. Only one region contains text at a * time; alternating between them makes repeated announcements * detectable by screen readers. */ renderStatusRegion(): TemplateResult<1>; renderBody(): TemplateResult<1>; protected render(): TemplateResult<1>; }