Skip to content

Add vertical rules to grid module - #15760

Merged
frederickobrien merged 1 commit into
mainfrom
vertical-rules-for-grid-module
Apr 30, 2026
Merged

frederickobrien merged 1 commit into
mainfrom
vertical-rules-for-grid-module

Conversation

@frederickobrien

@frederickobrien frederickobrien commented Apr 28, 2026 •

Copy link
Copy Markdown
Contributor

What does this change?

Branching off of #15428, this adds a verticalRules section to the grid module, allowing for lines to be snapped to their appropriate place in the layout. To be set just as the containers are.

For the outer lines only:

css([grid.container, grid.verticalRules])

Or for the central one too:

css([grid.container, grid.verticalRules({ centre: true })])

After a few iterations I made this something that's pure CSS and baked into the grid module itself. verticalRules adds outer borders, while verticalRules({ centre: true }) adds an additional one to the left hand side of the centre column.

In action over at #15428, which is built on top of this change:

image

@frederickobrien frederickobrien self-assigned this Apr 28, 2026
@frederickobrien frederickobrien added the feature Departmental tracking: work on a new feature label Apr 28, 2026
@github-actions

Copy link
Copy Markdown

Hello 👋! When you're ready to run Chromatic, please apply the run_chromatic label to this PR.

You will need to reapply the label each time you want to run Chromatic.

Click here to see the Chromatic project.

@github-actions

github-actions Bot commented Apr 28, 2026 •

Copy link
Copy Markdown

@frederickobrien
frederickobrien force-pushed the vertical-rules-for-grid-module branch from 5f63f26 to 03f4400 Compare April 28, 2026 13:55
@frederickobrien frederickobrien added this to the Interactives milestone Apr 28, 2026
@frederickobrien
frederickobrien force-pushed the vertical-rules-for-grid-module branch from 03f4400 to 784bb94 Compare April 28, 2026 15:38
@frederickobrien
frederickobrien force-pushed the vertical-rules-for-grid-module branch from 784bb94 to 2ef3374 Compare April 29, 2026 10:19

@JamieB-gu JamieB-gu left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good, a couple of questions.

Comment thread dotcom-rendering/src/grid.ts Outdated
Comment thread dotcom-rendering/src/grid.ts
@frederickobrien
frederickobrien force-pushed the vertical-rules-for-grid-module branch from 2ef3374 to 5abe620 Compare April 30, 2026 10:49
@frederickobrien
frederickobrien merged commit 54c4679 into main Apr 30, 2026
24 checks passed
@frederickobrien
frederickobrien deleted the vertical-rules-for-grid-module branch April 30, 2026 10:59
@gu-prout

gu-prout Bot commented Apr 30, 2026

Copy link
Copy Markdown

Seen on PROD (merged by @frederickobrien 10 minutes and 16 seconds ago) Please check your changes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Departmental tracking: work on a new feature Seen-on-PROD

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants