import{r as e}from"./rolldown-runtime-DIIn1E2Q.js";import{it as t}from"./vendor-primevue-CIZeDNer.js";import{A as n,D as r,G as i,I as a,K as o,Lt as s,O as c,R as l,_t as u,et as d,k as f,ut as p}from"./vendor-vue-core-IZuWV8u3.js";import"./vendor-other-DOjudfJ1.js";import{t as m}from"./src-B6n4nS3q.js";import{t as h}from"./Loader-Ov_vR8f1.js";import{o as g,r as _}from"./widgetPropFilter-Dy-SfJ-m.js";import{t as v}from"./layout-D00FkF_k.js";import{t as y}from"./WidgetLayoutField-BkyPHU3x.js";var b={class:`relative`},x=l({__name:`WidgetInputText`,props:i({widget:{},size:{default:`medium`},invalid:{type:Boolean,default:!1},loading:{type:Boolean,default:!1}},{modelValue:{default:``},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let i=p(e,`modelValue`),l=r(()=>g(e.widget.options,_)),x=r(()=>!!(e.widget.options?.read_only||e.widget.options?.disabled)),S=r(()=>({name:e.widget.name,label:e.widget.label,borderStyle:m(e.widget.borderStyle,e.invalid&&`border border-destructive-background`)}));return(e,r)=>(d(),f(y,{widget:S.value},{default:u(()=>[c(`div`,b,[e.loading?(d(),f(h,{key:0,size:`sm`,class:`absolute top-1/2 left-3 z-10 -translate-y-1/2 text-component-node-foreground`})):n(``,!0),a(s(t),o({modelValue:i.value,"onUpdate:modelValue":r[0]||=e=>i.value=e},l.value,{class:s(m)(s(v),`w-full px-4 hover:bg-component-node-widget-background-hovered`,e.size===`large`?`py-3 text-sm`:`py-2 text-xs`,e.loading&&`pl-9`),"aria-label":e.widget.name,readonly:x.value,size:`small`,pt:{root:`truncate min-w-[4ch]`}}),null,16,[`modelValue`,`class`,`aria-label`,`readonly`])])]),_:1},8,[`widget`]))}});export{x as default};
//# sourceMappingURL=WidgetInputText-ZzUA80X0.js.map