Skip to content

Commit 036d6a9

Browse files
kangabelldanny-avila
authored andcommitted
a11y: silence miscellaneous icons that should not be read by screen reader (#5723, #5724)
1 parent 1519afd commit 036d6a9

File tree

13 files changed

+15
-14
lines changed

13 files changed

+15
-14
lines changed

client/src/components/Chat/Input/TemporaryChat.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export const TemporaryChat = ({ isTemporaryChat, setIsTemporaryChat }: Temporary
1818
<div className="flex items-start gap-4 py-2.5 pl-3 pr-1.5 text-sm">
1919
<span className="mt-0 flex h-6 w-6 flex-shrink-0 items-center justify-center">
2020
<div className="icon-md">
21-
<MessageCircleDashed className="icon-md" />
21+
<MessageCircleDashed className="icon-md" aria-hidden="true" />
2222
</div>
2323
</span>
2424
<span className="text-token-text-secondary line-clamp-3 flex-1 py-0.5 font-semibold">

client/src/components/Endpoints/MinimalIcon.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ const MinimalIcon: React.FC<IconProps> = (props) => {
6969
<div
7070
data-testid="convo-icon"
7171
title={name}
72+
aria-hidden="true"
7273
style={{
7374
width: size,
7475
height: size,

client/src/components/Input/ModelSelect/TemporaryChat.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export const TemporaryChat = () => {
4343
<div className="sticky bottom-0 border-none bg-surface-tertiary px-6 py-4 ">
4444
<div className="flex items-center">
4545
<div className={cn('flex flex-1 items-center gap-2', isActiveConvo && 'opacity-40')}>
46-
<MessageCircleDashed className="icon-sm" />
46+
<MessageCircleDashed className="icon-sm" aria-hidden="true" />
4747
<span className="text-sm text-text-primary">{localize('com_ui_temporary_chat')}</span>
4848
</div>
4949
<div className="ml-auto flex items-center">

client/src/components/Nav/Bookmarks/BookmarkNav.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ const BookmarkNav: FC<BookmarkNavProps> = ({ tags, setTags, isSmallScreen }: Boo
3535
<div className="h-7 w-7 flex-shrink-0">
3636
<div className="relative flex h-full items-center justify-center rounded-full border border-border-medium bg-surface-primary-alt text-text-primary">
3737
{tags.length > 0 ? (
38-
<BookmarkFilledIcon className="h-4 w-4" />
38+
<BookmarkFilledIcon className="h-4 w-4" aria-hidden="true" />
3939
) : (
40-
<BookmarkIcon className="h-4 w-4" />
40+
<BookmarkIcon className="h-4 w-4" aria-hidden="true" />
4141
)}
4242
</div>
4343
</div>

client/src/components/Prompts/AdminSettings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ const AdminSettings = () => {
153153
variant="outline"
154154
className="mr-2 h-10 w-fit gap-1 border transition-all dark:bg-transparent dark:hover:bg-surface-tertiary sm:m-0"
155155
>
156-
<ShieldEllipsis className="cursor-pointer" />
156+
<ShieldEllipsis className="cursor-pointer" aria-hidden="true" />
157157
<span className="hidden sm:flex">{localize('com_ui_admin')}</span>
158158
</Button>
159159
</OGDialogTrigger>

client/src/components/Prompts/Command.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ const Command = ({
4646
return (
4747
<div className="rounded-xl border border-border-light">
4848
<h3 className="flex h-10 items-center gap-1 pl-4 text-sm text-text-secondary">
49-
<SquareSlash className="icon-sm" />
49+
<SquareSlash className="icon-sm" aria-hidden="true" />
5050
<Input
5151
type="text"
5252
tabIndex={tabIndex}

client/src/components/Prompts/Description.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ const Description = ({
4343
return (
4444
<div className="rounded-xl border border-border-light">
4545
<h3 className="flex h-10 items-center gap-1 pl-4 text-sm text-text-secondary">
46-
<Info className="icon-sm" />
46+
<Info className="icon-sm" aria-hidden="true" />
4747
<Input
4848
type="text"
4949
tabIndex={tabIndex}

client/src/components/Prompts/Groups/CategoryIcon.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,5 +48,5 @@ export default function CategoryIcon({
4848
if (!IconComponent) {
4949
return null;
5050
}
51-
return <IconComponent className={cn(colorClass, className)} />;
51+
return <IconComponent className={cn(colorClass, className)} aria-hidden="true" />;
5252
}

client/src/components/Prompts/PromptVariables.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const PromptVariables = ({
3030
return (
3131
<div className="rounded-xl border border-border-light bg-transparent p-4 shadow-md ">
3232
<h3 className="flex items-center gap-2 py-2 text-lg font-semibold text-text-primary">
33-
<Variable className="icon-sm" />
33+
<Variable className="icon-sm" aria-hidden="true" />
3434
{localize('com_ui_variables')}
3535
</h3>
3636
<div className="flex flex-col space-y-4">

client/src/components/SidePanel/Agents/AdminSettings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ const AdminSettings = () => {
144144
variant={'outline'}
145145
className="btn btn-neutral border-token-border-light relative mb-4 h-9 w-full gap-1 rounded-lg font-medium"
146146
>
147-
<ShieldEllipsis className="cursor-pointer" />
147+
<ShieldEllipsis className="cursor-pointer" aria-hidden="true" />
148148
{localize('com_ui_admin_settings')}
149149
</Button>
150150
</OGDialogTrigger>

0 commit comments

Comments
 (0)