> For the complete documentation index, see [llms.txt](https://docs.heisenware.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.heisenware.com/app-builder/build-frontend/widgets/display-widgets/media-view.md).

# Media view

The media view widget displays images and PDF documents. It visualizes raw Base64 strings, media server paths, file objects, or public URLs in your Apps.

<figure><img src="/files/xT2rXWHqVNARBChoGGR7" alt="" width="264"><figcaption></figcaption></figure>

## Data binding

### Function output or modifier to widget

| **Property** | **Description**                                                                                                               | **Type**                  |
| ------------ | ----------------------------------------------------------------------------------------------------------------------------- | ------------------------- |
| `data`       | Supplies the media content used to render images or documents on the widget canvas. Automatically unpacks single-item arrays. | string \| array \| object |
| `clear`      | Clears the currently displayed media item from the view layout when a signal is received.                                     | boolean                   |

### Data formats

The `data` property handles multiple flexible input payload types to streamline integration with your backends.

* **Base64 string:** A raw Base64-encoded string character block. The widget automatically resolves standard MIME categories (such as `image/png` or `application/pdf`).
* **File Base64 object:** A structured object defining explicit `base64` data and `type` properties.
* **File path object:** A structured object containing explicit backend server `path` and file `type` keys.
* **Media server path:** A direct text string locator path addressing a storage asset hosted directly on the platform media cluster.
* **URL:** A standard fully qualified public internet web link to an external image or file target.

<figure><img src="/files/UcR1cJBtkC4TgFOlBoMQ" alt=""><figcaption><p>A function node with an image connected to the media view widget. The extension node retrieves the content of the output array.</p></figcaption></figure>

<figure><img src="/files/891V1Pe5cv6qIRGRsovS" alt=""><figcaption><p>Binding a file item extracted from the media server file system directly into memory works without extra modifiers.</p></figcaption></figure>

## Configuration

Set the widget's defaults in the settings panel.

### General settings

| **Property**   | **Label**         | **Description**                                                                                                                      | **Type** |
| -------------- | ----------------- | ------------------------------------------------------------------------------------------------------------------------------------ | -------- |
| `objectFit`    | Image fitting     | Controls how the media stretches or scales to match its layout container boundaries (options include `Contain`, `Cover`, or `Fill`). | string   |
| `borderRadius` | Rounded corners % | Applies a border radius frame curvature to the media canvas outer edges as a percentage of the smaller layout dimension.             | integer  |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.heisenware.com/app-builder/build-frontend/widgets/display-widgets/media-view.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
