Skip to content

Interface: AnyDropErrorItemContext ​

Defined in: ui/src/types.ts:234

Context of an error panel row.

Extends ​

Properties ​

PropertyTypeDescriptionInherited fromDefined in
entryErrorEntry--ui/src/types.ts:236
fileAnyDropFile | null--ui/src/types.ts:238
indexnumber--ui/src/types.ts:237
instanceAnyDropThe instance.AnyDropRenderContext.instanceui/src/types.ts:117
kind"errorItem"--ui/src/types.ts:235
layoutstring & object | AnyDropLayoutThe current layout.AnyDropRenderContext.layoutui/src/types.ts:119
partsobject--ui/src/types.ts:241
parts.retryHTMLButtonElement | null--ui/src/types.ts:241
parts.textHTMLElement--ui/src/types.ts:241
rowHTMLElementThe library-owned .ad-error-row.-ui/src/types.ts:240

Methods ​

html() ​

ts
html(strings, ...values): HTMLElement;

Defined in: ui/src/types.ts:123

Builds DOM from markup; every ${value} is HTML-escaped.

Parameters ​

ParameterType
stringsTemplateStringsArray
...valuesunknown[]

Returns ​

HTMLElement

Inherited from ​

AnyDropRenderContext.html


icon() ​

ts
icon(name): HTMLElement;

Defined in: ui/src/types.ts:125

<span class="ad-icon" aria-hidden="true"> holding the configured icon.

Parameters ​

ParameterType
name| string & object | AnyDropIconName

Returns ​

HTMLElement

Inherited from ​

AnyDropRenderContext.icon


retry() ​

ts
retry(): void;

Defined in: ui/src/types.ts:243

Retries the file (a no-op when the entry is not retryable).

Returns ​

void


t() ​

ts
t(key, vars?): string;

Defined in: ui/src/types.ts:121

The current text of a dict* option, with placeholders replaced. Unknown keys return the key.

Parameters ​

ParameterType
key| "dictFileTooBig" | "dictInvalidFileType" | "dictResponseError" | "dictUploadCanceled" | "dictMaxFilesExceeded" | "dictFileUnreadable" | "dictInvalidPath" | "dictFileSizeUnits" | keyof AnyDropDict
vars?Record<string, string | number>

Returns ​

string

Inherited from ​

AnyDropRenderContext.t

Released under the MIT License.