Repository navigation
docs: stop calling the deprecated download handler inline() - #6819
Conversation
AbstractDownloadHandler.inline() is deprecated for removal. A Map icon is served inline without it, and an Anchor takes AttachmentType.INLINE instead.
vaadin-review-bot
left a comment
There was a problem hiding this comment.
Reviewed the changes — left 1 comment.
| Finding | |
|---|---|
| 💬 | "Components that show content, such as Image, already do" hides the actual point |
|
|
||
| - *Progress tracking* — show a progress bar during large downloads using the fluent `whenStart()`, `onProgress()`, and `whenComplete()` callbacks | ||
| - *Inline rendering* — display content in the browser instead of downloading it by calling `inline()` on the handler | ||
| - *Inline rendering* — display content in the browser instead of downloading it. Components that show content, such as `Image`, already do. [since:com.vaadin:vaadin@V25.4]#For an `Anchor`, pass `AttachmentType.INLINE`#. |
There was a problem hiding this comment.
💬 "Components that show content, such as Image, already do" hides the actual point
The sentence reads as a tautology: components that show content show content. The fact the reader needs is that a DownloadHandler passed to such a component is served inline without any extra call — Image.setSrc(DownloadHandler) registers the resource with DownloadDisposition.INLINE (flow-html-components/.../Image.java:256-261), as does IFrame.
Suggested rewrite:
A component that shows the content of a
DownloadHandler, such asImage, already serves it inline.
handle-downloads.adoc:127 · clarity
There was a problem hiding this comment.
Reworded as suggested: "A component that shows the content of a DownloadHandler, such as Image, already serves it inline."
Summary
Two pages still chained the deprecated
AbstractDownloadHandler.inline()(deprecated for removal in 25.4). This removes those calls.What changed
.inline(). Map serves icon images inline by itself in 25.4.inline(). It says that components that show content, such asImage, already serve it inline, and that anAnchortakesAttachmentType.INLINE(with a 25.4 badge).The same deprecated call on the Downloads reference page is handled in #6758.
Test summary
inline()deprecation note, and the Map serializer registering icon images withDownloadDisposition.INLINE.Working on behalf of Petter