"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9189,6684],{46895:function(e,A,a){var s=a(85893),r=a(45697),t=a.n(r),i=a(96631);let l=e=>{let{tekst:A,color:a,className:r}=e;return A?(0,s.jsx)("h1",{className:"".concat(r," proxima"),style:{fontWeight:"100",color:a},dangerouslySetInnerHTML:{__html:A}}):null};l.propTypes={tekst:t().string.isRequired,className:t().string,color:t().string},l.defaultProps={className:"mb-4 mt-2 text-start",color:i.ZP.SITE_TEXT_COLOR},A.Z=l},66684:function(e,A,a){a.r(A),a.d(A,{default:function(){return d}});var s=a(85893),r=a(40645),t=a.n(r),i=a(41664),l=a.n(i),n=a(25675),c=a.n(n);let o=[{short:"dkhavenergi",path:"/havenergi",img:(0,s.jsx)(c(),{src:{src:"/_next/static/media/dkhavenergi.ea9b6ead.png",height:21,width:139,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAABCAMAAADU3h9xAAAADFBMVEUAAAAAAAA7FQf/h1jBaQMUAAAABHRSTlNdamuLM9cX1wAAAAlwSFlzAAALEwAACxMBAJqcGAAAABFJREFUeJxjYGZiZGBgYGQAAAA3AAi2bds/AAAAAElFTkSuQmCC",blurWidth:8,blurHeight:1},alt:"DK Havenergi"})},{short:"dkvindkraft",path:"/vindkraft",img:(0,s.jsx)(c(),{src:{src:"/_next/static/media/dkvindkraft.56edf236.png",height:21,width:129,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAABCAMAAADU3h9xAAAAD1BMVEUBAQEAAAAAAAAnUViH4usY5Ve1AAAABXRSTlNqWnxUkbFtLC0AAAAJcEhZcwAACxMAAAsTAQCanBgAAAARSURBVHicY2BhZmBgYmRiBAAATgAOmH8yIAAAAABJRU5ErkJggg==",blurWidth:8,blurHeight:1},alt:"DK Vindkraft"})},{short:"dksolenergi",path:"/solenergi",img:(0,s.jsx)(c(),{src:{src:"/_next/static/media/dksolenergi.817b1aec.png",height:21,width:131,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAABCAMAAADU3h9xAAAAD1BMVEUAAAAAAAAAAABXOgL/wj/uLxtyAAAABXRSTlNvYVtgkK+IT/kAAAAJcEhZcwAACxMAAAsTAQCanBgAAAARSURBVHicY2BhZmBgZGRgAgAARwAMS3zjPQAAAABJRU5ErkJggg==",blurWidth:8,blurHeight:1},alt:"DK Solenergi"})},{short:"dkptx",path:"/ptx",img:(0,s.jsx)(c(),{src:{src:"/_next/static/media/dkptx.68668eb3.png",height:21,width:70,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAACCAMAAABSSm3fAAAAG1BMVEUAAAAAAAAAAACMmqaUoa0/TFUABAQAAABLW2fFWSqwAAAACXRSTlNzpkth+Tw3HFQHQDlWAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAGklEQVR4nGNgYeFgZGRgZGdgZmZlYmNgYAIAAekAMBociDYAAAAASUVORK5CYII=",blurWidth:8,blurHeight:2},alt:"DK PtX"})},{short:"dkinnovation",path:"/innovation",img:(0,s.jsx)(c(),{src:{src:"/_next/static/media/dkinnovation.3d7d8071.png",height:21,width:142,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAABCAMAAADU3h9xAAAAD1BMVEUAAAEAAAAAAAARABx0PaM2En1xAAAABXRSTlNVZkRYiMpHF4cAAAAJcEhZcwAACxMAAAsTAQCanBgAAAARSURBVHicY2BhZmRgYGRkAgAASwANLBssUgAAAABJRU5ErkJggg==",blurWidth:8,blurHeight:1},alt:"DK Innovation"})},{short:"dkccs",path:"/ccs",img:(0,s.jsx)(c(),{src:{src:"/_next/static/media/dkccs.20d7b17e.png",height:21,width:74,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAACCAMAAABSSm3fAAAAIVBMVEUAAAAAAAB7jlwAAAAAAQAWGwR7j1wLFgAAAAAAAACHlm6j0M0EAAAAC3RSTlNJY1hVkTjUXHaw+xBvIC8AAAAJcEhZcwAACxMAAAsTAQCanBgAAAAaSURBVHicY+BiY+dgYeRkYGBiYmVgZmBkBgAC5QA+NTE7XAAAAABJRU5ErkJggg==",blurWidth:8,blurHeight:2},alt:"DK CCS"})}];var d=()=>(0,s.jsxs)("div",{className:"jsx-72130c613bbb984d container",children:[(0,s.jsx)("header",{className:"jsx-72130c613bbb984d scroll py-2",children:o.map((e,A)=>(0,s.jsx)("div",{style:{borderLeft:0===A?"1px solid black":"none",borderRight:"1px solid black",display:"inline-block"},className:"jsx-72130c613bbb984d ps-2",children:(0,s.jsx)(l(),{href:e.path,className:"pe-2",children:e.img})},e.short))}),(0,s.jsx)(t(),{id:"72130c613bbb984d",children:".scroll.jsx-72130c613bbb984d{white-space:nowrap;overflow-x:auto;overflow-y:hidden;-webkit-overflow-scrolling:touch;-ms-overflow-style:-ms-autohiding-scrollbar}.scroll.jsx-72130c613bbb984d::-webkit-scrollbar{display:none}"})]})},57360:function(e,A,a){var s=a(85893),r=a(45697),t=a.n(r),i=a(5152),l=a.n(i),n=a(66684),c=a(47329),o=a(96631);let d=l()(()=>Promise.all([a.e(9734),a.e(8292)]).then(a.bind(a,27816)),{loadableGenerated:{webpack:()=>[27816]},ssr:!1}),h=e=>{let{children:A}=e;return(0,s.jsxs)("div",{style:{backgroundColor:o.ZP.TESTING?"pink":"white"},children:[(0,s.jsx)(c.Z,{}),(0,s.jsx)("div",{className:"container-fluid bg-white",children:(0,s.jsx)(n.default,{})}),(0,s.jsx)(d,{siteId:o.ZP.SITE_ID}),A]})};h.propTypes={children:t().oneOfType([t().array,t().object]).isRequired},A.Z=h},65035:function(e,A,a){var s=a(85893),r=a(45697),t=a.n(r),i=a(28276),l=a(41664),n=a.n(l),c=a(25675),o=a.n(c),d=a(67294),h=a(67814),g=a(65735),u=a(96631);let p=e=>{let{company:A}=e,{t:a}=(0,i.$G)("suppliers"),{id:r,name:t,dayphone:l,url:c,categories:p,logo_small:m,width:x="0",height:b="0"}=A,[j,v]=(0,d.useState)(!1),f=()=>{v(e=>!e)};return(0,s.jsx)("div",{className:"card mb-1",children:(0,s.jsxs)("div",{className:"card-body",children:[(0,s.jsxs)("div",{className:"row",children:[(0,s.jsx)("div",{className:"col-8 col-lg-10",children:(0,s.jsxs)(n(),{href:"/supplier/".concat(r),children:[(0,s.jsx)("h5",{className:"proxima",children:t}),(0,s.jsxs)("p",{children:[l&&(0,s.jsxs)(d.Fragment,{children:[l,(0,s.jsx)("br",{})]}),c&&(0,s.jsxs)(d.Fragment,{children:[c,(0,s.jsx)("br",{})]})]})]})}),(0,s.jsx)("div",{className:"col-4 col-lg-2 text-end",children:m&&+x>0&&(0,s.jsx)(n(),{href:"/supplier/".concat(r),children:(0,s.jsx)(o(),{src:"".concat(u.ZP.ANNONCE_SERVER,"medier/offshore_companies/").concat(r,"/").concat(m),alt:"Logo",className:"img-fluid",width:+x,height:+b})})})]}),p&&p.length>0&&(0,s.jsx)("div",{className:"mt-2",children:j?(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{onKeyDown:f,onClick:f,style:{cursor:"pointer"},role:"button",tabIndex:"-1",children:(0,s.jsxs)("small",{children:[(0,s.jsx)(h.G,{icon:g.eW2,className:"me-1"}),(0,s.jsx)("em",{children:a("categories")})]})}),(0,s.jsx)("div",{className:"pt-1",children:p.map(e=>(0,s.jsx)("div",{className:"tag",children:(0,s.jsx)(n(),{href:"/category/".concat(e.id),children:e.name})},e.id))})]}):(0,s.jsx)("div",{children:(0,s.jsx)("div",{onKeyDown:f,onClick:f,style:{cursor:"pointer"},role:"button",tabIndex:"-1",children:(0,s.jsxs)("small",{children:[(0,s.jsx)(h.G,{icon:g.I4f,className:"me-1"}),(0,s.jsx)("em",{children:a("categories")})]})})})})]})})};p.propTypes={company:t().object.isRequired},A.Z=p},39189:function(e,A,a){a.d(A,{Z:function(){return v}});var s=a(85893),r=a(67294),t=a(45697),i=a.n(t),l=a(41664),n=a.n(l),c=a(28276),o=a(57360),d=a(65035),h=a(89584),g=a(46895),u=a(27501),p=a(59734),m=a(32229);let x=e=>{let{handleChange:A,handleSelectChange:a,values:r}=e,{t}=(0,c.$G)("suppliers"),{data:i}=(0,p.ZP)("doi/categories/select",e=>(0,m.Z)({path:e}));return i?(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-3",children:(0,s.jsx)("input",{type:"search",style:{fontSize:"0.9rem"},className:"form-control form-control-sm",name:"supplierSearch",placeholder:t("search-company-by-name"),value:r.supplierSearch,onChange:A})}),(0,s.jsx)("div",{className:"mb-3",children:(0,s.jsx)(u.ZP,{instanceId:1,options:i,onChange:a,name:"categorySearch",value:i.find(e=>+e.value==+r.categorySearch),placeholder:t("search-company-by-category"),classNamePrefix:"form-control"})})]}):null};x.propTypes={handleChange:i().func.isRequired,handleSelectChange:i().func.isRequired,values:i().object.isRequired};var b=a(32665);let j=e=>{let{companies:A,supplierSearch:a,categorySearch:t}=e,{t:i}=(0,c.$G)("suppliers"),l=i("supplier-index"),u=i("supplier-index-description"),[p,m]=(0,r.useState)(A),[j,v]=(0,r.useState)({supplierSearch:a,categorySearch:t});return(0,r.useEffect)(()=>{let e=j.supplierSearch&&""!==j.supplierSearch?A.filter(e=>e.name.toLowerCase().indexOf(j.supplierSearch.toLowerCase())>-1):A;j.categorySearch>0&&(e=e.filter(e=>e.categories.some(e=>+e.id==+j.categorySearch))),m(e)},[j,A]),(0,s.jsxs)(o.Z,{children:[(0,s.jsx)(h.Z,{title:l,description:u}),(0,s.jsxs)("div",{className:"container py-4",children:[(0,s.jsx)(g.Z,{tekst:l}),(0,s.jsx)("div",{className:"pt-2",children:(0,s.jsx)(x,{handleChange:e=>{v(A=>({...A,[e.target.name]:e.target.value}))},handleSelectChange:e=>{v(A=>({...A,categorySearch:e.value}))},values:j})}),(0,s.jsxs)("div",{className:"d-flex justify-content-between mb-3",children:[(0,s.jsx)("div",{children:(0,s.jsxs)("em",{children:[p.length," ",i("suppliers-found")]})}),(0,s.jsx)("div",{children:(0,s.jsx)(n(),{href:"/registration",className:"btn btn-sm btn-outline-secondary",children:i("register-company")})})]}),p?p.map(e=>(0,s.jsx)(d.Z,{company:e},e.id)):null]}),(0,s.jsx)(b.Z,{})]})};j.propTypes={companies:i().array.isRequired,supplierSearch:i().string,categorySearch:i().number},j.defaultProps={supplierSearch:"",categorySearch:0};var v=j},32229:function(e,A,a){var s=a(96631),r=a(68701);let t=async e=>{var A,a;let t=null!=e?e:{};if(void 0===t.path)return console.log("path mangler",t),null;t.site_id=null!==(a=null!==(A=e.site_id)&&void 0!==A?A:e.siteId)&&void 0!==a?a:s.ZP.SITE_ID;try{let A=new URL("".concat(s.ZP.API_SERVER).concat(t.path,"/"));A.search=new URLSearchParams({...t});let a=await fetch(A),i=await a.json();if("undefined"!=typeof Storage&&((0,r.Aj)(),"ipaftale"===e.path)){let e=i.result.show_ip;(0,r.V9)(e)&&localStorage.setItem("ip",(0,r.h0)(e))}return void 0!==e.fullJson?i:i.result}catch(e){return console.log(e,t),null}},i=async e=>{var A,a,r,t;let i=null!=e?e:{};if(void 0===i.path)return console.log("path mangler",i),null;i.site_id=null!==(a=null!==(A=e.site_id)&&void 0!==A?A:e.siteId)&&void 0!==a?a:s.ZP.SITE_ID;let l=new URL(s.ZP.PROXY_SERVER);l.search=new URLSearchParams({...i});try{let e=await fetch(l),A=await e.json(),a=null!==(t=null!==(r=null==A?void 0:A.error)&&void 0!==r?r:null==A?void 0:A.message)&&void 0!==t?t:null;if(a)return console.log(i.path,a),null;return A}catch(e){return console.log("fetchParams",{error:"fetchDataError",path:i.path}),null}},l=async e=>{let A;let a=void 0===e.bypassProxy&&s.ZP.USE_PROXY,r={...e};if("ipaftale"===e.path){var l,n;r.host=null===(n=window)||void 0===n?void 0:null===(l=n.location)||void 0===l?void 0:l.host}return a&&(A=await i(r))?A:A=await t(r)};A.Z=l}}]);