Optional ReadonlyacceptAccepted MIME types; defaults to the common web image formats.
Optional ReadonlycompressShrink images before they are uploaded. On by default because the common
case, a photo straight off a phone, is several megabytes of pixels no
document will ever show; pass false to upload the bytes untouched.
Optional ReadonlycompressorSwap the compressor out (a worker, a WASM encoder, a stub in tests).
Optional ReadonlydeleteDelete the stored object when its image leaves the document.
Optional ReadonlymaxBytes; defaults to 10 MB.
Optional ReadonlyonSurfaced to the user when a file is rejected or an upload fails.
Optional ReadonlyonUpload lifecycle for progress UI; called on every state change.
ReadonlystorageWhere the bytes go. Any ImageStorage implementation.
Optional ReadonlytransformerSwap the rotate/crop rasteriser out, for the same reasons.
Reject anything that is not a real image before a byte leaves the browser.