my-mind icon indicating copy to clipboard operation
my-mind copied to clipboard

Support for third party formats on WebDAV

Open rosensvv opened this issue 4 years ago • 2 comments

I tried loading and saving a .mm (Freemind) formatted mindmap using the webDAV option, but it doesn't work, it tries to read is as it's native json. It would be really nice if the option to specify a format is also available on the webDAV storage backend, even better if it remembers/autodetects the type (maybe using the file extension?).

rosensvv avatar Nov 15 '21 15:11 rosensvv

Good point. The main question here is what is the preferred detection mechanism:

  1. explicit: show a selectbox so the user can pick one
  2. correct: use the Content-type response header
  3. easy: check the file extension

The first approach gives user the most control, but requires explicit interaction. The second one should be preferred in the theoretical case your WebDAV backend is extra-properly configured and respects mime types for individual mind map formats. I am not even sure they have mime types :)

So we are probably going to end with the last one. Cheers to Redmond! 😃

ondras avatar Nov 16 '21 08:11 ondras

I can only add that maybe it would be a good idea to match the loaded mindmap by default, ie if the user loads a .mm mindmap from a webDAV source, pressing the save icon would default to overwriting the loaded map on the same source, matching the format. If the "save as" prompt is invoked then one can use an explicit selectbox to specify (although the file extension approach is totally valid as well, there should be at least a table of format extensions shown in the same menu).

rosensvv avatar Nov 16 '21 09:11 rosensvv