* Add getter for node/edge types * change nodeTypes prop type to only Record<string, NodeType> - same for edges * Add rgb example * remove v-model for elements Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
16 lines
440 B
Vue
16 lines
440 B
Vue
<script lang="ts" setup>
|
|
import { Handle, NodeProps, Position } from '~/index'
|
|
|
|
interface RBGOutputNodeProps extends NodeProps {
|
|
rgb: string
|
|
}
|
|
|
|
const props = defineProps<RBGOutputNodeProps>()
|
|
</script>
|
|
<template>
|
|
<div :style="{ backgroundColor: props.rgb }" class="p-3 rounded-xl text-left text-white">
|
|
<div class="text-md uppercase">{{ props.rgb }}</div>
|
|
<Handle type="source" :position="Position.Left" />
|
|
</div>
|
|
</template>
|