Skip to content
easeweb
Search topics

Button labels cut off when people widen text spacing

Buttons with a fixed height, a single line and hidden overflow can't make room for a label that wider spacing makes longer, so the label is cut short.

WCAG 2.2
SC 1.4.12AA· new in 2.1
Required by
EN 301 549 (EU)
Broken
Spaced out, the end of the label is cut off.
The accessibility problem illustrated.
01

The problem

People who widen letter and word spacing to read more easily can't read button labels that a fixed-size button cuts short.

02

Try it

Widen the text spacing and read the buttons.

Turn on Text spacing: line height 1.5, letter spacing 0.12em, word spacing 0.16em and paragraph spacing 2em. Can you still read both buttons in full?

Broken Can you fix this?

Cast iron skillet, 26 cm

49.00

A recreated demo. The broken version is intentionally inaccessible.

03

The fix

Give buttons a minimum height and padding instead of a fixed box, and let the label or the row wrap.

  1. 1Give buttons and tabs a min-height and padding, never a fixed height.
  2. 2Let a label wrap, or its row wrap, rather than cutting it with an ellipsis.
  3. 3Never set line, letter or word spacing inline with !important.
Before Buttons with a fixed size and one line
<div class="buy-row">  <button type="submit" class="button"><span class="button-label">Add to basket</span></button>  <button type="button" class="button button-secondary"><span class="button-label">Buy it now</span></button></div>
After

Let the label wrap

<div class="buy-row">  <button type="submit" class="button"><span class="button-label">Add to basket</span></button>  <button type="button" class="button button-secondary"><span class="button-label">Buy it now</span></button></div>

Fixing this with an AI coding assistant? Get this guide as Markdown

04

Verify the fix

5 checks, no mouse.

Test with: Text spacing

0 of 5 checked

Record the OS, browser and assistive-technology versions, the build, the date, and the actual result of each step. Repeat after the button component or theme changes.

Limits

This is a starting pattern, not a guarantee for every application. 1.4.12 asks only that content survives the four values; it doesn't require a site to offer spacing controls of its own. Some content is exempt, such as text in images and captions burned into video. Class names in the snippets are placeholders. Test every template that has controls, not only the product page.

This is a recreated teaching example, not a finding about a named client. The code is a starting pattern: test it in your own product. No completed assistive-technology test is claimed here.

Keep this fixed as your code changes.

Turn guides like this into rules your coding agents and CI follow, then have the result retested with a keyboard and screen readers.

How retests work