Latest News & Current Event Updates | Yahoo Malaysia (2024)

  • News
  • Malaysia
  • Sports
    • Football
  • Gaming
    • Esports
    • Dota 2
    • League of Legends
    • VALORANT
    • Genshin Impact
    • Honkai: Star Rail
  • Finance
  • Lifestyle
    • Horoscope
    • Celebrity
    • Movies
    • Shopping
  • Tech
    • Metaverse
  • 中文新闻
    • 娱乐新闻

    ':"";if(a){var r=n.promos.showYahooLogo?"":"yns-no-logo";a=a.replace("{notifOnboardBtnLabel}",n.promos.notifOnboardBtnLabel).replace("{notifOnboardMsg}",n.promos.notifOnboardMsg).replace("{subscriptionTopic}",n.promos.subscriptionTopic).replace("{noLogoClass}",r).replace("{promoLogo}",n.promos.promoLogo)}var s=t.newCount>n.panel.maxCount?t.newCount:"",c=n.panel.notificationCenterPath,l=c?"":B,d=n.panel.headerMsg?"":" "+B,u=c?R:"",p=void 0;t.count?p=t.markup:p='

  • {emptyPanelMsg}

  • '.replace("{emptyPanelMsg}",n.panel.emptyPanelMsg);return e=e.replace("{notifMarkup}",p).replace("{promoMarkup}",a).replace("{hideClass}",l).replace("{notifCenterLink}",c).replace("{paddingClass}",u).replace("{headerMsg}",n.panel.headerMsg).replace("{hideHeaderClass}",d).replace(/{notificationCenterNavMsg}/g,n.panel.notificationCenterNavMsg).replace(/{newCount}/g,s)}},{key:"render",value:function(e,t){var n=this;if(n._panelNode){var i=void 0,o=n._panelNode,a=void 0,r=void 0;switch(e){case"expanded_panel":i='

    {headerMsg}

      {promoMarkup}{notifMarkup}

    {notificationCenterNavMsg}

    ',r=n._store.getNotifications(),a=n._generatePanelMarkup(i,r),o.innerHTML=a;break;case"error_panel":a=(i='

    {errorMsg}

    ').replace("{errorMsg}",n._config.panel.errorMsg),o.innerHTML=a}t&&t()}else t&&t(new Error("No panel parent"))}},{key:"createPanelParentNode",value:function(e){e&&(e.innerHTML='

    ',this._panelNode=document.getElementById(O))}},{key:"updateBadgeNode",value:function(e){if(e){var t=this._store.getNotifications().newCount,n=this._config.badge.maxCount;if(t){var i=t>n?n+"+":t;e.innerHTML=i}else e.innerHTML=""}}},{key:"addStyles",value:function(e){if(e&&"undefined"!=typeof window){var t=document.getElementById(this._config.panel.styleTagId);t||((t=document.createElement("style")).type="text/css",t.id=this._config.panel.styleTagId,t.innerText=e,document.head.appendChild(t))}}}]),e}(),P=function(){function e(t,n,i){E(this,e);var o=this;o._store=n,o._view=i,o._config=t;var a=o._config.panel;o._panelParentNode=document.querySelector(a.parentSelector),o._badgeNode=o._config.badge.selector&&document.querySelector(o._config.badge.selector),o._indicatorNode=a.indicatorSelector&&document.querySelector(a.indicatorSelector)}return x(e,[{key:"createPanelParentNode",value:function(){this._view.createPanelParentNode(this._panelParentNode),this._notifPanelNode=document.getElementById(O)}},{key:"refreshPanelNode",value:function(e,t){var n=this;L(n._notifPanelNode,M),n._store.fetchNotifications(e,(function(e,i){var o=window.wafer&&window.wafer.base;o&&o.destroy(n._notifPanelNode),e?n._notifPanelNode.innerHTML||(n._view.render("error_panel"),L(n._notifPanelNode,M)):(n._view.render("expanded_panel"),n._view.updateBadgeNode(n._badgeNode),n._showBadge(),n._showIndicator(),n._view.addStyles(i.css)),A(n._notifPanelNode,M),o&&o.sync(n._notifPanelNode.parentNode),t&&t(e,i)}))}},{key:"resetBadge",value:function(){var e=this;e._store.resetNewCount(),e._view.updateBadgeNode(e._badgeNode),L(e._badgeNode,e._config.badge.hideClass)}},{key:"_showIndicator",value:function(){this._indicatorNode&&(this._store.getNotifications().newCount?L(this._indicatorNode,this._config.panel.indicatorClass):A(this._indicatorNode,this._config.panel.indicatorClass))}},{key:"_showBadge",value:function(){var e=this;e._store.getNotifications().newCount?A(e._badgeNode,e._config.badge.hideClass):L(e._badgeNode,e._config.badge.hideClass)}}]),e}(),H={promos:{eligibleBodyClass:"display-push-promos",enableNotifOnboard:!0,bypassEligibleClassCheck:!1,notifOnboardBtnLabel:"Notify Me",notifOnboardMsg:"Get alerts for breaking news and top stories",promoLogo:"https://s.yimg.com/cv/apiv2/ae/news/circle_bell.png",showYahooLogo:!0,subscriptionTopic:"gondor_homerun_news"},badge:{hideClass:"",maxCount:5,selector:""},panel:{emptyPanelMsg:"You have no new notifications.",errorMsg:"",headerMsg:"Notifications",imageTag:"img:40x40|2|80",indicatorClass:"yns-indicator",indicatorSelector:null,maxCount:6,notificationCenterNavMsg:"View all {newCount} notifications",notificationCenterPath:"",notificationTypes:"",parentSelector:null,styleTagId:"notificationStyles",theme:"default"},service:{attemptCount:1,attemptDelay:2,url:null,resetUrl:null,isRMP:!1,responseType:"json",timeout:1500}},D={NotificationClient:function(){function e(t){E(this,e);var n=this;n.config=n._parseConfig(t),n._validateRequiredConfigs()&&(n._request=new k(n.config),n._store=new N(n.config,n._request),n._view=new q(n.config,n._store),n._panelController=new P(n.config,n._store,n._view),n._panelController.createPanelParentNode(),n._assignHelperMethods())}return x(e,[{key:"_parseConfig",value:function(e){var t={};for(var n in T(t,H),t)if(t.hasOwnProperty(n)){var i=t[n],o=e[n];"object"===(void 0===i?"undefined":_(i))?T(i,o):t[n]=e[n]}return t}},{key:"_validateRequiredConfigs",value:function(){var e=this.config;return!(!e.panel.parentSelector||!e.service.url)}},{key:"_assignHelperMethods",value:function(){var e=this;e.helpers={refreshPanelNode:e._panelController.refreshPanelNode.bind(e._panelController),resetBadge:e._panelController.resetBadge.bind(e._panelController),resetIndicator:function(){A(e._panelController._indicatorNode,e.config.panel.indicatorClass)}}}}]),e}()},F="lnct",U=function(){function e(){var e,t;this.personalized=!1,this.ybarElem=document.getElementById("ybar"),this.partnerClasses=null===(t=null===(e=this.ybarElem)||void 0===e?void 0:e.className)||void 0===t?void 0:t.match(/ybar-variant-([a-z]*)/),this.client=new D.NotificationClient(this.getConfig())}return e.prototype.refreshPanel=function(){var e,t,n,i=this,o={lastUpdate:this.getTimeStamp()||this.setTimeStamp(),loadInHpViewer:!0,includePersonalized:this.personalized},a=(null===(e=window.YAHOO)||void 0===e?void 0:e.context)||(null===(t=window.Af)||void 0===t?void 0:t.context)||{};return a.region&&a.lang&&(o.lang=a.lang,o.region=a.region),(null===(n=this.partnerClasses)||void 0===n?void 0:n.length)&&(o.partner=this.partnerClasses[1]),new Promise((function(e,t){i.client.helpers.refreshPanelNode({matrixParams:o},(function(n,i){n&&(c("Notification refresh error:",n),t(n)),e(i)}))}))},e.prototype.resetBadge=function(){this.client.helpers.resetBadge(),this.setTimeStamp()},e.prototype.getConfig=function(){var e,t,n,i,o,a=document.getElementById("notification-container"),r=null===(e=null==a?void 0:a.dataset)||void 0===e?void 0:e.config;if(I&&!r)return I;var s={promos:{eligibleBodyClass:"display-push-promos",enableNotifOnboard:!0},badge:{selector:"#notif-badge",hideClass:"ybar-notification-hidden"},panel:{emptyPanelMsg:"You have no new notifications.",errorMsg:"Please check back later.",headerMsg:"Notifications",maxCount:5,parentSelector:"#ybarNotificationBody",notificationTypes:"breakingNews"},service:{url:"/tdv2_fp/api/resource/NotificationHistory.getHistory",isRMP:!1}},l={};if(r){"att"===(null===(t=this.partnerClasses)||void 0===t?void 0:t[1])&&(s.promos.showYahooLogo=!1);try{var d=JSON.parse(r);l=h({},d),this.personalized=1===d.personalize}catch(e){c("Notifications config parsing error",e)}a&&delete a.dataset.config}return I=this.mergeConfigs(s,l),(null===(n=this.partnerClasses)||void 0===n?void 0:n.length)&&"yahoo"!==(null===(i=this.partnerClasses)||void 0===i?void 0:i[1])&&(null===(o=I.promos)||void 0===o?void 0:o.subscriptionTopic)&&delete I.promos.subscriptionTopic,I},e.prototype.mergeConfigs=function(e,t){var n=h({},e);for(var i in e)n[i]=h(h({},e[i]),t[i]);return n},e.prototype.getTimeStamp=function(){var e;return null===(e=window.localStorage)||void 0===e?void 0:e.getItem(F)},e.prototype.setTimeStamp=function(){var e,t=""+Math.floor((new Date).getTime()/1e3);return null===(e=window.localStorage)||void 0===e||e.setItem(F,t),t},e}();new U;var Y,j,G="",z=[],W=function(){},V=function(){window.removeEventListener("beforeunload",V),""!==G&&c("Rapid not found on page",new Error(G))},K=null,Z=function(){return null===K&&(K=document.getElementById("ybar")),K},J=function(){var e=0,t=window.YAHOO;if(Y)return Y;if(t)if(t.i13n)if(t.i13n.__RAPID_INSTANCES__)if(t.i13n.__RAPID_INSTANCES__.length<1)G="YBAR: no instances of rapid found!";else{var n=function(e){var t=void 0;if(e&&e.length>0)for(var n=0;n

    0){if(Y.addModules(o,!1,i),z.length>0)for(e=0;e40959)&&(o<13312||o>19903)&&(o<44032||o>55215))return!1}return!0},he={navBeaconFired:!1},me=["ready","navigation"],fe=function(){function e(e){var t=this;this.triggerEvent=r,this.addEventListener=s,this.logError=c,this.logPerformance=l,this.getConfig=d,this.getPerformanceMetrics=u,this.rapidRefresh=X,this.state=h({},he),this.modules=e,this.userEmail="",window.YBAR&&(me.forEach((function(e){var n="on".concat(e),i=window.YBAR[n];i&&(t[n]=i)})),window.YBAR.wssid&&(this.wssid=window.YBAR.wssid),window.YBAR.appid&&(this.appid=window.YBAR.appid)),me.forEach((function(e){var n="on".concat(e);s(e,(function(){for(var i,o=[],a=0;a0,i=_.scrollTope.pageOffset,a=_.scrollTop>x+y,r=_.scrollTop90&&Ie("performance",e)}catch(e){}}),1e3)})),se(),s("error",(function(e){var t=e&&e.detail||{},n=t.error||{},i=t.message||n.message||n.toString();try{var o={code:n.name,file:n.fileName||"",line:n.lineNumber||"",message:i};Ie("error",o)}catch(e){}}));var Me="_yb_1l8czky",Oe="_yb_14iqc0j",Be="_yb_17xlvp1",Re="_yb_gz4klx";if("undefined"!=typeof Element&&!Element.prototype.matches){var qe=Element.prototype;qe.matches=qe.matchesSelector||qe.mozMatchesSelector||qe.msMatchesSelector||qe.oMatchesSelector||qe.webkitMatchesSelector}var Pe=function(e,t){for(;e&&9!==e.nodeType;){if("function"==typeof e.matches&&e.matches(t))return e;e=e.parentNode}};function He(e,t,n,i,o){var a=De.apply(this,arguments);return e.addEventListener(n,a,o),{destroy:function(){e.removeEventListener(n,a,o)}}}function De(e,t,n,i){return function(n){n.delegateTarget=Pe(n.target,t),n.delegateTarget&&i.call(e,n)}}var Fe,Ue=function(e,t,n,i,o){return"function"==typeof e.addEventListener?He.apply(null,arguments):"function"==typeof n?He.bind(null,document).apply(null,arguments):("string"==typeof e&&(e=document.querySelectorAll(e)),Array.prototype.map.call(e,(function(e){return He(e,t,n,i,o)})))},Ye=function(e){this.data=e,this.next=null,this.prev=null},je=function(){function e(){this.head=null,this.tail=null}return e.prototype.push=function(e){var t=new Ye(e);return this.head?this.tail?(t.prev=this.tail,this.tail.next=t,this.tail=t):(this.tail=t,this.tail.prev=this.head,this.head.next=this.tail):(this.head=t,t.next=this.tail),t},e.prototype.size=function(){for(var e=0,t=this.head;t;)e+=1,t=t.next;return e},e.prototype.getHead=function(){return this.head},e.prototype.getTail=function(){return this.tail},e.prototype.get=function(e){if(e>=this.size())return null;for(var t=0,n=this.head;(null==n?void 0:n.next)&&t=200&&o.status<=299,status:o.status,text:function(){return Promise.resolve(o.responseText)},json:function(){return new Promise((function(e,t){try{e(JSON.parse(o.responseText))}catch(e){t(e)}}))}})},o.send(t.body)}))]}))}))},It=function(e,t){return void 0===t&&(t={}),("function"==typeof window.fetch?fetch:Tt)(e,t)},Nt=function(e,t){var n=e.url,i=e.headers,o=void 0===i?{}:i;return o["X-Requested-With"]="XMLHttpRequest",It(n,{headers:o,credentials:"include"}).then((function(e){return e.text().then((function(n){At({status:e.status,responseText:n},t)}))}))};!function(e){e[e.COUNT=0]="COUNT"}(Xe||(Xe={})),function(e){e[e.PENDING=0]="PENDING",e[e.COMPLETE=1]="COMPLETE"}($e||($e={}));var Mt={0:0,1:1,9:9,99:99,150:150},Ot=new Map,Bt=function(){function e(){}return Object.defineProperty(e.prototype,"wssid",{get:function(){var e,t,n=null===(e=window.YBAR)||void 0===e?void 0:e.wssid;return n||(n=(null===(t=document.querySelector('input[name="mail_wssid"]'))||void 0===t?void 0:t.value)||"",this.wssid=n),n},set:function(e){window.YBAR=window.YBAR||{},window.YBAR.wssid=e||""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"appid",{get:function(){var e,t,n=null===(e=window.YBAR)||void 0===e?void 0:e.appid;return n||(n=(null===(t=document.querySelector('input[name="mail_appid"]'))||void 0===t?void 0:t.value)||"",this.appid=n),n},set:function(e){window.YBAR=window.YBAR||{},window.YBAR.appid=e||""},enumerable:!1,configurable:!0}),e.prototype.fetchCount=function(e){return m(this,void 0,void 0,(function(){var t,n,i,o,a=this;return f(this,(function(r){return t=function(e){var t=Ot.get(e);if(t){if(t.status===$e.PENDING)return t.promise;var n=Date.now()-12e4;return t.data&&t.lastRequested>n?Promise.resolve(t.data):void 0}}(Xe.COUNT),(n=this._checkForMockData())?[2,n]:!e&&t?[2,t]:(1,i={data:{responseType:"json",requests:[{id:"GetMailboxId",uri:"/ws/v3/mailboxes/",method:"GET",filters:{select:{mailboxId:"$..mailboxes[?(@.isPrimary==true)].id"}},suppressResponse:!0,requests:[{id:"ListDecos",uri:"/ws/v3/mailboxes/@.id==$(mailboxId)/decos",method:"GET"}]}]}},o=this._fetch(i,1,(function(e){var t=a._normalizerCountResponse(e);return function(e,t){var n={lastRequested:Date.now(),status:$e.COMPLETE,promise:Promise.resolve(t),data:t};Ot.set(e,n)}(Xe.COUNT,t),t})),s=Xe.COUNT,c=o,l={lastRequested:Date.now(),status:$e.PENDING,promise:c},Ot.set(s,l),[2,o]);var s,c,l}))}))},e.prototype._fetch=function(e,t,n){var i,o;return m(this,void 0,void 0,(function(){var a,r,s,l,d,u,p,m,v,y,g,b,w,_,E,x;return f(this,(function(f){switch(f.label){case 0:if(a=e.data,r=void 0===a?{}:a,s=e.params,l=void 0===s?{}:s,d="EC-4008",u="EC-4003",p=this._getYmreqid(),!this.appid)throw new Error("No appId, user is logged out");m=h({appId:this.appid},l),this.wssid&&(m.wssid=this.wssid),e.params=m,v=[],Object.keys(m).forEach((function(e){var t=m[e];t&&v.push("".concat(encodeURIComponent(e),"=").concat(encodeURIComponent(t)))})),y=v.length?"?".concat(v.join("&")):"",g="https://apis.mail.yahoo.com/ws/v3/batch".concat(y),f.label=1;case 1:return f.trys.push([1,4,,5]),[4,It(g,{method:"POST",body:JSON.stringify(r),credentials:"include",headers:{"Content-Type":"application/json","X-Oath-YmReqId":p}})];case 2:return[4,(b=f.sent()).json()];case 3:if(w=f.sent(),b.ok)return[2,n(null===(o=w.result)||void 0===o?void 0:o.responses)];if((_=null===(i=null==w?void 0:w.error)||void 0===i?void 0:i.code)===u)return[2,this._handleWssidApiError(w,e,t,n)];throw _===d?new Error("Session has expired"):new Error("Mail Api Responded with an Error");case 4:throw E=f.sent(),c("JWS: ".concat((x=E).message),x),E;case 5:return[2]}}))}))},e.prototype._checkForMockData=function(){var e=document.getElementById("ybar");if(e&&e.hasAttribute("data-mc")){var t=e.getAttribute("data-mc");if(t&&Mt[t])return Mt[t]}},e.prototype._normalizerCountResponse=function(e){var t,n,i,o,a,r;if(!e)return 0;var s=((null===(i=null===(n=null===(t=null==e?void 0:e[0])||void 0===t?void 0:t.response)||void 0===n?void 0:n.result)||void 0===i?void 0:i.decos)||[]).find((function(e){return"FTI"===(null==e?void 0:e.id)}));return s&&null!==(r=null===(a=null===(o=null==s?void 0:s.counts)||void 0===o?void 0:o[0])||void 0===a?void 0:a.unseen)&&void 0!==r?r:0},e.prototype._handleWssidApiError=function(e,t,n,i){var o,a,r=null===(a=null===(o=null==e?void 0:e.error)||void 0===o?void 0:o.details)||void 0===a?void 0:a.wssid,s=t.params,c=(void 0===s?{}:s).wssid;if(r){if(c&&r===c)throw new Error("API provided same invalid WSSID");if(void 0!==n&&n>0)return n-=1,this.wssid=r,this._fetch(t,n,i);throw new Error("Max retries with invalid WSSID reached")}throw new Error("valid WSSID missing from API Response")},e.prototype._getYmreqid=function(){var e=(new Date).getTime();return"xxxxxxxx-xxxx-xxxx-09xx-xxxxxxxxxx00".replace(new RegExp("x","g"),(function(){var t=(e+16*Math.random())%16|0;return e=Math.floor(e/16),t.toString(16)}))},e}(),Rt={add:[{itemId:"ybar-mail-banner",reactions:["SHOWN"]}]};ye("ybar-mod-sidenav",(function(e){var t,n={sidenavBtn:document.getElementById("_yb_sidenav-btn"),sidenav:document.querySelector(".".concat(yt)),menu:document.querySelector(".".concat(bt)),sections:document.querySelectorAll(".".concat(ht)),closeBtn:document.querySelector(".".concat(tt)),panels:document.querySelectorAll(".".concat(pt)),backBtn:document.querySelector(".".concat(et)),footer:document.querySelector(".".concat(st)),copyright:document.querySelector(".".concat(it)),selectedSectionLinks:document.querySelectorAll(".".concat(ft," a")),focusedElement:document.querySelector(".".concat(ft," .").concat(rt)),editionsDropdown:document.querySelector(".".concat(ot)),mailUnread:document.querySelector(".".concat(_t)),mailTooltip:document.getElementById("_yb_mail-tooltip"),tooltipClose:document.getElementById("_yb_mail-tooltip-close")},i=window.location.href.split("?")[0]?window.location.href.split("?")[0].replace(/\/$/,""):window.location.href,o=y([],v(n.selectedSectionLinks),!1);if(!n.focusedElement)for(var a=0;a0){if(i&&o){var n=t>99;i.classList.add("".concat(kt)),o.classList.add("count-loaded"),i.textContent=n?"99+":t+"",n?i.classList.add("".concat(Et)):t>=10&&i.classList.add("".concat(xt))}e.onDestroy((function(){i&&(i.textContent="")}))}})).catch((function(){}))}(e,s)}));var qt="_yb_169o3ip",Pt=function(e,t){var n;t.logoImages&&(n=t.logoImages).length>0&&Array.prototype.forEach.call(n,(function(e){e.onerror=function(){e.onerror=null,e.style.display="none"}})),t.wrapper&&(function(e,t){e&&(Ce("#ybar-logo","#ybar-logo",t),t.onDestroy((function(){e.classList.remove("ybar-show-outline"),e.classList.remove("ybar-hide-outline")})))}(t.wrapper,e),function(e,t){t&&e.addElementListener(t,"click",(function(){e.triggerEvent("logo-click")}))}(e,t.wrapper))};ye("ybar-mod-logo",(function(e){var t={wrapper:document.getElementById("ybar-logo"),logoImages:document.querySelectorAll(".".concat(qt))};Pt(e,t)}));var Ht={"dropdown-open":"_yb_ggc49u","merchant-is-selected":"_yb_1ezljfd",overlay:"_yb_nj516i","selected-merchant-clear-button":"_yb_pepb29","shops-buttons":"_yb_916j6n","styled-select":"_yb_87ucwm",tooltip:"_yb_nnkk2d","tooltip--show":"_yb_etrf92",tooltip__text:"_yb_1kz8qw8",tooltip__voice:"_yb_1cmygz",tooltip__web:"_yb_ewn3qd",dark:"_yb_3wysvw",darker:"_yb_81e5ez",light:"_yb_1mh1ewu",midnight60:"_yb_s05yd6","search-input-uh3-hover":"_yb_19r0nul","search-input-uh3-focus-visible":"_yb_13phab8","sa-btn-bar":"_yb_2f3mor","searchbox-icon-uh3":"_yb_1fgizpa",empty:"_yb_1misaet"},Dt=function(e,t){var n=Math.max(e,t),i=Math.min(e,t),o=Math.abs(n-i);return y([],v(new Array(o+1)),!1).map((function(e,t){return i+t}))},Ft=function(e,t,n){var i=e.getConfig().bucketConfig,o=(void 0===i?{}:i).enable_search_ui,a=void 0!==o&&o;if(t.ybar){t.ybar.classList.add("ybar-searchbox-assist-fullscreen"),document.documentElement.classList.add("ybar-overlay"),document.body.classList.add("ybar-overlay-noscroll");Q("ybar","websrch","",{elm:"expand",subsec:"searchbox",itc:"1"}),setTimeout((function(){t.searchInput instanceof HTMLInputElement&&(n&&(t.searchInput.value=n),t.searchInput.focus(),a&&window.YAHOO&&window.YAHOO.SA&&window.YAHOO.SA.apps&&window.YAHOO.SA.apps[0]&&window.YAHOO.SA.apps[0].view&&!window.YAHOO.SA.apps[0].view.shown&&window.YAHOO.SA.apps[0].view.show())}))}},Ut=function(e){var t;null===(t=e.ybar)||void 0===t||t.classList.remove("ybar-searchbox-assist-fullscreen"),document.documentElement.classList.remove("ybar-overlay"),document.body.classList.remove("ybar-overlay-noscroll"),e.searchInput instanceof HTMLInputElement&&(e.searchInput.value="",e.searchInput.blur())},Yt=function(){function e(e,t,n){t&&(this.ybar=e,this.elem=t,this.options=n,this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.addEventListeners())}return Object.defineProperty(e.prototype,"tooltip",{get:function(){var e=this;return this.tooltipMarkup||(this.tooltipMarkup=this.createTooltip(),(this.options.tooltipParentElm||this.elem).appendChild(this.tooltipMarkup),this.ybar.onDestroy((function(){var t,n;null===(n=null===(t=e.tooltipMarkup)||void 0===t?void 0:t.parentNode)||void 0===n||n.removeChild(e.tooltipMarkup)}))),this.tooltipMarkup},enumerable:!1,configurable:!0}),e.prototype.show=function(){this.tooltip.classList.add(this.options.showClass)},e.prototype.hide=function(){this.tooltip.classList.remove(this.options.showClass)},e.prototype.addEventListeners=function(){this.ybar.addElementListener(this.elem,"mouseenter",this.show),this.ybar.addElementListener(this.elem,"focus",this.show),this.ybar.addElementListener(this.elem,"mouseleave",this.hide),this.ybar.addElementListener(this.elem,"blur",this.hide)},e.prototype.createTooltip=function(){var e=document.createElement("div");e.className=this.options.containerClass||"";var t=document.createElement("p");return t.textContent=this.options.label,t.className=this.options.textClass||"",e.appendChild(t),e},e}();!function(){var e,t,n,i,o,a,r,s,c,l,d,u,p,h,m,f={516:function(e,t,n){var i,o,a,r;e.exports=(i=n(336),o="default",a=function(e){return e.reduce((function(e,t){return e[t.id]=t.defaultMessage,e}),{})},((r=function(e){var t;this.lang=(t=e&&e.lang,-1!==i.indexOf(t)?e.lang:o)}).langMap={})[o]=a(n(559)),r.setLangMap=function(e,t){e&&t&&(r.langMap[e]=a(t))},r.prototype={t:function(e){switch(!0){case Boolean(r.langMap&&r.langMap[this.lang]&&r.langMap[this.lang][e]):return r.langMap[this.lang][e];case Boolean(r.langMap&&r.langMap[o]&&r.langMap[o][e]):return r.langMap[o][e];default:return""}}},r)},383:function(e,t,n){var i=n(645),o=n.n(i)()((function(e){return e[1]}));o.push([e.id,'/* Sprites */\n#spchp.permission-guide .guide .microphone .sprite,\n#spchp .close-button,\n#spch .close-button,\n#spch .spchc .microphone,\n#spch .spchc .speaking .microphone {\n background-image: url("https://s.yimg.com/pv/static/img/voiceSearch1x-1620383531565.min.png");\n background-repeat: no-repeat;\n background-size: initial;\n color: transparent;\n}\n/* Retina displays */\n@media\n only screen and (min-device-pixel-ratio: 2),\n only screen and (-webkit-min-device-pixel-ratio: 2),\n only screen and (min-resolution: 192dpi),\n only screen and (min-resolution: 2dppx) {\n#spchp.permission-guide .guide .microphone .sprite,\n#spchp .close-button,\n#spch .close-button,\n#spch .spchc .microphone,\n#spch .spchc .speaking .microphone {\n background-size: 41px 330px;\n background-image: url("https://s.yimg.com/pv/static/img/voiceSearch2x-1620383531565.min.png")\n}\n }\n\n/* permission guide */\n#spchp.permission-guide {\n height: 100%;\n width: 100%;\n padding: 0;\n opacity: 0.9;\n background-color: #fff;\n left: 0;\n overflow: hidden;\n position: fixed;\n text-align: left;\n top: 0;\n z-index: 10000;\n transition: visibility 0s linear 0.218s, background-color 0.218s;\n}\n#spchp.permission-guide .close-button {\n background-position: 0 0;\n width: 24px;\n height: 24px;\n border: none;\n cursor: pointer;\n right: 0;\n margin: 20px;\n padding: 0;\n position: absolute;\n top: 0;\n z-index: 10;\n opacity: 0.8;\n }\n#spchp.permission-guide .close-button:hover {\n opacity: 1;\n }\n#spchp.permission-guide .guide {\n margin: 191px 0 0 507px;\n }\n#spchp.permission-guide .guide .microphone {\n height: 68px;\n width: 52px;\n border-right: 1px solid #232a31;\n float: left;\n }\n#spchp.permission-guide .guide .microphone .sprite {\n background-position: 0 -105px;\n width: 28px;\n height: 28px;\n }\n#spchp.permission-guide .guide .guide-text {\n height: 68px;\n margin-left: 24px;\n float: left;\n }\n#spchp.permission-guide .guide .guide-text .title {\n color: #232a31;\n font-size: 32px;\n font-family: HelveticaNeue-Bold;\n line-height: 28px;\n margin-bottom: 16px;\n }\n#spchp.permission-guide .guide .guide-text .text {\n color: #232a31;\n font-size: 16px;\n line-height: 28px;\n }\n#spchp.permission-guide.hide {\n display: none;\n }\n\n/* speech panel */\n#spch.spch {\n background: #fff;\n height: 100%;\n left: 0;\n opacity: 0;\n overflow: hidden;\n position: fixed;\n text-align: left;\n top: 0;\n visibility: hidden;\n width: 100%;\n z-index: 10000;\n transition: visibility 0s linear 0.218s, background-color 0.218s;\n}\n#spch.spch .close-button {\n background-position: 0 0;\n width: 24px;\n height: 24px;\n border: none;\n cursor: pointer;\n right: 0;\n margin: 20px;\n padding: 0;\n position: absolute;\n top: 0;\n z-index: 10;\n opacity: 0.8;\n }\n#spch.spch .close-button:hover {\n opacity: 1;\n }\n#spch.spch .spchc {\n display: block;\n height: 97px;\n pointer-events: none;\n }\n#spch.spch .spchc .inner-container {\n width: 100%;\n height: 100%;\n opacity: 0.1;\n pointer-events: none;\n transition: opacity 0.318s ease-in;\n }\n#spch.spch .spchc .inner-container .spch-control {\n display: inline-block;\n }\n#spch.spch .spchc .inner-container .text-container {\n float: left;\n height: 91px;\n overflow: hidden;\n margin: 3px 0;\n pointer-events: none;\n width: calc(50% - 48.5px);\n }\n#spch.spch .spchc .inner-container .text-container p {\n display: table-cell;\n vertical-align: middle;\n width: 550px;\n height: 97px;\n }\n#spch.spch .spchc .inner-container .text-container .spcht {\n font-weight: normal;\n color: #6e7780;\n line-height: normal;\n opacity: 0;\n pointer-events: none;\n text-align: left;\n -webkit-font-smoothing: antialiased;\n transition: opacity 0.1s ease-in, margin-left 0.5s ease-in, top 0s linear 0.218s;\n }\n#spch.spch .spchc .inner-container .text-container .spcht.hide {\n display: none;\n }\n#spch.spch .spchc .inner-container .text-container #spcht-retry {\n color: #0f69ff;\n cursor: pointer;\n pointer-events: auto;\n }\n#spch.spch .spchc .inner-container .button-container {\n pointer-events: none;\n position: relative;\n transition: transform 0.218s, opacity 0.218s ease-in;\n }\n#spch.spch .spchc .inner-container .button-container .button {\n background-color: #fff;\n border: 1px solid #eee;\n border-radius: 100%;\n bottom: 0;\n box-shadow: 0 2px 5px rgb(0 0 0 / 10%);\n cursor: pointer;\n display: inline-block;\n left: 0;\n opacity: 0;\n pointer-events: none;\n position: absolute;\n right: 0;\n top: 0;\n transition: background-color 0.218s, border 0.218s, box-shadow 0.218s;\n }\n#spch.spch .spchc .inner-container .button-container .button .microphone {\n background-position: 0 -24px;\n width: 41px;\n height: 41px;\n left: 27px;\n pointer-events: none;\n position: absolute;\n top: 27px;\n transform: scale(1);\n }\n#spch.spch .spchc .inner-container .button-container.listening .ripple {\n position: absolute;\n width: 136px;\n height: 136px;\n z-index: -1;\n left: 50%;\n top: 50%;\n opacity: 0;\n margin: -70px 0 0 -70px;\n border-radius: 100px;\n animation: ripple 3.3s infinite;\n background-color: #fff !important;\n border: 2px solid #e0e4e9;\n }\n#spch.spch .spchc .inner-container .button-container.listening .ripple:nth-child(2) {\n animation-delay: 1.1s;\n }\n#spch.spch .spchc .inner-container .button-container.listening .ripple:nth-child(3) {\n animation-delay: 2.2s;\n }\n#spch.spch .spchc .inner-container .button-container.speaking .button {\n background-color: #0f69ff;\n }\n#spch.spch .spchc .inner-container .button-container.speaking .button .microphone {\n background-position: 0 -65px;\n width: 40px;\n height: 40px;\n pointer-events: none;\n position: absolute;\n transform: scale(1);\n }\n#spch.spch .spchc .inner-container .button-container.speaking .ripple {\n background-size: 114px;\n position: absolute;\n width: 114px;\n height: 114px;\n z-index: -1;\n left: 50%;\n top: 50%;\n margin: -57px 0 0 -57px;\n animation: speakingRipple1 2s infinite;\n }\n#spch.spch .spchc .inner-container .button-container.speaking .ripple:nth-child(2) {\n background-size: 123px;\n width: 123px;\n height: 123px;\n margin: -62px 0 0 -62px;\n animation: speakingRipple2 2s infinite;\n }\n#spch.spch .spchc .inner-container .button-container.speaking .ripple:nth-child(3) {\n background-size: 136px;\n width: 136px;\n height: 136px;\n margin: -68px 0 0 -68px;\n animation: speakingRipple3 2s infinite;\n }\n#spch.spch .spcho {\n background-image: linear-gradient(to bottom, rgb(255 255 255) 50%, rgb(255 255 255 / 0%) 99%);\n display: block;\n min-width: 100%;\n text-align: center;\n top: 145px;\n padding-bottom: 71px;\n pointer-events: auto;\n }\n#spch.spch .spcho #spch-trending {\n animation: fadeIn 1s forwards;\n opacity: 0;\n }\n#spch.spch .spcho #spch-trending .trending {\n color: #6e7780;\n display: inline-block;\n font-size: 16px;\n }\n#spch.spch .spcho #spch-trending #trending-label {\n font-weight: bold;\n margin: 5px;\n }\n#spch.spch .spcho #spch-trending.hide {\n display: none;\n }\n#spch.spch.s2tb .spchc, #spch.spch.s2tb-h .spchc {\n background: #fff;\n box-sizing: border-box;\n box-shadow: 0 2px 6px rgb(0 0 0 / 20%);\n height: auto;\n margin: 0;\n min-width: 100%;\n overflow: hidden;\n padding: 24px 115px;\n }\n#spch.spch.s2tb .spchc .inner-container, #spch.spch.s2tb-h .spchc .inner-container {\n opacity: 1;\n transition: opacity 0.318s ease-in;\n }\n#spch.spch.s2tb .spchc .inner-container .text-container, #spch.spch.s2tb-h .spchc .inner-container .text-container {\n position: relative;\n }\n#spch.spch.s2tb {\n background: rgb(255 255 255 / 0%);\n opacity: 1;\n visibility: visible;\n transition-delay: 0s;\n }\n#spch.spch.s2tb .spchc .inner-container .button-container {\n transform: scale(1);\n height: 97px;\n right: 0;\n top: 0;\n width: 97px;\n }\n#spch.spch.s2tb .spchc .inner-container .button-container .button {\n opacity: 1;\n pointer-events: auto;\n position: absolute;\n transform: scale(1);\n transition-delay: 0;\n }\n#spch.spch.s2tb .spchc .inner-container .text-container .spcht {\n font-size: 24px;\n margin-left: 0;\n opacity: 1;\n transition: opacity 0.5s ease-out, margin-left 0.5s ease-out;\n }\n#spch.spch.s2tb #spch-overlay {\n -webkit-backdrop-filter: blur(10px);\n backdrop-filter: blur(10px);\n background-color: #fff;\n height: 100%;\n opacity: 0.9;\n position: absolute;\n top: 149px;\n\n /* spchc\'s height */\n width: 100%;\n }\n#spch.spch.disable-blur-overlay #spch-overlay {\n background-color: transparent;\n\n /* stylelint-disable-next-line property-no-vendor-prefix */\n -webkit-backdrop-filter: none;\n backdrop-filter: none;\n }\n#spch.spch.disable-blur-overlay .spcho {\n height: 27px;\n padding-bottom: 20px;\n background: #fff;\n background-image: none;\n\n /* stylelint-disable-next-line property-no-vendor-prefix */\n\n /* stylelint-disable-next-line property-no-vendor-prefix */\n box-shadow: 0 8px 6px -6px rgb(0 0 0 / 20%);\n }\n#spch.spch.s2tb-h {\n background: rgb(255 255 255 / 0%);\n opacity: 0;\n visibility: hidden;\n }\n\n/* stylelint-disable-next-line keyframes-name-pattern */\n@keyframes fadeIn {\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n/* stylelint-disable-next-line keyframes-name-pattern */\n@keyframes ripple {\n 0% {\n opacity: 1;\n transform: scale(0.7);\n }\n\n 100% {\n opacity: 0;\n transform: scale(1);\n }\n}\n\n/* stylelint-disable-next-line keyframes-name-pattern */\n@keyframes speakingRipple1 {\n 0%,\n 100% {\n background-image: url("https://s.yimg.com/pv/static/img/ripple1-1-202105260611.png");\n }\n\n 25%,\n 75% {\n background-image: url("https://s.yimg.com/pv/static/img/ripple1-2-202105260611.png");\n transform: scale(1.1);\n }\n\n 50% {\n background-image: url("https://s.yimg.com/pv/static/img/ripple1-3-202105260611.png");\n transform: scale(0.9);\n }\n}\n\n/* stylelint-disable-next-line keyframes-name-pattern */\n@keyframes speakingRipple2 {\n 0%,\n 100% {\n background-image: none;\n }\n\n 25%,\n 75% {\n background-image: url("https://s.yimg.com/pv/static/img/ripple2-2-202105260611.png");\n transform: scale(1.1);\n }\n\n 50% {\n background-image: url("https://s.yimg.com/pv/static/img/ripple2-3-202105260611.png");\n transform: scale(0.9);\n }\n}\n\n/* stylelint-disable-next-line keyframes-name-pattern */\n@keyframes speakingRipple3 {\n 0%,\n 25%,\n 75%,\n 100% {\n background-image: none;\n }\n\n 50% {\n background-image: url("https://s.yimg.com/pv/static/img/ripple3-3-202105260611.png");\n transform: scale(0.9);\n }\n}\n',""]),t.Z=o},645:function(e){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=e(t);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,i){"string"==typeof e&&(e=[[null,e,""]]);var o={};if(i)for(var a=0;a0?" ".concat(n.layer):""," {")),i+=n.css,o&&(i+="}"),n.media&&(i+="}"),n.supports&&(i+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(i,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},589:function(e){e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},559:function(e){e.exports=JSON.parse('[{"id":"search.voice.hover_clear_text","description":"","defaultMessage":"Clear"},{"id":"search.voice.hover_search_text","description":"","defaultMessage":"Search the web"},{"id":"search.voice.hover_voice_text","description":"","defaultMessage":"Search by voice"},{"id":"search.voice.permission_text","description":"","defaultMessage":"Allow microphone access to enable voice search"},{"id":"search.voice.permission_title","description":"","defaultMessage":"Waiting for permission"},{"id":"search.voice.recognition_error","description":"","defaultMessage":"Please check your microphone and audio levels."},{"id":"search.voice.recognition_listening","description":"","defaultMessage":"Listening..."},{"id":"search.voice.recognition_nomatch","description":"","defaultMessage":"Didn\'t get that."},{"id":"search.voice.recognition_retry","description":"","defaultMessage":"Try again."},{"id":"search.voice.recognition_start","description":"","defaultMessage":"What would you like to search for?"},{"id":"search.voice.trending_title","description":"","defaultMessage":"Try saying"},{"id":"search.voice.trending_or","description":"","defaultMessage":"or"}]')},336:function(e){e.exports=JSON.parse('["ar-JO","da-DK","de-AT","de-CH","de-DE","el-GR","en-AU","en-CA","en-GB","en-IN","en-MY","en-NZ","en-PH","en-SG","es-AR","es-CL","es-CO","es-ES","es-MX","es-US","fi-FI","fr-CA","fr-CH","fr-FR","id-ID","it-CH","it-IT","ko-KR","nb-NO","nl-NL","pl-PL","pt-BR","ro-RO","ru-RU","sv-SE","th-TH","tr-TR","vi-VN","zh-Hant-HK","zh-Hant-TW"]')}},v={};function y(e){var t=v[e];if(void 0!==t)return t.exports;var n=v[e]={id:e,exports:{}};return f[e](n,n.exports,y),n.exports}y.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return y.d(t,{a:t}),t},y.d=function(e,t){for(var n in t)y.o(t,n)&&!y.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},y.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},y.nc=void 0,e=y(379),t=y.n(e),n=y(795),i=y.n(n),o=y(569),a=y.n(o),r=y(565),s=y.n(r),c=y(216),l=y.n(c),d=y(589),u=y.n(d),p=y(383),(h={}).styleTagTransform=u(),h.setAttributes=s(),h.insert=a().bind(null,"head"),h.domAPI=i(),h.insertStyleElement=l(),t()(p.Z,h),p.Z&&p.Z.locals&&p.Z.locals,m=y(516),function(e,t){var n={uiLang:"en-US",speechLang:"en-US",voiceButton:"#voice-btn",searchBox:{form:"#sf",input:"#yschsp",params:{fr:"",fr2:""}},enable_voice_trending:!1,trending:{market:"en-us"},ui:{speechOverlay:{disableBlur:!1}},browsers:{edge:!1}};function i(o){var a=this;if(a.config=Object.assign(n,o||{}),a.i18n=new i.I18n({lang:a.config.uiLang}),a.renderPermissionGuide(a),a.renderSpeechPanel(a),a.speechResult="",a.noSpeech=!0,a.isRecognitionStart=!1,a.recognition=null,a.voiceButton=t.querySelector(a.config.voiceButton),a.searchBoxForm=t.querySelector(a.config.searchBox.form),a.searchBoxQuery=t.querySelector(a.config.searchBox.input),a.speechPanel=t.querySelector("#spch"),a.speechButtonContainer=t.querySelector("#spchbc"),a.speechButton=t.querySelector("#spchbc-btn"),a.speechText=t.querySelector("#spcht"),a.speechOverlay=t.getElementById("spch-overlay"),a.retryLink=t.querySelector("#spcht-retry"),a.trending=t.getElementById("spch-trending"),a.trendingTerms=t.getElementById("trending-terms"),a.termSpans=t.getElementsByClassName("trending-term"),a.closeButton=t.querySelector("#spchx"),a.startAudio=new Audio("https://s.yimg.com/pv/static/misc/voice-start-202105050733.wav"),a.resultAudio=new Audio("https://s.yimg.com/pv/static/misc/voice-result-202105050733.wav"),a.errorAudio=new Audio("https://s.yimg.com/pv/static/misc/voice-error-202105050733.wav"),a.closeAudio=new Audio("https://s.yimg.com/pv/static/misc/voice-close-202105050733.wav"),a.permissionGuide=t.querySelector("#spchp"),a.permissionGuideClose=t.querySelector("#spchpx"),a.permissionGuideTimer=null,a.onEscKeyDown=function(e){"Escape"===e.code&&(a.recognition.stop(),a.sendBeacon("keybrd","voicesearch_cancel_esc"),a.closePanel(a))},a.isBrowserSupported()){var r=e.SpeechRecognition||e.webkitSpeechRecognition,s=e.SpeechGrammarList||e.webkitSpeechGrammarList;a.recognition=new r;var c=new s;c.addFromString&&c.addFromString("#JSGF V1.0;",1),a.recognition.grammars=c,a.recognition.continuous=!1,a.recognition.lang=a.config.speechLang,a.recognition.interimResults=!1,a.recognition.maxAlternatives=1,a.voiceButton&&(a.voiceButton.onclick=function(){a.recognition.start(),a.permissionGuideTimer&&e.clearTimeout(a.permissionGuideTimer),a.permissionGuideTimer=e.setTimeout((function(){a.isRecognitionStart||a.showPermissionGuide(a)}),300),t.addEventListener("keydown",a.onEscKeyDown),a.sendBeacon("clk","voicesearch")}),a.speechButton&&(a.speechButton.onclick=function(){a.isRecognitionStart?(a.recognition.stop(),a.sendBeacon("clk","voicesearch_panel_mic_close"),a.closePanel(a)):(a.recognition.start(),a.sendBeacon("clk","voicesearch_panel_mic_restart"))}),a.retryLink&&(a.retryLink.onclick=function(){a.isRecognitionStart||(a.recognition.start(),a.sendBeacon("clk","voicesearch_panel_retry"))}),a.speechOverlay&&(a.speechOverlay.onclick=function(){a.recognition.stop(),a.sendBeacon("clk","voicesearch_cancel_outside"),a.closePanel(a)}),a.closeButton&&(a.closeButton.onclick=function(){a.recognition.stop(),a.sendBeacon("clk","voicesearch_cancel"),a.closePanel(a)}),a.permissionGuideClose&&(a.permissionGuideClose.onclick=function(){a.recognition.stop(),a.sendBeacon("clk","voicesearch_permission_close"),a.closeAudio.play(),a.hidePermissionGuide(a)}),a.recognition.onresult=function(t){a.speechResult=t.results[0][0].transcript,a.handlePunctuation(a),a.speechText&&(a.speechText.innerText=a.speechResult),a.searchBoxQuery&&(a.searchBoxQuery.value=a.speechResult),a.resultAudio.play(),e.setTimeout((function(){if(a.speechPanel&&(a.speechPanel.classList.remove("s2tb"),a.speechPanel.classList.add("s2tb-h")),a.hideRetryLink(a),a.searchBoxForm){var e=a.searchBoxForm.querySelector("[name=fr]"),t=a.searchBoxForm.querySelector("[name=fr2]");e&&a.config.searchBox&&a.config.searchBox.params&&a.config.searchBox.params.fr&&(e.value=o.searchBox.params.fr,e.disabled=!1),t&&a.config.searchBox&&a.config.searchBox.params&&a.config.searchBox.params.fr2&&(t.value=o.searchBox.params.fr2,t.disabled=!1),a.searchBoxForm.submit()}}),1e3)},a.recognition.onspeechstart=function(){},a.recognition.onspeechend=function(){a.recognition.stop()},a.recognition.onerror=function(){a.speechText&&(a.speechText.innerText=a.i18n.t("search.voice.recognition_error")),a.hideTrending(a),a.showRetryLink(a),a.errorAudio.play()},a.recognition.onaudiostart=function(){a.speechButtonContainer&&a.speechButtonContainer.classList.add("listening")},a.recognition.onaudioend=function(){a.speechButtonContainer&&a.speechButtonContainer.classList.remove("listening")},a.recognition.onsoundstart=function(){a.hideTrending(a),a.noSpeech=!1,a.speechButtonContainer&&(a.speechButtonContainer.classList.remove("listening"),a.speechButtonContainer.classList.add("speaking"))},a.recognition.onsoundend=function(){a.speechButtonContainer&&a.speechButtonContainer.classList.remove("speaking")},a.recognition.onstart=function(){a.recognitionInit(a),a.startRecognition(a)},a.recognition.onend=function(){a.isRecognitionStart=!1,0==a.noSpeech&&""==a.speechResult&&(a.speechText&&(a.speechText.innerText=a.i18n.t("search.voice.recognition_nomatch")),a.hideTrending(a),a.showRetryLink(a),a.errorAudio.play())},document&&document.dispatchEvent&&document.dispatchEvent(new Event("VOICE_JS_READY"))}}i.I18n=m,i.prototype.renderPermissionGuide=function(e){var t='\n

    \n

    \n

    \n

    \n

    \n

    \n

    \n

    '.concat(e.i18n.t("search.voice.permission_title"),'

    \n

    ').concat(e.i18n.t("search.voice.permission_text"),"

    \n

    \n

    \n

    \n "),n=(new DOMParser).parseFromString(t,"text/html");document.body.appendChild(n.body.children[0])},i.prototype.renderSpeechPanel=function(e){var t='\n

    \n

    \n

    \n

    \n

    \n

    \n \n \n \n \n \n \n

    \n

    \n

    \n \n \n '.concat(e.i18n.t("search.voice.recognition_retry"),'\n

    \n

    \n

    \n

    \n

    \n

    \n ').concat(e.i18n.t("search.voice.trending_title"),'\n \n

    \n

    \n

    \n '),n=(new DOMParser).parseFromString(t,"text/html");e&&e.config&&e.config.ui&&e.config.ui.speechOverlay&&e.config.ui.speechOverlay.disableBlur&&n.body.children[0].classList.add("disable-blur-overlay"),document.body.appendChild(n.body.children[0])},i.prototype.isBrowserSupported=function(){for(var t=!1,n=this,i=Boolean(window.chrome),o=/CriOS/.test(window.navigator.userAgent),a=/Edg\//.test(window.navigator.userAgent),r=/Edge\//.test(window.navigator.userAgent),s=Boolean(window.opr),c=Boolean(window.navigator.brave),l=[{checkEnabled:function(){return!0},checkBrowser:function(){return i&&!o&&!a&&!s&&!c},checkAPI:function(){return e&&("SpeechRecognition"in e||"webkitSpeechRecognition"in e)&&("SpeechGrammarList"in e||"webkitSpeechGrammarList"in e)}},{checkEnabled:function(){return n&&n.config&&n.config.browsers&&n.config.browsers.edge},checkBrowser:function(){return i&&a&&!r},checkAPI:function(){return e&&("SpeechRecognition"in e||"webkitSpeechRecognition"in e)&&("SpeechGrammarList"in e||"webkitSpeechGrammarList"in e)}}],d=0;d0){var t=e.speechResult.charAt(e.speechResult.length-1);"."!==t&&"?"!==t&&"。"!==t&&"?"!==t||(e.speechResult=e.speechResult.slice(0,-1))}},i.prototype.sendBeacon=function(t,n){var i=e.YAHOO.ULT||{},o=e.YAHOO.SB||{};if(i.beacon_click){var a={_S:o.config.i13n.spaceid,_I:o.config.i13n.pvid,actn:t,sec:"search",slk:n};e.YAHOO.ULT.beacon_click(a)}},i.prototype.ajaxReq=function(n,i){var o,a,r=XMLHttpRequest.DONE||4,s=new XMLHttpRequest;if(t.documentMode&&t.documentMode<10)return(new e.XDomainRequest).onload=function(){try{a=JSON.parse(o),i(a)}catch(e){return}},s.open("GET",n),void s.send();s.onreadystatechange=function(){if(s.readyState===r)if(200===s.status){o=s.responseText;try{a=JSON.parse(o),i(a)}catch(e){return}}else i(a)},s.open("GET",n,!0),s.timeout=1e4,s.send()},e.YAHOO||(e.YAHOO={}),e.YAHOO.Util||(e.YAHOO.Util={}),e.YAHOO.Util.VoiceSearch=i}(window,document)}();var jt={containerClass:Ht.tooltip,textClass:Ht.tooltip__text,showClass:Ht["tooltip--show"]},Gt=["zh-hant-tw","zh-hant-hk"];ye("ybar-mod-searchbox",(function(e){var t={ybar:document.getElementById("ybar"),searchInput:document.getElementById("ybar-sbq"),buttonBar:document.querySelector(".".concat(Ht["sa-btn-bar"])),voiceSearchBtn:document.getElementById("ybar-sbq-voice"),searchForm:document.getElementById("ybar-sf"),searchBoxIcon:document.querySelector(".".concat(Ht["searchbox-icon-uh3"])),searchBoxPlaceholder:document.getElementById("ybar-smartphone-searchbox-placeholder"),searchBoxBackButton:document.getElementById("ybar-search-back-btn"),shopsButtonsWrap:document.querySelector(".".concat(Ht["shops-buttons"])),categorySelect:document.getElementById("shops-category-select"),selectedMerchantInput:document.getElementById("selected-merchant-input"),selectedMerchantClearButton:document.querySelector(".".concat(Ht["selected-merchant-clear-button"])),submitSearchBtn:document.getElementById("ybar-search"),clearSearchBtn:document.getElementById("ybar-sbq-x")};!function(e,t){var n,i,o,a=e.getConfig();if(t.ybar&&"desktop"===a.device&&(null===(n=a.bucketConfig)||void 0===n?void 0:n.highlight_searchassist)&&(null===(i=a.bucketConfig)||void 0===i?void 0:i.overlay_class)){t.ybar.setAttribute("data-ovrly-bkt",a.bucketConfig.overlay_class),null===(o=t.searchForm)||void 0===o||o.classList.add(Ht[a.bucketConfig.overlay_class]);var r=document.createElement("div");r.classList.add(Ht.overlay,Ht[a.bucketConfig.overlay_class]),document.body.appendChild(r),e.onDestroy((function(){document.body.removeChild(r)})),e.addElementListener(t.searchForm,"focusout",(function(e){if(t.searchForm&&t.searchInput){var n=e.relatedTarget;n&&!t.searchForm.contains(n)&&window.YAHOO.SA&&window.YAHOO.SA.apps&&window.YAHOO.SA.apps[0]&&window.YAHOO.SA.apps[0].view.shown&&window.YAHOO.SA.apps[0].view.hide()}}))}}(e,t),function(e,t){var n=e.getConfig();"smartphone"===n.device&&("finance"===n.property&&"crunch"===n.ytheme&&e.addElementListener(t.searchInput,"click",(function(){oe("search_input_focus_click"),e.addElementListener(t.searchForm,"click",(function(){if(t.ybar){if(t.ybar.classList.contains("ybar-searchbox-assist-fullscreen"))return;t.ybar.classList.add("ybar-searchbox-assist-fullscreen"),t.ybar.classList.add("ybar-searchbox-assist-fadein")}document.documentElement.classList.contains("ybar-overlay")||(document.documentElement.classList.toggle("ybar-overlay"),document.body.classList.add("ybar-overlay-noscroll"),Q("ybar","websrch","",{elm:"expand",subsec:"searchbox",itc:"1"}))}))})),e.addElementListener(t.searchBoxPlaceholder,"click",(function(){Ft(e,t)})),e.addElementListener(t.searchBoxPlaceholder,"keydown",(function(n){var i=n,o=i.keyCode,a=i.key,r=Dt(65,90),s=y(y([],v(Dt(58,57)),!1),v(Dt(96,105)),!1),c=y(y([],v(r),!1),v(s),!1).includes(o);(32===o||13===o||c)&&(n.preventDefault(),n.stopPropagation(),Ft(e,t,c?a:""))})),t.searchBoxBackButton&&(e.addElementListener(t.searchBoxBackButton,"click",(function(e){e.stopPropagation(),window.YAHOO&&window.YAHOO.SA&&window.YAHOO.SA.apps&&window.YAHOO.SA.apps[0]&&(window.YAHOO.SA.apps[0].view.resetQuery(),window.YAHOO.SA.apps[0].view.hide()),Ut(t),Q("ybar","back-close-srch","",{elm:"btn",subsec:"searchbox",itc:"1"})})),e.addElementListener(t.searchInput,"keyup",(function(e){e.stopPropagation(),27===e.keyCode&&(e.stopPropagation(),Ut(t))}))),e.addEventListener("viewerClosed",(function(){Ut(t)})),e.onDestroy((function(){Ut(t)})))}(e,t),t.voiceSearchBtn&&function(e,t){var n=e.getConfig(),i=n.locale,o=function(){var e,n;(null===(n=null===(e=window.YAHOO)||void 0===e?void 0:e.Util)||void 0===n?void 0:n.VoiceSearch)?new window.YAHOO.Util.VoiceSearch({uiLang:i,speechLang:i,voiceButton:"#ybar-sbq-voice",searchBox:{form:"#ybar-sf",input:"#ybar-sbq",params:{fr:t.voiceSearchBtn.dataset.fr||"yfp-t-voice",fr2:t.voiceSearchBtn.dataset.fr2||"p:fp,m:voice-search"}},ui:{speechOverlay:{disableBlur:Gt.includes(i.toLowerCase())}},browsers:{edge:!0},enable_voice_trending:!0,trending:{market:i}}):console.log("YBAR: VoiceJS lib was not loaded")};e.addElementListener(document,"VOICE_JS_READY",(function(){var i,o;t.voiceSearchBtn.style.visibility="visible",t.voiceSearchBtn.style.display="block",new Yt(e,t.voiceSearchBtn,h(h({},jt),{label:null!==(i=n.i18n.root.SEARCH_TOOLTIP_VOICE)&&void 0!==i?i:"Search with voice",containerClass:"".concat(Ht.tooltip," ").concat(Ht.tooltip__voice),tooltipParentElm:null===(o=t.voiceSearchBtn)||void 0===o?void 0:o.parentElement}))})),e.addElementListener(document,"DOMContentLoaded",(function(){var i,o;new Yt(e,t.submitSearchBtn,h(h({},jt),{label:null!==(i=n.i18n.root.SEARCH_TOOLTIP_WEB)&&void 0!==i?i:"Search the web",containerClass:"".concat(Ht.tooltip," ").concat(Ht.tooltip__web),tooltipParentElm:null===(o=t.voiceSearchBtn)||void 0===o?void 0:o.parentElement}))})),"loading"===document.readyState?e.addElementListener(document,"DOMContentLoaded",o):o(),window.addEventListener("keyup",(function(e){27===e.keyCode&&t.voiceSearchBtn.blur()}))}(e,h(h({},t),{voiceSearchBtn:t.voiceSearchBtn})),t.searchForm&&(e.addElementListener(t.searchBoxIcon,"mouseover",(function(){t.searchForm.classList.add("".concat(Ht["search-input-uh3-hover"]))})),e.addElementListener(t.searchBoxIcon,"mouseout",(function(){t.searchForm.classList.remove("".concat(Ht["search-input-uh3-hover"]))})),e.addElementListener(t.buttonBar,"mouseover",(function(){t.searchForm.classList.add("".concat(Ht["search-input-uh3-hover"]))})),e.addElementListener(t.buttonBar,"mouseout",(function(){t.searchForm.classList.remove("".concat(Ht["search-input-uh3-hover"]))})),e.addElementListener(t.searchInput,"keyup",(function(e){"Tab"===e.key&&t.searchForm.classList.add("".concat(Ht["search-input-uh3-focus-visible"])),t.searchInput.classList.toggle("".concat(Ht.empty),""===t.searchInput.value)})),e.addElementListener(t.searchInput,"keydown",(function(){t.searchForm.classList.remove("".concat(Ht["search-input-uh3-focus-visible"]))})),e.addElementListener(t.searchInput,"focusout",(function(){t.searchForm.classList.remove("".concat(Ht["search-input-uh3-focus-visible"]))})),e.addElementListener(t.submitSearchBtn,"click",(function(e){""===t.searchInput.value.trim()&&e.preventDefault()})),e.addElementListener(t.clearSearchBtn,"click",(function(){t.searchInput.classList.add("".concat(Ht.empty))})))})),function(){var e,t,n,i,o,a,r,s,c,l,d,u,p,h,m=window,f=document,v=(m=(function(e,t){var n,i="load",o=!1,a="Microsoft Internet Explorer"===e.navigator.appName&&(n=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})").exec(e.navigator.userAgent))&&n[1]&&parseFloat(n[1]);function r(e,t){var n=[];return s(t,(function(e,t){n.push(encodeURIComponent(e)+"="+encodeURIComponent(t))})),0\&]/gim,(function(e){return""+e.charCodeAt(0)+";"}))},afterOnload:function(t){if(v())return t();var n=function(t,n){o=!0,h(e,i,n),t()}.bind(e,t,n);p(e,i,n)},getWinLoaded:v,getDOMContentLoaded:function(){return"interactive"===t.readyState||"complete"===t.readyState||"loaded"===t.readyState},ae:p,de:h,ts:function(){return Math.round((new Date).getTime()/1e3)},bold:function(e,t,n,i){if(i=i||{},t.toLowerCase()==n.toLowerCase())return e.replace(/\{s\}/g,t);var o;if(!(n=n.split(/[\s|,]+/).filter((function(e){return""!==e}))).length)return t;i.ignorePunctuation&&(o=/[~`!@#$%^&*()_\-+={[}\]|\\:;"'<,>.?/]/g,n=n.concat(n.filter((function(e){return o.test(e)})).map((function(e){return e.replace(o,"")}))));n="(&[^;\\s]*)?(%needles)".replace("%needles",n.sort((function(e,t){return t.length-e.length})).map((function(e){return e=m(e),i.v2&&/^\d+$/.test(e)?"(^|\\D)("+e+")":e})).join("|"));var a=i.v2?function(t,n,i,o,a,r,s){return n&&!/\s/.test(i)?t:a&&s?o+e.replace(/\{s\}/g,a):e.replace(/\{s\}/g,i)}:function(t,n,i){return n&&!/\s/.test(i)?t:e.replace(/\{s\}/g,i)};return t.replace(new RegExp(n,"gi"),a)},fireEvent:function(n,i,o){var a;"function"==typeof e.CustomEvent?(a=new e.CustomEvent(i,{detail:o}),n.dispatchEvent(a)):"function"==typeof t.createEvent?((a=t.createEvent("CustomEvent")).initCustomEvent(i,!1,!1,o),n.dispatchEvent(a)):"function"==typeof t.attachEvent&&(document.documentElement[i]=o)},getScrollingEle:function(){return document.scrollingElement||document.documentElement},sendViewBeacon:function(t,n){var i;e.YAHOO.SB.config.i13n&&(i=e.YAHOO.SB.config.i13n,n=n?"b":"p",t.s||(t._S?t.s=t._S:i.spaceid&&(t.s=i.spaceid)),delete t._S,!t.mtestid&&i.mtestid&&(t.mtestid=i.mtestid),t.t=t.t||+(new Date).getTime(),(new Image).src=r("https://"+e.YAHOO.SB.config.beacon_host+"/"+n,t))},properties:s,has:c,debug:function(t){this.config.debug&&e.console&&e.console.log&&e.console.log(t)}},e.YAHOO.NBClass=e.YAHOO.SBClass=y,e.YAHOO.NB=e.YAHOO.SB=new y}(m,f),Array.prototype.forEach||(Array.prototype.forEach=function(e,t){var n,i;if(null==this)throw new TypeError(" this is null or not defined");var o,a=Object(this),r=a.length>>>0;if("function"!=typeof e)throw new TypeError(e+" is not a function");for(1>>0;if("function"!=typeof e)throw new TypeError;for(var i,o=[],a=2<=arguments.length?arguments[1]:void 0,r=0;r>>0;if("function"!=typeof e)throw new TypeError(e+" is not a function");for(1this.length)&&-1!==this.indexOf(e,t)}),window),f=document,m.YAHOO),y=v.NB,g={},b="before_get_assist",w="before_display_data",_="before_init_view",E="after_init_view",x="before_parse_data",k="before_update_assist",C="after_update_list",L="after_create_item",S="before_show_sa",A="after_reset_view",T="before_hide_view",I="after_hide_view",N="after_expanded",M="after_init_controller",O="click_assist",B="before_query_assist",R="before_key_submit",q="before_button_submit",P="before_submit_query",H="before_sb_focus",D="after_sb_focus",F="before_sb_blur",U="after_sb_blur",Y="before_beacon",j="after_set_ylc",G="after_reset_controller",z="after_item_highlight",W="after_item_reset_highlight";function V(e,t){var n,i;for(i in t=(e=e||{}).tag||t||"div",n=f.createElement(t),e.css&&(n.className=e.css),e.text&&(n.textContent=e.text),e.attrs)y.set(n,i,e.attrs[i]);for(i in e.style)n.style[i]=e.style[i];return e.wrap?((t=V(e.wrap)).appendChild(n),t):(t=y.cleanHTML(n,!0))?t[0]:null}function K(e){this.config=e||{},this.listeners={},this.cb={}}function Z(){}function J(){}function Q(){}function X(){var e=this.app.view.elems,t=e.sbClear;t&&(0{0}

    '}}function ge(e){var t=this.config,n=0,i=0,o=0,a=e.r;if(0<(e=a.length)){for(var r=e-1;0<=r;r--)75==a[r].m&&a[r].fd?(n=r,i++):76==a[r].m&&o++;e=a.splice(n,i),0

    Latest News & Current Event Updates | Yahoo Malaysia (2024)
    Top Articles
    Latest Posts
    Article information

    Author: Roderick King

    Last Updated:

    Views: 6386

    Rating: 4 / 5 (51 voted)

    Reviews: 82% of readers found this page helpful

    Author information

    Name: Roderick King

    Birthday: 1997-10-09

    Address: 3782 Madge Knoll, East Dudley, MA 63913

    Phone: +2521695290067

    Job: Customer Sales Coordinator

    Hobby: Gunsmithing, Embroidery, Parkour, Kitesurfing, Rock climbing, Sand art, Beekeeping

    Introduction: My name is Roderick King, I am a cute, splendid, excited, perfect, gentle, funny, vivacious person who loves writing and wants to share my knowledge and understanding with you.