I wrote a simple file encryption app some years ago that is a single self-contained HTML file. When you use it to encrypt files, it outputs another self-contained HTML file with a copy of the encrypted data inside, along with the code to decrypt it (if the correct password is specified): https://hypervault.github.io/