Skip to content

Commit

Permalink
Constrain logo proportions to 200x80 (#461)
Browse files Browse the repository at this point in the history
  • Loading branch information
sneridagh authored Jan 29, 2025
1 parent 44dfdd5 commit 21bb97d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/volto-light-theme/news/461.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Constrain logo proportions to 200x80. @sneridagh
11 changes: 11 additions & 0 deletions packages/volto-light-theme/src/theme/_header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,19 @@
padding-bottom: 35px;

.logo {
max-width: 200px;
max-height: 80px;
flex: 1 1 0;
align-self: center;

a {
display: block;

img {
width: 100%;
height: auto;
}
}
}

.navigation {
Expand Down

1 comment on commit 21bb97d

@acsr
Copy link

@acsr acsr commented on 21bb97d Jan 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am curious why this hard limitation change to autoscale into this box is named "Constrain proportion" and why it ended so small?
Should be "limit logo bounding box to" instead to reflect the purpose/effect better. Constrain proportion means "fixed aspect ratio" to something like the golden ratio 1,618 or 16:9. As long as this is not in the UI and just the commit message, it is not that big problem.

I am here because the change spoiled my recent attempts to work around ;-) and it took me here.

From a designers perspective the aspect ratio of word/image devices can vary a lot and have a visual weigth and balance and safe areas.

The fine adjustment is often be done by placing a transparent element in a safe area frame, but these settings should also be accessible easily as CSS padding. Since the same logo is also present by default in the footer as well, understanding the layout possibilities of this in VLT needs a bit more love by me.

Is there a related option in the upcoming TTW reachable settings?

Please sign in to comment.