Move initialization from helper script to Vue component#1107
Merged
Move initialization from helper script to Vue component#1107
Conversation
6bb5449 to
47f8424
Compare
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
47f8424 to
f93247e
Compare
Member
Author
|
/compile / |
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Member
Author
|
/backport to stable31 |
Member
Author
|
/backport to stable30 |
Member
Author
|
/backport to stable29 |
This was referenced Feb 5, 2025
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.
Requires #1106 and #1108
This is just a refactoring to move the initialization of the PDF.js library from workersrc.js to PDFView.vue. Although this does not (or, at least, should not :-) ) change the behaviour it is a prerequisite to update to PDF.js 4.X, as in that major version it is no longer possible to initialize the library in the helper script (maybe the app is now executed at an earlier point and setting
PDFViewerApplicationOptionsin workersrc.js has no effect because it is already too late, but I have not dived into that).In any case, the refactoring is done in its own separate pull request for clarity and easier reviewing.
Note that the code guarded by
if (hideDownload()) }currently does not work in Nextcloud 31, as when the public share page was moved to Vue thehideDownloadelement was removed. Nevertheless, this should be adjusted somehow in the hideDownload.js file and does not affect the refactoring (it should be adjusted because, although setting Hide download behaves as Disable download in Nextcloud 31 if I am not mistaken the previous behaviour is kept for existing shares until they are updated).