Skip to content

Target Size: Inline link adjacent to control #5384

Open

Description

@aardrian

Set-up

I have a styled select menu that is 24px in height (and more in width). It satisfies SC 2.5.8 without using any exceptions.

Immediately following (below) the select menu is a sentence of text. That sentence has two links which meet the Inline exception for 2.5.8 when evaluating them against one another.

However, that sentence is positioned close enough (margin 0) to the select menu that the first link butts up against the select menu. The size (18px tall) and position (abutting) mean it cannot satisfy the Spacing exception.

The select menu is not in the sentence, but the Inline exception allows for when the target's "size is otherwise constrained by the line-height of non-target text," seemingly not carving out when the thing it intersects is outside the sentence. In this case, the target is the first link.

Example

Screen shot:
A select menu with a paragraph of text immediately below it, that paragraph containing two links, the first of which butts up to the bottom of the select.

Browsable: https://cdpn.io/aardrian/debug/ByWRWxO

Editable: https://codepen.io/aardrian/pen/ByWRWxO

The Question

Does the first link in the sentence fail under 2.5.8?

Activity

  1. patrickhlauke commented on Sep 29, 2026

    @patrickhlauke
    Member

    my gut feeling (though I can't guarantee that this actually comes out from the normative wording) would be that this scenario FAILs. while the inline exception exempts links "from each other" to an extent (at least that was the high-level rationale at the time, because it was difficult/impossible to make sure there's sufficient spacing etc unless you forced sites to use exceedingly large line spacing/leading), I'd argue it still in practice doesn't exempt them from butting up against things too closely outside of the inline container they're in...

  2. patrickhlauke commented on Sep 29, 2026

    @patrickhlauke
    Member

    this may result in a clarification to understanding (assuming others agree with this interpretation of the edge case)

  3. detlevhfischer commented on Sep 29, 2026

    @detlevhfischer
    Contributor

    Agree with Patrick here. Just to be sure, you are talking about the unexpanded select abutting the text, correct?

  4. aardrian commented on Sep 29, 2026

    @aardrian
    Author

    Just to be sure, you are talking about the unexpanded select abutting the text, correct?

    No, I am asking if the first link (the target) abutting the select fails under 2.5.8.

    The select already passes. The options are under the User Agent Control exemption (assuming that was your ask) and are out of scope for my question anyway.

  5. innoticFR commented on Oct 8, 2026

    @innoticFR

    That’s a very good edge case. On one hand, being stricter when a link is on the first line might not make much sense, since it presents the exact same issue as on any other line. On the other hand, fixing a top margin on the paragraph is much easier and less intrusive than enforcing an unnaturally large line-height.

    A strict interpretation of "in a sentence" could have been that the target must be physically surrounded by the sentence itself on all sides. But then, that would exclude inline short text links on a first line of a paragraph like "pet", where the width itself isn't sufficient to meet the target size anyway.

    I don't have a definitive view on actual non-conformance, but there is certainly a need for clarification to outline best practices.

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    • Status
      To do

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions