editor: center marker

This commit is contained in:
Vašek Šraier 2020-10-04 11:31:01 +02:00
parent c1e6707abf
commit 62e673a196
2 changed files with 10 additions and 0 deletions

View file

@ -249,6 +249,7 @@
selectionToolEnabled={true}
on:selectTask={clickTask}
on:preSelectTask={startHovering}
showCenterMarker={true}
bind:this={graph}
{nodeDraggingEnabled}
on:openTask={openTaskDetailEditorButton}

View file

@ -12,6 +12,7 @@
export let selectionToolEnabled: boolean = false;
export let showHiddenEdges: boolean = false;
export let selection: Set<TaskDescriptor> = new Set();
export let showCenterMarker: boolean = false;
let hoveredTask: null | string = null;
@ -199,6 +200,10 @@
flex-grow: 1;
}
:global(#footer) {
z-index: 20;
}
rect {
fill: transparent;
stroke-dasharray: 5, 5;
@ -229,6 +234,10 @@
width={selectionRectangle[1][0] - selectionRectangle[0][0]}
height={selectionRectangle[1][1] - selectionRectangle[0][1]} />
{/if}
{#if showCenterMarker}
<line x1="10000" y1="0" x2="-10000" y2="0" stroke="gray" stroke-width="1px" stroke-dasharray="15,15" />
<line x1="0" y1="10000" x2="0" y2="-10000" stroke="gray" stroke-width="1px" stroke-dasharray="15,15" />
{/if}
{#each edges as edge}
<GraphEdge {edge} showLabelEdge={showHiddenEdges} />
{/each}