From 5ed7352359a4093a11cf2eb7bc7ae9a828381e83 Mon Sep 17 00:00:00 2001 From: Jay Sitter Date: Sat, 24 Jun 2023 01:58:21 -0400 Subject: [PATCH] fix: Emoji picker can be closed with escape key, other a11y fixes --- .eslintrc.json | 2 -- src/assets/css/main.css | 3 ++- src/shared/components/app/navbar.tsx | 2 +- src/shared/components/common/emoji-picker.tsx | 13 +++++++++++-- 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 598b7f3f..f82e6b06 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -26,9 +26,7 @@ "jsx-a11y/aria-activedescendant-has-tabindex": 1, "jsx-a11y/aria-role": 1, "jsx-a11y/click-events-have-key-events": 1, - "jsx-a11y/iframe-has-title": 1, "jsx-a11y/interactive-supports-focus": 1, - "jsx-a11y/no-redundant-roles": 1, "jsx-a11y/no-static-element-interactions": 1, "jsx-a11y/role-has-required-aria-props": 1, "curly": 0, diff --git a/src/assets/css/main.css b/src/assets/css/main.css index d61dafda..6c739549 100644 --- a/src/assets/css/main.css +++ b/src/assets/css/main.css @@ -124,7 +124,8 @@ .emoji-picker-container { position: absolute; - top: 30px; + top: 0; + left: 50%; z-index: 1000; transform: translateX(-50%); } diff --git a/src/shared/components/app/navbar.tsx b/src/shared/components/app/navbar.tsx index 2ede00e1..d25254e3 100644 --- a/src/shared/components/app/navbar.tsx +++ b/src/shared/components/app/navbar.tsx @@ -349,8 +349,8 @@ export class Navbar extends Component { {person && (