1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7345],{25082:function(e,n,t){"use strict";t.d(n,{Gh:function(){return u},W2:function(){return c}});var r=t(18003),o=t(13492),i=t(92084),c=((0,i.Z)((function(e){var n,t=e.breakpoints;return{root:(n={minHeight:387,display:"grid",width:930,margin:"0 auto",gridTemplateColumns:"repeat(auto-fill, minmax(232px, 1fr))"},(0,r.Z)(n,t.down("sm"),{width:"100%",gridTemplateColumns:"repeat(auto-fill, minmax(188px, 1fr))"}),(0,r.Z)(n,t.down("xs"),{gridTemplateColumns:"50% 50%"}),n)}}))(o.Z),(0,i.Z)((function(e){return{root:{margin:(0,e.spacing)(4,"auto"),display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center","& > #note":{display:"flex",justifyContent:"center",width:"100%",textAlign:"center",alignItems:"center",padding:"20px",fontSize:"18px"}}}}))(o.Z)),u=(0,i.Z)((function(e){var n=e.breakpoints,t=e.spacing;return{root:(0,r.Z)({width:930,textAlign:"center"},n.down("sm"),{width:"100%",padding:t(0,2)})}}))(o.Z)},5079:function(e,n,t){"use strict";t.r(n),t.d(n,{__N_SSP:function(){return B},default:function(){return M}});var r=t(11729),o=t(66105),i=t(1984),c=t.n(i),u=t(53014),a=t(18003),l=t(75234),d=t(25883),s=t(14219),p=t.n(s),f=t(65117),g=t.n(f),h=t(52082),y=t(62044),m=t(56168),v=t(72091),C=t.n(v),L=t(90731),b=t.n(L),j=t(42783),Z=t(32376),k=t(22217),x=t(65453),w=t(73814),q=t(91565),T=t(85383),O=t(85637),N=t(75332),P=t(20668),S=t(49275),_=t(25082),I=t(12969),E=t(98421),A=t(8014);function D(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function R(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?D(Object(t),!0).forEach((function(n){(0,a.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):D(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var U=(0,Z.Z)((function(e){return{loader:{textAlign:"center"}}})),W=function(){(0,y.Z)().t;var e=U();return(0,A.jsx)("div",{className:e.loader,children:(0,A.jsx)("h1",{children:"Loading..."})})},X=g()((function(){return Promise.all([t.e(3662),t.e(3284)]).then(t.bind(t,73284))}),{ssr:!1,loading:function(){return(0,A.jsx)(W,{})},loadableGenerated:{webpack:function(){return[73284]}}}),z=m.memo((function(e){var n,t=e.data,o=(0,N.useRouter)(),i=(0,y.Z)().t,c=(0,O.bp)(),u=c.state,s=c.dispatch,f=(0,q.N3)(u),g=m.useState(!1),v=(0,r.Z)(g,2),L=v[0],Z=(v[1],m.useState(t)),D=(0,r.Z)(Z,2),U=D[0],W=D[1],z=m.useState({pageSize:12,count:0,page:1}),F=(0,r.Z)(z,2),G=F[0],B=F[1],M=new URLSearchParams(window.location.search),H=M.getAll("brands"),Q=M.getAll("coverage"),J=M.getAll("finish"),K=M.getAll("type"),V=M.getAll("formula"),Y=M.getAll("skinType"),$=M.getAll("skinConcern"),ee=M.getAll("ingredients");(0,m.useEffect)((function(){if(U&&0===U.length){var e="".concat(H.length?"".concat(H.join(",")," "):""," ");e="".concat(e).concat(Q.length?" | ".concat(Q.join(",")):""),e="".concat(e).concat(J.length?" | ".concat(J.join(",")):""),e="".concat(e).concat(K.length?" | ".concat(K.join(",")):""),e="".concat(e).concat(V.length?" | ".concat(V.join(",")):""),e="".concat(e).concat(Y.length?" | ".concat(Y.join(",")):""),e="".concat(e).concat($.length?" | ".concat($.join(",")):""),e="".concat(e).concat(ee.length?" | ".concat(ee.join(",")):"")}}),[U]),(0,m.useEffect)((function(){t&&t.length&&W(t)}),[t]),function(){var e=(0,N.useRouter)(),n=(0,O.bp)().dispatch;(0,m.useEffect)((function(){(0,w.Z)(e.query)||n((0,T.s2)((0,x.dB)(e.query)))}),[e.query])}();var ne=M.get("brands"),te=M.get("key"),re=function(){var e=(0,d.Z)(p().mark((function e(){var n,t,r,o;return p().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!ne||!te){e.next=8;break}return e.next=3,(0,S.rQ)("".concat("https://www.matchmymakeup.com","/client/productline/"),{enableAuth:!1});case 3:n=e.sent,t=n.map((function(e){var n,t;return{id:e.id,brandName:e.brand,productId:e.id,productLineImage:e&&e.productLineImage&&null!==(n=e.productLineImage)&&void 0!==n&&n.imageWebPath?null===(t=e.productLineImage)||void 0===t?void 0:t.imageWebPath:"",productLineName:e.productName,productName:e.productName,lightness:e.lightness?e.lightness:"Same",colourTemperature:e.colourTemperature?e.colourTemperature:"Warm",shadeId:e.id,coverage:e.productLine&&e.productLine.coverage?e.productLine.coverage:"",finish:e.productLine&&e.productLine.finish?e.productLine.finish:"",type:e.productLine&&e.productLine.type?e.productLine.type:"",formula:e.productLine&&e.productLine.formula?e.productLine.formula:[],productLineCategory:e.productLine&&e.productLine.productLineCategory?e.productLine.productLineCategory:{}}})),r=t.filter((function(e){return e.brandName===ne})),o=C()(r,"brandName"),W(o);case 8:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();(0,m.useEffect)((function(){ne&&"f"===te&&re()}),[ne,te]),(0,m.useEffect)((function(){var e=t||[],n=[];H.length&&(H.filter((function(e){var r=null===t||void 0===t?void 0:t.filter((function(n){return n.brandName===e}));return null!==r&&void 0!==r&&r.length&&n.push.apply(n,(0,l.Z)(r)),""})),e=b()(n,"shadeId"));var r=[];Q.length&&(Q.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.coverage&&e.productLineCategory.coverage.find((function(e){return e===n}))&&r.push(e),""})),""})),e=b()(r,"id"));var o=[];J.length&&(J.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.finish&&e.productLineCategory.finish.find((function(e){return e===n}))&&o.push(e),""})),""})),e=b()(o,"id"));var i=[];K.length&&(K.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.type&&e.productLineCategory.type===n&&i.push(e),""})),""})),e=b()(i,"id"));var c=[];V.length&&(V.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.formula&&e.productLineCategory.formula.find((function(e){return e===n}))&&c.push(e),""})),""})),e=b()(c,"id"));var u=[];Y.length&&(Y.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.skinType&&e.productLineCategory.skinType.find((function(e){return e===n}))&&u.push(e),""})),""})),e=b()(u,"id"));var a=[];$.length&&($.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.skinConcern&&e.productLineCategory.skinConcern.find((function(e){return e===n}))&&a.push(e),""})),""})),e=b()(a,"id"));var d=[];ee.length&&(ee.filter((function(n){return e.filter((function(e){return e.productLineCategory&&e.productLineCategory.productIngredient&&e.productLineCategory.productIngredient.find((function(e){return e===n}))&&d.push(e),""})),""})),e=b()(d,"id")),H.length||Q.length||J.length||K.length||V.length||Y.length||$.length||ee.length?(W(C()(e,["level","brandName"])),B(R(R({},G),{},{count:e.length,page:1}))):W(C()(t,["level","brandName"]))}),[o.query.brands,o.query.coverage,o.query.finish,o.query.type,o.query.formula,o.query.skinConcern,o.query.skinType,o.query.ingredients]);var oe=(n={},(0,a.Z)(n,j.h2.Brands,[]),(0,a.Z)(n,j.h2.Coverage,[]),(0,a.Z)(n,j.h2.Finish,[]),(0,a.Z)(n,j.h2.Type,[]),(0,a.Z)(n,j.h2.Formula,[]),(0,a.Z)(n,j.h2.Ingredients,[]),(0,a.Z)(n,j.h2.SkinConcern,[]),(0,a.Z)(n,j.h2.SkinType,[]),n),ie=function(e,n,t){var r=(0,x.t7)(h.Z.PRODUCTS,e,t),i=r;n&&n.length&&(i=R(R({},r),{},{query:R(R({},r.query),{},{brands:n})})),e&&e.coverage&&e.coverage.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{coverage:e.coverage})})),e&&e.finish&&e.finish.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{finish:e.finish})})),e&&e.type&&e.type.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{type:e.type})})),e&&e.formula&&e.formula.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{formula:e.formula})})),e&&e.skinType&&e.skinType.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{skinType:e.skinType})})),e&&e.skinConcern&&e.skinConcern.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{skinConcern:e.skinConcern})})),e&&e.ingredients&&e.ingredients.length&&(i=R(R({},i),{},{query:R(R({},i.query),{},{ingredients:e.ingredients})})),s((0,T.s2)(e)),o.push(i)};return(0,w.Z)(U)?(0,A.jsxs)(E.Rz,{children:[(0,A.jsx)(P.Z,{message:i("common:empty-products")}),(0,A.jsx)(k.Z,{color:"primary",onClick:function(){var e,n;e=R(R({},f),oe),o.push((0,x.t7)(h.Z.PRODUCTS,e,n))},children:"See other matching products"})]}):(0,A.jsxs)(_.W2,{children:[(0,A.jsx)(X,{apply:ie,handleClear:function(e){W(t),B(R(R({},G),{},{count:t.length})),s((0,T.s2)(j.oG)),o.push((0,x.t7)(h.Z.PRODUCTS,e))},handleClear2:function(e){o.push((0,x.t7)(h.Z.PRODUCTS,e))},data:U,matchData:t}),U&&U.length>0?(0,A.jsx)("div",{id:"note",children:"Images demonstrate packaging only, see the match bubble for an indication of your matched shade."}):null,U&&U.length>0?(0,A.jsx)(I.Z,{data:U,loader:L,pageInfo:G,handlePageChange:function(e,n){B(R(R({},G),{},{page:n})),ie(f,n)}}):null]})})),F=(0,m.memo)(z),G=t(4444);var B=!0,M=function(e){var n=e.products,t=e.locale,i=m.useState(!1),a=(0,r.Z)(i,2),l=a[0],d=a[1],s=(0,N.useRouter)().asPath,p="en"!==t?"".concat(G.env.NEXT_SITE_DOMAIN,"/").concat(t).concat(s):"".concat(G.env.NEXT_SITE_DOMAIN).concat(s);return(0,A.jsxs)(A.Fragment,{children:[(0,A.jsxs)(c(),{children:[(0,A.jsx)("link",{rel:"canonical",href:p}),(0,A.jsx)("meta",{property:"og:image",content:"/static/images/background/seo.jpeg"})]}),(0,A.jsx)(u.Z,{children:l?(0,A.jsx)(o.Z,{}):(0,A.jsx)(F,{handleError:function(){d(!0)},data:n})})]})}},67153:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/products",function(){return t(5079)}])}},function(e){e.O(0,[3714,2835,4885,3591,7710,8335,1157,8979,5613,9470,6722,5323,2152,8428,466,4734,3014,4990,9774,2888,179],(function(){return n=67153,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
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.