|
@@ -46,11 +46,19 @@ const LogBucketCard: React.FunctionComponent<LogBucketCardProps> = ({
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
useEffect(() => {
|
|
useEffect(() => {
|
|
|
- if (isExpanded && (!Array.isArray(logs) || !logs.length)) {
|
|
|
|
|
|
|
+ if (!Array.isArray(logs) || !logs.length) {
|
|
|
getLogsForBucket();
|
|
getLogsForBucket();
|
|
|
}
|
|
}
|
|
|
}, [currentProject, currentCluster, logEvent, isExpanded]);
|
|
}, [currentProject, currentCluster, logEvent, isExpanded]);
|
|
|
|
|
|
|
|
|
|
+ // if (!isExpanded) {
|
|
|
|
|
+ // <StyledCard>
|
|
|
|
|
+ // <FlexCenter>
|
|
|
|
|
+ // <button>Display logs</button>
|
|
|
|
|
+ // </FlexCenter>
|
|
|
|
|
+ // </StyledCard>;
|
|
|
|
|
+ // }
|
|
|
|
|
+
|
|
|
return (
|
|
return (
|
|
|
<StyledCard>
|
|
<StyledCard>
|
|
|
{/* Case: Is still getting logs and user triggered expanded */}
|
|
{/* Case: Is still getting logs and user triggered expanded */}
|
|
@@ -76,6 +84,12 @@ const Log = styled.div`
|
|
|
color: white;
|
|
color: white;
|
|
|
`;
|
|
`;
|
|
|
|
|
|
|
|
|
|
+const FlexCenter = styled.div`
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ justify-content: center;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+`;
|
|
|
|
|
+
|
|
|
const StyledCard = styled.div`
|
|
const StyledCard = styled.div`
|
|
|
border: 1px solid #ffffff44;
|
|
border: 1px solid #ffffff44;
|
|
|
margin-bottom: 30px;
|
|
margin-bottom: 30px;
|