Skip to content

Commit

Permalink
Merge pull request #611 from nextcloud/fix/take_whole_height
Browse files Browse the repository at this point in the history
  • Loading branch information
skjnldsv committed Jun 23, 2022
2 parents 641d8ea + 4448a5f commit 9f6eb39
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions js/files_pdfviewer-public.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/files_pdfviewer-public.js.map

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions src/public.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ window.addEventListener('DOMContentLoaded', function() {
const contentElmt = document.getElementById('files-public-content')
const sharingTokenElmt = document.getElementById('sharingToken')
const footerElmt = document.querySelector('body > footer')
const mainContent = document.querySelector('#content')

const sharingToken = sharingTokenElmt.value
const downloadUrl = generateUrl('/s/{token}/download', { token: sharingToken })
Expand All @@ -67,6 +68,7 @@ window.addEventListener('DOMContentLoaded', function() {
contentElmt.appendChild(viewerNode)
viewerNode.src = viewerUrl
footerElmt.style.display = 'none'
mainContent.style.minHeight = '100%' // Make the viewer take the whole height as the footer is now hidden.
} else {
logger.error('Unable to inject the PDF Viewer')
}
Expand Down

0 comments on commit 9f6eb39

Please sign in to comment.