Skip to content

Commit 8574027

Browse files
Prevents inactive indicator icon/tooltip from appearing in ActionMenu items (#4770)
* prevents inactive indicator icon/tooltip from appearing in ActionMenu items * adds changeset * test(vrt): update snapshots --------- Co-authored-by: broccolinisoup <[email protected]>
1 parent 533f997 commit 8574027

11 files changed

+7
-2
lines changed

.changeset/curvy-shrimps-agree.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@primer/react': patch
3+
---
4+
5+
Prevents inactive indicator icon/tooltip from appearing in ActionMenu items

packages/react/src/ActionList/Item.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ export const Item = React.forwardRef<HTMLLIElement, ActionListItemProps>(
345345
<ItemWrapper {...wrapperProps}>
346346
<Selection selected={selected} />
347347
<VisualOrIndicator
348-
inactiveText={inactiveText}
348+
inactiveText={showInactiveIndicator ? inactiveText : undefined}
349349
itemHasLeadingVisual={Boolean(slots.leadingVisual)}
350350
labelId={labelId}
351351
loading={loading}
@@ -386,7 +386,7 @@ export const Item = React.forwardRef<HTMLLIElement, ActionListItemProps>(
386386
{slots.inlineDescription}
387387
</ConditionalWrapper>
388388
<VisualOrIndicator
389-
inactiveText={inactiveText}
389+
inactiveText={showInactiveIndicator ? inactiveText : undefined}
390390
itemHasLeadingVisual={Boolean(slots.leadingVisual)}
391391
labelId={labelId}
392392
loading={loading}

0 commit comments

Comments
 (0)