1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7177],{161:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});let n="https://cached-api.voxmarkets.co.uk/img",s=e=>e.includes("vox.store.images"),o=e=>e.includes("vox.assets.public"),l=e=>e<=64?64:e<=320?320:e<=640?640:1024,i=()=>!0;function a(e){let{src:t,width:r,height:a,quality:c}=e,u=l(r);if(s(t)){let e=encodeURIComponent(t),r="".concat(n,"/resize?nocrop=true&width=").concat(u,"&url=").concat(e);return i()?"".concat(n,"/resize?nocrop=true&type=webp&width=").concat(u,"&url=").concat(e):r}if(o(t)){let e="".concat(n,"/resize?nocrop=true&width=").concat(u,"&url=").concat(t);return i()?"".concat(n,"/resize?nocrop=true&type=webp&width=").concat(u,"&url=").concat(t):e}if(t.includes("vox.store.images")){let e=encodeURIComponent(t),r="".concat(n,"/resize?nocrop=true&width=").concat(u,"&url=").concat(e);return i()?"".concat(n,"/resize?nocrop=true&type=webp&width=").concat(u,"&url=").concat(e):r}return t}},3400:(e,t,r)=>{"use strict";r.d(t,{default:()=>h});var n=r(5155),s=r(2115),o=r(6874),l=r.n(o),i=r(8889),a=r(5886),c=r(8618),u=r(2035),d=r(1890);function h(){let{user:e,loading:t,refresh:r}
1=(0,i.Ay)(),[o,h]=(0,s.useState)(!1),[m,p]=(0,s.useState)(!1),f=(0,s.useRef)(null);(0,s.useEffect)(()=>{let e=e=>{f.current&&!f.current.contains(e.target)&&p(!1)};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[]),(0,s.useEffect)(()=>{if(!t&&!e)try{{let e="vm-login-overlay-should-reopen";"1"===sessionStorage.getItem(e)&&(sessionStorage.removeItem(e),h(!0))}}catch(e){}},[t,e]);let g=async()=>{h(!1),"undefined"!=typeof document&&(document.cookie="vox-logout-pending=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT; secure; samesite=lax"),await r()};if(t)return(0,n.jsx)("div",{});if(!e)return(0,n.jsxs)("div",{children:[(0,n.jsxs)(c.nz,{onClick:()=>h(!0),className:"mx-1 p-2 md:px-4 md:py-3 border border-2 border-white border-solid transition-colors cursor-pointer",href:"#",children:["Log In",(0,n.jsx)("svg",{className:"inline-block ml-2",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,n.jsx)("path",{d:"M9.9987 10.8333C12.2999 10.8333 14.1654 8.96785 14.1654 6.66667C14.1654 4.36548 12.2999 2.5 9.9987 2.5C7.69751 2.5 5.83203 4.36548 5.83203 6.66667C5.83203 8.96785 7.69751 10.8333 9.9987 10.8333ZM9.9987 10.8333C11.7668 10.8333 13.4625 11.5357 14.7127 12.786C15.963 14.0362 16.6654 15.7319 16.6654 17.5M9.9987 10.8333C8.23059 10.8333 6.53489 11.5357 5.28465 12.786C4.03441 14.0362 3.33203 15.7319 3.33203 17.5",stroke:"white",strokeWidth:"1.66667",strokeLinecap:"round",strokeLinejoin:"round"})})]}),(0,n.jsxs)(c.jn,{className:"mx-1 p-2 md:px-4 md:py-3 border border-2 border-vox-yellow border-solid transition-colors cursor-pointer",href:"/registration",children:["Join ",(0,n.jsx)("span",{className:"hidden lg:inline",children:"Community"}),(0,n.jsxs)("svg",{className:"inline-block ml-2",width:"29",height:"29",viewBox:"0 0 29 29",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,n.jsx)("g",{clipPath:"url(#clip0_2638_20269)",children:(0,n.jsx)("path",{d:"M8.93217 19.3812L18.8317 9.48175M18.8317 9.48175H8.93217M18.8317 9.48175V19.3812",stroke:"#002840",strokeWidth:"2"})}),(0,n.jsx)("defs",{children:(0,n.jsx)("clipPath",{id:"clip0_2638_20269",children:(0,n.jsx)("rect",{width:"24",height:"16",fill:"white",transform:"translate(0 16.9999) rotate(-45)"})})})]})]}),(0,n.jsx)(a.A,{isOpen:o,onClose:()=>h(!1),onSwitchToSignup:()=>{h(!1),window.location.href="/registration"},onLoginSuccess:g})]});let x=()=>{(0,i.US)(),(0,u.clearUserProperties)();let e="https://www.voxmarkets.co.uk:3636",t=new URL("/",d.env.NEXT_PUBLIC_SITE_URL||window.location.origin).toString(),r=new URL("/api/auth/signout",window.location.origin);if(r.searchParams.set("redirect",t),e&&e!==window.location.origin){let t=new URL("/api/auth/signout",e);t.searchParams.set("redirect",r.toString()),window.location.href=t.toString()}else window.location.href=r.toString()};return(0,n.jsxs)("div",{className:"relative",ref:f,children:[(0,n.jsxs)("div",{className:"flex items-center space-x-2 cursor-pointer",onClick:()=>p(!m),children:[(0,n.jsx)(l(),{href:"/profile",className:"text-white",children:(0,n.jsx)("div",{className:"w-12 h-12 bg-gradient-to-br from-vox-yellow to-black/10 rounded-full flex items-center justify-center text-white font-semibold text-lg hover:from-vox-yellow hover:to-black transition-colors",children:(e=>{if(!e)return"?";let t=e.display_name||e.name||e.login||"";if(!t)return"?";let r=t.trim().split(/\s+/);return r.length>=2?(r[0][0]+r[r.length-1][0]).toUpperCase():1===r.length?r[0].substring(0,2).toUpperCase():"?"})(e)})}),(0,n.jsx)("svg",{className:"w-4 h-4 text-white transition-transform duration-200 ".concat(m?"rotate-180":""),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,n.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})]}),m&&(0,n.jsxs)("div",{className:"absolute right-0 mt-2 w-48 bg-white rounded-md shadow-lg py-1 z-50 border border-gray-200",children:[(0,n.jsx)(l(),{href:"/profile",className:"block w-full text-left px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 hover:text-gray-900 transition-colors",children:"Profile Settings"}),(0,n.jsx)(l(),{href:"/profile/watchlist",className:"block w-full text-left px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 hover:text-gray-900 transition-colors",children:"Manage Watchlist"}),(0,n.jsx)("button",{onClick:()=>{x(),p(!1)},className:"block w-full text-left px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 hover:text-gray-900 transition-colors",children:"Logout"})]})]})}},4004:()=>{},5120:(e,t,r)=>{Promise.resolve().then(r.t.bind(r,6874,23)),Promise.resolve().then(r.t.bind(r,3063,23)),Promise.resolve().then(r.t.bind(r,5932,23)),Promise.resolve().then(r.t.bind(r,4004,23)),Promise.resolve().then(r.bind(r,7736)),Promise.resolve().then(r.t.bind(r,8101,23)),Promise.resolve().then(r.t.bind(r,8508,23)),Promise.resolve().then(r.bind(r,7896)),Promise.resolve().then(r.bind(r,3400)),Promise.resolve().then(r.bind(r,5690)),Promise.resolve().then(r.bind(r,2540))},5932:e=>{e.exports={style:{fontFamily:"'Inter', 'Inter Fallback'",fontStyle:"normal"},className:"__className_f367f3"}},7736:(e,t,r)=>{"use strict";r.d(t,{default:()=>i});var n=r(2115),s=r(5695),o=r(8889),l=r(2035);
1function i(){let e=(0,s.usePathname)(),t=(0,s.useSearchParams)(),{user:r,loading:i}=(0,o.Ay)();return(0,n.useEffect)(()=>{i||(r&&r.id?(0,l.setUserProperties)(r):(0,l.clearUserProperties)())},[r,i]),(0,n.useEffect)(()=>{},[e,t]),null}},7896:(e,t,r)=>{"use strict";r.d(t,{default:()=>c});var n=r(5155),s=r(2115),o=r(9715);r(6874);var l=r(5695),i=r(2035);let a=e=>{if(!e)return null;let t=e.split(":");return t.length>1?(0,n.jsxs)("span",{children:[(0,n.jsx)("strong",{children:t[0]}),":",t[1]]}):(0,n.jsx)("span",{children:(0,n.jsx)("strong",{children:e})})},c=e=>{var t;let{market:r,sector:c,sectorFilter:u,marketFilter:d,handleResults:h,className:m}=e,p=(0,l.useRouter)(),f=(0,l.usePathname)(),[g,x]=(0,s.useState)(""),[v,w]=(0,s.useState)({qmsecurities:[]}),[b,y]=(0,s.useState)(!1),[j,k]=(0,s.useState)(!1),[N,S]=(0,s.useState)(!1),[_,C]=(0,s.useState)(c||u||null),[P,L]=(0,s.useState)(r||d||null);(0,s.useEffect)(()=>{C(u||c||null),L(d||r||null)},[u,d,c,r]),(0,s.useEffect)(()=>{g.trim()&&(E.current&&clearTimeout(E.current),E.current=setTimeout(()=>{I(g)},100))},[_,P]);let E=(0,s.useRef)(null),T=(0,s.useRef)(null),U=(0,s.useRef)(null);(0,s.useEffect)(()=>{S(!1),x("")},[f]),(0,s.useEffect)(()=>()=>{E.current&&clearTimeout(E.current),T.current&&T.current.abort(),U.current&&clearTimeout(U.current)},[]);let I=async e=>{T.current&&T.current.abort(),T.current=new AbortController;try{var t;k(!0);let r=new URLSearchParams({q:e});_&&r.append("sector",_),P&&r.append("market",P);let n=await fetch((0,o.Sw)("/search?".concat(r.toString())),{signal:T.current.signal});if(!n.ok)throw Error("Search failed");let s=await n.json(),l=s.results||s;w(l),h?h(l):y(!0);let a=(null==l?void 0:null===(t=l.qmsecurities)||void 0===t?void 0:t.length)||0;(0,i.trackSuggestionsLoaded)(a,e)}catch(e){"AbortError"!==e.name&&(console.error("Search error:",e),y(!1))}finally{k(!1)}},R=(e,t)=>{t.preventDefault(),x(e.longname),y(!1),S(!0),(0,i.trackSuggestionAccepted)(g,e),e.symbolstring?p.push("/listings/".concat(e.symbolstring)):e.companySlug&&p.push("/company/".concat(e.companySlug))};return(0,n.jsxs)("div",{className:"relative w-full",children:[(0,n.jsx)("input",{type:"text",value:g,onChange:e=>{let t=e.target.value;x(t),t.trim()&&!g.trim()?(0,i.trackSearchTyping)("start"):t.trim()&&(0,i.trackSearchTyping)("continue"),E.current&&clearTimeout(E.current),t.trim()?E.current=setTimeout(()=>{I(t)},300):(T.current&&T.current.abort(),y(!1),k(!1),h&&h(null))},onFocus:()=>{var e;U.current&&clearTimeout(U.current),!h&&g.trim()&&(null==v?void 0:null===(e=v.qmsecurities)||void 0===e?void 0:e.length)>0&&y(!0)},onBlur:()=>{U.current=setTimeout(()=>{y(!1)},200)},placeholder:"Company search...",className:"w-full p-2 border border-gray-300 rounded-full bg-white focus:outline-none focus:ring-2 focus:ring-blue-500 ".concat(m||""),disabled:N}),N&&(0,n.jsx)("div",{className:"absolute top-0 left-0 w-full h-full flex items-center justify-center bg-white bg-opacity-75 rounded-full",children:(0,n.jsx)("span",{className:"text-sm text-gray-600",children:"Loading..."})}),b&&!N&&!h&&(0,n.jsx)("ul",{className:"absolute bg-white border border-gray-300 rounded-2xl shadow-lg w-full overflow-hidden z-50",children:j?(0,n.jsx)("li",{className:"p-2 text-sm text-gray-500",children:"Searching..."}):(null==v?void 0:null===(t=v.qmsecurities)||void 0===t?void 0:t.length)>0?v.qmsecurities.map((e,t)=>(0,n.jsx)("li",{onClick:t=>R(e,t),className:"p-2 hover:bg-gray-200 cursor-pointer text-sm",children:(0,n.jsxs)("div",{className:"pointer-events-none",children:[e.longname," ",a(e.symbolstring)]})},t)):(0,n.jsx)("li",{className:"p-2 text-sm text-gray-500",children:"No suggestions found"})})]})}},8101:()=>{},8508:e=>{e.exports={style:{fontFamily:"'satoshi', 'satoshi Fallback', Inter, ui-sans-serif, system-ui, sans-serif"},className:"__className_3f250c",variable:"__variable_3f250c"}},8618:(e,t,r)=>{"use strict";r.d(t,{Ti:()=>a,jn:()=>c,nz:()=>i});var n=r(5155),s=r(6874),o=r.n(s);let l="rounded-full px-4 py-2 text-center hover:shadow-md inline-block whitespace-nowrap";function i(e){let{children:t,className:r,href:s,...i}=e,a="bg-vox-blue text-white ".concat(l," ").concat(r);return s?(0,n.jsx)(o(),{href:s,className:a,...i,children:t}):(0,n.jsx)("span",{className:a,...i,children:t})}function a(e){let{children:t,className:r,href:s,...i}=e,a="bg-gray-200 px-4 py-2 rounded-full border-white ".concat(l," ").concat(r);return s?(0,n.jsx)(o(),{href:s,className:a,...i,children:t}):(0,n.jsx)("span",{className:a,...i,children:t})}function c(e){let{children:t,className:r,href:s,...i}=e;return s?(0,n.jsx)(o(),{href:s,className:"bg-vox-yellow text-vox-blue ".concat(l," ").concat(r),...i,children:t}):(0,n.jsx)("span",{className:classes,...i,children:t})}},9715:(e,t,r)=>{"use strict";r.d(t,{Sw:()=>s});var n=r(1890);
1function s(e){let t=function(){let e=n.env.NEXT_PUBLIC_V4_BASE||n.env.V4_BASE_URL;return e||(!function(){{var e;let t=(null===(e=window.location)||void 0===e?void 0:e.hostname)||"";return"localhost"===t||"127.0.0.1"===t}}()?"https://api.voxmarkets.co.uk/v4":n.env.NEXT_PUBLIC_LOCAL_API_BASE||"http://localhost:3002/api")}(),r=e.startsWith("/")?e:"/".concat(e);return"".concat(t).concat(r)}}},e=>{var t=t=>e(e.s=t);e.O(0,[8151,6874,3063,6520,5690,8441,1684,7358],()=>t(5120)),_N_E=e.O()}]);
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.