chore: update deps

Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
braks
2023-05-25 20:48:26 +02:00
committed by Braks
parent 128b968168
commit 5a86c7cf1d
16 changed files with 878 additions and 732 deletions
+3 -3
View File
@@ -2,7 +2,7 @@ import type { D3DragEvent, DragBehavior, SubjectPosition } from 'd3-drag'
import { drag } from 'd3-drag'
import { select } from 'd3-selection'
import type { Ref } from 'vue'
import type { MaybeComputedRef } from '@vueuse/core'
import type { MaybeRefOrGetter } from '@vueuse/core'
import type { NodeDragEvent, NodeDragItem, XYPosition } from '~/types'
export type UseDragEvent = D3DragEvent<HTMLDivElement, null, SubjectPosition>
@@ -12,8 +12,8 @@ interface UseDragParams {
onDrag: (event: Omit<NodeDragEvent, 'intersections'>) => void
onStop: (event: Omit<NodeDragEvent, 'intersections'>) => void
el: Ref<Element | undefined>
disabled?: MaybeComputedRef<boolean>
selectable?: MaybeComputedRef<boolean>
disabled?: MaybeRefOrGetter<boolean>
selectable?: MaybeRefOrGetter<boolean>
id?: string
dragHandle?: MaybeComputedRef<string | undefined>
}
+6 -6
View File
@@ -1,12 +1,12 @@
import type { MaybeComputedRef } from '@vueuse/core'
import type { MaybeRefOrGetter } from '@vueuse/core'
import type { Connection, ConnectionHandle, HandleType, MouseTouchEvent, ValidConnectionFunc } from '~/types'
interface UseHandleProps {
handleId: MaybeComputedRef<string | null>
nodeId: MaybeComputedRef<string>
type: MaybeComputedRef<HandleType>
isValidConnection?: MaybeComputedRef<ValidConnectionFunc | null>
edgeUpdaterType?: MaybeComputedRef<HandleType>
handleId: MaybeRefOrGetter<string | null>
nodeId: MaybeRefOrGetter<string>
type: MaybeRefOrGetter<HandleType>
isValidConnection?: MaybeRefOrGetter<ValidConnectionFunc | null>
edgeUpdaterType?: MaybeRefOrGetter<HandleType>
onEdgeUpdate?: (event: MouseTouchEvent, connection: Connection) => void
onEdgeUpdateEnd?: (event: MouseTouchEvent) => void
}
+2 -3
View File
@@ -1,6 +1,5 @@
import type { Ref } from 'vue'
import type { KeyFilter, KeyPredicate, MaybeComputedRef } from '@vueuse/core'
import { isBoolean, isFunction } from '@vueuse/core'
import type { KeyFilter, KeyPredicate, MaybeRefOrGetter } from '@vueuse/core'
export function isInputDOMNode(event: KeyboardEvent): boolean {
const target = (event.composedPath?.()?.[0] || event.target) as HTMLElement
@@ -38,7 +37,7 @@ function createKeyPredicate(keyFilter: string[], pressedKeys: Set<string>): KeyP
* @param keyFilter - Can be a boolean, a string or an array of strings. If it's a boolean, it will always return that value. If it's a string, it will return true if the key is pressed. If it's an array of strings, it will return true if any of the keys are pressed, or a combination is pressed (e.g. ['ctrl+a', 'ctrl+b'])
* @param onChange - Callback function that will be called when the key state changes
*/
export default (keyFilter: MaybeComputedRef<KeyFilter | null>, onChange?: (keyPressed: boolean) => void): Ref<boolean> => {
export default (keyFilter: MaybeRefOrGetter<KeyFilter | null>, onChange?: (keyPressed: boolean) => void): Ref<boolean> => {
const window = useWindow()
const isPressed = ref(resolveUnref(keyFilter) === true)