1import{A as e,C as t,D as n,F as r,O as i,St as a,Z as o,_t as s,b as c,cn as l,ct as u,d,f,gt as p,l as m,o as h,pn as g,qt as _,ut as v,w as y,x as b,z as x,zt as S}from"./ARSLoXLj.js";import{t as C}from"./BZTB_sbI.js";import{t as w}from"./D1Ffb9kd.js";import{t as T}from"./tct9Ynd5.js";import{t as E}from"./Pc2GzV0A.js";import{d as D}from"./8beAxG0M.js";import{c as O,s as k}from"./ChOV5kXS.js";import{t as A}from"./Cf3WZc8b.js";import{t as j}from"./BUWiS_Zu.js";r(),_(),a();var M={key:0,class:`ws:rounded ws:bg-primary ws:text-primary absolute min-w-full flex-wrap items-center gap-x-2 bg-white px-6 py-4 md:px-0`},N=e({__name:`ZgSearchInputError`,props:{errorMessage:{}},setup(e){let r=e,{resolveByBrand:a}=T(),s=c(()=>a({[E.ZUMTOBEL]:()=>`small`,[E.THORN]:()=>`base`,default:()=>`base`}));return(e,a)=>r.errorMessage?(o(),y(`div`,M,[n(g(r.errorMessage)+` `,1),b(`span`,null,[i(S(D),{is:j,to:{name:`language-country-contact`},size:S(s),variant:`primary:plain`,class:`flex justify-center`},{default:p(()=>[n(g(e.$t(`search.contactUs`)),1)]),_:1},8,[`size`])])])):t(``,!0)}});r(),h(),a(),_();var P={class:`group relative`},F=[`aria-label`],I=[`disabled`,`placeholder`],L=[`aria-label`],R=[`aria-label`],z=e({__name:`ZgSearchInput`,props:x({placeholder:{default:void 0},source:{default:void 0},ariaLabel:{default:``},isWorkspace:{type:Boolean},iconFilled:{type:Boolean},isClearable:{type:Boolean,default:!0},errorMessage:{default:void 0},isLoading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},fullBorder:{type:Boolean,default:!1},submitOnBlur:{type:Boolean,default:!1}},{modelValue:{},modelModifiers:{}}),emits:x([`input:submit`,`input:update`,`input:clear`],[`update:modelValue`]),setup(e,{expose:n,emit:r}){let a=e,c=r,p=v(`input`),h=u(e,`modelValue`),{trackSearchInput:_}=C(),x=e=>e?k(e)?O(e):e:``,T=w(()=>{h.value&&_({searchTerm:h.value,source:a.source}),c(`input:submit`,x(h.value))},300,{leading:!0,trailing:!0,maxWait:1e3}),E=w(()=>{c(`input:update`,x(h.value))},300,{leading:!0,trailing:!0,maxWait:1e3}),D=()=>{a.submitOnBlur&&T()},j=()=>{h.value=``,c(`input:clear`)};return n({searchInput:p}),(n,r)=>{let c=A;return o(),y(`div`,P,[b(`form`,{role:`search`,class:l([`block w-full`,{"tl:flex":!a.isWorkspace&&e.iconFilled}]),"aria-label":a.ariaLabel??e.placeholder??n.$t(`search.action`),onSubmit:r[3]||=f((...e)=>S(T)&&S(T)(...e),[`stop`,`prevent`])},[s(b(`input`,{ref_key:`input`,ref:p,"onUpdate:modelValue":r[0]||=e=>h.value=e,type:`text`,class:l([`border-secondary text-primary placeholder:text-tertiary focus-within:border-accent-secondary group-hover:border-accent-secondary ws:rounded-lg ws:border ws:border-04 ws:bg-04 ws:pl-4 focus-within:ws:border-accent-secondary h-10 w-full rounded-none border-b border-solid py-2 pr-14 outline-hidden focus-within:border-b-2`,{"focus-within:pb-1.75":!e.isWorkspace,"border-primary-disabled text-primary-disabled group-hover:border-primary-disabled":e.disabled,"h-8 border p-3":e.fullBorder}]),disabled:e.disabled,placeholder:e.isWorkspace?n.$t(`search.searchBox.placeholderWorkspace`):e.placeholder,onBlur:D,onKeydown:r[1]||=d(f((...e)=>S(T)&&S(T)(...e),[`prevent`]),[`enter`]),onInput:r[2]||=(...e)=>S(E)&&S(E)(...e)},null,42,I),[[m,h.value]]),b(`div`,{class:l([`absolute! top-1/2 flex -translate-y-1/2`,[e.iconFilled?`right-0 gap-x-4`:`right-4 gap-x-2`,{"tl:static tl:transform-none":e.iconFilled&&!e.isWorkspace}]])},[h.value&&e.isClearable?(o(),y(`button`,{key:0,type:`button`,class:`text-primary`,"aria-label":n.$t(`common.forms.input.clearable`),onClick:j},g(n.$t(`common.forms.input.clearable`)),9,L)):t(``,!0),b(`button`,{type:`submit`,class:l({"bg-accent-primary ws:rounded-lg right-0 flex size-10 items-center justify-center":e.iconFilled,"tl:rounded-full":e.iconFilled&&!e.isWorkspace}),"aria-label":n.$t(`search.action`)},[i(c,{icon:e.isLoading?`loading`:`search`,class:l([`text-size-icon`,[e.iconFilled?`text-primary-inverted`:[`ws:text-accent-primary`,h.value?`text-accent-primary`:`text-primary`],{"animate-spin":e.isLoading,"text-primary-disabled":e.disabled}]]),"aria-hidden":``},null,8,[`icon`,`class`])],10,R)],2)],42,F),i(N,{"error-message":e.errorMessage},null,8,[`error-message`])])}}});
1export{N as n,z as t};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.