import { defineStore } from 'pinia'
import { ref, computed } from 'vue'
export const useVersionTreeStore = defineStore('versionTree', () => {
	const state = ref({
		nodeDetail: {
			nodeCreateTime:'',
			nodeSketchTime:'',
			userEndChat:{
				content:'',
				createTime:'',
				image_url:'',
			},
			generateEndChat:{
				content:'',
				createTime:'',
				image_url:'',
			},
		},// 节点详情
	})

	const setNodeDetail = (v: any) => { 
		for(const key in v){
			state.value.nodeDetail[key] = v[key]
		}
	 }

	return {
		state,
		setNodeDetail,
	}
})
