Skip to content

Commit

Permalink
feat(workflow): split components
Browse files Browse the repository at this point in the history
  • Loading branch information
qianmoQ committed Dec 7, 2024
1 parent a03f9b4 commit 86ccb65
Show file tree
Hide file tree
Showing 8 changed files with 565 additions and 862 deletions.
20 changes: 1 addition & 19 deletions src/App.vue
Original file line number Diff line number Diff line change
@@ -1,25 +1,7 @@
<template>
<ShadcnWorkflowEditor
v-model:nodes="nodes"
v-model:edges="edges"
@node-select="handleNodeSelect"
@edge-select="handleEdgeSelect"
/>
<ShadcnWorkflowEditor />
</template>

<script setup lang="ts">
import { ref } from 'vue'
import { Edge } from '@/ui/workflow/types.ts'
import ShadcnWorkflowEditor from '@/ui/workflow/ShadcnWorkflowEditor.vue'
const nodes = ref<Node[]>([])
const edges = ref<Edge[]>([])
const handleNodeSelect = (node: Node) => {
console.log('Selected node:', node)
}
const handleEdgeSelect = (edge: Edge) => {
console.log('Selected edge:', edge)
}
</script>
Loading

0 comments on commit 86ccb65

Please sign in to comment.