Skip to content

fix(ActionList): replace deprecated --control-medium-lineBoxHeight with --base-size-20#7749

Merged
lukasoppermann merged 2 commits into
mainfrom
copilot/remove-control-medium-lineboxheight
Apr 13, 2026
Merged

fix(ActionList): replace deprecated --control-medium-lineBoxHeight with --base-size-20#7749
lukasoppermann merged 2 commits into
mainfrom
copilot/remove-control-medium-lineboxheight

Conversation

Copilot AI commented Apr 13, 2026

Copy link
Copy Markdown
Contributor

--control-medium-lineBoxHeight is being deprecated/removed. Two references existed in ActionList.module.css — one active, one already commented out.

Changelog

Changed

  • .VisualWrap: min-height: var(--control-medium-lineBoxHeight)min-height: var(--base-size-20) (same 20px value via stable base token)

Removed

  • Orphaned commented-out line-height: calc(var(--control-medium-lineBoxHeight) - var(--base-size-2)) and its associated stale comment in the inline description rule

Rollout strategy

  • Patch release
  • Minor release
  • Major release; if selected, include a written rollout or migration plan
  • None; if selected, include a brief description as to why

Testing & Reviewing

CSS-only token swap with no visual change — --control-medium-lineBoxHeight and --base-size-20 both resolve to 20px. The existing line-height: 20px fallback directly below confirms the value.

Merge checklist

Original prompt

Problem

The CSS variable --control-medium-lineBoxHeight is used (and referenced in a comment) in packages/react/src/ActionList/ActionList.module.css. This variable is being removed/deprecated and should no longer be used.

There are two occurrences in the file:

  1. Line 654 — inside .ItemDescriptionWrap [data-description-variant='inline'] .Description: already commented out, referencing --control-medium-lineBoxHeight in a comment:

    /* line-height: calc(var(--control-medium-lineBoxHeight) - var(--base-size-2)); */
  2. Line 679 — inside .VisualWrap: an active usage as min-height:

    min-height: var(--control-medium-lineBoxHeight);

What to do

In packages/react/src/ActionList/ActionList.module.css:

  1. Line 679 (.VisualWrap): Replace the active usage:

    min-height: var(--control-medium-lineBoxHeight);

    with:

    min-height: var(--base-size-20);

    The value of --control-medium-lineBoxHeight is {base.size.20} (20px), which maps directly to --base-size-20. The existing /* stylelint-disable-next-line primer/typography */ comment and the line-height: 20px directly below confirm this is the correct value.

  2. Line 654 (.ItemDescriptionWrap): Remove the commented-out line that references --control-medium-lineBoxHeight entirely, since it is already commented out and no longer needed:

    /* line-height: calc(var(--control-medium-lineBoxHeight) - var(--base-size-2)); */

    Delete this line (and the /* adjust line-height for baseline alignment */ comment above it if it becomes orphaned/unnecessary).

No other files in this repo use control-medium-lineBoxHeight.

The following is the prior conversation context from the user's chat exploration (may be truncated):

User: Search github/github, github/github-ui and primer/react for any occurence of teh css variables:

control-xsmall-lineBoxHeight
control-small-lineBoxHeight
control-medium-lineBoxHeight
control-large-lineBoxHeight
control-xlarge-lineBoxHeight

Return a list of search links for each repo as links with the name X results found for $variableName in $repo

Assistant: Here are the search results for each CSS variable across the three repos:


control-xsmall-lineBoxHeight

control-small-lineBoxHeight

control-medium-lineBoxHeight

control-large-lineBoxHeight

control-xlarge-lineBoxHeight


Summary: The only usage found is control-medium-lineBoxHeight in primer/react — appearing twice in [ActionList.module.css](https:/...

This pull request was created from Copilot chat.

@changeset-bot

changeset-bot Bot commented Apr 13, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 710e7f2

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

…tionList.module.css

Agent-Logs-Url: https://github.com/primer/react/sessions/ed5c13db-c002-40c4-8014-96b97073c148

Co-authored-by: lukasoppermann <813754+lukasoppermann@users.noreply.github.com>
Copilot AI changed the title [WIP] Remove deprecated CSS variable --control-medium-lineBoxHeight fix(ActionList): replace deprecated --control-medium-lineBoxHeight with --base-size-20 Apr 13, 2026
Copilot AI requested a review from lukasoppermann April 13, 2026 08:34
@lukasoppermann
lukasoppermann marked this pull request as ready for review April 13, 2026 08:58
@lukasoppermann
lukasoppermann requested a review from a team as a code owner April 13, 2026 08:58
@github-actions github-actions Bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Apr 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Action required

👋 Hi, this pull request contains changes to the source code that github/github-ui depends on. If you are GitHub staff, test these changes with github/github-ui using the integration workflow. Check the integration testing docs for step-by-step instructions. Or, apply the integration-tests: skipped manually label to skip these checks.

To publish a canary release for integration testing, apply the Canary Release label to this PR.

Copilot AI 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.

Pull request overview

Removes usage of a deprecated Primer control line-box-height token from ActionList styles by switching to a stable base size token, keeping the rendered size the same.

Changes:

  • Replaced .VisualWrap min-height from --control-medium-lineBoxHeight to --base-size-20.
  • Deleted an orphaned commented-out line-height rule (and its associated comment) that referenced the deprecated token.
Show a summary per file
File Description
packages/react/src/ActionList/ActionList.module.css Swaps deprecated token usage to a stable base token and removes stale commented-out reference.

Copilot's findings

  • Files reviewed: 1/1 changed files
  • Comments generated: 0

@github-actions
github-actions Bot temporarily deployed to storybook-preview-7749 April 13, 2026 09:09 Inactive
@lukasoppermann lukasoppermann added skip changeset This change does not need a changelog Canary Release Apply this label when you want CI to create a canary release of the current PR labels Apr 13, 2026
@primer-integration

Copy link
Copy Markdown

👋 Hi from github/github-ui! Your integration PR is ready: https://github.com/github/github-ui/pull/18417

@primer-integration

Copy link
Copy Markdown

Integration test results from github/github-ui:

Passed  CI   Passed
Passed  VRT   Passed
Passed  Projects   Passed

All checks passed!

@lukasoppermann
lukasoppermann added this pull request to the merge queue Apr 13, 2026
Merged via the queue into main with commit 94c96a4 Apr 13, 2026
72 of 73 checks passed
@lukasoppermann
lukasoppermann deleted the copilot/remove-control-medium-lineboxheight branch April 13, 2026 10:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Canary Release Apply this label when you want CI to create a canary release of the current PR integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm skip changeset This change does not need a changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants