fix(files_sharing): Hide download should not prevent download#50897
fix(files_sharing): Hide download should not prevent download#50897
Conversation
Hide download is meant to hide the download button from the UI not enforce the `download:false` attribute. This commit also modifies the advanced options to only show "Allow download and sync" on public shares. Signed-off-by: nfebe <[email protected]>
| {{ t('files_sharing', 'Hide download') }} | ||
| </NcCheckboxRadioSwitch> | ||
| <NcCheckboxRadioSwitch v-else | ||
| <NcCheckboxRadioSwitch v-if="isPublicShare" |
There was a problem hiding this comment.
This is internal share not public share
There was a problem hiding this comment.
We need a way to users to undo, the effects of the bug introduced by merging hideDownload and download permissions.
Looking at the backend, it is the same control, so I am not sure why there distinction is there and it is needed internally however maybe we can leave it for both?
There was a problem hiding this comment.
Note that apps in the public page used the hideDownload element to know if they should hide the download or not. That element was also removed when the public page was moved to Vue, so the value should be added back somehow. For example, with $this->initialState->provideInitialState('hideDownload', $share->getHideDownload()); in DefaultPublicShareTemplateProvider.php similarly to what was done with the sharingToken value during the migration to Vue. Otherwise even if the download is hidden the apps in the public page would not know it.
Additionally it would be nice if something like isDownloadHidden() or something like that was added to @nextcloud/sharing. However this could be done at a later point, it would not be a must to restore the previous behaviour.
Edit: oh, and the Download button should also be hidden from the public share page :-) That was done in the past but lost with the Vue migration
This comment was marked as off-topic.
This comment was marked as off-topic.
|
Resolved in : #52180 |
Hide download is meant to hide the download button from the UI not enforce the
download:falseattribute.This commit also modifies the advanced options to only show "Allow download and sync" on public shares.
Resolves : #48954