Skip to content

Commit

Permalink
Change color for selected node and edges (MarquezProject#2458)
Browse files Browse the repository at this point in the history
Signed-off-by: tito12 <vladyslav.sedenko@gmail.com>
Signed-off-by: Xavier-Cliquennois <xavier.cliquennois@wearegraphite.io>
  • Loading branch information
tito12 authored and Xavier-Cliquennois committed Jul 26, 2023
1 parent 02ba16e commit 0c83acd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions web/src/components/lineage/components/edge/Edge.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class Edge extends React.Component<EdgeProps> {
data={edge.points}
x={(d, index) => (index === 0 ? d.x + 20 : d.x - 25)}
y={d => d.y}
stroke={edge.isSelected ? theme.palette.common.white : theme.palette.secondary.main}
stroke={edge.isSelected ? theme.palette.primary.main : theme.palette.secondary.main}
strokeWidth={1}
opacity={1}
shapeRendering='geometricPrecision'
Expand All @@ -66,7 +66,7 @@ class Edge extends React.Component<EdgeProps> {
y={edge.y - ICON_SIZE / 2}
width={ICON_SIZE}
height={ICON_SIZE}
color={edge.isSelected ? theme.palette.common.white : theme.palette.secondary.main}
color={edge.isSelected ? theme.palette.primary.main : theme.palette.secondary.main}
/>
))}
</>
Expand Down
8 changes: 4 additions & 4 deletions web/src/components/lineage/components/node/Node.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class Node extends React.Component<NodeProps> {
style={{ cursor: 'pointer' }}
r={RADIUS}
fill={isSelected ? theme.palette.secondary.main : theme.palette.common.white}
stroke={isSelected ? theme.palette.common.white : theme.palette.secondary.main}
stroke={isSelected ? theme.palette.primary.main : theme.palette.secondary.main}
strokeWidth={BORDER / 2}
cx={node.x}
cy={node.y}
Expand All @@ -76,7 +76,7 @@ class Node extends React.Component<NodeProps> {
height={ICON_SIZE}
x={node.x - ICON_SIZE / 2}
y={node.y - ICON_SIZE / 2}
color={isSelected ? theme.palette.common.white : theme.palette.secondary.main}
color={isSelected ? theme.palette.primary.main : theme.palette.secondary.main}
/>
</g>
) : (
Expand All @@ -86,7 +86,7 @@ class Node extends React.Component<NodeProps> {
x={node.x - RADIUS}
y={node.y - RADIUS}
fill={isSelected ? theme.palette.secondary.main : theme.palette.common.white}
stroke={isSelected ? theme.palette.common.white : theme.palette.secondary.main}
stroke={isSelected ? theme.palette.primary.main: theme.palette.secondary.main}
strokeWidth={BORDER / 2}
width={RADIUS * 2}
height={RADIUS * 2}
Expand All @@ -109,7 +109,7 @@ class Node extends React.Component<NodeProps> {
height={ICON_SIZE}
x={node.x - ICON_SIZE / 2}
y={node.y - ICON_SIZE / 2}
color={isSelected ? theme.palette.common.white : theme.palette.secondary.main}
color={isSelected ? theme.palette.primary.main : theme.palette.secondary.main}
/>
</g>
)}
Expand Down

0 comments on commit 0c83acd

Please sign in to comment.