fix(filemanager): fix invalid uri when using scrolling triggers cursor pagination#330
Merged
HFO4 merged 1 commit intoMar 18, 2026
Conversation
5 tasks
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the FileManager explorer views to generate loading-placeholder items with a cloudreve://-prefixed path (instead of a plain /<id> path), aiming to make placeholder entries compatible with code paths that parse file URIs.
Changes:
- Add
CrUriPrefixusage for loading-placeholderpathgeneration across List, Grid, and Gallery views. - Simplify placeholder
idassignment by reusing the localidvariable.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/component/FileManager/Explorer/ListView/ListBody.tsx | Updates list-view loading placeholder path/id generation to use CrUriPrefix. |
| src/component/FileManager/Explorer/GridView/GridView.tsx | Updates grid-view loading placeholder path/id generation to use CrUriPrefix. |
| src/component/FileManager/Explorer/GalleryView/GalleryView.tsx | Updates gallery-view loading placeholder path/id generation to use CrUriPrefix. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Comment on lines
35
to
40
| const id = `loadingPlaceholder-${pagination.next_token}-${i}`; | ||
| list.push({ | ||
| ...files[0], | ||
| path: "/" + id, | ||
| id: `loadingPlaceholder-${pagination.next_token}-${i}`, | ||
| path: `${CrUriPrefix}${id}`, | ||
| id: id, | ||
| first: i == 0, |
Comment on lines
97
to
103
| file={{ | ||
| ...files[0], | ||
| path: "/" + id, | ||
| id: `loadingPlaceholder-${pagination.next_token}-${i}`, | ||
| path: `${CrUriPrefix}${id}`, | ||
| id: id, | ||
| first: i == 0, | ||
| placeholder: true, | ||
| }} |
Comment on lines
53
to
58
| const id = `loadingPlaceholder-${pagination.next_token}-${i}`; | ||
| list.push({ | ||
| ...files[0], | ||
| path: "/" + id, | ||
| id: `loadingPlaceholder-${pagination.next_token}-${i}`, | ||
| path: `${CrUriPrefix}${id}`, | ||
| id: id, | ||
| first: i == 0, |
HFO4
approved these changes
Mar 18, 2026
Member
|
Thanks! |
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Close cloudreve/cloudreve#3369 (& cloudreve/cloudreve#3368).