UI components
UI components offer a simple way to add advanced features to the front-end of your module. You can easily add a component by using $this->components
(the Components object):
$this->components->add('file-previews');
Components overview
File previews (
file-previews
)After adding the
file-previews
component, every<a href="">
tag withclass="file-preview"
will launch a file preview dialog, if there is a previewer available for the specific file format. The following file formats are supported:- Video: mp4, mov, avi (if browser supports the file type in the
<video>
element) - Audio: mp3, wav, ogg(if browser supports the file type in the
<audio>
element) - Images: jpg, jpeg, png, gif, psd, ai, tiff, bmp
- Documents: pdf, txt, rtf, md, doc, docx, odt, ott (including variants)
- Presentations: ppt, pptx, odp, otp (including variants)
- Spreadsheets: xls, xlsx, ods, ots
- Video: mp4, mov, avi (if browser supports the file type in the
Text editor (
wysiwyg
)
Drawing canvas (
drawing
)