1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[368],{3278:(e,t,n)=>{"use strict";n.d(t,{R:()=>o});var r=n(7876),i=n(4232),l=n(4e3),c=n(674),a=n(4587),s=n.n(a);let u=e=>{let{onZoomIn:t,onZoomOut:n}=e;return(0,r.jsxs)("div",{className:"map-controls",children:[(0,r.jsx)("button",{onClick:t,className:"zoom-btn",children:(0,r.jsx)(s(),{className:"zoom-icon",src:"/add.png",alt:"Zoom In",width:44,height:44,priority:!0})}),(0,r.jsx)("button",{onClick:n,className:"zoom-btn",children:(0,r.jsx)(s(),{className:"zoom-icon",src:"/minus.png",alt:"Zoom Out",width:44,height:44,priority:!0})})]})};function o(e){let{multiSelect:t=!1,name:n,children:a}=e,s=(0,i.useRef)(null),o=(0,i.useRef)(null),h=(0,i.useRef)(null),{zoomIn:d,zoomOut:m}=((0,i.useEffect)(()=>{let e;if(!s.current||!o.current||!h)return;let t=c.Ltv(s.current),n=t.selectChild("#image").node();if(!n)throw Error("Cannot find #image node in the SVG structure.");let{width:r,height:i}=n.getBoundingClientRect(),l=c.s_O().on("zoom",function(e){let{transform:t}=e;o.current&&c.Ltv(o.current).attr("transform",t.toString())});function a(){let e=t.node();if(!e)return;let{width:n,height:c}=e.getBoundingClientRect(),a=Math.max(n/r,c/i);l.scaleExtent([a,8]).extent([[0,0],[n,c]]).translateExtent([[0,0],[r,i]]),l.scaleTo(t,a)}h.current=l,t.call(l).on("dblclick.zoom",null),a();let u=()=>{clearTimeout(e),e=setTimeout(()=>{a()},100)};return window.addEventListener("resize",u,{passive:!0}),()=>{window.removeEventListener("resize",u)}},[o,s,h]),{zoomIn:function(){if(s.current&&h.current){let e=c.Ltv(s.current);h.current.scaleBy(e.transition().duration(200),1.2)}},zoomOut:function(){if(s.current&&h.current){let e=c.Ltv(s.current);h.current.scaleBy(e.transition().duration(200),.8)}}});return!function(e,t,n,r){let a=(0,l.useRouter)(),s=(0,l.usePathname)(),u=(0,l.useSearchParams)(),o=(0,i.useRef)(new Set),h=(0,i.useRef)(!1),d=(0,i.useRef)(!0),m=window.matchMedia("(max-width: 500px)").matches,x=()=>{let n;if(!e.current||!t.current)return;h.current=!0;let i=Array.from(o.current).map(e=>document.getElementById(e)).filter(e=>null!==e);if(i.length>0)n=i.reduce((t,n)=>{let r=n.getBBox(),i=n.getCTM();if(!i)return t;let l=[{x:r.x,y:r.y},{x:r.x+r.width,y:r.y},{x:r.x,y:r.y+r.height},{x:r.x+r.width,y:r.y+r.height}].map(t=>{let n=e.current.createSVGPoint();return n.x=t.x,n.y=t.y,n.matrixTransform(i)}),c=Math.min(...l.map(e=>e.x)),a=Math.min(...l.map(e=>e.y)),s=Math.max(...l.map(e=>e.x)),u=Math.max(...l.map(e=>e.y));return t?{x:Math.min(t.x,c),y:Math.min(t.y,a),width:Math.max(t.x+t.width,s)-Math.min(t.x,c),height:Math.max(t.y+t.height,u)-Math.min(t.y,a)}:{x:c,y:a,width:s-c,height:u-a}},null);else if(d.current){let t=e.current.getBBox();n=m?{x:t.x+.25*t.width,y:t.y+.25*t.height,width:.5*t.width,height:.5*t.height}:{x:t.x,y:t.y,width:t.width,height:t.height}}else{h.current=!1;return}if(!n){h.current=!1;return}let l=e.current.clientWidth,a=e.current.clientHeight,s=l/n.width,u=a/n.height,x=i.length?Math.min(Math.min(s,u),4):({absheron:1.5,bina:1.8,sederek:2.5})[r]||1,f=n.x+n.width/2,g=n.y+n.height/2,w=null;w=i.length?c.GSI.translate(l/2,a/2).scale(x).translate(-f,-g):c.GSI.translate(m?-l:0,0).scale(x),c.Ltv(e.current).transition().duration(750).ease(c.TD8).call(t.current.transform,w).on("end",()=>{h.current=!1,d.current&&(d.current=!1)}).on("interrupt",()=>{h.current=!1})};(0,i.useEffect)(()=>{var n,r,i;if(o.current=new Set(((null===(n=u.get("ids"))||void 0===n?void 0:n.split(","))||[]).filter(Boolean)),(null==e?void 0:null===(r=e.current)||void 0===r?void 0:r.clientWidth)>0&&(null==e?void 0:null===(i=e.current)||void 0===i?void 0:i.clientHeight)>0&&(null==t?void 0:t.current)){let e=requestAnimationFrame(()=>{x()});return()=>cancelAnimationFrame(e)}},[u,e,t]),(0,i.useEffect)(()=>{let r=c.Ubm("[id*='shop']");r.each(function(){let e=c.Ltv(this),t=this.id;e.classed("selected",o.current.has(t))}),r.on("click",function(i){if(h.current){i.stopPropagation();return}i.stopPropagation();let l=c.Ltv(this),d=this.id,m=l.classed("selected");if(!(null==e?void 0:e.current)||!(null==t?void 0:t.current))return;n||(r.classed("selected",!1),o.current.clear()),m||(l.classed("selected",!0),o.current.add(d)),m&&n&&(l.classed("selected",!1),o.current.delete(d));let f=new URLSearchParams(u.toString()),g=Array.from(o.current).join(",");o.current.size>0?(f.set("ids",g),x()):f.delete("ids"),a.replace("".concat(s,"?").concat(f.toString()),{scroll:!1})})},[s,a,u,e,t,n])}(s,h,t,n),(0,r.jsxs)("div",{style:{position:"relative",width:"100%",height:"100%"},children:[(0,r.jsx)(u,{onZoomIn:d,onZoomOut:m}),(0,r.jsx)("svg",{ref:s,id:"map",width:"100%",height:"100%",style:{border:"1px solid #e5e7eba8",borderRadius:"8px"},children:(0,r.jsx)("g",{id:"image",children:(0,r.jsx)("g",{ref:o,children:a})})})]})}},5216:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>a});var r=n(7876),i=n(4232),l=n(3278),c=n(3292);function a(){return(0,r.jsx)("div",{style:{width:"100%",height:"calc(100vh)",overflow:"hidden"},children:(0,r.jsx)(i.Suspense,{fallback:(0,r.jsx)("div",{children:"Loading..."}),children:(0,r.jsx)(l.R,{name:"bina",children:(0,r.jsx)(c.default,{})})})})}},8019:(e,t,n)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/maps/bina",function(){return n(5216)}])}},e=>{var t=t=>e(e.s=t);e.O(0,[587,489,292,636,593,792],()=>t(8019)),_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.