Skip to content

Commit

Permalink
feat: address pr feedback
Browse files Browse the repository at this point in the history
Signed-off-by: Olga Nad <olga@union.ai>
  • Loading branch information
olga-union committed Apr 18, 2022
1 parent 64dc90b commit 1ab2b6d
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions src/components/flytegraph/ReactFlow/customNodeComponents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ export const ReactFlowCustomTaskNode = ({ data }: any) => {
width: '8px',
height: '8px',
marginLeft: '4px',
marginTop: '1px',
color: COLOR_GRAPH_BACKGROUND,
};

Expand All @@ -249,13 +250,14 @@ export const ReactFlowCustomTaskNode = ({ data }: any) => {
};

const renderCacheIcon = (cacheStatus) => {
if (cacheStatus === CatalogCacheStatus.CACHE_HIT) {
return <CachedOutlined style={cacheIconStyles} />;
switch (cacheStatus) {
case CatalogCacheStatus.CACHE_HIT:
return <CachedOutlined style={cacheIconStyles} />;
case CatalogCacheStatus.CACHE_POPULATED:
return <PublishedWithChangesOutlined style={cacheIconStyles} />;
default:
return null;
}
if (cacheStatus === CatalogCacheStatus.CACHE_POPULATED) {
return <PublishedWithChangesOutlined style={cacheIconStyles} />;
}
return null;
};

return (
Expand Down

0 comments on commit 1ab2b6d

Please sign in to comment.