@nyris/nyris-webapp 0.3.46 → 0.3.47

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +0,0 @@
1
- /*! For license information please see main.d68884f6.chunk.js.LICENSE.txt */
2
- (this["webpackJsonp@nyris/nyris-webapp"]=this["webpackJsonp@nyris/nyris-webapp"]||[]).push([[0],{218:function(e,t,n){e.exports=n.p+"static/media/Union.2545c072.svg"},276:function(e,t,n){e.exports=n.p+"static/media/no-image.04b676b3.svg"},277:function(e,t,n){e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.l=!0,a.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(r,a,function(t){return e[t]}.bind(null,a));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=2)}([function(e,t){e.exports=n(0)},function(e,t){e.exports=n(59)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(3);t.Preview=r.default;var a=n(7);t.Capture=a.default,function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(14))},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=a(n(0)),l=n(4),c=n(1),u=o(n(5)),s=n(6),f=function(e){return e.dotHover?"pointer":e.tlHover?"nw-resize":e.trHover?"ne-resize":e.blHover?"sw-resize":e.brHover?"se-resize":e.rectHover?"move":"default"};t.default=function(e){var t=e.dotColor,n=e.image,a=e.maxHeight,o=e.maxWidth,d=e.minCropHeight,p=e.minCropWidth,h=e.onSelectionChange,m=e.regions,g=e.rounded,v=e.selection,y=e.expandAnimation,b=c.getThumbSizeLongestEdge(o,a,n.width,n.height),x=b.w,w=b.h,C=function(e,t,n,r,a){var o=n.x1,i=n.x2,l=n.y1,c=n.y2,u={x1:Math.max(o*e,5),x2:Math.min(i*e,e-5),y1:Math.max(l*t,5),y2:Math.min(c*t,t-5)};return r&&a&&u.x2-u.x1<r&&u.y2-u.y1<a?{x1:Math.max(o*e-r/2,5),x2:Math.min(i*e+r/2,e-5),y1:Math.max(l*t-a/2,5),y2:Math.min(c*t+a/2,t-5)}:u}(x,w,v,p,d),E=C.x1,O=C.y1,j=C.x2,L=C.y2,k=[100,100],S=k[0],R=k[1],N=i.useRef(null),I=i.useState({tlHover:!1,trHover:!1,blHover:!1,brHover:!1,dotHover:!1,rectHover:!1}),M=I[0],_=I[1],F=function(e){var t={};Object.assign(t,M,e),_(t)},T=function(e,t){if(!(t.target instanceof u.default.Stage)){var n=t.target.getAbsolutePosition(),r=n.x,a=n.y,o=t.target.getSize(),i=o.width,l=o.height,c=function(e,t,n,r,a,o){var i=e.x1,l=e.x2,c=e.y1,u=e.y2;switch(t){case"rect":return{x1:n,y1:r,x2:n+a,y2:r+o};case"tl":return{x1:n,y1:r,x2:l,y2:u};case"tr":return{x2:n,y1:r,x1:i,y2:u};case"bl":return{x1:n,y2:r,x2:l,y1:c};case"br":return{x2:n,y2:r,x1:i,y1:c}}}({x1:E,x2:j,y1:O,y2:L},e,r+("rect"!==e?D:0),a+("rect"!==e?D:0),i,l),s={x1:c.x1/x,x2:c.x2/x,y1:c.y1/w,y2:c.y2/w};G(s)}};i.useEffect((function(){if(N.current){var e=new u.default.Animation((function(e){if(e&&N.current){var t=40*e.time/1e3;N.current.dashOffset(-t)}}),N.current.getLayer());return e.start(),function(){e&&e.stop()}}}),[N]);var H=T.bind(null,"rect"),P=T.bind(null,"tl"),B=T.bind(null,"tr"),A=T.bind(null,"bl"),V=T.bind(null,"br"),G=function(e){h&&h(e)};if(!n)return null;var z=m.map((function(e,t){var n=e.normalizedRect,r=n.x1,a=n.x2,o=n.y1,i=n.y2,l=x*((a-r)/2+r),c=w*((i-o)/2+o);return{region:e,key:l+"-"+c+"-"+t,x:l,y:c,show:e.show}})),D=10,q=[4,4,4,4],Z=function(e){e.beginPath();var t=0,n=0,r=0,i=0;"number"==typeof q&&g?t=n=r=i=Math.min(q,x/2,w/2):g&&(t=Math.min(q[0]||0,o/2,a/2),n=Math.min(q[1]||0,o/2,a/2),i=Math.min(q[2]||0,o/2,a/2),r=Math.min(q[3]||0,o/2,a/2)),e.moveTo(t,0),e.lineTo(o-n,0),e.arc(o-n,n,n,3*Math.PI/2,0,!1),e.lineTo(o,a-i),e.arc(o-i,a-i,i,0,Math.PI/2,!1),e.lineTo(r,a),e.arc(r,a-r,r,Math.PI/2,Math.PI,!1),e.lineTo(0,t),e.arc(t,t,t,Math.PI,3*Math.PI/2,!1),e.closePath()},W=i.useState(!1),U=W[0],Y=W[1];return i.useEffect((function(){setTimeout((function(){Y(!0)}),300)}),[]),i.default.createElement(l.Stage,{width:x,height:w,style:{cursor:f(M),width:x,height:w,margin:"auto"}},i.default.createElement(l.Layer,{key:"img",clipFunc:Z},i.default.createElement(l.Image,{image:n,width:y?80:x,height:y?80:w,ref:function(e){null==e||e.to({width:x,height:w,duration:.3})},fill:"white"})),U&&i.default.createElement(i.default.Fragment,null,i.default.createElement(l.Layer,{key:"selection",clipFunc:Z},i.default.createElement(l.Rect,{stroke:"white",opacity:0,strokeWidth:0,x:E,y:O,width:j-E,height:L-O}),i.default.createElement(l.Rect,{stroke:"black",draggable:!0,onDragMove:H,dragBoundFunc:function(e){var t=e.x,n=e.y,r=j-E+5,a=L-O+5;return{x:Math.max(Math.min(t,x-r),5),y:Math.max(Math.min(n,w-a),5)}},onMouseOver:function(){return F({rectHover:!0})},onMouseOut:function(){return F({rectHover:!1})},opacity:0,strokeWidth:2,x:E,y:O,width:j-E,height:L-O,dash:[0,0],ref:N}),i.default.createElement(l.Rect,{fill:"black",opacity:.3,x:0,y:0,width:x,height:O}),i.default.createElement(l.Rect,{fill:"black",opacity:.3,x:0,y:L,width:x,height:w-L}),i.default.createElement(l.Rect,{fill:"black",opacity:.3,x:0,y:O,width:E,height:L-O}),i.default.createElement(l.Rect,{fill:"black",opacity:.3,x:j,y:O,width:x-j,height:L-O})),i.default.createElement(l.Layer,null,i.default.createElement(l.Path,{data:"M2 18V10C2 5.58172 5.58172 2 10 2H18",stroke:"white",strokeWidth:5,lineCap:"round",opacity:1,x:E-3,y:O-3,shadowColor:"#000000",shadowBlur:4,shadowOffset:{x:0,y:0},shadowOpacity:.25}),i.default.createElement(l.Rect,{draggable:!0,onDragMove:P,dragBoundFunc:function(e){var t=e.x,n=e.y;return{x:Math.max(Math.min(t,j-S),0),y:Math.max(Math.min(n,L-R),0)}},onMouseOver:function(){return F({tlHover:!0})},onMouseOut:function(){return F({tlHover:!1})},opacity:1,width:20+D,height:20+D,x:E-D,y:O-D}),i.default.createElement(l.Path,{data:"M2 2L10 2C14.4183 2 18 5.58172 18 10L18 18",stroke:"white",strokeWidth:5,lineCap:"round",opacity:1,x:j+3,y:O-3,offsetX:20,shadowColor:"#000000",shadowBlur:4,shadowOffset:{x:0,y:0},shadowOpacity:.25}),i.default.createElement(l.Rect,{draggable:!0,onDragMove:B,dragBoundFunc:function(e){var t=e.x,n=e.y;return{x:Math.min(Math.max(t,E+S),x),y:Math.max(Math.min(n,L-R),0)}},onMouseOver:function(){return F({trHover:!0})},onMouseOut:function(){return F({trHover:!1})},opacity:1,width:20+D,height:20+D,x:j-D,y:O-D,offsetX:20-D}),i.default.createElement(l.Path,{data:"M18 18L10 18C5.58172 18 2 14.4183 2 10L2 2",stroke:"white",strokeWidth:5,lineCap:"round",opacity:1,x:E-3,y:L+3,offsetY:20,shadowColor:"#000000",shadowBlur:4,shadowOffset:{x:0,y:0},shadowOpacity:.25}),i.default.createElement(l.Rect,{draggable:!0,onDragMove:A,dragBoundFunc:function(e){var t=e.x,n=e.y;return{x:Math.max(Math.min(t,j-S),0),y:Math.min(Math.max(n,O+R),w)}},onMouseOver:function(){return F({blHover:!0})},onMouseOut:function(){return F({blHover:!1})},opacity:1,width:20+D,height:20+D,x:E-D,y:L-D,offsetY:20-D}),i.default.createElement(l.Path,{data:"M18 2L18 10C18 14.4183 14.4183 18 10 18L2 18",stroke:"white",strokeWidth:5,lineCap:"round",x:j+3,y:L+3,opacity:1,offsetY:20,offsetX:20,shadowColor:"#000000",shadowBlur:4,shadowOffset:{x:0,y:0},shadowOpacity:.25}),i.default.createElement(l.Rect,{opacity:1,draggable:!0,onDragMove:V,dragBoundFunc:function(e){var t=e.x,n=e.y;return{x:Math.min(Math.max(t,E+S),x),y:Math.min(Math.max(n,O+R),w)}},onMouseOver:function(){return F({brHover:!0})},onMouseOut:function(){return F({brHover:!1})},x:j-D,y:L-D,width:20+D,height:20+D,offsetY:20-D,offsetX:20-D})),i.default.createElement(s.NodeGroup,{data:z,keyAccessor:function(e){return e.key},start:function(e,t){return{opacity:0,x:-100,y:e.y}},enter:function(e,t){return{opacity:[1],x:[e.x],y:e.y,timing:{delay:100*t,duration:300}}}},(function(e){return i.default.createElement(l.Layer,{key:"dots"},e.map((function(e){var n=e.key,a=e.data,o=e.state;return i.default.createElement(l.Circle,r({onClick:function(){G(a.region.normalizedRect),F({dotHover:!1})},onTap:function(){G(a.region.normalizedRect),F({dotHover:!1})},onMouseOver:function(){return F({dotHover:!0})},onMouseOut:function(){return F({dotHover:!1})},key:n,radius:7},o,{stroke:t,fill:"white",strokeWidth:5,opacity:a.region.show}))})))}))))}},function(e,t){e.exports=n(828)},function(e,t){e.exports=n(463)},function(e,t){e.exports=n(879)},function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(a,o){function i(e){try{c(r.next(e))}catch(e){o(e)}}function l(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,l)}c((r=r.apply(e,t||[])).next())}))},a=this&&this.__generator||function(e,t){var n,r,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;i;)try{if(n=1,r&&(a=2&o[0]?r.return:o[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,o[1])).done)return a;switch(r=0,a&&(o=[2&o[0],a.value]),o[0]){case 0:case 1:a=o;break;case 4:return i.label++,{value:o[1],done:!1};case 5:i.label++,r=o[1],o=[0];continue;case 7:o=i.ops.pop(),i.trys.pop();continue;default:if(!((a=(a=i.trys).length>0&&a[a.length-1])||6!==o[0]&&2!==o[0])){i=0;continue}if(3===o[0]&&(!a||o[1]>a[0]&&o[1]<a[3])){i.label=o[1];break}if(6===o[0]&&i.label<a[1]){i.label=a[1],a=o;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(o);break}a[2]&&i.ops.pop(),i.trys.pop();continue}o=t.call(e,i)}catch(e){o=[6,e],r=0}finally{n=a=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,l])}}},o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var l=o(n(0));n(8);var c=n(1),u=i(n(12)),s=i(n(13));t.default=function(e){var t=e.onCaptureComplete,n=e.onCaptureCanceled,o=e.useAppText,i=l.useRef(null),f=l.useState(),d=f[0],p=f[1];return l.useEffect((function(){navigator.mediaDevices.getUserMedia({video:{facingMode:"environment",width:640}}).then((function(e){var t=i.current;t&&(t.srcObject=e,p(e))})).catch((function(e){switch(e.name){case"NotFoundError":alert("Camera not found. Try with a file instead.");break;case"NotAllowedError":alert("You have to allow using the camera in order to take pictures. If you are not asked again for permissions, go to site settings and reset permissions there.");break;default:alert("Sorry, something has gone wrong while enabeling the camera. ("+e+")")}}))}),[i]),l.useEffect((function(){return function(){d&&(d.getVideoTracks&&d.getAudioTracks?(d.getVideoTracks().map((function(e){return e.stop()})),d.getAudioTracks().map((function(e){return e.stop()}))):d.stop())}}),[d]),l.default.createElement("div",{className:"nyris-capture-captureUi"},l.default.createElement("video",{autoPlay:!0,playsInline:!0,ref:i,className:"nyris-capture-video"}),l.default.createElement("input",{type:"file",name:"file",id:"capture_file",className:"nyris-capture-inputFile",accept:"image/*",capture:"environment",onChange:function(e){return r(void 0,void 0,void 0,(function(){var n,r;return a(this,(function(a){switch(a.label){case 0:return(n=e.target)&&n.files?[4,c.urlOrBlobToCanvas(n.files[0])]:[3,2];case 1:r=a.sent(),t(r),a.label=2;case 2:return[2]}}))}))}}),l.default.createElement("label",{className:"nyris-capture-app-button",htmlFor:"capture_file"},o),l.default.createElement("button",{className:"nyris-capture-backBtn",onClick:n},l.default.createElement("img",{src:s.default,alt:"back",width:"72"})),l.default.createElement("button",{className:"nyris-capture-searchBtn",onClick:function(){if(i.current){var e=c.elementToCanvas(i.current);t(e)}}},l.default.createElement("img",{src:u.default,alt:"capture"})))}},function(e,t,n){var r=n(9),a=n(10);"string"==typeof(a=a.__esModule?a.default:a)&&(a=[[e.i,a,""]]);r(a,{insert:"head",singleton:!1}),e.exports=a.locals||{}},function(e,t,n){"use strict";var r,a=function(){var e={};return function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}e[t]=n}return e[t]}}(),o=[];function i(e){for(var t=-1,n=0;n<o.length;n++)if(o[n].identifier===e){t=n;break}return t}function l(e,t){for(var n={},r=[],a=0;a<e.length;a++){var l=e[a],c=t.base?l[0]+t.base:l[0],u=n[c]||0,s="".concat(c," ").concat(u);n[c]=u+1;var f=i(s),d={css:l[1],media:l[2],sourceMap:l[3]};-1!==f?(o[f].references++,o[f].updater(d)):o.push({identifier:s,updater:m(d,t),references:1}),r.push(s)}return r}function c(e){var t=document.createElement("style"),r=e.attributes||{};if(void 0===r.nonce){var o=n.nc;o&&(r.nonce=o)}if(Object.keys(r).forEach((function(e){t.setAttribute(e,r[e])})),"function"==typeof e.insert)e.insert(t);else{var i=a(e.insert||"head");if(!i)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");i.appendChild(t)}return t}var u,s=(u=[],function(e,t){return u[e]=t,u.filter(Boolean).join("\n")});function f(e,t,n,r){var a=n?"":r.media?"@media ".concat(r.media," {").concat(r.css,"}"):r.css;if(e.styleSheet)e.styleSheet.cssText=s(t,a);else{var o=document.createTextNode(a),i=e.childNodes;i[t]&&e.removeChild(i[t]),i.length?e.insertBefore(o,i[t]):e.appendChild(o)}}function d(e,t,n){var r=n.css,a=n.media,o=n.sourceMap;if(a?e.setAttribute("media",a):e.removeAttribute("media"),o&&btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),e.styleSheet)e.styleSheet.cssText=r;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(r))}}var p=null,h=0;function m(e,t){var n,r,a;if(t.singleton){var o=h++;n=p||(p=c(t)),r=f.bind(null,n,o,!1),a=f.bind(null,n,o,!0)}else n=c(t),r=d.bind(null,n,t),a=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(n)};return r(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;r(e=t)}else a()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"==typeof t.singleton||(t.singleton=(void 0===r&&(r=Boolean(window&&document&&document.all&&!window.atob)),r));var n=l(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var r=0;r<n.length;r++){var a=i(n[r]);o[a].references--}for(var c=l(e,t),u=0;u<n.length;u++){var s=i(n[u]);0===o[s].references&&(o[s].updater(),o.splice(s,1))}n=c}}}},function(e,t,n){(t=n(11)(!1)).push([e.i,".nyris-capture-app-button {\n position: fixed;\n top: 0;\n right: 0;\n color: white;\n margin: 10px;\n padding: 10px;\n background-color: rgba(255,255,255,0.3);\n border-radius: 2px;\n text-shadow: 1px 1px 3px #000;\n line-height: 1em;\n box-shadow: 1px 1px 3px rgba(0, 0, 0,0.5);\n}\n\n.nyris-capture-inputFile {\n visibility: hidden;\n}\n\n.nyris-capture-captureUi {\n position: fixed;\n top: 0;\n left: 0;\n bottom: 0;\n height: 100%;\n width: 100%;\n background-color: black;\n z-index: 10000;\n}\n\n.nyris-capture-video {\n position: fixed;\n min-height: 100%;\n min-width: 100%;\n top: 50%;\n left: 50%;\n transform: translateX(-50%) translateY(-50%);\n width: auto;\n height: auto;\n}\n\n.nyris-capture-searchBtn {\n position: fixed;\n bottom: 0;\n right: 0;\n z-index: 10001;\n left: 50%;\n transform: translateX(-50%);\n\n color: black;\n background-color: transparent;\n text-transform: uppercase;\n border: 0;\n margin: auto;\n display: block;\n -webkit-filter: drop-shadow( 1px 1px 5px #000 );\n filter: drop-shadow( 1px 1px 5px #000 );\n\n}\n\n.nyris-capture-backBtn {\n position: fixed;\n bottom: 0;\n left: 0;\n z-index: 10001;\n color: white;\n background-color: transparent;\n border: 0;\n\n text-transform: uppercase;\n border-radius: 50%;\n display: block;\n padding: 0;\n font-size: 16px;\n margin-bottom: 5px;\n margin-left: 5px;\n -webkit-filter: drop-shadow( 1px 1px 5px #000 );\n filter: drop-shadow( 1px 1px 5px #000 );\n}\n\n",""]),e.exports=t},function(e,t,n){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=function(e,t){var n,r,a,o=e[1]||"",i=e[3];if(!i)return o;if(t&&"function"==typeof btoa){var l=(n=i,r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),a="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),"/*# ".concat(a," */")),c=i.sources.map((function(e){return"/*# sourceURL=".concat(i.sourceRoot||"").concat(e," */")}));return[o].concat(c).concat([l]).join("\n")}return[o].join("\n")}(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"==typeof e&&(e=[[null,e,""]]);var a={};if(r)for(var o=0;o<this.length;o++){var i=this[o][0];null!=i&&(a[i]=!0)}for(var l=0;l<e.length;l++){var c=[].concat(e[l]);r&&a[c[0]]||(n&&(c[2]?c[2]="".concat(n," and ").concat(c[2]):c[2]=n),t.push(c))}},t}},function(e,t,n){"use strict";n.r(t),n.d(t,"ReactComponent",(function(){return c}));var r=n(0);function a(){return(a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var o=r.createElement("defs",null,r.createElement("path",{id:"capture_svg__a",d:"M150 540a30 30 0 1160 0 30 30 0 01-60 0z"}),r.createElement("path",{id:"capture_svg__b",d:"M144 540a36 36 0 1172 0 36 36 0 01-72 0zm36 33.95a33.94 33.94 0 100-67.89 33.94 33.94 0 000 67.89z"})),i=r.createElement("use",{fill:"#c00",xlinkHref:"#capture_svg__a",transform:"translate(-144 -504)"}),l=r.createElement("use",{fill:"#c00",fillOpacity:.9,xlinkHref:"#capture_svg__b",opacity:.7,transform:"translate(-144 -504)"});function c(e){return r.createElement("svg",a({width:72,height:72},e),o,i,l)}t.default="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iNzIiIGhlaWdodD0iNzIiIHZpZXdCb3g9IjAgMCA3MiA3MiI+PGRlZnM+PHBhdGggaWQ9IjFoN3JhIiBkPSJNMTUwIDU0MGEzMCAzMCAwIDEgMSA2MCAwIDMwIDMwIDAgMCAxLTYwIDB6Ii8+PHBhdGggaWQ9IjFoN3JiIiBkPSJNMTQ0IDU0MGEzNiAzNiAwIDEgMSA3MiAwIDM2IDM2IDAgMCAxLTcyIDB6bTM2IDMzLjk1YTMzLjk0IDMzLjk0IDAgMSAwIDAtNjcuODkgMzMuOTQgMzMuOTQgMCAwIDAgMCA2Ny44OXoiLz48L2RlZnM+PGc+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoLTE0NCAtNTA0KSI+PHVzZSBmaWxsPSIjYzAwIiB4bGluazpocmVmPSIjMWg3cmEiLz48L2c+PGcgb3BhY2l0eT0iLjciIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0xNDQgLTUwNCkiPjx1c2UgZmlsbD0iI2MwMCIgZmlsbC1vcGFjaXR5PSIuOSIgeGxpbms6aHJlZj0iIzFoN3JiIi8+PC9nPjwvZz48L3N2Zz4="},function(e,t,n){"use strict";n.r(t),n.d(t,"ReactComponent",(function(){return l}));var r=n(0);function a(){return(a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}var o=r.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),i=r.createElement("path",{d:"M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z",fill:"#fff"});function l(e){return r.createElement("svg",a({width:24,height:24},e),o,i)}t.default="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij4KICAgIDxwYXRoIGQ9Ik0wIDBoMjR2MjRIMHoiIGZpbGw9Im5vbmUiLz4KICAgIDxwYXRoIGQ9Ik0yMCAxMUg3LjgzbDUuNTktNS41OUwxMiA0bC04IDggOCA4IDEuNDEtMS40MUw3LjgzIDEzSDIwdi0yeiIgZmlsbD0id2hpdGUiLz4KPC9zdmc+Cg=="},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.makeFileHandler=function(e){return function(t){var n=null,r=t;if(r&&r.target){var a=r.target;if(a.files&&a.files[0]&&(n=a.files[0]),a.value&&(a.value=""),n)return e(n)}var o=t;if(o&&(n=o.dataTransfer&&o.dataTransfer.files[0]),n)return e(n)}}}])},423:function(e,t,n){},425:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(a,o){function i(e){try{c(r.next(e))}catch(t){o(t)}}function l(e){try{c(r.throw(e))}catch(t){o(t)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,l)}c((r=r.apply(e,t||[])).next())}))},a=this&&this.__generator||function(e,t){var n,r,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:l(0),throw:l(1),return:l(2)},"function"===typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;i;)try{if(n=1,r&&(a=2&o[0]?r.return:o[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,o[1])).done)return a;switch(r=0,a&&(o=[2&o[0],a.value]),o[0]){case 0:case 1:a=o;break;case 4:return i.label++,{value:o[1],done:!1};case 5:i.label++,r=o[1],o=[0];continue;case 7:o=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===o[0]||2===o[0])){i=0;continue}if(3===o[0]&&(!a||o[1]>a[0]&&o[1]<a[3])){i.label=o[1];break}if(6===o[0]&&i.label<a[1]){i.label=a[1],a=o;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(o);break}a[2]&&i.ops.pop(),i.trys.pop();continue}o=t.call(e,i)}catch(l){o=[6,l],r=0}finally{n=a=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,l])}}},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=o(n(748));function l(e,t){return{x1:e.x1*t.w,x2:e.x2*t.w,y1:e.y1*t.h,y2:e.y2*t.h}}function c(e){return{w:e.x2-e.x1,h:e.y2-e.y1}}function u(e){var t=e,n=e;return{w:t.naturalWidth||n.videoWidth||e.width,h:t.naturalHeight||n.videoHeight||e.height}}t.selectFirstCenteredRegion=function(e,t,n){var r=e.filter((function(e){return function(e,t){var n=e[0],r=e[1],a=t[0],o=t[1];return Math.sqrt(Math.pow(n-a,2)+Math.pow(r-o,2))}([.5,.5],function(e){var t=e.x1,n=e.x2,r=e.y1;return[(n-t)/2+t,(e.y2-r)/2+r]}(e.normalizedRect))<t}));return 0===r.length?n:r[0].normalizedRect},t.getUrlParam=function(e){var t=new RegExp("[?&]"+e+"(=([^&#]*))?(&|$|#)","i").exec(window.location.href);return t&&t[2]?(console.log("has value",e,t[2]),decodeURIComponent(t[2])):!!t||void 0},t.getThumbSizeArea=function(e,t,n){var r=e*t,a=Math.sqrt(r*n);return{w:a,h:a/n}},t.getThumbSizeLongestEdge=function(e,t,n,r){return e/t>n/r?{w:n*t/r,h:t}:{w:e,h:r*e/n}},t.scaleRect=l,t.getRectSize=c,t.getRectAspectRatio=function(e,t){var n=c(l(e,t));return n.w/n.h},t.getElementSize=u,t.elementToCanvas=function(e,t,n){var r=u(e),a=r.w,o=r.h,i=n||{x1:0,x2:1,y1:0,y2:1},l=i.x1,c=i.x2,s=i.y1,f=a*l,d=a*(c-l),p=o*s,h=o*(i.y2-s),m=t&&t.w||a,g=t&&t.h||o,v=document.createElement("canvas");v.width=m,v.height=g;var y=v.getContext("2d");if(!y)throw Error("Error converting element to canvas: Can not get 2d context");return y.fillStyle="rgb(255, 255,255)",y.fillRect(0,0,m,g),y.drawImage(e,f,p,d,h,0,0,m,g),v},t.urlOrBlobToCanvas=function(e){return new Promise((function(t,n){i.default(e,(function(e){e?t(e):n()}),{canvas:!0,orientation:!0,crossOrigin:"anonymous"})}))},t.canvasToJpgBlob=function(e,t){return new Promise((function(n,r){e.toBlob((function(e){e?n(e):r()}),"image/jpeg",t)}))},t.cadExtensions=[".stp",".step",".stl",".obj",".glb",".gltf"],t.isCadFile=function(e){return t.cadExtensions.some((function(t){return e.name.endsWith(t)}))},t.isImageFile=function(e){return e.type.startsWith("image/")},t.timePromise=function(e){return r(this,void 0,void 0,(function(){var t,n,r;return a(this,(function(a){switch(a.label){case 0:return t=Date.now(),[4,e];case 1:return n=a.sent(),r=Date.now(),[2,{res:n,durationSeconds:(r-t)/1e3}]}}))}))}},470:function(e,t,n){e.exports=n.p+"static/media/img-1-1.6144e5f9.png"},471:function(e,t,n){e.exports=n.p+"static/media/img-1-2.ad943f0f.png"},472:function(e,t,n){e.exports=n.p+"static/media/img2-1.a87c79c7.png"},473:function(e,t,n){e.exports=n.p+"static/media/img2-2.39c5b73f.png"},474:function(e,t,n){e.exports=n.p+"static/media/img3-1.443b0c3a.png"},475:function(e,t,n){e.exports=n.p+"static/media/img3-2.37db7999.png"},476:function(e,t,n){e.exports=n.p+"static/media/img4-1.9c34c158.png"},477:function(e,t,n){e.exports=n.p+"static/media/img4-2.9d280a04.png"},478:function(e,t,n){e.exports=n.p+"static/media/img5-1.b61dbd4d.png"},479:function(e,t,n){e.exports=n.p+"static/media/img5-2.1c77c093.png"},480:function(e,t,n){e.exports=n.p+"static/media/img6-1.8b03dd21.png"},481:function(e,t,n){e.exports=n.p+"static/media/img6-2.1e3e7fed.png"},482:function(e,t,n){e.exports=n.p+"static/media/reverse_camera.28c80509.svg"},490:function(e,t,n){e.exports=n.p+"static/media/icon_search.373c3cc4.svg"},493:function(e,t,n){e.exports=n.p+"static/media/camera.ae3f4f51.svg"},495:function(e,t,n){e.exports=n.p+"static/media/email_share.92bbfb8b.svg"},517:function(e,t,n){e.exports=n(878)},59:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(a,o){function i(e){try{c(r.next(e))}catch(t){o(t)}}function l(e){try{c(r.throw(e))}catch(t){o(t)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,l)}c((r=r.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var n,r,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:l(0),throw:l(1),return:l(2)},"function"===typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;i;)try{if(n=1,r&&(a=2&o[0]?r.return:o[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,o[1])).done)return a;switch(r=0,a&&(o=[2&o[0],a.value]),o[0]){case 0:case 1:a=o;break;case 4:return i.label++,{value:o[1],done:!1};case 5:i.label++,r=o[1],o=[0];continue;case 7:o=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===o[0]||2===o[0])){i=0;continue}if(3===o[0]&&(!a||o[1]>a[0]&&o[1]<a[3])){i.label=o[1];break}if(6===o[0]&&i.label<a[1]){i.label=a[1],a=o;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(o);break}a[2]&&i.ops.pop(),i.trys.pop();continue}o=t.call(e,i)}catch(l){o=[6,l],r=0}finally{n=a=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,l])}}},i=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n};var l=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),n(747);var c=n(425),u=l(n(753));!function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(425));var s=function(){function e(e){if(this.httpClient=u.default.create(),!e.apiKey)throw new Error("The api-key is not set.");this.apiKey=e.apiKey;var t=e.baseUrl||"https://api.nyris.io";this.imageMatchingUrl=t+"/find/v1.1",this.cadMatchingUrl=t+"/cad/find/v0.1",this.imageMatchingUrlBySku=t+"/recommend/v1/",this.imageMatchingSubmitManualUrl=t+"/find/v1/manual/",this.feedbackUrl=t+"/feedback/v1/",this.regionProposalUrl=t+"/find/v2/regions/",this.findFilters=t+"/find/v1/filters",this.responseFormat=e.responseFormat||"application/offers.complete+json",this.maxHeight=e.maxHeight||500,this.maxWidth=e.maxWidth||500,this.jpegQuality=e.jpegQuality||.92,this.customSearchRequest=e.customSearchRequest,this.responseHook=e.responseHook,this.xOptions=e.xOptions}return e.prototype.prepareImage=function(e,t){return a(this,void 0,void 0,(function(){var n,r,a,i,l;return o(this,(function(o){switch(o.label){case 0:return n=t||{x1:0,x2:1,y1:0,y2:1},r=c.getElementSize(e),a=c.getRectAspectRatio(n,r),i=c.getThumbSizeArea(this.maxWidth,this.maxHeight,a),l=c.elementToCanvas(e,i,n),[4,c.canvasToJpgBlob(l,this.jpegQuality)];case 1:return[2,o.sent()]}}))}))},e.prototype.getSearchRequestHeaders=function(e){var t={"X-Api-Key":this.apiKey,"Accept-Language":"de,*;q=0.5",Accept:this.responseFormat,"Content-Type":e||"application/octet-stream"},n=[];return this.xOptions&&n.push(this.xOptions),n.length>0&&(t["X-Options"]=n.join(" ")),t},e.prototype.getRegionRequestHeaders=function(e){var t={"X-Api-Key":this.apiKey,"Content-Type":e||"application/octet-stream"},n=[];return this.xOptions&&n.push(this.xOptions),n.length>0&&(t["X-Options"]=n.join(" ")),t},e.prototype.getParams=function(e){var t=e.geoLocation?{lat:e.geoLocation.lat.toString(),lon:e.geoLocation.lon.toString(),dist:e.geoLocation.dist.toString()}:{};return t=r(r({},t),{text:e.text})},e.prototype.parseCategoryPredictions=function(e){return Object.entries(e||{}).map((function(e){return{name:e[0],score:e[1]}})).sort((function(e,t){return t.score-e.score}))},e.prototype.findByCad=function(e,t){return a(this,void 0,void 0,(function(){var n,r,a;return o(this,(function(o){switch(o.label){case 0:return n=e.type,r=this.getSearchRequestHeaders(n),a=this.getParams(t),[4,c.timePromise(this.httpClient.request({method:"POST",url:this.cadMatchingUrl,data:e,params:a,headers:r,responseType:"json"}))];case 1:return[2,o.sent().res.data]}}))}))},e.prototype.find=function(e,t,n){return a(this,void 0,void 0,(function(){var a,l,u,s,f,d,p;return o(this,(function(o){switch(o.label){case 0:return a=new FormData,l={},u=this.getSearchRequestHeaders("image/jpeg"),t&&e.text?(a.append("text",e.text),e.text,s=i(e,["text"]),l=this.getParams(s)):e.text&&n&&n.length>0?a.append("text",e.text):l=this.getParams(e),t?[4,this.prepareImage(t,e.cropRect)]:[3,2];case 1:if(f=o.sent(),this.customSearchRequest)return[2,this.customSearchRequest(f,this.httpClient)];a.append("image",f),o.label=2;case 2:if(n&&n.length>0)for(d=0;d<n.length;d++)for(a.append("filters["+d+"].filterType",n[d].key),p=0;p<n[d].values.length;p++)a.append("filters["+d+"].filterValues["+p+"]",n[d].values[p]);return[4,c.timePromise(this.httpClient.request(r({method:"POST",url:this.imageMatchingUrl,params:l,headers:u,responseType:"json"},t||n&&n.length?{data:a}:{data:null})))];case 3:return[2,o.sent().res.data]}}))}))},e.prototype.findBySku=function(e,t){return a(this,void 0,void 0,(function(){var n,r,a;return o(this,(function(o){switch(o.label){case 0:return n=this.getSearchRequestHeaders(),r=""+this.imageMatchingUrlBySku+encodeURIComponent(e)+"/"+encodeURIComponent(t),[4,this.httpClient.get(r,{headers:n,responseType:"json"})];case 1:return a=o.sent(),this.responseHook&&(a=this.responseHook),[2,a]}}))}))},e.prototype.findRegions=function(e){return a(this,void 0,void 0,(function(){var t,n,r,a,i,l,u,s;return o(this,(function(o){switch(o.label){case 0:return t=c.getElementSize(e),n=t.w,r=t.h,a=c.getThumbSizeArea(this.maxWidth,this.maxHeight,n/r),i=c.elementToCanvas(e,a),[4,c.canvasToJpgBlob(i,this.jpegQuality)];case 1:return l=o.sent(),u=this.getRegionRequestHeaders("image/jpeg"),[4,this.httpClient.request({method:"POST",url:this.regionProposalUrl,data:l,headers:u})];case 2:return s=o.sent(),[2,s.data.regions.map((function(e){return{classId:e.classId,confidence:e.confidence,normalizedRect:{x1:e.region.left/a.w,x2:e.region.right/a.w,y1:e.region.top/a.h,y2:e.region.bottom/a.h}}}))]}}))}))},e.prototype.sendFeedback=function(e,t,n){return a(this,void 0,void 0,(function(){var a,i;return o(this,(function(o){switch(o.label){case 0:return a={"X-Api-Key":this.apiKey,"Content-Type":"application/json"},i=r({request_id:t,timestamp:new Date,session_id:e},n),[4,this.httpClient.request({method:"POST",url:this.feedbackUrl,headers:a,data:i})];case 1:return o.sent(),[2]}}))}))},e.prototype.getFilters=function(e){return a(this,void 0,void 0,(function(){var t,n;return o(this,(function(r){switch(r.label){case 0:return t=this.getSearchRequestHeaders(),n=this.findFilters+"?limit="+e,[4,this.httpClient.get(n,{headers:t,responseType:"json"})];case 1:return[2,r.sent().data]}}))}))},e.prototype.searchFilters=function(e,t,n){return void 0===n&&(n=100),a(this,void 0,void 0,(function(){var r,a;return o(this,(function(o){switch(o.label){case 0:return r=this.getSearchRequestHeaders(),a=this.findFilters+"/"+e+"/"+t+"?limit="+n,[4,this.httpClient.get(a,{headers:r,responseType:"json"})];case 1:return[2,o.sent().data]}}))}))},e}();t.default=s},746:function(e,t,n){},811:function(e,t,n){},812:function(e,t,n){},815:function(e,t,n){},878:function(e,t,n){"use strict";n.r(t);n(340),n(383);var r=n(0),a=n.n(r),o=n(28),i=n.n(o);Boolean("localhost"===window.location.hostname||"[::1]"===window.location.hostname||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));var l=n(219),c=n(923),u=(n(422),n(74)),s=n(46),f=n(5),d=n(8),p=n(6),h=n(925),m=n(16),g=n(253),v=n(470),y=n.n(v),b=n(471),x=n.n(b),w=n(472),C=n.n(w),E=n(473),O=n.n(E),j=n(474),L=n.n(j),k=n(475),S=n.n(k),R=n(476),N=n.n(R),I=n(477),M=n.n(I),_=n(478),F=n.n(_),T=n(479),H=n.n(T),P=n(480),B=n.n(P),A=n(481),V=n.n(A),G={x1:0,x2:1,y1:0,y2:1},z=[{value:10,label:"10"},{value:20,label:"20"},{value:30,label:"30"},{value:40,label:"40"},{value:50,label:"50"},{value:60,label:"60"},{value:70,label:"70"},{value:80,label:"80"},{value:90,label:"90"},{value:100,label:"100"}],D=[{title:"SELECT THE RIGHT IMAGE AREA",description:"The main object should occupy the major part of the image. Use the cropping tool available to crop the image and remove excess background.",imageLeft:y.a,imageRight:x.a},{title:"PICTURE CLARITY",description:"The image should not be blurred or out of focus.",imageLeft:C.a,imageRight:O.a},{title:"OPTIMAL LIGHTING",description:"The images should be taken in a bright area or use your camera\u2019s flash to take a well-lit picture.",imageLeft:L.a,imageRight:S.a},{title:"MONOCHROME BACKGROUND",description:"The object should be placed on a plain and light background and patterned background should be avoided.",imageLeft:N.a,imageRight:M.a},{title:"VISIBILITY OF THE OBJECT",description:"Click an image encapsulating most of the object\u2019s key components.",imageLeft:F.a,imageRight:H.a},{title:"OCR CAPTURE",description:"It is recommended to take a clear picture of the text on the typeplate etc, to ensure that the model can detect the text and give accurate results.",imageLeft:B.a,imageRight:V.a}],q={categoryPredictions:[],codes:[],configureFilter:{},errorMessage:"",fetchingRegions:!1,fetchingResults:!1,filterOptions:[],filters:[],imageThumbSearchInput:"",isShowModalDetailItemMobile:!1,preFilter:{},loadingSearchAlgolia:!1,preFilterDropdown:!1,imageCaptureHelpModal:!1,regions:[],requestImage:void 0,results:[],resultSearchText:[],selectedRegion:void 0,textSearchInputMobile:"",valueTextSearch:{configure:{filters:""},page:1,refinementList:""}},Z=Object(g.b)({name:"search",initialState:q,reducers:{setSearchResults:function(e,t){var n=t.payload,r=n.results,a=n.requestId,o=n.categoryPredictions,i=n.codes,l=n.duration,c=n.filters;return Object(f.a)(Object(f.a)({},e),{},{filters:c,results:r,requestId:a,categoryPredictions:o,codes:i,duration:l,sessionId:e.sessionId||a,fetchingResults:!1})},setRegions:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{regions:t.payload})},setSelectedRegion:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{selectedRegion:t.payload})},setRequestImage:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{requestImage:{canvas:t.payload,id:Math.random().toString()},regions:[]})},selectionChanged:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{selectedRegion:n})},loadFileSelectRegion:function(e,t){var n=t.payload,r=n.results,a=n.requestId,o=n.categoryPredictions,i=n.codes,l=n.duration;return Object(f.a)(Object(f.a)({},e),{},{results:r,requestId:a,categoryPredictions:o,codes:i,duration:l,sessionId:e.sessionId||a,fetchingRegions:!1})},loadingActionResults:function(e){return Object(f.a)(Object(f.a)({},e),{},{fetchingResults:!0})},loadingActionRegions:function(e){return Object(f.a)(Object(f.a)({},e),{},{fetchingRegions:!0})},searchFileImageNonRegion:function(e,t){var n=t.payload,r=n.results,a=n.requestId,o=n.duration,i=n.categoryPredictions,l=n.codes;return Object(f.a)(Object(f.a)({},e),{},{results:r,requestId:a,duration:o,categoryPredictions:i,codes:l,fetchingResults:!1})},changeValueTextSearch:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{valueTextSearch:n})},resultSearchText:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{resultSearchText:n})},updateResults:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{results:n})},updateQueryText:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{queryText:n})},reset:function(e,t){return{results:[],regions:[],selectedRegion:G,requestImage:void 0,fetchingResults:!1,fetchingRegions:!1,filterOptions:[],categoryPredictions:[],codes:[],errorMessage:"",valueTextSearch:{},resultSearchText:[],filters:[],loadingSearchAlgolia:!1,imageThumbSearchInput:"",textSearchInputMobile:"",isShowModalDetailItemMobile:!1,preFilter:e.preFilter||{},preFilterDropdown:!1,imageCaptureHelpModal:!1}},onResetRequestImage:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{requestImage:void 0,imageThumbSearchInput:"",results:[],regions:[]})},configureFilter:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{configureFilter:n})},setUpdateSession:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{sessionId:n})},updateResultChangePosition:function(e,t){var n=t.payload.results;return Object(f.a)(Object(f.a)({},e),{},{fetchingResults:!1,results:n})},setError:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{fetchingRegions:!1,fetchingResults:!1,errorMessage:t.payload})},setImageSearchInput:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{imageThumbSearchInput:n})},updateStatusLoading:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{loadingSearchAlgolia:n})},updateValueTextSearchMobile:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{textSearchInputMobile:n})},onToggleModalItemDetail:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{isShowModalDetailItemMobile:n})},setPreFilter:function(e,t){var n=t.payload;return Object(f.a)(Object(f.a)({},e),{},{preFilter:n})},setPreFilterDropdown:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{preFilterDropdown:t.payload})},setImageCaptureHelpModal:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{imageCaptureHelpModal:t.payload})},setFilter:function(e,t){return Object(f.a)(Object(f.a)({},e),{},{filter:t.payload})}}}),W=Z.actions,U=W.changeValueTextSearch,Y=(W.configureFilter,W.loadFileSelectRegion,W.loadingActionRegions,W.loadingActionResults),K=W.onResetRequestImage,Q=W.onToggleModalItemDetail,J=W.reset,X=(W.resultSearchText,W.searchFileImageNonRegion,W.selectionChanged),ee=(W.setError,W.setFilter,W.setImageCaptureHelpModal),te=W.setImageSearchInput,ne=W.setPreFilter,re=W.setPreFilterDropdown,ae=W.setRegions,oe=W.setRequestImage,ie=W.setSearchResults,le=W.setSelectedRegion,ce=W.setUpdateSession,ue=W.updateQueryText,se=W.updateResultChangePosition,fe=(W.updateResults,W.updateStatusLoading),de=W.updateValueTextSearchMobile,pe=Z.reducer,he=n(99);function me(e){var t=new RegExp("[?&]".concat(e,"(=([^&#]*))?(&|$|#)"),"i").exec(window.location.href);return t&&t[2]?decodeURIComponent(t[2]):!!t||void 0}settings.algolia.enabled=!0;var ge=Object(f.a)(Object(f.a)({},{auth0:{},algolia:{enabled:!0,apiKey:"",appId:"",indexName:""},xOptions:!1,apiKey:"UNSET",preview:!0,regions:!1,maxWidth:500,maxHeight:500,jpegQuality:.92,baseUrl:"https://api.nyris.io",instantRedirectPatterns:["^https?://(www.)?youtube.com/","^https?://(www.)?youtu.be/","^https?://(www.)?vimeo.com/","^https?://(www.)?dailymotion.com/","^https?://(www.)?dai.ly/"],theme:{},field:{ctaLinkField:"",productName:"",productDetails:"",manufacturerNumber:"",productTag:"",warehouseNumber:"",warehouseNumberValue:"",warehouseShelfNumber:"",warehouseShelfNumberValue:"",warehouseStock:"",warehouseStockValue:""}}),settings);ge=Object(f.a)(Object(f.a)({},ge),{},{apiKey:me("apiKey")||ge.apiKey,xOptions:me("xOptions")||ge.xOptions,regions:me("use.regions")||ge.regions,preview:me("use.preview")||ge.preview});var ve,ye=Object(he.b)({settings:function(){return ge},search:pe}),be=Object(g.a)({reducer:ye,devTools:!1}),xe=function(){return Object(l.b)()},we=l.c,Ce=(n(746),n(423),n(908)),Ee=["svgRef","title"];function Oe(){return(Oe=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function je(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Le=function(e){var t=e.svgRef,n=e.title,r=je(e,Ee);return a.a.createElement("svg",Oe({width:28,height:28,viewBox:"0 0 28 28",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,ve||(ve=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M28 24C28 24.5523 27.5523 25 27 25H1C0.447715 25 0 24.5523 0 24V7C0 6.44772 0.447715 6 1 6H7.46L9.17 3.45C9.35398 3.17061 9.66548 3.00173 10 3H18C18.3345 3.00173 18.646 3.17061 18.83 3.45L20.54 6H27C27.5523 6 28 6.44772 28 7V24ZM2 23H26V8H20C19.6655 7.99827 19.354 7.82939 19.17 7.55L17.46 5H10.54L8.83 7.55C8.64602 7.82939 8.33452 7.99827 8 8H2V23ZM14 21C10.6863 21 8 18.3137 8 15C8 11.6863 10.6863 9 14 9C17.3137 9 20 11.6863 20 15C20 18.3137 17.3137 21 14 21ZM14 11C11.7909 11 10 12.7909 10 15C10 17.2091 11.7909 19 14 19C16.2091 19 18 17.2091 18 15C18 12.7909 16.2091 11 14 11Z",fill:"currentColor"})))},ke=a.a.forwardRef((function(e,t){return a.a.createElement(Le,Oe({svgRef:t},e))})),Se=(n.p,n(929)),Re=n(907),Ne=n(61),Ie=n.n(Ne),Me=n(485),_e=n.n(Me),Fe=n(482),Te=n.n(Fe),He=n(10),Pe=n(182),Be=n(483),Ae=n.n(Be),Ve=n(59),Ge=n.n(Ve);function ze(){ze=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var De=function(){var e=Object(d.a)(ze().mark((function e(t){var n;return ze().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(t instanceof HTMLCanvasElement)){e.next=4;break}e.t0=t,e.next=7;break;case 4:return e.next=6,Object(Ve.urlOrBlobToCanvas)(t);case 6:e.t0=e.sent;case 7:return n=e.t0,e.abrupt("return",n);case 9:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),qe=function(e){return 0===e.length?G:e.reduce((function(e,t){return e.confidence=e.confidence||0,t.confidence=t.confidence||0,e.confidence>=t.confidence?e:t})).normalizedRect},Ze=function(){var e=Object(d.a)(ze().mark((function e(t,n){var r,a,o;return ze().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=new Ge.a(n),e.next=3,r.findRegions(t);case 3:return a=e.sent,o=qe(a),e.abrupt("return",{selectedRegion:Object(He.isEqual)(o,G)?G:o,regions:a});case 6:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),We=function(e){var t=e.image,n=e.settings,r=e.region,a=e.filters,o=e.text,i=new Ge.a(n),l=o?{text:o}:{};return r&&(l=Object(f.a)(Object(f.a)({},l),{},{cropRect:r})),i.find(l,t,a)};function Ue(){Ue=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var Ye,Ke=function(e){var t,n=e.isToggle,o=e.onToggleModal,i=Object(r.useRef)(null),l=Object(r.useState)("environment"),c=Object(p.a)(l,2),u=c[0],m=c[1],g=Object(r.useState)(1),v=Object(p.a)(g,2),y=v[0],b=v[1],x=we((function(e){return e})),w=x.search,C=x.settings,E=Object(s.f)(),O=xe(),j=w.preFilter,L=Object(r.useCallback)((function(){m((function(e){return"environment"===e?"user":"environment"}))}),[]),k=function(){var e=Object(d.a)(Ue().mark((function e(t){var n,r,a,o,i;return Ue().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return O(fe(!0)),O(Y()),"/result"!==E.location.pathname&&E.push("/result"),e.next=5,De(t);case 5:if(r=e.sent,O(oe(r)),O(te(t)),O(Q(!1)),S(),!C.regions){e.next=17;break}return e.next=13,Ze(r,C);case 13:a=e.sent,O(ae(a.regions)),n=a.selectedRegion,O(le(n));case 17:o=[{key:C.visualSearchFilterKey,values:Object.keys(j)}],i=[],We({image:r,settings:C,filters:Object(He.isEmpty)(j)?void 0:o,region:n}).then((function(e){null===e||void 0===e||e.results.map((function(e){i.push({sku:e.sku,score:e.score})}));var t=Object(f.a)(Object(f.a)({},e),{},{filters:i});O(ie(t)),O(fe(!1))})).catch((function(e){console.log("error input search",e),O(fe(!1))}));case 20:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),S=function(){m("environment"),b(1),o()},R=Object(Pe.a)({onDrop:function(){var e=Object(d.a)(Ue().mark((function e(t){var n,r,a,o,i,l;return Ue().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=[],O(fe(!0)),O(te(URL.createObjectURL(t[0]))),e.next=5,De(t[0]);case 5:if(o=e.sent,O(oe(o)),!C.regions){e.next=14;break}return e.next=10,Ze(o,C);case 10:i=e.sent,O(ae(i.regions)),a=i.selectedRegion,O(le(a));case 14:return l=[{key:C.visualSearchFilterKey,values:Object.keys(j)}],e.abrupt("return",We({image:o,settings:C,filters:Object(He.isEmpty)(j)?void 0:l,region:a}).then((function(e){null===e||void 0===e||e.results.map((function(e){r.push({sku:e.sku,score:e.score})})),n=Object(f.a)(Object(f.a)({},e),{},{filters:r}),O(ie(n)),setTimeout((function(){O(fe(!1)),S(),E.push("/result")}),500)})).catch((function(e){console.log("err camera_custom",e),O(fe(!1)),S()})));case 16:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()}).getInputProps;return a.a.createElement(h.a,{className:"box-camera-custom"},a.a.createElement(Se.a,{anchor:"bottom",open:n,onClose:S,className:"modal-togggle-cam"},a.a.createElement(h.a,{className:"wrap-camera"},a.a.createElement("button",{className:"btn-close-modal right",style:{backgroundColor:"#666666"},onClick:S},a.a.createElement(Ie.a,{style:{fontSize:20,color:"#fff"}})),a.a.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",width:"100%"},className:"full-height"},a.a.createElement(Ae.a,{audio:!1,width:"100%",className:"full-height",imageSmoothing:!0,screenshotFormat:"image/jpeg",forceScreenshotSourceSize:!0,videoConstraints:Object(f.a)(Object(f.a)({},{width:1080,height:1080,aspectRatio:1.33333333333}),{},{facingMode:u}),ref:i,style:{height:"100%",width:"100%",objectFit:"cover",transform:"scale(".concat(y,")")},screenshotQuality:1},(function(e){var t=e.getScreenshot;return a.a.createElement("button",{onClick:function(){var e=t();k(e)},className:"btn-capture-camera"},a.a.createElement("svg",{width:"63",height:"63",viewBox:"0 0 63 63",fill:"none",xmlns:"http://www.w3.org/2000/svg"},a.a.createElement("circle",{cx:"31.5",cy:"31.5",r:"31.5",fill:"white"})))}))),a.a.createElement("button",{className:"btn-switch-camera",onClick:L},a.a.createElement("img",{src:Te.a,alt:"",width:52,height:52})),a.a.createElement("div",{className:"box-scale-camera",style:{backgroundColor:null===(t=C.theme)||void 0===t?void 0:t.secondaryColor}},a.a.createElement("button",{className:"".concat(1===y&&"active"),style:{backgroundColor:1===y?"white":"",color:1===y?"black":"white"},onClick:function(){return b(1)}},"1"),a.a.createElement("button",{className:"".concat(1.5===y&&"active"),style:{backgroundColor:1.5===y?"white":"",color:1.5===y?"black":"white"},onClick:function(){return b(1.5)}},"1.5"),a.a.createElement("button",{className:"".concat(2===y&&"active"),style:{backgroundColor:2===y?"white":"",color:2===y?"black":"white"},onClick:function(){return b(2)}},"2")),a.a.createElement("div",{className:"wrap-box-input-mobile custom-library"},a.a.createElement("input",Object.assign({id:"icon-button-file",type:"file",style:{display:"none"}},R({accept:"image/png,image/jpeg",onClick:function(e){e.stopPropagation()}}))),a.a.createElement("label",{htmlFor:"icon-button-file"},a.a.createElement(Re.a,{color:"primary","aria-label":"upload picture",component:"span",style:{width:32,height:32,borderRadius:"100%",padding:7,backgroundColor:"#F3F3F5"}},a.a.createElement(_e.a,{style:{fontSize:20,color:"red"}})))))))},Qe=["svgRef","title"];function Je(){return(Je=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Xe(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var $e,et=function(e){var t=e.svgRef,n=e.title,r=Xe(e,Qe);return a.a.createElement("svg",Je({width:24,height:22,viewBox:"0 0 22 21",style:{enableBackground:"new 0 0 22 20.28"},ref:t},r),n?a.a.createElement("title",null,n):null,Ye||(Ye=a.a.createElement("path",{className:"st3",d:"M 10.959 1.845 C 11.109 1.845 11.266 1.886 11.408 1.96 L 19.66 6.661 C 19.935 6.825 20.101 7.112 20.101 7.424 L 20.101 15.776 C 20.101 16.111 19.91 16.415 19.61 16.562 L 15.912 18.384 C 15.787 18.449 15.646 18.474 15.513 18.474 C 15.347 18.474 15.189 18.433 15.048 18.343 C 14.782 18.178 14.624 17.9 14.624 17.596 L 14.624 10.041 L 10.959 7.957 L 7.294 10.041 L 7.294 17.605 C 7.294 17.908 7.136 18.196 6.87 18.351 C 6.728 18.441 6.562 18.483 6.405 18.483 C 6.272 18.483 6.13 18.449 6.006 18.392 L 2.307 16.57 C 2.008 16.415 1.817 16.111 1.817 15.776 L 1.817 7.424 C 1.817 7.112 1.983 6.817 2.265 6.661 L 10.519 1.96 C 10.651 1.886 10.801 1.845 10.959 1.845 M 10.959 0.205 C 10.51 0.205 10.069 0.32 9.679 0.541 L 1.426 5.242 C 0.645 5.693 0.155 6.529 0.155 7.424 L 0.155 15.776 C 0.155 16.735 0.695 17.596 1.568 18.031 L 5.266 19.852 C 5.615 20.025 6.014 20.115 6.405 20.115 C 6.878 20.115 7.343 19.984 7.742 19.738 C 8.499 19.278 8.956 18.474 8.956 17.596 L 8.956 10.984 L 10.959 9.844 L 12.962 10.984 L 12.962 17.596 C 12.962 18.474 13.41 19.278 14.175 19.738 C 14.583 19.984 15.039 20.115 15.522 20.115 C 15.912 20.115 16.311 20.025 16.66 19.852 L 20.359 18.031 C 21.231 17.605 21.771 16.735 21.771 15.776 L 21.771 7.424 C 21.771 6.529 21.281 5.693 20.492 5.242 L 12.239 0.541 C 11.848 0.32 11.408 0.205 10.959 0.205 Z",fill:"currentColor",transform:"matrix(0.999999, 0.00121, -0.00121, 0.999999, 0.012302, -0.013258)"})))},tt=a.a.forwardRef((function(e,t){return a.a.createElement(et,Je({svgRef:t},e))})),nt=(n.p,["svgRef","title"]);function rt(){return(rt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function at(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ot,it=function(e){var t=e.svgRef,n=e.title,r=at(e,nt);return a.a.createElement("svg",rt({width:12,height:12,viewBox:"0 0 12 12",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,$e||($e=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M2.66658 10.9888C3.65328 11.6481 4.81331 12 6 12C7.5913 12 9.11742 11.3679 10.2426 10.2426C11.3679 9.11742 12 7.5913 12 6C12 4.81331 11.6481 3.65328 10.9888 2.66658C10.3295 1.67989 9.39246 0.910851 8.2961 0.456725C7.19975 0.0025997 5.99335 -0.11622 4.82946 0.115291C3.66557 0.346802 2.59648 0.918247 1.75736 1.75736C0.918247 2.59648 0.346802 3.66557 0.115291 4.82946C-0.11622 5.99335 0.0025997 7.19975 0.456725 8.2961C0.910851 9.39246 1.67989 10.3295 2.66658 10.9888ZM3.14278 1.72387C3.98852 1.15877 4.98284 0.857145 6 0.857145C7.36397 0.857145 8.67208 1.39898 9.63655 2.36345C10.601 3.32793 11.1429 4.63603 11.1429 6C11.1429 7.01716 10.8412 8.01148 10.2761 8.85722C9.71103 9.70296 8.90782 10.3621 7.96809 10.7514C7.02835 11.1406 5.9943 11.2425 4.99668 11.044C3.99906 10.8456 3.08269 10.3558 2.36345 9.63655C1.64421 8.91731 1.1544 8.00094 0.955964 7.00332C0.757526 6.00571 0.859372 4.97165 1.24862 4.03192C1.63787 3.09218 2.29705 2.28898 3.14278 1.72387ZM6 2.57143C5.87285 2.57143 5.74857 2.60913 5.64285 2.67977C5.53713 2.75041 5.45473 2.85081 5.40608 2.96827C5.35742 3.08574 5.34469 3.215 5.36949 3.3397C5.3943 3.4644 5.45553 3.57895 5.54543 3.66885C5.63534 3.75876 5.74988 3.81999 5.87458 3.84479C5.99929 3.8696 6.12854 3.85686 6.24601 3.80821C6.36348 3.75955 6.46388 3.67715 6.53452 3.57144C6.60515 3.46572 6.64286 3.34143 6.64286 3.21429C6.64286 3.04379 6.57513 2.88028 6.45457 2.75972C6.33401 2.63916 6.1705 2.57143 6 2.57143ZM6.42857 8.57143V5.14286H4.71428V6H5.57143V8.57143H4.28571V9.42857H7.71428V8.57143H6.42857Z",fill:"currentColor"})))},lt=a.a.forwardRef((function(e,t){return a.a.createElement(it,rt({svgRef:t},e))})),ct=(n.p,["svgRef","title"]);function ut(){return(ut=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function st(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ft,dt=function(e){var t=e.svgRef,n=e.title,r=st(e,ct);return a.a.createElement("svg",ut({width:24,height:24,viewBox:"0 0 24 24",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,ot||(ot=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.5 22.5H4.5C4.10232 22.4995 3.72105 22.3414 3.43984 22.0602C3.15864 21.7789 3.00046 21.3977 3 21V3C3.00046 2.60232 3.15864 2.22105 3.43984 1.93984C3.72105 1.65864 4.10232 1.50046 4.5 1.5H13.5C13.8977 1.50046 14.279 1.65864 14.5602 1.93984C14.8414 2.22105 14.9995 2.60232 15 3V5.25H13.5V3H4.5V21H13.5V18.75H15V21C14.9995 21.3977 14.8414 21.7789 14.5602 22.0602C14.279 22.3414 13.8977 22.4995 13.5 22.5ZM18.129 12.75L15.4395 15.4395L16.5 16.5L21 12L16.5 7.5L15.4395 8.5605L18.129 11.25H8.25C7.83579 11.25 7.5 11.5858 7.5 12C7.5 12.4142 7.83579 12.75 8.25 12.75H18.129Z",fill:"#AAABB5"})))},pt=a.a.forwardRef((function(e,t){return a.a.createElement(dt,ut({svgRef:t},e))})),ht=(n.p,["svgRef","title"]);function mt(){return(mt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function gt(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var vt,yt=function(e){var t=e.svgRef,n=e.title,r=gt(e,ht);return a.a.createElement("svg",mt({width:16,height:16,viewBox:"0 0 16 16",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,ft||(ft=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.475 3.575C13.7649 3.28505 13.7649 2.81495 13.475 2.525C13.1851 2.23505 12.715 2.23505 12.425 2.525L8.70711 6.24289C8.31658 6.63342 7.68342 6.63342 7.29289 6.24289L3.575 2.525C3.28505 2.23505 2.81495 2.23505 2.525 2.525C2.23505 2.81495 2.23505 3.28505 2.525 3.575L6.24289 7.29289C6.63342 7.68342 6.63342 8.31658 6.24289 8.70711L2.525 12.425C2.23505 12.7149 2.23505 13.1851 2.525 13.475C2.81495 13.7649 3.28505 13.7649 3.575 13.475L7.29289 9.75711C7.68342 9.36658 8.31658 9.36658 8.70711 9.75711L12.425 13.475C12.7149 13.7649 13.1851 13.7649 13.475 13.475C13.7649 13.1851 13.7649 12.715 13.475 12.425L9.75711 8.70711C9.36658 8.31658 9.36658 7.68342 9.75711 7.29289L13.475 3.575Z",fill:"currentColor"})))},bt=a.a.forwardRef((function(e,t){return a.a.createElement(yt,mt({svgRef:t},e))})),xt=(n.p,["svgRef","title"]);function wt(){return(wt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Ct(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Et=function(e){var t=e.svgRef,n=e.title,r=Ct(e,xt);return a.a.createElement("svg",wt({width:80,height:10,viewBox:"0 0 80 10",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,vt||(vt=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M53.4951 2.32957V7.28957H54.9651V3.93957C55.1251 3.78624 55.2718 3.66957 55.4051 3.58957C55.5384 3.5029 55.6984 3.45957 55.8851 3.45957C56.0984 3.45957 56.2518 3.52624 56.3451 3.65957C56.4451 3.7929 56.4951 4.03957 56.4951 4.39957V7.28957H57.9651V4.20957C57.9651 3.58957 57.8451 3.1029 57.6051 2.74957C57.3651 2.38957 56.9718 2.20957 56.4251 2.20957C56.0918 2.20957 55.7951 2.2829 55.5351 2.42957C55.2751 2.57624 55.0418 2.7529 54.8351 2.95957H54.7951L54.6951 2.32957H53.4951ZM59.3778 9.19957C59.4911 9.21957 59.6211 9.22957 59.7677 9.22957C60.1611 9.22957 60.4877 9.15624 60.7477 9.00957C61.0144 8.86957 61.2378 8.65957 61.4177 8.37957C61.6044 8.09957 61.7777 7.7529 61.9377 7.33957L63.6577 2.32957H62.2477L61.6478 4.45957C61.5877 4.6929 61.5277 4.92957 61.4678 5.16957L61.3078 5.86957H61.2677C61.2011 5.6229 61.1377 5.3829 61.0777 5.14957C61.0177 4.91624 60.9511 4.68624 60.8778 4.45957L60.1677 2.32957H58.6877L60.5977 7.15957L60.5277 7.41957C60.4678 7.60624 60.3677 7.75957 60.2277 7.87957C60.0944 8.00624 59.9044 8.06957 59.6577 8.06957C59.6111 8.06957 59.5611 8.06624 59.5077 8.05957C59.4611 8.05957 59.4011 8.04957 59.3277 8.02957L59.0677 9.10957C59.1677 9.14957 59.2711 9.17957 59.3778 9.19957ZM64.4326 2.32957V7.28957H65.9026V4.40957C66.0359 4.06957 66.2026 3.8329 66.4026 3.69957C66.6093 3.56624 66.8059 3.49957 66.9926 3.49957C67.0993 3.49957 67.1893 3.50624 67.2626 3.51957C67.3359 3.52624 67.4126 3.53957 67.4926 3.55957L67.7726 2.30957C67.7059 2.27624 67.6259 2.2529 67.5326 2.23957C67.4393 2.21957 67.3226 2.20957 67.1826 2.20957C66.9226 2.20957 66.6659 2.2929 66.4126 2.45957C66.1659 2.61957 65.9526 2.86624 65.7726 3.19957H65.7326L65.6326 2.32957H64.4326ZM68.417 2.32957V7.28957H69.887V2.32957H68.417ZM68.547 1.38957C68.7003 1.52957 68.9003 1.59957 69.147 1.59957C69.3936 1.59957 69.5936 1.52957 69.747 1.38957C69.9003 1.24957 69.977 1.0629 69.977 0.829571C69.977 0.596237 69.9003 0.40957 69.747 0.269571C69.5936 0.12957 69.3936 0.0595703 69.147 0.0595703C68.9003 0.0595703 68.7003 0.12957 68.547 0.269571C68.3936 0.40957 68.317 0.596237 68.317 0.829571C68.317 1.0629 68.3936 1.24957 68.547 1.38957ZM71.6306 7.21957C71.9773 7.34624 72.314 7.40957 72.6406 7.40957C73.0873 7.40957 73.4606 7.33957 73.7606 7.19957C74.0606 7.0529 74.2873 6.85957 74.4406 6.61957C74.6006 6.37957 74.6806 6.10957 74.6806 5.80957C74.6806 5.53624 74.6206 5.3029 74.5006 5.10957C74.3806 4.91624 74.214 4.75624 74.0006 4.62957C73.794 4.49624 73.564 4.38624 73.3106 4.29957C73.104 4.2329 72.9306 4.1729 72.7906 4.11957C72.6573 4.05957 72.5573 3.99624 72.4906 3.92957C72.424 3.8629 72.3906 3.7829 72.3906 3.68957C72.3906 3.57624 72.4373 3.4829 72.5306 3.40957C72.624 3.33624 72.7673 3.29957 72.9606 3.29957C73.134 3.29957 73.3106 3.32957 73.4906 3.38957C73.6706 3.4429 73.8506 3.5329 74.0306 3.65957L74.6606 2.83957C74.4473 2.6529 74.1906 2.5029 73.8906 2.38957C73.5973 2.26957 73.2706 2.20957 72.9106 2.20957C72.344 2.20957 71.884 2.3529 71.5306 2.63957C71.184 2.91957 71.0106 3.2929 71.0106 3.75957C71.0106 4.01957 71.0706 4.2429 71.1906 4.42957C71.3173 4.61624 71.4806 4.77624 71.6806 4.90957C71.8806 5.0429 72.1006 5.1529 72.3406 5.23957C72.5206 5.30624 72.6806 5.36957 72.8206 5.42957C72.9673 5.4829 73.084 5.54624 73.1706 5.61957C73.264 5.6929 73.3106 5.78624 73.3106 5.89957C73.3106 6.02624 73.2606 6.12957 73.1606 6.20957C73.0606 6.2829 72.9006 6.31957 72.6806 6.31957C72.474 6.31957 72.2573 6.28624 72.0306 6.21957C71.8106 6.14624 71.5873 6.01957 71.3606 5.83957L70.7406 6.66957C70.9873 6.90957 71.284 7.0929 71.6306 7.21957ZM76.2742 3.91957C76.5742 4.0929 76.9076 4.17957 77.2742 4.17957C77.6342 4.17957 77.9642 4.0929 78.2642 3.91957C78.5709 3.74624 78.8109 3.50957 78.9842 3.20957C79.1642 2.9029 79.2542 2.5529 79.2542 2.15957C79.2542 1.76624 79.1642 1.41957 78.9842 1.11957C78.8109 0.812904 78.5709 0.572904 78.2642 0.399571C77.9642 0.226237 77.6342 0.13957 77.2742 0.13957C76.9076 0.13957 76.5742 0.226237 76.2742 0.399571C75.9742 0.572904 75.7342 0.812904 75.5542 1.11957C75.3742 1.41957 75.2842 1.76624 75.2842 2.15957C75.2842 2.5529 75.3742 2.9029 75.5542 3.20957C75.7342 3.50957 75.9742 3.74624 76.2742 3.91957ZM78.0142 3.49957C77.8009 3.62624 77.5542 3.68957 77.2742 3.68957C76.9942 3.68957 76.7442 3.62624 76.5242 3.49957C76.3109 3.3729 76.1409 3.19624 76.0142 2.96957C75.8942 2.73624 75.8342 2.46624 75.8342 2.15957C75.8342 1.8529 75.8942 1.58624 76.0142 1.35957C76.1409 1.12624 76.3109 0.946237 76.5242 0.819571C76.7442 0.692904 76.9942 0.629571 77.2742 0.629571C77.5542 0.629571 77.8009 0.692904 78.0142 0.819571C78.2276 0.946237 78.3942 1.12624 78.5142 1.35957C78.6409 1.58624 78.7042 1.8529 78.7042 2.15957C78.7042 2.46624 78.6409 2.73624 78.5142 2.96957C78.3942 3.19624 78.2276 3.3729 78.0142 3.49957ZM76.4642 1.15957V3.12957H77.0342V2.52957H77.3242L77.6242 3.12957H78.2242L77.8142 2.35957C77.9342 2.30624 78.0209 2.22957 78.0742 2.12957C78.1342 2.02957 78.1642 1.92624 78.1642 1.81957C78.1642 1.5929 78.0876 1.42624 77.9342 1.31957C77.7809 1.2129 77.5876 1.15957 77.3542 1.15957H76.4642ZM77.2442 2.12957H77.0342V1.58957H77.2442C77.3442 1.58957 77.4176 1.61624 77.4642 1.66957C77.5176 1.71624 77.5442 1.77624 77.5442 1.84957C77.5442 1.92957 77.5176 1.99624 77.4642 2.04957C77.4176 2.1029 77.3442 2.12957 77.2442 2.12957ZM0.745093 0.729571V7.28957H1.57509V4.68957H2.65509C3.13509 4.68957 3.55509 4.61624 3.91509 4.46957C4.28176 4.31624 4.56509 4.0929 4.76509 3.79957C4.97176 3.49957 5.07509 3.11957 5.07509 2.65957C5.07509 2.17957 4.97176 1.79957 4.76509 1.51957C4.55843 1.23957 4.27176 1.03957 3.90509 0.919571C3.53843 0.792904 3.10843 0.729571 2.61509 0.729571H0.745093ZM2.55509 4.00957H1.57509V1.39957H2.51509C3.08843 1.39957 3.51843 1.4929 3.80509 1.67957C4.09843 1.85957 4.24509 2.18624 4.24509 2.65957C4.24509 3.11957 4.10509 3.45957 3.82509 3.67957C3.55176 3.89957 3.12843 4.00957 2.55509 4.00957ZM6.86501 7.10957C7.21168 7.30957 7.58168 7.40957 7.97501 7.40957C8.37501 7.40957 8.74502 7.30957 9.08502 7.10957C9.42501 6.90957 9.69835 6.61957 9.90501 6.23957C10.1183 5.85957 10.225 5.4029 10.225 4.86957C10.225 4.3229 10.1183 3.85957 9.90501 3.47957C9.69835 3.09957 9.42501 2.80957 9.08502 2.60957C8.74502 2.40957 8.37501 2.30957 7.97501 2.30957C7.58168 2.30957 7.21168 2.40957 6.86501 2.60957C6.52501 2.80957 6.24835 3.09957 6.03501 3.47957C5.82835 3.85957 5.72501 4.3229 5.72501 4.86957C5.72501 5.4029 5.82835 5.85957 6.03501 6.23957C6.24835 6.61957 6.52501 6.90957 6.86501 7.10957ZM8.71501 6.49957C8.50168 6.6529 8.25501 6.72957 7.97501 6.72957C7.69501 6.72957 7.44835 6.6529 7.23501 6.49957C7.02835 6.33957 6.86501 6.11957 6.74501 5.83957C6.63168 5.55957 6.57501 5.23624 6.57501 4.86957C6.57501 4.49624 6.63168 4.16957 6.74501 3.88957C6.86501 3.6029 7.02835 3.3829 7.23501 3.22957C7.44835 3.06957 7.69501 2.98957 7.97501 2.98957C8.25501 2.98957 8.50168 3.06957 8.71501 3.22957C8.92835 3.3829 9.09168 3.6029 9.20502 3.88957C9.31835 4.16957 9.37502 4.49624 9.37502 4.86957C9.37502 5.23624 9.31835 5.55957 9.20502 5.83957C9.09168 6.11957 8.92835 6.33957 8.71501 6.49957ZM10.8859 2.42957L12.2359 7.28957H13.2559L13.9059 4.68957C13.9659 4.46957 14.0192 4.24624 14.0659 4.01957C14.1192 3.7929 14.1692 3.53624 14.2159 3.24957H14.2559C14.3092 3.53624 14.3592 3.7929 14.4059 4.01957C14.4592 4.23957 14.5125 4.4629 14.5659 4.68957L15.2159 7.28957H16.2859L17.5959 2.42957H16.7959L16.0859 5.23957L15.9459 5.89957C15.8992 6.11957 15.8492 6.35957 15.7959 6.61957H15.7559C15.7025 6.35957 15.6492 6.11957 15.5959 5.89957C15.5492 5.67957 15.4959 5.45957 15.4359 5.23957L14.7059 2.42957H13.8059L13.0859 5.23957L12.9259 5.89957C12.8792 6.11957 12.8292 6.35957 12.7759 6.61957H12.7359C12.6959 6.35957 12.6525 6.11957 12.6059 5.89957C12.5592 5.67957 12.5092 5.45957 12.4559 5.23957L11.7459 2.42957H10.8859ZM19.3943 7.10957C19.7543 7.30957 20.151 7.40957 20.5843 7.40957C20.9176 7.40957 21.2143 7.3629 21.4743 7.26957C21.741 7.17624 21.981 7.05624 22.1943 6.90957L21.8943 6.36957C21.7276 6.4829 21.541 6.5729 21.3343 6.63957C21.1343 6.70624 20.9176 6.73957 20.6843 6.73957C20.391 6.73957 20.121 6.66957 19.8743 6.52957C19.6276 6.3829 19.431 6.16957 19.2843 5.88957C19.1711 5.66316 19.1037 5.39316 19.082 5.07957H22.3343C22.3543 4.99957 22.3643 4.91957 22.3643 4.83957C22.371 4.75957 22.3743 4.67624 22.3743 4.58957C22.3743 4.12957 22.301 3.72957 22.1543 3.38957C22.0076 3.04957 21.7876 2.78624 21.4943 2.59957C21.2076 2.40624 20.8576 2.30957 20.4443 2.30957C20.071 2.30957 19.7176 2.4129 19.3843 2.61957C19.051 2.82624 18.7776 3.11957 18.5643 3.49957C18.351 3.87957 18.2443 4.3329 18.2443 4.85957C18.2443 5.39957 18.3476 5.85957 18.5543 6.23957C18.761 6.6129 19.041 6.9029 19.3943 7.10957ZM21.6343 4.42957H19.0962C19.1257 4.1659 19.185 3.94256 19.2743 3.75957C19.4143 3.48624 19.591 3.28957 19.8043 3.16957C20.0176 3.0429 20.2343 2.97957 20.4543 2.97957C20.8343 2.97957 21.1243 3.10624 21.3243 3.35957C21.531 3.60624 21.6343 3.9629 21.6343 4.42957ZM23.5752 2.42957V7.28957H24.3952V4.16957C24.5619 3.75624 24.7552 3.46624 24.9752 3.29957C25.2019 3.1329 25.4186 3.04957 25.6252 3.04957C25.7252 3.04957 25.8052 3.05624 25.8652 3.06957C25.9319 3.07624 26.0019 3.08957 26.0752 3.10957L26.2552 2.40957C26.1752 2.36957 26.0952 2.3429 26.0152 2.32957C25.9352 2.31624 25.8419 2.30957 25.7352 2.30957C25.4552 2.30957 25.1952 2.39957 24.9552 2.57957C24.7153 2.75957 24.5152 3.0029 24.3552 3.30957H24.3252L24.2552 2.42957H23.5752ZM27.7244 7.10957C28.0844 7.30957 28.4811 7.40957 28.9144 7.40957C29.2477 7.40957 29.5444 7.3629 29.8044 7.26957C30.0711 7.17624 30.3111 7.05624 30.5244 6.90957L30.2244 6.36957C30.0577 6.4829 29.8711 6.5729 29.6644 6.63957C29.4644 6.70624 29.2477 6.73957 29.0144 6.73957C28.7211 6.73957 28.4511 6.66957 28.2044 6.52957C27.9577 6.3829 27.7611 6.16957 27.6144 5.88957C27.5012 5.66316 27.4337 5.39316 27.4121 5.07957H30.6644C30.6844 4.99957 30.6944 4.91957 30.6944 4.83957C30.7011 4.75957 30.7044 4.67624 30.7044 4.58957C30.7044 4.12957 30.6311 3.72957 30.4844 3.38957C30.3377 3.04957 30.1177 2.78624 29.8244 2.59957C29.5377 2.40624 29.1877 2.30957 28.7744 2.30957C28.4011 2.30957 28.0477 2.4129 27.7144 2.61957C27.3811 2.82624 27.1077 3.11957 26.8944 3.49957C26.6811 3.87957 26.5744 4.3329 26.5744 4.85957C26.5744 5.39957 26.6777 5.85957 26.8844 6.23957C27.0911 6.6129 27.3711 6.9029 27.7244 7.10957ZM29.9644 4.42957H27.4262C27.4557 4.1659 27.5151 3.94256 27.6044 3.75957C27.7444 3.48624 27.9211 3.28957 28.1344 3.16957C28.3477 3.0429 28.5644 2.97957 28.7844 2.97957C29.1644 2.97957 29.4544 3.10624 29.6544 3.35957C29.8611 3.60624 29.9644 3.9629 29.9644 4.42957ZM32.0953 6.74957C32.462 7.18957 32.952 7.40957 33.5653 7.40957C33.852 7.40957 34.122 7.3429 34.3753 7.20957C34.6287 7.06957 34.8487 6.90624 35.0353 6.71957H35.0653L35.1353 7.28957H35.8153V0.169571H34.9853V2.03957L35.0253 2.86957C34.812 2.68957 34.602 2.5529 34.3953 2.45957C34.1953 2.35957 33.952 2.30957 33.6653 2.30957C33.292 2.30957 32.9453 2.4129 32.6253 2.61957C32.3053 2.82624 32.0453 3.1229 31.8453 3.50957C31.652 3.88957 31.5553 4.3429 31.5553 4.86957C31.5553 5.67624 31.7353 6.3029 32.0953 6.74957ZM34.3853 6.54957C34.1853 6.6629 33.972 6.71957 33.7453 6.71957C33.3187 6.71957 32.9887 6.55624 32.7553 6.22957C32.522 5.89624 32.4053 5.43957 32.4053 4.85957C32.4053 4.48624 32.4687 4.1629 32.5953 3.88957C32.722 3.60957 32.8887 3.3929 33.0953 3.23957C33.3087 3.07957 33.5453 2.99957 33.8053 2.99957C34.0053 2.99957 34.202 3.03957 34.3953 3.11957C34.5887 3.1929 34.7853 3.3229 34.9853 3.50957V6.04957C34.7853 6.26957 34.5853 6.43624 34.3853 6.54957ZM40.9042 7.24957C41.1442 7.35624 41.3775 7.40957 41.6042 7.40957C41.9708 7.40957 42.3142 7.30624 42.6342 7.09957C42.9542 6.8929 43.2108 6.5929 43.4042 6.19957C43.6042 5.80624 43.7042 5.3329 43.7042 4.77957C43.7042 4.27957 43.6308 3.84624 43.4842 3.47957C43.3375 3.10624 43.1208 2.81957 42.8342 2.61957C42.5475 2.4129 42.1942 2.30957 41.7742 2.30957C41.5075 2.30957 41.2408 2.37624 40.9742 2.50957C40.7142 2.63624 40.4742 2.79624 40.2542 2.98957L40.2742 2.10957V0.169571H39.4542V7.28957H40.1142L40.1842 6.78957H40.2142C40.4342 6.9829 40.6642 7.13624 40.9042 7.24957ZM42.1742 6.48957C41.9675 6.6429 41.7308 6.71957 41.4642 6.71957C41.3042 6.71957 41.1175 6.6829 40.9042 6.60957C40.6975 6.52957 40.4875 6.39624 40.2742 6.20957V3.65957C40.5075 3.43957 40.7308 3.27624 40.9442 3.16957C41.1642 3.05624 41.3742 2.99957 41.5742 2.99957C41.8808 2.99957 42.1275 3.07624 42.3142 3.22957C42.5008 3.37624 42.6375 3.58624 42.7242 3.85957C42.8108 4.12624 42.8542 4.43624 42.8542 4.78957C42.8542 5.18957 42.7942 5.53624 42.6742 5.82957C42.5542 6.11624 42.3875 6.33624 42.1742 6.48957ZM44.7124 9.34957C44.8124 9.36957 44.9158 9.37957 45.0224 9.37957C45.3491 9.37957 45.6258 9.30624 45.8524 9.15957C46.0791 9.0129 46.2724 8.80957 46.4324 8.54957C46.5924 8.29624 46.7291 8.00957 46.8424 7.68957L48.6724 2.42957H47.8724L47.0024 5.11957C46.9424 5.3329 46.8758 5.55957 46.8024 5.79957C46.7358 6.0329 46.6658 6.2629 46.5924 6.48957H46.5524C46.4791 6.2629 46.4024 6.02957 46.3224 5.78957C46.2424 5.54957 46.1624 5.32624 46.0824 5.11957L45.0924 2.42957H44.2424L46.1924 7.29957L46.0824 7.65957C45.9824 7.95957 45.8424 8.20624 45.6624 8.39957C45.4891 8.59957 45.2624 8.69957 44.9824 8.69957C44.9291 8.69957 44.8724 8.6929 44.8124 8.67957C44.7524 8.6729 44.6924 8.65957 44.6324 8.63957L44.4524 9.27957C44.5324 9.30624 44.6191 9.32957 44.7124 9.34957Z",fill:"currentColor"})))},Ot=a.a.forwardRef((function(e,t){return a.a.createElement(Et,wt({svgRef:t},e))})),jt=(n.p,n(69)),Lt=n(930);var kt=function(e){var t=e.children,n=e.openModal,r=void 0!==n&&n,o=e.handleClose,i=e.classNameModal,l=e.classNameComponentChild,c=e.rounded,u=void 0===c||c;return a.a.createElement(Lt.a,{open:r,onClose:o,className:"modal-container ".concat(i||""),style:{display:"flex",justifyContent:"center",alignItems:"center"}},a.a.createElement("div",{className:l,style:{overflowY:"auto",maxHeight:"95vh",borderRadius:u?8:0}},t))};var St,Rt=function(e){var t,n,o,i=Object(r.useState)(!1),l=Object(p.a)(i,2),c=l[0],f=l[1],d=Object(s.f)(),m=we((function(e){return e})).search.imageCaptureHelpModal,g=xe(),v=we((function(e){return e})).settings,y=Object(jt.b)(),b=y.user,x=y.isAuthenticated,w=y.logout,C=v.auth0,E=Object(r.useState)(!1),O=Object(p.a)(E,2),j=O[0],L=O[1];return a.a.createElement(a.a.Fragment,null,a.a.createElement(kt,{openModal:j,handleClose:function(){L(!1)}},a.a.createElement("div",{style:{backgroundColor:"white",width:"360px",padding:"24px"}},a.a.createElement("div",{style:{display:"flex",justifyContent:"flex-end"},onClick:function(){return L(!1)}},a.a.createElement(bt,{width:"16px",height:"16px",fontSize:"16px",color:"black"})),a.a.createElement("p",{style:{fontSize:"36px",fontWeight:"bold",color:"#2B2C46"}},"Logout"),a.a.createElement("p",{style:{fontSize:"13px",color:"#2B2C46",paddingTop:"16px"}},"Are you sure you want to log out? Your session will be securely closed."),a.a.createElement("p",{style:{fontSize:"13px",color:"#2B2C46",paddingTop:"16px"}},"Email"),a.a.createElement("div",{style:{backgroundColor:"#FAFAFA",height:"32px",paddingLeft:"16px",paddingRight:"16px",marginTop:"8px"}},null===b||void 0===b?void 0:b.email),a.a.createElement("div",{style:{display:"flex",width:"100%",marginTop:"16px"}},a.a.createElement("div",{style:{width:"50%",backgroundColor:"#2B2C46",color:"white",padding:"16px"},onClick:function(){w({logoutParams:{returnTo:window.location.origin}})}},"Confirm log out")))),"/"===(null===(t=d.location)||void 0===t?void 0:t.pathname)&&v.showPoweredByNyris&&a.a.createElement("div",{style:{backgroundColor:"#fff",display:"flex",justifyContent:"center",padding:"16px 0px 16px 0px"}},a.a.createElement(Ot,{style:{cursor:"pointer"},onClick:function(){window.open("https://www.nyris.io","_blank")},color:"#AAABB5"})),a.a.createElement(h.a,{className:"box-footer-mobile",display:"flex",position:"relative",alignItems:"center",height:"100%",justifyContent:"space-between",style:{paddingLeft:"16px",paddingRight:"16px",height:"64px"}},a.a.createElement(u.b,{style:{width:"48px",height:"48px",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"100%",backgroundColor:"/"!==d.location.pathname||m?"":"#E0E0E0"},activeClassName:"active",to:"/",className:"nav-link p-0 menu-children rounded-0",onClick:function(){g(J("")),g(ne({})),g(ee(!1))}},a.a.createElement(tt,{color:"/"!==d.location.pathname||m?"#AAABB5":"#2B2C46"})),"/"!==(null===(n=d.location)||void 0===n?void 0:n.pathname)&&!m&&a.a.createElement(h.a,{className:"box-icon-camera-mobile"},a.a.createElement(Ce.a,{onClick:function(){f(!c)}},a.a.createElement(ke,{color:"#55566B"}))),a.a.createElement("div",{style:{display:"flex",gap:"24px"}},"/"!==(null===(o=d.location)||void 0===o?void 0:o.pathname)&&a.a.createElement("div",{style:{width:"48px",height:"48px",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"100%",backgroundColor:m?"#E0E0E0":""},onClick:function(){g(ee(!m))}},a.a.createElement(lt,{fontSize:24,width:24,height:24,color:m?"#2B2C46":"#AAABB5"})),C.enabled&&x&&a.a.createElement("div",{style:{display:"flex",alignItems:"center",justifyContent:"center"},onClick:function(){L(!0)}},a.a.createElement(pt,{fontSize:24,width:24,height:24})))),a.a.createElement(h.a,{className:"box-screenshot-camera"},a.a.createElement(Ke,{isToggle:c,onToggleModal:function(){f(!c)}})))},Nt=["svgRef","title"];function It(){return(It=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Mt(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var _t,Ft=function(e){var t=e.svgRef,n=e.title,r=Mt(e,Nt);return a.a.createElement("svg",It({width:16,height:16,viewBox:"0 0 16 16",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,St||(St=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15 4H12.95C12.7 2.85 11.7 2 10.5 2C9.3 2 8.3 2.85 8.05 4H1V5H8.05C8.3 6.15 9.3 7 10.5 7C11.7 7 12.7 6.15 12.95 5H15V4ZM10.5 6C9.65 6 9 5.35 9 4.5C9 3.65 9.65 3 10.5 3C11.35 3 12 3.65 12 4.5C12 5.35 11.35 6 10.5 6ZM1 12H3.05C3.3 13.15 4.3 14 5.5 14C6.7 14 7.7 13.15 7.95 12H15V11H7.95C7.7 9.85 6.7 9 5.5 9C4.3 9 3.3 9.85 3.05 11H1V12ZM5.5 10C6.35 10 7 10.65 7 11.5C7 12.35 6.35 13 5.5 13C4.65 13 4 12.35 4 11.5C4 10.65 4.65 10 5.5 10Z",fill:"currentColor"})))},Tt=a.a.forwardRef((function(e,t){return a.a.createElement(Ft,It({svgRef:t},e))})),Ht=(n.p,n(909)),Pt=n(910),Bt=["svgRef","title"];function At(){return(At=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Vt(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Gt,zt=function(e){var t=e.svgRef,n=e.title,r=Vt(e,Bt);return a.a.createElement("svg",At({width:24,height:24,viewBox:"0 0 24 24",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,_t||(_t=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M23.3723 22.117C23.719 22.4637 23.719 23.0257 23.3723 23.3723C23.0257 23.719 22.4637 23.719 22.117 23.3723L16.8475 18.1028C16.3904 17.6457 15.6641 17.6208 15.123 17.9745C11.1608 20.5639 5.82363 19.9525 2.55769 16.3754C-0.967972 12.5138 -0.832726 6.56215 2.86471 2.86471C6.56215 -0.832726 12.5138 -0.967972 16.3754 2.55769C19.9525 5.82363 20.5639 11.1608 17.9745 15.123C17.6208 15.6641 17.6457 16.3904 18.1028 16.8475L23.3723 22.117ZM9.79677 1.80687C5.38428 1.80687 1.80725 5.3839 1.80725 9.79639C1.81214 14.2069 5.38631 17.781 9.79677 17.7859C14.2093 17.7859 17.7863 14.2089 17.7863 9.79639C17.7863 5.3839 14.2093 1.80687 9.79677 1.80687Z",fill:"#000"})))},Dt=a.a.forwardRef((function(e,t){return a.a.createElement(zt,At({svgRef:t},e))})),qt=(n.p,["svgRef","title"]);function Zt(){return(Zt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Wt(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Ut=function(e){var t=e.svgRef,n=e.title,r=Wt(e,qt);return a.a.createElement("svg",Zt({width:16,height:16,viewBox:"0 0 16 16",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,Gt||(Gt=a.a.createElement("path",{d:"M9.33333 16H6.66667C6.31305 16 5.97391 15.8595 5.72386 15.6095C5.47381 15.3594 5.33333 15.0203 5.33333 14.6667V9.60667L0.393333 4.66667C0.142942 4.41777 0.00148853 4.07972 0 3.72667V1.33333C0 0.979711 0.140476 0.640573 0.390524 0.390524C0.640573 0.140476 0.979711 0 1.33333 0H14.6667C15.0203 0 15.3594 0.140476 15.6095 0.390524C15.8595 0.640573 16 0.979711 16 1.33333V3.72667C15.9985 4.07972 15.8571 4.41777 15.6067 4.66667L10.6667 9.60667V14.6667C10.6667 15.0203 10.5262 15.3594 10.2761 15.6095C10.0261 15.8595 9.68696 16 9.33333 16ZM1.33333 1.33333V3.72667L6.66667 9.06V14.6667H9.33333V9.06L14.6667 3.72667V1.33333H1.33333Z",fill:"currentColor"})))},Yt=a.a.forwardRef((function(e,t){return a.a.createElement(Ut,Zt({svgRef:t},e))})),Kt=(n.p,function(){var e=Object(s.g)().search;return Object(r.useMemo)((function(){return new URLSearchParams(e)}),[e])}),Qt=n(37);var Jt,Xt=Object(Ht.a)(Object(r.memo)(Object(Pt.a)((function(e){var t,n,o,i,l,c,d,m,g,v,y,b,x=Object(jt.b)().user,w=we((function(e){return e.settings})).auth0,C=e.onToggleFilterMobile,E=e.refine,O=xe(),j=we((function(e){return e})).search,L=j.imageThumbSearchInput,k=j.textSearchInputMobile,S=j.preFilter,R=j.preFilterDropdown,N=j.valueTextSearch,I=j.queryText,M=j.requestImage,_=j.selectedRegion,F=Kt(),T=Object(r.useRef)(null),H=Object(r.useState)(!1),P=Object(p.a)(H,2),B=P[0],A=P[1],V=Object(s.f)(),G=we((function(e){return e})).settings,z=Object(r.useState)(I||""),D=Object(p.a)(z,2),q=D[0],Z=D[1],W=F.get("query")||"";Object(r.useEffect)((function(){var e;"/result"===(null===(e=V.location)||void 0===e?void 0:e.pathname)&&(L||k)?A(!0):A(!1)}),[L,V.location,k]),Object(r.useEffect)((function(){var e;""!==L&&(V.push("/result"),O(de("")),(null===(e=G.algolia)||void 0===e?void 0:e.enabled)?E(""):(O(ue("")),Z("")))}),[L,O,E,V,G.algolia]),Object(r.useEffect)((function(){var e;Object(He.isEmpty)(W)||(O(de(W)),(null===(e=G.algolia)||void 0===e?void 0:e.enabled)?(E(W),setTimeout((function(){E(W)}),100)):O(ue(W)))}),[F,E,O,W,G.algolia]);var U=Object(r.useCallback)(Object(He.debounce)((function(e){var t;if(!(null===(t=G.algolia)||void 0===t?void 0:t.enabled)){var n;O(ue(e));var r=[],a=[{key:G.visualSearchFilterKey,values:Object.keys(S)}];e||M?(O(fe(!0)),We({image:null===M||void 0===M?void 0:M.canvas,settings:G,filters:Object(He.isEmpty)(S)?void 0:a,region:_,text:e}).then((function(e){null===e||void 0===e||e.results.map((function(e){r.push({sku:e.sku,score:e.score})})),n=Object(f.a)(Object(f.a)({},e),{},{filters:r}),O(ie(n)),O(fe(!1))})).catch((function(e){console.log("error input search",e),O(fe(!1))}))):O(ie([]))}e?V.push({pathname:"/result",search:"?query=".concat(e)}):V.push("/result")}),500),[M]),Y=Object(r.useMemo)((function(){var e=!1;return!!(null===N||void 0===N?void 0:N.refinementList)&&(Object.keys(null===N||void 0===N?void 0:N.refinementList).forEach((function(t){"object"!==typeof N.refinementList[t]||(e=!0)})),e)}),[null===N||void 0===N?void 0:N.refinementList]),K=Object(r.useMemo)((function(){var t;return!(G.postFilterOption&&(null===(t=e.allSearchResults)||void 0===t?void 0:t.hits.length)>0)}),[G.postFilterOption,null===(t=e.allSearchResults)||void 0===t?void 0:t.hits]);return a.a.createElement("div",{style:{width:"100%",background:"#fff"}},"/result"!==(null===(n=V.location)||void 0===n?void 0:n.pathname)&&a.a.createElement(h.a,{className:"box-content",style:{display:"flex",alignItems:"center",height:"48px",background:null===(o=G.theme)||void 0===o?void 0:o.headerColor}},a.a.createElement(u.b,{to:"/",style:{lineHeight:0,paddingLeft:"10px"},onClick:function(){O(J("")),O(ne({}))}},a.a.createElement("img",{src:null===(i=G.theme)||void 0===i?void 0:i.appBarLogoUrl,alt:"logo",style:{aspectRatio:1,width:null===(l=G.theme)||void 0===l?void 0:l.logoWidth,height:null===(c=G.theme)||void 0===c?void 0:c.logoHeight}}))),(w.enabled&&(null===x||void 0===x?void 0:x.email_verified)||!w.enabled)&&a.a.createElement("div",{style:{margin:"16px 8px",display:"flex",columnGap:"8px",alignItems:"center"}},a.a.createElement("div",{className:"wrap-header-mobile",style:{height:"56px"}},a.a.createElement("div",{style:{display:"flex",alignItems:"center",height:"100%"}},a.a.createElement("div",{ref:T,id:"box-input-search",className:"d-flex w-100",style:{alignItems:"center",height:"100%"}},a.a.createElement(h.a,{className:"pre-filter-icon",onClick:function(){G.preFilterOption&&(C(!1),O(re(!R)))},style:{cursor:G.preFilterOption?"pointer":""}},G.preFilterOption&&a.a.createElement("div",{className:"icon-hover",style:Object(f.a)({},Object(He.isEmpty)(S)?{backgroundColor:"#2B2C46"}:{backgroundColor:"".concat(null===(d=G.theme)||void 0===d?void 0:d.primaryColor)})},a.a.createElement(Tt,{color:"white"})),!G.preFilterOption&&a.a.createElement(Dt,{width:16,height:16}),!Object(He.isEmpty)(S)&&a.a.createElement("div",{style:{position:"absolute",top:"7px",left:"35px",display:"flex",justifyContent:"center",alignItems:"center",background:"white",width:"10px",height:"10px",borderRadius:"100%"}},a.a.createElement("div",{style:{width:"8px",height:"8px",background:null===(m=G.theme)||void 0===m?void 0:m.primaryColor,borderRadius:"100%"}}))),a.a.createElement($t,{value:k||W||q,onChange:function(e){U(e.currentTarget.value),""===e.currentTarget.value?(O(de("")),E("")):O(de(e.currentTarget.value))}}),"/"!==(null===(g=V.location)||void 0===g?void 0:g.pathname)&&k&&a.a.createElement(Ce.a,{onClick:function(){if(L)return V.push("/result"),O(de("")),void E("");O(de("")),O(J("")),E(""),V.push("/")},style:{marginRight:"8px",border:0,width:"40px",height:"40px"}},a.a.createElement(Ie.a,{style:{fontSize:16,color:null===(v=G.theme)||void 0===v?void 0:v.secondaryColor}}))))),B&&G.postFilterOption&&a.a.createElement("div",{style:{position:"relative",width:"56px",height:"56px",padding:" 8px",flexShrink:0,borderRadius:"32px",background:"#FAFAFA",boxShadow:" 0px 0px 8px 0px rgba(0, 0, 0, 0.15)"},onClick:function(){K||(C(),O(re(!1)))}},a.a.createElement("div",{style:{display:"flex",background:"".concat(K?"#F3F3F5":null===(y=G.theme)||void 0===y?void 0:y.primaryColor),borderRadius:"40px",width:"40px",height:"40px",justifyContent:"center",alignItems:"center"}},a.a.createElement(Yt,{color:"".concat(K?"#E0E0E0":"white")})),Y&&!K&&a.a.createElement("div",{style:{position:"absolute",top:"8px",left:"37px",display:"flex",justifyContent:"center",alignItems:"center",background:"white",width:"10px",height:"10px",borderRadius:"100%"}},a.a.createElement("div",{style:{width:"8px",height:"8px",background:null===(b=G.theme)||void 0===b?void 0:b.primaryColor,borderRadius:"100%"}})))))})))),$t=function(e){var t=e.value,n=e.onChange;Object(r.useEffect)((function(){var e=document.getElementById("mobile-input-search"),t=function(t){"Enter"===t.key&&(null===e||void 0===e||e.blur())};return null===e||void 0===e||e.addEventListener("keyup",t,!1),function(){null===e||void 0===e||e.removeEventListener("scroll",t,!1)}}),[]);var o=Object(Qt.b)().t;return a.a.createElement("input",{style:{border:"0px",width:"100%",display:"flex",flexGrow:1,fontSize:14,paddingLeft:"12px",paddingRight:"4px",color:"#2B2C46",outline:"none",borderRadius:"32px"},className:"input-search",placeholder:o("Search"),value:t,onChange:n,id:"mobile-input-search"})},en=n(17),tn=n(931),nn=["svgRef","title"];function rn(){return(rn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function an(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var on=function(e){var t=e.svgRef,n=e.title,r=an(e,nn);return a.a.createElement("svg",rn({width:16,height:16,viewBox:"0 0 16 16",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,Jt||(Jt=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14.153 13.1029C16.4093 10.3896 16.6189 6.51922 14.6686 3.57859C12.7184 0.63796 9.06952 -0.677581 5.68945 0.34128C2.30938 1.36014 -0.00263212 4.47248 2.24892e-06 8.00018C0.00045013 9.86651 0.658681 11.6731 1.85919 13.1029L1.84775 13.1123C1.86985 13.139 1.89369 13.1635 1.91756 13.188L1.91757 13.1881L1.91758 13.1881C1.93694 13.208 1.95633 13.2279 1.97482 13.249C2.00851 13.2878 2.04377 13.3248 2.07913 13.3618L2.07914 13.3619L2.07918 13.3619C2.09781 13.3814 2.11647 13.401 2.13494 13.4209C2.29507 13.5942 2.45942 13.761 2.63247 13.918C2.66868 13.9509 2.70582 13.9824 2.74301 14.0139L2.74305 14.0139L2.79259 14.0561C2.97558 14.2138 3.16338 14.3631 3.35873 14.5026C3.37125 14.5114 3.38306 14.5212 3.39489 14.5311L3.39492 14.5311C3.40691 14.5411 3.41892 14.5511 3.4317 14.5601V14.5528C6.17596 16.4824 9.83728 16.4824 12.5815 14.5528V14.5599C12.5943 14.5509 12.6063 14.5409 12.6183 14.531C12.6302 14.5211 12.642 14.5113 12.6545 14.5025C12.8496 14.363 13.0377 14.2137 13.2207 14.056L13.2614 14.0214L13.2614 14.0214C13.3015 13.9874 13.3417 13.9534 13.3808 13.9179C13.5538 13.7608 13.7182 13.594 13.8783 13.4208C13.8971 13.4005 13.9161 13.3806 13.935 13.3607L13.9351 13.3606C13.97 13.3239 14.0049 13.2872 14.0384 13.2489C14.057 13.2276 14.0766 13.2074 14.0962 13.1873L14.0962 13.1873L14.0962 13.1873C14.1199 13.163 14.1436 13.1386 14.1655 13.1122L14.153 13.1029ZM8.00611 3.42892C9.42735 3.42892 10.5795 4.58015 10.5795 6.00026C10.5795 7.42036 9.42735 8.57159 8.00611 8.57159C6.58486 8.57159 5.43271 7.42036 5.43271 6.00026C5.43271 4.58015 6.58486 3.42892 8.00611 3.42892ZM6.29051 10.2858C4.72789 10.2866 3.4558 11.5416 3.43525 13.1029C6.03294 15.4418 9.97927 15.4418 12.577 13.1029C12.5564 11.5416 11.2843 10.2866 9.7217 10.2858H6.29051Z",fill:"#2B2C46"})))},ln=a.a.forwardRef((function(e,t){return a.a.createElement(on,rn({svgRef:t},e))})),cn=(n.p,n(934));var un=function(){var e,t,n,r=xe(),o=we((function(e){return e})).settings,i=Object(jt.b)(),l=i.user,c=i.isAuthenticated,u=i.logout,s=o.auth0,f=a.a.useState(null),d=Object(p.a)(f,2),m=d[0],g=d[1],v=Object(en.a)({root:{},paper:{border:"0px",boxShadow:"0px 0px 8px 0px rgba(0, 0, 0, 0.20)",top:"58px !important",borderRadius:"0px !important"}})((function(e){return a.a.createElement(tn.a,Object.assign({elevation:0,getContentAnchorEl:null,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"}},e))})),y=Object(en.a)((function(e){return{root:{"&:focus":{backgroundColor:e.palette.primary.main,"& .MuiListItemIcon-root, & .MuiListItemText-primary":{color:e.palette.common.white}},padding:"0px"}}}))(cn.a);return a.a.createElement(h.a,{className:"box-content",display:"flex"},a.a.createElement("a",{href:window.location.origin,style:{lineHeight:0,paddingLeft:"10px"},onClick:function(){r(J("")),r(ne({}))}},a.a.createElement("img",{src:null===(e=o.theme)||void 0===e?void 0:e.appBarLogoUrl,alt:"logo",style:{aspectRatio:1,width:null===(t=o.theme)||void 0===t?void 0:t.logoWidth,height:null===(n=o.theme)||void 0===n?void 0:n.logoHeight}})),s.enabled&&c&&a.a.createElement("div",{style:{position:"relative"}},a.a.createElement("div",{style:{display:"flex",columnGap:"16px",alignItems:"center",paddingRight:"24px",cursor:"pointer"},"aria-controls":"simple-menu","aria-haspopup":"true",onClick:function(e){g(e.currentTarget)}},a.a.createElement("p",{style:{color:"#2B2C46"}},null===l||void 0===l?void 0:l.email),a.a.createElement(ln,null)),a.a.createElement(v,{id:"simple-menu",anchorEl:m,keepMounted:!0,open:Boolean(m),onClose:function(){g(null)}},a.a.createElement(y,null,a.a.createElement("div",{style:{display:"flex",width:"152px",paddingLeft:"8px",paddingRight:"8px",flexDirection:"column",alignItems:"flex-start",gap:"8px",boxShadow:"0px 0px 8px 0px rgba(0, 0, 0, 0.20)",backgroundColor:"#fff"}},a.a.createElement("div",{style:{display:"flex",width:"75px",height:"24px",padding:"4px 8px",alignItems:"center",backgroundColor:"#2B2C46",color:"#fff",fontSize:"10px",cursor:"pointer"},onClick:function(){u({logoutParams:{returnTo:window.location.origin}})}},"Sign out"))))))},sn=n(489);function fn(){fn=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var dn=n.n(sn).a.create(),pn=function(){var e=Object(d.a)(fn().mark((function e(t){var n,r,a,o;return fn().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.apiKey,r=t.baseUrl,a={"X-Api-Key":n},e.next=4,dn.request({method:"POST",url:"".concat(r,"/find/v1/session"),headers:a});case 4:return o=e.sent,e.abrupt("return",o.data.session);case 6:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();var hn=function(e){var t=e.handleClose;return a.a.createElement(h.a,{style:{paddingBottom:"24px"}},a.a.createElement(h.a,{display:"flex",justifyContent:"end",position:"sticky",top:0,style:{background:"white",width:"100%"}},a.a.createElement(Ce.a,{onClick:t,style:{paddingTop:"8px",paddingRight:"8px"}},a.a.createElement(Ie.a,{fontSize:"small"}))),a.a.createElement("p",{style:{fontSize:"40px",lineHeight:"40px",fontWeight:700,color:"#2B2C46",paddingLeft:"24px",paddingRight:"24px"}},"Six ways to optimize visual search"),a.a.createElement("div",{style:{display:"flex",flexDirection:"column",rowGap:"16px",marginTop:"16px",paddingLeft:"24px",paddingRight:"24px"}},D.map((function(e,t){return a.a.createElement("div",{key:t,style:{display:"flex",flexDirection:"column",rowGap:"8px"}},a.a.createElement("p",{style:{fontSize:"16px",lineHeight:"24px",fontWeight:700,color:"#2B2C46",marginBottom:"0px"}},"".concat(t+1,"- ").concat(e.title)),a.a.createElement("p",{style:{fontSize:"14px",lineHeight:"20px",fontWeight:400,color:"#2B2C46",marginBottom:"0px"}},e.description),a.a.createElement("div",{style:{display:"flex",columnGap:"16px"}},a.a.createElement("div",null,a.a.createElement("img",{src:e.imageLeft,alt:""})),a.a.createElement("div",null,a.a.createElement("img",{src:e.imageRight,alt:""}))))}))))},mn=n(88),gn=n(63),vn=n(60),yn=["children","enabled"];function bn(e){var t=e.children,n=e.enabled,o=void 0===n||n,i=Object(mn.a)(e,yn),l=Object(r.useState)(),c=Object(p.a)(l,2),u=c[0],s=c[1];return Object(r.useEffect)((function(){s(o)}),[o]),u?a.a.createElement("div",i,t):a.a.createElement(a.a.Fragment,null)}var xn=n(264),wn=n.n(xn),Cn=n(265),En=n.n(Cn),On=n(912);function jn(e){var t=e.icon,n=e.label,o=(e.labelPosition,e.className,e.classNameLabel),i=void 0===o?"":o,l=Object(r.useState)(""),c=Object(p.a)(l,2),u=c[0],s=c[1];return Object(r.useEffect)((function(){s(t)}),[t]),a.a.createElement("div",{style:{display:"flex",alignItems:"center"}},n&&a.a.createElement("div",{className:i},a.a.createElement(On.a,{style:{textTransform:"none",fontSize:12,color:"#55566B",fontWeight:600}},n)),"remove"===u?a.a.createElement(wn.a,{style:{color:"#55566B"}}):a.a.createElement(En.a,{style:{color:"#55566B"}}))}var Ln=n(121),kn=n(926),Sn=n(52),Rn=n.n(Sn),Nn=n(937),In=n(924),Mn={collapsed:function(e){return{height:e?"auto":0,opacity:0,pointerEvents:"none",transitionEnd:{display:"none"}}},expanded:function(e){return{height:"auto",opacity:1,pointerEvents:"auto",display:"block"}}},_n={ease:[.16,1,.3,1],duration:.6};function Fn(e){var t=e.isCollapsed,n=e.className,r=e.children,o=Object(Nn.a)();return a.a.createElement(a.a.Fragment,null,a.a.createElement(In.a.div,{key:"collapse",initial:"collapsed",animate:t?"collapsed":"expanded",variants:Mn,className:Rn()("overflow-hidden",n),transition:_n,custom:o},r))}var Tn=n(190),Hn=n(913),Pn=n(111),Bn=n.n(Pn),An=Object(Ln.atom)({searchResults:void 0,isSearchStalled:void 0}),Vn=Object(Tn.selectAtom)(An,(function(e){return e.searchResults}),Bn.a);Object(Tn.selectAtom)(An,(function(e){return e.isSearchStalled}));Object(Pt.a)(Object(r.memo)((function(e){var t=e.searchResults,n=e.isSearchStalled,a=Object(Tn.useUpdateAtom)(An);return Object(r.useEffect)((function(){a({searchResults:t,isSearchStalled:n})}),[a,t,n]),null}),Bn.a));var Gn=Object(Hn.a)(Object(r.memo)((function(e){var t=e.children,n=e.className,o=e.header,i=e.attributes,l=void 0===i?[]:i,c=e.isOpened,u=void 0!==c&&c,s=(e.items,e.onToggle),f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=Object(r.useMemo)((function(){var t=(null===e||void 0===e?void 0:e.disjunctiveFacets)||[],n=(null===e||void 0===e?void 0:e.hierarchicalFacets)||[];return[].concat(Object(vn.a)(t),Object(vn.a)(n))}),[e]),a=Object(r.useMemo)((function(){var e=!t.length;return n.forEach((function(n){null===t||void 0===t||t.forEach((function(t){n.name===t&&n.data&&(e=!0)}))})),e}),[n,t]);return a}(Object(Tn.useAtomValue)(Vn),l),d=Object(m.useMediaQuery)({query:"(max-width: 776px)"});return a.a.createElement(h.a,null,a.a.createElement("div",{className:Rn()("border-neutral-light",{hidden:!f},n)},a.a.createElement(Ce.a,{className:"w-full flex items-center justify-between group","aria-expanded":u,style:{paddingLeft:0},onClick:function(e){"function"===typeof s&&s(e)}},a.a.createElement("div",{className:"flex items-center w-full subhead"},a.a.createElement(On.a,{className:"fw-700",style:{textTransform:"none",fontFamily:"Source Sans 3 !important",fontSize:14}},o||l[0])),!d&&a.a.createElement("div",{className:"text-neutral-dark can-hover:transition-colors can-hover:group-hover:text-neutral-light"},u?a.a.createElement(wn.a,null):a.a.createElement(En.a,null))),a.a.createElement(Fn,{isCollapsed:!u},a.a.createElement("div",{className:"mt-4"},t))))})));function zn(e){var t;return(null===e||void 0===e?void 0:e.attributes)?null===(t=e.options)||void 0===t?void 0:t.attributes.join(":"):null===e||void 0===e?void 0:e.attribute}function Dn(e){var t=e.widgets,n=[];return(null===t||void 0===t?void 0:t.length)?t.forEach((function(e){return n.push(zn(e))})):n.push(zn(e)),n.join(":")}function qn(e){return null===e||void 0===e?void 0:e.attribute}var Zn=["children","onToggle","panelId"];var Wn=Object(Ln.atom)((function(e){return Boolean(Object.values(e(Un)).find((function(e){return!0===e})))}),(function(e,t,n){var r,a,o=n(e(Wn));t(Un,(r=e(Un),a=o,Object.keys(r).reduce((function(e,t){return Object(f.a)(Object(f.a)({},e),{},Object(gn.a)({},t,a))}),{})))})),Un=Object(Ln.atom)({});function Yn(e){var t=e.children,n=e.onToggle,o=e.panelId,i=Object(mn.a)(e,Zn),l=Object(r.useCallback)((function(){return n(o)}),[n,o]);return a.a.createElement(Gn,Object.assign({onToggle:l},i),t)}function Kn(e){var t,n=e.dynamicWidgets,o=void 0===n||n,i=e.onApply,l=(e.disjunctiveFacets,we((function(e){return e})).settings),c=l.refinements,u=Object(Ln.useAtom)(Un),d=Object(p.a)(u,2),g=d[0],v=d[1],y=Object(Ln.useAtom)(Wn),b=Object(p.a)(y,2),x=b[0],w=b[1],C=Object(s.f)(),E=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),O=Object(Qt.b)().t;Object(r.useEffect)((function(){v((function(e){return Object(f.a)(Object(f.a)({},e),c.reduce((function(e,t){return Object(f.a)(Object(f.a)({},e),{},Object(gn.a)({},Dn(t),Boolean(t.isExpanded)))}),{}))}))}),[]);var j=Object(r.useCallback)((function(e){v((function(t){return Object(f.a)(Object(f.a)({},t),{},Object(gn.a)({},e,!t[e]))}))}),[v]),L=Object(r.useMemo)((function(){return c.map((function(e){return a.a.createElement(kn.a,Object.assign({className:"box-refinement-list",attribute:e.attribute},e.options,{translations:{noResults:"No results",placeholder:""},sortBy:["isRefined:desc","name:asc"]}))}))}),[c]),k=Object(r.useMemo)((function(){return L.map((function(e,t){var n=c[t],r=Dn(n),o=function(e){var t,n=null===(t=e)||void 0===t?void 0:t.widgets,r=[];return(null===n||void 0===n?void 0:n.length)?n.forEach((function(e){return r.push(qn(e))})):r.push(qn(e)),r}(n);return e?a.a.createElement(Yn,{key:r,panelId:r,attributes:o,header:n.header,isOpened:E?!g[r]:g[r],onToggle:j},e):a.a.createElement(a.a.Fragment,null)}))}),[L,c,j,g,E]),S=Object(r.useCallback)((function(){w((function(e){return!e}))}),[w]);return a.a.createElement(a.a.Fragment,null,!E&&a.a.createElement("div",{className:"wrap-main-header-panel"},a.a.createElement(h.a,{style:{borderBottom:"1px solid #E0E0E0"}},a.a.createElement(Ce.a,{className:"text-neutral-darkest",onClick:S,style:{justifyContent:"flex-end"}},a.a.createElement(jn,{icon:x?"remove":"add",label:"".concat(O(x?"Collapse all":"Expand all")," ")})))),a.a.createElement(h.a,null,E&&a.a.createElement("div",{style:{display:"flex",justifyContent:"flex-end",position:"sticky",top:"0px",zIndex:100,background:"white",alignItems:"center",paddingTop:"10px",paddingRight:"10px"}},a.a.createElement(Ce.a,{onClick:i},a.a.createElement(Ie.a,null))),a.a.createElement(h.a,{className:"box-center-filter",style:Object(f.a)({},E?{paddingLeft:"24px",paddingRight:"24px",overflow:"auto"}:{})},a.a.createElement(bn,{enabled:o},k))),E&&a.a.createElement(h.a,{style:{position:"sticky",bottom:0,width:"100%"}},a.a.createElement(Ce.a,{className:"text-white",style:{width:"100%",backgroundColor:null===(t=l.theme)||void 0===t?void 0:t.primaryColor,fontWeight:700,fontSize:14,borderRadius:0},onClick:function(){i(),"/result"!==C.location.pathname&&C.push("/result")}},"APPLY")))}var Qn=Object(Pt.a)(Object(r.memo)((function(e){var t;return a.a.createElement(Kn,{disjunctiveFacets:null===e||void 0===e||null===(t=e.allSearchResults)||void 0===t?void 0:t.disjunctiveFacets,onApply:e.onApply})}))),Jn=n(935),Xn=n(490),$n=n.n(Xn);function er(){er=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var tr=function(){var e=Object(d.a)(er().mark((function e(){var t,n,r,a=arguments;return er().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=a.length>0&&void 0!==a[0]?a[0]:10,n=a.length>1?a[1]:void 0,r=new Ge.a(n),e.abrupt("return",r.getFilters(t));case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),nr=function(){var e=Object(d.a)(er().mark((function e(){var t,n,r,a,o,i=arguments;return er().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=i.length>0&&void 0!==i[0]?i[0]:"",n=i.length>1?i[1]:void 0,r=i.length>2?i[2]:void 0,a=new Ge.a(r),o=n||"",e.abrupt("return",a.searchFilters(t,o));case 6:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),rr=n(915);function ar(e,t){return(null===e||void 0===e?void 0:e.length)>t?(null===e||void 0===e?void 0:e.slice(0,t))+"...":e}function or(){or=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var ir=function(e){var t,n,o=e.handleClose,i=xe(),l=we((function(e){return e})),c=l.settings,u=Object(r.useState)([]),s=Object(p.a)(u,2),g=s[0],v=s[1],y=Kt().get("query")||"",b=l.search,x=b.preFilter,w=b.requestImage,C=b.selectedRegion,E=Object(r.useState)(x||{}),O=Object(p.a)(E,2),j=O[0],L=O[1],k=Object(r.useState)(!1),S=Object(p.a)(k,2),R=S[0],N=S[1],I=Object(r.useState)(0),M=Object(p.a)(I,2),_=M[0],F=M[1],T=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),H=Object(r.useMemo)((function(){return Object.keys(j).reduce((function(e,t){return!0===j[t]?e+1:e}),0)}),[j]),P=function(){var e=Object(d.a)(or().mark((function e(){var t;return or().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return N(!0),t=tr(1e3,c).then((function(e){var t,n=((null===(t=e.find((function(e){return e.key===c.visualSearchFilterKey})))||void 0===t?void 0:t.values)||[]).sort().reduce((function(e,t){var n;if(!t[0])return e;var r=null===(n=t[0])||void 0===n?void 0:n.toLocaleUpperCase();return e[r]?e[r].push(t):e[r]=[t],e}),{});v(n),F(Object.keys(n).length)})).catch((function(e){console.log("err getDataFilterDesktop",e)})).finally((function(){N(!1)})),e.abrupt("return",t);case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();Object(r.useEffect)((function(){P()}),[]);var B=function(){var e=Object(d.a)(or().mark((function e(t){var n;return or().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t){e.next=3;break}return P(),e.abrupt("return");case 3:return e.next=5,nr(c.visualSearchFilterKey,encodeURIComponent(t),c).then((function(e){e.length>0?(v(Object(gn.a)({},e[0][0].toLocaleUpperCase(),e)),e.length<=20?F(1):e.length<=40?F(2):F(4)):(v({}),F(4))})).catch((function(e){console.log("err filterSearchHandler",e)}));case 5:return n=e.sent,e.abrupt("return",n);case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),A=function(){var e,t=Object(He.pickBy)(j,(function(e){return!!e}));if(i(ne(t)),!(null===(e=c.algolia)||void 0===e?void 0:e.enabled)&&(y||w)){var n,r=[],a=[{key:c.visualSearchFilterKey,values:Object.keys(t)}];i(fe(!0)),We({image:null===w||void 0===w?void 0:w.canvas,settings:c,filters:Object(He.isEmpty)(t)?void 0:a,region:C,text:y}).then((function(e){null===e||void 0===e||e.results.map((function(e){r.push({sku:e.sku,score:e.score})})),n=Object(f.a)(Object(f.a)({},e),{},{filters:r}),i(ie(n)),i(fe(!1))})).catch((function(e){i(fe(!1))}))}o()};return a.a.createElement(h.a,{className:"box-child-component-filter-desktop",display:"flex",flexDirection:"column",style:{position:"relative"}},a.a.createElement("div",{style:{background:"white",width:"100%",display:"flex",justifyContent:"space-between",position:"sticky",top:0,zIndex:100}},a.a.createElement(On.a,{style:{color:"#000",fontSize:"24px",fontWeight:700,paddingLeft:"14px",marginBottom:T?"0px":"-8px",marginTop:T?"0px":"24px"}},c.preFilterTitle),a.a.createElement(Ce.a,{onClick:o},a.a.createElement(Ie.a,null))),a.a.createElement(h.a,{className:"box-top",display:"flex",justifyContent:"space-between",alignItems:"center"},a.a.createElement(h.a,{className:"box-input-search-filter",display:"flex",justifyItems:"center",style:T?{width:"100%"}:void 0},a.a.createElement(h.a,{className:"icon-search",style:{marginRight:11},display:"flex",justifyContent:"center",alignItems:"center"},a.a.createElement("img",{style:{maxWidth:"fit-content"},src:$n.a,alt:"",width:18,height:18})),a.a.createElement("input",{className:"input-search-filter",placeholder:"Search",onChange:function(e){B(e.target.value)}}))),!Object(He.isEmpty)(j)&&H>0&&a.a.createElement(h.a,{style:{padding:"10px 16px 10px 16px",display:"flex",justifyContent:"space-between",backgroundColor:"#FAFAFA"}},a.a.createElement(h.a,{style:{display:"flex",flexWrap:"wrap",rowGap:"8px",columnGap:"8px",alignItems:"baseline",fontSize:"12px",marginBottom:"4px"}},Object.keys(j).map((function(e,t){return j[e]?a.a.createElement(h.a,{key:t,className:"box-keyFilter",style:{display:"flex",height:"fit-content",gap:"8px"}},a.a.createElement(On.a,{className:"keyFilter"},e),a.a.createElement(Ce.a,{style:{padding:0},onClick:function(){return L(Object(f.a)(Object(f.a)({},j),{},Object(gn.a)({},e,!1)))}},a.a.createElement(Ie.a,{style:{fontSize:12,color:"#2B2C46"}}))):a.a.createElement(a.a.Fragment,null)})),a.a.createElement("p",{style:{fontWeight:"bold",color:"#000"}},"".concat(H,"/").concat(10)),a.a.createElement(h.a,{style:{color:"#E31B5D",fontSize:"12px",cursor:"pointer",marginLeft:"12px"},onClick:function(){L({})}},"Clear all"))),a.a.createElement(h.a,{className:"box-bottom",height:"100%",style:T?{columnCount:1,marginBottom:j?"50px":"0px"}:_<=4?{columnCount:_,height:"100%",padding:"24px 24px 40px 24px",backgroundColor:"#FAFAFA"}:{columnCount:4,padding:"24px 24px 40px 24px",backgroundColor:"#FAFAFA"}},Object.entries(g).map((function(e,t){var n=Object(p.a)(e,2),r=n[0],o=n[1];return a.a.createElement(h.a,{className:"box-group-items",key:r},a.a.createElement(h.a,{style:{display:"flex",flexDirection:"column",rowGap:"12px",width:"100%"}},a.a.createElement(On.a,{style:{fontWeight:"bold",color:"#000",fontSize:"12px"}},r),o.map((function(e,t){return a.a.createElement(Jn.a,{key:e,title:e,placement:"top",arrow:!0,disableHoverListener:e.length<35},a.a.createElement(h.a,{"aria-label":e,style:{cursor:"pointer",fontSize:"12px",minHeight:"20px",color:"#2B2C46",width:"100%",maxWidth:"fit-content",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",backgroundColor:j[e]?"#E9E9EC":"",borderRadius:8,paddingLeft:"8px",paddingRight:"8px"},onClick:function(){H<10&&L(Object(f.a)(Object(f.a)({},j),{},Object(gn.a)({},e,!j[e])))}},ar(e,35)))}))))})),R&&a.a.createElement(h.a,{style:{columnCount:T?1:4}},Array(12).fill("").map((function(e,t){return a.a.createElement(h.a,{key:t,mb:5},a.a.createElement(rr.a,{animation:"pulse",height:30,width:60}),Array(6).fill("").map((function(e,t){return a.a.createElement(rr.a,{key:t,animation:"pulse",height:30})})))}))),Object(He.isEmpty)(g)&&!R&&a.a.createElement(On.a,null,"No result found")),!T&&a.a.createElement(h.a,{className:"footer",style:{height:64,marginTop:"auto"},display:"flex"},a.a.createElement(Ce.a,{className:"button-left",style:{width:"50%",height:"64px",backgroundColor:"#2B2C46",color:"#fff",borderRadius:0,justifyContent:"flex-start",textTransform:"none",paddingLeft:"16px"},onClick:function(){return o()}},"Cancel"),a.a.createElement(Ce.a,{className:"button-right",style:{width:"50%",backgroundColor:null===(t=c.theme)||void 0===t?void 0:t.primaryColor,color:"#fff",borderRadius:0,justifyContent:"flex-start",textTransform:"none",paddingLeft:"16px"},onClick:function(){return A()}},"Apply")),T&&a.a.createElement(h.a,{className:"footer",style:{height:64,marginTop:"auto",position:"fixed",bottom:"0px",left:"0px",width:"100vw"},display:"flex"},a.a.createElement(Ce.a,{className:"button-left",style:{width:"50%",backgroundColor:"#000000",color:"#fff",borderRadius:0,justifyContent:"flex-start"},onClick:function(){return o()}},"Cancel"),a.a.createElement(Ce.a,{className:"button-right",style:{width:"50%",backgroundColor:null===(n=c.theme)||void 0===n?void 0:n.primaryColor,color:"#fff",borderRadius:0,justifyContent:"flex-start"},onClick:function(){return A()}},"Apply")))};var lr=function(e){var t=e.children,n=xe(),o=we((function(e){return e})).search,i=o.preFilterDropdown,l=o.imageCaptureHelpModal,c=Object(r.useState)(!1),u=Object(p.a)(c,2),s=u[0],f=u[1];return a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"wrap-mobile"},a.a.createElement("div",{className:"box-header-mobile-main"},a.a.createElement(Xt,{onToggleFilterMobile:function(e){f(Object(He.isUndefined)(e)?!s:e)}})),a.a.createElement("div",{style:{display:"flex",flexGrow:1,flexDirection:"column",overflowY:"auto",overflowX:"hidden",height:"100%",backgroundColor:"#fff"}},t),a.a.createElement("div",{className:"footer-wrap-main",style:{zIndex:999}},a.a.createElement(Rt,null))),a.a.createElement(h.a,{className:"box-filter ".concat(s?"open":"close"," "),position:"absolute",style:{top:"0px",height:"100%",width:"100%"}},a.a.createElement(Qn,{onApply:function(){f(!s)}})),i&&a.a.createElement(h.a,{className:"box-filter open",position:"absolute",style:{top:"0px",height:"100%",width:"100%",zIndex:999}},a.a.createElement("div",{style:{width:"100%"},className:"wrap-filter-desktop"},a.a.createElement("div",{className:"bg-white box-filter-desktop isMobile"},a.a.createElement(ir,{handleClose:function(){return n(re(!i))}})))),l&&a.a.createElement(h.a,{className:"box-filter open",position:"absolute",style:{top:"0px",width:"100%",zIndex:100}},a.a.createElement("div",{style:{width:"100%"},className:"wrap-filter-desktop"},a.a.createElement("div",{className:"bg-white box-filter-desktop isMobile"},a.a.createElement(hn,{handleClose:function(){return n(ee(!l))}})))))},cr=n(492),ur=n.n(cr),sr=function(){return a.a.createElement("svg",{width:150,height:150,viewBox:"0 0 150 150",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"loading-spinner"},a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M75 150C116.421 150 150 116.421 150 75C150 33.5786 116.421 0 75 0C33.5786 0 0 33.5786 0 75C0 116.421 33.5786 150 75 150ZM75 140.367C111.101 140.367 140.367 111.101 140.367 75.0003C140.367 38.8991 111.101 9.63332 75 9.63332C38.8988 9.63332 9.63304 38.8991 9.63304 75.0003C9.63304 111.101 38.8988 140.367 75 140.367Z",fill:"url(#paint0_linear_2236_26778)"}),a.a.createElement("defs",null,a.a.createElement("linearGradient",{id:"paint0_linear_2236_26778",x1:75,y1:0,x2:75,y2:150,gradientUnits:"userSpaceOnUse"},a.a.createElement("stop",{stopColor:"#3E36DC"}),a.a.createElement("stop",{offset:.916667,stopColor:"#1E1F31"}))))},fr=function(){var e=Object(Qt.b)().t;return a.a.createElement(h.a,{className:"loadingSpinCT",style:{top:0,bottom:0,display:"flex",justifyContent:"center",alignItems:"center"}},a.a.createElement("p",{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",fontSize:16,color:"#fff",fontWeight:300}},e("loading")),a.a.createElement(sr,null))},dr=n(335),pr=n(275),hr=n.n(pr),mr=n(927);var gr,vr,yr=Object(r.memo)((function(e){var t,n=e.children,o=xe(),i=we((function(e){return e})),l=i.settings,c=i.search.valueTextSearch,u=l.algolia,s=u.apiKey,d=u.appId,p=u.indexName,h=null===(t=l.algolia)||void 0===t?void 0:t.enabled,m=Object(r.useMemo)((function(){var e=hr()(d,s);return e.initIndex(p),Object(f.a)(Object(f.a)({},e),{},{search:function(t){return t.every((function(e){var t,n,r;return!(null===(t=e.params)||void 0===t?void 0:t.query)&&(!(null===(n=e.params)||void 0===n?void 0:n.filters)||(null===(r=e.params)||void 0===r?void 0:r.filters.endsWith("<score=1>")))}))?Promise.resolve({results:t.map((function(){return{hits:[],nbHits:0,nbPages:0,processingTimeMS:0}}))}):h?e.search(t):void 0}})}),[s,d,p,h]);return a.a.createElement("div",{style:{position:"relative"}},a.a.createElement(mr.a,{indexName:p,searchClient:m,searchState:h?c:{},onSearchStateChange:function(e){e.page&&void 0!==e.query&&h&&o(U(e))}},n))})),br=["svgRef","title"];function xr(){return(xr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function wr(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Cr=function(e){var t=e.svgRef,n=e.title,r=wr(e,br);return a.a.createElement("svg",xr({width:80,height:10,viewBox:"0 0 80 10",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,gr||(gr=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M53.4951 2.66941V7.62941H54.9651V4.27941C55.1251 4.12608 55.2718 4.00941 55.4051 3.92941C55.5384 3.84275 55.6984 3.79941 55.8851 3.79941C56.0984 3.79941 56.2518 3.86608 56.3451 3.99941C56.4451 4.13275 56.4951 4.37941 56.4951 4.73941V7.62941H57.9651V4.54941C57.9651 3.92941 57.8451 3.44275 57.6051 3.08941C57.3651 2.72941 56.9718 2.54941 56.4251 2.54941C56.0918 2.54941 55.7951 2.62275 55.5351 2.76941C55.2751 2.91608 55.0418 3.09275 54.8351 3.29941H54.7951L54.6951 2.66941H53.4951ZM59.3778 9.53941C59.4911 9.55941 59.6211 9.56941 59.7677 9.56941C60.1611 9.56941 60.4877 9.49608 60.7477 9.34941C61.0144 9.20941 61.2378 8.99941 61.4177 8.71941C61.6044 8.43941 61.7777 8.09275 61.9377 7.67941L63.6577 2.66941H62.2477L61.6478 4.79941C61.5877 5.03275 61.5277 5.26941 61.4678 5.50941L61.3078 6.20941H61.2677C61.2011 5.96275 61.1377 5.72275 61.0777 5.48941C61.0177 5.25608 60.9511 5.02608 60.8778 4.79941L60.1677 2.66941H58.6877L60.5977 7.49941L60.5277 7.75941C60.4678 7.94608 60.3677 8.09941 60.2277 8.21941C60.0944 8.34608 59.9044 8.40941 59.6577 8.40941C59.6111 8.40941 59.5611 8.40608 59.5077 8.39942C59.4611 8.39942 59.4011 8.38941 59.3277 8.36941L59.0677 9.44941C59.1677 9.48941 59.2711 9.51941 59.3778 9.53941ZM64.4326 2.66941V7.62941H65.9026V4.74941C66.0359 4.40941 66.2026 4.17275 66.4026 4.03941C66.6093 3.90608 66.8059 3.83941 66.9926 3.83941C67.0993 3.83941 67.1893 3.84608 67.2626 3.85941C67.3359 3.86608 67.4126 3.87941 67.4926 3.89941L67.7726 2.64941C67.7059 2.61608 67.6259 2.59275 67.5326 2.57941C67.4393 2.55941 67.3226 2.54941 67.1826 2.54941C66.9226 2.54941 66.6659 2.63275 66.4126 2.79941C66.1659 2.95941 65.9526 3.20608 65.7726 3.53941H65.7326L65.6326 2.66941H64.4326ZM68.417 2.66941V7.62941H69.887V2.66941H68.417ZM68.547 1.72941C68.7003 1.86941 68.9003 1.93941 69.147 1.93941C69.3936 1.93941 69.5936 1.86941 69.747 1.72941C69.9003 1.58941 69.977 1.40275 69.977 1.16941C69.977 0.936081 69.9003 0.749414 69.747 0.609414C69.5936 0.469414 69.3936 0.399414 69.147 0.399414C68.9003 0.399414 68.7003 0.469414 68.547 0.609414C68.3936 0.749414 68.317 0.936081 68.317 1.16941C68.317 1.40275 68.3936 1.58941 68.547 1.72941ZM71.6306 7.55941C71.9773 7.68608 72.314 7.74941 72.6406 7.74941C73.0873 7.74941 73.4606 7.67941 73.7606 7.53941C74.0606 7.39275 74.2873 7.19941 74.4406 6.95941C74.6006 6.71941 74.6806 6.44941 74.6806 6.14941C74.6806 5.87608 74.6206 5.64275 74.5006 5.44941C74.3806 5.25608 74.214 5.09608 74.0006 4.96941C73.794 4.83608 73.564 4.72608 73.3106 4.63941C73.104 4.57275 72.9306 4.51275 72.7906 4.45941C72.6573 4.39941 72.5573 4.33608 72.4906 4.26941C72.424 4.20275 72.3906 4.12275 72.3906 4.02941C72.3906 3.91608 72.4373 3.82275 72.5306 3.74941C72.624 3.67608 72.7673 3.63941 72.9606 3.63941C73.134 3.63941 73.3106 3.66941 73.4906 3.72941C73.6706 3.78275 73.8506 3.87275 74.0306 3.99941L74.6606 3.17941C74.4473 2.99275 74.1906 2.84275 73.8906 2.72941C73.5973 2.60941 73.2706 2.54941 72.9106 2.54941C72.344 2.54941 71.884 2.69275 71.5306 2.97941C71.184 3.25941 71.0106 3.63275 71.0106 4.09941C71.0106 4.35941 71.0706 4.58275 71.1906 4.76941C71.3173 4.95608 71.4806 5.11608 71.6806 5.24941C71.8806 5.38275 72.1006 5.49275 72.3406 5.57941C72.5206 5.64608 72.6806 5.70941 72.8206 5.76941C72.9673 5.82275 73.084 5.88608 73.1706 5.95941C73.264 6.03275 73.3106 6.12608 73.3106 6.23941C73.3106 6.36608 73.2606 6.46941 73.1606 6.54941C73.0606 6.62275 72.9006 6.65941 72.6806 6.65941C72.474 6.65941 72.2573 6.62608 72.0306 6.55941C71.8106 6.48608 71.5873 6.35941 71.3606 6.17941L70.7406 7.00941C70.9873 7.24941 71.284 7.43275 71.6306 7.55941ZM76.2742 4.25941C76.5742 4.43275 76.9076 4.51941 77.2742 4.51941C77.6342 4.51941 77.9642 4.43275 78.2642 4.25941C78.5709 4.08608 78.8109 3.84941 78.9842 3.54941C79.1642 3.24275 79.2542 2.89275 79.2542 2.49941C79.2542 2.10608 79.1642 1.75941 78.9842 1.45941C78.8109 1.15275 78.5709 0.912748 78.2642 0.739414C77.9642 0.566081 77.6342 0.479414 77.2742 0.479414C76.9076 0.479414 76.5742 0.566081 76.2742 0.739414C75.9742 0.912748 75.7342 1.15275 75.5542 1.45941C75.3742 1.75941 75.2842 2.10608 75.2842 2.49941C75.2842 2.89275 75.3742 3.24275 75.5542 3.54941C75.7342 3.84941 75.9742 4.08608 76.2742 4.25941ZM78.0142 3.83941C77.8009 3.96608 77.5542 4.02941 77.2742 4.02941C76.9942 4.02941 76.7442 3.96608 76.5242 3.83941C76.3109 3.71275 76.1409 3.53608 76.0142 3.30941C75.8942 3.07608 75.8342 2.80608 75.8342 2.49941C75.8342 2.19275 75.8942 1.92608 76.0142 1.69941C76.1409 1.46608 76.3109 1.28608 76.5242 1.15941C76.7442 1.03275 76.9942 0.969414 77.2742 0.969414C77.5542 0.969414 77.8009 1.03275 78.0142 1.15941C78.2276 1.28608 78.3942 1.46608 78.5142 1.69941C78.6409 1.92608 78.7042 2.19275 78.7042 2.49941C78.7042 2.80608 78.6409 3.07608 78.5142 3.30941C78.3942 3.53608 78.2276 3.71275 78.0142 3.83941ZM76.4642 1.49941V3.46941H77.0342V2.86941H77.3242L77.6242 3.46941H78.2242L77.8142 2.69941C77.9342 2.64608 78.0209 2.56941 78.0742 2.46941C78.1342 2.36941 78.1642 2.26608 78.1642 2.15941C78.1642 1.93275 78.0876 1.76608 77.9342 1.65941C77.7809 1.55275 77.5876 1.49941 77.3542 1.49941H76.4642ZM77.2442 2.46941H77.0342V1.92941H77.2442C77.3442 1.92941 77.4176 1.95608 77.4642 2.00941C77.5176 2.05608 77.5442 2.11608 77.5442 2.18941C77.5442 2.26941 77.5176 2.33608 77.4642 2.38941C77.4176 2.44275 77.3442 2.46941 77.2442 2.46941ZM0.745093 1.06941V7.62941H1.57509V5.02941H2.65509C3.13509 5.02941 3.55509 4.95608 3.91509 4.80941C4.28176 4.65608 4.56509 4.43275 4.76509 4.13941C4.97176 3.83941 5.07509 3.45941 5.07509 2.99941C5.07509 2.51941 4.97176 2.13941 4.76509 1.85941C4.55843 1.57941 4.27176 1.37941 3.90509 1.25941C3.53843 1.13275 3.10843 1.06941 2.61509 1.06941H0.745093ZM2.55509 4.34941H1.57509V1.73941H2.51509C3.08843 1.73941 3.51843 1.83275 3.80509 2.01941C4.09843 2.19941 4.24509 2.52608 4.24509 2.99941C4.24509 3.45941 4.10509 3.79941 3.82509 4.01941C3.55176 4.23941 3.12843 4.34941 2.55509 4.34941ZM6.86501 7.44941C7.21168 7.64941 7.58168 7.74941 7.97501 7.74941C8.37501 7.74941 8.74502 7.64941 9.08502 7.44941C9.42501 7.24941 9.69835 6.95941 9.90501 6.57941C10.1183 6.19941 10.225 5.74275 10.225 5.20941C10.225 4.66275 10.1183 4.19941 9.90501 3.81941C9.69835 3.43941 9.42501 3.14941 9.08502 2.94941C8.74502 2.74941 8.37501 2.64941 7.97501 2.64941C7.58168 2.64941 7.21168 2.74941 6.86501 2.94941C6.52501 3.14941 6.24835 3.43941 6.03501 3.81941C5.82835 4.19941 5.72501 4.66275 5.72501 5.20941C5.72501 5.74275 5.82835 6.19941 6.03501 6.57941C6.24835 6.95941 6.52501 7.24941 6.86501 7.44941ZM8.71501 6.83941C8.50168 6.99275 8.25501 7.06941 7.97501 7.06941C7.69501 7.06941 7.44835 6.99275 7.23501 6.83941C7.02835 6.67941 6.86501 6.45941 6.74501 6.17941C6.63168 5.89941 6.57501 5.57608 6.57501 5.20941C6.57501 4.83608 6.63168 4.50941 6.74501 4.22941C6.86501 3.94275 7.02835 3.72275 7.23501 3.56941C7.44835 3.40941 7.69501 3.32941 7.97501 3.32941C8.25501 3.32941 8.50168 3.40941 8.71501 3.56941C8.92835 3.72275 9.09168 3.94275 9.20502 4.22941C9.31835 4.50941 9.37502 4.83608 9.37502 5.20941C9.37502 5.57608 9.31835 5.89941 9.20502 6.17941C9.09168 6.45941 8.92835 6.67941 8.71501 6.83941ZM10.8859 2.76941L12.2359 7.62941H13.2559L13.9059 5.02941C13.9659 4.80941 14.0192 4.58608 14.0659 4.35941C14.1192 4.13275 14.1692 3.87608 14.2159 3.58941H14.2559C14.3092 3.87608 14.3592 4.13275 14.4059 4.35941C14.4592 4.57941 14.5125 4.80275 14.5659 5.02941L15.2159 7.62941H16.2859L17.5959 2.76941H16.7959L16.0859 5.57941L15.9459 6.23941C15.8992 6.45941 15.8492 6.69941 15.7959 6.95941H15.7559C15.7025 6.69941 15.6492 6.45941 15.5959 6.23941C15.5492 6.01941 15.4959 5.79941 15.4359 5.57941L14.7059 2.76941H13.8059L13.0859 5.57941L12.9259 6.23941C12.8792 6.45941 12.8292 6.69941 12.7759 6.95941H12.7359C12.6959 6.69941 12.6525 6.45941 12.6059 6.23941C12.5592 6.01941 12.5092 5.79941 12.4559 5.57941L11.7459 2.76941H10.8859ZM19.3943 7.44941C19.7543 7.64941 20.151 7.74941 20.5843 7.74941C20.9176 7.74941 21.2143 7.70275 21.4743 7.60941C21.741 7.51608 21.981 7.39608 22.1943 7.24941L21.8943 6.70941C21.7276 6.82275 21.541 6.91275 21.3343 6.97941C21.1343 7.04608 20.9176 7.07941 20.6843 7.07941C20.391 7.07941 20.121 7.00941 19.8743 6.86941C19.6276 6.72275 19.431 6.50941 19.2843 6.22941C19.1711 6.003 19.1037 5.733 19.082 5.41941H22.3343C22.3543 5.33941 22.3643 5.25941 22.3643 5.17941C22.371 5.09941 22.3743 5.01608 22.3743 4.92941C22.3743 4.46941 22.301 4.06941 22.1543 3.72941C22.0076 3.38941 21.7876 3.12608 21.4943 2.93941C21.2076 2.74608 20.8576 2.64941 20.4443 2.64941C20.071 2.64941 19.7176 2.75275 19.3843 2.95941C19.051 3.16608 18.7776 3.45941 18.5643 3.83941C18.351 4.21941 18.2443 4.67275 18.2443 5.19941C18.2443 5.73941 18.3476 6.19941 18.5543 6.57941C18.761 6.95275 19.041 7.24275 19.3943 7.44941ZM21.6343 4.76941H19.0962C19.1257 4.50574 19.185 4.28241 19.2743 4.09941C19.4143 3.82608 19.591 3.62941 19.8043 3.50941C20.0176 3.38275 20.2343 3.31941 20.4543 3.31941C20.8343 3.31941 21.1243 3.44608 21.3243 3.69941C21.531 3.94608 21.6343 4.30275 21.6343 4.76941ZM23.5752 2.76941V7.62941H24.3952V4.50941C24.5619 4.09608 24.7552 3.80608 24.9752 3.63941C25.2019 3.47275 25.4186 3.38941 25.6252 3.38941C25.7252 3.38941 25.8052 3.39608 25.8652 3.40941C25.9319 3.41608 26.0019 3.42941 26.0752 3.44941L26.2552 2.74941C26.1752 2.70941 26.0952 2.68275 26.0152 2.66941C25.9352 2.65608 25.8419 2.64941 25.7352 2.64941C25.4552 2.64941 25.1952 2.73941 24.9552 2.91941C24.7153 3.09941 24.5152 3.34275 24.3552 3.64941H24.3252L24.2552 2.76941H23.5752ZM27.7244 7.44941C28.0844 7.64941 28.4811 7.74941 28.9144 7.74941C29.2477 7.74941 29.5444 7.70275 29.8044 7.60941C30.0711 7.51608 30.3111 7.39608 30.5244 7.24941L30.2244 6.70941C30.0577 6.82275 29.8711 6.91275 29.6644 6.97941C29.4644 7.04608 29.2477 7.07941 29.0144 7.07941C28.7211 7.07941 28.4511 7.00941 28.2044 6.86941C27.9577 6.72275 27.7611 6.50941 27.6144 6.22941C27.5012 6.003 27.4337 5.733 27.4121 5.41941H30.6644C30.6844 5.33941 30.6944 5.25941 30.6944 5.17941C30.7011 5.09941 30.7044 5.01608 30.7044 4.92941C30.7044 4.46941 30.6311 4.06941 30.4844 3.72941C30.3377 3.38941 30.1177 3.12608 29.8244 2.93941C29.5377 2.74608 29.1877 2.64941 28.7744 2.64941C28.4011 2.64941 28.0477 2.75275 27.7144 2.95941C27.3811 3.16608 27.1077 3.45941 26.8944 3.83941C26.6811 4.21941 26.5744 4.67275 26.5744 5.19941C26.5744 5.73941 26.6777 6.19941 26.8844 6.57941C27.0911 6.95275 27.3711 7.24275 27.7244 7.44941ZM29.9644 4.76941H27.4262C27.4557 4.50574 27.5151 4.28241 27.6044 4.09941C27.7444 3.82608 27.9211 3.62941 28.1344 3.50941C28.3477 3.38275 28.5644 3.31941 28.7844 3.31941C29.1644 3.31941 29.4544 3.44608 29.6544 3.69941C29.8611 3.94608 29.9644 4.30275 29.9644 4.76941ZM32.0953 7.08941C32.462 7.52941 32.952 7.74941 33.5653 7.74941C33.852 7.74941 34.122 7.68275 34.3753 7.54941C34.6287 7.40941 34.8487 7.24608 35.0353 7.05941H35.0653L35.1353 7.62941H35.8153V0.509414H34.9853V2.37941L35.0253 3.20941C34.812 3.02941 34.602 2.89275 34.3953 2.79941C34.1953 2.69941 33.952 2.64941 33.6653 2.64941C33.292 2.64941 32.9453 2.75275 32.6253 2.95941C32.3053 3.16608 32.0453 3.46275 31.8453 3.84941C31.652 4.22941 31.5553 4.68275 31.5553 5.20941C31.5553 6.01608 31.7353 6.64275 32.0953 7.08941ZM34.3853 6.88941C34.1853 7.00275 33.972 7.05941 33.7453 7.05941C33.3187 7.05941 32.9887 6.89608 32.7553 6.56941C32.522 6.23608 32.4053 5.77941 32.4053 5.19941C32.4053 4.82608 32.4687 4.50275 32.5953 4.22941C32.722 3.94941 32.8887 3.73275 33.0953 3.57941C33.3087 3.41941 33.5453 3.33941 33.8053 3.33941C34.0053 3.33941 34.202 3.37941 34.3953 3.45941C34.5887 3.53275 34.7853 3.66275 34.9853 3.84941V6.38941C34.7853 6.60941 34.5853 6.77608 34.3853 6.88941ZM40.9042 7.58941C41.1442 7.69608 41.3775 7.74941 41.6042 7.74941C41.9708 7.74941 42.3142 7.64608 42.6342 7.43941C42.9542 7.23275 43.2108 6.93275 43.4042 6.53941C43.6042 6.14608 43.7042 5.67275 43.7042 5.11941C43.7042 4.61941 43.6308 4.18608 43.4842 3.81941C43.3375 3.44608 43.1208 3.15941 42.8342 2.95941C42.5475 2.75275 42.1942 2.64941 41.7742 2.64941C41.5075 2.64941 41.2408 2.71608 40.9742 2.84941C40.7142 2.97608 40.4742 3.13608 40.2542 3.32941L40.2742 2.44941V0.509414H39.4542V7.62941H40.1142L40.1842 7.12941H40.2142C40.4342 7.32275 40.6642 7.47608 40.9042 7.58941ZM42.1742 6.82941C41.9675 6.98275 41.7308 7.05941 41.4642 7.05941C41.3042 7.05941 41.1175 7.02275 40.9042 6.94941C40.6975 6.86941 40.4875 6.73608 40.2742 6.54941V3.99941C40.5075 3.77941 40.7308 3.61608 40.9442 3.50941C41.1642 3.39608 41.3742 3.33941 41.5742 3.33941C41.8808 3.33941 42.1275 3.41608 42.3142 3.56941C42.5008 3.71608 42.6375 3.92608 42.7242 4.19941C42.8108 4.46608 42.8542 4.77608 42.8542 5.12941C42.8542 5.52941 42.7942 5.87608 42.6742 6.16941C42.5542 6.45608 42.3875 6.67608 42.1742 6.82941ZM44.7124 9.68941C44.8124 9.70941 44.9158 9.71941 45.0224 9.71941C45.3491 9.71941 45.6258 9.64608 45.8524 9.49941C46.0791 9.35275 46.2724 9.14942 46.4324 8.88941C46.5924 8.63608 46.7291 8.34941 46.8424 8.02941L48.6724 2.76941H47.8724L47.0024 5.45941C46.9424 5.67275 46.8758 5.89941 46.8024 6.13941C46.7358 6.37275 46.6658 6.60275 46.5924 6.82941H46.5524C46.4791 6.60275 46.4024 6.36941 46.3224 6.12941C46.2424 5.88941 46.1624 5.66608 46.0824 5.45941L45.0924 2.76941H44.2424L46.1924 7.63941L46.0824 7.99941C45.9824 8.29941 45.8424 8.54608 45.6624 8.73941C45.4891 8.93941 45.2624 9.03941 44.9824 9.03941C44.9291 9.03941 44.8724 9.03275 44.8124 9.01941C44.7524 9.01275 44.6924 8.99941 44.6324 8.97941L44.4524 9.61941C44.5324 9.64608 44.6191 9.66941 44.7124 9.68941Z",fill:"url(#paint0_linear_5277_64421)"})),vr||(vr=a.a.createElement("defs",null,a.a.createElement("linearGradient",{id:"paint0_linear_5277_64421",x1:53,y1:12.0596,x2:80,y2:12.0596,gradientUnits:"userSpaceOnUse"},a.a.createElement("stop",{stopColor:"#3E36DC"}),a.a.createElement("stop",{offset:1,stopColor:"#E31B5D"})))))},Er=a.a.forwardRef((function(e,t){return a.a.createElement(Cr,xr({svgRef:t},e))}));n.p;var Or=function(){var e=Object(r.useState)(!1),t=Object(p.a)(e,2),n=t[0],o=t[1];return a.a.createElement("div",{className:"powered-by-nyris",style:{display:"flex",padding:"9px 0px",justifyContent:"center",borderTop:"1px solid #E0E0E0"},onMouseOver:function(){o(!0)},onMouseOut:function(){o(!1)}},n&&a.a.createElement(Er,{style:{cursor:"pointer"},onClick:function(){window.open("https://www.nyris.io","_blank")}}),!n&&a.a.createElement(Ot,{style:{cursor:"pointer"},onClick:function(){window.open("https://www.nyris.io","_blank")},color:"#2B2C46"}))};function jr(){jr=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}ur()(document).ready((function(){psol.core.setUserInfo({server_type:"oem_apps_cadenas_webcomponentsdemo",title:"Herr",firstname:"Max",lastname:"Mustermann",userfirm:"CADENAS GmbH",street:"Berliner Allee 28 b+c",zip:"86153",city:"Augsburg",country:"de",phone:"+49 (0) 821 2 58 58 0-0",fax:"+49 (0) 821 2 58 58 0-999",email:"info@cadenas.de"}),psol.core.setServiceBaseUrl("https://webapi.partcommunity.com"),window.onpageshow=function(e){e.persisted&&window.location.reload()}})),dr.a.use(Qt.a).init({resources:{en:{translation:{Search:"Search","Drag and drop":"Drag and drop","an image here":"an image here","Manufacturer Number":"Manufacturer No.","Mfr. No.":"Mfr. No.","Close group":"Close group","Show group":"Show group","Adjust the search frame around your object for improved results":"Adjust the search frame around your object for improved results","Crop the image for better results":"Crop the image for better results","Items per page":"Items per page","Search with an image":"Search with an image","Clear text search":"Clear text search","View details":"View details","Clear image search":"Clear image search ","Add or change pre-filter":"Add or change pre-filter","Expand all":"Expand all","Collapse all":"Collapse all",Brand:"Brand",loading:"loading","No products were found matching your search criteria.":"No products were found matching your search criteria.","Please upload an image or enter a keyword to search.":"Please upload an image or enter a keyword to search."}},de:{translation:{Search:"Suche","Drag and drop":"Bild hierher ziehen","an image here":"","Mfr. No.":"Herst. Teile-Nr.","Manufacturer Number":"Herstellerteilenummer","Close group":"Schlie\xdfe Gruppe","Show group":"Zeige Gruppe","Adjust the search frame around your object for improved results":"Anpassen des Rahmens f\xfcr bessere Ergebnisse","Crop the image for better results":"Zuschneiden f\xfcr bessere Ergebnisse","Items per page":"Artikel pro Seite","Search with an image":"Bildsuche","Clear text search":"Suchtext l\xf6schen","View details":"Details anzeigen","Clear image search":"Bildsuche zur\xfcck setzen","Add or change pre-filter":"Vorfilter hinzuf\xfcgen oder \xe4ndern","Expand all":"Alles anzeigen","Collapse all":"Alles einklappen",Brand:"Marke",loading:"L\xe4dt","No products were found matching your search criteria.":"Keine Produkte entsprechen Ihren Suchkriterien.","Please upload an image or enter a keyword to search.":"F\xfcr die Suche bitte Bild hochladen oder Stichwort eingeben."}},pt:{translation:{Search:"Busca","Drag and drop":"Escolha uma imagem","an image here":"","Manufacturer Number":"N\xfamero do fabricante","Mfr. No.":"Nr. do Fab","Close group":"Fechar grupo","Show group":"Mostrar grupo","Adjust the search frame around your object for improved results":"Ajuste a caixa de busca para melhores resultados","Crop the image for better results":"Ajuste o campo de imagem para melhores resultados","Items per page":"Itens por p\xe1gina","Search with an image":"Busque com uma imagem","Clear text search":"Limpar busca","View details":"Ver detalhes","Clear image search":"Limpar imagem","Add or change pre-filter":"Adicionar ou selecionar pre-filtro","Expand all":"Expandir","Collapse all":"esconder tudo",Brand:"Marca",loading:"Carregando","No products were found matching your search criteria.":"Nenhum produto foi encontrado com estes crit\xe9rios ","Please upload an image or enter a keyword to search.":"Fa\xe7a o upload de uma imagem ou busque via texto"}}},fallbackLng:"en",interpolation:{escapeValue:!1},returnNull:!1});var Lr,kr=Object(r.memo)((function(e){var t,n,o,i,l,c=e.children,u=xe(),g=we((function(e){return e})),v=g.settings,y=g.search.loadingSearchAlgolia,b=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),x=Object(r.useState)(!1),w=Object(p.a)(x,2),C=w[0],E=w[1],O=Object(s.f)(),j=b&&"/result"===(null===(t=O.location)||void 0===t?void 0:t.pathname)||"/"===(null===(n=O.location)||void 0===n?void 0:n.pathname),L=we((function(e){return e.settings.language})),k=Object(jt.b)().isAuthenticated,S=v.auth0,R=v.showPoweredByNyris,N=!S.enabled||S.enabled&&k;dr.a.changeLanguage(L),Object(r.useEffect)((function(){(function(){var e=Object(d.a)(jr().mark((function e(){var t;return jr().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,pn(v);case 2:t=e.sent,u(ce(t));case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()().catch(console.log)}),[]),Object(r.useEffect)((function(){var e;"/"===(null===(e=O.location)||void 0===e?void 0:e.pathname)&&(document.title=v.appTitle||"",u(K("")))}),[O.location]);var I="newVersion";b?(I="mobile",l=Rt,i=Xt):i=un;var M=.01*window.innerHeight;return document.documentElement.style.setProperty("--vh","".concat(M,"px")),Object(r.useEffect)((function(){var e=function(){var e=.01*window.innerHeight;document.documentElement.style.setProperty("--vh","".concat(e,"px"))};return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}}),[]),a.a.createElement("div",{style:{position:"relative"}},y&&a.a.createElement(h.a,{className:"box-wrap-loading",style:{zIndex:99999999}},a.a.createElement(fr,null)),a.a.createElement(yr,null,b&&N&&a.a.createElement(lr,null,c),!b&&N&&a.a.createElement("div",{className:"layout-main-".concat(I)},a.a.createElement("div",{className:b?j?"box-header-".concat(I,"-main"):"":"box-header-".concat(I,"-main"),style:Object(f.a)({},"newVersion"===I?{background:null===(o=v.theme)||void 0===o?void 0:o.headerColor}:{})},a.a.createElement(i,{onToggleFilterMobile:function(e){E(Object(He.isUndefined)(e)?!C:e)}})),a.a.createElement("div",{className:"box-body-".concat(I,"-wrap-main")},c),b&&a.a.createElement("div",{className:"footer-wrap-main"},a.a.createElement(l,null)),R&&a.a.createElement(Or,null)),!N&&a.a.createElement(a.a.Fragment,null," ",c)))})),Sr=(n(811),n(812),["svgRef","title"]);function Rr(){return(Rr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Nr(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Ir=function(e){var t=e.svgRef,n=e.title,r=Nr(e,Sr);return a.a.createElement("svg",Rr({width:48,height:48,viewBox:"0 0 48 48",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,Lr||(Lr=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M22.7016 39.816L22.6416 39.7584H22.6392L11.1192 28.2384C10.3704 27.4896 10.3704 26.2728 11.1192 25.524C11.4816 25.1616 11.964 24.9624 12.4776 24.9624C12.9912 24.9624 13.4736 25.1616 13.836 25.524L22.0776 33.7656V1.92C22.0776 0.8616 22.9392 0 23.9976 0C25.056 0 25.9176 0.8616 25.9176 1.92V33.7656L34.1592 25.524C34.5216 25.1616 35.004 24.9624 35.5176 24.9624C36.0312 24.9624 36.5136 25.1616 36.876 25.524C37.6248 26.2728 37.6248 27.4896 36.876 28.2384L25.356 39.7584C25.2672 39.8472 25.1688 39.9288 25.0632 39.9984C25.0176 40.0296 24.9648 40.0584 24.912 40.0848L24.9081 40.0869C24.8472 40.1197 24.7907 40.1501 24.732 40.1736C24.672 40.1976 24.6072 40.2192 24.5448 40.236C24.4872 40.2552 24.432 40.2696 24.3744 40.2816C24.2496 40.308 24.1224 40.32 23.9976 40.32C23.8728 40.32 23.7456 40.3056 23.6208 40.2816C23.5632 40.2696 23.508 40.2552 23.4528 40.236C23.388 40.2192 23.3256 40.2 23.2632 40.1736C23.2032 40.1496 23.148 40.1208 23.0928 40.0896C23.0328 40.0608 22.9824 40.032 22.932 39.9984C22.8504 39.9432 22.7736 39.8808 22.7016 39.816ZM44.16 34.56C44.16 33.5016 45.0216 32.64 46.08 32.64C47.1384 32.64 48 33.5016 48 34.56V46.08C48 47.1384 47.1384 48 46.08 48H1.92C0.8616 48 0 47.1384 0 46.08V34.56C0 33.5016 0.8616 32.64 1.92 32.64C2.9784 32.64 3.84 33.5016 3.84 34.56V44.16H44.16V34.56Z",fill:"currentColor"})))},Mr=a.a.forwardRef((function(e,t){return a.a.createElement(Ir,Rr({svgRef:t},e))}));n.p;function _r(){_r=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var Fr=Object(r.memo)((function(e){var t=Object(s.f)(),n=xe(),r=e.onChangeLoading,o=e.isLoading,i=we((function(e){return e})),l=i.settings,c=i.search.preFilter,u=Object(Qt.b)().t,p=Object(Pe.a)({onDrop:function(){var e=Object(d.a)(_r().mark((function e(a){var o,i,u,s,d,p;return _r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t.push("/result"),n(fe(!0)),n(Y()),r(!0),i=[],console.log("fs",a),n(te(URL.createObjectURL(a[0]))),e.next=9,De(a[0]);case 9:if(u=e.sent,n(oe(u)),s=[{key:l.visualSearchFilterKey,values:Object.keys(c)}],!l.regions){e.next=19;break}return e.next=15,Ze(u,l);case 15:p=e.sent,n(ae(p.regions)),d=p.selectedRegion,n(le(d));case 19:return e.abrupt("return",We({image:u,settings:l,region:d,filters:Object(He.isEmpty)(c)?void 0:s}).then((function(e){null===e||void 0===e||e.results.map((function(e){i.push({sku:e.sku,score:e.score})})),o=Object(f.a)(Object(f.a)({},e),{},{filters:i}),n(ie(o)),r(!1),n(fe(!1))})));case 20:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()}),m=p.getRootProps,g=p.getInputProps,v=p.isDragActive;return a.a.createElement(h.a,{className:"box-content-main",style:{marginTop:32,paddingTop:0}},o&&a.a.createElement(fr,null),a.a.createElement("div",Object.assign({className:"box-border-none",style:{position:"relative"}},m({onClick:function(e){e.stopPropagation()}})),a.a.createElement(a.a.Fragment,null,a.a.createElement(h.a,Object.assign({className:"box-content-drop ".concat(v?"drag-active":"")},m({onClick:function(e){e.stopPropagation()}})),a.a.createElement(h.a,{style:{marginBottom:16}},a.a.createElement(Mr,{width:48,height:48})),a.a.createElement("label",{htmlFor:"select_file",className:"",style:{fontSize:14}},a.a.createElement("span",{className:"fw-700 text-f14",style:{paddingRight:"4px"}},u("Drag and drop")),u("an image here")),a.a.createElement("input",Object.assign({},g(),{type:"file",name:"file",id:"select_file",className:"inputFile",placeholder:"Choose photo",style:{display:"block",cursor:"pointer"}}))))))})),Tr=n(494),Hr=n.n(Tr),Pr=n(493),Br=n.n(Pr);function Ar(){Ar=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var Vr=Object(Ht.a)(Object(r.memo)((function(e){var t,n,o,i,l,c,u=e.refine,g=e.onToggleFilterMobile,v=we((function(e){return e})),y=v.search,b=v.settings,x=y.imageThumbSearchInput,w=y.preFilter,C=y.requestImage,E=y.selectedRegion,O=Object(r.useRef)(null),j=Object(s.f)(),L=Object(r.useState)(""),k=Object(p.a)(L,2),S=k[0],R=k[1],N=xe(),I=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),M=Kt(),_=Object(r.useState)(!1),F=Object(p.a)(_,2),T=F[0],H=F[1],P=Object(Qt.b)().t,B=null===(t=b.algolia)||void 0===t?void 0:t.enabled;Object(r.useEffect)((function(){(null===O||void 0===O?void 0:O.current)&&(null===O||void 0===O||O.current.focus())}),[O]),Object(r.useEffect)((function(){var e=M.get("query")||"";Object(He.isEmpty)(e)||(R(e),N(ue(e)),B&&(u(e),setTimeout((function(){u(e)}),100)))}),[M,u,N,B]),Object(r.useEffect)((function(){x&&(R(""),B&&u(""),j.push("/result"))}),[x,B]);var A=Object(r.useCallback)(Object(He.debounce)((function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!B){var n;N(ue(e));var r=[],a=[{key:b.visualSearchFilterKey,values:Object.keys(w)}];e||C?(N(fe(!0)),We({image:t?null===C||void 0===C?void 0:C.canvas:void 0,settings:b,filters:Object(He.isEmpty)(w)?void 0:a,region:t?E:void 0,text:e}).then((function(e){null===e||void 0===e||e.results.map((function(e){r.push({sku:e.sku,score:e.score})})),n=Object(f.a)(Object(f.a)({},e),{},{filters:r}),N(ie(n)),N(fe(!1))})).catch((function(e){console.log("error input search",e),N(fe(!1))}))):N(ie([]))}e?j.push({pathname:"/result",search:"?query=".concat(e)}):j.push("/result")}),500),[C,w,E,B]),V=Object(Pe.a)({onDrop:function(){var e=Object(d.a)(Ar().mark((function e(t){var n,r,a,o,i,l;return Ar().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t[0]){e.next=2;break}return e.abrupt("return");case 2:return N(fe(!0)),N(Y()),"/result"!==j.location.pathname&&j.push("/result"),r=[],N(te(URL.createObjectURL(t[0]))),e.next=9,De(t[0]);case 9:if(o=e.sent,N(oe(o)),i=[{key:b.visualSearchFilterKey,values:Object.keys(w)}],!b.regions){e.next=19;break}return e.next=15,Ze(o,b);case 15:l=e.sent,N(ae(l.regions)),a=l.selectedRegion,N(le(a));case 19:return e.abrupt("return",We({image:o,settings:b,filters:Object(He.isEmpty)(w)?void 0:i,region:a}).then((function(e){null===e||void 0===e||e.results.map((function(e){r.push({sku:e.sku,score:e.score})})),n=Object(f.a)(Object(f.a)({},e),{},{filters:r}),N(ie(n)),N(fe(!1))})).catch((function(e){console.log("error input search",e),N(fe(!1))})));case 20:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()}).getInputProps;return a.a.createElement("div",{className:"wrap-input-search-field"},a.a.createElement("div",{className:"box-input-search d-flex"},a.a.createElement("form",{noValidate:!0,action:"",role:"search"},a.a.createElement(h.a,{className:"box-inp"},a.a.createElement(Jn.a,{title:Object(He.isEmpty)(w)?P("Add or change pre-filter"):Object.keys(w).join(", "),placement:"top",arrow:!0,disableHoverListener:!b.preFilterOption},a.a.createElement(h.a,{className:"pre-filter-icon",style:{cursor:b.preFilterOption?"pointer":"default"},onClick:function(){return!!b.preFilterOption&&H(!0)}},b.preFilterOption&&a.a.createElement("div",{className:"icon-hover",style:Object(f.a)({},Object(He.isEmpty)(w)?{backgroundColor:"#2B2C46"}:{backgroundColor:"".concat(null===(n=b.theme)||void 0===n?void 0:n.primaryColor)})},a.a.createElement(Tt,{color:"white"})),!b.preFilterOption&&a.a.createElement(Dt,{width:16,height:16}),!Object(He.isEmpty)(w)&&a.a.createElement("div",{style:{position:"absolute",top:"5px",left:"35px",display:"flex",justifyContent:"center",alignItems:"center",background:"white",width:"12px",height:"12px",borderRadius:"100%"}},a.a.createElement("div",{style:{width:"8px",height:"8px",background:null===(o=b.theme)||void 0===o?void 0:o.primaryColor,borderRadius:"100%",strokeWidth:"2px"}})))),a.a.createElement(h.a,{style:{height:"75%",order:1}},x&&a.a.createElement(h.a,{style:{border:"2px solid ".concat(null===(i=b.theme)||void 0===i?void 0:i.primaryColor),backgroundColor:"".concat(null===(l=b.theme)||void 0===l?void 0:l.primaryColor,"26"),marginRight:"5px"},className:"box-image-search-thumb",display:"flex"},a.a.createElement("img",{src:x,style:{objectFit:"contain"},alt:"img_search"}),a.a.createElement(Jn.a,{title:P("Clear image search"),placement:"top",arrow:!0},a.a.createElement("button",{type:"button",onClick:function(){S||(N(J("")),j.push("/")),N(J("")),B?u(S):A(S,!1)}},a.a.createElement(Ie.a,{style:{fontSize:20,color:null===(c=b.theme)||void 0===c?void 0:c.primaryColor}}))))),a.a.createElement("input",{style:{border:"0px",width:"100%",fontSize:14,color:"#2B2C46"},className:"input-search",placeholder:P("Search"),value:S,onChange:function(e){R(e.currentTarget.value),A(e.currentTarget.value),""===e.currentTarget.value&&(R(""),B&&u(""))},ref:O})),"/result"===j.location.pathname&&S&&a.a.createElement(Ce.a,{className:"btn-clear-text",onClick:function(){if(x)return B||A(""),R(""),void(B&&u(""));R(""),B&&u(""),N(J("")),j.push("/")}},a.a.createElement(Jn.a,{title:P("Clear text search"),placement:"top",arrow:!0},a.a.createElement(Hr.a,{style:{fontSize:16,color:"#2B2C46"}}))),I?a.a.createElement(h.a,null,a.a.createElement(Ce.a,{className:"btn-mobile-filter",onClick:g},a.a.createElement(Tt,{width:18,height:18}))):a.a.createElement("div",{className:"wrap-box-input-mobile d-flex"},a.a.createElement("input",Object.assign({accept:"image/*",id:"icon-button-file",type:"file",style:{display:"none"}},V({onClick:function(e){e.stopPropagation()}}))),a.a.createElement(Jn.a,{title:P("Search with an image"),placement:"top",arrow:!0},a.a.createElement("label",{htmlFor:"icon-button-file"},a.a.createElement(Re.a,{color:"primary","aria-label":"upload picture",component:"span",style:{width:32,height:32,borderRadius:"100%",padding:7}},a.a.createElement("img",{src:Br.a,alt:"",width:18,height:18}))))))),b.preFilterOption&&a.a.createElement(kt,{openModal:T,handleClose:function(){return H(!1)},classNameModal:"wrap-filter-desktop",classNameComponentChild:"bg-white box-filter-desktop"},a.a.createElement(ir,{handleClose:function(){return H(!1)}})))}))),Gr=n(916);var zr,Dr=function(){var e=we((function(e){return e})).settings,t=Object(r.useState)(!1),n=Object(p.a)(t,2),o=n[0],i=n[1],l=e.algolia,c=l.apiKey,u=l.appId,s=l.indexName;hr()(u,c).initIndex(s);var f=["image/*"].concat(e.cadSearch?Ve.cadExtensions:[]).join(","),d=Object(Gr.a)((function(e){e.hits;return a.a.createElement("div",null)}));return a.a.createElement(h.a,{className:"box-content-main ".concat(o?"loading":"")},a.a.createElement(h.a,{className:"box-content_top",style:{position:"relative"}},e.headerText&&a.a.createElement(h.a,{className:"fw-700 text-f32 text-dark2",style:{position:"absolute",bottom:"49px"}},a.a.createElement("h1",null,e.headerText)),a.a.createElement("div",{className:"wrap-input-search"},a.a.createElement("div",{style:{display:"none"}},a.a.createElement(d,null)),a.a.createElement(Vr,null))),a.a.createElement(h.a,{className:"box-content_bottom"},a.a.createElement(Fr,{acceptTypes:f,isLoading:o,onChangeLoading:function(e){i(e)}})))},qr=["svgRef","title"];function Zr(){return(Zr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Wr(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Ur=function(e){var t=e.svgRef,n=e.title,r=Wr(e,qr);return a.a.createElement("svg",Zr({width:121,height:96,viewBox:"0 0 121 96",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,a.a.createElement("g",{style:{mixBlendMode:"multiply"}},zr||(zr=a.a.createElement("path",{d:"M81.7314 54.5169C81.7314 66.4489 71.985 76.1561 60.0049 76.1561C48.0248 76.1561 38.2785 66.4489 38.2785 54.5169C38.2785 42.5849 48.0248 32.8777 60.0049 32.8777C71.985 32.8777 81.7314 42.5849 81.7314 54.5169ZM120.005 24.1972V84.8366C120.005 90.4872 115.363 95.1111 109.689 95.1111H10.3215C4.64805 95.1111 0.00549316 90.4878 0.00549316 84.8366V24.1972C0.00549316 18.5466 4.64748 13.9227 10.3215 13.9227H34.2641L37.8838 5.57484C39.3502 2.1909 42.6961 0 46.3964 0H73.6134C77.3137 0 80.6602 2.1909 82.1272 5.57484L85.7469 13.9227H109.69C115.363 13.9227 120.005 18.546 120.005 24.1972H120.005ZM21.6286 26.4758C21.6286 25.1029 20.5011 23.98 19.1227 23.98H12.2151C10.8366 23.98 9.7092 25.1029 9.7092 26.4758V29.8484C9.7092 31.2214 10.8366 32.3443 12.2151 32.3443H19.1227C20.5011 32.3443 21.6286 31.2214 21.6286 29.8484V26.4758ZM92.258 54.5169C92.258 50.1826 91.4044 45.975 89.7215 42.0118C88.0965 38.1861 85.7719 34.7512 82.8116 31.8029C79.8514 28.8545 76.4027 26.5392 72.5615 24.9207C68.5818 23.2441 64.3578 22.3944 60.0061 22.3944C55.6543 22.3944 51.4298 23.2446 47.4506 24.9207C43.6094 26.5392 40.1607 28.8545 37.2005 31.8029C34.2403 34.7512 31.9156 38.1861 30.2906 42.0118C28.6072 45.9756 27.7541 50.1826 27.7541 54.5169C27.7541 58.8512 28.6077 63.0588 30.2906 67.022C31.9156 70.8477 34.2403 74.2825 37.2005 77.2309C40.1607 80.1793 43.6094 82.4946 47.4506 84.113C51.4303 85.7897 55.6543 86.6394 60.0061 86.6394C64.3578 86.6394 68.5824 85.7892 72.5615 84.113C76.4027 82.4946 79.8514 80.1793 82.8116 77.2309C85.7719 74.2825 88.0965 70.8477 89.7215 67.022C91.405 63.0582 92.258 58.8512 92.258 54.5169Z",fill:"currentColor"}))))},Yr=a.a.forwardRef((function(e,t){return a.a.createElement(Ur,Zr({svgRef:t},e))}));n.p;var Kr=function(){var e=xe(),t=Object(r.useState)(!1),n=Object(p.a)(t,2),o=n[0],i=n[1];return Object(r.useEffect)((function(){e(J(""))}),[e]),a.a.createElement("div",{style:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",width:"100%",height:"100%"}},a.a.createElement("div",{className:"take-photo"},a.a.createElement("div",{className:"take-photo-wrapper",style:{background:"linear-gradient(90deg, #55566B 0%, #2B2C46 100%)"}},a.a.createElement("div",{className:"outer",onClick:function(){i(!o)}},a.a.createElement("div",{className:"inner"},a.a.createElement(Yr,{color:"#2B2C46"}))))),a.a.createElement(h.a,{className:"box-screenshot-camera"},a.a.createElement(Ke,{isToggle:o,onToggleModal:function(){i(!o)}})))};var Qr=function(){var e=Object(m.useMediaQuery)({query:"(max-width: 776px)"})?Kr:Dr;return a.a.createElement(e,null)},Jr=n(500),Xr=n.n(Jr),$r=n(501),ea=n.n($r),ta=n(917);var na=Object(Hn.a)(Object(r.memo)((function(e){var t=e.children,n=e.type,o=void 0===n?"native":n,i=e.className,l=e.items,c=e.refine,u=Object(r.useCallback)((function(){return c(l)}),[c,l]),s=we((function(e){return e})).settings;return a.a.createElement(Ce.a,{type:o,disabled:!l.length,className:i,onClick:u,style:{color:s.theme.secondaryColor,fontWeight:"bold",textTransform:"capitalize",padding:0}},t)}),Bn.a)),ra=n(148),aa=n.n(ra),oa=["children","className","selected","closeIcon"];function ia(e){var t=e.children,n=e.className,r=(e.selected,e.closeIcon),o=void 0!==r&&r,i=Object(mn.a)(e,oa);return a.a.createElement(Ce.a,Object.assign({type:"native",className:n},i),t,o&&a.a.createElement(aa.a,{style:{fontSize:"16px",fontWeight:"bold"}}))}Object(Ln.atom)(0);var la=Object(Hn.a)((function(e){var t=e.items,n=e.refine,o=e.className,i=e.statusSwitchButton,l=we((function(e){return e})).settings,c=Object(r.useState)([]),u=Object(p.a)(c,2),s=u[0],f=u[1];Object(r.useEffect)((function(){i&&f(t)}),[t,i]);var d=Object(r.useMemo)((function(){return s.reduce((function(e,t){return[].concat(Object(vn.a)(e),Object(vn.a)(function(e,t){var n,r;switch(t.forEach((function(t){(function(e,t){var n=e.attribute;return(null===n||void 0===n?void 0:n.attributes)?(null===n||void 0===n?void 0:n.attributes[0])===t.attribute:n===t.attribute})(t,e)&&(r=t)})),null===(n=r)||void 0===n?void 0:n.type){case"size":case"list":var a;return(null===e||void 0===e||null===(a=e.items)||void 0===a?void 0:a.map((function(e){var t;return{category:null===(t=r)||void 0===t?void 0:t.header,label:e.label,value:e.value}})))||[];default:return[]}}(t,null===l||void 0===l?void 0:l.refinements)))}),[])}),[l,s]);return d.length?a.a.createElement("div",{className:o,style:{marginBottom:d.length>0?"10px":"0px",marginTop:d.length>0?"16px":"0px"}},a.a.createElement("ul",{className:"flex flex-wrap gap-3"},d.map((function(e){return a.a.createElement(ta.a.li,{key:[e.category,e.label].join(":")},a.a.createElement(ia,{closeIcon:!0,onClick:function(){return n(e.value)}},e.category&&a.a.createElement("div",{className:"text-f12"},e.category,":"),a.a.createElement("div",{className:"capitalize fw-700",style:{marginLeft:5,textTransform:"capitalize",marginRight:10}},e.label)))})),a.a.createElement("li",{key:"clear",className:Rn()("flex items-center",{hidden:d.length<2})},a.a.createElement(na,{className:"text-f12 fw-600"},"Clear all")))):null})),ca=n(918),ua=n(919);var sa,fa=Object(ua.a)((function(e){var t=e.children;return a.a.createElement(ca.a,{container:!0,justifyContent:"space-between",alignItems:"center",style:{height:"100%"}},t,a.a.createElement(ca.a,{item:!0,className:"item-notify-right",style:{minWidth:32}}))})),da=n(334),pa=n.n(da),ha=n(218),ma=n.n(ha),ga=["svgRef","title"];function va(){return(va=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function ya(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ba,xa=function(e){var t=e.svgRef,n=e.title,r=ya(e,ga);return a.a.createElement("svg",va({width:10,height:11,viewBox:"0 0 10 11",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,sa||(sa=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.56905 7.91401C6.92789 7.46225 7.47234 7.19773 8.04926 7.19483C9.10003 7.19483 9.95185 8.04665 9.95185 9.09742C9.95185 10.1482 9.10003 11 8.04926 11C6.99849 11 6.14667 10.1482 6.14667 9.09742C6.14847 8.92726 6.17408 8.75819 6.22277 8.59513L3.44118 6.85616C2.93785 7.48979 2.0888 7.73571 1.32474 7.46917C0.560687 7.20264 0.0488281 6.48196 0.0488281 5.67275C0.0488281 4.86354 0.560687 4.14287 1.32474 3.87633C2.0888 3.60979 2.93785 3.85571 3.44118 4.48934L6.22277 2.75037C6.17408 2.58732 6.14847 2.41825 6.14667 2.24809C6.14083 1.32028 6.80508 0.523574 7.7188 0.36244C8.63252 0.201306 9.52922 0.722744 9.84111 1.59657C10.153 2.4704 9.78909 3.44177 8.97983 3.89559C8.17057 4.34941 7.15198 4.15332 6.56905 3.4315L3.78746 5.17047C3.88883 5.49765 3.88883 5.84785 3.78746 6.17504L6.56905 7.91401ZM9.19066 2.24808C9.19066 1.61762 8.67957 1.10653 8.04911 1.10653C7.41864 1.10653 6.90755 1.61762 6.90755 2.24808C6.90755 2.87855 7.41864 3.38964 8.04911 3.38964C8.67957 3.38964 9.19066 2.87855 9.19066 2.24808ZM1.96089 6.81431C1.33043 6.81431 0.819336 6.30322 0.819336 5.67275C0.819336 5.04229 1.33043 4.5312 1.96089 4.5312C2.59136 4.5312 3.10245 5.04229 3.10245 5.67275C3.10245 6.30322 2.59136 6.81431 1.96089 6.81431ZM6.90755 9.09742C6.90755 9.72788 7.41864 10.239 8.04911 10.239C8.67957 10.239 9.19066 9.72788 9.19066 9.09742C9.19066 8.46695 8.67957 7.95586 8.04911 7.95586C7.41864 7.95586 6.90755 8.46695 6.90755 9.09742Z",fill:"currentColor"})))},wa=a.a.forwardRef((function(e,t){return a.a.createElement(xa,va({svgRef:t},e))})),Ca=(n.p,["svgRef","title"]);function Ea(){return(Ea=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Oa(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ja,La=function(e){var t=e.svgRef,n=e.title,r=Oa(e,Ca);return a.a.createElement("svg",Ea({width:11,height:11,viewBox:"0 0 11 11",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,ba||(ba=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M1.53059 7.14308H3.81466V9.11675C3.7348 9.90592 4.28699 10.6128 5.04806 10.6957C5.14416 10.7075 5.24128 10.7075 5.33738 10.6957H5.93504C6.19675 10.6882 6.42056 10.4984 6.47941 10.2338V10.1865L6.86009 7.68387L8.20769 5.56415H10.6669V0.0378923H3.43399C0.601741 0.0378923 0.00788307 1.75498 0.00788307 3.19576V5.56415C-0.0719852 6.35332 0.480213 7.06022 1.24128 7.14308C1.33738 7.15493 1.43449 7.15493 1.53059 7.14308ZM8.38276 0.827361H9.90548V4.77469H8.38276V0.827361ZM3.43384 0.827355C1.6142 0.827355 0.769092 1.5813 0.769092 3.19575V5.56415C0.769092 6.13256 0.982271 6.35361 1.53045 6.35361H4.57587V9.11674C4.57587 9.68516 4.78905 9.90621 5.33723 9.90621H5.76739L5.82069 9.51148L6.09858 7.39176L7.6213 5.051V0.827355H3.43384Z",fill:"currentColor"})))},ka=a.a.forwardRef((function(e,t){return a.a.createElement(La,Ea({svgRef:t},e))})),Sa=(n.p,["svgRef","title"]);function Ra(){return(Ra=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Na(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Ia,Ma=function(e){var t=e.svgRef,n=e.title,r=Na(e,Sa);return a.a.createElement("svg",Ra({width:12,height:11,viewBox:"0 0 12 11",fill:"currentColor",ref:t},r),n?a.a.createElement("title",null,n):null,ja||(ja=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.80278 3.59938H7.51871V1.62572C7.59858 0.836545 7.04638 0.129649 6.28531 0.0467847C6.18921 0.0349422 6.0921 0.0349422 5.996 0.0467847H5.39833C5.13662 0.0542197 4.91282 0.244093 4.85396 0.508622V0.55599L4.47329 3.0586L3.12568 5.17831H0.666504V10.7046H7.89939C10.7316 10.7046 11.3255 8.98748 11.3255 7.54671V5.17831C11.4054 4.38914 10.8532 3.68224 10.0921 3.59938C9.99599 3.58754 9.89888 3.58754 9.80278 3.59938ZM2.95061 9.9151H1.4279V5.96777H2.95061V9.9151ZM7.89954 9.9151C9.71918 9.9151 10.5643 9.16116 10.5643 7.5467V5.1783C10.5643 4.60989 10.3511 4.38884 9.80293 4.38884H6.7575V1.62571C6.7575 1.05729 6.54432 0.836243 5.99615 0.836243H5.56598L5.51268 1.23098L5.23479 3.35069L3.71208 5.69146V9.9151H7.89954Z",fill:"currentColor"})))},_a=a.a.forwardRef((function(e,t){return a.a.createElement(Ma,Ra({svgRef:t},e))})),Fa=(n.p,["svgRef","title"]);function Ta(){return(Ta=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Ha(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Pa,Ba=function(e){var t=e.svgRef,n=e.title,r=Ha(e,Fa);return a.a.createElement("svg",Ta({width:16,height:16,viewBox:"0 0 16 16",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,Ia||(Ia=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M1.42028 4.82804C1.42028 5.22014 1.10221 5.53825 0.710142 5.53825C0.318078 5.53825 0 5.22014 0 4.82804V2.69216C0 1.20767 1.20757 0 2.69193 0H4.87323C5.26529 0 5.58337 0.318104 5.58337 0.710201C5.58337 1.1023 5.26529 1.4204 4.87323 1.4204H2.69193C1.99071 1.4204 1.42028 1.99087 1.42028 2.69216V4.82804ZM13.3081 0H11.1268C10.7347 0 10.4167 0.318104 10.4167 0.710201C10.4167 1.1023 10.7347 1.4204 11.1268 1.4204H13.3081C14.0093 1.4204 14.5798 1.99087 14.5798 2.69216V4.82804C14.5798 5.22014 14.8978 5.53825 15.2899 5.53825C15.682 5.53825 16 5.22014 16 4.82804V2.69216C16 1.20767 14.7925 0 13.3081 0ZM15.2899 10.4614C14.8978 10.4614 14.5798 10.7795 14.5798 11.1716V13.3078C14.5798 14.0091 14.0093 14.5796 13.3081 14.5796H11.1268C10.7347 14.5796 10.4167 14.8977 10.4167 15.2898C10.4167 15.6819 10.7347 16 11.1268 16H13.3081C14.7925 16 16 14.7923 16 13.3078V11.1716C16 10.7795 15.682 10.4614 15.2899 10.4614ZM4.87323 14.5796H2.69193C1.99071 14.5796 1.42028 14.0091 1.42028 13.3078V11.1716C1.42028 10.7795 1.10221 10.4614 0.710142 10.4614C0.318078 10.4614 0 10.7792 0 11.1716V13.3078C0 14.7923 1.20757 16 2.69193 16H4.87323C5.26529 16 5.58337 15.6819 5.58337 15.2898C5.58337 14.8977 5.26529 14.5796 4.87323 14.5796ZM12.6019 12.6029C12.4476 12.7572 12.2425 12.8421 12.0242 12.8421L12.0245 12.8418C11.8062 12.8418 11.6011 12.7569 11.4468 12.6026L10.2604 11.4161C9.59218 11.8613 8.81663 12.0952 8.00047 12.0952C6.90685 12.0952 5.87863 11.6694 5.1054 10.8961C4.33217 10.1228 3.90641 9.09453 3.90641 8.00082C3.90641 6.90711 4.33217 5.87881 5.1054 5.10552C5.87863 4.33222 6.90685 3.90643 8.00047 3.90643C9.09408 3.90643 10.1223 4.33222 10.8955 5.10552C11.6688 5.87881 12.0945 6.90711 12.0945 8.00082C12.0945 8.81706 11.8607 9.59266 11.4154 10.2612L12.6019 11.4478C12.9203 11.7662 12.9203 12.2845 12.6019 12.6029ZM9.73685 9.73702C9.75171 9.72248 9.76723 9.70795 9.78342 9.69407C10.2201 9.23426 10.4605 8.63373 10.4605 8.00082C10.4605 6.64418 9.35667 5.54023 8.00014 5.54023C6.6436 5.54023 5.53974 6.64418 5.53974 8.00082C5.53974 9.35747 6.64327 10.4614 8.00014 10.4614C8.63299 10.4614 9.23347 10.2213 9.69325 9.78425C9.70745 9.76774 9.72198 9.75188 9.73685 9.73702Z",fill:"#2B2C46"})))},Aa=a.a.forwardRef((function(e,t){return a.a.createElement(Ba,Ta({svgRef:t},e))})),Va=(n.p,["svgRef","title"]);function Ga(){return(Ga=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function za(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Da=function(e){var t=e.svgRef,n=e.title,r=za(e,Va);return a.a.createElement("svg",Ga({width:16,height:17,viewBox:"0 0 16 17",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,Pa||(Pa=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14.643 4.65152L8.343 1.24366C8.12642 1.12191 7.85958 1.12191 7.643 1.24366L1.34303 4.65152C1.12828 4.77548 0.997588 5.00142 1.00003 5.24448V12.0602C1.00047 12.3061 1.13689 12.5327 1.35703 12.6532L7.657 16.061C7.87358 16.1828 8.14042 16.1828 8.357 16.061L14.657 12.6532C14.8717 12.5292 15.0024 12.3033 15 12.0602V5.24448C14.9995 4.9986 14.8631 4.772 14.643 4.65152ZM7.99982 2.61361L12.8578 5.24447L7.99982 7.87534L3.14185 5.24447L7.99982 2.61361ZM2.40015 6.40315L7.30012 9.05447V14.3094L2.40015 11.6581V6.40315ZM8.69983 14.3094V9.05447L13.5998 6.40315V11.6581L8.69983 14.3094Z",fill:"#2B2C46"})))},qa=a.a.forwardRef((function(e,t){return a.a.createElement(Da,Ga({svgRef:t},e))})),Za=(n.p,n(276)),Wa=n.n(Za),Ua=n(904),Ya=n(333),Ka=n.n(Ya),Qa=n(495),Ja=n.n(Qa),Xa=function(e){var t=e.dataItem,n=e.isOpen,r=e.setModalState,o=t["image(main_similarity)"]||t.main_image_link;return a.a.createElement(kt,{openModal:n,handleClose:function(){return r(!1)}},a.a.createElement(h.a,{className:"box-modal-default box-modal-share",style:{padding:"4px"}},a.a.createElement(h.a,{className:"ml-auto",style:{width:"fit-content",marginRight:5}},a.a.createElement(Ce.a,{style:{padding:0},onClick:function(){return r(!1)}},a.a.createElement(aa.a,{style:{fontSize:16,color:"#55566B"}}))),a.a.createElement(h.a,{className:"box-content-box-share"},a.a.createElement(On.a,{className:"text-f12 text-gray text-bold",style:{marginBottom:"5px"}},"Share"),o&&a.a.createElement(Ua.a,{component:"form",className:"box-input"},a.a.createElement(h.a,{className:"text-f9 text-gray",style:{width:"100%",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",paddingRight:"10px"}},o),a.a.createElement(Re.a,{color:"secondary","aria-label":"directions",style:{padding:"4px"},onClick:function(){navigator.clipboard.writeText(o)}},a.a.createElement(Ka.a,{style:{fontSize:14}}))),a.a.createElement(Ua.a,{component:"form",className:"box-input",style:{marginTop:"12px",marginBottom:"8px"}},a.a.createElement(h.a,{className:"text-f9 text-gray",style:{width:"100%",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",paddingRight:"10px",display:"flex",alignItems:"center"}},a.a.createElement("span",{style:{fontWeight:"bold",paddingRight:"4px"}},"SKU:")," ",t.sku),a.a.createElement(Re.a,{color:"secondary","aria-label":"directions",style:{padding:"4px"},onClick:function(){navigator.clipboard.writeText(t.sku)}},a.a.createElement(Ka.a,{style:{fontSize:14}}))),a.a.createElement(h.a,{className:"box-media-share",display:"flex",style:{marginTop:"18px"}},a.a.createElement("a",{style:{padding:0},href:"mailto:support@nyris.io?subject=GF-Sparepart-Search&body= ".concat(encodeURIComponent("SKU: "+t.sku+"\r\n"+(o?"Image Link: ".concat(o):""))," ")},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement("img",{width:40,height:40,src:Ja.a,alt:"icon_email"})))))))};function $a(){$a=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var eo=function(){var e=Object(d.a)($a().mark((function e(t,n){var r,a,o,i;return $a().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.search,a=t.settings,o=r.sessionId,i=r.requestId||r.sessionId,e.next=5,ao(a,o,i,{event:"feedback",data:{success:n}});case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),to=function(){var e=Object(d.a)($a().mark((function e(t,n,r){var a,o;return $a().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=t.search,o=t.settings,e.next=3,ao(o,a.sessionId,a.requestId,{event:"click",data:Object(f.a)({positions:[n]},r?{product_ids:[r]}:{})});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),no=function(){var e=Object(d.a)($a().mark((function e(t,n,r){var a,o;return $a().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=t.search,o=t.settings,e.next=3,ao(o,a.sessionId,a.requestId,{event:"conversion",data:Object(f.a)({positions:[n]},r?{product_ids:[r]}:{})});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),ro=function(){var e=Object(d.a)($a().mark((function e(t,n){var r,a,o,i,l,c,u,s,f;return $a().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.settings,a=t.search,o=a.sessionId,i=a.requestId,l=n.x1,c=n.x2,u=n.y1,s=n.y2,f={event:"region",data:{rect:{x:l,y:u,w:c-l,h:s-u}}},e.next=6,ao(r,o,i,f);case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),ao=function(){var e=Object(d.a)($a().mark((function e(t,n,r,a){var o;return $a().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(o=new Ge.a(t),!n||!r){e.next=10;break}return e.prev=2,e.next=5,o.sendFeedback(n,r,a).then((function(e){}));case 5:e.next=10;break;case 7:e.prev=7,e.t0=e.catch(2),console.log("error sendFeedbackByApi",e.t0);case 10:case"end":return e.stop()}}),e,null,[[2,7]])})));return function(t,n,r,a){return e.apply(this,arguments)}}(),oo=n(921),io=n(497),lo=n.n(io),co=n(282),uo=(n(813),n(814),n(815),function(e){var t=e.imgItem,n=e.setSelectedImage,o=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),i=Object(r.useRef)(null),l=Object(r.useRef)(null),c=Object(r.useMemo)((function(){var e=75+58*t.length,n=o?240:460;return e<n?e:n}),[t.length,o]),u=Object(r.useMemo)((function(){return{type:"slide",perPage:1,perMove:1,gap:"1rem",pagination:!1,arrows:!1}}),[]),s=Object(r.useMemo)((function(){return{type:"slide",rewind:!0,gap:"1rem",pagination:!1,fixedWidth:40,fixedHeight:40,cover:!0,focus:"center",isNavigation:!0,arrows:t.length>1,width:c}}),[t.length,c]),f=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return t.map((function(t){return a.a.createElement(co.b,{key:t.url,className:e?"":"img-container"},a.a.createElement("img",{style:{objectFit:"contain",height:"100%"},alt:"preview",src:t.url}))}))};return a.a.useEffect((function(){var e;i.current&&l.current&&(null===(e=l.current)||void 0===e?void 0:e.splide)&&i.current.sync(l.current.splide)}),[]),a.a.createElement(a.a.Fragment,null,a.a.createElement(co.a,{onActive:function(e){var t,r,a;n(null===e||void 0===e||null===(t=e.root)||void 0===t||null===(r=t.querySelector("li.is-active"))||void 0===r||null===(a=r.querySelector("img"))||void 0===a?void 0:a.src)},options:u,ref:i,style:{maxWidth:"100%",height:o?"80%":""}},f()),a.a.createElement("div",{className:"thumbs-list"},a.a.createElement(co.a,{options:s,ref:l},f(!0))))}),so=n(496),fo=n.n(so);var po,ho=function(e){var t=e.title,n=e.value,r=e.padding,o=void 0===r?e.padding||"4px 16px":r,i=e.width,l=void 0===i?e.width||"fit-content":i;return a.a.createElement(h.a,{display:"flex",flexDirection:"column",borderRadius:2,width:l,style:{backgroundColor:"#E0E0E0",padding:o,flexGrow:1}},a.a.createElement(On.a,{style:{color:"#2B2C46",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},className:"text-f12 fw-700"},t),a.a.createElement(On.a,{style:{color:"#2B2C46",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},className:"text-f12 fw-400"},n))},mo=["svgRef","title"];function go(){return(go=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function vo(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var yo=function(e){var t=e.svgRef,n=e.title,r=vo(e,mo);return a.a.createElement("svg",go({width:16,height:16,viewBox:"0 0 16 16",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,po||(po=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12.5055 6.45389C12.7282 6.23157 13.0888 6.23169 13.3113 6.45415C13.5338 6.67672 13.5338 7.03757 13.3113 7.26013L8.70707 11.8643C8.31655 12.2548 7.68338 12.2548 7.29286 11.8643L2.68867 7.26013C2.4661 7.03757 2.4661 6.67672 2.68867 6.45415C2.91113 6.23169 3.27178 6.23157 3.49438 6.45389L5.7219 8.67847C6.35205 9.30779 7.42854 8.86148 7.42854 7.97089V0.571428C7.42854 0.255837 7.68437 0 7.99996 0C8.31556 0 8.57139 0.255838 8.57139 0.571429V7.97089C8.57139 8.86148 9.64788 9.30779 10.278 8.67847L12.5055 6.45389ZM12.7143 14.8571C13.2665 14.8571 13.7143 14.4094 13.7143 13.8571V13.1429C13.7143 12.8273 13.9701 12.5714 14.2857 12.5714C14.6013 12.5714 14.8571 12.8273 14.8571 13.1429V14.8571C14.8571 15.4883 14.3454 16 13.7143 16H2.28568C1.6545 16 1.14282 15.4883 1.14282 14.8571V13.1429C1.14282 12.8273 1.39866 12.5714 1.71425 12.5714C2.02984 12.5714 2.28568 12.8273 2.28568 13.1429V13.8571C2.28568 14.4094 2.7334 14.8571 3.28568 14.8571H12.7143Z",fill:"#2B2C46"})))},bo=a.a.forwardRef((function(e,t){return a.a.createElement(yo,go({svgRef:t},e))})),xo=(n.p,function(){return a.a.createElement("svg",{width:150,height:150,viewBox:"0 0 150 150",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"loading-spinner"},a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M75 150C116.421 150 150 116.421 150 75C150 33.5787 116.421 1.31134e-05 75 1.31134e-05C33.5787 1.31134e-05 1.31134e-05 33.5787 1.31134e-05 75C1.31134e-05 116.421 33.5787 150 75 150ZM75 145C113.66 145 145 113.66 145 75C145 36.3401 113.66 5.00001 75 5.00001C36.3401 5.00001 5.00001 36.3401 5.00001 75C5.00001 113.66 36.3401 145 75 145Z",fill:"url(#paint0_linear_3392_14489)"}),a.a.createElement("defs",null,a.a.createElement("linearGradient",{id:"paint0_linear_3392_14489",x1:75,y1:0,x2:75,y2:150,gradientUnits:"userSpaceOnUse"},a.a.createElement("stop",{stopColor:"#D3D1FF"}),a.a.createElement("stop",{offset:1,stopColor:"white"}))))});var wo=function(){var e=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),t=Object(Qt.b)().t;return a.a.createElement("div",{style:{borderRadius:"2px",background:"linear-gradient(180deg, #FAFAFA 0%, #E4E3FF 100%)",width:"100%",height:e?"368px":"456px",display:"flex",justifyContent:"center",alignItems:"center",position:"relative"}},a.a.createElement("p",{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}},t("loading")),a.a.createElement(xo,null))},Co=["actMeasureGrid","actCut","actAnimate","actIsometric","actExternalAR"];var Eo=function(e){var t=e.is3dView,n=e.sku,o=e.setStatus3dView,i=e.status3dView,l=Object(r.useState)(""),c=Object(p.a)(l,2),u=c[0],s=c[1],f=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),d=we((function(e){return e})).settings;Object(r.useEffect)((function(){var e,t,r={$container:$("#cnsWebViewer3d"),viewerBackendType:psol.components.WebViewer3D.ViewerBackends.WebGL,devicePixelRatio:window.devicePixelRatio,radialMenuActions:[],favoriteActions:Co,showProgressDialog:!1,webglViewerSettings:{ColorTL:"#fff",ColorTR:"#fff",ColorML:"#fff",ColorMR:"#fff",ColorBL:"#fff",ColorBR:"#fff",showLogo:!1,logoTexture:"./img/logo.png",logoScaleFactor:1,logoMixFactor:.5,material:{preset:"pcloud",edit:!1},measureGrid:{colors:{dimensions:"#000000",outline:"#0000ff",grid:"#757575",unit:"mm"}},helperOptions:{gridOn:!1,axisOn:!1},shadeMode:psol.components.WebViewer3D.ShadeModes.ShadeAndLines,enableEditableDimensions:!0,showPartNameTooltip:!1}},a=new psol.components.WebViewer3D(r);psol.core.setApiKey(null===(e=d.cadenas)||void 0===e?void 0:e.cadenasAPIKey),o("loading"),psol.core.ajaxGetOrPost({url:psol.core.getServiceBaseUrl()+"/service/reversemap",data:{catalog:null===(t=d.cadenas)||void 0===t?void 0:t.catalog,part:n,exact:"0"}}).then((function(e){var t=e.mident||"";s(t),a.show().then((function(){a.loadByVarset(null,null,t).then((function(){o("loaded")})).catch((function(e){o("not-found")}))}))}))}),[n,o,d]);var g=!t||"loaded"!==i;return a.a.createElement(a.a.Fragment,null,"not-found"!==i&&a.a.createElement("div",{id:"cnsWebViewer3d",style:{height:g?"0px":f?"368px":"456px",width:"100%",opacity:g?0:1,transition:t&&"loaded"!==i?"opacity 2s ease":""}}),a.a.createElement("div",{style:{position:"absolute",bottom:"19px",right:"26px"}},t&&"loaded"===i&&a.a.createElement(h.a,{style:{background:"#E9E9EC",width:"32px",height:"32px",borderRadius:"100%",display:"flex",justifyContent:"center",alignItems:"center",cursor:"pointer"},onClick:function(){new psol.components.DownloadDialog({mident:u}).show()}},a.a.createElement(bo,{width:14,height:14,color:"#FFF"}))),"loading"===i&&t&&a.a.createElement(wo,null),"not-found"===i&&t&&a.a.createElement("div",{style:{height:f?"368px":"456px",width:"100%",color:"#AAABB5",background:"linear-gradient(180deg, #fff 0%, #E9E9EC 100%)",fontSize:"16px",display:"flex",justifyContent:"center",alignItems:"center"}},"No 3D View available for this item"))},Oo=n(920),jo=Object(Oo.a)((function(e){return{buttonStyle3D:Object(gn.a)({bottom:function(e){return e?"20px":"68px"}},e.breakpoints.up("md"),{bottom:function(e){return e?"20px":"10px"}}),buttonStyleImageSearch:Object(gn.a)({bottom:function(e){return e?"20px":"78px"}},e.breakpoints.up("md"),{bottom:function(e){return e?"20px":"4px"}})}}));var Lo=function(e){var t,n,o,i,l,c,u,s=e.dataItem,d=e.handleClose,g=e.handlerFeedback,v=e.onHandlerModalShare,y=e.show3dView,b=void 0!==y&&y,x=e.onSearchImage,w=s.sku,C=s.title,E=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),O=we((function(e){return e})).settings,j=s[O.field.productTag],L=Object(r.useState)(!1),k=Object(p.a)(L,2),S=k[0],R=k[1],N=Object(r.useState)("none"),I=Object(p.a)(N,2),M=I[0],_=I[1],F=Object(r.useState)(b),T=Object(p.a)(F,2),H=T[0],P=T[1],B=Object(r.useState)([]),A=Object(p.a)(B,2),V=A[0],G=A[1],z=Object(r.useState)(""),D=Object(p.a)(z,2),q=D[0],Z=D[1],W=Object(r.useState)(),U=Object(p.a)(W,2),Y=U[0],K=U[1],Q=Object(Qt.b)().t,J=jo(null===e||void 0===e?void 0:e.show3dView),X=Object(He.get)(s,(null===(t=O.field)||void 0===t?void 0:t.ctaLinkField)?null===(n=O.field)||void 0===n?void 0:n.ctaLinkField:"links.main");Object(r.useEffect)((function(){s&&(ee(s),$(s["image(main_similarity)"]||s.main_image_link))}),[s]);var $=function(e,t){t=t||5e3;var n=new Image;n.onerror=n.onabort=function(){clearTimeout(void 0),Z("")},n.onload=function(){return clearTimeout(void 0),void Z(e)},n.src=e},ee=function(e){var t=function(e){var t=[],n=e;if(!e)return[];for(var r in n)(null===r||void 0===r?void 0:r.includes("image(recognition)"))||(null===r||void 0===r?void 0:r.includes("additional_image_link"))?Object(He.isEmpty)(n[r])||n[r]&&t.push({url:n[r]}):"image(main_similarity)"!==r&&"main_image_link"!==r||n[r]&&t.push({url:n[r]});return t}(e);G(t)},te=Object(r.useMemo)((function(){var e=Object(He.get)(s,O.field.productDetails);try{return e.join(", ")}catch(t){return e}}),[s,O.field.productDetails]),ne=Object(He.get)(s,O.field.manufacturerNumber);return a.a.createElement(h.a,{className:"box-modal-default",borderRadius:12,style:{margin:E?0:"",width:"600px",backgroundColor:"#fff"}},a.a.createElement(h.a,{className:"ml-auto",style:{width:"fit-content",marginRight:4,position:"absolute",top:"28px",right:"28px",zIndex:100}},a.a.createElement(Ce.a,{style:{padding:0},onClick:function(){return null===d||void 0===d?void 0:d()}},a.a.createElement(aa.a,{style:{fontSize:24,color:"#55566B"}}))),a.a.createElement("div",{style:{position:"relative"}},(null===(o=O.cadenas)||void 0===o?void 0:o.cadenas3dWebView)&&a.a.createElement(Eo,{is3dView:H,sku:w,status3dView:Y,setStatus3dView:K}),a.a.createElement(h.a,{className:"box-carosel",style:Object(f.a)(Object(f.a)({},0===V.length?{display:"flex",justifyContent:"center"}:{}),{},{width:H?"0px":"100%",height:H?"0px":E?"368px":"60%",opacity:H?0:1,transition:H?"":"opacity 3s ease",paddingTop:H?"0px":"16px"})},V.length>0&&a.a.createElement(uo,{imgItem:V,setSelectedImage:function(e){Z(e||q)}}),V.length>0&&a.a.createElement(Ce.a,{className:J.buttonStyleImageSearch,style:{position:"absolute",right:"16px",background:"#E9E9EC",width:"32px",height:"32px",borderRadius:"100%",display:"flex",justifyContent:"center",alignItems:"center",cursor:"pointer",bottom:E?"25px":"4px"},onClick:function(){if(q.length>1)return x(q),void(null===d||void 0===d||d())}},a.a.createElement(Aa,{color:"#AAABB5"})),0===V.length&&a.a.createElement("div",{style:{width:"400px",height:"400px",display:"flex",alignItems:"center",justifyContent:"center"}},a.a.createElement("img",{src:Wa.a,alt:"image_item",className:"img-style",style:{width:"150px",height:"150px",padding:"8px"}}))),a.a.createElement("div",{className:J.buttonStyle3D,style:{position:"absolute",left:"16px",bottom:E?"25px":"10px"}},!H&&"not-found"!==Y&&(null===(i=O.cadenas)||void 0===i?void 0:i.cadenas3dWebView)&&a.a.createElement(h.a,{style:{background:"#E9E9EC",width:"32px",height:"32px",borderRadius:"100%",display:"flex",justifyContent:"center",alignItems:"center",cursor:"pointer"},onClick:function(){P(!0)}},a.a.createElement(qa,{width:16,height:16,color:"#AAABB5"})),H&&a.a.createElement(h.a,{style:{background:"#2B2C46",width:"32px",height:"32px",borderRadius:"100%",display:"flex",justifyContent:"center",alignItems:"center",cursor:"pointer"},onClick:function(){P(!1)}},a.a.createElement(bt,{width:16,height:16,color:"#FFF"})))),a.a.createElement(h.a,{style:{overflowY:"auto",maxHeight:"90svh",paddingLeft:"16px",paddingRight:"16px",paddingBottom:"16px",backgroundColor:"#F3F3F5",marginTop:"6px"}},a.a.createElement(h.a,{className:"box-content",display:"flex",style:{marginTop:"16px",flexDirection:"column",backgroundColor:"#F3F3F5"}},a.a.createElement(h.a,{className:"box-top"},O.warehouseVariant&&a.a.createElement(h.a,{display:"flex",justifyContent:"space-between",flexDirection:"row",style:{color:"#2B2C46",marginBottom:10,paddingLeft:16,paddingRight:16},gridGap:8},a.a.createElement(On.a,{className:"text-f12 max-line-1 fw-400",style:{color:"#2B2C46"}},w),O.warehouseVariant&&a.a.createElement(On.a,{className:"text-f12 max-line-1 fw-400",style:{color:"#2B2C46"}},a.a.createElement("span",{style:{color:s[O.field.warehouseStockValue]?"#00C070":"#c54545",fontWeight:600}},s[O.field.warehouseStockValue]||0))),a.a.createElement(ca.a,{container:!0,justifyContent:"space-between",style:{backgroundColor:"#F3F3F5"}},a.a.createElement(h.a,{display:"flex",flexDirection:"row",flexWrap:"wrap",style:{gap:6},width:"100%"},!O.warehouseVariant&&O.CTAButtonText&&a.a.createElement(ho,{title:"Produktname",value:C,width:O.warehouseVariant?{xs:"49%",md:"fit-content"}:{xs:"100%",md:"fit-content"}}),!O.warehouseVariant&&a.a.createElement(ho,{title:O.itemIdLabel||"SKU",value:w,width:O.warehouseVariant?{xs:"49%",md:"fit-content"}:{xs:"100%",md:"fit-content"}}),(j||O.brandName)&&a.a.createElement(ho,{title:Q("Brand"),value:j||O.brandName,width:ne?{xs:"49%",md:"fit-content"}:{xs:"100%",md:"fit-content"}}),ne&&a.a.createElement(ho,{title:Q("Manufacturer Number"),value:ne,width:j||O.brandName?{xs:"49%",md:"fit-content"}:{xs:"100%",md:"fit-content"}}),O.warehouseVariant&&a.a.createElement(a.a.Fragment,null,O.field.warehouseNumber&&a.a.createElement(ho,{title:s[O.field.warehouseNumber],value:s[O.field.warehouseNumberValue]||"N/A",width:{xs:"49%",md:"fit-content"}}),O.field.warehouseShelfNumber&&a.a.createElement(ho,{title:s[O.field.warehouseShelfNumber],value:s[O.field.warehouseShelfNumberValue]||"N/A",width:{xs:"49%",md:"fit-content"}}))),a.a.createElement(ca.a,{item:!0,xs:12,style:{backgroundColor:"#F3F3F5"}},a.a.createElement(h.a,{style:{background:null===(l=O.theme)||void 0===l?void 0:l.primaryColor,boxShadow:"0px 4px 4px rgba(0, 0, 0, 0.25)",borderRadius:4,marginTop:8},display:"flex",justifyContent:"space-between",alignItems:"center",className:"btn-detail-item"},a.a.createElement(h.a,{style:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%",padding:"0px 12px",minHeight:64,cursor:X?"pointer":"normal"},onClick:function(){X&&window.open("".concat(X),"_blank")}},a.a.createElement(On.a,{className:"text-f18 fw-700 text-white max-line-2",align:"left",style:{letterSpacing:"0.55px",maxWidth:"500px",paddingRight:"4px"}},O.CTAButtonText?O.CTAButtonText:s[O.field.productName]),X&&a.a.createElement("img",{src:ma.a,alt:"",style:{minWidth:16,marginLeft:5}}))),te&&a.a.createElement(h.a,{className:"w-100"},a.a.createElement(Ce.a,{className:"w-100 button-hover",style:{backgroundColor:"#F3F3F5",color:"#2b2c46",display:"flex",fontSize:14,justifyContent:"space-between",marginTop:12,paddingLeft:"15px",paddingRight:"15px",textTransform:"initial"},onClick:function(){return R((function(e){return!e}))}},Q("View details"),S?a.a.createElement(fo.a,{htmlColor:null===(c=O.theme)||void 0===c?void 0:c.secondaryColor}):a.a.createElement(lo.a,{htmlColor:null===(u=O.theme)||void 0===u?void 0:u.secondaryColor})),a.a.createElement(oo.a,{in:S},a.a.createElement(On.a,{style:{fontSize:14,padding:5,paddingLeft:15,paddingRight:15,color:"#2b2c46"}},te)))))),O.showFeedbackAndShare&&a.a.createElement(h.a,{className:"box-bottom",style:{height:"48px",padding:"0px 16px 0px 16px",marginBottom:10,marginTop:10},display:"flex",justifyContent:"center"},a.a.createElement(ca.a,{container:!0,justifyContent:O.shareOption?"space-between":"space-around",alignItems:"center"},a.a.createElement(ca.a,{item:!0},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement(Ce.a,{className:"btn-item",onClick:function(){g("like"),_("like")}},a.a.createElement(_a,{width:24,height:24,color:"like"===M?"#3E36DC":"#000000"})))),a.a.createElement(ca.a,{item:!0},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement(Ce.a,{className:"btn-item",onClick:function(){g("dislike"),_("dislike")}},a.a.createElement(ka,{width:24,height:24,color:"dislike"===M?"#CC1854":"#000000"})))),O.shareOption&&a.a.createElement(ca.a,{item:!0},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement(Ce.a,{className:"btn-item",onClick:function(){return v()}},a.a.createElement(wa,{width:24,height:24,color:"#000000"})))))))))};var ko=Object(r.memo)((function(e){var t,n,o,i,l,c,u=e.dataItem,s=e.isHover,f=void 0!==s&&s,d=e.onSearchImage,g=e.handlerGroupItem,v=e.handlerFeedback,y=e.isGroupItem,b=e.handlerCloseGroup,x=e.main_image_link,w=e.indexItem,C=xe(),E=Object(r.useState)(""),O=Object(p.a)(E,2),j=O[0],L=O[1],k=we((function(e){return e})),S=k.settings,R=Object(r.useState)(),N=Object(p.a)(R,2),I=N[0],M=N[1],_=Object(r.useState)(!1),F=Object(p.a)(_,2),T=F[0],H=F[1],P=Object(r.useState)("none"),B=Object(p.a)(P,2),A=B[0],V=B[1],G=Object(Qt.b)().t,z=u.sku,D=u.collap,q=u[S.field.productTag],Z=Object(m.useMediaQuery)({query:"(max-width: 776px)"});Object(r.useEffect)((function(){x&&W(x)}),[x]);var W=function(e,t){t=t||5e3;var n=new Image;n.onerror=n.onabort=function(){clearTimeout(void 0),L("")},n.onload=function(){return clearTimeout(void 0),void L(e)},n.src=e},U=Object(He.get)(u,(null===(t=S.field)||void 0===t?void 0:t.ctaLinkField)?null===(n=S.field)||void 0===n?void 0:n.ctaLinkField:"links.main"),Y=Object(He.get)(u,S.field.manufacturerNumber);return a.a.createElement(h.a,{className:"wrap-main-item-result"},a.a.createElement(kt,{openModal:"3d"===I||"image"===I,handleClose:function(e){M(void 0)}},a.a.createElement(Lo,{dataItem:u,handleClose:function(){M(void 0)},handlerFeedback:v,show3dView:"3d"===I,onHandlerModalShare:function(){return H(!0)},onSearchImage:function(e){C(fe(!0)),d(e)}})),a.a.createElement(Xa,{setModalState:H,dataItem:u,isOpen:T}),a.a.createElement(h.a,{className:"box-top"},y&&D&&a.a.createElement(h.a,{className:"btn-show-result"},a.a.createElement(Ce.a,{onClick:function(){g(u,w)}},G("Show group"),a.a.createElement(pa.a,{style:{fontSize:"10px"}}))),y&&!D&&a.a.createElement(h.a,{className:"btn-show-result"},a.a.createElement(Ce.a,{onClick:function(){b(u,w)}},G("Close group"),a.a.createElement(pa.a,{style:{fontSize:"10px"}}))),!f&&x&&a.a.createElement(h.a,{className:"box-icon-modal",onClick:function(){j.length>1&&d(x)}},a.a.createElement(Aa,{width:16,height:16,color:"#AAABB5"})),(null===(o=S.cadenas)||void 0===o?void 0:o.cadenas3dWebView)&&a.a.createElement(h.a,{className:"box-icon-modal-3d",onClick:function(){M("3d")}},a.a.createElement(qa,{width:16,height:16,color:"#AAABB5"})),a.a.createElement(h.a,{className:"box-image"},a.a.createElement(h.a,{style:{width:"100%",height:"100%",cursor:"pointer",display:"flex",justifyContent:"center",alignItems:"center"},onClick:function(e){e.preventDefault(),to(k,w,u.sku),M("image"),C(Q(!0)),C(fe(!0)),setTimeout((function(){C(fe(!1))}),400)}},x?a.a.createElement("img",{src:x,key:x,alt:"image_item",className:"img-style product-image",style:{width:"100%",height:"100%",objectFit:"contain"}}):a.a.createElement("img",{src:Wa.a,alt:"image_item",style:{width:"70%",height:"50%"}})))),a.a.createElement(h.a,{className:"box-content",display:"flex",style:{flexDirection:"column",backgroundColor:"#F3F3F5",flexGrow:1,zIndex:100}},a.a.createElement(h.a,{className:"box-top",style:{color:"#FFFFFF"}},a.a.createElement(h.a,{display:"flex",justifyContent:"space-between",flexDirection:"column",style:{color:"#2B2C46"},gridGap:8},S.CTAButtonText&&a.a.createElement(On.a,{className:"text-f12 max-line-1 fw-700",style:{color:"#2B2C46",marginTop:8}},ar(u[S.field.productName],45)),a.a.createElement(h.a,{display:"flex",justifyContent:"space-between",flexDirection:"row",style:{color:"#2B2C46",marginTop:8},gridGap:8},a.a.createElement(Jn.a,{title:z,placement:"top",arrow:!0,disableHoverListener:(null===z||void 0===z?void 0:z.length)<19||!z},a.a.createElement(On.a,{className:"text-f12 max-line-1 fw-400",style:{color:"#2B2C46"}},ar(z,S.warehouseVariant?Z?17:20:29))),S.warehouseVariant&&a.a.createElement(On.a,{className:"text-f12 max-line-1 fw-400",style:{color:"#2B2C46"}},a.a.createElement("span",{style:{color:u[S.field.warehouseStockValue]?"#00C070":"#c54545",fontWeight:600}},u[S.field.warehouseStockValue]||0))),a.a.createElement(h.a,{display:"flex",justifyContent:"space-between",flexDirection:"row",style:{color:"#2B2C46"},gridGap:8},(q||S.brandName)&&a.a.createElement(ho,{title:G("Brand"),value:q||S.brandName,padding:"4px 8px",width:{xs:"49%"}}),Y&&a.a.createElement(ho,{title:G("Mfr. No."),value:Y,padding:"4px 8px",width:{xs:"49%"}})))),S.warehouseVariant&&a.a.createElement(h.a,{display:"flex",justifyContent:"space-between",style:{color:"#2B2C46",marginTop:"8px"},gridGap:10},S.field.warehouseNumber&&a.a.createElement(ho,{title:u[S.field.warehouseNumber],value:u[S.field.warehouseNumberValue]||"N/A",padding:"4px 8px",width:{xs:"49%"}}),S.field.warehouseShelfNumber&&a.a.createElement(ho,{title:u[S.field.warehouseShelfNumber],value:u[S.field.warehouseShelfNumberValue]||"N/A",padding:"4px 8px",width:{xs:"49%"}})),a.a.createElement("div",null,S.CTAButtonText?a.a.createElement(h.a,{style:{boxShadow:"-2px 2px 4px rgba(170, 171, 181, 0.5)",height:40,background:null===(c=S.theme)||void 0===c?void 0:c.primaryColor,borderRadius:4,padding:"0px 8px",marginTop:"8px"},display:"flex",justifyItems:"center",alignItems:"center",justifyContent:"space-between"},a.a.createElement(h.a,{style:{display:"flex",justifyContent:"space-between",width:"100%",padding:0,cursor:U?"pointer":"normal"},onClick:function(){U&&(no(k,w,u.sku),window.open("".concat(U),"_blank"))}},a.a.createElement(On.a,{className:"text-white max-line-2",style:{overflow:"hidden",textOverflow:"ellipsis",fontWeight:500,fontSize:"12px",letterSpacing:"0.27px",wordBreak:"break-all",maxWidth:!Z&&U?"136px":"164x",paddingRight:"8px"},align:"left"},S.CTAButtonText),!Z&&U&&a.a.createElement("img",{src:ma.a,alt:"more-info",width:16}))):a.a.createElement(Jn.a,{title:u[S.field.productName],placement:"top",arrow:!0,disableHoverListener:(null===(i=u[S.field.productName])||void 0===i?void 0:i.length)<45},a.a.createElement(h.a,{style:{boxShadow:"-2px 2px 4px rgba(170, 171, 181, 0.5)",height:40,background:null===(l=S.theme)||void 0===l?void 0:l.primaryColor,borderRadius:4,padding:"0px 8px",marginTop:"8px"},display:"flex",justifyItems:"center",alignItems:"center",justifyContent:"space-between"},a.a.createElement(h.a,{style:{display:"flex",justifyContent:"space-between",width:"100%",padding:0,cursor:U?"pointer":"normal"},onClick:function(){U&&(no(k,w,u.sku),window.open("".concat(U),"_blank"))}},a.a.createElement(On.a,{className:"text-white max-line-2",style:{overflow:"hidden",textOverflow:"ellipsis",fontWeight:500,fontSize:"12px",letterSpacing:"0.27px",wordBreak:"break-all",maxWidth:!Z&&U?"136px":"164x",paddingRight:"8px"},align:"left"},ar(u[S.field.productName],45)),!Z&&U&&a.a.createElement("img",{src:ma.a,alt:"more-info",width:16})))),S.showFeedbackAndShare&&a.a.createElement(h.a,{className:"box-bottom",style:{marginBottom:6,marginTop:12}},a.a.createElement(ca.a,{container:!0,justifyContent:S.shareOption?"space-between":"space-around",alignItems:"center"},a.a.createElement(ca.a,{item:!0},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement(Ce.a,{className:"btn-item",onClick:function(){v("like"),V("like")}},a.a.createElement(_a,{width:16,height:16,color:"like"===A?"#3E36DC":"#000000"})))),a.a.createElement(ca.a,{item:!0},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement(Ce.a,{className:"btn-item",onClick:function(){v("dislike"),V("dislike")}},a.a.createElement(ka,{width:16,height:16,color:"dislike"===A?"#CC1854":"#000000"})))),S.shareOption&&a.a.createElement(ca.a,{item:!0},a.a.createElement(h.a,{display:"flex",alignItems:"center"},a.a.createElement(Ce.a,{className:"btn-item",onClick:function(){return H(!0)}},a.a.createElement(wa,{width:16,height:16,color:"#000000"})))))))))})),So=function(e){var t=e.allSearchResults,n=e.isSearchStalled,a=we((function(e){return e})),o=a.search,i=a.settings,l=o||{},c=l.valueTextSearch,u=l.results,s=i||{},d=s.showGroup,h=s.algolia,m=Object(r.useState)([]),g=Object(p.a)(m,2),v=g[0],y=g[1],b=Object(r.useState)(!1),x=Object(p.a)(b,2),w=x[0],C=x[1],E=Object(r.useState)({}),O=Object(p.a)(E,2),j=O[0],L=O[1];Object(r.useEffect)((function(){var e;if(null===t||void 0===t||null===(e=t.hits)||void 0===e?void 0:e.length){C(!1);var n=d?function(e){var t,n=[],r=[],a=e.map((function(e){return e.group_id?e:Object(f.a)(Object(f.a)({},e),{},{group_id:Object(He.uniqueId)("random-group-id")})})),o=Object(He.groupBy)(a,"group_id");return L(o),0===(null===(t=n=Object.values(o))||void 0===t?void 0:t.length)?e:(n.forEach((function(e){var t;(null===e||void 0===e?void 0:e.length)>=2?(t=Object(f.a)(Object(f.a)({},e[0]),{},{isGroup:!0,collap:!0}),r.push(t)):(t=Object(f.a)(Object(f.a)({},e[0]),{},{isGroup:!1,collap:null}),r.push(t))})),r)}(null===t||void 0===t?void 0:t.hits):null===t||void 0===t?void 0:t.hits;y(n)}else y([])}),[null===t||void 0===t?void 0:t.hits,c]),Object(r.useEffect)((function(){n&&C(!0)}),[n]);var k=Object(r.useMemo)((function(){return null===u||void 0===u?void 0:u.map((function(e){return Object(f.a)(Object(f.a)({},e),{},{main_image_link:e.image||e.images?e.images[0]:""})}))}),[u]);return{productList:(null===h||void 0===h?void 0:h.enabled)?v:k||[],handlerGroupItem:function(e,t){var n=e.group_id,r=Object(vn.a)(v),a=r.slice(0,t+1);a.filter((function(e){return e.group_id===n}))[0].collap=!1;var o=r.slice(t+1,r.length),i=Object(vn.a)(j[n]);i.shift(),o=i.concat(o),y(a.concat(o))},handlerCloseGroup:function(e,t){var n=e.group_id,r=Object(vn.a)(v),a=r.slice(0,t+1);a.filter((function(e){return e.group_id===n}))[0].collap=!0;var o=r.slice(t+1,r.length);o=o.filter((function(e){return e.group_id!==n})),y(a.concat(o))},algoliaRequest:w,isLoading:!1,hasError:!1,errorMessage:"",loadProductList:function(){},reset:function(){}}};var Ro,No=Object(Pt.a)(Object(r.memo)((function(e){var t=e.allSearchResults,n=e.getUrlToCanvasFile,o=e.sendFeedBackAction,i=e.moreInfoText,l=e.searchQuery,c=e.requestImage,u=e.isSearchStalled,s=we((function(e){return e})),f=s.search,d=s.settings,p=f.loadingSearchAlgolia,g=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),v=Object(Qt.b)().t,y=So({allSearchResults:t}),b=y.productList,x=y.handlerCloseGroup,w=y.handlerGroupItem,C=y.algoliaRequest,E=Object(r.useMemo)((function(){return c||f.valueTextSearch.query||l||u?0!==b.length||p||u?b.map((function(e,t){return a.a.createElement(h.a,{key:t,style:{height:"fit-content"}},a.a.createElement(ko,{dataItem:e,indexItem:t,isHover:!1,onSearchImage:function(e){n(e)},handlerFeedback:function(e){o(e)},handlerGroupItem:function(e,t){return w(e,t)},handlerCloseGroup:function(e,t){return x(e,t)},isGroupItem:!!d.showGroup&&(null===e||void 0===e?void 0:e.isGroup),moreInfoText:i,main_image_link:e["image(main_similarity)"]||e.main_image_link}))})):a.a.createElement(h.a,{style:{marginTop:"50px",width:"100%",textAlign:"center"}},v("No products were found matching your search criteria.")):a.a.createElement(h.a,{style:{marginTop:"50px",width:"100%",textAlign:"center"}},v("Please upload an image or enter a keyword to search."))}),[b,l,c,f.valueTextSearch,u,C,p,g]);return a.a.createElement(a.a.Fragment,null,E)}))),Io=n(938),Mo=n(932),_o=n(933),Fo=function(e,t){var n=t||{x1:0,x2:1,y1:0,y2:1};if(!e)return null;var r=Object(Ve.getElementSize)(e),a=Object(Ve.getRectAspectRatio)(n,r),o=Object(Ve.getThumbSizeArea)(600,600,a);return Object(Ve.elementToCanvas)(e,o,n)},To=n(192),Ho=n(43),Po=n(44),Bo=n(101),Ao=n.n(Bo),Vo=function(){function e(){Object(Ho.a)(this,e)}return Object(Po.a)(e,null,[{key:"success",value:function(e){Ao.a.success(e,{duration:3e3,style:{background:"#1E1F31",color:"#fff"}})}},{key:"error",value:function(e){Ao.a.error(e,{duration:3e3,style:{background:"#1E1F31",color:"#fff"}})}}]),e}(),Go=n(922),zo=["svgRef","title"];function Do(){return(Do=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function qo(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Zo=function(e){var t=e.svgRef,n=e.title,r=qo(e,zo);return a.a.createElement("svg",Do({width:20,height:20,viewBox:"0 0 20 20",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,Ro||(Ro=a.a.createElement("path",{d:"M10 0.000191037C8.68453 -0.0079651 7.38053 0.245119 6.16361 0.744768C4.94669 1.24442 3.84108 1.98069 2.91088 2.91088C1.98069 3.84108 1.24442 4.94669 0.744768 6.16361C0.245119 7.38053 -0.0079651 8.68453 0.000191037 10C-0.0079651 11.3155 0.245119 12.6195 0.744768 13.8364C1.24442 15.0533 1.98069 16.1589 2.91088 17.0891C3.84108 18.0193 4.94669 18.7556 6.16361 19.2552C7.38053 19.7549 8.68453 20.008 10 19.9998C11.3155 20.008 12.6195 19.7549 13.8364 19.2552C15.0533 18.7556 16.1589 18.0193 17.0891 17.0891C18.0193 16.1589 18.7556 15.0533 19.2552 13.8364C19.7549 12.6195 20.008 11.3155 19.9998 10C20.008 8.68453 19.7549 7.38053 19.2552 6.16361C18.7556 4.94669 18.0193 3.84108 17.0891 2.91088C16.1589 1.98069 15.0533 1.24442 13.8364 0.744768C12.6195 0.245119 11.3155 -0.0079651 10 0.000191037ZM13.8891 14.9999L5.0001 6.11129L6.11129 5.0001L14.9999 13.8891L13.8891 14.9999Z",fill:"#E31B5D"})))},Wo=a.a.forwardRef((function(e,t){return a.a.createElement(Zo,Do({svgRef:t},e))}));n.p;function Uo(){Uo=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var Yo=/.+\@.+\..+$/,Ko=function(e){switch(e.status){case 400:return"Your email could not be sent, please try again or send an email to support@nyris.io";case 421:case 450:case 451:case 452:return"Email delivery failed. Rest assured, we're continuously attempting to send it for you. Alternatively, you can forward the email to support@nyris.io";default:return"Your email could not be sent, please try again or send an email to support@nyris.io"}};function Qo(e){var t,n=e.requestImage,o=e.selectedRegion,i=e.setIsRfqModalOpen,l=e.isRfqModalOpen,c=e.setRfqStatus,u=Object(r.useState)(""),s=Object(p.a)(u,2),f=s[0],h=s[1],g=Object(r.useState)(void 0),v=Object(p.a)(g,2),y=v[0],b=v[1],x=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),w=we((function(e){return e})).settings,C=Object(r.useState)(""),E=Object(p.a)(C,2),O=E[0],j=E[1],L=a.a.useCallback((function(e){j(e.slice(0,150))}),[j]);Object(r.useEffect)((function(){return To.a.init("SMGihPnuEGcYLm0V4")}),[]),Object(r.useEffect)((function(){f&&(Yo.test(f)?b(!0):b(!1))}),[f]);var k=function(){var e=Object(d.a)(Uo().mark((function e(t){var r,l,u,s;return Uo().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.preventDefault(),l=n.canvas,u=Fo(l,o),"service_zfsxshi",i(!1),!(s=null===(r=w.rfq)||void 0===r?void 0:r.emailTemplateId)){e.next=20;break}return e.prev=7,c("loading"),e.next=11,To.a.send("service_zfsxshi",s,{email_id:f.trim(),information_text:O,request_image:null===u||void 0===u?void 0:u.toDataURL()});case 11:c("sent"),Vo.success("Request sent successfully"),e.next=19;break;case 15:e.prev=15,e.t0=e.catch(7),c("inactive"),Ao()((function(t){return a.a.createElement("div",{style:{display:"flex",flexDirection:"column",fontSize:"14px",width:"294px"}},a.a.createElement("span",{style:{fontWeight:"bold"}},"Email not sent"),a.a.createElement("span",null,Ko(e.t0)),a.a.createElement("a",{href:"mailto:support@nyris.io?subject=Request for quotation&body=".concat(O),style:{padding:"8px 16px 8px 16px",border:"1px solid #000",marginTop:"16px",backgroundColor:"transparent",color:"#000",cursor:"pointer",width:"fit-content"}},"support@nyris.io"))}),{duration:5e3,style:{background:"#FFE5EF",color:"#000000",maxWidth:"400px"},icon:a.a.createElement("div",{style:{minWidth:"20px",minHeight:"20px"}},a.a.createElement(Wo,null))});case 19:i(!1);case 20:case"end":return e.stop()}}),e,null,[[7,15]])})));return function(t){return e.apply(this,arguments)}}();return a.a.createElement(kt,{openModal:l,handleClose:function(e){i(!1)}},a.a.createElement("div",{style:{display:"flex",width:x?"360px":"378px",flexDirection:"column",backgroundColor:"#fff"}},a.a.createElement("div",{style:{padding:"16px",display:"flex",flexDirection:"column"}},a.a.createElement(Ie.a,{style:{fontSize:16,color:"black",alignSelf:"flex-end",cursor:"pointer"},onClick:function(){return i(!1)}}),a.a.createElement("p",{style:{color:"#2B2C46",fontSize:"20px",fontWeight:"bold"}},"Submit your image for quotation")),a.a.createElement("div",{style:{padding:"16px",backgroundColor:"#F3F3F5",display:"flex",justifyContent:"center"}},a.a.createElement("img",{src:null===(t=Fo(null===n||void 0===n?void 0:n.canvas,o))||void 0===t?void 0:t.toDataURL(),alt:"request_image",style:{maxHeight:"200px"}})),a.a.createElement("div",{style:{padding:"0px 16px 16px 16px",backgroundColor:"#F3F3F5",display:"flex",flexDirection:"column",rowGap:"16px"}},a.a.createElement("div",null,a.a.createElement("p",{style:{fontSize:"12px",color:"#2B2C46",marginBottom:"8px"}},"Your email (required)"),a.a.createElement("input",{value:f,onChange:function(e){return h(e.currentTarget.value.trim())},style:{width:"100%",border:"none",height:"32px",padding:"8px 16px 8px 16px"}}),!y&&!Object(He.isUndefined)(y)&&a.a.createElement("p",{style:{color:"red",fontSize:"12px",paddingTop:"8px"}},"Please enter a valid email.")),a.a.createElement("div",null,a.a.createElement("div",{style:{marginBottom:"8px",display:"flex",justifyContent:"space-between",fontSize:"12px",color:"#2B2C46"}},a.a.createElement("p",null,"Additional information"),a.a.createElement("p",null,"".concat(O.length,"/150"))),a.a.createElement(Go.a,{value:O,onChange:function(e){return L(e.currentTarget.value)},style:{width:"100%",border:"none",maxWidth:"346px",padding:"8px 16px 8px 16px"}}))),a.a.createElement("div",{style:{display:"flex"}},a.a.createElement("button",{style:{height:"66px",display:"flex",alignItems:"center",width:"50%",backgroundColor:"#4B4B4A",color:"white",fontSize:"14px",paddingLeft:"16px",border:"none",cursor:"pointer"},onClick:function(){return i(!1)}},"Cancel"),a.a.createElement("button",{style:{height:"66px",display:"flex",alignItems:"center",width:"50%",backgroundColor:y?"#4DBE51":"#E9E9EC",color:y?"#fff":"#AAABB5",fontSize:"14px",paddingLeft:"16px",border:"none",cursor:y?"pointer":"normal"},disabled:!y,onClick:k},"Send"))))}var Jo=n(277),Xo=n(498),$o=n.n(Xo),ei=n(499),ti=n.n(ei);var ni,ri=function(e){var t=e.setImageSelection,n=e.imageSelection,o=e.debouncedOnImageSelectionChange,i=e.filteredRegions,l=e.showAdjustInfoBasedOnConfidence,c=e.showAdjustInfo,u=e.showPostFilter,s=e.disjunctiveFacets,f=Object(Qt.b)().t,d=Object(r.useState)(!1),m=Object(p.a)(d,2),g=m[0],v=m[1],y=we((function(e){return e})),b=y.search,x=y.settings,w=b.requestImage;return a.a.createElement(h.a,{className:"wrap-main-col-left ".concat(g?"toggle":""),style:{display:"flex",flexDirection:"column",justifyContent:"space-between"}},a.a.createElement(h.a,{className:"box-toggle-coloumn",style:{right:w||g?"0px":"16px"}},a.a.createElement(Ce.a,{style:{color:"#55566b",height:"32px"},onClick:function(){v(!g)}},g?a.a.createElement($o.a,null):a.a.createElement(ti.a,null))),a.a.createElement(h.a,null,x.preview&&w&&a.a.createElement(h.a,{className:"col-left"},a.a.createElement(h.a,{className:"box-preview"},a.a.createElement(h.a,{className:"preview-item",style:{backgroundColor:"white",paddingTop:"32px",width:"100%"}},a.a.createElement("div",{style:{backgroundColor:"#F3F3F5",width:"100%",paddingTop:"16px",paddingBottom:"16px"}},a.a.createElement(Jo.Preview,{key:null===w||void 0===w?void 0:w.id,onSelectionChange:function(e){t(e),o(e)},image:null===w||void 0===w?void 0:w.canvas,selection:n||G,regions:i,maxWidth:288,maxHeight:288,dotColor:"#FBD914",minCropWidth:60,minCropHeight:60,rounded:!0})))),(l||c)&&a.a.createElement(h.a,{className:"box-title_col-left",alignItems:"center",style:{backgroundColor:"#3E36DC",display:"flex",columnGap:"6px",padding:"5px"}},a.a.createElement(lt,{color:"white"}),a.a.createElement(On.a,{style:{fontSize:10,color:"#fff"}},c?f("Crop the image for better results"):"Crop the image for better results"))),u&&a.a.createElement(h.a,{className:"col-left__bottom"},a.a.createElement(Kn,{disjunctiveFacets:s}))))},ai=function(e,t){return Object(r.useMemo)((function(){return e.map((function(e){var n,r,a,o;return(null===(n=e.normalizedRect)||void 0===n?void 0:n.x1)===(null===t||void 0===t?void 0:t.x1)&&(null===(r=e.normalizedRect)||void 0===r?void 0:r.x2)===(null===t||void 0===t?void 0:t.x2)&&(null===(a=e.normalizedRect)||void 0===a?void 0:a.y1)===(null===t||void 0===t?void 0:t.y1)&&(null===(o=e.normalizedRect)||void 0===o?void 0:o.y2)===(null===t||void 0===t?void 0:t.y2)||0===(null===t||void 0===t?void 0:t.x1)&&1===(null===t||void 0===t?void 0:t.x2)&&0===(null===t||void 0===t?void 0:t.y1)&&1===(null===t||void 0===t?void 0:t.y2)?Object(f.a)(Object(f.a)({},e),{},{show:!1}):Object(f.a)(Object(f.a)({},e),{},{show:!0})}))}),[e,t])},oi=n(928),ii=["svgRef","title"];function li(){return(li=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function ci(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ui,si=function(e){var t=e.svgRef,n=e.title,r=ci(e,ii);return a.a.createElement("svg",li({width:16,height:16,viewBox:"0 0 16 16",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,ni||(ni=a.a.createElement("path",{d:"M8.65944 6.57845C8.28211 6.24747 7.71789 6.24747 7.34056 6.57845L3.3956 10.0389C3.18599 10.2228 3.18599 10.5491 3.3956 10.733C3.56978 10.8858 3.83022 10.8858 4.0044 10.733L7.34056 7.80652C7.71789 7.47554 8.28211 7.47554 8.65944 7.80652L11.9956 10.733C12.1698 10.8858 12.4302 10.8858 12.6044 10.733C12.814 10.5491 12.814 10.2228 12.6044 10.0389L8.65944 6.57845Z",fill:"currentColor"})))},fi=a.a.forwardRef((function(e,t){return a.a.createElement(si,li({svgRef:t},e))})),di=(n.p,["svgRef","title"]);function pi(){return(pi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function hi(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var mi,gi=function(e){var t=e.svgRef,n=e.title,r=hi(e,di);return a.a.createElement("svg",pi({width:16,height:16,viewBox:"0 0 16 16",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,ui||(ui=a.a.createElement("path",{d:"M8.65944 10.4215C8.28211 10.7525 7.71789 10.7525 7.34056 10.4215L3.3956 6.96105C3.18599 6.77719 3.18599 6.45088 3.3956 6.26702C3.56978 6.11423 3.83022 6.11423 4.0044 6.26702L7.34056 9.19348C7.71789 9.52446 8.28211 9.52446 8.65944 9.19348L11.9956 6.26702C12.1698 6.11423 12.4302 6.11423 12.6044 6.26702C12.814 6.45088 12.814 6.77719 12.6044 6.96105L8.65944 10.4215Z",fill:"#currentColor"})))},vi=a.a.forwardRef((function(e,t){return a.a.createElement(gi,pi({svgRef:t},e))})),yi=(n.p,["svgRef","title"]);function bi(){return(bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function xi(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var wi=function(e){var t=e.svgRef,n=e.title,r=xi(e,yi);return a.a.createElement("svg",bi({width:14,height:14,viewBox:"0 0 14 14",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,mi||(mi=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 0.5C9 0.223858 8.77614 0 8.5 0H5.5C5.22386 0 5 0.223858 5 0.5C5 0.776142 5.22386 1 5.5 1H8.5C8.77614 1 9 0.776142 9 0.5ZM1.5 3C1.22386 3 1 2.77614 1 2.5C1 2.22386 1.22386 2 1.5 2H12.5C12.7761 2 13 2.22386 13 2.5C13 2.77614 12.7761 3 12.5 3C12.2239 3 12 3.22386 12 3.5V13C12 13.5523 11.5523 14 11 14H3C2.44772 14 2 13.5523 2 13V3.5C2 3.22386 1.77614 3 1.5 3ZM4 3C3.44772 3 3 3.44772 3 4V12C3 12.5523 3.44772 13 4 13H10C10.5523 13 11 12.5523 11 12V4C11 3.44772 10.5523 3 10 3H4ZM6 5.5C6 5.22386 5.77614 5 5.5 5C5.22386 5 5 5.22386 5 5.5V10.5C5 10.7761 5.22386 11 5.5 11C5.77614 11 6 10.7761 6 10.5V5.5ZM9 5.5C9 5.22386 8.77614 5 8.5 5C8.22386 5 8 5.22386 8 5.5V10.5C8 10.7761 8.22386 11 8.5 11C8.77614 11 9 10.7761 9 10.5V5.5Z",fill:"currentColor"})))},Ci=a.a.forwardRef((function(e,t){return a.a.createElement(wi,bi({svgRef:t},e))})),Ei=(n.p,["requestImage","imageSelection","setImageSelection","debouncedOnImageSelectionChange","filteredRegions","showAdjustInfo","showAdjustInfoBasedOnConfidence"]);var Oi=Object(Ht.a)(Object(r.memo)((function(e){var t,n,o,i=e.requestImage,l=e.imageSelection,c=e.setImageSelection,u=e.debouncedOnImageSelectionChange,d=e.filteredRegions,m=e.showAdjustInfo,g=e.showAdjustInfoBasedOnConfidence,v=Object(mn.a)(e,Ei),y=Object(Qt.b)().t,b=v.refine,x=Object(r.useState)(!1),w=Object(p.a)(x,2),C=w[0],E=w[1],O=Object(r.useState)(!1),j=Object(p.a)(O,2),L=j[0],k=j[1],S=we((function(e){return e.settings})),R=we((function(e){return e.search})).preFilter,N=null===(t=S.algolia)||void 0===t?void 0:t.enabled,I=Kt(),M=xe(),_=Object(s.f)(),F=function(){E((function(e){return!e})),k(!0)},T=I.get("query")||"",H=function(){if(T||(M(J("")),_.push("/")),M(J("")),N&&setTimeout((function(){b(T)}),100),!N){var e,t=[],n=[{key:S.visualSearchFilterKey,values:Object.keys(R)}];T||i?(M(fe(!0)),We({settings:S,filters:Object(He.isEmpty)(R)?void 0:n,text:T}).then((function(n){null===n||void 0===n||n.results.map((function(e){t.push({sku:e.sku,score:e.score})})),e=Object(f.a)(Object(f.a)({},n),{},{filters:t}),M(ie(e)),M(fe(!1))})).catch((function(e){console.log("error input search",e),M(fe(!1))}))):M(ie([]))}};return a.a.createElement(h.a,{className:"col-left",style:{backgroundColor:"#5D5D63",marginBottom:"15px"}},C&&a.a.createElement("div",null,a.a.createElement(h.a,{className:"box-preview"},a.a.createElement(h.a,{className:"preview-item expand-animation",style:{backgroundColor:"transparent"}},a.a.createElement(Jo.Preview,{key:null===i||void 0===i?void 0:i.id,onSelectionChange:function(e){c(e),u(e)},image:null===i||void 0===i?void 0:i.canvas,selection:l||G,regions:d,maxWidth:240,maxHeight:240,dotColor:"#FBD914",minCropWidth:60,minCropHeight:60,rounded:!1,expandAnimation:!0})),(g||m)&&a.a.createElement(h.a,{className:"box-title_col-left",alignItems:"center",style:{backgroundColor:"#3E36DC",display:"flex",columnGap:"6px",padding:"5px",width:"fit-content"}},a.a.createElement(lt,{color:"white"}),a.a.createElement(On.a,{style:{fontSize:10,color:"#fff"}},m?y("Crop the image for better results"):"Crop the image for better results"))),a.a.createElement(oi.a,null,a.a.createElement(h.a,{sx:{position:"absolute",left:"15px",top:"25px",padding:"4px"},onClick:H},a.a.createElement(h.a,{sx:{width:"24px",height:"24px",justifyContent:"center",alignItems:"center",display:"flex",borderRadius:"100%"}},a.a.createElement(Ci,{color:"white",fill:"white"})))),a.a.createElement(oi.a,{mdUp:!0},a.a.createElement(h.a,{className:"slideDown",sx:{position:"absolute",bottom:"25px",right:"20px"},onClick:F},a.a.createElement(h.a,{bgcolor:"white",sx:{width:"24px",height:"24px",justifyContent:"center",alignItems:"center",display:"flex",borderRadius:"100%"}},a.a.createElement(fi,{color:"black"}))))),!C&&a.a.createElement(h.a,{className:L?"shrink-animation":"",sx:{display:"flex",alignItems:"center",justifyContent:"center",height:80,width:"100%"}},a.a.createElement(oi.a,null,a.a.createElement(h.a,{sx:{position:"absolute",left:"15px",top:"25px",padding:"4px"},onClick:H},a.a.createElement(h.a,{sx:{width:"24px",height:"24px",justifyContent:"center",alignItems:"center",display:"flex",borderRadius:"100%"}},a.a.createElement(Ci,{color:"white",fill:"white"})))),a.a.createElement(h.a,{sx:{display:"flex",height:"100%",width:"100%",justifyContent:"center",alignItems:"center"},onClick:F},i&&(null===i||void 0===i||null===(n=i.canvas)||void 0===n?void 0:n.toDataURL)&&a.a.createElement("img",{src:null===i||void 0===i||null===(o=i.canvas)||void 0===o?void 0:o.toDataURL(),style:{width:"80px",height:"80px",objectFit:"contain",background:"white"},alt:"preview"}),a.a.createElement("div",{className:L?"shrink-animation circle-layer":"circle-layer"})),a.a.createElement(oi.a,{mdUp:!0},a.a.createElement(h.a,{sx:{position:"absolute",right:"25px",padding:"4px"},onClick:F},a.a.createElement(h.a,{bgcolor:"white",className:L?"slideUp":"",sx:{width:"24px",height:"24px",justifyContent:"center",alignItems:"center",display:"flex",borderRadius:"100%"}},a.a.createElement(vi,{color:"black",fill:"black"}))))))})));var ji=function(e){var t,n=e.requestImage,r=(e.rfqRef,e.rfqStatus),o=e.selectedRegion,i=e.setIsRfqModalOpen,l=Object(m.useMediaQuery)({query:"(max-width: 776px)"});return a.a.createElement(h.a,{style:{padding:"0px 16px 0px 16px",backgroundColor:"#F6F3F1",width:"100%",marginBottom:l?"0px":"32px",alignSelf:"end",height:"248px",display:"flex",alignItems:"center"},className:"rfq-box"},a.a.createElement(h.a,{style:{width:"100%",display:"flex",columnGap:"16px",alignItems:"center",justifyContent:"space-around"}},a.a.createElement("div",null,a.a.createElement("img",{src:null===(t=Fo(null===n||void 0===n?void 0:n.canvas,o))||void 0===t?void 0:t.toDataURL(),alt:"request_image",style:{mixBlendMode:"inactive"!==r?"overlay":"unset",maxHeight:"181px",maxWidth:"181px",borderRadius:"2px"}})),a.a.createElement(h.a,null,a.a.createElement(h.a,{style:{paddingBottom:"12px"}},a.a.createElement(h.a,{style:{fontSize:"14px",color:"inactive"===r?"#4B4B4A":"#CACAD1",fontWeight:"bold"}},l?"No matches found?":"No matches found for your request?"),a.a.createElement(h.a,{style:{fontSize:"12px",maxWidth:"320x",lineHeight:"14.1px",color:"inactive"===r?"#4B4B4A":"#CACAD1",fontWeight:"normal"}},"Get personalised help from our team of product experts.")),a.a.createElement("button",{style:{maxWidth:"200px",background:"inactive"===r?"#4B4B4A":"#E9E9EC",boxShadow:"inactive"===r?"0px 0px 4px 0px rgba(0, 0, 0, 0.25)":"",borderRadius:"2px",padding:"16px 16px 16px 16px",display:"flex",alignItems:"center",color:"inactive"===r?"#fff":"#CACAD1",fontSize:"14px",height:"48px",cursor:"inactive"===r?"pointer":"default",border:"none"},disabled:"inactive"!==r,onClick:function(){i(!0)}},"Request a Quote"))))};function Li(){Li=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var ki,Si=/.+\@.+\..+$/,Ri=function(e){switch(e.status){case 400:return"Your email could not be sent, please try again or send an email to:";case 421:case 450:case 451:case 452:return"Email delivery failed. Rest assured, we're continuously attempting to send it for you. Alternatively, you can forward the email to:";default:return"Your email could not be sent, please try again or send an email to:"}};function Ni(e){var t,n,o=e.requestImage,i=e.selectedRegion,l=e.setIsInquiryModalOpen,c=e.isInquiryModalOpen,u=we((function(e){return e})),s=u.search.preFilter,f=u.settings,h=Object.keys(s),g=Object(r.useState)(""),v=Object(p.a)(g,2),y=v[0],b=v[1],x=Object(r.useState)(void 0),w=Object(p.a)(x,2),C=w[0],E=w[1],O=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),j=Object(r.useState)(""),L=Object(p.a)(j,2),k=L[0],S=L[1],R=a.a.useCallback((function(e){S(e.slice(0,150))}),[S]);Object(r.useEffect)((function(){return To.a.init("SMGihPnuEGcYLm0V4")}),[]),Object(r.useEffect)((function(){y&&(Si.test(y)?E(!0):E(!1))}),[y]);var N=function(){var e=Object(d.a)(Li().mark((function e(t){var n,r,c,u;return Li().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.preventDefault(),r=(o||{}).canvas,c=r?Fo(r,i):null,"service_zfsxshi",l(!1),!(u=null===(n=f.support)||void 0===n?void 0:n.emailTemplateId)){e.next=17;break}return e.prev=7,e.next=10,To.a.send("service_zfsxshi",u,{email_id:y.trim(),information_text:k||"<not specified>",request_image:null===c||void 0===c?void 0:c.toDataURL(),prefilter_values:(null===h||void 0===h?void 0:h.length)?h.join(", "):"<not specified>"});case 10:Vo.success("Request sent successfully"),e.next=16;break;case 13:e.prev=13,e.t0=e.catch(7),Ao()((function(t){return a.a.createElement("div",{style:{display:"flex",flexDirection:"column",fontSize:"14px",width:"294px"}},a.a.createElement("span",{style:{fontWeight:"bold"}},"Email not sent"),a.a.createElement("span",null,Ri(e.t0)),a.a.createElement("a",{href:"mailto:support@nyris.io?subject=Request for quotation&body=".concat(encodeURIComponent("Hello,\n I filled out the support form on the Search Suite, but it failed. I inquired the following:\n email:\n Pre-filter:\n Additional Text: ")),style:{padding:"8px 16px 8px 16px",border:"1px solid #000",marginTop:"16px",backgroundColor:"transparent",color:"#000",cursor:"pointer",width:"fit-content"}},"support@nyris.io"))}),{duration:5e3,style:{background:"#FFE5EF",color:"#000000",maxWidth:"400px"},icon:a.a.createElement("div",{style:{minWidth:"20px",minHeight:"20px"}},a.a.createElement(Wo,null))});case 16:l(!1);case 17:case"end":return e.stop()}}),e,null,[[7,13]])})));return function(t){return e.apply(this,arguments)}}();return a.a.createElement(kt,{openModal:c,rounded:!1,handleClose:function(e){l(!1)}},a.a.createElement("div",{style:{display:"flex",width:O?"360px":"378px",flexDirection:"column",backgroundColor:"#F3F3F5"}},a.a.createElement("div",{style:{padding:"16px",display:"flex",alignItems:"center",justifyContent:"space-between"}},a.a.createElement("p",{style:{color:"#2B2C46",fontSize:O?"18px":"20px",fontWeight:"bold"}},o?"Submit your image for inquiry":"Submit your inquiry"),a.a.createElement("div",{onClick:function(){return l(!1)},style:{display:"flex",padding:"1px"}},a.a.createElement(Ie.a,{style:{fontSize:16,color:"black",cursor:"pointer"}}))),o&&a.a.createElement("div",{style:{padding:"16px",backgroundColor:"#F3F3F5",display:"flex",justifyContent:"center"}},a.a.createElement("img",{src:null===(t=Fo(null===o||void 0===o?void 0:o.canvas,i))||void 0===t?void 0:t.toDataURL(),alt:"request_image",style:{maxHeight:"200px"}})),a.a.createElement("div",{style:{padding:"16px 16px 16px 16px",backgroundColor:"#F3F3F5",display:"flex",flexDirection:"column",rowGap:"16px"}},a.a.createElement("div",null,a.a.createElement("p",{style:{fontSize:"12px",color:"#2B2C46",marginBottom:"8px"}},"Your email (required)"),a.a.createElement("input",{value:y,onChange:function(e){return b(e.currentTarget.value.trim())},style:{width:"100%",border:"none",height:"32px",padding:"8px 16px 8px 16px",fontSize:"13px",color:" #2B2C46"}}),!C&&!Object(He.isUndefined)(C)&&a.a.createElement("p",{style:{color:"red",fontSize:"12px",paddingTop:"8px"}},"Please enter a valid email.")),f.preFilterOption&&a.a.createElement("div",null,a.a.createElement("div",{style:{display:"flex",columnGap:"4px",alignItems:"center",marginBottom:"8px"}},a.a.createElement("p",{style:{fontSize:"12px",color:"#2B2C46"}},"Machine"),a.a.createElement(Jn.a,{title:"Please select a pre-filter before search request to refine and yield accurate results.",placement:"top",arrow:!0},a.a.createElement(lt,{style:{cursor:"pointer"}}))),a.a.createElement("div",{style:{width:"100%",border:"none",padding:"8px 16px 8px 16px",fontSize:"13px",color:"#2B2C46",minHeight:"32px",backgroundColor:"#fff"}},h.join(", ")||"Pre-filter is not selected")),a.a.createElement("div",null,a.a.createElement("div",{style:{marginBottom:"8px",display:"flex",justifyContent:"space-between",fontSize:"12px",color:"#2B2C46"}},a.a.createElement("p",null,"Additional information"),a.a.createElement("p",null,"".concat(k.length,"/150"))),a.a.createElement(Go.a,{value:k,onChange:function(e){return R(e.currentTarget.value)},style:{width:"100%",border:"none",maxWidth:"346px",minHeight:"40px",padding:"8px 16px 8px 16px",fontSize:"13px",color:" #2B2C46"}}))),a.a.createElement("div",{style:{display:"flex"}},a.a.createElement("button",{style:{height:"66px",display:"flex",alignItems:"center",width:"50%",backgroundColor:"#2B2C46",color:"white",fontSize:"14px",paddingLeft:"16px",border:"none",cursor:"pointer"},onClick:function(){return l(!1)}},"Cancel"),a.a.createElement("button",{style:{height:"66px",display:"flex",alignItems:"center",width:"50%",backgroundColor:C?null===(n=f.theme)||void 0===n?void 0:n.primaryColor:"#E9E9EC",color:C?"#fff":"#AAABB5",fontSize:"14px",paddingLeft:"16px",border:"none",cursor:C?"pointer":"normal"},disabled:!C,onClick:N},"Send"))))}var Ii=["svgRef","title"];function Mi(){return(Mi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function _i(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Fi,Ti=function(e){var t=e.svgRef,n=e.title,r=_i(e,Ii);return a.a.createElement("svg",Mi({width:17,height:12,viewBox:"0 0 17 12",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,ki||(ki=a.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.6888 0C16.0047 0 16.2931 0.192151 16.4241 0.489651C16.4738 0.593965 16.5 0.711618 16.5 0.830018V11.1561C16.5 11.2133 16.494 11.2703 16.4821 11.3256C16.4737 11.3686 16.462 11.4111 16.4474 11.4521C16.3285 11.7849 16.0308 12 15.6888 12H1.30961C0.967644 12 0.669889 11.7849 0.551024 11.4521C0.511476 11.3414 0.494785 11.2261 0.501415 11.1094V0.890625C0.494785 0.773926 0.511476 0.658628 0.551024 0.547891C0.669878 0.215062 0.967644 0 1.30961 0H15.6888ZM8.49921 6.90797L15.0048 1.10306H1.99367L8.49921 6.90797ZM5.8515 6L1.56406 9.8257V2.1743L5.8515 6ZM6.66657 6.72729L7.97182 7.89199C8.11913 8.02342 8.30643 8.0958 8.49921 8.0958C8.692 8.0958 8.87929 8.02342 9.02659 7.89199L10.3319 6.7273L15.0048 10.8969H1.99367L6.66657 6.72729ZM15.4374 9.82838L11.1469 6L15.4374 2.17162V9.82838Z",fill:"currentColor"})))},Hi=a.a.forwardRef((function(e,t){return a.a.createElement(Ti,Mi({svgRef:t},e))})),Pi=(n.p,["svgRef","title"]);function Bi(){return(Bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Ai(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Vi=function(e){var t=e.svgRef,n=e.title,r=Ai(e,Pi);return a.a.createElement("svg",Bi({width:14,height:14,viewBox:"0 0 14 14",fill:"none",ref:t},r),n?a.a.createElement("title",null,n):null,Fi||(Fi=a.a.createElement("path",{d:"M12.3849 14H12.2933C1.71255 13.3915 0.210246 4.46385 0.000245939 1.73923C-0.0166751 1.52739 0.00837059 1.31429 0.0739478 1.11214C0.139525 0.909999 0.244345 0.722779 0.382401 0.561213C0.520458 0.399646 0.689038 0.266909 0.878482 0.170606C1.06793 0.0743029 1.27451 0.0163271 1.4864 5.04857e-07H4.45332C4.66901 -0.000208291 4.87979 0.0643519 5.05836 0.185318C5.23693 0.306285 5.37506 0.478084 5.45486 0.678462L6.27332 2.69231C6.35213 2.88806 6.37168 3.10266 6.32956 3.30943C6.28744 3.51621 6.1855 3.70605 6.0364 3.85539L4.88948 5.01308C5.06863 6.03117 5.55619 6.96967 6.28619 7.70159C7.01619 8.43352 7.9534 8.92355 8.97101 9.10538L10.1395 7.94769C10.2911 7.80024 10.4827 7.70067 10.6905 7.66141C10.8983 7.62215 11.113 7.64494 11.3079 7.72692L13.3379 8.54C13.5353 8.62232 13.7037 8.76153 13.8216 8.9399C13.9396 9.11827 14.0018 9.32771 14.0002 9.54154V12.3846C14.0002 12.813 13.8301 13.2239 13.5271 13.5269C13.2242 13.8298 12.8133 14 12.3849 14ZM1.61563 1.07692C1.47282 1.07692 1.33586 1.13365 1.23488 1.23464C1.1339 1.33562 1.07717 1.47258 1.07717 1.61539V1.65846C1.32486 4.84615 2.91332 12.3846 12.3526 12.9231C12.4233 12.9275 12.4942 12.9178 12.5612 12.8947C12.6282 12.8716 12.69 12.8355 12.743 12.7885C12.7961 12.7415 12.8393 12.6845 12.8702 12.6207C12.9012 12.5569 12.9192 12.4877 12.9233 12.4169V9.54154L10.8933 8.72846L9.34794 10.2631L9.08948 10.2308C4.40486 9.64385 3.76948 4.95923 3.76948 4.91077L3.73717 4.65231L5.2664 3.10692L4.45871 1.07692H1.61563Z",fill:"currentColor"})))},Gi=a.a.forwardRef((function(e,t){return a.a.createElement(Vi,Bi({svgRef:t},e))}));n.p;var zi=function(e){var t,n=e.requestImage,o=e.selectedRegion,i=e.query,l=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),c=Object(r.useState)(!1),u=Object(p.a)(c,2),s=u[0],f=u[1],d=Object(r.useState)("inactive"),g=Object(p.a)(d,2),v=g[0],y=g[1];Object(r.useEffect)((function(){y("inactive")}),[o,i]);var b=we((function(e){return e.settings.support}))||{},x=b.description,w=b.emailInquiry,C=b.supportNumber,E=(we((function(e){return e.settings.theme}))||{}).secondaryColor;return a.a.createElement(a.a.Fragment,null,s&&a.a.createElement(Ni,{requestImage:n,selectedRegion:o,setIsInquiryModalOpen:f,isInquiryModalOpen:s}),a.a.createElement(h.a,{style:{backgroundColor:"#F3F3F5",width:"100%",marginBottom:"32px",alignSelf:"end",display:"flex",alignItems:"center",marginRight:"12px"},className:"rfq-box"},a.a.createElement(h.a,{style:{width:"100%",display:"flex",columnGap:l?"16px":"26px",alignItems:"center"}},n&&a.a.createElement("div",null,a.a.createElement("img",{src:null===(t=Fo(null===n||void 0===n?void 0:n.canvas,o))||void 0===t?void 0:t.toDataURL(),alt:"request_image",style:{mixBlendMode:"unset",maxHeight:l?"120px":"181px",maxWidth:l?"120px":"181px",borderRadius:"2px"}})),a.a.createElement(h.a,{style:{width:"100%"}},a.a.createElement(h.a,{style:{paddingBottom:"8px",paddingLeft:"16px"}},a.a.createElement(h.a,{style:{fontSize:"14px",color:"inactive"===v?"#4B4B4A":"#2B2C46",fontWeight:"bold"}},l?"No matches found?":"No matches found for your request?"),a.a.createElement(h.a,{style:{fontSize:"14px",maxWidth:"320x",lineHeight:"16px",color:"inactive"===v?"#4B4B4A":"#2B2C46",fontWeight:"normal"}},x)),a.a.createElement("div",{style:{display:"flex",gap:l?"8px":"16px",width:"100%",maxWidth:"400px"},className:"support-button-wrapper"},w&&a.a.createElement("div",{style:{width:w&&C?"50%":"100%",maxWidth:"170px",minWidth:"86px",background:"inactive"===v?E:"#E9E9EC",boxShadow:"inactive"===v?"0px 0px 4px 0px rgba(0, 0, 0, 0.25)":"",borderRadius:"2px",padding:l?"8px 8px 8px 8px":"8px 16px 8px 16px",display:"flex",alignItems:"center",color:"inactive"===v?"#fff":"#CACAD1",fontSize:"13px",cursor:"inactive"===v?"pointer":"default",border:"none"},onClick:function(){f(!0)}},a.a.createElement("div",{style:{width:"100%",display:"flex",alignItems:"center",justifyContent:"space-between"}},a.a.createElement("p",null,"Inquiry"),a.a.createElement(Hi,{color:"#fff",width:16,height:16}))),C&&a.a.createElement("a",{style:{width:w&&C?"50%":"100%",maxWidth:"170px",minWidth:"86px",background:E,boxShadow:"0px 0px 4px 0px rgba(0, 0, 0, 0.25)",borderRadius:"2px",padding:l?"8px 8px 8px 8px":"8px 16px 8px 16px",display:"flex",alignItems:"center",color:"#fff",fontSize:"13px",cursor:"pointer",border:"none",fontWeight:500},href:"tel:".concat(C)},a.a.createElement("div",{style:{width:"100%",display:"flex",alignItems:"center",justifyContent:"space-between"}},a.a.createElement("p",null," Call us"),a.a.createElement(Gi,{color:"#fff",width:16,height:16}))))))))};var Di=function(e){var t=e.submitFeedback,n=e.onFeedbackClose;return a.a.createElement("div",{className:"feedback-wrapper"},a.a.createElement("p",null,"Are these results useful?"),a.a.createElement("div",{className:"feedback-icon-wrapper",onClick:function(){return t(!1)}},a.a.createElement(ka,null)),a.a.createElement("div",{className:"feedback-icon-wrapper",onClick:function(){return t(!0)}},a.a.createElement(_a,null)),a.a.createElement("div",{className:"feedback-icon-wrapper",onClick:function(){return n()}},a.a.createElement(bt,null)))};function qi(){qi=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},o=a.iterator||"@@iterator",i=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(S){c=function(e,t,n){return e[t]=n}}function u(e,t,n,a){var o=t&&t.prototype instanceof d?t:d,i=Object.create(o.prototype),l=new j(a||[]);return r(i,"_invoke",{value:w(e,n,l)}),i}function s(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(S){return{type:"throw",arg:S}}}e.wrap=u;var f={};function d(){}function p(){}function h(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,v=g&&g(g(L([])));v&&v!==t&&n.call(v,o)&&(m=v);var y=h.prototype=d.prototype=Object.create(m);function b(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function x(e,t){var a;r(this,"_invoke",{value:function(r,o){function i(){return new t((function(a,i){!function r(a,o,i,l){var c=s(e[a],e,o);if("throw"!==c.type){var u=c.arg,f=u.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):t.resolve(f).then((function(e){u.value=e,i(u)}),(function(e){return r("throw",e,i,l)}))}l(c.arg)}(r,o,a,i)}))}return a=a?a.then(i,i):i()}})}function w(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return k()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var l=C(i,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var c=s(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}function C(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void 0,C(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var a=s(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,f;var o=a.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,f):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,f)}function E(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function j(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(E,this),this.reset(!0)}function L(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,a=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return a.next=a}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=h,r(y,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=c(h,l,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,c(e,l,"GeneratorFunction")),e.prototype=Object.create(y),e},e.awrap=function(e){return{__await:e}},b(x.prototype),c(x.prototype,i,(function(){return this})),e.AsyncIterator=x,e.async=function(t,n,r,a,o){void 0===o&&(o=Promise);var i=new x(u(t,n,r,a),o);return e.isGeneratorFunction(n)?i:i.next().then((function(e){return e.done?e.value:i.next()}))},b(y),c(y,l,"Generator"),c(y,o,(function(){return this})),c(y,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=L,j.prototype={constructor:j,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return i.type="throw",i.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],i=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(l&&c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;O(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:L(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},e}var Zi=Object(Pt.a)(Object(r.memo)((function(e){var t,n,o,i,l,c=xe(),u=Object(r.useRef)(null),s=we((function(e){return e})),g=s.search,v=s.settings,y=g.requestImage,b=g.regions,x=g.selectedRegion,w=g.preFilter,C=g.loadingSearchAlgolia,E=g.imageThumbSearchInput,O=null===v||void 0===v?void 0:v.productCtaText,j=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),L=Object(r.useState)(null),k=Object(p.a)(L,2),S=k[0],R=k[1],N=function(){return u.current.scrollIntoView("-100px")},I=Object(r.useState)(),M=Object(p.a)(I,2),_=M[0],F=M[1],T=Object(Qt.b)().t,H=Object(r.useState)(!1),P=Object(p.a)(H,2),B=P[0],A=P[1],V=Object(r.useState)(!1),D=Object(p.a)(V,2),q=D[0],Z=D[1],W=Object(r.useState)("inactive"),U=Object(p.a)(W,2),K=U[0],J=U[1],$=Object(r.useState)(!1),ee=Object(p.a)($,2),ne=ee[0],re=ee[1],ce=Object(r.useRef)(null),ue=Object(r.useRef)(null),de=Object(r.useState)("not-scrolled"),pe=Object(p.a)(de,2),he=pe[0],me=pe[1],ge=Object(r.useState)("not-scrolled"),ve=Object(p.a)(ge,2),ye=ve[0],be=ve[1],Ce=Object(r.useState)(!1),Ee=Object(p.a)(Ce,2),Oe=Ee[0],je=Ee[1],Le=Kt().get("query")||g.valueTextSearch.query,ke=null===(t=v.algolia)||void 0===t?void 0:t.enabled,Se=v.postFilterOption;Object(r.useEffect)((function(){if(!C&&(E.includes("blob:")||E.includes("data:"))&&ce.current!==E){A(!0);var e=setTimeout((function(){A(!1)}),2e3);return ce.current=E,function(){clearTimeout(e),A(!1)}}}),[E,C]),Object(r.useEffect)((function(){x&&(R(x),J("inactive"),me("not-scrolled"),be("not-scrolled"))}),[x]),Object(r.useEffect)((function(){y&&(me("not-scrolled"),be("not-scrolled"),N(),R(G))}),[y]);var Re=Object(r.useCallback)(function(){var e=Object(d.a)(qi().mark((function e(t,n){var r;return qi().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=[{key:v.visualSearchFilterKey,values:Object.keys(w)}],c(Y()),e.abrupt("return",We({image:t,settings:v,region:n,filters:Object(He.isEmpty)(w)?void 0:r}).then((function(e){return c(fe(!1)),Object(f.a)({},e)})).catch((function(e){c(fe(!1)),console.log("error call api change selection find image",e)})));case 3:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),[v,c,w]),Ne=Object(r.useCallback)(Object(He.debounce)(function(){var e=Object(d.a)(qi().mark((function e(t){var n;return qi().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(y){e.next=2;break}return e.abrupt("return");case 2:return c(fe(!0)),n=y.canvas,Re(n,t).then((function(e){c(se(e)),e.results.find((function(e){return e.score>=.65}))||Z(!0),setTimeout((function(){Z(!1)}),2e3)})),e.abrupt("return");case 6:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),250),[y,Re]),Ie=function(){var e=Object(d.a)(qi().mark((function e(t){return qi().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:eo(s,"like"===t);case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),Me=function(){var e=Object(d.a)(qi().mark((function e(t){var n,r,a,o;return qi().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return c(fe(!0)),j&&(N(),c(Q(!1))),c(Y()),c(te(t)),e.next=6,De(t);case 6:if(n=e.sent,c(oe(n)),r=void 0,!v.regions){e.next=16;break}return e.next=12,Ze(n,v);case 12:a=e.sent,r=a.selectedRegion,c(ae(a.regions)),c(le(r));case 16:o=[{key:v.visualSearchFilterKey,values:Object.keys(w)}],We({image:n,settings:v,region:r,filters:Object(He.isEmpty)(w)?void 0:o}).then((function(e){c(ie(e)),c(fe(!1))}));case 18:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),_e=y?["sku:DOES_NOT_EXIST<score=1> "]:[],Fe=(null===g||void 0===g?void 0:g.results)?null===g||void 0===g?void 0:g.results.slice().reverse().map((function(e,t){return"sku:'".concat(e.sku,"'<score=").concat(t,"> ")})):"",Te=[].concat(_e,Object(vn.a)(Fe)).join("OR ");Object(r.useEffect)((function(){if(document.title="Search results",!y&&!Object(He.isEmpty)(Le)){var e=Object.keys(w),t=e.length>0?e.map((function(e){return"".concat(v.alogoliaFilterField,":'").concat(e,"'")})).join(" OR "):"";F(t)}}),[w,y,Le,v.alogoliaFilterField]),Object(r.useEffect)((function(){if(y&&ke){c(fe(!0));var e=y.canvas;return Re(e).then((function(e){c(se(e))})),function(){}}}),[w]),Object(r.useEffect)((function(){if(y){var e=Object.keys(w),t=e.length>0?e.map((function(e){return"".concat(v.alogoliaFilterField,":'").concat(e,"'")})).join(" OR "):"",n=e.length>0?Te?"(".concat(Te,") AND ").concat(t):t:Te;F(n)}}),[Te,v.alogoliaFilterField]);var Pe=Object(r.useCallback)(Object(He.debounce)((function(e){ro(s,e),c(X(e)),Ne(e)}),500),[Ne,s.search]),Be=ai(b,S),Ae=Object(r.useMemo)((function(){var t;return Se&&(null===(t=e.allSearchResults)||void 0===t?void 0:t.hits.length)>0&&ke}),[Se,null===(n=e.allSearchResults)||void 0===n?void 0:n.hits,ke]),Ve=Object(r.useMemo)((function(){return y||Se&&Ae}),[Ae,Se,y]);Object(r.useEffect)((function(){var e=function(){setTimeout((function(){me((function(e){return"not-scrolled"===e?"scrolled":e})),setTimeout((function(){me((function(e){return"scrolled"===e?"user-scrolled":e}))}),5e3)}),1e3)};return y&&window.addEventListener("scroll",e,{capture:!0}),function(){window.removeEventListener("scroll",e)}}),[y]),Object(r.useEffect)((function(){if(y&&v.showFeedback){setTimeout((function(){be((function(e){return"not-scrolled"===e?"scrolled":e}))}),5e3);var e=function(){setTimeout((function(){be((function(e){return"not-scrolled"===e?"scrolled":e}))}),100)};return window.addEventListener("scroll",e,{capture:!0}),function(){window.removeEventListener("scroll",e)}}}),[y,x,v.showFeedback]);var Ge=function(){var e=Object(d.a)(qi().mark((function e(t){return qi().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:je(!0),setTimeout((function(){je(!1)}),3e3),be("user-scrolled"),eo(s,t);case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();return a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"wrap-main-result loading",id:"wrap-main-result",ref:u},a.a.createElement(a.a.Fragment,null,ne&&a.a.createElement(Qo,{requestImage:y,selectedRegion:x,setIsRfqModalOpen:re,isRfqModalOpen:ne,setRfqStatus:J}),_&&ke&&a.a.createElement(Io.a,{query:Le,filters:_}),a.a.createElement(h.a,{className:"box-wrap-result-component"},!j&&a.a.createElement("div",{className:"box-search"},a.a.createElement(Vr,null)),a.a.createElement(h.a,{className:"box-result",style:{height:v.showPoweredByNyris?"calc(100vh - 177px)":"calc(100vh - 148px)"}},!j&&Ve&&a.a.createElement(ri,{setImageSelection:R,allSearchResults:e.allSearchResults,debouncedOnImageSelectionChange:Pe,filteredRegions:Be,imageSelection:S,showAdjustInfo:B,showAdjustInfoBasedOnConfidence:q,showPostFilter:Ae,disjunctiveFacets:e.allSearchResults.disjunctiveFacets}),a.a.createElement(h.a,{className:"col-right ".concat(v.preview&&"ml-auto mr-auto"," ").concat(j&&"col-right-result-mobile"),style:{paddingTop:j?"8px":"40px",overflow:j?"":"auto",display:"flex",flexDirection:"column"}},!j&&a.a.createElement(h.a,{className:"wrap-box-refinements"},a.a.createElement(la,{statusSwitchButton:!0})),j&&v.preview&&y&&a.a.createElement(Oi,{requestImage:y,imageSelection:S,setImageSelection:R,debouncedOnImageSelectionChange:Pe,filteredRegions:Be,showAdjustInfoBasedOnConfidence:q,showAdjustInfo:B}),a.a.createElement(h.a,{style:{display:"flex",flexDirection:"column",flexGrow:1,backgroundColor:"#FAFAFA"}},a.a.createElement(h.a,{className:"box-item-result ml-auto mr-auto",style:{height:"100%",paddingLeft:j?0:16}},Oe&&a.a.createElement("div",{className:"box-item-result feedback-floating"},a.a.createElement("div",{className:"feedback-success"},"Thanks for your feedback!")),"scrolled"===ye&&!Oe&&a.a.createElement("div",{className:"box-item-result feedback-floating"},a.a.createElement(Di,{submitFeedback:Ge,onFeedbackClose:function(){be("user-scrolled")}})),a.a.createElement(No,{getUrlToCanvasFile:Me,setLoading:!1,sendFeedBackAction:Ie,moreInfoText:O,requestImage:y,searchQuery:Le}),a.a.createElement(h.a,{className:"pagination-result",style:{width:"100%",margin:j?"":"20px auto",marginBottom:j&&!y?"64px":"20px",padding:"0 20%",alignSelf:"end"}},(null===(o=e.allSearchResults)||void 0===o?void 0:o.hits.length)>0&&(y||Le)&&a.a.createElement(Mo.a,{showFirst:!1,translations:{previous:a.a.createElement(Xr.a,{style:{color:"#161616"}}),next:a.a.createElement(ea.a,{style:{color:"#161616"}})}})),y&&!C&&!e.isSearchStalled&&v.rfq&&v.rfq.enabled&&a.a.createElement(ji,{rfqRef:ue,rfqStatus:K,setIsRfqModalOpen:re,requestImage:y,selectedRegion:x}),!C&&!e.isSearchStalled&&v.support&&v.support.enabled&&(Le||y)&&a.a.createElement(zi,{requestImage:y,selectedRegion:x,query:Le}))),!j&&(null===(i=e.allSearchResults)||void 0===i||null===(l=i.hits)||void 0===l?void 0:l.length)>0&&ke&&a.a.createElement(h.a,null,a.a.createElement(h.a,{className:"box-notify"},a.a.createElement(fa,{search:g},a.a.createElement(h.a,{display:"flex",style:{padding:"0 20px"},className:"box-change-hit-items"},a.a.createElement("span",{style:{paddingRight:"10px"}},T("Items per page"),":"),a.a.createElement(_o.a,{items:z,defaultRefinement:20}))))),j&&v.showPoweredByNyris&&a.a.createElement("div",{style:{backgroundColor:"#FAFAFA",display:"flex",justifyContent:"center",paddingBottom:"46px"}},a.a.createElement(Ot,{style:{cursor:"pointer"},onClick:function(){window.open("https://www.nyris.io","_blank")},color:"#AAABB5"}))))))),"scrolled"===he&&y&&j&&e.allSearchResults.hits.length>0&&v.rfq&&v.rfq.enabled&&a.a.createElement("div",{style:{fontSize:"14px",fontWeight:"bold",letterSpacing:"1.16px",color:"white",borderRadius:"16px",backgroundColor:"#4B4B4A",boxShadow:"0px 0px 16px 0px rgba(85, 86, 107, 0.70)",padding:"8px 16px",zIndex:100,position:"absolute",left:"50%",transform:"translate(-50%, -50%)",width:"356px",bottom:"86px"}},"Scroll down for personalized support"))})));var Wi=function(){var e=Object(m.useMediaQuery)({query:"(max-width: 776px)"}),t=we((function(e){return e.settings.auth0})).supportEmail;return a.a.createElement("div",{style:{backgroundColor:"white",height:"100%",paddingLeft:e?"32px":"64px",paddingTop:e?"24px":"32px",display:"flex",flexDirection:"column",gap:"16px"}},a.a.createElement("div",{style:{fontSize:"20px",fontWeight:"bold",color:"#2B2C46"}},"Email verification is required"),a.a.createElement("div",{style:{width:"200px",height:"4px",background:"#3E36DC",borderRadius:"4px"}}),a.a.createElement("p",{style:{color:"#2B2C46",fontSize:"13px"}},"Please verify your email for access to the Search Suite. If you haven't received your verification email yet, contact support."),a.a.createElement("a",{className:"contact-support",style:{backgroundColor:"#2B2C46",padding:"8px 16px 8px 16px",color:"#fff",border:"none",cursor:"pointer",fontSize:"14px",width:"fit-content"},href:"mailto:".concat(t||"support@nyris.io","?subject=Resend Email Verification&body=")},"Contact Support"))},Ui=["component"],Yi=function(e){var t=e.component,n=Object(mn.a)(e,Ui),o=we((function(e){return e.settings})).auth0,i=Object(jt.b)(),l=i.user,c=i.isAuthenticated,u=i.isLoading,f=i.loginWithRedirect;Object(r.useEffect)((function(){u||l||c||!o.enabled||f()}),[f,u,l,c,o]);var d=t;return a.a.createElement(s.a,Object.assign({},n,{render:function(e){return o.enabled?c&&!(null===l||void 0===l?void 0:l.email_verified)?a.a.createElement(Wi,null):c&&(null===l||void 0===l?void 0:l.email_verified)?a.a.createElement(d,e):a.a.createElement("div",null):a.a.createElement(d,e)}}))},Ki=function(){var e=Object(jt.b)(),t=e.user,n=e.isAuthenticated,o=e.isLoading,i=e.loginWithRedirect,l=we((function(e){return e.settings})).auth0;return Object(r.useEffect)((function(){o||t||n||!l.enabled||i(),!n&&l.enabled||(window.location.href="/")}),[i,o,t,n,l]),a.a.createElement("div",null)},Qi=function(){var e=Object(jt.b)(),t=e.user,n=e.isAuthenticated,o=e.isLoading,i=e.loginWithRedirect,l=e.logout,c=we((function(e){return e.settings})).auth0;return Object(r.useEffect)((function(){o||t||n||!c.enabled?n?l({logoutParams:{returnTo:window.location.origin}}):c.enabled||(window.location.href="/"):i()}),[i,n,o,t,l,c]),a.a.createElement("div",null)};var Ji=Object(r.memo)((function(){return a.a.createElement(s.c,null,a.a.createElement(s.c,null,a.a.createElement(s.a,{path:"/login",exact:!0,component:Ki}),a.a.createElement(s.a,{path:"/logout",exact:!0,component:Qi}),a.a.createElement(kr,null,a.a.createElement(Yi,{exact:!0,strict:!0,path:"/",component:Qr}),a.a.createElement(Yi,{exact:!0,strict:!0,path:"/result",component:Zi}))))})),Xi=(n(877),n(502)),$i=function(){var e=Object(m.useMediaQuery)({query:"(max-width: 776px)"});return a.a.createElement(Bo.Toaster,{containerStyle:e?{bottom:80}:{top:60},position:e?"bottom-center":"top-right"},(function(e){return a.a.createElement(Bo.ToastBar,{toast:e,style:{padding:0,borderRadius:0}},(function(t){var n=t.icon;return a.a.createElement(a.a.Fragment,null,a.a.createElement("span",{style:{width:5,height:"100%",background:"success"===e.type?"#61d345":"transparent",marginRight:7}}),a.a.createElement("span",{style:{padding:15,display:"inline-flex"}},n,a.a.createElement("span",{style:{fontSize:15,fontWeight:300,margin:"0 10px"}}," ",Object(Bo.resolveValue)(e.message,e)),"loading"!==e.type&&a.a.createElement("span",{style:{display:"flex",alignItems:"center"}},a.a.createElement(aa.a,{fontSize:"small",style:{cursor:"pointer",marginLeft:10},onClick:function(){return Ao.a.dismiss(e.id)}}))))}))}))},el=function(e){var t=e.children,n=we((function(e){return e.settings}));return n.auth0.enabled?a.a.createElement(jt.a,{domain:n.auth0.domain||"",clientId:n.auth0.clientId||"",authorizationParams:{redirect_uri:window.location.origin}},t):a.a.createElement(a.a.Fragment,null,t)};document.title=window.location.host;var tl=Object(Xi.a)({overrides:{MuiTooltip:{arrow:{color:"black"},tooltip:{backgroundColor:"black"}}}});i.a.render(a.a.createElement(r.Fragment,null,a.a.createElement($i,null),a.a.createElement(l.a,{store:be},a.a.createElement(el,null,a.a.createElement(c.a,{theme:tl},a.a.createElement(u.a,null,a.a.createElement(Ji,null)))))),document.getElementById("root")),"serviceWorker"in navigator&&navigator.serviceWorker.ready.then((function(e){e.unregister()}))}},[[517,1,2]]]);
3
- //# sourceMappingURL=main.d68884f6.chunk.js.map