From a574f9ba152819a52888dedcb3a4f29a413b39f5 Mon Sep 17 00:00:00 2001 From: Kevin Newton Date: Fri, 15 Oct 2021 09:26:46 -0400 Subject: [PATCH] Deprecate a11y emoji --- CHANGELOG.md | 4 ++++ docs/accessible-emoji.md | 2 +- src/rules/accessible-emoji.ts | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6fc73fad..0e9c487c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a ## [Unreleased] +### Changed + +- Deprecate the accessible-emoji rule. See https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/issues/627 for details. + ## [1.1.0] - 2021-10-14 ### Added diff --git a/docs/accessible-emoji.md b/docs/accessible-emoji.md index 4da887a9..30bed5e1 100644 --- a/docs/accessible-emoji.md +++ b/docs/accessible-emoji.md @@ -1,4 +1,4 @@ -# accessible-emoji +# [Deprecated] accessible-emoji Emojis have become a common way of communicating content to the end user. To a person using a screenreader, however, he/she may not be aware that this content is there at all. By wrapping the emoji in a ``, giving it the `role="img"`, and providing a useful description in `aria-label`, the screenreader will treat the emoji as an image in the accessibility tree with an accessible name for the end user. diff --git a/src/rules/accessible-emoji.ts b/src/rules/accessible-emoji.ts index 27d98d7b..9655704f 100644 --- a/src/rules/accessible-emoji.ts +++ b/src/rules/accessible-emoji.ts @@ -15,6 +15,7 @@ const rule: Rule.RuleModule = { docs: { url: makeDocsURL("accessible-emoji") }, + deprecated: true, messages: { default: `Emojis should be wrapped in , have role="img", and have an accessible description with aria-label or aria-labelledby.` }