You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
11 KiB

1 month ago
exports.id=826,exports.ids=[826],exports.modules={2292:(e,t,r)=>{Promise.resolve().then(r.bind(r,3418))},5486:(e,t,r)=>{Promise.resolve().then(r.t.bind(r,2994,23)),Promise.resolve().then(r.t.bind(r,6114,23)),Promise.resolve().then(r.t.bind(r,9727,23)),Promise.resolve().then(r.t.bind(r,9671,23)),Promise.resolve().then(r.t.bind(r,1868,23)),Promise.resolve().then(r.t.bind(r,4759,23))},5303:()=>{},3418:(e,t,r)=>{"use strict";r.d(t,{MainNav:()=>l});var n=r(326),a=r(7577);function s({basePath:e="",locale:t="zh-CN"}){return n.jsx("button",{onClick:()=>{let e=window.location.pathname.split("/").filter(Boolean),t="en"===e[0]?"en":"zh-CN"===e[0]?"zh-CN":null,r="en"===t?"zh-CN":"en";t?e[0]=r:e.unshift(r);let n="/"+e.join("/");window.location.assign(n)},className:"bg-white border border-[#ccd5e4] text-[#0f3c88] px-2.5 py-1.5 rounded-[6px] text-xs md:text-sm tracking-[0.14em] uppercase cursor-pointer hover:bg-[#0f3c88] hover:text-white active:scale-95 transition-all duration-150 touch-manipulation",children:"en"===t?"CN":"EN"})}function l({items:e,basePath:t="",locale:r="zh-CN"}){let[l,i]=(0,a.useState)(!1),[o,c]=(0,a.useState)(""),d="en"===r?"SensiGuard Technologies":"衡感智能",x=e=>{if(!o||e.startsWith("#"))return!1;let r=`${t}${e}`;return"/"===e||""===e?o===t||o===`${t}/`:o===r||o.startsWith(`${r}/`)};return(0,n.jsxs)("header",{className:"w-full fixed top-0 left-0 right-0 z-50 bg-white/95 border-b border-[#dfe4ee] backdrop-blur-md shadow-[0_2px_16px_rgba(14,37,74,0.08)]",children:[(0,n.jsxs)("div",{className:"max-w-[1280px] mx-auto px-4 lg:px-8 py-3.5 md:py-5 flex items-center justify-between",children:[(0,n.jsxs)("a",{href:t||"/",className:"flex items-center gap-2 md:gap-3 no-underline flex-shrink-0",children:[n.jsx("img",{src:"/img/Log.jpg",alt:d,className:"h-8 w-auto md:h-10"}),n.jsx("div",{className:`font-semibold text-[#0f1f3f] text-xs sm:text-sm md:text-base hidden sm:block ${"en"===r?"tracking-[0.12em] uppercase":"tracking-[0.08em]"}`,children:d})]}),n.jsx("nav",{className:"hidden md:flex items-center gap-5 lg:gap-7",children:e.map(e=>{let r="/contact"===e.href,a=e.href.startsWith("#")?e.href:`${t}${e.href}`,s=x(e.href);return(0,n.jsxs)("a",{href:a,className:`no-underline transition-all duration-200 text-sm lg:text-base leading-none ${r?`inline-flex items-center justify-center px-4 lg:px-5 py-2 rounded-full font-medium tracking-[0.1em] ${s?"bg-[#0f3c88] text-white shadow-[0_6px_14px_rgba(15,60,136,0.25)]":"border border-[#0f3c88] text-[#0f3c88] hover:bg-[#0f3c88] hover:text-white"}`:`relative group px-2 lg:px-3 py-1 tracking-[0.1em] ${s||"/"===e.href?"text-[#0f3c88]":"text-[#1b1f2a] hover:text-[#0f3c88]"}`}`,children:[e.label,!r&&n.jsx("span",{className:`pointer-events-none absolute left-0 right-0 -bottom-2 h-[2px] rounded-full transform transition-all duration-200 ${s?"opacity-100 scale-100 bg-[#0f3c88]":"opacity-0 scale-75 group-hover:opacity-100 group-hover:scale-100 group-hover:bg-[#0f3c88]"}`})]},e.label)})}),(0,n.jsxs)("div",{className:"flex items-center gap-3",children:[n.jsx(s,{basePath:t,locale:r}),n.jsx("button",{onClick:()=>i(!l),className:"md:hidden p-2 text-[#1c2538] hover:text-[#0f3c88] focus:outline-none","aria-label":"Toggle menu",children:n.jsx("svg",{className:"w-6 h-6",fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",viewBox:"0 0 24 24",stroke:"currentColor",children:l?n.jsx("path",{d:"M6 18L18 6M6 6l12 12"}):n.jsx("path",{d:"M4 6h16M4 12h16M4 18h16"})})})]})]}),l&&n.jsx("div",{className:"md:hidden bg-white border-t border-[#dfe4ee] max-h-[calc(100vh-80px)] overflow-y-auto shadow-[0_10px_24px_rgba(14,37,74,0.12)]",children:n.jsx("nav",{className:"max-w-[1200px] mx-auto px-4 md:px-6 py-4 space-y-2",children:e.map(e=>{let r="/contact"===e.href,a=e.href.startsWith("#")?e.href:`${t}${e.href}`,s=x(e.href);return n.jsx("a",{href:a,className:`block py-2 px-2 rounded-md ${r?`border ${s?"border-transparent bg-[#0f3c88] text-white":"border-[#0f3c88] text-[#0f3c88] bg-transparent"}`:s?"text-[#0f3c88] font-medium bg-[#eef3fb]":"text-[#1d2332] hover:text-[#0f3c88] hover:bg-[#f3f6fb]"}`,onC