Brochure PDF, and any other PDF in a media picker, shows a generic document icon. A thumbnail of page 1 would make it obvious at a glance which brochure is attached.
Parked after looking into it: Umbraco offers no easy hook, and the work is bigger than the payoff for something cosmetic.
Why the obvious route does not exist
The media picker renders umb-imaging-thumbnail, which is image-or-icon with nothing to extend. When there is no image URL it draws the media type icon and stops.
Umbraco-CMS/src/Umbraco.Web.UI.Client/src/packages/media/imaging/components/imaging-thumbnail.element.ts, around line 130.
There is a fileUploadPreview extension point with alias and wildcard matching, but it belongs to input-upload-field — the upload control inside a media item — not the picker on a content page. Different component, wrong place for this.
Two routes if it is ever wanted
Server-side thumbnails. Rasterise page 1 on upload and store it so Umbraco's imaging pipeline has a real image to serve. Previews would then appear everywhere media is shown, not just this field. Needs a server-side PDF rasteriser, and is arguably an Umbraco or ImageSharp concern rather than UpDoc's.
Override the property editor UI for the one data type, wrapping the picker in a custom element that uses the existing up-doc-pdf-thumbnail (which already renders page 1 to a data URL via PDF.js). Confined to Brochure PDF, but it is client-side presentation, which per CLAUDE.md does not belong in the shipped RCL.
Why parked
The field works. The filename identifies the brochure. This is polish, and the cheap version is in the wrong repo while the right version is a bigger piece of work than the problem justifies.
Related: #124, which made media pickers valid mapping destinations.
Brochure PDF, and any other PDF in a media picker, shows a generic document icon. A thumbnail of page 1 would make it obvious at a glance which brochure is attached.
Parked after looking into it: Umbraco offers no easy hook, and the work is bigger than the payoff for something cosmetic.
Why the obvious route does not exist
The media picker renders
umb-imaging-thumbnail, which is image-or-icon with nothing to extend. When there is no image URL it draws the media type icon and stops.Umbraco-CMS/src/Umbraco.Web.UI.Client/src/packages/media/imaging/components/imaging-thumbnail.element.ts, around line 130.There is a
fileUploadPreviewextension point with alias and wildcard matching, but it belongs toinput-upload-field— the upload control inside a media item — not the picker on a content page. Different component, wrong place for this.Two routes if it is ever wanted
Server-side thumbnails. Rasterise page 1 on upload and store it so Umbraco's imaging pipeline has a real image to serve. Previews would then appear everywhere media is shown, not just this field. Needs a server-side PDF rasteriser, and is arguably an Umbraco or ImageSharp concern rather than UpDoc's.
Override the property editor UI for the one data type, wrapping the picker in a custom element that uses the existing
up-doc-pdf-thumbnail(which already renders page 1 to a data URL via PDF.js). Confined to Brochure PDF, but it is client-side presentation, which per CLAUDE.md does not belong in the shipped RCL.Why parked
The field works. The filename identifies the brochure. This is polish, and the cheap version is in the wrong repo while the right version is a bigger piece of work than the problem justifies.
Related: #124, which made media pickers valid mapping destinations.