When opened in edit session, sidebar and file picker don't work
Describe the bug When opening Text from the desktop file manager, a special session is open which lacks support for the sidebar (clicking the button does nothing) and file picker. The close button also acts a bit odd - well, doesn't really do much at all ;-)
To Reproduce Steps to reproduce the behavior:
- Go to your file manager, go in a Nc synced folder and right-click a markdown file
- From the menu, pick Nextcloud -> edit
Expected behavior Browser shows up. In the browser, editing works, but inserting a image, or linking to a file on Nc, using the sidebar or closing using the close button all don't work.
Nc 20/beta3 on cloud.nc.c
Yep, as discussed already, the sidebar/filepicker will be something very hard to achieve due to the anonymous session that is used for direct editing but I'll look into the close behavior
Yep, as discussed already, the sidebar/filepicker will be something very hard to achieve due to the anonymous session that is used for direct editing but I'll look into the close behavior
At SOME point we'll have to detect the user is logged in and just open the file directly, but the close behavior and hiding the sidebar open button which doesn't work will solve 90% of the problem... Plus, this isn't the highest priority problem. You can edit files, that's what matters.
It's still reproduceable.
At SOME point we'll have to detect the user is logged in and just open the file directly, but the close behavior and hiding the sidebar open button which doesn't work will solve 90% of the problem... Plus, this isn't the highest priority problem. You can edit files, that's what matters.
Yes, if the user is logged in we should definitely just redirect for the desktop case and hide the button otherwise :+1:
Code wise this should be straight forward in https://github.com/nextcloud/text/blob/8cdb2d22fc42c60e03f480b1ddecfe328dbaaf42/lib/DirectEditing/TextDirectEditor.php#L162 to detect if the user is logged in and then just redirect.
For hiding the button we should check if android/iOS is used in the apps web view and if not hide it accordingly:
https://github.com/nextcloud/text/blob/master/src/views/DirectEditing.vue#L32
Might be related to some further standardisation of the direct editing interfaces so partly related to https://github.com/nextcloud/text/issues/1170