import{l as c,c as s,o as r,f as n,b as y,t as d,y as m,n as p}from"./app-B4kV47qU.js";const g={key:0,class:"label mb-1"},f=["type","value","placeholder","required","step"],v={key:1,class:"my-1 text-[11px] font-light text-danger-600"},h={__name:"TextareaField",props:{label:{type:String,default:""},customStyle:{type:String,default:""},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},validationMessage:{type:[String,Array],default:""},placeholder:{type:String,default:"Example: text..."},isRequired:{type:Boolean,default:!1},step:{type:String,default:"any"},attrs:{type:Object,default:()=>({})}},emits:["update:modelValue"],setup(e,{emit:i}){const t=e,u=i,a=c(()=>t.validationMessage&&Array.isArray(t.validationMessage)?t.validationMessage[0]:t.validationMessage),o=l=>{u("update:modelValue",l.target.value)};return(l,b)=>(r(),s("div",{class:p(["w-full",e.customStyle])},[e.label?(r(),s("label",g,d(l.trans(e.label)),1)):n("",!0),y("textarea",m({type:e.type,value:e.modelValue,onInput:o,class:["input",{"border border-danger-600":a.value}],placeholder:e.placeholder,required:e.isRequired,step:e.step},e.attrs),null,16,f),a.value?(r(),s("div",v,d(a.value),1)):n("",!0)],2))}};export{h as _};
