diff --git a/packages/compass-components/src/components/signal-popover.spec.tsx b/packages/compass-components/src/components/signal-popover.spec.tsx
index 8081cd93066..53150b9be32 100644
--- a/packages/compass-components/src/components/signal-popover.spec.tsx
+++ b/packages/compass-components/src/components/signal-popover.spec.tsx
@@ -51,23 +51,6 @@ describe('SignalPopover', function () {
});
});
- it('should show insights badge text by default if shouldExpandBadge is true', function () {
- const { rerender } = render(
-
- );
-
- // opacity: 0 means that the text will not show up
- expect(screen.getByTestId('insight-badge-text').style.opacity).to.equal(
- '0'
- );
-
- rerender();
- // opacity: 1 means that the text will show up
- expect(screen.getByTestId('insight-badge-text').style.opacity).to.equal(
- '1'
- );
- });
-
describe('SignalHooksProvider', function () {
it('should call hooks through the signal lifecycle', function () {
const hooks: React.ComponentProps = {
diff --git a/packages/compass-components/src/components/signal-popover.tsx b/packages/compass-components/src/components/signal-popover.tsx
index 5940bd355bd..9121e699a95 100644
--- a/packages/compass-components/src/components/signal-popover.tsx
+++ b/packages/compass-components/src/components/signal-popover.tsx
@@ -124,7 +124,6 @@ type SignalPopoverProps = {
darkMode?: boolean;
onPopoverOpenChange?: (open: boolean) => void;
className?: string;
- shouldExpandBadge?: boolean;
};
const signalCardContentStyles = css({
@@ -442,7 +441,6 @@ const SignalPopover: React.FunctionComponent = ({
darkMode: _darkMode,
onPopoverOpenChange: _onPopoverOpenChange,
className,
- shouldExpandBadge,
}) => {
const hooks = useContext(TrackingHooksContext);
const darkMode = useDarkMode(_darkMode);
@@ -455,7 +453,6 @@ const SignalPopover: React.FunctionComponent = ({
const currentSignal = signals[currentSignalIndex];
const multiSignals = signals.length > 1;
const isActive = isHovered || popoverOpen;
- const shouldShowFullBadge = isActive || shouldExpandBadge;
const triggerRef = useRef(null);
@@ -592,7 +589,7 @@ const SignalPopover: React.FunctionComponent = ({
className
),
style: {
- width: shouldShowFullBadge ? activeBadgeWidth : 18,
+ width: isActive ? activeBadgeWidth : 18,
},
ref: triggerRef,
},
@@ -611,7 +608,7 @@ const SignalPopover: React.FunctionComponent = ({
size="small"
className={cx(badgeIconStyles, badgeIconCollapsedStyles)}
data-testid="insight-badge-icon"
- style={{ opacity: shouldShowFullBadge ? 0 : 1 }}
+ style={{ opacity: isActive ? 0 : 1 }}
>
= ({
data-testid="insight-badge-text"
style={{
width: activeBadgeWidth,
- opacity: shouldShowFullBadge ? 1 : 0,
+ opacity: isActive ? 1 : 0,
}}
>
{badgeLabel}
diff --git a/packages/compass-crud/src/components/crud-toolbar.tsx b/packages/compass-crud/src/components/crud-toolbar.tsx
index d6c38c77417..15d425628f4 100644
--- a/packages/compass-crud/src/components/crud-toolbar.tsx
+++ b/packages/compass-crud/src/components/crud-toolbar.tsx
@@ -258,9 +258,7 @@ const CrudToolbar: React.FunctionComponent = ({
onClick={onDeleteButtonClicked}
>
)}
- {insights && (
-
- )}
+ {insights && }