In the file uploader widget, there is an attribute called Allowed extensions where you can define what extensions can be uploaded
The best way to solve this is create an enumeration with filetype. In a microflow check the extension (by finding the last . in the name and do a substring on the rest). When you have the extension string compare it to known filetypes like .png and .pdf etc. Set the enumeration according to what you find. Then you can use this enumeration in the document overview. Hope this helps.
If you try to achieve something like this fiddle, than as far is i know there is no way to do that with default functionality.
The File Manager widget only validates after the user has selected a file. Instead of limiting the file a user can see as demonstrated using the fiddle above.