Skip to content
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

Fix SVG text overlap on small screens #1300

Open
wants to merge 1 commit into
base: sepolia
Choose a base branch
from

Conversation

Seapluz
Copy link

@Seapluz Seapluz commented Oct 3, 2024

Issue Description:
There was a bug identified on the Scroll Network frontend where the text overlaps with an SVG on screens smaller than 600px. Specifically, the overlap occurs near the "Mainnet Housewarming Party" section on the index page. On screens that are exactly 600px wide, the issue is not present, but once the screen width drops to 599px or smaller, the text and SVG elements start overlapping, causing display issues.

Fix Description:
To resolve this issue, I modified the CSS for the affected element by adjusting the height. The height of the container holding the SVG was changed to 15rem or higher, ensuring that there is enough space for both the text and the SVG on smaller screens. This change prevents the overlap and provides a more consistent and user-friendly display across different screen sizes.

Here’s the key change applied:

@media (max-width: 600px) { .svg-container { height: 15rem; /* Adjusted to prevent overlap */ margin-top: 20px; /* Added margin to improve spacing */ } }

By making this adjustment, the overlapping issue is fixed, and the layout behaves as expected on smaller screens.

@Seapluz
Copy link
Author

Seapluz commented Oct 3, 2024

Pull Request: Fix for SVG and Text Overlap on Small Screens
Issue:
Fixes #1003: On screens smaller than 600px, the text near "Mainnet Housewarming Party" overlaps with the SVG.

Fix:
I adjusted the height of the SVG container to 15rem for screen sizes below 600px, ensuring enough space for both the text and the SVG. This resolves the overlap issue and improves the overall user experience on smaller screens.

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.

1 participant