Skip to content

feat: Implement enhancements for new design #192

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 12 commits into
base: feat/new-design
Choose a base branch
from

Conversation

MoritzWeber0
Copy link
Member

I tried to split the different parts into different commits, so that we can easily take out some individual parts.

Copy link

netlify bot commented Jun 12, 2025

Deploy Preview for fipguide ready!

Name Link
🔨 Latest commit ba78057
🔍 Latest deploy log https://app.netlify.com/projects/fipguide/deploys/68507d8e24bb9f000876ebfe
😎 Deploy Preview https://deploy-preview-192--fipguide.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@fipguide fipguide deleted a comment from netlify bot Jun 12, 2025
@MoritzWeber0 MoritzWeber0 mentioned this pull request Jun 12, 2025
3 tasks
@MoritzWeber0 MoritzWeber0 marked this pull request as ready for review June 12, 2025 20:11
Copy link
Member

@therobrob therobrob left a comment

Choose a reason for hiding this comment

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

i've some questions and comments about your suggestions. to resolve them, it seems cool to talk about it, i think :)

Comment on lines +188 to +196
margin-bottom: 2rem;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 2rem;

@media (max-width: #{$breakpoint-md}) {
display: flex;
flex-direction: column;
}
Copy link
Member

Choose a reason for hiding this comment

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

What added value does it have compared to Bootstrap?

Copy link
Member Author

Choose a reason for hiding this comment

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

I see a few advantages:

  • Reduced bundle size when removing Bootstrap completely, initially discussed here: Check necessity of bootstrap #74 (comment). If we still want to get rid of Bootstrap, I'd slowly decrease the dependency and at least leave it out from newly introduced code.
  • Native DevTools support. Chrome and Firefox have some neat development tools around grid layout. The devtools didn't work with the bootstrap grid layout.
  • Less chance of breaking changes. Bootstrap is under active development and can introduce breaking changes. CSS itself is considered as rather stable.

Comment on lines 222 to 249
.o-startpage__shortcut-wrapper {
display: grid;
grid-template-columns: 1fr 1fr 1fr 3fr;
gap: 2rem;
margin-bottom: 2rem;

@media (max-width: #{$breakpoint-md}) {
display: flex;
flex-wrap: wrap;
gap: 1rem;
}

}

.o-startpage__search {
margin-bottom: 2rem;
width: 100%;
}

.o-startpage__news-teaser-wrapper {
display: grid;
grid-template-columns: 1fr 1fr 1fr;
gap: 2rem;

@media (max-width: #{$breakpoint-md}) {
display: flex;
flex-direction: column;
}
Copy link
Member

Choose a reason for hiding this comment

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

What added value does it have compared to Bootstrap?

Copy link
Member Author

Choose a reason for hiding this comment

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

Some as here: #192 (comment)

Comment on lines +74 to +75
object-fit: cover;
height: 100%;
Copy link
Member

Choose a reason for hiding this comment

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

in my opinion, we should show the images always in aspect-ratio 16/9. Don't you think so?

Copy link
Member Author

Choose a reason for hiding this comment

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

I disagree here :)

Let's have a look at the news list with a viewport that has a width of 850px.

This is the previous version:
image

I can see mainly two issues here:

  1. The images have a small white line at the bottom because they can't fit properly.
  2. The text preview is very limited.

Number 1 is probably easily fixable. Number 2 is more challenging: When I increase the preview lines, the height increases. When we would preserve the image ratio now, the width would also increase and takes away the space that I would use for the content preview.

In the updated version, I have three preview lines. The aspect ratio is not 16:9 anymore, but because of the CSS object-fitting, it just zooms in slightly. Still looks good in my opinion.

image

}

.m-teaser__text {
line-clamp: 3;
Copy link
Member

Choose a reason for hiding this comment

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

in my option, three rows are too much

Copy link
Member Author

Choose a reason for hiding this comment

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

I checked a few blogs and most of them have around 5 lines of preview. Also bahnhof.de has more than three lines in their news:

image

Since our case with "news" is pretty similar, I'd argue that three lines are still ok. Two lines often don't even let the user read the first sentence.

@@ -22,7 +22,7 @@ <h3 class="m-teaser__headline">{{ $page.Title }}</h3>
</a>

<div class="m-teaser__text">
{{ $page.Summary | plainify | truncate 100 }}
{{ partial "strip-material-icons" $page.Summary | plainify | truncate 500 }}
Copy link
Member

Choose a reason for hiding this comment

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

Do we need truncate if we use a line clamp?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes. Line clamp is just a CSS property and doesn't influence the size of the DOM. With truncate, only a part of the content is added to the DOM of the list view. If we don't use it, it would always add the full content, which increases the size of the page slightly.

@MoritzWeber0 MoritzWeber0 requested a review from therobrob June 17, 2025 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants