From 4b65760a1dc87fc8930520fc18340c3d16ccbe8d Mon Sep 17 00:00:00 2001 From: SATYA SB <107645008+satya07sb@users.noreply.github.com> Date: Tue, 11 Mar 2025 12:31:51 +0530 Subject: [PATCH] [accessibility-3554312-3560235]:[Screen reader - Cosmos DB Query Copilot - Query Faster with Copilot>Enable Query Advisor]: Screen reader does not announce the associated text information when focus lands on the 'Like/Dislike' button. (#2067) Co-authored-by: Satyapriya Bai --- src/Common/Constants.ts | 4 ++++ .../QueryCopilot/QueryCopilotPromptbar.tsx | 14 ++++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/Common/Constants.ts b/src/Common/Constants.ts index 840849904..94ca16c27 100644 --- a/src/Common/Constants.ts +++ b/src/Common/Constants.ts @@ -530,6 +530,10 @@ export class ariaLabelForLearnMoreLink { public static readonly AzureSynapseLink = "Learn more about Azure Synapse Link."; } +export class FeedbackLabels { + public static readonly provideFeedback: string = "Provide feedback"; +} + export const QueryCopilotSampleDatabaseId = "CopilotSampleDB"; export const QueryCopilotSampleContainerId = "SampleContainer"; diff --git a/src/Explorer/QueryCopilot/QueryCopilotPromptbar.tsx b/src/Explorer/QueryCopilot/QueryCopilotPromptbar.tsx index 1582a4335..830eb5196 100644 --- a/src/Explorer/QueryCopilot/QueryCopilotPromptbar.tsx +++ b/src/Explorer/QueryCopilot/QueryCopilotPromptbar.tsx @@ -18,7 +18,7 @@ import { Text, TextField, } from "@fluentui/react"; -import { HttpStatusCodes, NormalizedEventKey } from "Common/Constants"; +import { FeedbackLabels, HttpStatusCodes, NormalizedEventKey } from "Common/Constants"; import { handleError } from "Common/ErrorHandlingUtils"; import QueryError, { QueryErrorSeverity } from "Common/QueryError"; import { createUri } from "Common/UrlUtility"; @@ -579,7 +579,7 @@ export const QueryCopilotPromptbar: React.FC = ({ {userContext.feedbackPolicies?.policyAllowFeedback && ( - Provide feedback + {FeedbackLabels.provideFeedback} {showCallout && !hideFeedbackModalForLikedQueries && ( = ({ { setShowCallout(!likeQuery); @@ -648,8 +649,9 @@ export const QueryCopilotPromptbar: React.FC = ({ /> { let toggleStatusValue = "Unpressed";