title | page_title | description | slug | tags | published | position |
---|---|---|---|---|---|---|
Template |
DropZone Content Template |
Learn more about how to modify the default content of the Telerik UI for Blazor DropZone by using its template and defining a custom layout. |
dropzone-template |
telerik,blazor,dropzone,external,drag,drop,file,template,custom,content |
true |
5 |
The DropZone allows you to customize the default rendering of its content by using a Template
.
The Template
is a RenderFragment
and allows you to add whatever custom content is required such as simple text, HTML elements, or other components.
caption Use Template to add custom content in the DropZone
<TelerikDropZone Id="@DropZoneId">
<Template>
<TelerikSvgIcon Icon="@SvgIcon.FileAdd" />
<span>Drop files here</span>
</Template>
</TelerikDropZone>
<TelerikFileSelect DropZoneId="@DropZoneId" />
@code {
private string DropZoneId => "my-dropzone";
}