Repository navigation
Fix service section grid layouts - #8
Closed
diecasting wants to merge 2 commits into
Closed
diecasting wants to merge 2 commits into
diecasting wants to merge 2 commits into
Conversation
- assets/css/custom.css: add 36 Tailwind-equivalent utility classes (py-12/sm:py-16, grid-cols-1/lg:grid-cols-3, gaps, dark variants, etc.) to restore vertical rhythm and card grids on the structured service partials. Root cause: the service section partials were added after the committed Tailwind v4 compiled main.css was generated (no content scan, no CI Tailwind rebuild), so these utilities were absent from the bundle. - config/_default/params.toml: preserve the previously approved showEdit = false (removes visitor-visible edit anchors on service pages). Scope is intentionally minimal: CSS shim only. No partial/template/content/ SEO/analytics/config changes, and main.css is not recompiled here. Known limitations (see PR): 28/35 service pages built & verified locally; die-casting-tooling pages are not built in any language (unverified); a pre-existing mobile overflow on de/cnc-machining (theme text-4xl) is NOT addressed by this patch; production is not yet deployed.
Owner
Author
|
Closing in favor of PR #9. This PR inadvertently bundled PR #7's spacing changes (assets/css/custom.css + config/_default/params.toml) because its head branch was based on feat-service-css-spacing-fix. PR #9 is branched directly off main and contains only the five G1 layout partials, keeping it independent of PR #7. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Five service-section containers (Materials & Alloys, Manufacturing Process, Equipment & Capacity, Quality & Certifications, Technical Resources) were migrated from Tailwind
gridutility classes to the already-existing.hy-grid--2/.hy-grid--3classes defined inassets/css/custom.css.grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3hy-grid hy-grid--3 gap-4grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3hy-grid hy-grid--3 gap-4grid grid-cols-1 gap-4 sm:grid-cols-2hy-grid hy-grid--2 gap-4grid grid-cols-1 gap-8 lg:grid-cols-2hy-grid hy-grid--2 gap-8grid grid-cols-1 gap-8 lg:grid-cols-2hy-grid hy-grid--2 gap-8The
mt-8andgap-4/gap-8utilities are intentionally preserved (the.hy-gridbase rule defines onlydisplay:grid, no gap; the provenrelated-servicesreference keepsgap-4).Root cause
The broken grid was caused by the legacy override rule
main .grid { display: block !important; }inassets/css/custom.css, which outranks the compiled.grid { display: grid; }utility (specificity +!important). It was not caused by the absence of.grid { display: grid; }from the compiled CSS bundle — that rule is present and shipped to production.This is a distinct issue from PR #7, which only restored spacing (
py-12), container width (max-w-5xl), dark-mode variants, andgrid-cols-*definitions but did not restoredisplay:gridand did not touch the legacy override. Therefore this PR is independent of PR #7.Verification
hugo --minify) passes cleanly (exit 0, only.Site.*deprecation warnings).public/against all five service pages at 375 / 768 / 1440 px (light + dark): every target rendersdisplay:gridwith the expected item-aware columns (materials/manufacturing-process: 1 / 2 / 3; equipment/quality-control/technical-resources: 1 / 1 / 2), with no container or document horizontal overflow, no baregridclass remaining, and unchanged homepage /related-servicesgrids.phaseB_plan/G1_implementation_report.md(machine-readable:g1_local_measure.json,analyze_g1_local.py).Notes
equipmentsection intentionally remains single-column at 768px (the.hy-grid--2breakpoint is 1024px). This matches the original single-column-at-tablet behavior ofquality-controlandtechnical-resources.