Skip to content

Commit

Permalink
fix: add a guard & change status message format for api
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-golovanov committed Dec 4, 2024
1 parent c9bcbc0 commit bd066b3
Showing 1 changed file with 9 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ export function Response(props: ResponseProps) {
</Styled.HelpSection>
)}

{response && (
{response && !!currentContentType && (
<Styled.DataContainer
$height={responseTabHeight}
data-testid="t--response-data-container"
Expand All @@ -260,13 +260,15 @@ export function Response(props: ResponseProps) {
$isBold
kind="code"
>
{`${action.name}.run():`}
{`${action.name}.run()${action.pluginType === PluginType.DB ? ":" : ""}`}
</Styled.StatusBarText>
<Styled.StatusBarText
$hasTooltip={!!tooltipContent}
data-testid="t--response-record-count"
kind="code"
>{`${recordCount} record${recordCount > 1 ? "s" : ""}`}</Styled.StatusBarText>
{action.pluginType === PluginType.DB && (
<Styled.StatusBarText
$hasTooltip={!!tooltipContent}
data-testid="t--response-record-count"
kind="code"
>{`${recordCount} record${recordCount > 1 ? "s" : ""}`}</Styled.StatusBarText>
)}
</Styled.StatusBarInfo>
</Tooltip>
<BindDataButton
Expand Down

0 comments on commit bd066b3

Please sign in to comment.