import{aa as n}from"./_applist-tangy-colts-beg-36.js";import{_ as e}from"./main-tangy-colts-beg.js";import{h as a,s as i}from"./machine.-tangy-colts-beg-869.js";import"./lodash-tangy-colts-beg-516.js";globalThis.jotaiAtomCache=globalThis.jotaiAtomCache||{cache:new Map,get(t,o){return this.cache.has(t)?this.cache.get(t):(this.cache.set(t,o),o)}};const l=n(({helpers:t})=>({states:{components:[{componentName:t.componentName.mixInput,id:"code",label:e("Coupon Code"),onChange:"HANDLE_CODE",path:"code",placeholder:e("Enter coupon code (e.g., SAVE10)"),render:!0,required:!0,value:void 0},{componentName:t.componentName.mixInput,id:"title",label:e("Coupon Title"),onChange:"HANDLE_TITLE",path:"title",placeholder:e("Enter coupon title (e.g., Save 10%)"),render:!0,required:!0,value:void 0},{componentName:t.componentName.select,id:"type",label:e("Discount Type"),onChange:"HANDLE_TYPE",options:[{label:e("Percentage"),value:"percentage"},{label:e("Fixed Amount"),value:"fixed"}],path:"type",placeholder:e("Select discount type"),render:!0,required:!0,value:void 0},{componentName:t.componentName.mixInput,id:"amount",label:e("Discount Amount"),onChange:"HANDLE_AMOUNT",path:"amount",placeholder:e("Enter discount amount (e.g., 10)"),render:!0,required:!0,value:void 0}]},actions:{HANDLE_AMOUNT:a("amount"),HANDLE_CODE:a("code"),HANDLE_TITLE:a("title"),HANDLE_TYPE:a("type"),ON_MACHINE_LOAD:async({$:o})=>{i(o,[{db:"code",id:"code"},{db:"title",id:"title"},{db:"type",id:"type"},{db:"amount",id:"amount"}])}}}));export{l as default};
