PageSourceSearch

https://www.mitutoyo.com.sg/_next/static/chunks/9915.72b14f056781f28a.js

js mitutoyo.com.sg collected 2026-10-08 06:47:42 UTC 6,822 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9915],{59915:function(e,n,t){t.r(n),t.d(n,{default:function(){return b}});var r=t(85893),i=t(94184),a=t.n(i),o=t(41664),s=t(11163);function u(e,n){void 0===n&&(n={});for(var t=function(e){for(var n=[],t=0;t<e.length;){var r=e[t];if("*"!==r&&"+"!==r&&"?"!==r)if("\\"!==r)if("{"!==r)if("}"!==r)if(":"!==r)if("("!==r)n.push({type:"CHAR",index:t,value:e[t++]});else{var i=1,a="";if("?"===e[s=t+1])throw new TypeError('Pattern cannot start with "?" at '+s);for(;s<e.length;)if("\\"!==e[s]){if(")"===e[s]){if(0===--i){s++;break}}else if("("===e[s]&&(i++,"?"!==e[s+1]))throw new TypeError("Capturing groups are not allowed at "+s);a+=e[s++]}else a+=e[s++]+e[s++];if(i)throw new TypeError("Unbalanced pattern at "+t);if(!a)throw new TypeError("Missing pattern at "+t);n.push({type:"PATTERN",index:t,value:a}),t=s}else{for(var o="",s=t+1;s<e.length;){var u=e.charCodeAt(s);if(!(u>=48&&u<=57||u>=65&&u<=90||u>=97&&u<=122||95===u))break;o+=e[s++]}if(!o)throw new TypeError("Missing parameter name at "+t);n.push({type:"NAME",index:t,value:o}),t=s}else n.push({type:"CLOSE",index:t,value:e[t++]});else n.push({type:"OPEN",index:t,value:e[t++]});else n.push({type:"ESCAPED_CHAR",index:t++,value:e[t++]});else n.push({type:"MODIFIER",index:t,value:e[t++]})}return n.push({type:"END",index:t,value:""}),n}(e),r=n.prefixes,i=void 0===r?"./":r,a="[^"+l(n.delimiter||"/#?")+"]+?",o=[],s=0,u=0,f="",c=function(e){if(u<t.length&&t[u].type===e)return t[u++].value},d=function(e){var n=c(e);if(void 0!==n)return n;var r=t[u],i=r.type,a=r.index;throw new TypeError("Unexpected "+i+" at "+a+", expected "+e)},p=function(){for(var e,n="";e=c("CHAR")||c("ESCAPED_CHAR");)n+=e;return n};u<t.length;){var h=c("CHAR"),v=c("NAME"),x=c("PATTERN");if(v||x){var m=h||"";-1===i.indexOf(m)&&(f+=m,m=""),f&&(o.push(f),f=""),o.push({name:v||s++,prefix:m,suffix:"",pattern:x||a,modifier:c("MODIFIER")||""})}else{var g=h||c("ESCAPED_CHAR");if(g)f+=g;else if(f&&(o.push(f),f=""),c("OPEN")){m=p();var y=c("NAME")||"",E=c("PATTERN")||"",w=p();d("CLOSE"),o.push({name:y||(E?s++:""),pattern:y&&!E?a:E,prefix:m,suffix:w,modifier:c("MODIFIER")||""})}else d("END")}}return o}function l(e){return e.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1")}function f(e){return e&&e.sensitive?"":"i"}function c(e,n,t){return function(e,n,t){void 0===t&&(t={});for(var r=t.strict,i=void 0!==r&&r,a=t.start,o=void 0===a||a,s=t.end,u=void 0===s||s,c=t.encode,d=void 0===c?function(e){return e}:c,p="["+l(t.endsWith||"")+"]|$",h="["+l(t.delimiter||"/#?")+"]",v=o?"^":"",x=0,m=e;x<m.length;x++){var g=m[x];if("string"===typeof g)v+=l(d(g));else{var y=l(d(g.prefix)),E=l(d(g.suffix));if(g.pattern)if(n&&n.push(g),y||E)if("+"===g.modifier||"*"===g.modifier){var w="*"===g.modifier?"?":"";v+="(?:"+y+"((?:"+g.pattern+")(?:"+E+y+"(?:"+g.pattern+"))*)"+E+")"+w}else v+="(?:"+y+"("+g.pattern+")"+E+")"+g.modifier;else v+="("+g.pattern+")"+g.modifier;else v+="(?:"+y+E+")"+g.modifier}}if(u)i||(v+=h+"?"),v+=t.endsWith?"(?="+p+")":"$";else{var b=e[e.length-1],j="string"===typeof b?h.indexOf(b[b.length-1])>-1:void 0===b;i||(v+="(?:"+h+"(?="+p+"))?"),j||(v+="(?="+h+"|"+p+")")}return new RegExp(v,f(t))}(u(e,t),n,t)}function d(e,n,t){return e instanceof RegExp?function(e,n){if(!n)return e;for(var t=/\((?:\?<(.*?)>)?(?!\?)/g,r=0,i=t.exec(e.source);i;)n.push({name:i[1]||r++,prefix:"",suffix:"",modifier:"",pattern:""}),i=t.exec(e.source);return e}(e,n):Array.isArray(e)?function(e,n,t){var r=e.map((function(e){return d(e,n,t).source}));return new RegExp("(?:"+r.join("|")+")",f(t))}(e,n,t):c(e,n,t)}var p=t(67294),h=t(86896),v=t(36005),x=t(5152),m=(t(25675),t(52091)),g=t(44080),y=t(15668),E=(0,x.default)((function(){return t.e(81).then(t.bind(t,81))}),{loadableGenerated:{webpack:function(){return[81]}},ssr:!1}),w=(0,x.default)((function(){return t.e(4952).then(t.bind(t,54952))}),{loadableGenerated:{webpack:function(){return[54952]}},ssr:!1});function b(e){(0,v.U2)(e,"region",{});var n,t,i=(0,p.useState)(e.menuData||[]),u=i[0],l=(i[1],(0,p.useState)(!1)),f=l[0],c=l[1],x=(0,p.useContext)(y.pl),b=(0,s.useRouter)(),j=(0,h.Z)().formatMessage,N=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return j({id:e,defaultMessage:n||e})},C=(0,p.useState)(null),M=C[0],A=C[1],k=(0,p.useMemo)((function(){return(0,v.U2)(b.query,"domainLocale","sg-en")}),[b]),R=(0,p.useCallback)((function(e){return e?e.startsWith("http")?e:"/".concat(k).concat(e):"/".concat(k)}),[k]);return(0,r.jsxs)("nav",{id:"desktop-nav","aria-label":"primary",className:"flex flex-wrap justify-center border-gray-200 w-full",children:[(0,r.jsxs)("div",{className:"flex container navBar-height items-center",children:[(0,r.jsx)("div",{className:"flex w-52 cursor-pointer",children:e.logo&&(0,r.jsx)(o.default,{href:R(),passHref:!0,children:(0,r.jsx)("a",{target:"_self",children:(0,r.jsx)("img",{src:"/img/mitutoyo-logo.svg",alt:"Logo ".concat(e.title),width:160,height:52.5})})})}),(0,r.jsx)("div",{className:"flex flex-grow float-right",children:(0,r.jsx)("div",{className:a()("mainmenu w-full justify-end"),children:(0,r.jsx)("ul",{id:"navigation","aria-label":"Menu trees",children:u.map((function(e,n){return(0,r.jsx)("li",{className:M&&f&&M.id===e.id||d("/"+k+"/"+e.link.split("/")[1],[],{sensitive:!0,end:!1}).test(b.asPath)?"active":"",onMouseEnter:function(){return function(e){if(c(!0),u&&u.length>0){var n=u.find((function(n){return n.id==e}));void 0!==n&&n.children&&n.children.length>0?A(n):A(null)}}(e.id)},onMouseLeave:function(){return c(!1)},"aria-label":"menuItem",children:(0,r.jsx)(o.default,{href:{pathname:R(e.link)},passHref:!0,children:(0,r.jsx)("a",{target:"_self","data-value":e.id,"aria-label":"".concat(N("ariaLabel.link.openMenu","Open menu of")," ").concat(e.title),children:e.title})})},e.id)}))})})}),(0,r.jsx)("div",{className:"flex w-8 items-center",children:(0,r.jsx)("button",{className:"text-gray-400 cursor-pointer px-4",onClick:function(){return x.dispatch({type:"toggleSearchMenu"})},"aria-label":"Open search box",children:(0,r.jsx)(m.U41,{className:"text-xl",role:"img","aria-hidden":"true"})})})]}),(0,r.jsx)(g.u,{as:p.Fragment,show:(null===x||void 0===x||null===(n=x.state)||void 0===n?void 0:n.isSearchOpen)||f,enter:"transition-opacity duration-100",enterFrom:"opacity-0",enterTo:"opacity-100",leave:"transition-opacity duration-100",leaveFrom:"opacity-100",leaveTo:"opacity-0",children:(0,r.jsxs)("div",{id:"hoverMenu",style:{backgroundColor:"#f4f4f4",position:"fixed",top:"118px",width:"100%"},onMouseEnter:function(){return c(!0)},onMouseLeave:function(){return c(!1)},children:[(null===x||void 0===x||null===(t=x.state)||void 0===t?void 0:t.isSearchOpen)&&
1(0,r.jsx)(w,{prefixUrl:k}),f&&M&&(0,r.jsx)(E,{item:M,onClick:function(){c(!f)},domainLocale:k,showImage:!0})]})})]})}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.