Problem/Motivation

The display headings do not match the brand stylesheet (VBN — Stylesheet, Foundation page, 04 - Display):

  • Desktop tracking is missing. Desktop/Display/D1 to D6 carry a letter-spacing of -2% (Figma renders D1 at -1.08px on 54px). The theme sets none.
  • There is no mobile display scale. The design specifies Mobile/Display/D1 to D6 as 44 / 36 / 30 / 24 / 20 / 16 px. The theme leaves this to Bootstrap RFS, whose fluid sizes land well below the design on a phone: .display-1 computes to about 33px at 375px against 44px.

Out of scope for #3620731, which covers headings and body styles only.

Steps to reproduce

  1. Render an element with class="display-1" on a site using Vartheme BS5 Rightup.
  2. At 1400px, computed letter-spacing is normal (design: -0.02em).
  3. At 375px, computed font-size is about 33px (design: 44px).

Proposed resolution

  • Add the mobile display steps to the existing media-breakpoint-down(md) type scale in scss/base/vartheme.base.scss. vartheme.base.css loads after bootstrap.base.css at the same specificity, so these win over RFS.
  • Add letter-spacing: -0.02em to .display-1 to .display-6 at md and up. em keeps it at -2% of whatever size resolves.

Builds on the #3620731 branch, because it extends that issue's mobile block.

Measured before and after

Same page and same theme in both halves of each image. The after half is the merge request's own compiled css/base/vartheme.base.css and components/base/root/root.css, loaded after the shipping stylesheets so the cascade matches what the branch would serve. The figure at the right of each row is the computed font-size and letter-spacing read back from the browser, not a design annotation.

Desktop, 1920px. Every step gains -2% tracking. On the 54px .display-1 that computes to -1.08px, which is what the design shows:

Only local images are allowed.

Mobile, 375px. The steps move off RFS onto the design's scale — 44 / 36 / 30 / 24 / 20 / 16px, where RFS resolved .display-1 to 32.96px. Tracking stays normal here, because the design tracks the displays only from md up:

Only local images are allowed.

Remaining tasks

  • ✅ File an issue
  • ✅ Addition/Change/Update/Fix
  • ❌ Testing to ensure no regression
  • ➖ Automated unit/functional testing coverage
  • ➖ Developer Documentation support
  • ➖ User Guide Documentation support
  • ❌ UX/UI designer responsibilities
  • ➖ Accessibility and Readability
  • ❌ Reviewed by a human
  • ❌ Code review by maintainers
  • ❌ Full testing and approval
  • ❌ Credit contributors
  • ❌ Review with the product owner
  • ✅ Update Release Notes
  • ✅ Release

User interface changes

Display headings get -2% tracking on desktop and the design's smaller sizes on phones.

API changes

N/A

Data model changes

N/A

Release notes snippet

Display headings now follow the brand stylesheet: -2% letter-spacing on desktop and the mobile display scale on phones.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

rajab natshah created an issue. See original summary.

rajab natshah’s picture

Status: Active » Needs review

Opened !11.

  • .display-1 to .display-6 get letter-spacing: -0.02em at md and up.
  • The design's mobile display steps (44 / 36 / 30 / 24 / 20 / 16 px) are added to the existing mobile type scale. They win over RFS because vartheme.base.css loads after bootstrap.base.css at the same specificity.
  • The compiled diff is exactly those rules in css/base/vartheme.base.css.

The branch builds on #3620731 (!8), so until !8 merges, !11's diff includes its commits; the change specific to this issue is ce0b02d.

On #3620731 (!8), the lead weight is also corrected to the design's Regular 400 (52d40d2): Figma binds Lead to Body/Regular/Large.

rajab natshah’s picture

Issue summary: View changes

  • rajab natshah committed a75c1f6d on 1.0.x
    fix: #3622269 Add the design's desktop display tracking and mobile...
rajab natshah’s picture

Assigned: rajab natshah » Unassigned
Issue summary: View changes
Status: Needs review » Fixed
Issue tags: +vartheme_bs5_rightup-1.0.0-alpha1

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

rajab natshah’s picture

Issue summary: View changes

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.