nextcloud / richdocuments

📑 Collabora Online for Nextcloud
https://nextcloud.com/collaboraonline
358 stars 117 forks source link

New document will not open if it is outside the visible file list #1245

Open DmDS opened 4 years ago

DmDS commented 4 years ago

Describe the bug A new document will not open if it is created outside of the visible file list.

To Reproduce Steps to reproduce the behavior:

  1. open a folder with a lot of files. don't scroll down!
  2. create a new document with a name starting with the last letter of alphafit. the document will not open.
  3. scroll down to load the entire filelist. you will find your file.
  4. now create a new file with any name. it will open after creation because the filelist is fully lazyloaded.

Expected behavior New document must open after creation.

Client details:

Server details

Nextcloud version: 19., 20., 21.0.1

Version of the richdocuments app 3..-4.1.0

Version of Collabora Online 6.4.*

Video https://yadi.sk/i/-Fj7qBYaJe4czg the first document was created outside of the visible file list and did not open. the second document opened fine because it was created within the visible list.

Temporary solution disable filelist lazyload ./nextcloud/apps/files/js/filelist.js change var rows = Math.ceil(this.$container.height() / 50); to var rows = Math.ceil(this.$container.height());

DmDS commented 4 years ago

./richdocuments/js/files.js line 86 find {animate:!1,scrollTo:!1}) change scrollTo:!1 to scrollTo:!0 the document will always open after creation. but it will also open the file info panel on the right..

update: sometimes the collabora interface is not displayed correctly

DmDS commented 4 years ago

another solution - disable filelist lazyload ./apps/files/js/filelist.js line 110 var rows = Math.ceil(this.$container.height() / 50); to var rows = Math.ceil(this.$container.height());

juliusknorr commented 4 years ago

I cannot reproduce this yet unfortunately, could you maybe do a quick screen recording so that we can see what exactly happens when?

husisusi commented 4 years ago

I can not reproduce it on nc18.0.10

DmDS commented 4 years ago

https://yadi.sk/i/-Fj7qBYaJe4czg the first file was created outside of the visible file list and did not open. the second file opened fine because it was created within the visible list.

husisusi commented 4 years ago

https://yadi.sk/i/-Fj7qBYaJe4czg the first file was created outside of the visible file list and did not open. the second file opened fine because it was created within the visible list.

Is it possible to try it with nc18.0.10?

DmDS commented 4 years ago

Is it possible to try it with nc18.0.10?

no.... can you search this file (./nextcloud/apps/files/js/filelist.js) for the line in 18.0.10?

var rows = Math.ceil(this.$container.height() / 50);
husisusi commented 4 years ago

can you search this file (./nextcloud/apps/files/js/files.js) for the line in 18.0.10?

There is no "Math.ceil" on 18.0.10 in ./nextcloud/apps/files/js/files.js

DmDS commented 4 years ago

possibly lazy loading is not implemented in 18.0.10 and documents open fine

husisusi commented 4 years ago

I will try to reproduce it on nc 19.x, give me 30 min.

husisusi commented 4 years ago

I was able to reproduce it on nc 19.0.4 and nc 20.0.1. Version 18.0.10 is not affected. I confirm the bug.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

DmDS commented 3 years ago

3.7.13 breaks the opening of new files completely....

drikqlis commented 3 years ago

Can confirm that on 3.7.13 when creating new file you cannot open it - nothing happens. You have to refresh the page and then it is working. Nextcloud 20.0.6, Ubuntu 18.04 LTS, Chrome and Firefox affected.