local na rede Internet:MSN 香港 | 首頁contente
MSNtry{window._peTimings=window._peTimings||{};window._peTimings["TTJSStart"]=Math.round(performance.now());}catch(e){console.error("ErrorinaddingTTJSStartmarker");}functiongetCookieConsentRequired(){returntrue;}window._ssrServiceEntryUrl="/bundles/v1/homePe/latest/SSR-service-entry.2606e4469f7da12.js";window["_webWorkerBundle"]="/bundles/v1/homePe/latest/web-worker.01ef3a5bf1b5138.js";window["_authCookieName"]="ace";!function(){"usestrict";vare={},t={};functionn(o){vari=t[o];if(void0!==i)returni.exports;vars=t[o]={exports:{}};returne[o](s,s.exports,n),s.exports}leto,i,s,r;functionc(){if(i)returni;conste=document.head.getAttribute("data-info");returni=((/f:\s*([^;]+)/i.exec(e)||{})[1]||"").toLowerCase(),i}functiona(e){vart;return((null===(t=document.head)||void0===t||null===(t=t.getAttribute("data-info"))||void0===t?void0:t.split(";").find((e=>e.startsWith("f:"))))||"").includes(e)}n.g=function(){if("object"==typeofglobalThis)returnglobalThis;try{returnthis||newFunction("returnthis")()}catch(e){if("object"==typeofwindow)returnwindow}}(),function(){if(void0!==n){constt=n.e,o={};vare;document.head.getAttribute("data-info");n.e=function(i){returnt(i).catch((function(t){consts=o.hasOwnProperty(i)?o[i]:2;if(void0===e&&(e=!1),e&&2===s&&(n.p=n.p.replace("/assets.","/assets2.")),sthis.maxLength&&this.list.shift()}getdata(){returnthis.list}};functionm(e,t,n){leti=arguments.length>3&&void0!==arguments[3]?arguments[3]:g.Alert,s=arguments.length>4?arguments[4]:void0,a=arguments.length>5?arguments[5]:void0;try{constd=function(){if(!o){conste=document.head.getAttribute("data-client-settings");e&&(o=JSON.parse(e))}returno}(),l=c(),p=function(e){if(e){const{pcsInfo:t,peGenTime:n}=e,o=newDate(n).getTime(),i=!t||["prod","prod-ssr","prod-ssrntp"].includes(t.env);r=i?"browser.events.data.msn.com":"events-sandbox.data.msn.com";return{cors:"true","content-type":"application/x-json-stream","client-id":"NO_AUTH","client-version":"1DS-Web-JS-2.2.2",apikey:i?"0ded60c75eaa3484c42c1c43fe8-9fc57d3f-fdac-4bcf-b927-75eafee-7279":"f8857dedc6f54ca8962cfb713e01e7d7-e-fe0b-446f-95ae-f98c-7028","upload-time":o,w:"0",anoncknm:"app_anon"}}returnnull}(d);leth="";p&&p.apikey&&""!==p.apikey&&(h=function(e){if(e){constt=e.indexOf("-");if(t>0)returne.substring(0,t)}return""}(p.apikey));constm=function(e,t,n,o,i,s){letr=arguments.length>6&&void0!==arguments[6]?arguments[6]:g.Alert;if(n){i=i||{};const{apptype:a,audienceMode:d,petype:l,peGenTime:p,bundleInfo:h,deviceFormFactor:g="",fd_muid:w,os:m}=n;i.peGenTime=p,i.build=h&&h.v,i.appType=a;constv=function(e,t,n){consto=n&&"phone"===n.toLowerCase(),i=t&&"enterprise"===t;return{bingHomepe:"binghomepe",mmx:"emmx",edge:"spartan",edgeChromium:i?"entnews":"anaheim",hybrid:"spartan",hub:o?"prime_mobile":"prime",microsoftNews:"msnews",office:"entnews",views:o?"prime_mobile":"prime",homePe:o?"prime_mobile":"prime",windowsShell:"windowsshell"}[e]}(a,d,g),y=v||a,k=document.getElementsByTName("html")[0].getAttribute("lang");letS,A="",C="muid";try{if("edgeChromium"===a&&"object"==typeofwindow&&window.location&&window.location.search){conste=newURLSearchParams(window.location.search);S=e.has("startpe")?"msedgdhp":"msedgntp","enterprise"===d?S="entnewsntp":"xbox"===m&&(S="xboxntp")}window&&window.getCookieConsentRequired&&"function"==typeofwindow.getCookieConsentRequired&&window.getCookieConsentRequired()||(A=u("muid"))}catch{}A||(A=n.aid,C="aid");constI={name:"MS.News.Web.AppError",time:p,ver:"4.0",iKey:`o:${o}`,data:{baseData:{},baseType:"MS.News.Web.Base",pe:{name:"default",product:y,type:b(l),content:f[a]??{category:"standaloneError"},ocid:S},browser:{clientId:A,clientIdType:C},flight:{id:s},request:{activityId:n.aid,requestId:n.aid,afdMuid:w},locale:{mkt:k},extSchema:{id:e,severity:r,pb:i,messe:t}}};varc;if(A&&"muid"===C)I.ext={...null==I?void0:I.ext,user:{...null==I||null===(c=I.ext)||void0===c?void0:c.user,localId:`t:${A}`}};returnI.data.flight.tmpl="","object"==typeofwindow&&(window.isSSREnabled&&(I.data.flight.tmpl+=";ssr-enabled:1"),window.isSSRCompleted&&(I.data.flight.tmpl+=";ssr-completed:1")),I?JSON.stringify(I):null}returnnull}(t,e,d,h,n,l,i);if(a&&!function(e){if(null==e)return!1;returne.startsWith("2")||e.startsWith("3")}(null==d?void0:d.aid))returnconsole.error(m),voidconsole.error(`ThisApperrorId:${t}willnotbesentduetoapperrorsampling!`);if(p&&m){console.error(m),w.push(m);conste=""+r+"/OneCollector/1.0"+function(e){return"?"+Object.keys(e).map((function(t){returnt+"="+encodeURIComponent(e[t])})).join("&")}(p);if(s&&!performance.getEntriesByType("visibility-state").some((e=>"visible"===e.name))){constt=()=>{"visible"===document.visibilityState&&nigator.sendBeacon(e,m)};document.addEventListener("visibilitychange",t,{once:!0})}elsenigator.sendBeacon(e,m)}}catch{}}constf={homePe:{vertical:"homepe",category:"",id:"",domainId:"",title:"undefined"!=typeofdocument?:""}};functionb(e){lett=e;switch(e){case"windowsshellhp":t="dhp";break;case"video":t="watch"}returnt}constv="visibilitychange";functiony(){return"visible"===document.visibilityState?Promise.resolve():newPromise((e=>{document.addEventListener(v,(()=>{"visible"===document.visibilityState&&e()}),{once:!0})}))}functionk(e){constt=window&&window.chrome&&window.chrome.ntpSettingsPrivate;t&&t.logLoadingError&&y().then((()=>{t.logLoadingError(e)}))}functionS(e){if("undefined"==typeofwindow||!window.document||window.isRenderServiceEnv)return;constt=window.trustedTypes;if(!t||!t.createPolicy)return;constn=window.trustedTypePolicies||(window.trustedTypePolicies={});if(n[e])returnn[e];consto=t.createPolicy(e,{createScriptURL:e=>{constt=function(e){constt=["ntp.msn.com","ntp.msn.cn","assets.msn.cn","assets.msn.com","","assets2.msn.com","assets2.msn.cn","","int.msn.com","r.bing.com","business.bing.com","staticview.msn.com","staticview.msn.cn",document.location.hostname];letn;try{n=newURL(e,location.origin)}catch(e){return"about:blank#error"}if(n.hostname&&!t.includes(n.hostname))return"about:blank#error";returne}(e);returnt}});returnn[e]=o,o}constA=,C=;functionI(e,t){constn=S(t);if(n){constt=n.createScriptURL(e),o=t&&t.toString();returnt&&"about:blank#error"!==o?t:(m("URLisnottrustedtypescompliant.",C,{customMesse:"FailedURLis:"+e},g.Deprecated,!0),e)}returnm("Trustedtypespolicyisnotailable.",A,{},g.Deprecated,!0),e}const_={},E=3;functionq(e){constt=document.createElement("script");returnt.type="text/jascript",t.crossOrigin="anonymous",t.src=I(e,"fallbackBundleUrlPolicy"),t.onerror=()=>x(t),t.onload=e=>function(e){constt=e.target.src,n=t.substring(t.lastIndexOf("/")+1).split(".")[0]||"",o=window._peTimings.retriedBundles;window._peTimings.retriedBundles=o?`${o},${n}`:n}(e),t}functionx(e){if(!e)return;constt=e.src;letn=_[t]||1;if(ne.replaceWith(o)),100)}elsem("Errorwhenloadingbundle:"+t,,{retryCount:n,timeElapsed:Math.round(performance.now()),nType:d()},g.Deprecated)}constT="experience";functionP(){conste=["vendors","microsoft","common"];window.addEventListener("load",(()=>{window._peTimings.nType=d(),window.requestIdleCallback((()=>{constt=function(e){constt=window.homePeWebpackChunks;if(!t)return[...e,T];if(t.length>e.length)return[];t.forEach((t=>e.splice(e.indexOf(t[0][0]),1)));constn=L(T);t.push===Array.prototype.push&&n.responseEnd>0&&e.push(T);returne}(e);varn;t.length&&(a("msn-bndl-irtry")?t.forEach(O):Promise.race([y(),(n=5e5,newPromise((e=>setTimeout((()=>e("timeout")),n))))]).then((()=>{t.forEach(O)})))}))}),{once:!0})}functionO(e){constt=L(e);t&&(t.responseEnd>0?x(Array.from(document.scripts).find((e=>e.src===t.name))):setTimeout((()=>{window.requestIdleCallback((()=>{O(e)}))}),100))}functionL(e){constt=performance.getEntriesByType("resource").filter((t=>"script"===t.initiatorType&&t.name.indexOf(`/${e}.`)>-1));returnt[t.length-1]}functionN(e){m("Errorwhenloadingbundle:"+e,,{...arguments.length>1&&void0!==arguments[1]?arguments[1]:{}})}functionR(e,t,n,o,i){m("JSException",,{source:t,customMesse:e,line:n,column:o,stack:i&&i.stack})}functionW(e){m("JSException",,{customMesse:e&&e.reason&&e.reason.messe,stack:e&&e.reason&&e.reason.stack})}functionM(e){try{if(e)returnJSON.parse(e)}catch(e){}returnnull}functionD(){return!("undefined"==typeofwindow||!window.document||!window.document.createElement||window.isRenderServiceEnv)}"undefined"!=typeofwindow&&window.document&&window.document.createElement&&(window._peTimings=window._peTimings||{},window.requestIdleCallback=window.requestIdleCallback||window.setTimeout);constU="Authorization";varF,$;!function(e){e.Presentation="presentation"}(F||(F={})),function(e){e.Unknown="Unknown",e.Portrait="Portrait",e.Landscape="Landscape"}($||($={}));varB,H;!function(e){e[e.Undefined=0]="Undefined",e[e.Basic=1]="Basic",e[e.Advanced=2]="Advanced",e[e.Premium=3]="Premium"}(B||(B={})),function(e){e.Init="init",e.Config="config",e.Targeted="targeted",e.Sticky="sticky",e.NoSticky="no_sticky",e.Admin="admin",e.Forced="forced",e.Manual="manual"}(H||(H={}));newSet(["winp0dash","winp1taskbar","winp1taskbarent","winp1taskbardirect","winp1taskbardirectent","winp1taskbarent","winp2juntaskbar","winp2juntaskbarent","winp2","winp2ent","winp2fp","winp2fpent","winp2fptaskbar","winp2fptaskbarent","winp2fptaskbarhover","winp2fptaskbarhoverent","winp2widget","winp2widgetent"]);constj=newSet(["finance-app-win","weather-app-win","winpstoreapp"]),J=(newSet(["msedgdhp","msedgdhphdr","msedgntphdr","msedgntp","msedgdhp","entnewsntp"]),newSet(["hpmsn"]));newSet(["chromentpnews"]);functionG(){vare;returnD()?M(document.head.dataset.clientSettings||(null===(e=document.getElementsByClassName("peregrine-widget-settings")[0])||void0===e?void0:e.getAttribute("data-client-settings"))):null}constV="feed/personalize/settings";functionX(e,t){constn=t.replace(/[[\]]/g,"\\$&"),o=newRegExp("[?&]"+n+"(=([^]*)|&|#|$)").exec(e);if(!o)returnnull;consti=o[2];returndecodeURIComponent(i.replace(/\+/g,""))||""}letz=newclass{constructor(){D()?(this.isDebugEnabled=(X(window.location.href,"debug")||"").toLowerCase()in{1:1,true:1}||"vp"===(X(window.location.href,"reqsrc")||"").toLowerCase(),this.isDebugEnabled&&!n.g.TEST_ENV&&(window.webpackRequire=n)):this.isDebugEnabled=!1}getLoggingService(){returnnull}isDebug(){returnthis.isDebugEnabled}setDebug(e){this.isDebugEnabled=e}setTs(e){}log(e,t){this.isDebug()&&console.info(e)}logError(e){console.error(e)}logCallback(e){this.isDebug()&&console.info(e())}logObjects(){this.isDebug()&&console.log(...arguments)}logSingleObject(e,t){this.isDebug()&&console.log(e)}};classK{getsupported(){return!!this.store}constructor(e){this.store=e}getItem(e){if(this.supported)returnthis.store.getItem(e)}getObject(e,t){constn=this.getItem(e);if(null!=n){conste=M(n);if(null!=e)returne}returnt}key(e){if(this.supported&&e>=0)returnthis.store.key(e)}keys(){returnthis.supported?Object.keys(this.store):[]}setObject(e,t){void0!==t?this.setItem(e,JSON.stringify(t)):this.removeItem(e)}removeObject(e){constt=this.removeItem(e);if(null!=t)returnM(t)}setItem(e,t){letn=!(arguments.length>2&&void0!==arguments[2])||arguments[2];if(this.supported)try{if(!t)throw"Attemptedtostorenull/undefinedvalue:"+t;this.store.setItem(e,t)}catch(e){if(!n)throwe;z.logError(e)}elseif(!n)thrownewError("WebStorenotsupported")}getlength(){if(this.supported)returnthis.store.length}removeItem(e){if(this.supported){constt=this.getItem(e);returnthis.store.removeItem(e),t}}clear(){this.supported&&this.store.clear()}removeSubstringKeys(e){if(!this.supported||!e)return;constt=[];for(letn=0;n{n=!1,t=void0}},o}!function(e){e.Notailable="notailable",e.Expired="expired",e.Valid="valid"}(Z||(Z={}));constre="currentaccount",ce=se((()=>{conste=u(re,!0),t=e&&M(e),{login_hint:n}=t||{};returnn&&t})),ae=se((()=>!!u(re)));letde=newMap;constle=Object.freeze({set(e,t){returnde.set(e,t),this},get:function(e,t){letn=de.get(e);returnvoid0===n&&t&&(n=t(),de.set(e,n)),n},clear(){de.clear()},delete:e=>de.delete(e),has:e=>de.has(e)});constue="__RequestDataInstance__";classpe{constructor(e,t){if(this.url=newURL(e.href),this.innerHeight=e.innerHeight,this.devicePixelRatio=e.devicePixelRatio,this.canUseCssGrid=e.canUseCssGrid,this.requestId=e.requestId,this.cookie=e.cookie,this.referer=e.referer,this.userent=e.userent,this.clientData=e.clientData,this.oneServiceHeaders=function(e){try{if(e)returnJSON.parse(e)}catch(e){}}(e.oneServiceHeaders)||{},this.isPssrMode=t,t){conste=he("OSATE",this.cookie),t=!!e&&"1"===e,n=he("OSAT",this.cookie);if(t&&n||!e&&!n)returnthis.msalAuthReady=!0,void(n&&(this.oneServiceHeaders.Authorization=`Bearer${n}`));this.msalAuthReady=!1,this.pssrRejectedReason=e&&!t?"interactiveLogin":e&&!n?"missOSAT":"missOSATE"}}staticgetInstance(){conste=le.get(ue);returne||(n.g.TEST_ENV?ge({href:"httplocalhost:8080/",innerHeight:768,devicePixelRatio:1,canUseCssGrid:!1,requestId:"0",cookie:"",userent:"",referer:"",oneServiceHeaders:""}):ge({href:"httplocalhost:8080/",innerHeight:0,devicePixelRatio:0,canUseCssGrid:!1,requestId:"0",cookie:"",userent:"",referer:"",oneServiceHeaders:""}))}staticresetInstance(e){constt=newpe(e,arguments.length>1&&void0!==arguments[1]&&arguments[1]);returnle.set(ue,t),t}}functionhe(e,t){if(t&&e){constn=newRegExp("\\b"+e+"\\s*=\\s*([^;]*)","i").exec(t);returnn&&n.length>1?n[1]:null}returnnull}constge=pe.resetInstance,we=()=>pe.getInstance();functionme(){try{returnlocalStore}catch(e){returnnull}}constfe="__PeExperimentInstance__";functionbe(e){le.set(fe,e)}functionve(e){if(!le.has(fe)&&D()){vart;be(ye(document.head.dataset.info||(null===(t=window.document.getElementsByClassName("peregrine-widget-settings")[0])||void0===t||null===(t=t.dataset)||void0===t?void0:t.info)||""))}constn=le.get(fe);returnn&&n.has(e)}functionye(e){constt=(e||"").replace(/(^f:|;.*$)/g,"").split(",");returnnewSet(t)}constke="uxlogin",Se="uxlogout",Ae="uxedit",Ce="useRedirect",Ie="uxswitch",_e=se((()=>{conste=me();returne&&"1"===e.getItem(ke)||D()&&location.search&&location.search.includes(`${ke}=1`)}));constEe=se((()=>{conste=function(){try{returnsessionStore}catch(e){returnnull}}();returne&&!!e.getItem(Se)}));constqe=se((()=>{conste=me();returne&&"1"===e.getItem(Ae)}));constxe=se((()=>{conste=me(),t=!ve("prg-noredirect")&&e&&"1"===e.getItem(Ce)&&function(){conste=document.head.dataset.clientSettings||"",{browser:t}=M(e)||{},{browserType:n=""}=t||{};return!!/safari/i.test(n)}();returnt}));constTe=se((()=>{conste=me();returne&&"1"===e.getItem(Ie)}));constPe={bingHomepeMobile:"binghomepemobile",outlookMobile:"OnOOutlookMobile",officeMobile:"OnOOfficeMobile",sapphire:"OnOStartApp",skype:"OnOSkype",freFullPe:"emmxFre",winWeatherApp:"weather-app-win",xiaomiApp:"xmweather-",launcher:"launcherntp",launcherInterests:"launcherInterests",moto:"moto",swiftKey:"swiftMSN 香港 | 首頁Key",winMoneyApp:"finance-app-win"},Oe="superappdhp",Le=["ios","android","ipados"];letNe=Xe("ocid").toLowerCase(),Re=Xe("chpltfm"),[We,Me]=Re.toLowerCase().split("-");functionDe(){if(!D()||Je())return!1;conste=window.sapphireWebViewBridge,t=window.webkit,n=e&&e.send,o=t&&t.messeHandlers&&t.messeHandlers.send&&t.messeHandlers.send.postMesse;return!(!n&&!o)}functionUe(){conste=Re&&"outlook"===We&&Le.includes(Me),t=Ne===Pe.outlookMobile.toLowerCase();returne||t}functionFe(){conste=Re&&["office","union"].includes(We)&&Le.includes(Me),t=Ne===Pe.officeMobile.toLowerCase();returne||t}function$e(){conste=Ne===Pe.skype.toLowerCase()||"skype"===We;returnD()&&(null===(t=window.skypeWebviewBridge)||void0===t?void0:t.isSkype)||e;vart}functionBe(){return!(!D()||Je())&&(De()||Ne===Pe.sapphire.toLowerCase()||Ne===Oe.toLowerCase())}functionHe(){conste=Xe("edge");return("emmx"===We||"1"===e)&&Be()||"mmx"===Ne}functionje(){return"3rdp"===We||Ne.startsWith(Pe.xiaomiApp)||Ne===Pe.moto.toLowerCase()||Je()}functionJe(){returnNe.toLowerCase()===Pe.swiftKey.toLowerCase()||"swiftkey"==We.toLowerCase()}functionGe(){return-1!==location.href.indexOf("huawei")||-1!==location.href.indexOf("airfind")||-1!==location.href.indexOf("aloha")||"vivo"===Ne&&je()}constVe=se((()=>De()||$e()||Fe()||Ue()||Be()||Ne===Pe.winWeatherApp.toLowerCase()||Ne===Pe.winMoneyApp.toLowerCase()||He()||je()||[Pe.launcher.toLowerCase(),Pe.launcherInterests.toLowerCase()].includes(Ne)&&Be()||Je()||Ge()||-1!==location.href.indexOf("metaos=true")));functionXe(e){try{returnnewURL(location.href).searchParams.get(e)||""}catch(e){return""}}constze=G()||{},Ke={newsAndInterests:1,windowsNewsbar:1,windowsNewsPlus:1,winWidgets:1,windowsShell:1,windowsShellV2:1,distribution:1,superApp:1,channeldesktop:1,channelmobile:1,edgeMobile:1},Qe={edgeChromium:1},Ye={winWidgets:1},Ze={edgeChromium:1,shopping:1,newsAndInterests:1,windowsNewsbar:1,windowsNewsPlus:1,winWidgets:1,windowsShell:1,windowsShellV2:1},et={edgeChromium:1,channeldesktop:1,channelmobile:1,cgHomePe:1,distribution:1,newsAndInterests:1,windowsNewsbar:1,windowsNewsPlus:1,winWidgets:1,windowsShell:1,windowsShellV2:1,superApp:1,edgeMobile:1},tt=se((()=>ze&&ze.apptype)),nt=(se((()=>D()&&tt()inYe)),se((()=>D()&&!Ve()&&!(tt()inKe)&&!st()&&!rt()))),ot=se((()=>nt()&&!(tt()inQe)));se((()=>nt()&&(!(tt()inQe)||!ae()))),se((()=>nt()&&!lt()&&!ut()));constit=se((()=>ut()||lt())),st=se((()=>{conste=!(tt()inZe)&&pt()&&function(){conste=newURLSearchParams(D()?window.location.search:we().url.search).get("ocid")||(null==ze?void0:ze.ocid),t=null==e?void0:e.toLowerCase(),n=!J.has(t)&&"homePe"!==tt()&&!j.has(t);returnn}()&&!function(){conste="windows"==tt()&&"windowshp"==(ze&&ze.petype)&&(D()?window.location.href:we().url.href).includes(`${V}`);returne}();returne})),rt=()=>D()&&document&&document.body&&document.body.getElementsByClassName("peregrine-widgets").length>0,ct=se((()=>ve("prg-1s-workid")||ve("prg-1s-sm-workid")||ve("prg-1s-twid")||ve("prg-1s-mm-wid-t")));se((()=>tt()inet||st()));functionat(){conste=te;if(e)returnz.log("dual-auth:tryGet1SAuthTokenreturnedlivetokens"),e;constt=ne();if(t)returnz.log(`dual-auth:tryGet1SAuthTokenreturnedcachedtokensthatare${oe()}`),t;z.log("dual-auth:tryGet1SAuthTokenreturnedemptytokens")}functiondt(e){constt={};returne&&(t[U]=`Bearer${e}`),t}functionlt(){returnot()&&_e()||function(){conste=ot()&&!ht()&&!_e()&&ce()&&("expired"==oe()||qe());returne}()||Ee()||xe()}functionut(){returnot()&&!ce()&&Te()}constpt=se((()=>{const{browser:e}=ze,{browserType:t="",detected:n={}}=e||{},{browserType:o=""}=n||{};return/edgeChromium/i.test(t)||/edgeAnMSN 香港 | 首頁droid/i.test(t)||/edgeiOS/i.test(t)||/edge/i.test(o)}));se((()=>ot()&&!st()));constht=()=>{conste=ce();if(!e)return!1;lett;switch(e.account_type){case"MSA":t=ot()?"ace":"aace";break;case"AAD":t=ot()?"WID":"APP_WID";break;default:return!1}return!!u(t)};constgt="__core_auth_authHeaderPromiseParts__",wt=()=>le.get(gt);varmt;!function(){lete;constt={promise:newPromise((t=>e=t)),resolver:e};le.set(gt,t)}(),function(e){e.GLOBAL="GLOBAL",e.GCC_MODERATE="GCC_MODERATE"}(mt||(mt={}));letft;functionbt(){returnft}functionvt(e){constt=e||bt()||"al_app_anon",n=yt();return!!(n&&(["anon","al_anon"].includes(t)&&n.AL_ANON||["app_anon","al_app_anon"].includes(t)&&n.AL_APP_ANON))}constyt=se((()=>M(u("AL_STATE",!0))));constkt=()=>{conste=u("elt",!0),t=e&&M(e),{access_token:n,account_type:o,login_hint:i,region_scope:s}=t||{};return(n||o||i||s)&&t};classSt{constructor(){this.childCookieName="child",this.domInfo=document.head.dataset.info,this.command="command"}init(e,t){this.clientSettings=e||G(),this.authCookieName=bt()||window._authCookieName||"",this.bundle=window._webWorkerBundle||"",t=t||{};constn=this.buildWebWorkerUrl(this.clientSettings,t),o=this.clientSettings.apptype;leti;if(o&&"edgeChromium"===o){if(i=this.tryGetWebWorkerUsingPolicy(n,"webWorkerUrlPolicy"),!i)returnvoidconsole.warn("Errorincreatingtrustedtypescompliantwebworker")}elsei=window.webWorker=newWorker(n,{name:"web-worker"});consts=window.webWorkerMesses=[];i.onmesse=e=>{s.push(e.data)};constr=window.webWorkerErrors=[];if(i.onerror=e=>{r.push(e)},window.chrome){conste=this.getAudienceMode(this.clientSettings),t=window.webWorker&&window.chrome&&window.chrome.ntpSettingsPrivate;t&&"function"==typeoft.getPref&&(t.getPref("ntp.news_feed_display",(e=>{e&&e.value&&i.postMesse({id:"FeedDisplaySetting",type:this.command,payload:e.value})})),t.getPref("ntp.layout_mode",(e=>{e&&e.value&&i.postMesse({id:"LayoutModeSetting",type:this.command,payload:e.value})})),t.getPref("new_device_fre.has_user_seen_new_fre",(e=>{e&&i.postMesse({id:"NewUserFre",type:this.command,payload:e.value})}))),t&&"function"==typeoft.getConfigData&&t.getConfigData((e=>{constt=(null==e?void0:e.enabledFeatures)||[];t.includes("msReducedNtpAdsForNewDevice_ste1")&&i.postMesse({id:"EdgeNoAds",type:this.command,payload:!0}),t.includes("msReducedNtpAdsForNewDevice_ste2")&&i.postMesse({id:"EdgeReduceAds",type:this.command,payload:!0})})),"enterprise"===e&&this.clientSettings.browser&&"edgeChromium"===this.clientSettings.browser.browserType&&parseInt(this.clientSettings.browser.version)>=87?this.getEnterpriseAccessToken().then((e=>{e&&i.postMesse({id:"AuthTokenEnterprise",type:this.command,payload:dt(e)})})):i.postMesse({id:"AuthTokenEnterprise",type:this.command,payload:{}}),"adult"!==e&&"enterprise"!==e||this.sendPeConfiguration()}it()&&wt().promise.then((e=>i.postMesse({id:"AuthHeaders",type:this.command,payload:e||{}})))}buildWebWorkerUrl(){lete=arguments.length>0&&void0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void0;return(this.bundle||"")+"#"+this.qsFromDocument()+this.qsFromCookies()+this.qsFromDataAttribute(e||this.clientSettings)+this.qsMisc(t)+this.qsAuth(e||this.clientSettings)+this.qsFromUrl()+this.qsFromServiceWorker()+this.qsSelectedPivot()+this.qsXboxXToken()}qs(e,t,n){returne?t+"="+(n||e)+"&":""}qsFromDocument(){vare;returnthis.qs(document.getElementsByTName("html")[0].getAttribute("lang"),"lang")+this.qs(encodeURIComponent(window.location.href),"adsReferer")+this.qs(null===(e=D()?window.devicePixelRatio:we().devicePixelRatio)||void0===e?void0:e.toString(),"devicePixelRatio")}qsFromServiceWorker(){if(!nigator.serviceWorker||!nigator.serviceWorker.controller)return"";conste=nigator.serviceWorker.controller;if("activated"!==e.state||!e.scriptURL)return"";if(e.scriptURL){constt=newURL(e.scriptURL).searchParams.toString();returnt?"&"+t+"&":""}return""}qsFromCookies(){returnthis.qs(h(this.authCookieName),"aace","1")+this.qs(h("muid"),"muid")+this.qs(h(this.childCookieName),"child")+this.qs(h("cbypass"),"cbypass")+this.qs(this.cookieBannerConsentRequired().toString(),"ccRequired")+this.qs(h("ecasession"),"ecasession")+this.qs(h("TOptOut"),"browserOptOut")}qsFromDataAttributeHelper(e,t){returne&&e.featureFls&&e.featureFls.wpoEnabled&&t&&!t.includes("remwpofltww")&&(t=this.appendWpoFlightsToInfo(e,t)),this.qs(e.pcsInfo&&e.pcsInfo.env||e.env,"env")+this.qs(e.aid,"aid")+this.qs(e.apptype,"apptype")+this.qs(e.petype,"petype")+this.qs(e.audienceMode,"audienceMode")+this.qs(e.configIndexDocId,"configIndexDocId")+this.qs(e.deviceFormFactor,"deviceFormFactor")+this.qs(e.domain,"domain")+this.qs(e.configRootUrl,"configRootUrl")+this.qs(this.getHighestCbid(e.cbid,e.apptype),"cbid")+this.qs(e.ocid,"ocid")+this.qs(e.os,"os")+this.qs(JSON.stringify(e.locale),"locale")+this.qs(e.geo_lat,"lat")+this.qs(e.geo_long,"long")+this.qs(JSON.stringify(e.featureFls),"featureFls")+this.qs(JSON.stringify(e.browser),"browser")+this.qs(JSON.stringify(e.servicesEndpoints),"servicesEndpoints")+this.qs(e.bundleInfo&&e.bundleInfo.v||"","buildVersion")+this.qs(t,"dataInfo")}qsSelectedPivot(){conste="selectedPivot";lett;try{constn=me();n&&(t=n.getItem(e))}catch(e){console.warn("Errorgettingpivotidfromlocalstore."+e)}returnthis.qs(t,e)}qsXboxXToken(){conste="xboxXTokenId";lett;try{constn=me();n&&(t=n.getItem(e))}catch(e){console.warn("ErrorgettingxboxXTokenfromlocalstore."+e)}returnthis.qs(t,e)}appendWpoFlightsToInfo(e,t){constn=this.getWpoFlightsFromLocalStore(e);if(n&&n.length){conste=";",o=t.split(e);for(lete=0;ee.id))}}catch(e){console.warn(`Errorgettingwpoflightsfromlsfor${o}Error:${e}`)}returnnull}getHighestCbid(e,t){try{constn=me(),o=parseInt(e),i=parseInt(JSON.parse(n.getItem(`cbid_${t||""}`)));lets;if(o&&!isNaN(o)&&i&&!isNaN(i)&&(s=o>i?o:i),s=s||o||i,s)returnwindow._cbid=s.toString()}catch(e){console.warn("ErrorgettinghighestCBID"+e)}}getAudienceMode(e){me();constt=u(this.authCookieName),n=u(this.childCookieName),{child:o}=t&&JSON.parse(t)||{};returnt&&(1===o||n)?"kids":e.audienceMode||"adult"}sendPeConfiguration(){conste=this.clientSettings.petype;if(e){constt=u&&u("pglt-edgeChromium-"+e);if(t)returnvoidwindow.webWorker.postMesse({id:"PeConfiguration",type:this.command,payload:t})}window.webWorker.postMesse({id:"PeConfiguration",type:this.command,payload:!1})}qsFromDataAttribute(e){lett,n;consto=me();if(o){consti=JSON.parse(o.getItem("shd_"+e.petype)||null);i&&i.clientSettings&&i.info&&(t={...i.clientSettings,bundleInfo:e.bundleInfo},n=i.info)}return(!t||!n||e.peGenTime>=t.peGenTime)&&(t=e,n=this.domInfo),t.audienceMode=this.getAudienceMode(t),this.qsFromDataAttributeHelper(t,n)}qsFromUrl(){conste=location.search;returne&&e.length?e.substring(1,e.length):""}getEnterpriseAccessToken(){returnnewPromise((e=>{window.chrome&&window.chrome.authPrivate?window.chrome.authPrivate.getPrimaryAccountInfo((t=>{t&&"GCC_MODERATE"!==t.region_scope||e("");constn={account_id:t.account_id,account_type:t.account_type,client_id:"d7b530a4-7680-4c23-a8bf-c52c121d2e87",scope_or_resource:"enterprisenews.microsoft.com"};window.chrome.authPrivate.acquireAccessTokenSilently(n,(t=>{t.is_success?e(t.access_token):e("")}))})):e("")}))}qsMisc(e){returnthis.qs(performance.timeOrigin&&performance.timeOrigin.toString(),"mainTimeOrigin")+this.qs(e.disableWWConfig&&"1","disableWWConfig")}qsAuth(e){lett=this.qs(ot()&&"1","disableWWAuth");if(!it()){conste=ot()&&at()||{};t+=this.qs(encodeURIComponent(JSON.stringify(dt(e.accessToken))),"authHeaders")}returnt+=this.qs(vt()&&"1","isAccountLinked"),t+=this.qs(this.shouldFetchAppAnonCookie()&&"1","fetchAppAnonCookie"),t}getSingleColRequest(e){constt="render_single_column",n="feed_layout";leto,i;for(constsofe){const{key:e,value:r}=s;e===t?o=r:e===n&&(i=r)}return"boolean"==typeofo?o:!!i&&(i&&"single"===i.type)}cookieBannerConsentRequired(){conste=null!=document.getElementById("consent-banner-container")&&null===u("MSCC"),t=null!=document.getElementById("onetrust-sdk")&&null===u("eupubconsent-v2");returne||t}shouldFetchAppAnonCookie(){if(!pt())return!0;conste=(()=>{conste=kt();if(e){if("MSA"===e.account_type)return"MSA";if("AAD"===e.account_type)return"AAD"}})();return"MSA"===e||p("lt")?!p("aace"):"AAD"===e?vt()&&!ct():void0}tryGetWebWorkerUsingPolicy(e,t){constn=S(t);if(n){constt=n.createScriptURL(e),o=t&&t.toString();if(!o||"about:blank#error"===o)return;window.webWorker=newWorker(t,{name:"web-worker"})}elsewindow.webWorker=newWorker(e,{name:"web-worker"});returnwindow.webWorker}getFlightList(){return((/^f:\s*([^;]+)/i.exec(this.domInfo)||{})[1]||"").toLowerCase().split(",")}}functionAt(e){returnnewPromise((t=>setTimeout(t,e)))}varCt,It;!function(e){e.Anon="ANON",e.AppAnon="APP_ANON",e.Unknown=""}(Ct||(Ct={})),function(e){e.AnonCookieExists="ace",e.AppAnonCookieExists="aace"}(It||(It={}));const_t="child";functionEt(e,t){if(e){constn=newRegExp("\\b"+t+"\\s*=\\s*([^;]*)","i").exec(e);returnn&&n.length>1?n[1]:null}returnnull}constqt="prg-pw-",xt="prg-",Tt="prg-1sw-",Pt="prg1flights";functionOt(e){lett=arguments.length>1&&void0!==arguments[1]?arguments[1]:xt;constn=t.length,o=[];returne&&e.length&&(e.forEach((e=>{consti=e&&e.trim();i&&i.length>=n&&i.substring(0,n).toLowerCase()===t&&o.push(i.toLowerCase())})),o.sort()),o}functionLt(e){vart;returndocument.head.dataset[e]||(null===(t=Rt())||void0===t?void0:t.dataset[e])}letNt;functionRt(){returnvoid0===Nt&&(Nt=document.getElementsByClassName("peregrine-widget-settings")[0]||null),Nt}!function(){lete=arguments.length>0&&void0!==arguments[0]?arguments[0]:{};constt={};try{varn,o,i;if(!D())returnt;consts=M(Lt("clientSettings"))||{};letr=null===(n=s.apptype)||void0===n?void0:n.toLocaleLowerCase();constc=e.crsOptions||{};"winwidgets"!==r&&"homepe"!==r||(c.crsPrefetch=!0),null!==(o=s.widgetAttributes)&&void0!==o&&null!==(o=o.clientPerf)&&void0!==o&&o.earlyCRSCall&&(c.crsPrefetch=!0),"edgechromium"===r&&(r="edgechr");consta=!(null===(i=s.widgetAttributes)||void0===i||null===(i=i.clientPerf)||void0===i||!i.shouldUsePWOnlyFlights),{all:d,prg:l}=function(){lete=arguments.length>0&&void0!==arguments[0]&&arguments[0];constt=Lt("info"),n=(t&&t.match(/f:\s*([^;]+)/i)||[])[1]||"",o=n.split(","),i=function(e){lett=xt;returnarguments.length>1&&void0!==arguments[1]&&arguments[1]?t=qt:null!=e&&e.includes(Pt)&&(t=Tt),t}(o,e),s=Ot(o,i);return{all:o,prg:s}}(a);(c.crsPrefetch||d.includes("inlinecrscall")||d.includes(`icrscall-${r}`))&&(!function(e,t,n){consto=function(e,t){letn;consto=decodeURIComponent(Et(e,"aace")),{child:i}=o&&M(o)||{},s=Et(e,_t);returnn=o&&(1===i||s)?"kids":t.audienceMode||"adult",n}(document.cookie,e),{apptype:i,browser:s,domain:r,bundleInfo:{v:c}={},deviceFormFactor:a,locale:{content:d,display:l}={},ocid:u,os:p,petype:h,servicesEndpoints:{crs:g}={}}=e,w=(Rt()?D()?window.location.hostname:we().url.hostname:r)||"";if(!i||!c||!g)return;constm={audienceMode:o,browser:s,deviceFormFactor:a,domain:w,locale:{content:d,display:l},ocid:u,os:p,platform:"web",peType:h,peExperiments:t},f=newURLSearchParams([["expType","AppConfig"],["expInstance","default"],["apptype",i],["v",c]]),b=`${g.path}${g.v}/config/?${f}&targetScope=${JSON.stringify(m)}`,v=e=>{constt=newURL(`${e}${b}`),{timeout:o=5e3}=n;leti;if(window.crsRequestData={url:t.toString()},o>=0){conste=newAbortController;setTimeout((()=>e.abort()),o),i=e.signal}returnfetch(t,{signal:i})},y="msn."+(function(e,t){return!!(e.hostname.toLowerCase().endsWith(".cn")||t.isChinaCompliance||t.useCnDomain||e.search.match(/item=revip:cn/))}(location,e)?"cn":"com"),{domain:k}=g,S=k&&newURL(k).host;letA=v(S||`assets.${y}`);n.disableFallback||(A=A.catch((()=>{const{hostname:e}=location,t=e.match(/\.msn\.(com|cn)$/)?e:`${y}`;returnv(t)})));window.crsPromise=A}(s,l,c),t.inlineCRS=!0)}catch(e){console.error("InlineHeadCommon:"+e)}}();constWt=document.head.attributes["data-info"].value;letMt;if(Wt){conste=Wt.split(";").find((e=>e.startsWith("f:")));e&&(Mt=e.substring(2),Mt.indexOf("1sw-pcsreturnhp")>-1&&m("PCSreturned.ExecutinginlineJS.",8e4,{customMesse:location.href},g.Deprecated))}functionDt(e){vart;return((null===(t=document.hMSN 香港 | 首頁ead)||void0===t||null===(t=t.getAttribute("data-info"))||void0===t?void0:t.split(";").find((e=>e.startsWith("f:"))))||"").includes(e)}Dt("hp-noww")||(newSt).init(),window.onerror=R,void0!==window.onunhandledrejection&&(window.onunhandledrejection=W),window.onErrorHandler=N,function(){lete=arguments.length>0&&void0!==arguments[0]?arguments[0]:["vendors","common","microsoft"],t=arguments.length>1&&void0!==arguments[1]?arguments[1]:"Errorwhenloadingbundle(s):",n=arguments.length>2&&void0!==arguments[2]?arguments[2]:5e5,o=arguments.length>3?arguments[3]:void0,i=arguments.length>4?arguments[4]:void0;a("msn-bndl-rtry")||a("msn-bndl-irtry")?P():y().then((()=>{setTimeout((()=>{constn=window.homePeWebpackChunks;if(n){consts=n.length,r=e.length+1;if(s{t.length&&t[0][0]&&e.splice(e.indexOf(t[0][0]),1)}))}k(),m(t+e.toString(),,{}),i&&(k(o),i(o,{customMesse:e.toString()}))}}}),n)}))}(),(Dt("prg-sdkpreload")||Dt("prg-renderoptimize"))&&asyncfunction(){window.apnt=window.apnt||{anq:[]},window.apnt.anq=window.apnt.anq||[],awaitasyncfunction(e){if(!D())return;const{src:t,id:n,async:o=!0,container:i=document.head,retryNumber:s=0,retryDelayMs:r=0}=e;try{awaitasyncfunction(e){lett=arguments.length>1&&void0!==arguments[1]?arguments[1]:3,n=arguments.length>2&&void0!==arguments[2]?arguments[2]:100;if(t3&&void0!==arguments[3])||arguments[3];returnnewPromise(((i,s)=>{constr=function(){lete=arguments.length>0&&void0!==arguments[0]?arguments[0]:void0,t=arguments.length>1&&void0!==arguments[1]?arguments[1]:void0,n=!(arguments.length>2&&void0!==arguments[2])||arguments[2],o=arguments.length>3&&void0!==arguments[3]?arguments[3]:"anonymous",i=arguments.length>4?arguments[4]:void0,s=arguments.length>5?arguments[5]:void0;if(!D())thrownewError("createScriptTisunsupportedserverside.ThiscallshouldbewrappedincanUseDOM().");constr=document.createElement("script");returnt&&(r.id=t),i&&r.setAttribute("class",i),s&&(r.onload=s),r.type="text/jascript",e&&(window&&window.trustedTypesURLValidation?r.src=window.trustedTypesURLValidation(e,"scriptSrcUrlPolicy"):r.src=e,r.async=n,r.crossOrigin=o),window&&window.NONCE_ID&&(r.nonce=window.NONCE_ID),r}(e,t,o,void0,void0,(()=>i(!0)));r.crossOrigin=void0,r.onerror=s,n.prepend(r)}))}(t,n,i,o)),s,r)}catch(e){m("FailedtodownloadStaticJS",,{scriptId:n,scriptSrc:t},g.Alert)}}({id:"display-sdk",src:"acdn.adnxs.com/ast/ast.js",container:document.head,retryDelayMs:200,retryNumber:5})}()}(); if(matchMedia("(prefers-color-scheme:dark)").matches){consts=document.createElement("style");document.head.appendChild(s);s.type="text/css";s.appendChild(document.createTextNode("body{background:#}"));}const_clientSettings=JSON.parse(document.head.dataset.clientSettings);functionpreloadConfigIDB(){consto=window.indexedDB;if(!o)return;conste="Configurations_12",n="IndexedDB-"+e+".",r=window._appTimings||(window._appTimings={});r[n+"open-Start"]=performance.now(),window._idbConfigLookup={};consti=window._idbConfigLookup;lett,s;window._idbConfigReadPromise=newPromise((o,e)=>{t=o,s=e}),window._idbConfigOpenPromise=(()=>{try{constd=o.open("wwConfigs",1);returnnewPromise((o,c)=>{d.onerror=(()=>{c(newError("ConfigIDBpreloadopenfailure:"+d.error))}),d.onsuccess=(()=>{r[n+"open-End"]=performance.now();constc=d.result;o(c),r[n+"getAllObjects-Start"]=performance.now();consta=c.transaction(e,"readonly").objectStore(e).openCursor();a.onsuccess=function(){consto=this.result;o?(i[o.key]=o.value,o.continue()):(r[n+"getAllObjects-End"]=performance.now(),t())},a.onerror=(()=>{s(newError("ConfigIDBpreloadreadfailure"))})}),d.onupgradeneeded=(()=>{d.result.createObjectStore(e)})})}catch(o){returnPromise.reject(newError("ConfigIDBpreloadopenfailure:"+o))}})()}preloadConfigIDB();functionappendProtocolQSP(url){returnurl;}functionappendScript(url,async,defer,fetchPriority=""){lets=document.createElement("script");s.type="text/jascript";constakmurl=appendProtocolQSP(url);constw=window.trustedTypesURLValidation;s.src=w?w(akmurl,"bundleUrlPolicy"):akmurl;if(async){s.async=true;}if(defer){s.defer=true;}if(fetchPriority){s.fetchPriority=fetchPriority;}s.onerror=()=>onErrorHandler(s.src);s.nonce="";s.crossOrigin="anonymous";document.body.appendChild(s);}