feat(additional-components): add Panel component

This commit is contained in:
braks
2022-10-10 21:33:44 +02:00
committed by Braks
parent ef3111bde0
commit 3541b24587
4 changed files with 30 additions and 0 deletions
@@ -0,0 +1,15 @@
<script lang="ts" setup>
import { useVueFlow } from '@vue-flow/core'
import type { PanelProps } from './types'
const props = defineProps<PanelProps>()
const pointerEvents = useVueFlow()
const positionClasses = computed(() => `${props.position}`.split('-'))
</script>
<template>
<div class="vue-flow__panel" :class="positionClasses" :style="{ pointerEvents }">
<slot />
</div>
</template>