Skip to content

Commit

Permalink
fix: added conditional render for rightAdornment block
Browse files Browse the repository at this point in the history
  • Loading branch information
sunduckcow committed Sep 27, 2023
1 parent 0a870b4 commit 917e5aa
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/components/Settings/Settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -305,9 +305,15 @@ Settings.Item = function SettingsItem({
<span className={b('item-title', {badge: withBadge})}>
{renderTitleComponent(title)}
</span>
<div className={b('item-right-adornment', {hidden: showRightAdornmentOnHover})}>
{renderRightAdornment?.({title})}
</div>
{renderRightAdornment && (
<div
className={b('item-right-adornment', {
hidden: showRightAdornmentOnHover,
})}
>
{renderRightAdornment({title})}
</div>
)}
</Flex>
{description ? <span className={b('item-description')}>{description}</span> : null}
</label>
Expand Down

0 comments on commit 917e5aa

Please sign in to comment.