How does one disable download option when a file cannot be previewed - regular download option had been removed with the share-custom-config.xml - however the files which cannot be previewed show a download link
You need to reconfigure the download action and implement a custom evaluator to do your custom check (is a preview available) to determine if the download action should be shown. This requires Java implementation and potentially an additional call to the backend for each document in the document list / detail page.
Other than that there is no (standard) way to disable the download option when a preview is not available, unless you do some dirty client-side UI hacks.
Retrieving data ...