linting
This commit is contained in:
@@ -2,10 +2,10 @@
|
|||||||
import { getEdgeToolbarTransform } from '@xyflow/system';
|
import { getEdgeToolbarTransform } from '@xyflow/system';
|
||||||
|
|
||||||
import { useStore } from '$lib/store';
|
import { useStore } from '$lib/store';
|
||||||
|
import { getEdgeIdContext } from '$lib/store/context';
|
||||||
|
|
||||||
import { EdgeLabel } from '$lib/components/EdgeLabel';
|
import { EdgeLabel } from '$lib/components/EdgeLabel';
|
||||||
import type { EdgeToolbarProps } from './types';
|
import type { EdgeToolbarProps } from './types';
|
||||||
import { getContext } from 'svelte';
|
|
||||||
import { getEdgeIdContext } from '$lib/store/context';
|
|
||||||
|
|
||||||
let {
|
let {
|
||||||
x,
|
x,
|
||||||
|
|||||||
@@ -13,7 +13,6 @@
|
|||||||
} from '@xyflow/system';
|
} from '@xyflow/system';
|
||||||
|
|
||||||
import type { ResizeControlProps } from './types';
|
import type { ResizeControlProps } from './types';
|
||||||
import type { Node } from '$lib/types';
|
|
||||||
|
|
||||||
let {
|
let {
|
||||||
nodeId,
|
nodeId,
|
||||||
@@ -79,7 +78,7 @@
|
|||||||
changes.set(id, change);
|
changes.set(id, change);
|
||||||
|
|
||||||
for (const childChange of childChanges) {
|
for (const childChange of childChanges) {
|
||||||
changes.set(childChange.id, {x: childChange.position.x, y: childChange.position.y });
|
changes.set(childChange.id, { x: childChange.position.x, y: childChange.position.y });
|
||||||
}
|
}
|
||||||
|
|
||||||
store.nodes = store.nodes.map((node) => {
|
store.nodes = store.nodes.map((node) => {
|
||||||
@@ -88,7 +87,7 @@
|
|||||||
const vertical = !resizeDirection || resizeDirection === 'vertical';
|
const vertical = !resizeDirection || resizeDirection === 'vertical';
|
||||||
|
|
||||||
if (change) {
|
if (change) {
|
||||||
return {
|
return {
|
||||||
...node,
|
...node,
|
||||||
position: {
|
position: {
|
||||||
x: horizontal ? (change.x ?? node.position.x) : node.position.x,
|
x: horizontal ? (change.x ?? node.position.x) : node.position.x,
|
||||||
|
|||||||
@@ -35,8 +35,10 @@ export interface EdgeLayoutBaseOptions<NodeType extends Node = Node, EdgeType ex
|
|||||||
onerror: OnError;
|
onerror: OnError;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface EdgeLayoutAllOptions<NodeType extends Node = Node, EdgeType extends Edge = Edge>
|
export interface EdgeLayoutAllOptions<
|
||||||
extends EdgeLayoutBaseOptions<NodeType, EdgeType> {
|
NodeType extends Node = Node,
|
||||||
|
EdgeType extends Edge = Edge
|
||||||
|
> extends EdgeLayoutBaseOptions<NodeType, EdgeType> {
|
||||||
onlyRenderVisible: never;
|
onlyRenderVisible: never;
|
||||||
visibleNodes: never;
|
visibleNodes: never;
|
||||||
transform: never;
|
transform: never;
|
||||||
|
|||||||
Reference in New Issue
Block a user