update: Add names to components
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -61,6 +61,7 @@ const attrs = useAttrs() as Record<'style', CSSProperties>
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'BezierEdge',
|
||||
inheritAttrs: false,
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -39,6 +39,11 @@ const cy = computed(() => {
|
||||
else return val
|
||||
})
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'EdgeAnchor',
|
||||
}
|
||||
</script>
|
||||
<template>
|
||||
<circle class="vue-flow__edgeupdater" :cx="cx" :cy="cy" :r="props.radius" stroke="transparent" fill="transparent" />
|
||||
</template>
|
||||
|
||||
@@ -30,6 +30,11 @@ const { width, height, x, y } = useElementBounding(edgeRef)
|
||||
const transform = computed(() => `translate(${props.x - width.value / 2 || 0} ${props.y - height.value / 2 || 0})`)
|
||||
const bgPadding = computed(() => [props.labelBgPadding[0], props.labelBgPadding[1]])
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'EdgeText',
|
||||
}
|
||||
</script>
|
||||
<template>
|
||||
<g :transform="transform" class="vue-flow__edge-textwrapper">
|
||||
<rect
|
||||
|
||||
@@ -130,6 +130,11 @@ const edgePos = computed(() =>
|
||||
)
|
||||
const elementsSelectable = computed(() => store.elementsSelectable)
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'Edge',
|
||||
}
|
||||
</script>
|
||||
<template>
|
||||
<g
|
||||
v-show="!props.edge.isHidden && isVisible(edgePos)"
|
||||
|
||||
@@ -64,6 +64,7 @@ const attrs = useAttrs() as Record<'style', CSSProperties>
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'SmoothStepEdge',
|
||||
inheritAttrs: false,
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -43,6 +43,11 @@ const props = withDefaults(defineProps<StepEdgeProps>(), {
|
||||
})
|
||||
const attrs = useAttrs() as Record<'style', CSSProperties>
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'StepEdge',
|
||||
}
|
||||
</script>
|
||||
<template>
|
||||
<SmoothStepEdge v-bind="{ ...props, ...attrs }" :border-radius="0">
|
||||
<slot />
|
||||
|
||||
@@ -66,6 +66,7 @@ const attrs = useAttrs() as Record<'style', CSSProperties>
|
||||
</script>
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'StraightEdge',
|
||||
inheritAttrs: false,
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user