Fixes broken PDF viewer

PDF viewer now correctly detects the files app.
Added missing JS dependency.

Fixes #1409