chore(svelte): use prettier
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
<script lang="ts">
|
||||
|
||||
import { createEventDispatcher, onMount, setContext, SvelteComponentTyped } from 'svelte';
|
||||
import cc from 'classcat';
|
||||
import { errorMessages, type NodeProps } from '@xyflow/system';
|
||||
@@ -59,7 +58,7 @@
|
||||
});
|
||||
|
||||
function dispatchEvent(eventName: string) {
|
||||
const node = $nodes.find(n => n.id === id);
|
||||
const node = $nodes.find((n) => n.id === id);
|
||||
dispatch(eventName, node);
|
||||
}
|
||||
|
||||
@@ -69,13 +68,20 @@
|
||||
addSelectedNodes([id]);
|
||||
}
|
||||
|
||||
dispatchEvent('node:click')
|
||||
dispatchEvent('node:click');
|
||||
}
|
||||
</script>
|
||||
|
||||
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
||||
<div
|
||||
use:drag={{ nodeId: id, isSelectable: selectable, disabled: false, handleSelector: undefined, noDragClassName: 'nodrag', store }}
|
||||
use:drag={{
|
||||
nodeId: id,
|
||||
isSelectable: selectable,
|
||||
disabled: false,
|
||||
handleSelector: undefined,
|
||||
noDragClassName: 'nodrag',
|
||||
store
|
||||
}}
|
||||
bind:this={nodeRef}
|
||||
data-id={id}
|
||||
class={cc(['svelte-flow__node', `svelte-flow__node-${type || 'default'}`, className])}
|
||||
|
||||
Reference in New Issue
Block a user