Skip to content

Issue #16243: Remove extra spacing between top image and gray bar in header#16270

Merged
romani merged 1 commit into
checkstyle:masterfrom
SheikhZaeem:remove-top-spacing
Feb 5, 2025
Merged

Issue #16243: Remove extra spacing between top image and gray bar in header#16270
romani merged 1 commit into
checkstyle:masterfrom
SheikhZaeem:remove-top-spacing

Conversation

@SheikhZaeem

Copy link
Copy Markdown
Contributor

This pull request solves the issue #16243 by removing the unnecessary space between top image and the gray bar. It was done by setting the .banner class height to 97px to ensure proper alignment.

Issue Link:
Fixes: #16243

@SheikhZaeem

Copy link
Copy Markdown
Contributor Author

github, generate site

@SheikhZaeem SheikhZaeem changed the title Issue #16243: Remove extra spacing between top image and gray bar in … Issue #16243: Remove extra spacing between top image and gray bar in header Feb 2, 2025
@github-actions

github-actions Bot commented Feb 2, 2025

Copy link
Copy Markdown
Contributor

@SheikhZaeem

SheikhZaeem commented Feb 2, 2025

Copy link
Copy Markdown
Contributor Author

@romani, @Zopsss Should we also move left sidebar up or extend gray area to left?
Screenshot 2025-02-02 at 10 42 55 PM

@romani

romani commented Feb 2, 2025

Copy link
Copy Markdown
Member

Please make it long, whole width, as before. Difference in rendering should be only no white space between image and that panel

@SheikhZaeem

Copy link
Copy Markdown
Contributor Author

Please make it long, whole width, as before. Difference in rendering should be only no white space between image and that panel

Sure

Comment thread src/site/resources/css/site.css Outdated
#banner {
border-bottom: 1px solid #fff;
background: url("../images/header-background.png") repeat-x scroll 0 0 transparent;
height: 97px;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can you tell me how you decided to keep 97px?

IMO you should not give predefined height to HTML elements, there is a chance that it might not work in some devices and it'll give you responsive design issues.

@Zopsss

Zopsss commented Feb 3, 2025

Copy link
Copy Markdown
Member

There is extra spacing between banner and breadcrumbs bar because of extra margins given to CS logo and red line.

Screenshot 2025-02-03 211517
Screenshot 2025-02-03 211532

If you remove these margins the extra spacing also gets removed.

To solve such CSS issues, you can inspect element and see where the issue is coming from, it will help you to fix them more quickly.

@Zopsss

Zopsss commented Feb 3, 2025

Copy link
Copy Markdown
Member

@romani FYI, we had this extra spacing in our old site https://checkstyle.sourceforge.io/version/10.21.1/

Maybe instead of completely removing it, we should decrease its amount.

@Zopsss

Zopsss commented Feb 3, 2025

Copy link
Copy Markdown
Member

@SheikhZaeem try to use following type of PR description: #16213 and after sending PR, leave a comment on issue, similar to: #16077 (comment)

it helps maintainer to know which task you're targeting.

@SheikhZaeem

SheikhZaeem commented Feb 3, 2025

Copy link
Copy Markdown
Contributor Author

@Zopsss Thanks a lot again. I will work on them asap. But can you please again explain the part regarding the PR description.

@SheikhZaeem

SheikhZaeem commented Feb 3, 2025

Copy link
Copy Markdown
Contributor Author

If you remove these margins the extra spacing also gets removed.

@Zopsss Well I cannot remove a margin directly from .h1 as it affects all the elements related to that class. Let me figure out something else.

Screenshot 2025-02-04 at 12 52 08 AM

@SheikhZaeem

Copy link
Copy Markdown
Contributor Author

github, generate site

@github-actions

github-actions Bot commented Feb 5, 2025

Copy link
Copy Markdown
Contributor

@SheikhZaeem

SheikhZaeem commented Feb 5, 2025

Copy link
Copy Markdown
Contributor Author

@romani Well I fixed the problem by removing the h1 margin in the left banner without removing the margin from other places that uses h1 class. Now there is no space between the top image and the content below. However I noticed an additional problem: when we click on the checkstyle image on the top left, it shows something like this:

Screenshot 2025-02-05 at 11 49 11 AM

But this problem was before my changes. If you want I can fix this also. Thank you

@romani

romani commented Feb 5, 2025

Copy link
Copy Markdown
Member

However I noticed an additional problem: when we click on the checkstyle image on the top left, it shows something like this

It is side effect of our AWS temp site. It will work as required in actual release website

@romani romani left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I like a fix.

Thanks a lot.

@Zopsss , please do final review.

@Zopsss

Zopsss commented Feb 5, 2025

Copy link
Copy Markdown
Member

I'm taking back my this statement: #16270 (comment)

Maybe instead of completely removing it, we should decrease its amount.


Old site had this because of some other reasons. It's good that we have fixed it now.

@Zopsss

Zopsss commented Feb 5, 2025

Copy link
Copy Markdown
Member

But can you please again explain the part regarding the PR description.

Check the description of PR I referenced. In there, I have mentioned the task that PR covers. It mentioning the task in description saves some time of maintainers.

@Zopsss Zopsss left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Sorry for the late review, I wasn't active for few days. The CSS LGTM, thanks a lot for the help!

@SheikhZaeem

Copy link
Copy Markdown
Contributor Author

Sorry for the late review, I wasn't active for few days. The CSS LGTM, thanks a lot for the help!

@Zopsss @romani Thanks a lot both of you for feedback. It is my pleasure.

@romani romani merged commit a37f416 into checkstyle:master Feb 5, 2025
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.

Inprove website rendering

3 participants