Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setting to use .md or .mdenc for live preview formatting of encrypted notes #127

Closed
LiamSwayne opened this issue Oct 1, 2023 · 4 comments
Labels
can't fix Some 3rd party issue or limitation is preventing this issue from being worked on

Comments

@LiamSwayne
Copy link
Contributor

LiamSwayne commented Oct 1, 2023

In 2.3.2, encrypted notes started using .mdenc instead of .md. Notes are presented as txts, and live preview formatting doesn't work. Only reading view shows formatting.

A setting to use .md or .mdenc could be used to enable or disable live preview formatting in encrypted notes.

Edit: Another reason to enable the option for .md is Obsidian Sync. Because .mdenc isn't recognized as a normal note, you have to enable syncing for all unsupported file types just to sync an encrypted note.

@LiamSwayne LiamSwayne changed the title setting to use .md or .mdenc setting to use .md or .mdenc for live preview formatting of encrypted notes Oct 1, 2023
@Whoareyouagain
Copy link

I second this. It is nice to have a encrypted note but I couldn't use it due to plugins are not detecting the mdenc file as .md thus preventing plugins not to functions within .mdenc.

I have community plugin installed, Advanced Tables. I used this plugin to give me CSV-like view for my tables in source view. There is one table that I want to keep it encrypted and I have over 400 cells in that file. Decrypted note prevents the source view from autoformatting to function which made it a pain to add vertical bar "|" or append a column to 100+ rows automatically. It also prevented Editing Toolbar, another community plugin, to function inside the decrypted source note as well.

I could use in-place option, however the issue is my vault lives in OneDrive folder. Once I decrypt the in-place, the text become plain-text and saved automatically in OneDrive. And OneDrive have file versioning for every revision which defeat the purpose of using Meld Encrypt plugin.

I would like an option to allow the plugins to function in decrypted source view if this is possible.

@azigler
Copy link

azigler commented Oct 19, 2023

Came here to express the same viewpoint as @Whoareyouagain, as the new file format breaks the preview and interferes with how other plugins can be utilized with an encrypted note. @LiamSwayne makes a good point that it also disables file syncing by default.

A setting to toggle between md and mdenc (or set a custom extension entirely) would allow greater flexibility.

@meld-cp
Copy link
Owner

meld-cp commented Oct 21, 2023

Greetings,

Just to clarify the comments by @LiamSwayne & @azigler, 2.3.2 didn't change the extension of encrypted notes from .md to .mdenc, it changed it from .encrypted to .mdenc. Unfortunately, Live Preview has never worked. 😔 but why?

As long as the plugin has to use it's own editor to keep it's contents encrypted on disk, it will never have the same rich editing features of .md notes.

This is also the reason why other plugins aren't compatible.

To make this pain easier, 2.3.0 added a feature to quickly decrypt an encrypted note back to .md. This brings back the rich editing and plugin experience, but with the downside of the note now sitting on disk in plaintext until it's re-encrypted... and, as @Whoareyouagain mentioned, being plaintext for a moment means that it is also open for any backup or file-sync to store it elsewhere.

Unfortunately, I don't have a way around this limitation.

@meld-cp meld-cp added the can't fix Some 3rd party issue or limitation is preventing this issue from being worked on label Oct 21, 2023
@LiamSwayne
Copy link
Contributor Author

Thanks for the clarification

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
can't fix Some 3rd party issue or limitation is preventing this issue from being worked on
Projects
None yet
Development

No branches or pull requests

4 participants