Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Improve layout for the public download page
This centers the content inside the pages, while also not hardcoded the
size of the footer.

Signed-off-by: Carl Schwan <[email protected]>
  • Loading branch information
CarlSchwan authored and backportbot[bot] committed Jan 14, 2022
commit 30decc3ed1f6c15a799278274cf1a75776441b56
2 changes: 1 addition & 1 deletion apps/files_sharing/templates/public.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
<?php if ($_['previewURL'] === $_['downloadURL'] && !$_['hideDownload']): ?>
<div class="directDownload">
<div>
<?php p($_['filename'])?> (<?php p($_['fileSize']) ?>)
<?php p($_['filename'])?>&nbsp;(<?php p($_['fileSize']) ?>)
</div>
<a href="<?php p($_['downloadURL']); ?>" id="downloadFile" class="button">
<span class="icon icon-download"></span>
Expand Down
31 changes: 21 additions & 10 deletions core/css/public.scss
Original file line number Diff line number Diff line change
@@ -1,8 +1,25 @@
$footer-height: 65px;

#body-public {
.header-right {
min-height: 100vh;
display: flex;
flex-direction: column;

#content {
flex-grow: 2;
min-height: initial;

/** Center the shared content inside the page */
&.app-files_sharing {
justify-content: center;
align-items: center;
#app-content {
min-height: inherit;
padding-left: 1rem;
padding-right: 1rem;
}
}
}

.header-right {
#header-primary-action a {
color: var(--color-primary-text);
}
Expand Down Expand Up @@ -35,12 +52,6 @@ $footer-height: 65px;
}
}

#content {
// 100% - footer
min-height: calc(100% - #{$footer-height});

}

/** don't apply content header padding on the base layout */
&.layout-base #content {
padding-top: 0;
Expand Down Expand Up @@ -72,8 +83,8 @@ $footer-height: 65px;
display: flex;
align-items: center;
justify-content: center;
height: $footer-height;
flex-direction: column;
padding: 0.5rem;
p {
text-align: center;
color: var(--color-text-lighter);
Expand Down