Problem/Motivation

DSFR 1.15.4 renders the non-clickable tags of a tags group as span instead of p, as the tag accessibility doc already asked: "Si le tag est utilisé à l’intérieur d’un élément qui possède une sémantique (<p>, li), utiliser un élément <span>."

Upstream: fix(tag): utilisation de span dans groupe de tags https://github.com/GouvernementFR/dsfr/pull/1539 (shipped in 1.15.4, missing from the changelog).

Proposed resolution

We could do as for the badge:
- components/tag: a new tag prop, p (default) or span, for tags without URL that are neither dismissible nor pressable. Clickable tags stay a link, the others stay a button.
- components/tag_group: the slot description asks for span.
- The stories that put tags in a group set span: tag_group, card, tile, grid_row.

API changes

New tag prop on the tag component. The default markup does not change.

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

just_like_good_vibes created an issue. See original summary.

just_like_good_vibes’s picture

just_like_good_vibes’s picture

Issue summary: View changes

just_like_good_vibes’s picture

Assigned: just_like_good_vibes » Unassigned
Status: Active » Fixed

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.

Status: Fixed » Closed (fixed)

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