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

Load custom CSS #324

Merged
merged 1 commit into from
Apr 10, 2024
Merged

Load custom CSS #324

merged 1 commit into from
Apr 10, 2024

Conversation

MoltonMontro
Copy link
Member

conf.py would now be able to load custom CSS and JS from _static.

Currently, css/custom.css is loaded. The only styling rule is to add word-wrapping to tables (on desktop monitors, i.e. where horizontal scrollbars are undesirable).

@SDGNelson
Copy link
Member

For comparison I checked the tables on the Gun Asset page:
with custom style
without custom style

It looks to me like it may have had an unintended effect: With the page at full size the Requires_NonZero_Attachment_Caliber name is wrapping the 'r' to a new line. Shrinking the page width it does appear to be removing the horizontal scrollbar as-intended, however.

I'm not sure I understand about the intention though: I see the page width threshold is 769 px. I would guess most desktop users have screens wider than that, IIRC the Steam Hardware Survey reports 1920x1080 as the most common resolution. What's your thought process behind the change?

@MoltonMontro
Copy link
Member Author

MoltonMontro commented Apr 10, 2024

For @media query breakpoints, a min-width of 769px would be the start of laptops / small screens (going larger). Basically, most non-touch devices (where horizontal scrolling is more likely to cause information to be missed).

These commits were part of a separate PR, but I broke them off because they felt tangential. The original PR was expanding on introductory articles, and some revisions had tables where horizontal scrollbars would've been unavoidable. E.g., moving launch options into tables a la Godot or Unity.

My assumption is that the table column widths specified are too small for that column, causing it wrap instead of automatically adjust these widths. 😞

Technically we could just strip all manually-specified column widths, or adjust them as needed, or just have a custom class to add wrapping to tables that would want it. But the CSS file included here is definitely more proactive than reactive (no current content should need it, at 1920x1080px screens).

Unsure where to go from here with the PR. Maybe close for now, or I could strip the one CSS rule (leaving the file blank)?

@MoltonMontro
Copy link
Member Author

MoltonMontro commented Apr 10, 2024

New push comments out this styling rule (for now?). May revisit in the future.

@SDGNelson SDGNelson merged commit 30e63c4 into SmartlyDressedGames:latest Apr 10, 2024
2 checks passed
@MoltonMontro MoltonMontro deleted the css branch April 11, 2024 00:58
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.

None yet

2 participants