Skip to content

Commit

Permalink
refactor(FixedDot): remove redundant isExpanded check for button text
Browse files Browse the repository at this point in the history
  • Loading branch information
TylerAPfledderer committed Aug 29, 2023
1 parent 3966ff8 commit 7643675
Showing 1 changed file with 12 additions and 14 deletions.
26 changes: 12 additions & 14 deletions src/components/FeedbackWidget/FixedDot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,20 +36,18 @@ const FixedDot = ({ bottomOffset, isExpanded, ...props }: FixedDotProps) => {
}}
{...props}
>
{isExpanded && (
<ScaleFade in={isExpanded} delay={0.25}>
<Text
as="span"
fontWeight="bold"
noOfLines={2}
height="100%"
alignItems="center"
display={{ base: "none", lg: isExpanded ? "flex" : "none" }}
>
<Translation id="feedback-widget-prompt" />
</Text>
</ScaleFade>
)}
<ScaleFade in={isExpanded} delay={0.25}>
<Text
as="span"
fontWeight="bold"
noOfLines={2}
height="100%"
alignItems="center"
display={{ base: "none", lg: isExpanded ? "flex" : "none" }}
>
<Translation id="feedback-widget-prompt" />
</Text>
</ScaleFade>
</Button>
)
}
Expand Down

0 comments on commit 7643675

Please sign in to comment.