-
Notifications
You must be signed in to change notification settings - Fork 159
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
Added file previews #3187
Added file previews #3187
Conversation
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
24dfe94
to
00d97cf
Compare
Previews do work when I scroll over the same element at least once. |
2fbdb54
to
445ec41
Compare
|
445ec41
to
ba359d1
Compare
added tests but discovered some new issues:
|
ba359d1
to
1c419d9
Compare
and now the lorem file is locked. |
1c419d9
to
e530fbd
Compare
rebased |
Seems master is all green #3202 So there is something I changed here that is causing new side effects 😢 |
seems there's a locking issue. waiting for previews to always load is not a good idea as we need to use a delay, it will slow down the tests. idea: add a hidden loading indicator, maybe "data-loading" on the preview while the media source is running, so that the tests know that they need to wait longer. |
or use |
Added |
Pls post a screenshot into description |
5d14937
to
05107ac
Compare
adjusted and rebased |
4f950c4
to
cc77caf
Compare
while trying to debug the tests I found more issues which are fixed now:
However there are still these issues:
|
e905d33
to
09aeb74
Compare
Seems that The code is in the right place: https://github.com/owncloud/phoenix/blob/filelist-previews/tests/acceptance/stepDefinitions/filesContext.js#L114 I've now added an extra 1 second delay after waiting, just in case the file locks need more time to release themselves... |
now debugging waitForAllThumbnailsLoaded, seems the selector is not working because the attribute is missing when "previewLoaded" is false ?! |
09aeb74
to
d38cfa2
Compare
okay, seems Vue.js doesn't render HTML attributes if their value is boolean false. Had to set it to the string let's see... |
d38cfa2
to
7ebf071
Compare
I had an explicit check for a file entry in the file list with "upload overwrite" but doesn't cover all cases. We anyway don't need it any more due to the global waiting. So I've added "user browses to files page" before all the overwrite cases. Squashed |
💥 Acceptance tests webUIOCIS failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/9034/
|
Added new component FileItem wrapped around oc-file to better encapsulated the formatting methods as computed properties instead of using the mixin. Added preview support in file list loaded using mediaSource.
7ebf071
to
59b1fd2
Compare
added a few more fixes. |
💥 Acceptance tests webUIOCIS failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/9036/
|
When displaying the file list or scrolling down to formerly invisible resources, wait for ajax calls to make sure the mediaSource and preview loading call has ended before performing any operations. This is to avoid running into file lock issues while loading the previews.
59b1fd2
to
6518128
Compare
almost all green, I've pushed one last fix. the OCIS tests fail, especially the ones related to thumbnail. Not sure if the thumbnailer service is already in place ? if not, we should skip them. do you mind having a look @dpakach ? |
💥 Acceptance tests webUIOCIS failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/9037/
|
@PVince81, I think we can skip the tests on ocis until we properly implement thumbnail service in CI. |
@@ -69,6 +69,7 @@ Feature: Sharing files and folders with internal groups | |||
When the user renames file "lorem.txt" to "new-lorem.txt" using the webUI | |||
And the user shares file "new-lorem.txt" with group "grp1" as "Editor" using the webUI | |||
And the user re-logs in as "user1" using the webUI | |||
And the user browses to the files page |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we call waitTillThumbnailsLoaded
function in the user has logged in
or user has re-logged in
step.
That way we can avoid having user has browsed to the files page
everywhere after logging in.
The CI has passed but I restarted just to make sure it is stable |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good. If you're okay with tests @individual-it @dpakach feel free to merge 😉
if (this.item.etag) { | ||
// add etag for URL based caching | ||
// strip double quotes from etag | ||
query.c = this.item.etag.substr(2, this.item.etag.length - 2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@LukasHirt, oh no here is a bug..
the substr
should be substr(1, this.item.etag.length - 2)
or else it will cut of the first character. :/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for catching that! I'll open a PR with fix and ping you for review 😉
Description
Related Issue
Part of #276
Motivation and Context
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist:
Open tasks: