import{aa as s,ab as c}from"./_applist-tangy-colts-beg-36.js";import{_ as a}from"./main-tangy-colts-beg.js";import{h as n,s as T}from"./machine.-tangy-colts-beg-869.js";import{h as d,a as r,c as E}from"./flowluco-tangy-colts-beg-376.js";import{c as i}from"./machineh-tangy-colts-beg-571.js";import"./lodash-tangy-colts-beg-516.js";globalThis.jotaiAtomCache=globalThis.jotaiAtomCache||{cache:new Map,get(t,e){return this.cache.has(t)?this.cache.get(t):(this.cache.set(t,e),e)}};const h=s(({helpers:t})=>({states:{components:[E(t),{allowClear:!0,componentName:t.componentName.select,fieldType:"config",helperText:a("Select the parent task."),id:"task-id",label:a("Select Parent Task"),onChange:"SELECT_TASK",onRefetch:"REFETCH_TASKS",options:[],render:"IF_CONNECTION_SELECTED",required:!1,value:void 0},{componentName:t.componentName.mixInput,fieldType:"config",helperText:a("Enter the name of the task."),id:"task-name",label:a("Task Name"),onChange:"SET_TASK_NAME",render:"IF_CONNECTION_SELECTED",required:!0,value:void 0},{componentName:t.componentName.mixInput,fieldType:"config",helperText:a("Enter the description of the task."),id:"task-description",label:a("Task Description"),onChange:"SET_TASK_DESCRIPTION",render:"IF_CONNECTION_SELECTED",required:!1,value:void 0},{componentName:t.componentName.mixInput,fieldType:"config",helperText:a("Enter the due date for the task (YYYY-MM-DD format)."),id:"task-due-date",label:a("Due Date"),onChange:"SET_TASK_DUE_DATE",render:"IF_CONNECTION_SELECTED",required:!1,value:void 0}]},actions:{ON_MACHINE_LOAD:({$:e})=>{T(e,[{db:"connectionId",id:"connection-id"},{db:"taskId",id:"task-id"},{db:"taskName",id:"task-name"},{db:"taskDescription",id:"task-description"},{db:"taskDueDate",id:"task-due-date"}]),i(e)},CONNECTION_ADD_CHANGE:r,SET_DOMAIN:d,SET_CONNECTION:async({$:e,e:o})=>{n("connectionId")({$:e,e:o}),await i(e)},SELECT_TASK:n("taskId"),REFETCH_TASKS:({$:e})=>i(e),SET_TASK_NAME:n("taskName"),SET_TASK_DESCRIPTION:n("taskDescription"),SET_TASK_DUE_DATE:n("taskDueDate"),IF_CONNECTION_SELECTED:({$:e})=>{var o;return c((o=e.getComponent("connection-id"))==null?void 0:o.value)}}}));export{h as default};
