1import{G as e,H as t}from"./jsx-runtime-D4_EPXwy.js";import{$ as n,Dt as r,I as i,Mt as a,St as o,W as s,at as c,ht as l,lt as u,mt as d,ot as f,pt as p,vt as m,yt as ee}from"./useGlobalPostalCode-B3Zt02CD.js";import{N as te,P as ne,S as re,b as ie,d as h,f as g,g as _,v,x as y}from"./Separator-CvF6Rflt.js";import{i as ae}from"./FocusScope-CzuqmPaf.js";import{c as b,m as x}from"./usePostalCode-BRbA7e3c.js";var S=new WeakMap;function C(e){let t=S.get(e);if(t!=null)return t;let n=0,r=t=>{for(let i of t)i.type===`section`?r(g(i,e)):i.type===`item`&&n++};return r(e),S.set(e,n),n}var w=e(t(),1);function oe(e){let{selectionManager:t,collection:n,disabledKeys:r,ref:i,keyboardDelegate:a,layoutDelegate:o,orientation:s}=e,c=h({usage:`search`,sensitivity:`base`}),l=t.disabledBehavior,u=(0,w.useMemo)(()=>a||new v({collection:n,disabledKeys:r,disabledBehavior:l,ref:i,collator:c,layoutDelegate:o,orientation:s}),[a,o,n,r,i,c,l,s]),{collectionProps:d}=_({...e,ref:i,selectionManager:t,keyboardDelegate:u});return{listProps:d}}var T=(0,w.createContext)(null),E={};E={collectionLabel:`Ù
ÙØªØ±ØØ§Øª`};var D={};D={collectionLabel:`ÐÑедложениÑ`};var O={};O={collectionLabel:`Návrhy`};var k={};k={collectionLabel:`Forslag`};var A={};A={collectionLabel:`Empfehlungen`};var j={};j={collectionLabel:`Î ÏοÏάÏειÏ`};var M={};M={collectionLabel:`Suggestions`};var N={};N={collectionLabel:`Sugerencias`};var P={};P={collectionLabel:`Soovitused`};var F={};F={collectionLabel:`Ehdotukset`};var I={};I={collectionLabel:`Suggestions`};var L={};L={collectionLabel:`×צע×ת`};var R={};R={collectionLabel:`Prijedlozi`};var z={};z={collectionLabel:`Javaslatok`};var B={};B={collectionLabel:`Suggerimenti`};var V={};V={collectionLabel:`åè£`};var H={};H={collectionLabel:`ì ì`};var U={};U={collectionLabel:`PasiÅ«lymai`};var se={};se={collectionLabel:`Ieteikumi`};var W={};W={collectionLabel:`Forslag`};var G={};G={collectionLabel:`Suggesties`};var K={};K={collectionLabel:`Sugestie`};var q={};q={collectionLabel:`Sugestões`};var J={};J={collectionLabel:`Sugestões`};var Y={};Y={collectionLabel:`Sugestii`};var X={};X={collectionLabel:`ÐÑедложениÑ`};var Z={};Z={collectionLabel:`Návrhy`};var Q={};Q={collectionLabel:`Predlogi`};var ce={};ce={collectionLabel:`Predlozi`};var le={};le={collectionLabel:`Förslag`};var $={};$={collectionLabel:`Ãneriler`};var ue={};ue={collectionLabel:`ÐÑопозиÑÑÑ`};var de={};de={collectionLabel:`建议`};var fe={};fe={collectionLabel:`建è°`};var pe={};pe={"ar-AE":E,"bg-BG":D,"cs-CZ":O,"da-DK":k,"de-DE":A,"el-GR":j,"en-US":M,"es-ES":N,"et-EE":P,"fi-FI":F,"fr-FR":I,"he-IL":L,"hr-HR":R,"hu-HU":z,"it-IT":B,"ja-JP":V,"ko-KR":H,"lt-LT":U,"lv-LV":se,"nb-NO":W,"nl-NL":G,"pl-PL":K,"pt-BR":q,"pt-PT":J,"ro-RO":Y,"ru-RU":X,"sk-SK":Z,"sl-SI":Q,"sr-SP":ce,"sv-SE":le,"tr-TR":$,"uk-UA":ue,"zh-CN":de,"zh-TW":fe};function me(e){return e&&e.__esModule?e.default:e}function he(e,t){let{inputRef:n,collectionRef:i,filter:c,disableAutoFocusFirst:f=!1}=e,h=a(),g=(0,w.useRef)(void 0),_=(0,w.useRef)(!1),v=(0,w.useRef)(null),b=(0,w.useRef)(null),x=s()!==`virtual`;(0,w.useEffect)(()=>()=>clearTimeout(g.current),[]);let S=p(e=>{!e.isTrusted&&x&&n.current&&o(r(n.current))!==n.current&&n.current.focus();let a=e.target;e.isTrusted||!a||v.current===a.id||(clearTimeout(g.current),a===i.current?(v.current=null,t.setFocusedNodeId(null)):_.current?(v.current=a.id,g.current=setTimeout(()=>{t.setFocusedNodeId(a.id)},500)):(v.current=a.id,t.setFocusedNodeId(a.id)),_.current=!1)}),C=(0,w.useCallback)(e=>{var t;if(e!=null){var n;(n=b.current)==null||n.removeEventListener(`focusin`,S),b.current=e,e.addEventListener(`focusin`,S)}else(t=b.current)==null||t.removeEventListener(`focusin`,S)},[S]),oe=d((0,w.useMemo)(()=>ee(i,C),[i,C])),T=p(()=>{var e;_.current=!0,(e=i.current)==null||e.dispatchEvent(new CustomEvent(`react-aria-focus`,{cancelable:!0,bubbles:!0,detail:{focusStrategy:`first`}}))}),E=p(e=>{var n;re(o()),v.current=null,t.setFocusedNodeId(null);let r=new CustomEvent(te,{cancelable:!0,bubbles:!0,detail:{clearFocusKey:e}});clearTimeout(g.current),_.current=!1,(n=i.current)==null||n.dispatchEvent(r)}),D=e=>
1{t.inputValue!==e&&t.inputValue.length<=e.length&&!f?T():E(!0),t.setInputValue(e)},O=(0,w.useRef)(null),k=e=>{if(O.current=e.target,e.nativeEvent.isComposing)return;let t=v.current;switch(e.key){case`a`:if(u(e))return;break;case`Escape`:if(e.isDefaultPrevented())return;break;case` `:return;case`Tab`:`continuePropagation`in e&&e.continuePropagation();return;case`Home`:case`End`:case`PageDown`:case`PageUp`:case`ArrowUp`:case`ArrowDown`:{var n;if((e.key===`Home`||e.key===`End`)&&t==null&&e.shiftKey)return;e.preventDefault();let r=new CustomEvent(ne,{cancelable:!0,bubbles:!0});(n=i.current)==null||n.dispatchEvent(r);break}}e.isPropagationStopped()||e.stopPropagation();let r=!0;if(r=t==null?i.current?.dispatchEvent(new KeyboardEvent(e.nativeEvent.type,e.nativeEvent))||!1:document.getElementById(t)?.dispatchEvent(new KeyboardEvent(e.nativeEvent.type,e.nativeEvent))||!1,r)switch(e.key){case`ArrowLeft`:case`ArrowRight`:E();break}},A=p(e=>{if(e.target===O.current){var t;e.stopImmediatePropagation();let n=v.current;n==null?(t=i.current)==null||t.dispatchEvent(new KeyboardEvent(e.type,e)):document.getElementById(n)?.dispatchEvent(new KeyboardEvent(e.type,e))}});(0,w.useEffect)(()=>(document.addEventListener(`keyup`,A,!0),()=>{document.removeEventListener(`keyup`,A,!0)}),[A]);let j=ae(me(pe),`@react-aria/autocomplete`),M=l({id:h,"aria-label":j.format(`collectionLabel`)}),N=(0,w.useCallback)(e=>!c||c(e,t.inputValue),[t.inputValue,c]);return{textFieldProps:{value:t.inputValue,onChange:D,onKeyDown:k,autoComplete:`off`,"aria-haspopup":`listbox`,"aria-controls":h,"aria-autocomplete":`list`,"aria-activedescendant":t.focusedNodeId??void 0,autoCorrect:`off`,spellCheck:`false`,enterKeyHint:`go`,onBlur:e=>{if(!e.isTrusted)return;let t=v.current?document.getElementById(v.current):null;t&&y(t,e.relatedTarget)},onFocus:e=>{if(!e.isTrusted)return;let t=v.current?document.getElementById(v.current):null;if(t){let n=e.target;queueMicrotask(()=>{y(n,t),ie(t,n)})}}},collectionProps:m(M,{shouldUseVirtualFocus:x,disallowTypeAhead:!0}),collectionRef:oe,filter:c==null?void 0:N}}function ge(e){let{onInputChange:t,inputValue:n,defaultInputValue:r=``}=e,a=e=>{t&&t(e)},[o,s]=(0,w.useState)(null),[c,l]=i(n,r,a);return{inputValue:c,setInputValue:l,focusedNodeId:o,setFocusedNodeId:s}}var _e=(0,w.createContext)(null),ve=(0,w.createContext)(null),ye=(0,w.createContext)(null);function be(e){let t=f(_e,e.slot);e=m(t,e);let{filter:r,disableAutoFocusFirst:i}=e,a=ge(e),o=(0,w.useRef)(null),s=(0,w.useRef)(null),{textFieldProps:l,collectionProps:u,collectionRef:d,filter:p}=he({...c(e),filter:r,disableAutoFocusFirst:i,inputRef:o,collectionRef:s},a);return w.createElement(n,{values:[[ve,a],[T,l],[b,l],[x,{ref:o}],[ye,{filter:p,collectionProps:u,collectionRef:d}]]},e.children)}var xe=(0,w.createContext)({});export{C as a,oe as i,be as n,ye as r,xe 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.