Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions src/components/grid-layout/cards/diagrams/diagram-styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,20 @@ export const styles = {
transform: 'unset !important',
},
},
nadDefaultCursors: {
'& .nad-branch-edges .nad-edge-path, & .nad-3wt-edges .nad-edge-path, & .nad-branch-edges .nad-winding, & .nad-3wt-nodes .nad-winding, & .nad-edge-infos':
{
cursor: 'pointer',
},
},
nadEditModeCursors: {
'& .nad-label-box': {
cursor: 'grab',
},
'& .nad-edge-infos': {
cursor: 'default',
},
},
paperBorders: (theme) => ({
borderLeft: '1px solid ' + theme.palette.action.disabled,
borderBottom: '1px solid ' + theme.palette.action.disabledBackground,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,8 @@ function NetworkAreaDiagramContent(props: NetworkAreaDiagramContentProps) {
styles.divDiagram,
styles.divNetworkAreaDiagram,
loadFlowStatus !== RunningStatus.SUCCEED ? styles.divDiagramInvalid : undefined,
isEditNadMode && !showLabels ? styles.hideLabels : undefined
isEditNadMode && !showLabels ? styles.hideLabels : undefined,
isEditNadMode ? styles.nadEditModeCursors : styles.nadDefaultCursors
)}
/>
<DiagramControls
Expand Down
8 changes: 2 additions & 6 deletions src/nad-index.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
.nad-branch-edges .nad-edge-path,
.nad-3wt-edges .nad-edge-path {
stroke: var(--vl-color, lightgrey);
stroke-width: 0.25%;
fill: none;
}
.nad-3wt-edges .nad-edge-path,
.nad-branch-edges .nad-winding,
.nad-3wt-nodes .nad-winding {
stroke: var(--vl-color, lightgrey);
Expand Down Expand Up @@ -67,7 +63,7 @@ foreignObject.nad-text-nodes {
width: max-content;
padding: 10px;
border-radius: 10px;
cursor: grab;
cursor: pointer;
border: 2px solid rgba(0,0,0,0);
}
.nad-legend-square {
Expand Down
Loading