<template>
	<div class="absolute top-0 right-0 p-16px flex flex-col gap-12px">
		<el-tooltip content="节点" placement="left">
			<el-popover placement="left-start" width="360px">
				<NodeLibary @add-node="(val) => $emit('create:node', val)" />
				<template #reference>
					<IconButton type="primary" class="ml-12px" icon="lucide:package-plus" square />
				</template>
			</el-popover>
		</el-tooltip>

		<el-tooltip content="注释" placement="left">
			<IconButton
				icon="lucide:file-plus-corner"
				square
				@click="$emit('create:node', 'stickyNote')"
			/>
		</el-tooltip>
		<el-tooltip content="运行" placement="left">
			<IconButton icon="lucide:play" icon-color="#fff" type="success" square />
		</el-tooltip>
	</div>
</template>

<script setup lang="ts">
import { IconButton } from '@repo/ui'
import NodeLibary from '@/features/nodeLibary/index.vue'
</script>

<style scoped></style>
