From a78a8c4a94a8681ce51d0742c83ed07e4a794622 Mon Sep 17 00:00:00 2001 From: Brad Ullman Date: Tue, 28 Mar 2023 01:35:57 -0700 Subject: [PATCH] make all chat area components tabbable (accessibility) (#246) * make all chat area components tabbable * align message role description * remove inline styles on icons * remove inline styles on icons --- components/Chat/Chat.tsx | 15 ++++----- components/Chat/ChatInput.tsx | 19 +++++------ components/Chat/ChatMessage.tsx | 52 ++++++++++++++++++------------- components/Chat/CopyButton.tsx | 25 --------------- components/Chat/ModelSelect.tsx | 2 +- components/Chat/PromptList.tsx | 8 +---- components/Chat/Regenerate.tsx | 4 +-- components/Chat/SystemPrompt.tsx | 2 +- components/Chatbar/Chatbar.tsx | 6 ++-- components/Markdown/CodeBlock.tsx | 8 ++--- pages/index.tsx | 33 ++++++++++++-------- tailwind.config.js | 5 +++ 12 files changed, 83 insertions(+), 96 deletions(-) delete mode 100644 components/Chat/CopyButton.tsx diff --git a/components/Chat/Chat.tsx b/components/Chat/Chat.tsx index bd854cf..de4d46c 100644 --- a/components/Chat/Chat.tsx +++ b/components/Chat/Chat.tsx @@ -217,16 +217,17 @@ export const Chat: FC = memo( <>
{t('Model')}: {conversation.model.name} - - + + +
{showSettings && (
diff --git a/components/Chat/ChatInput.tsx b/components/Chat/ChatInput.tsx index 618db80..8f748f5 100644 --- a/components/Chat/ChatInput.tsx +++ b/components/Chat/ChatInput.tsx @@ -237,28 +237,26 @@ export const ChatInput: FC = ({
{messageIsStreaming && ( )} {!messageIsStreaming && !conversationIsEmpty && ( )} -
+