Enhanced document previews for a range of different document and media types, plus a dashlet allowing any content item to be displayed on a site dashboard.
Similar to the built-in Image plugin, the Media Viewers plugins should support checking the file size of the source file, allowing administrators to configure a maximum file size beyond which the viewer will not be used.
var srcMaxSize = this.attributes.srcMaxSize;
if (!this.attributes.src && srcMaxSize.match(/^\d+$/) && this.wp.options.size > parseInt(srcMaxSize))
{
// File is too big
}
Similar to the built-in
Image
plugin, the Media Viewers plugins should support checking the file size of the source file, allowing administrators to configure a maximum file size beyond which the viewer will not be used.