Default Light
MgLibrary
Overview
Installation
Buttons
Cards
Charts
Codes
Data Grids
Dropdowns
Editors
Headers & Animations
Icons
Indicators
Inputs
Lists
Modals
Menus
Panels
Pills & Chips
Scheduling
Tabs
Time Line
Trees
Customization

File Upload

Stylized file uploader with previews.

Use this example to explore default behavior, customization points, and accessibility-friendly patterns in a real Blazor page.

File Upload

MgFileUpload

A stylized file uploader with support for filters and image previews.

API Reference

MgFileUpload

Property Type Default Description
DisplayText string "" Button text to show for file chooser.
ShowPreview bool false Show an image preview for image files.
Filter string "*/*" Accept filter (e.g., image/*, .pdf).
FileChosen EventCallback<IBrowserFile> - Fired when a user selects a file.
An unhandled error has occurred. Reload 🗙