Federal Reserve Chairman Jerome Powell's remarks at Jackson Hole

    {promoMarkup}{notifMarkup}

‘,panelEmptyTemplate=’

  • {emptyPanelMsg}

  • ‘,panelErrorTemplate=’

    {errorMsg}

    ‘,panelParentTemplate=”,notifOnboardPromoTemplate=’

  • ‘,EXPANDED_PANEL=”expanded_panel”,ERROR_PANEL=”error_panel”,NotificationView=function(){function e(t,n){classCallCheck(this,e);var i=this;i._config=t,i._panelNode=null,i._store=n}return createClass(e,[{key:”_generatePanelMarkup”,value:function(e,t){var n=this._config,i=void 0,o=void 0;”undefined”!=typeof window&&(i=window.Notification&&”default”===window.Notification.permission,o=n.promos.bypassEligibleClassCheck||hasClass(document.body,n.promos.eligibleBodyClass));var s=n.promos.enableNotifOnboard&&i&&o?notifOnboardPromoTemplate:””;if(s){var r=n.promos.showYahooLogo?””:”yns-no-logo”;s=s.replace(“{notifOnboardBtnLabel}”,n.promos.notifOnboardBtnLabel).replace(“{notifOnboardMsg}”,n.promos.notifOnboardMsg).replace(“{subscriptionTopic}”,n.promos.subscriptionTopic).replace(“{noLogoClass}”,r).replace(“{promoLogo}”,n.promos.promoLogo)}var a=t.newCount>n.panel.maxCount?t.newCount:””,c=n.panel.notificationCenterPath,l=c?””:constants.panelHideElement,u=n.panel.headerMsg?””:” “+constants.panelHideElement,d=c?constants.panelPaddingBtm:””,p=void 0;t.count?p=t.markup:p=panelEmptyTemplate.replace(“{emptyPanelMsg}”,n.panel.emptyPanelMsg);return e=e.replace(“{notifMarkup}”,p).replace(“{promoMarkup}”,s).replace(“{hideClass}”,l).replace(“{notifCenterLink}”,c).replace(“{paddingClass}”,d).replace(“{headerMsg}”,n.panel.headerMsg).replace(“{hideHeaderClass}”,u).replace(/{notificationCenterNavMsg}/g,n.panel.notificationCenterNavMsg).replace(/{newCount}/g,a)}},{key:”render”,value:function(e,t){var n=this;if(n._panelNode){var i=void 0,o=n._panelNode,s=void 0,r=void 0;switch(e){case EXPANDED_PANEL:i=panelTemplate,r=n._store.getNotifications(),s=n._generatePanelMarkup(i,r),o.innerHTML=s;break;case ERROR_PANEL:s=(i=panelErrorTemplate).replace(“{errorMsg}”,n._config.panel.errorMsg),o.innerHTML=s}t&&t()}else t&&t(new Error(“No panel parent”))}},{key:”createPanelParentNode”,value:function(e){e&&(e.innerHTML=panelParentTemplate,this._panelNode=document.getElementById(constants.panelNodeId))}},{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}(),EXPANDED_PANEL$1=”expanded_panel”,ERROR_PANEL$1=”error_panel”,PanelController=function(){function e(t,n,i){classCallCheck(this,e);var o=this;o._store=n,o._view=i,o._config=t;var s=o._config.panel;o._panelParentNode=document.querySelector(s.parentSelector),o._badgeNode=o._config.badge.selector&&document.querySelector(o._config.badge.selector),o._indicatorNode=s.indicatorSelector&&document.querySelector(s.indicatorSelector)}return createClass(e,[{key:”createPanelParentNode”,value:function(){this._view.createPanelParentNode(this._panelParentNode),this._notifPanelNode=document.getElementById(constants.panelNodeId)}},{key:”refreshPanelNode”,value:function(e,t){var n=this;addClass(n._notifPanelNode,constants.panelLoading),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$1),addClass(n._notifPanelNode,constants.panelLoading)):(n._view.render(EXPANDED_PANEL$1),n._view.updateBadgeNode(n._badgeNode),n._showBadge(),n._showIndicator(),n._view.addStyles(i.css)),removeClass(n._notifPanelNode,constants.panelLoading),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),addClass(e._badgeNode,e._config.badge.hideClass)}},{key:”_showIndicator”,value:function(){this._indicatorNode&&(this._store.getNotifications().newCount?addClass(this._indicatorNode,this._config.panel.indicatorClass):removeClass(this._indicatorNode,this._config.panel.indicatorClass))}},{key:”_showBadge”,value:function(){var e=this;e._store.getNotifications().newCount?removeClass(e._badgeNode,e._config.badge.hideClass):addClass(e._badgeNode,e._config.badge.hideClass)}}]),e}(),config={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:40×40|2|80″,indicatorClass:”yns-indicator”,indicatorSelector:null,maxCount:6,notificationCenterNavMsg:”View all {newCount} notifications”,notificationCenterPath:””,notificationTypes:””,parentSelector:null,styleTagId:”notificationStyles”,theme:”default”},service:{attemptCount:2,attemptDelay:1,url:null,resetUrl:null,isRMP:!1,responseType:”json”,timeout:1500}},Main=function(){function e(t){classCallCheck(this,e);var n=this;n.config=n._parseConfig(t),n._validateRequiredConfigs()&&(n._request=new NotificationRequest(n.config),n._store=new NotificationStore(n.config,n._request),n._view=new NotificationView(n.config,n._store),n._panelController=new PanelController(n.config,n._store,n._view),n._panelController.createPanelParentNode(),n._assignHelperMethods())}return createClass(e,[{key:”_parseConfig”,value:function(e){var t={};for(var n in objectAssign(t,config),t)if(t.hasOwnProperty(n)){var i=t[n],o=e[n];”object”===(void 0===i?”undefined”:_typeof(i))?objectAssign(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(){removeClass(e._panelController._indicatorNode,e.config.panel.indicatorClass)}}}}]),e}(),notificationClient_module_min=Main,notificationClient={NotificationClient:notificationClient_module_min},CONSUMPTION_STORAGE_KEY=”lnct”,NotifClient=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 notificationClient.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},s=(null===(e=window.YAHOO)||void 0===e?void 0:e.context)||(null===(t=window.Af)||void 0===t?void 0:t.context)||{};return s.region&&s.lang&&(o.lang=s.lang,o.region=s.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&&(logError(“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={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}},i=document.getElementById(“notification-container”),o=null===(e=null==i?void 0:i.dataset)||void 0===e?void 0:e.config,s={};if(o){“att”===(null===(t=this.partnerClasses)||void 0===t?void 0:t[1])&&(n.promos.showYahooLogo=!1);try{var r=JSON.parse(o);s=__assign({},r),this.personalized=1===r.personalize}catch(e){logError(“Notifications config parsing error”,e)}i&&delete i.dataset.config}return this.mergeConfigs(n,s)},e.prototype.mergeConfigs=function(e,t){var n=__assign({},e);for(var i in e)n[i]=__assign(__assign({},e[i]),t[i]);return n},e.prototype.getTimeStamp=function(){var e;return null===(e=window.localStorage)||void 0===e?void 0:e.getItem(CONSUMPTION_STORAGE_KEY)},e.prototype.setTimeStamp=function(){var e,t=””+Math.floor((new Date).getTime()/1e3);return null===(e=window.localStorage)||void 0===e||e.setItem(CONSUMPTION_STORAGE_KEY,t),t},e}(),notifClient=new NotifClient,getNotifClient=function(){return notifClient},reInit=function(){notifClient=new NotifClient},ybarRapid,ybarRapidInterval,ybarRapidErrMsg=””,beaconQueue=[],noop=function(){},logRapidError=function(){window.removeEventListener(“beforeunload”,logRapidError),””!==ybarRapidErrMsg&&logError(“Rapid not found on page”,new Error(ybarRapidErrMsg))},findRapidWithSpaceid=function(e){var t=void 0;if(e&&e.length>0)for(var n=0;n0){if(ybarRapid.addModules(o,!1,i),beaconQueue.length>0)for(e=0;e90&&fireImageBeacon(“performance”,e)}catch(e){}}),1e3)}))},measureInit=measure(“ybar-init”);initYbar(),measureInit.stop(),initPerformanceMetricsBeaconListener(),initRapid(),initErrorBeaconListener();var selected=”_yb_1xz0y”,Css$9={“right-item”:”_yb_1n655″,selected:selected,”ybar-mod-topnavigation”:”_yb_yibs7″,”ybar-mod-topnavigation-teaser-imp”:”_yb_1zo86″},DOCUMENT_NODE_TYPE=9;if(“undefined”!=typeof Element&&!Element.prototype.matches){var proto=Element.prototype;proto.matches=proto.matchesSelector||proto.mozMatchesSelector||proto.msMatchesSelector||proto.oMatchesSelector||proto.webkitMatchesSelector}function closest(e,t){for(;e&&e.nodeType!==DOCUMENT_NODE_TYPE;){if(“function”==typeof e.matches&&e.matches(t))return e;e=e.parentNode}}var closest_1=closest;function _delegate(e,t,n,i,o){var s=listener.apply(this,arguments);return e.addEventListener(n,s,o),{destroy:function(){e.removeEventListener(n,s,o)}}}function delegate(e,t,n,i,o){return”function”==typeof e.addEventListener?_delegate.apply(null,arguments):”function”==typeof n?_delegate.bind(null,document).apply(null,arguments):(“string”==typeof e&&(e=document.querySelectorAll(e)),Array.prototype.map.call(e,(function(e){return _delegate(e,t,n,i,o)})))}function listener(e,t,n,i){return function(n){n.delegateTarget=closest_1(n.target,t),n.delegateTarget&&i.call(e,n)}}var delegate_1=delegate,ListNode=function(e){this.data=e,this.next=null,this.prev=null},LinkedList=function(){function e(){this.head=null,this.tail=null}return e.prototype.push=function(e){var t=new ListNode(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)&&t0&&Array.prototype.forEach.call(e,(function(e){e.onerror=function(){e.onerror=null,e.style.display=”none”}}))},fixLogoOutline=function(e,t){e&&(hideOutlineOnMouseDown(“#ybar-logo”,”#ybar-logo”,t),t.onDestroy((function(){e.classList.remove(“ybar-show-outline”),e.classList.remove(“ybar-hide-outline”)})))},logoClick=function(e,t){t&&e.addElementListener(t,”click”,(function(){e.triggerEvent(“logo-click”)}))},init$4=function(e,t){t.logoImages&&hideLogosOnError(t.logoImages),t.wrapper&&(fixLogoOutline(t.wrapper,e),logoClick(e,t.wrapper))};initModule(“ybar-mod-logo”,(function(e){var t={wrapper:document.getElementById(“ybar-logo”),logoImages:document.querySelectorAll(“.”.concat(Css$8[“logo-image”]))};init$4(e,t)}));var overlay$1=”_yb_1p3uh”,tooltip=”_yb_wqrsm”,tooltip__text=”_yb_1xyyv”,tooltip__voice=”_yb_vfxhq”,tooltip__web=”_yb_1st4f”,dark=”_yb_oqo9a”,darker=”_yb_cr95c”,light=”_yb_ys6do”,midnight60=”_yb_xev53″,Css$7={“dropdown-open”:”_yb_r5u5e”,”merchant-is-selected”:”_yb_3oj4o”,overlay:overlay$1,”selected-merchant-clear-button”:”_yb_itf5f”,”shops-buttons”:”_yb_5wrjc”,”styled-select”:”_yb_q2p62″,tooltip:tooltip,”tooltip–show”:”_yb_1fb6p”,tooltip__text:tooltip__text,tooltip__voice:tooltip__voice,tooltip__web:tooltip__web,dark:dark,darker:darker,light:light,midnight60:midnight60},range=function(e,t){var n=Math.max(e,t),i=Math.min(e,t),o=Math.abs(n-i);return __spreadArray([],new Array(o+1),!0).map((function(e,t){return i+t}))},openSearchOverlay=function(e,t,n){var i=e.getConfig().bucketConfig,o=(void 0===i?{}:i).enable_search_ui,s=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”);beaconClick(“ybar”,”websrch”,””,{elm:”expand”,subsec:”searchbox”,itc:”1″}),setTimeout((function(){t.searchInput instanceof HTMLInputElement&&(n&&(t.searchInput.value=n),t.searchInput.focus(),s&&t.searchInput.click())}))}},closeSearchOverlay=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())},initMweb=function(e,t){“smartphone”===e.getConfig().device&&(e.addElementListener(t.searchBoxPlaceholder,”click”,(function(){openSearchOverlay(e,t)})),e.addElementListener(t.searchBoxPlaceholder,”keydown”,(function(n){var i=n,o=i.keyCode,s=i.key,r=range(65,90),a=__spreadArray(__spreadArray([],range(58,57),!0),range(96,105),!0),c=__spreadArray(__spreadArray([],r,!0),a,!0).includes(o);(32===o||13===o||c)&&(n.preventDefault(),n.stopPropagation(),openSearchOverlay(e,t,c?s:””))})),t.searchBoxBackButton&&(e.addElementListener(t.searchBoxBackButton,”click”,(function(e){e.stopPropagation(),closeSearchOverlay(t);beaconClick(“ybar”,”back-close-srch”,””,{elm:”btn”,subsec:”searchbox”,itc:”1″})})),e.addElementListener(t.searchInput,”keyup”,(function(e){e.stopPropagation();27===e.keyCode&&(e.stopPropagation(),closeSearchOverlay(t))}))),e.onDestroy((function(){closeSearchOverlay(t)})))},Tooltip=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}();createCommonjsModule((function(module){(function(){var __webpack_modules__={“./src/index.js”:
    /*!**********************!*
    !*** ./src/index.js ***!
    **********************/function(__unused_webpack_module,__unused_webpack_exports,__webpack_require__){eval(“var I18n = __webpack_require__(/*! ./lib/I18n */ “./src/lib/I18n.js”);nn(function (win, doc) {n “use strict”;nn var defaultConfig = {n uiLang: ‘en-US’,n speechLang: ‘en-US’,n voiceButton: ‘#voice-btn’,n searchBox: {n form: ‘#sf’,n input: ‘#yschsp’,n params: {n fr: ”,n fr2: ”n }n },n enable_voice_trending: false,n trending: {n market: “en-us”n },n ui: {n speechOverlay: {n disableBlur: falsen }n },n browsers: {n edge: falsen }n };nn function VoiceSearch(config) {n var self = this;n self.config = Object.assign(defaultConfig, config || {});n self.i18n = new VoiceSearch.I18n({n lang: self.config.uiLangn });n self.renderPermissionGuide(self);n self.renderSpeechPanel(self);n self.speechResult = ”;n self.noSpeech = true;n self.isRecognitionStart = false;n self.recognition = null;n self.voiceButton = doc.querySelector(self.config.voiceButton);n self.searchBoxForm = doc.querySelector(self.config.searchBox.form);n self.searchBoxQuery = doc.querySelector(self.config.searchBox.input);n self.speechPanel = doc.querySelector(‘#spch’);n self.speechButtonContainer = doc.querySelector(‘#spchbc’);n self.speechButton = doc.querySelector(‘#spchbc-btn’);n self.speechText = doc.querySelector(‘#spcht’);n self.speechOverlay = doc.getElementById(‘spch-overlay’);n self.retryLink = doc.querySelector(‘#spcht-retry’);n self.trending = doc.getElementById(‘spch-trending’);n self.trendingTerms = doc.getElementById(‘trending-terms’);n self.termSpans = doc.getElementsByClassName(“trending-term”);n self.closeButton = doc.querySelector(‘#spchx’);n self.startAudio = new Audio(‘https://s.yimg.com/pv/static/misc/voice-start-202105050733.wav’);n self.resultAudio = new Audio(‘https://s.yimg.com/pv/static/misc/voice-result-202105050733.wav’);n self.errorAudio = new Audio(‘https://s.yimg.com/pv/static/misc/voice-error-202105050733.wav’);n self.closeAudio = new Audio(‘https://s.yimg.com/pv/static/misc/voice-close-202105050733.wav’);n self.permissionGuide = doc.querySelector(‘#spchp’);n self.permissionGuideClose = doc.querySelector(‘#spchpx’);n self.permissionGuideTimer = null;nn self.onEscKeyDown = function (e) {n if (e.code !== ‘Escape’) {n return;n }nn self.recognition.stop();n self.sendBeacon(‘keybrd’, ‘voicesearch_cancel_esc’); // The clean up should put inside closePanel() instead of here,n // or func won’t be cleaned up if user close panel with btn or overlaynn self.closePanel(self);n };nn if (self.isBrowserSupported()) {n var SpeechRecognition = win.SpeechRecognition || win.webkitSpeechRecognition;n var SpeechGrammarList = win.SpeechGrammarList || win.webkitSpeechGrammarList;n var speechGrammar = ‘#JSGF V1.0;’;n self.recognition = new SpeechRecognition();n var speechRecognitionList = new SpeechGrammarList();nn if (speechRecognitionList.addFromString) {n speechRecognitionList.addFromString(speechGrammar, 1);n }nn self.recognition.grammars = speechRecognitionList;n self.recognition.continuous = false;n self.recognition.lang = self.config.speechLang;n self.recognition.interimResults = false;n self.recognition.maxAlternatives = 1;n /* Listeners */nn if (self.voiceButton) {n self.voiceButton.onclick = function () {n self.recognition.start();nn if (self.permissionGuideTimer) {n win.clearTimeout(self.permissionGuideTimer);n }nn self.permissionGuideTimer = win.setTimeout(function () {n if (!self.isRecognitionStart) {n self.showPermissionGuide(self);n }n }, 300); // Also close when pressing escnn doc.addEventListener(‘keydown’, self.onEscKeyDown);n self.sendBeacon(‘clk’, ‘voicesearch’);n };n }nn if (self.speechButton) {n self.speechButton.onclick = function () {n if (!self.isRecognitionStart) {n self.recognition.start();n self.sendBeacon(‘clk’, ‘voicesearch_panel_mic_restart’);n } else {n self.recognition.stop();n self.sendBeacon(‘clk’, ‘voicesearch_panel_mic_close’);n self.closePanel(self);n }n };n }nn if (self.retryLink) {n self.retryLink.onclick = function () {n if (!self.isRecognitionStart) {n self.recognition.start();n self.sendBeacon(‘clk’, ‘voicesearch_panel_retry’);n }n };n }nn if (self.speechOverlay) {n self.speechOverlay.onclick = function () {n self.recognition.stop();n self.sendBeacon(‘clk’, ‘voicesearch_cancel_outside’);n self.closePanel(self);n };n }nn if (self.closeButton) {n self.closeButton.onclick = functionn /*event*/n () {n self.recognition.stop();n self.sendBeacon(‘clk’, ‘voicesearch_cancel’);n self.closePanel(self);n };n }nn if (self.permissionGuideClose) {n self.permissionGuideClose.onclick = functionn /*event*/n () {n self.recognition.stop();n self.sendBeacon(‘clk’, ‘voicesearch_permission_close’);n self.closeAudio.play();n self.hidePermissionGuide(self);n };n }n /* Recognition Events */nnn self.recognition.onresult = function (event) {n // The SpeechRecognitionEvent results property returns a SpeechRecognitionResultList objectn // The SpeechRecognitionResultList object contains SpeechRecognitionResult objects.n // It has a getter so it can be accessed like an arrayn // The first [0] returns the SpeechRecognitionResult at the last position.n // Each SpeechRecognitionResult object contains SpeechRecognitionAlternative objects that contain individual results.n // These also have getters so they can be accessed like arrays.n // The second [0] returns the SpeechRecognitionAlternative at position 0.n // We then return the transcript property of the SpeechRecognitionAlternative objectn // console.log(‘Confidence: ‘ + event.results[0][0].confidence);n self.speechResult = event.results[0][0].transcript;n /* Punctuation Handling: Check last character and strip it if necessary */nn self.handlePunctuation(self);nn if (self.speechText) {n self.speechText.innerText = self.speechResult;n }nn if (self.searchBoxQuery) {n self.searchBoxQuery.value = self.speechResult;n }nn self.resultAudio.play();n win.setTimeout(function () {n if (self.speechPanel) {n self.speechPanel.classList.remove(“s2tb”);n self.speechPanel.classList.add(“s2tb-h”);n }nn self.hideRetryLink(self);nn if (self.searchBoxForm) {n var inputFr = self.searchBoxForm.querySelector(‘[name=fr]’);n var inputFr2 = self.searchBoxForm.querySelector(‘[name=fr2]’);nn if (inputFr && self.config.searchBox && self.config.searchBox.params && self.config.searchBox.params.fr) {n inputFr.value = config.searchBox.params.fr;n inputFr.disabled = false; // for homepage casen }nn if (inputFr2 && self.config.searchBox && self.config.searchBox.params && self.config.searchBox.params.fr2) {n inputFr2.value = config.searchBox.params.fr2;n inputFr2.disabled = false; // for homepage casen }nn self.searchBoxForm.submit();n }n }, 1000);n };nn self.recognition.onspeechstart = functionn /*event*/n () {// Fired when speech startsn };nn self.recognition.onspeechend = function () {n // Fired when speech endsn self.recognition.stop();n };nn self.recognition.onerror = functionn /*event*/n () {n // console.log(‘Error occurred in recognition: ‘ + event.error);n if (self.speechText) {n self.speechText.innerText = self.i18n.t(‘search.voice.recognition_error’);n }nn self.hideTrending(self);n self.showRetryLink(self);n self.errorAudio.play();n };nn self.recognition.onaudiostart = functionn /*event*/n () {n // Fired when the user agent has started to capture audio.n if (self.speechButtonContainer) {n self.speechButtonContainer.classList.add(“listening”);n }n };nn self.recognition.onaudioend = functionn /*event*/n () {n // Fired when the user agent has finished capturing audio.n if (self.speechButtonContainer) {n self.speechButtonContainer.classList.remove(“listening”);n }n };nn self.recognition.onsoundstart = functionn /*event*/n () {n // Fired when any sound — recognisable speech or not — has been detected.n self.hideTrending(self);n self.noSpeech = false;nn if (self.speechButtonContainer) {n self.speechButtonContainer.classList.remove(“listening”);n self.speechButtonContainer.classList.add(“speaking”);n }n };nn self.recognition.onsoundend = functionn /*event*/n () {n // Fired when no sound presentn if (self.speechButtonContainer) {n self.speechButtonContainer.classList.remove(“speaking”);n }n };nn self.recognition.onstart = functionn /*event*/n () {n // Fired when the speech recognition service has begun listeningn self.recognitionInit(self);n self.startRecognition(self);n };nn self.recognition.onend = functionn /*event*/n () {n // Fired when the speech recognition service has disconnected.n self.isRecognitionStart = false;nn if (self.noSpeech == false && self.speechResult == ”) {n // No match: Fired when the speech recognition can’t recognise speechn if (self.speechText) {n self.speechText.innerText = self.i18n.t(‘search.voice.recognition_nomatch’);n }nn self.hideTrending(self);n self.showRetryLink(self);n self.errorAudio.play();n }n }; // trigger onReady event when initializednnn if (document && document.dispatchEvent) {n document.dispatchEvent(new Event(‘VOICE_JS_READY’));n }n }n } // static membersnnn VoiceSearch.I18n = I18n; // instance membersnn VoiceSearch.prototype.renderPermissionGuide = function (self) {n var tmpl = “\n

    \n \n

    \n \n

    \n

    “.concat(self.i18n.t(‘search.voice.permission_title’), “

    \n

    “).concat(self.i18n.t(‘search.voice.permission_text’), “

    \n

    \n

    \n

    \n “);n var dom = new DOMParser().parseFromString(tmpl, ‘text/html’);n document.body.appendChild(dom.body.children[0]);n };nn VoiceSearch.prototype.renderSpeechPanel = function (self) {n var tmpl = “\n

    \n \n \n

    \n

    \n

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

    \n

    \n

    \n \n \n “.concat(self.i18n.t(‘search.voice.recognition_retry’), “\n

    \n

    \n

    \n

    \n

    \n

    \n “).concat(self.i18n.t(‘search.voice.trending_title’), “\n \n

    \n

    \n

    \n “);n var dom = new DOMParser().parseFromString(tmpl, ‘text/html’);nn if (self && self.config && self.config.ui && self.config.ui.speechOverlay && self.config.ui.speechOverlay.disableBlur) {n dom.body.children[0].classList.add(‘disable-blur-overlay’);n }nn document.body.appendChild(dom.body.children[0]);n };nn VoiceSearch.prototype.isBrowserSupported = function () {n var isSupported = false;n var self = this;n var isChromium = Boolean(window.chrome);n var isIOSChrome = /CriOS/.test(window.navigator.userAgent);n var isEdge = /Edg\//.test(window.navigator.userAgent);n var isLegacyEdge = /Edge\//.test(window.navigator.userAgent);n var isOpera = Boolean(window.opr);n var isBrave = Boolean(window.navigator.brave);n var browsers = [// chromen {n checkEnabled: function checkEnabled() {n return true;n },n checkBrowser: function checkBrowser() {n return isChromium && !isIOSChrome && !isEdge && !isOpera && !isBrave;n },n checkAPI: function checkAPI() {n return win && (‘SpeechRecognition’ in win || ‘webkitSpeechRecognition’ in win) && (‘SpeechGrammarList’ in win || ‘webkitSpeechGrammarList’ in win);n }n }, // edgen {n checkEnabled: function checkEnabled() {n return self && self.config && self.config.browsers && self.config.browsers.edge;n },n checkBrowser: function checkBrowser() {n return isChromium && isEdge && !isLegacyEdge;n },n checkAPI: function checkAPI() {n return win && (‘SpeechRecognition’ in win || ‘webkitSpeechRecognition’ in win) && (‘SpeechGrammarList’ in win || ‘webkitSpeechGrammarList’ in win);n }n }];nn for (var b = 0; b 0) {n var lastChar = self.speechResult.charAt(self.speechResult.length – 1);nn if (lastChar === ‘.’ || lastChar === ‘?’ || lastChar === ‘。’ || lastChar === ‘?’) {n self.speechResult = self.speechResult.slice(0, -1);n }n }n };nn VoiceSearch.prototype.sendBeacon = function (actn, slk) {n var ULT = win.YAHOO.ULT || {},n SB = win.YAHOO.SB || {};nn if (ULT.beacon_click) {n var trackParams = {n _S: SB.config.i13n.spaceid,n _I: SB.config.i13n.pvid,n actn: actn,n sec: ‘search’,n slk: slkn };n win.YAHOO.ULT.beacon_click(trackParams);n }n };nn VoiceSearch.prototype.ajaxReq = function (url, callback) {n var DONE_STATE = XMLHttpRequest.DONE || 4; // for IE-compatibilitynn var xhr = new XMLHttpRequest();n var responseRaw;n var response; // CORS request only for IE8/IE9nn if (doc.documentMode && doc.documentMode n // tags it will allow on a pagenn if (!options.singleton && typeof options.singleton !== ‘boolean’) {n options.singleton = isOldIE();n }nn list = list || [];n var lastIdentifiers = modulesToDom(list, options);n return function update(newList) {n newList = newList || [];nn if (Object.prototype.toString.call(newList) !== ‘[object Array]’) {n return;n }nn for (var i = 0; i >>0;if(“function”!=typeof e)throw new TypeError(e+” is not a function”);for(arguments.length>1&&(n=t),i=0;i>>0;if(“function”!=typeof e)throw new TypeError;for(var i=[],o=arguments.length>=2?arguments[1]:void 0,s=0;s>>0;if(“function”!=typeof e)throw new TypeError(e+” is not a function”);for(arguments.length>1&&(n=t),i=new Array(r),o=0;othis.length)&&-1!==this.indexOf(e,t)}),function(){function e(e){return”function”==typeof e.trim?e.trim():e.replace(/^s+|s+$/gm,””)}function t(e){var t;c&&c&]/gim,(function(e){return””+e.charCodeAt(0)+”;”}))},ae:function(e,t,n,i){if(i=i||!1,e.addEventListener)e.addEventListener(t,n,i);else{if(!e.attachEvent)return!1;e.attachEvent(“on”+t,n)}},de:function(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n);else{if(!e.detachEvent)return!1;e.detachEvent(“on”+t,n)}},ts:function(){return Math.round((new Date).getTime()/1e3)},bold:function(e,t,n,o){var s,r=(o.pattern||””)+”(&[^;\s]*)?(%needles)”;return(o=o.exact?[i(n)]:n.split(/[s|,]+/).filter((function(e){return””!==e})).sort((function(e,t){return t.length-e.length})).map(i)).length?(r=r.replace(“%needles”,o.join(“|”)),t.replace(new RegExp(r,”gi”),(s=e,function(e,t,n){return t&&!/s/.test(n)?e:s.replace(/{s}/g,n)}))):t},fireEvent:function(e,t,n){var i;”function”==typeof s.CustomEvent?(i=new s.CustomEvent(t,{detail:n}),e.dispatchEvent(i)):”function”==typeof r.createEvent?((i=r.createEvent(“CustomEvent”)).initCustomEvent(t,!1,!1,n),e.dispatchEvent(i)):(r.attachEvent,document.documentElement[t]=n)}},s.YAHOO=s.YAHOO||{},s.YAHOO.NBClass=o,s.YAHOO.NB=new o,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,s=Object(this),r=s.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=[],s=2>>0;if(“function”!=typeof e)throw new TypeError(e+” is not a function”);for(1this.length)&&-1!==this.indexOf(e,t)});var s,r,a,c,l,u,d,p,f,h,m=window,g=document,y=m.YAHOO,v=y.NB,b={},_=”before_get_assist”,w=”before_display_data”,C=”before_init_view”,E=”after_init_view”,S=”before_parse_data”,x=”before_update_assist”,T=”after_update_list”,k=”after_create_item”,L=”before_show_sa”,I=”after_reset_view”,A=”after_hide_view”,M=”after_init_controller”,N=”click_assist”,R=”before_query_assist”,O=”before_key_submit”,B=”before_button_submit”,P=”before_submit_query”,D=”after_item_highlight”,q=”after_item_reset_highlight”,j=”before_sb_focus”,V=”after_sb_focus”,$=”before_sb_blur”,F=”after_sb_blur”,U=”before_beacon”,H=”after_set_ylc”,Y=”after_reset_controller”;function G(e,t){t=(e=e||{}).tag||t||”div”;var n,i=g.createElement(t);for(n in e.css&&(i.className=e.css),e.text&&(i.textContent=e.text),e.attrs)v.set(i,n,e.attrs[n]);for(n in e.style)i.style[n]=e.style[n];return e.wrap?((t=G(e.wrap)).appendChild(i),t):i}function z(e){this.config=e||{},this.listeners={},this.cb={}}function W(){}function J(){}function Q(){}function K(){var e=this.app.view.elems,t=e.sbClear;t&&(0Manage history’},log:{sec:”search”,slk:”clear history”,rspns:”upd”,t2:”search”,t4:”clear history”}}}function Te(){function e(e){e.keyCode&&27!==e.keyCode&&13!=e.keyCode||(v.stopPropagation(e),s.value=””,v.setFocus(s),i.show(),n.control.beacon(“tapClr”,r,t.config.log))}var t=this,n=t.app,i=n.view,o=i.elems,s=o.sbInput,r=o.sbClear;r&&(v.ae(r,”click”,e),v.ae(r,”keydown”,e))}function ke(){this.config={log:{_r:2,actn:”clk”,pos:1,sec:”search”,slk:”clearsearch”,rspns:”upd”,t1:”hdr”,t2:”search”,t3:”clear”,t4:”clearsearch”}}}y.SA=(u=[],z.prototype={jsonp:function(e){var t=g.getElementsByTagName(“head”)[0],n=g.createElement(“script”);v.set(n,”type”,”text/javascript”),v.set(n,”src”,e),t.appendChild(n),v.ae(n,”load”,(function(){t.removeChild(n)}))},createElem:G,getElemStyleValue:function(e,t){return m.getComputedStyle?m.getComputedStyle(e).getPropertyValue(t):e.currentStyle?(t=t.replace(/-([a-z]){1}/g,(function(e,t){return t.toUpperCase()})),e.currentStyle[t]):””},format:function(e,t){if(e)return e.replace(/{(d+)}/g,(function(e,n){return t&&void 0!==t[n]?t[n]:””})).trim()},on:function(e,t,n){var i;e&&t&&((i=this.listeners)[e]||(i[e]=[]),i[e].push({thisArg:n||this,fn:t}))},notify:function(e,t){var n=this.listeners;if(!n[e])return!1;n[e].forEach((function(e){var n=e.thisArg;(e=e.fn)&&e.apply&&1!=n.config.disable&&e.apply(n,t||[])}))},init:function(e){var t,n,i,o,s=this,r=s.config,a=r.plugins={};for(o in s.view=t=new l.viewClass,s.model=n=new l.modelClass,s.control=i=new l.controlClass,b){var c=new b[o];a[o]=c.config=c.config||{},c.createElem=G,c.init(s)}”object”==typeof e&&v.merge(r,e),s.ready=t.init(s)&&n.init(s)&&i.init(s)}},d=z,l={ver:”assistjs-v1.0.155-ybar”,apps:u,plugs:b,add:function(e,t){b[e]=t},msg:{BEFORE_GET_ASSIST:_,BEFORE_DISPLAY_DATA:w,BEFORE_INIT_VIEW:C,AFTER_INIT_VIEW:E,BEFORE_PARSE_DATA:S,BEFORE_UPDATE_ASSIST:x,AFTER_UPDATE_LIST:T,AFTER_CREATE_ITEM:k,BEFORE_SHOW_SA:L,AFTER_RESET_VIEW:I,AFTER_HIDE_VIEW:A,AFTER_INIT_CONTROLLER:M,CLICK_ASSIST:N,BEFORE_QUERY_ASSIST:R,BEFORE_KEY_SUBMIT:O,BEFORE_BUTTON_SUBMIT:B,BEFORE_SUBMIT_QUERY:P,BEFORE_SB_FOCUS:j,AFTER_SB_FOCUS:V,BEFORE_SB_BLUR:$,AFTER_SB_BLUR:F,BEFORE_BEACON:U,AFTER_SET_YLC:H,AFTER_RESET_CONTROLLER:Y,AFTER_ITEM_HIGHLIGHT:D,AFTER_ITEM_RESET_HIGHLIGHT:q},markers:{GOSSIP_MARKER_SEARCH_HISTORY:13,GOSSIP_MARKER_TRENDING:9,GOSSIP_MARKER_PEOPLE_ALSO_SEARCH_FOR:42},init:function(e){var t,n=v.ieVer;return!(n&&n”+s+” “+n.config.saAria.shownText+””)},show:function(){var e=this,t=e.config,n=e.elems.sbInput.value,i=n.length;e.app.notify(L),e.shown&&e.sameQuery()||(e.lastInput=n,it.maxInput?e.hide():(e.model.fetch(),e.triggered=!0))},hide:function(){var e=this,t=(n=e.elems).saAria,n=n.sbForm,i=e.config;v.removeClass(g.body,i.typingClass),n&&n.parentElement&&v.removeClass(n.parentElement,i.typingClass),v.removeClass(n,i.noResultClass),e.clearAssist(),e.shown=!1,e.triggered=!1,t&&(v.set(t,”aria-expanded”,”false”),t.innerHTML=”

    “+e.config.saAria.closedText+”

    “),e.app.notify(A)},clearAssist:function(){this.elems.saTray.innerHTML=””,this.items.splice(0,this.items.length),this.assistItem=null},createItem:function(e){var t,n={idx:e.idx,data:e.origData},i=v.htmlEncode,o=this.config,s=(t=this.app.createElem)(o.saItem,”li”);return(t=(v.set(s,”pos”,e.idx),t(o.saTitle,”span”))).innerHTML=e.t||(o.boldTag&&e.k&&e.q?v.bold(o.boldTag,i(e.k),i(e.q),o.highlight||{}):i(e.k)),s.appendChild(t),n.li=s,n.title=t,this.app.notify(k,[n,e]),n},resetQuery:function(){this.elems.sbInput.value=this.origQuery},reset:function(){var e=this,t=e.config,n=e.elems.sbForm;t.resetQuery&&e.resetQuery(),e.hide(),n.action=e.origAction,e.app.notify(I)},sameQuery:function(){return this.elems.sbInput.value==this.lastInput}},Q),l.initConfig=function(){return{elems:{sbForm:”sb-form”,sbInput:”sb-input”,sbSubmit:”sb-search”,sbClear:”sb-clr”,sbCancel:”sb-cancel”,saTray:”sa-tray”},customEvent:{},sa:{css:”sa”,attrs:{type:”normal”}},saList:{css:”sa-list”,attrs:{role:”listbox”},style:{cursor:”pointer”}},saItem:{css:”sa-item”,attrs:{role:”option”}},saTitle:{css:”sa-item-title”},saAria:{shownText:”new suggestions shown”,closedText:”Suggestion box closed”,css:”sa-aria-live-region”,attrs:{“aria-live”:”polite”},style:{position:”absolute”,left:”-9999px”}},saBE:{host:””,base:”/sugg/gossip/gossip-us-ura/”,params:{l:1,bm:3,output:”sd1″,nresults:10}},shBE:{host:””,base:”/history”},minInput:0,maxInput:255,boldTag:”{s}“,ylc:{_r:2},ylcAssist:{use_case:””},hideOnOutsideClick:!0,noQueryClass:”sa-noQuery”,typingClass:”typing”,noResultClass:”sf-noResult”}},b.hideSbClr=(X.prototype={init:function(e){(this.app=e).on(L,K,this)}},X),b.saFr=(ne.prototype={init:function(e){(this.app=e).on(E,Z,this),e.on(R,ee,this),e.on(I,te,this)}},ne),b.ipos=(se.prototype={init:function(e){(this.app=e).on(L,ie,this),e.on(_,oe,this)}},se),b.saTray=(ae.prototype={init:function(e){(this.app=e).on(C,re,this)}},ae),b.saFlvr=(le.prototype={init:function(e){e.on(k,ce,this)}},le),b.saEdit=(de.prototype={init:function(e){e.on(k,ue,this)}},de),b.saAnnot=(fe.prototype={init:function(e){e.on(k,pe,this)}},fe),b.saImg=(me.prototype={init:function(e){e.on(k,he,this)}},me),b.saGroup=(ve.prototype={init:function(e){this.app=e,this.idxs={},e.on(k,ge,this),e.on(T,ye,this)}},ve),b.saPCActn=(Ee.prototype={init:function(e){var t=this;t.app=e,t.selectedIndex=-1,e.on(w,be,t),e.on(M,_e,t),e.on(V,we,t),e.on(F,Ce,t)}},Ee),b.tapRmv=(xe.prototype={init:function(e){(this.app=e).on(N,Se,this)}},xe),b.tapClr=(ke.prototype={init:function(e){(this.app=e).on(M,Te,this)}},ke)}();var history=”_yb_eu8dn”,lowlight=”_yb_44yin”,sa=”_yb_zvqr9″,trending=”_yb_y56s6″,Css$6={“bot-search-icon”:”_yb_8f0qa”,”bot-search-icon-container”:”_yb_1ktad”,”bot-search-item”:”_yb_19mp9″,”bot-search-item-col”:”_yb_t69yj”,”bot-search-span”:”_yb_197m5″,history:history,”list-item-hover”:”_yb_1ovt3″,lowlight:lowlight,”no-wrap”:”_yb_1bj60″,”related-title”:”_yb_1yzng”,sa:sa,”sa-annot-rich”:”_yb_l5oyd”,”sa-annot-subtitle”:”_yb_13911″,”sa-annot-title”:”_yb_1c22h”,”sa-edit”:”_yb_1urny”,”sa-edit-icon”:”_yb_18crq”,”sa-edit-text”:”_yb_1ncjl”,”sa-fd-actn-cont”:”_yb_1xz55″,”sa-grp-hdr”:”_yb_1gak8″,”sa-grp-hdr-title”:”_yb_3h4ah”,”sa-history”:”_yb_1wts2″,”sa-img”:”_yb_opv8p”,”sa-img-ctn”:”_yb_zs77i”,”sa-img-icon”:”_yb_28dqf”,”sa-item”:”_yb_3bj6u”,”sa-item-title”:”_yb_pbfec”,”sa-rich-thumb”:”_yb_1pb5u”,”sa-sbx-container”:”_yb_9cq7n”,”sa-sugg”:”_yb_pcnlm”,”sa-thumb-icon”:”_yb_r7o3f”,”sa-tray”:”_yb_5l2uw”,”sa-tray-list-container”:”_yb_153i5″,”sa-trending”:”_yb_1dgje”,”sub-assist”:”_yb_uj1yg”,”suggestion-title”:”_yb_djni3″,trending:trending,”trending-title”:”_yb_15c4f”,”yui3-highlight”:”_yb_2x7et”},saConfV1={boldTag:’{s}‘,customEvent:{customBtn:”searchBtnClicked”,customKeyBoard:”enterKeyPressed”,customSelection:”assistSelectionClicked”},elems:{sbForm:”ybar-sf”,sbInput:”ybar-sbq”,sbSubmit:”ybar-search”,sbClear:”ybar-sbq-x”,sbCancel:”ybar-search-back-btn”},hightlight:{exact:!0,pattern:”^”},minInput:1,sa:{css:Css$6[“sa-tray”]},saBE:{base:””,host:””,params:{appid:”yfp-t”}},saItem:{css:””},saList:{css:Css$6[“sa-tray-list-container”]},saTitle:{css:””,style:{display:”block”}},plugins:{saFr:{disable:!0},saTray:{afterNode:”ybar-sbq”,ctn:{css:Css$6[“sa-sbx-container”]},tray:{css:Css$6.sa+” “+Css$6.lowlight}},saPCActn:{css:Css$6[“list-item-hover”]},ylcEncode:{disable:!0},saFlvr:{disable:!0},saEdit:{disable:!0},saAnnot:{disable:!0},saImg:{disable:!0},saPopup:{disable:!0}}},richSAConfV1={saBE:{base:””,host:””,params:{appid:”yfp-t”,”.crumb”:””,f:1}},shBE:{host:”https://search.yahoo.com”,base:”/history”,params:{_bcrumb:””}},minInput:0,plugins:{saFlvr:{m9:Css$6[“sa-trending”],m13:Css$6[“sa-history”],flvr:Css$6[“sa-sugg”]},saEdit:{ctn:{css:Css$6[“sa-edit”]},icon:{css:Css$6[“sa-edit-icon”]},text:{css:Css$6[“sa-edit-text”],text:”Remove”}},saAnnot:{title:{css:Css$6[“sa-annot-title”]},subtitle:{css:Css$6[“sa-annot-subtitle”]},richClass:Css$6[“sa-annot-rich”]},tapRmv:{placeholder:””},saImg:{placeholder:{css:Css$6[“sa-img-icon”]},thumbnail:{css:Css$6[“sa-img”]},ctn:{css:Css$6[“sa-img-ctn”]}},saGroup:{hdr:{css:Css$6[“sa-grp-hdr”]},title:{css:Css$6[“sa-grp-hdr-title”]},grps:{m9:{text:”Trending Now”,css:Css$6.trending},m13:{text:””,css:Css$6.history}}}}},richSAConfV1Smartphone={saBE:{base:””,host:””,params:{appid:”mi5″,”.crumb”:””,f:1}},shBE:{host:”https://search.yahoo.com”,base:”/history”,params:{_bcrumb:””}},saItem:{css:Css$6[“sa-item”]},saTitle:{css:Css$6[“sa-item-title”]},minInput:0,plugins:{saFlvr:{m9:Css$6[“sa-trending”],m13:Css$6[“sa-history”],flvr:Css$6[“sa-sugg”]},saEdit:{ctn:{css:Css$6[“sa-edit”]},icon:{css:Css$6[“sa-edit-icon”]},text:{css:Css$6[“sa-edit-text”]}},saAnnot:{title:{css:Css$6[“sa-annot-title”]},subtitle:{css:Css$6[“sa-annot-subtitle”]},richClass:Css$6[“sa-annot-rich”]},tapRmv:{placeholder:””},saImg:{placeholder:{css:Css$6[“sa-img-icon”],wrap:{css:Css$6[“sa-thumb-icon”]}},thumbnail:{css:Css$6[“sa-img”]},ctn:{css:Css$6[“sa-img-ctn”]},richClass:Css$6[“sa-rich-thumb”],showIconOnImgLoad:!0},saGroup:{hdr:{css:Css$6[“sa-grp-hdr”]},title:{css:Css$6[“sa-grp-hdr-title”]},grps:{m9:{text:”Trending Now”,css:Css$6.trending},m13:{text:””,css:Css$6.history}}}}},bottomSearch=function(e,t,n){var i=document.createElement(“div”);i.className=n[“bot-search-item”];var o=document.createElement(“div”),s=document.createElement(“div”);o.className=n[“bot-search-item-col”],s.className=n[“bot-search-item-col”];var r=document.createElement(“div”);r.className=n[“bot-search-icon-container”];var a=document.createElementNS(“http://www.w3.org/2000/svg”,”svg”),c=document.createElementNS(“http://www.w3.org/2000/svg”,”path”);a.setAttribute(“width”,”20″),a.setAttribute(“height”,”20″),a.setAttribute(“viewBox”,”0 0 24 24″),a.classList.add(n[“bot-search-icon”]),c.setAttribute(“d”,”M3.7634,15.837 L6.1814,15.837 C6.5214,17.45 7.0614,18.891 7.7584,20.045 C6.0094,19.118 4.6024,17.637 3.7634,15.837 L3.7634,15.837 Z M2.9144,12.008 C2.9144,11.351 2.9844,10.711 3.1164,10.094 L5.8884,10.094 C5.8264,10.717 5.7864,11.354 5.7864,12.008 C5.7864,12.663 5.8264,13.299 5.8884,13.922 L3.1164,13.922 C2.9844,13.305 2.9144,12.665 2.9144,12.008 L2.9144,12.008 Z M7.7584,3.971 C7.0614,5.125 6.5214,6.566 6.1814,8.179 L3.7634,8.179 C4.6024,6.379 6.0094,4.898 7.7584,3.971 L7.7584,3.971 Z M11.0504,3.142 L11.0504,8.179 L8.1054,8.179 C8.6604,5.664 9.7414,3.771 11.0504,3.142 L11.0504,3.142 Z M12.9654,3.142 C14.2754,3.771 15.3564,5.664 15.9114,8.179 L12.9654,8.179 L12.9654,3.142 Z M20.2524,8.179 L17.8344,8.179 C17.4954,6.566 16.9544,5.126 16.2574,3.971 C18.0064,4.898 19.4144,6.379 20.2524,8.179 L20.2524,8.179 Z M11.0504,20.875 C9.7414,20.245 8.6594,18.352 8.1054,15.837 L10.1354,15.837 C10.2104,15.161 10.3914,14.519 10.6584,13.922 L7.7984,13.922 C7.7354,13.305 7.7004,12.665 7.7004,12.008 C7.7004,11.351 7.7354,10.711 7.7984,10.094 L11.0504,10.094 L11.0504,13.184 C11.5394,12.388 12.1904,11.702 12.9654,11.183 L12.9654,10.094 L20.8994,10.094 C21.0284,10.697 21.0964,11.323 21.0994,11.964 L21.0994,11.964 L21.0994,12.661 C21.0994,13.19 21.5284,13.618 22.0574,13.618 L22.0584,13.618 C22.5874,13.618 23.0164,13.19 23.0164,12.661 L23.0164,11.965 L23.0144,11.965 C22.9904,5.662 17.6704,0.608 11.2724,1.024 C5.8994,1.373 1.4994,5.676 1.0414,11.04 C0.5134,17.228 5.1074,22.463 11.0504,22.975 C11.1664,22.985 11.3274,22.993 11.4844,22.999 C11.8104,23.012 12.1194,22.85 12.2904,22.572 L12.2924,22.569 C12.5734,22.113 12.3964,21.514 11.9124,21.284 L11.0504,20.875 Z M15.9434,18.874 C14.6054,18.874 13.5214,17.79 13.5214,16.452 C13.5214,15.115 14.6054,14.03 15.9434,14.03 C17.2804,14.03 18.3654,15.115 18.3654,16.452 C18.3654,17.79 17.2804,18.874 15.9434,18.874 M21.6354,20.908 L19.4524,18.725 C19.8774,18.07 20.1264,17.291 20.1264,16.452 C20.1264,14.145 18.2584,12.274 15.9514,12.269 L15.9354,12.269 C13.6284,12.274 11.7604,14.145 11.7604,16.452 C11.7604,18.763 13.6324,20.635 15.9434,20.635 C16.7814,20.635 17.5614,20.386 18.2154,19.961 L20.3984,22.144 C20.7404,22.486 21.2934,22.486 21.6354,22.144 C21.9774,21.803 21.9774,21.249 21.6354,20.908″),a.appendChild(c),r.appendChild(a),o.appendChild(r);var l=document.createElement(“span”),u=document.createElement(“span”);u.className=n[“bot-search-span”];var d=document.createElement(“span”),p=e.split(“{query}”);return l.textContent=p[0]||””,u.textContent=t,d.textContent=p[1]||””,s.appendChild(l),s.appendChild(u),s.appendChild(d),i.appendChild(o),i.appendChild(s),i},_getQueryStringByName=function(e){var t=new RegExp(“[?&]”+e+”=([^]*)”).exec(window.location.search);return t?t[1]:null},_getFrValueByMode=function(e,t,n){void 0===e&&(e=!1),void 0===t&&(t=!1);var i=document.getElementById(“ybar”),o=null==i?void 0:i.querySelector(‘input[name=”fr”]’),s=o?o.value:”yfp-t”,r=_getQueryStringByName(“fr”),a=r||s,c=i&&i.className&&i.className.match(/ybar-variant-([a-z]+)/),l=c?c[1]:””;return-1===[“att”,”frontier”,”rogers”].indexOf(l)&&(e&&(a+=”-m”),t&&(a+=”-s”)),”tn”!==n&&”tg”!==n||(a=r?a+”-tn”:(null==o?void 0:o.dataset.tnvalue)||a),a},_getFr2ValueByMode=function(e,t,n,i,o){void 0===n&&(n=!1);var s=null,r=”smartphone”===t&&!!document.querySelector(“.Reader-open”)||”smartphone”!==t&&!!document.querySelector(“.modal-open”),a=e.querySelector(‘input[name=”fr2″]’);if(a){s=a.value;var c=a.dataset&&a.dataset.savalue,l=a.dataset&&a.dataset.modalsb,u=a.dataset&&a.dataset.modalsa;n?s=r&&u?u:c:r&&l&&(s=l),i&&o&&(s=””.concat(s,”,ct:”).concat(i,”,kt:”).concat(o))}return s},_getTsrcValueByMode=function(e,t){void 0===t&&(t=!1);var n=null,i=e.querySelector(‘input[name=”.tsrc”]’);if(i){n=i.value;var o=i.dataset&&i.dataset.savalue;t&&o&&(n=o)}return n},_setInputValues=function(e,t,n){var i=e.querySelectorAll(t);if(i)for(var o=0;o=0?(s=”srch-asst”,u=!0,l=a.idx+1):s=”kybrd”:s=”botSearchClicked”===e.type?”sitesrch”:”icon”,”homepage”!==i&&”my”!==i||!r&&!u)”smartphone”===o&&(setFr2(t,o,u),setTsrc(t,u));else{var d=m(a),p=d.category,f=d.keyword;setFr(t,r,u,p),setFr2(t,o,u,p,f),setTsrc(t,u)}”ngy”===i&&(r||u)&&setFr(t,r,u),_(getI13nObject(s,”0″,l.toString()))}},y=function(e){var n,s=!!document.querySelector(“.modal-open”),r=null===(n=e.detail)||void 0===n?void 0:n.data,a=!0,c=(r&&r.idx||0)+1;if(“homepage”===i||”my”===i){var l=m(r),u=l.category,d=l.keyword;setFr(t,s,a,u),setFr2(t,o,a,u,d),setTsrc(t,a)}else”smartphone”===o&&(setFr2(t,o,a),setTsrc(t,a));”ngy”===i&&setFr(t,s,a),_(getI13nObject(“srch-asst”,”0″,c.toString()))},v=function(e){if(“function”==typeof n.beaconClick&&9!==e.keyCode&&13!==e.keyCode&&1===p&&”smartphone”!==o){n.saveCurrentTimerValue(“search_input_keyboard_input”);var t=getI13nObject(“keystroke”,”1″);delete t.clickParams.tar,p++,n.beaconClick(t.sec,t.slk,t.pValue,t.clickParams)}},b=function(){n.saveCurrentTimerValue(“search_input_focus_click”),”smartphone”===o&&t.addEventListener(“click”,(function(){if(e){if(e.classList.contains(“ybar-searchbox-assist-fullscreen”))return;e.classList.add(“ybar-searchbox-assist-fullscreen”)}if(!document.documentElement.classList.contains(“ybar-overlay”)){document.documentElement.classList.toggle(“ybar-overlay”),document.body.classList.add(“ybar-overlay-noscroll”);”function”==typeof n.beaconClick&&n.beaconClick(“ybar”,”websrch”,””,{elm:”expand”,subsec:”searchbox”,itc:”1″})}}))},_=function(e){if(“function”==typeof n.beaconClick){n.saveCurrentTimerValue(“search_query_submit”);var i={pp:{A_utm:n.getPerformanceI13nObject()}};n.beaconClick(e.sec,e.slk,e.pValue,e.clickParams,void 0,(function(){setTimeout((function(){t&&t.submit()}),300)}),i)}else t&&t.submit()};function w(){this.config={botSearch:{action:l,text:d||””},suggestionTitle:{text:u||””}}}function C(e){var t=this.config,n=this.app.view,i=n.elems.sbForm,o=n.elems.sbInput.value,s=suggestionTitle(Css$6,t.suggestionTitle.text),r=bottomSearch(t.botSearch.text,o,Css$6);r&&(e&&s&&(e.prepend(s),e.appendChild(r)),r.addEventListener(“click”,(function(){t.botSearch.action&&(i.action=t.botSearch.action),n.hide(),g(new CustomEvent(“botSearchClicked”))})))}c&&(c&&(c.addEventListener(“enterKeyPressed”,g),c.addEventListener(“assistSelectionClicked”,y),c.addEventListener(“searchBtnClicked”,g),c.addEventListener(“keydown”,v),c.addEventListener(“click”,b)),”homepage”!==i&&”my”!==i&&”ngy”!==i||(setFr(t),”homepage”===i&&setTypeByQueryString(t)),n.saveCurrentTimerValue(“search_assist_ready”)),w.prototype={init:function(e){this.app=e,e.on(“after_update_list”,C,this)}},l&&(null===(a=window.YAHOO.SA)||void 0===a||a.add(“saBotSearch”,w))},saInitV1=function(e,t,n,i,o,s){var r=t.searchBox.getAttribute(“data-appid”);if(window.YAHOO&&window.YAHOO.SA){“attgoog”===r&&(n.saBE.params.appid=”attgoog”),n.saBE.host=t.searchBox.getAttribute(“data-sabase”);var a=t.searchBox.dataset.sacrumb,c=t.searchBox.dataset.sabcrumb,l=t.searchBox.dataset.mtestid;a&&(n.saBE.params[“.crumb”]=a),c&&n.shBE&&(n.shBE.params._bcrumb=c),l&&(n.saBE.params.mtestid=l),ApplyOverrides$1(t.ybar,t.searchBox,{beaconClick:beaconClick,saveCurrentTimerValue:saveCurrentTimerValue,getPerformanceI13nObject:getPerformanceI13nObject},i,o,s),window.YAHOO.SA.init(n)}else{var u=”Search lib not found. SearchAssist failed to initialise”;e.logError(u,new Error(u))}},saConfV0={boldTag:’{s}‘,clearButtonId:”ybar-sbq-x”,suppressEmptyQuery:!0,anykey:!0,autofocus:!0,enableYlc:!1,fr2:”sa-gp-ybar”,searchBoxId:”ybar-sbq”,cssClass:{container:Css$6[“sa-sbx-container”],trayContainer:Css$6.sa+” “+Css$6.lowlight,tray:Css$6[“sa-tray”],traySub:Css$6[“sa-tray”]+” “+Css$6[“sub-assist”]+” “+Css$6[“no-wrap”],ul:Css$6[“sa-tray-list-container”],liHighlight:Css$6[“list-item-hover”],li:””,span:””,text:””,aria:””,actionContainer:Css$6[“sa-fd-actn-cont”],relatedSearches:Css$6[“related-title”],trendingNow:Css$6[“trending-title”]}},YbRapid=getAugmentedNamespace(rapid),nativeAssist=createCommonjsModule((function(e){var t=function(e,t){var n=function(){if(“Microsoft Internet Explorer”===e.navigator.appName){var t=new RegExp(“MSIE ([0-9]{1,}[.0-9]{0,})”).exec(e.navigator.userAgent);return t&&t[1]&&parseFloat(t[1])}return!1}();function i(e,t){e.prototype=Object.create?Object.create(t.prototype):function(e){function t(){}return t.prototype=e,new t}(t.prototype),e.prototype.constructor=e}function o(e){return”function”==typeof e.trim?e.trim():e.replace(/^s+|s+$/gm,””)}function s(e){if(n&&n{s}”,annotation:{},cssClass:{container:”sa-sbx-container”,trayContainer:”sa lowlight”,tray:”sa-tray”,traySub:”sa-tray sub-assist no-wrap”,ul:”sa-tray-list-container”,liHighlight:”list-item-hover”,li:””,span:””,text:””,aria:”sa-aria-live-region”,actionContainer:”sa-fd-actn-cont”,relatedSearches:”related-title”,trendingNow:”trending-title”},text:{relatedSearches:”Related Searches”,trendingNow:”Trending Now”,ariaShown:”new suggestions shown”,ariaClosed:”Suggestion box closed”},customEvent:!1,suppressEmptyQuery:!1,enableAnnotation:!1,enableIpos:!0,subAssist:!0,subTrayDelta:5,trayPadding:12,debug:!1,objectName:”SA”,anykey:!1,clearBeaconing:!1,enableYlc:!0,autofocus:!1,highlight:{pattern:””,exact:!1},minQueryLength:0,enableTabRender:!0}}return e.YAHOO=e.YAHOO||{},c.prototype={set:function(e,t,n){e.setAttribute(t,n)},get:function(e,t){return e.getAttribute(t)},merge:function e(t,n){for(var i in n)”object”==typeof n[i]&&”object”==typeof t[i]?e(t[i],n[i]):t[i]=n[i]},extend:i,buildUrl:function(e,t){var n=[];for(var i in t)t.hasOwnProperty(i)&&n.push(encodeURIComponent(i)+”=”+encodeURIComponent(t[i]));return n.length>0&&(e=e+(-1===e.indexOf(“?”)?”?”:”&”)+n.join(“&”)),e},stopPropagation:function(e){e.returnValue=!1,e.cancelBubble=!0,e.preventDefault&&e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation()},setFocus:function(e){s(e),r(e)},cursorEnd:s,select:function(e,t,i){if(n&&n&]/gim,(function(e){return””+e.charCodeAt(0)+”;”}))},ae:function(e,t,n,i){if(i||(i=!1),e.addEventListener)e.addEventListener(t,n,i);else{if(!e.attachEvent)return!1;e.attachEvent(“on”+t,n)}},de:function(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n);else{if(!e.detachEvent)return!1;e.detachEvent(“on”+t,n)}},ts:function(){return Math.round((new Date).getTime()/1e3)},bold:function(e,t,n,i){var o,s,r=(i.pattern?i.pattern:””)+”(&[^;\s]*)?(%needles)”;return(o=i.exact?[a(n)]:n.split(/[s|,]+/).filter((function(e){return””!==e})).sort((function(e,t){return t.length-e.length})).map((function(e){return a(e)}))).length?(r=r.replace(“%needles”,o.join(“|”)),t=t.replace(new RegExp(r,”gi”),(s=e,function(e,t,n){return t&&!/s/.test(n)?e:s.replace(/{s}/g,n)})),t):t},debug:function(t){this.config.debug&&e.console&&e.console.log&&e.console.log(t)}},i(l,c),l.prototype.init=function(n,i){var o=this;if(this.saModel=i,this.config=n,this.clearButton=this.clearButton||t.getElementById(this.config.clearButtonId),this.searchbox=this.searchbox||t.getElementById(this.config.searchBoxId),!this.searchbox)return!1;this.config.gossipParam.pq=this.searchbox.value;for(var s=this.searchbox;s&&!this.formTag;)s.tagName&&”form”===s.tagName.toLowerCase()&&(this.formTag=s),s=s.parentNode;return!!this.formTag&&(this.container=t.createElement(“div”),this.container.className=this.config.cssClass.container,this.trayContainer=t.createElement(“div”),this.trayContainer.className=this.config.cssClass.trayContainer,this.container.appendChild(this.trayContainer),this.searchbox.parentNode.insertBefore(this.container,this.searchbox.nextSibling),this.searchbox.setAttribute(“role”,”combobox”),this.searchbox.setAttribute(“aria-autocomplete”,”both”),this.ae(e,”load”,(function(){o.aria=t.createElement(“div”),o.aria.className=o.config.cssClass.aria,o.set(o.aria,”aria-live”,”polite”),o.aria.style.position=”absolute”,o.aria.style.left=”-9999px”,t.body.appendChild(o.aria)})),!0)},l.prototype.getWidth=function(e,n){var i,o={p:e,t:this.config.boldTag.replace(“{s}”,this.htmlEncode(e)),idx:0},s=t.createElement(“div”);s.className=this.config.cssClass.container;var r=t.createElement(“div”);r.className=this.config.cssClass.trayContainer,s.appendChild(r);var a=t.createElement(“div”);a.className=this.config.cssClass.traySub,a.style.left=”-9999px”,r.appendChild(a);var c=t.createElement(“ul”);c.className=this.config.cssClass.ul,a.appendChild(c);var l=this.createItem(o);n&&((i=t.createElement(“span”)).innerHTML=n,l.suggestionSpan.appendChild(i)),c.appendChild(l.li),this.searchbox.parentNode.insertBefore(s,this.searchbox.nextSibling);var u=l.suggestionSpan.clientWidth+this.config.subTrayDelta;return s.outerHTML=””,u},l.prototype.display=function(n){var i=n.data,o=n.sqpos,s=n.hiddenNeedle,r=this,a={};this.hide(),this.selectedItem=!1,this.tray=t.createElement(“div”),this.set(this.tray,”type”,”normal”),this.tray.className=this.config.cssClass.tray,o&&this.config.subAssist&&(this.tray.className=this.config.cssClass.traySub,this.tray.style.left=this.getWidth(s)+”px”),this.ul=t.createElement(“ul”),this.ul.className=this.config.cssClass.ul,this.set(this.ul,”role”,”listbox”),this.tray.appendChild(this.ul),this.itemList=[],this.config.ylcParam.n_sugg=r.saModel.ylc.n_sugg,i.forEach((function(n){var i;if(n.idx=r.itemList.length,4===n.m&&r.config.text.trendingNow&&!a.trending){var s=t.createElement(“span”);s.className=r.config.cssClass.trendingNow,s.innerHTML=r.config.text.trendingNow,r.ul.appendChild(s),a.trending=!0}var c=r.createItem(n);!o&&r.config.enableAnnotation&&n.m&&r.config.annotation[n.m]&&n.fd&&(i=r.getItemAnnotation(n,c.suggestionSpan))&&c.suggestionSpan.appendChild(i),r.ul.appendChild(c.li),r.itemList.push(c.li),r.ae(c.li,”mouseenter”,(function(e){r.resetHighlight(),c.li.className=r.config.cssClass.li+” “+r.config.cssClass.liHighlight,r.selectedItem=n.idx})),r.ae(c.li,”mouseleave”,(function(e){c.li.className=r.config.cssClass.li})),r.ae(c.li,”click”,(function(i){var o=r.searchbox.value,s=i.target||i.srcElement;r.saModel.ylc.pos=n.idx+1,r.saModel.ylc.pqstr=o,r.saModel.ylc.pqstrl=o.length,r.saModel.ylc.use_case=””,r.formTag.fr2&&(r.formTag.fr2.value=r.config.fr2),r.searchbox.value=n.p,s.tagName&&”a”===s.tagName.toLowerCase()&&(r.searchbox.value=r.get(s,”data”),r.saModel.ylc.use_case=s.innerHTML),r.hide(),r.saModel.addYlc(r.saModel.clickTarget),r.config.customEvent?(r.saModel.addYlk(s),function(n,i,o){var s;”function”==typeof e.CustomEvent?(s=new e.CustomEvent(i,{detail:o}),n.dispatchEvent(s)):”function”==typeof t.createEvent?((s=t.createEvent(“CustomEvent”)).initCustomEvent(i,!1,!1,o),n.dispatchEvent(s)):(t.attachEvent,document.documentElement[i]=o)}(r.searchbox,”assistSelection”,{data:n})):r.suggestionClick(i,n)}))})),this.aria&&(this.set(this.aria,”aria-expanded”,”true”),this.aria.innerHTML=”

    “+r.itemList.length+” “+this.config.text.ariaShown+”

    “),this.show()},l.prototype.suggestionClick=function(e,t){this.formTag.submit()},l.prototype.show=function(){this.shown=!0,this.resetHighlight(),this.trayContainer.appendChild(this.tray)},l.prototype.hide=function(){this.aria&&(this.set(this.aria,”aria-expanded”,”false”),this.aria.innerHTML=”

    “+this.config.text.ariaClosed+”

    “),this.shown=!1,this.resetHighlight(),this.trayContainer.innerHTML=””},l.prototype.resetHighlight=function(){!1!==this.selectedItem&&this.itemList.length&&(this.itemList[this.selectedItem].className=this.config.cssClass.li)},l.prototype.resetHightlight=l.prototype.resetHighlight,l.prototype.tab=function(){if(!this.shown||!this.itemList.length)return!1;if(!1!==this.selectedItem)this.searchbox.value=this.get(this.itemList[this.selectedItem],”data”),this.saModel.fetch();else{if(this.searchbox.value===this.get(this.itemList[0],”data”))return this.saModel.unset(),!1;this.searchbox.value=this.get(this.itemList[0],”data”),this.saModel.fetch()}return!0},l.prototype.moveUpDown=function(e){return!(!this.shown||!this.itemList.length)&&(this.resetHighlight(),e?!1===this.selectedItem||this.selectedItem=this.itemList.length-1?this.selectedItem=0:this.selectedItem++,this.itemList[this.selectedItem].className=this.config.cssClass.li+” “+this.config.cssClass.liHighlight,this.searchbox.value=this.get(this.itemList[this.selectedItem],”data”),!0)},l.prototype.createItem=function(e){var n=t.createElement(“li”),i=this;if(n.className=this.config.cssClass.li,this.set(n,”pos”,e.idx),this.set(n,”role”,”option”),this.config.formatResult){var o=this.config.ylcVal;o&&(o=o.replace(“cposV”,e.idx),i.config.ylcParam&&(o=o.replace(“t9Val”,i.config.ylcParam.n_sugg)),this.set(n,”data-ylk”,o)),this.set(n,”data-position”,e.idx)}i.set(n,”data”,e.p);var s=t.createElement(“span”);s.className=i.config.cssClass.span,s.style.display=”block”,n.appendChild(s);var r=t.createElement(“span”);return r.className=i.config.cssClass.text,r.innerHTML=e.t,s.appendChild(r),{li:n,suggestionSpan:s}},l.prototype.getItemAnnotation=function(e){var n,i,o,s=this.config.annotation[e.m]||{},r=this.config.cssClass,a=e.fd,c=””,l=””,u=this.searchbox.clientWidth-2*this.config.trayPadding;if(s.subtitle&&a.subtitle){if(l=s.subtitle.replace(“{subtitle}”,this.htmlEncode(a.subtitle)),!(this.getWidth(e.p,l)‘+l+””)>u){l=””;break}l&&(c+=’‘+l+”“)}return c&&((n=t.createElement(“span”)).innerHTML=c),n},i(u,c),u.prototype.unset=function(){this.triggered=!1,this.saView.hide()},u.prototype.jsonp=function(e,n){var i={command:this.saView.searchbox.value,t_stmp:this.ts(),callback:”YAHOO.”+this.config.objectName+”.cb.”+e};this.merge(i,this.config.gossipParam),n&&this.merge(i,n);var o=this.buildUrl(this.config.saBase,i),s=t.getElementsByTagName(“head”)[0],r=t.createElement(“script”);this.set(r,”type”,”text/javascript”),this.set(r,”src”,o),s.appendChild(r),this.ae(r,”load”,(function(){s.removeChild(r)}))},u.prototype.read=function(e){var t,n=this,i=[],o=e.sqpos,s=e.q=e.q||””,r=””;e&&”object”==typeof e.r&&e.r.length>0?(n.config.subAssist&&o&&(s=e.q.substr(o),r=e.q.substr(0,o),e.r.forEach((function(t){n.saView.getWidth(t.k)>n.saView.searchbox.clientWidth&&(o=0,s=e.q,r=””)}))),e.r.forEach((function(e){t=n.config.subAssist&&o?e.k.substr(o):e.k,i.push({p:e.k,t:n.bold(n.config.boldTag,n.htmlEncode(t),n.htmlEncode(s),n.config.highlight),fd:e.fd,m:e.m})})),this.ylc.n_sugg=e.r.length,this.ylc.pos=0,this.saView.display({data:i,sqpos:o,hiddenNeedle:r})):(this.ylc.n_sugg=0,this.ylc.pos=0,this.saView.hide()),e&&e.l&&(this.ylc.gprid=e.l.gprid)},u.prototype.fetch=function(){var e,t=this.saView.searchbox,n=this,i=null,s=n.lastValue===n.saView.searchbox.value;if(n.config.suppressEmptyQuery&&””==o(t.value))return n.unset(),!0;if(n.saView.shown&&s)return!0;if(this.config.enableIpos&&!s&&void 0!==n.lastValue&&((e=this.getCursorPosition())===t.value.length&&(e=null),null!==e&&(i={ipos:e})),n.lastValue=n.saView.searchbox.value,this.config.minQueryLength&&this.saView.searchbox.value.lengththis.config.max)return this.unset(),!0;this.triggered=!0,this.callBackIdx++;var r=”sacb”+this.callBackIdx;for(var a in n.cbTable)n.cbTable.hasOwnProperty(a)&&(n.cbTable[a]=function(){});this.cbTable[r]=function(e){n.read(e||{}),n.cbTable[r]=function(){}},this.jsonp(r,i)},u.prototype.getCursorPosition=function(){var e,n=this.saView.searchbox,i=null;return”number”==typeof n.selectionStart?i=n.selectionStart:t.selection&&(n.focus(),(e=t.selection.createRange()).moveStart(“character”,-t.activeElement.value.length),i=e.text.length),i},u.prototype.addYlc=function(e){var t=encodeURIComponent(this.saView.searchbox.value);this.ylc.query=t,this.ylc.qstrl=t.length,this.ylc.t_stmp=this.ts(),this.config.enableYlc&&this.ULT?this.saView.formTag.action=this.ULT.y64_token(“ylc”,e,this.ylc):this.debug(“YLC logging is disabled”)},u.prototype.addYlk=function(e){var t=this,n=[];if([“gprid”,”query”,”pqstr”].forEach((function(e){e in t.ylc&&n.push(e+”:”+t.ylc[e])})),t.config.ylcVal=t.config.ylcVal+”;”+n.join(“;”),e){var i=t.get(e,”data-ylk”)+”;”+n.join(“;”);t.set(e,”data-ylk”,i)}},u.prototype.init=function(t){return this.config=t,this.ULT=e.YAHOO.ULT,this.ULT||(this.debug(“ULT library is missing. Disabling ylc logging”),this.config.enableYlc=!1),this.ylc={},this.merge(this.ylc,this.config.ylcParam),this.clickTarget=this.config.clkLink?this.config.clkLink:this.saView.formTag.action,this.submitTarget=this.saView.formTag.action,!0},i(d,c),d.prototype.init=function(i){var s=this;s.lastValue=null,this.config=i,this.config.autofocus&&this.setFocus(this.saView.searchbox),!n||n>=9?this.ae(this.saView.searchbox,”input”,(function(e){s.saModel.fetch()})):8===n&&this.ae(this.saView.searchbox,”propertychange”,(function(e){“value”===e.propertyName&&!1===s.saView.selectedItem&&s.saModel.fetch()})),s.config.anykey&&this.ae(t,”keydown”,(function(e){var n=t.activeElement;if(!n.tagName||”input”!==n.tagName.toLowerCase()&&”textarea”!==n.tagName.toLowerCase())return 27===e.keyCode&&!s.saView.shown&&s.saView.searchbox.value.length?(s.select(s.saView.searchbox,0,s.saView.searchbox.value.length),void s.stopPropagation(e)):void(e.keyCode-1?i=o=l:(i=-u.moveStart(“character”,-l),i+=a.slice(0,i).split(“n”).length-1,u.compareEndPoints(“EndToEnd”,d)>-1?o=l:(o=-u.moveEnd(“character”,-l),o+=a.slice(0,o).split(“n”).length-1)),r.selectionStart=i,r.selectionEnd=o}s.lastValue!==s.saView.searchbox.value&&!1===s.saView.selectedItem&&s.saModel.fetch()};this.ae(this.saView.searchbox,”focus”,(function(e){!s.saModel.triggered&&s.saModel.fetch(),n&&9===n&&!s.ie9_attached&&(s.ae(t,”selectionchange”,r),s.ie9_attached=!0)})),this.ae(this.saView.searchbox,”blur”,(function(e){n&&9===n&&s.ie9_attached&&(s.de(t,”selectionchange”,r),s.ie9_attached=!1)})),this.ae(this.saView.searchbox,”click”,(function(e){!s.saModel.triggered&&s.saModel.fetch()}));var a=function(e){if(s.saView.shown){for(var t=e.target?e.target:e.srcElement;t;){if(t===s.saView.formTag)return;t=t.parentNode}s.config.touchOriented&&s.stopPropagation(e),s.saModel.unset()}};return”ontouchstart”in e?(this.config.touchOriented=!0,this.ae(t.body,”touchstart”,a,!0)):this.ae(t,”click”,a),this.ae(this.saView.formTag,”submit”,(function(e){s.saModel.addYlc(s.saModel.submitTarget)})),this.saView.clearButton&&this.ae(this.saView.clearButton,”click”,(function(e){if(s.saView.searchbox.value=””,s.saModel.triggered=!1,s.setFocus(s.saView.searchbox),s.config.enableYlc&&s.config.clearBeaconing&&s.saModel.ULT){var t={_r:2,actn:”clk”,pos:1,sec:”clearsearch”,slk:”clear”,t1:”hdr”,t2:”searchbox”,t3:”clear”};s.merge(t,s.config.clrLog),s.saModel.ULT.beacon_click(t)}})),!0},i(p,c),p.prototype.saModelClass=u,p.prototype.saViewClass=l,p.prototype.saControlClass=d,p.prototype.init=function(i){return!(n&&n=200&&o.statusn?Promise.resolve(t.data):void 0}},setCacheData=function(e,t){var n={lastRequested:Date.now(),status:JwsRequestStatus.COMPLETE,promise:Promise.resolve(t),data:t};jwsCache.set(e,n)},setCachePromise=function(e,t){var n={lastRequested:Date.now(),status:JwsRequestStatus.PENDING,promise:t};jwsCache.set(e,n)},Jws=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.fetchPreview=function(e,t){var n=(void 0===e?{}:e).maxMessages,i=void 0===n?4:n;return __awaiter(this,void 0,void 0,(function(){var e,n,o,s=this;return __generator(this,(function(r){return e=getCache(JwsRequestType.PREVIEW),!t&&e?[2,e]:(1,n={data:{responseType:”json”,requests:[{id:”GetMailboxId”,uri:”/ws/v3/mailboxes/”,method:”GET”,filters:{select:{mailboxId:”$..mailboxes[?(@.isPrimary==true)].id”}},suppressResponse:!0,requests:[{id:”ListMessages”,uri:”/ws/v3/mailboxes/@.id==$(mailboxId)/messages/@.select==q?q=count%3A6+offset%3A0+folderType%3AINBOX+-sort%3Adate”,method:”GET”}]}]}},o=this._fetch(n,1,(function(e){var t=s._normalizePreviewResponse(e,{maxMessages:i});return setCacheData(JwsRequestType.PREVIEW,t),t})),setCachePromise(JwsRequestType.PREVIEW,o),[2,o])}))}))},e.prototype.fetchCount=function(e){return __awaiter(this,void 0,void 0,(function(){var t,n,i,o=this;return __generator(this,(function(s){return t=getCache(JwsRequestType.COUNT),!e&&t?[2,t]:(1,n={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”}]}]}},i=this._fetch(n,1,(function(e){var t=o._normalizerCountResponse(e);return setCacheData(JwsRequestType.COUNT,t),t})),setCachePromise(JwsRequestType.COUNT,i),[2,i])}))}))},e.prototype._fetch=function(e,t,n){var i,o;return __awaiter(this,void 0,void 0,(function(){var s,r,a,c,l,u,d,p,f,h,m,g,y,v,b,_;return __generator(this,(function(w){switch(w.label){case 0:if(s=e.data,r=void 0===s?{}:s,a=e.params,c=void 0===a?{}:a,l=”EC-4008″,u=”EC-4003″,d=this._getYmreqid(),!this.appid)throw new Error(“No appId, user is logged out”);p=__assign({appId:this.appid},c),this.wssid&&(p.wssid=this.wssid),e.params=p,f=[],Object.keys(p).forEach((function(e){var t=p[e];t&&f.push(“”.concat(encodeURIComponent(e),”=”).concat(encodeURIComponent(t)))})),h=f.length?”?”.concat(f.join(“&”)):””,m=”https://apis.mail.yahoo.com/ws/v3/batch”.concat(h),w.label=1;case 1:return w.trys.push([1,4,,5]),[4,ybarFetch(m,{method:”POST”,body:JSON.stringify(r),credentials:”include”,headers:{“Content-Type”:”application/json”,”X-Oath-YmReqId”:d}})];case 2:return[4,(g=w.sent()).json()];case 3:if(y=w.sent(),g.ok)return[2,n(null===(o=y.result)||void 0===o?void 0:o.responses)];if((v=null===(i=null==y?void 0:y.error)||void 0===i?void 0:i.code)===u)return[2,this._handleWssidApiError(y,e,t,n)];throw v===l?new Error(“Session has expired”):new Error(“Mail Api Responded with an Error”);case 4:throw b=w.sent(),logError(“JWS: “.concat((_=b).message),_),b;case 5:return[2]}}))}))},e.prototype._normalizePreviewResponse=function(e,t){var n,i,o,s=this,r=(void 0===t?{}:t).maxMessages,a=void 0===r?4:r;return e?((null===(o=null===(i=null===(n=null==e?void 0:e[0])||void 0===n?void 0:n.response)||void 0===i?void 0:i.result)||void 0===o?void 0:o.messages)||[]).map((function(e){return s._parseRawMessage(e)})).filter((function(e,t){return!!(e&&t0)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._parseRawMessage=function(e){var t,n,i,o,s,r,a=e.id,c=e.snippet,l=e.headers,u=e.flags;return(null==l?void 0:l.date)&&(null===(t=null==l?void 0:l.from)||void 0===t?void 0:t[0])?{from:(null===(i=null===(n=l.from)||void 0===n?void 0:n[0])||void 0===i?void 0:i.name)||””,email:(null===(s=null===(o=l.from)||void 0===o?void 0:o[0])||void 0===s?void 0:s.email)||””,subject:null==l?void 0:l.subject,read:null!==(r=null==u?void 0:u.read)&&void 0!==r&&r,mid:a,date:parseInt(l.date,10)||void 0,snippet:c||””}:null},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}(),showMailUnreadCount$1=function(e){var t=document.querySelectorAll(“.”.concat(Css$5.badge));null!==t&&0!==t.length&&(new Jws).fetchCount().then((function(n){if(t&&n>0)for(var i=function(i){t[i].classList.remove(Css$5.hide),t[i].textContent=n>99?”99+”:n.toString(),e.onDestroy((function(){t[i].classList.add(Css$5.hide),t[i].textContent=””}))},o=0;o40959)&&(o19903))return!1}return!0},normalizeAndEscapeUserRecord=function(e){var t={fn:e.fn||””,ln:e.ln||””,em:e.em||””,alias:e.alias||””,imageUrl:e.imageUrl,state:e.state,fullName:null,identifier:””};return t.fullName=isNameCJK(t.fn,t.ln)?[t.ln,t.fn].join(“”):[t.fn,t.ln].join(” “),t.identifier=t.em||t.alias,t},createAccountItemElement=function(e,t,n){var i=n.ybarAccMenuItemTemplate,o=n.crumb;if(i){var s=(t+1).toString(),r=i.getAttribute(“data-signedOutState”),a=i.getAttribute(“data-done”)||””,c=getTemplateContent(i),l=c.children&&c.children[0];if(!l&&c.childNodes)for(var u=0;u=0;–t){e[t]=normalizeAndEscapeUserRecord(e[t]);var n=e[t].state;0!==n&&”0″!==n||(window.YBAR&&window.YBAR.setUserEmail(e[t].em),e.splice(t,1)[0])}return e},addDoneUrlToEl=function(e,t,n){return 0===e.indexOf(“javascript:”)||~e.indexOf(“https://membernotifications.aol.com/notice/maillogout”)?e:(n&&(n=~e.indexOf(“&activity=ybar-“)?void 0:n.replace(“[[pspid]]”,getSpaceId())),~e.indexOf(“done=”)?(e=e.replace(/[[page]]/g,encodeURIComponent(window.location.href)),n&&(e+=”&”+n),e):~e.indexOf(“dest=[[done]]”)?e.replace(/[[done]]/g,encodeURIComponent(t)):(e=appendQorA(e),e+=”.done=”+encodeURIComponent(t),n&&(e+=”&”+n),e))},addDoneUrlToAllLink=function(e,t){var n,i=e.ybarAccMenuItemTemplate,o=e.ybarAccountContainer,s=document.querySelector(“.”.concat(Css$4[“ybar-mod-account”],” .”).concat(Css$4[“ybar-login-btn”])),r=document.querySelector(“.”.concat(Css$4[“ybar-mod-account”],” .”).concat(Css$4[“ybar-sign-out”])),a=o&&o.querySelectorAll(“a”),c=””,l=window.location.href;if(s){var u=s.href;t.onDestroy((function(){s.href=u})),s.href=addDoneUrlToEl(s.href,l,s.getAttribute(“data-redirect-params”)||void 0)}if(i?(l=i.getAttribute(“data-done”)||””,c=i.getAttribute(“data-sign-out-url”)||””):r&&(c=r.getAttribute(“data-sign-out-url”)||””),a){var d=function(){var e=n,i=a[e].href;t.onDestroy((function(){a[e].href=i}));var o=a[n].getAttribute(“data-redirect-params”);a[n].classList.contains(Css$4[“ybar-sign-out”])?a[n].href=addDoneUrlToEl(a[n].href,c,o||void 0):a[n].href=addDoneUrlToEl(a[n].href,l,o||void 0)};for(n=0;n0){var m=document.querySelector(“”.concat(s,” .”).concat(Css$4[“ybar-sign-out”])),g=m&&m.getAttribute(“data-soa”),y=document.querySelector(“”.concat(s,” .”).concat(Css$4[“ybar-sign-out-text”]));if(y&&g&&(y.innerText=g),c&&c.classList.add(Css$4.show),n){var v=document.querySelector(“”.concat(s,” “).concat(Css$4[“ybar-icon-arrow”])),b=Css$4[“ybar-icon-arrow-up”],_=Css$4[“ybar-icon-arrow-down”],w=Css$4[“ybar-item-hidden”],C=document.querySelectorAll(“.”.concat(Css$4[“ybar-item-hidden”]));v&&(v.classList.toggle(_),e.addElementListener(v,”click”,(function(){for(var e=0;eu){var E=document.querySelector(“”.concat(s,” .”).concat(Css$4[“ybar-see-info”]));E&&E.style&&(E.style.display=”block”)}addDoneUrlToAllLink(t,e)}else r&&(r.style.display=”block”)}))}},handleResetBadge=function(e){getNotifClient().resetBadge(),e.notifBadge&&(e.notifBadge.style.visibility=”hidden”),e.profNotifBadge&&(e.profNotifBadge.style.visibility=”hidden”)},getPath=function(e){if(“function”==typeof e.composedPath)return e.composedPath();if(e.path)return e.path;for(var t=e.target,n=[];null!==t.parentNode;)n.push(t),t=t.parentNode;return n.push(document,window),n},notify=function(e,t){var n=t.ybarAccountContainer,i=t.smartphoneNotifContainer,o=t.notificationMenu,s=t.notifBadge,r=t.dropdownContainer,a=t.ybarNotificationBody,c=t.profNotifBadge,l=t.backButton,u=function(e){(null==e?void 0:e.newCount)&&e.newCount>0&&s&&(s.style.visibility=”visible”,c&&(c.style.visibility=”visible”,c.innerText=s.innerText))},d=getNotifClient(),p=function(){d.refreshPanel().then(u).catch((function(){}))};if(i){p();var f=setInterval((function(){p()}),3e5);e.onDestroy((function(){clearInterval(f)})),e.addElementListener(o,”click”,(function(){p(),r&&(r.style.display=”block”),n&&(n.style.width=”100%”,n.scrollTop=0,n.style.overflow=”hidden”),handleResetBadge(t),beaconClick(“ybar”,”notification”,””,{slk:”notification”,elm:”btn”,elmt:”visible”===(null==s?void 0:s.style.visibility)?”new alert”:””,sec:”ybar”,subsec:”notification”,pkgt:”profile-pane”,itc:”1″})})),e.addElementListener(l,”click”,(function(){r&&(r.style.display=”none”),n&&(n.style.width=””,n.style.overflow=””),beaconClick(“ybar”,”back-notification”,””,{slk:”back-notification”,elm:”arrow”,pkgt:”profile-pane”,sec:”ybar”,subsec:”notification”,itc:”1″})})),a&&e.addElementListener(a,”click”,(function(e){getPath(e).find((function(e){var t=e;if(t.nodeName&&”a”===t.nodeName.toLowerCase()&&t.classList.contains(“yns-link”))return r&&(r.style.display=”none”),n&&(n.style.width=””,n.dispatchEvent(new CustomEvent(“toggle-overlay”))),!0}))}))}},canBuildAccSwitcherList=!0,accSettingDropdownOpen=!1,visibilityTracking=0,params,imageElementsConfig={ybarAccountImage:{selector:”ybar-account-img”,size:”64″},ybarCurrentUserProfileImage:{selector:”ybar-current-user-profile-img”,size:”128″},ybarUserProfileImage:{selector:”ybar-user-profile-img”,size:”128″}},pictureOnErrorForSize=function(e,t){var n=”https://s.yimg.com/wm/modern/images/default_user_profile_pic_”+e+”.png”;t.onerror=null,t.srcset=””,t.src=n},init$3=function(e,t){var n=t.ybarAccountContainer,i=t.ybarAccountMenu,o=t.ybarMobile,s=t.isSmartphone,r=t.ybarMenuManagePub,a=t.arrowWrapper,c=t.downArrow,l=t.upArrow,u=t.otherAccWrapper,d=t.signInAccountMenu,p=t.signInBtn,f=t.ybarModAccount,h=t.yahooPlusImpression,m=function(i){if(n)n.style.removeProperty(“display”),”false”===n.getAttribute(“data-enabled”)&&(n.style.display=”none”),addDoneUrlToAllLink(t,e);else{var o=new Error(“ybarAccountContainer not Found”);logError(“ERROR:”,o)}n&&canBuildAccSwitcherList&&(canBuildAccSwitcherList=!1,e.onDestroy((function(){canBuildAccSwitcherList=!0})),buildAccSwitcherList(e,t,i))},g=function(){var e,t;0===visibilityTracking&&(visibilityTracking=1,null===(e=null==i?void 0:i.parentNode)||void 0===e||e.removeEventListener(“mouseenter”,g),null===(t=null==i?void 0:i.parentNode)||void 0===t||t.removeEventListener(“focusin”,g),setTimeout((function(){refreshModule()}),500))},y=function(){null==n||n.classList.remove(“ybarMenuOpen”),null==i||i.setAttribute(“aria-expanded”,”false”)},v=function(){if(h&&!h.getAttribute(“src”)&&h.getAttribute(“data-src”)){var t=h.getAttribute(“data-src”)||””;addConsentToUrl(t).then((function(e){h.setAttribute(“src”,e)})),e.onDestroy((function(){h.setAttribute(“src”,””)}))}};if(p&&(addHoverEvent(e,p,”ybar”,”sign-in”,params={elm:”signin”,subsec:”settings”,itc:”2″}),addDoneUrlToAllLink(t,e)),i||o||d){if(o)m(!0);else{if(m(!1),e.addEventListener(“close-all-menus”,(function(){i&&!isHovered(i)?i.checked=!1:d&&d.classList.contains(Css$4.show)&&d.parentNode&&!isHovered(d.parentNode)&&y()})),e.onDestroy((function(){y()})),i){if(i.onchange=function(){e.triggerEvent(“close-all-menus”)},params={itc:”2″,elm:”menu”,elmt:”user-info”,subsec:”accounts”},s){var b=document.querySelector(“#ybarAccountMenuOpener”);b&&b.setAttribute(“data-ylk”,”slk:Settings;elm:btn;sec:ybar;subsec:settings;pkgt:profile-pane;itc:0;tar:login.yahoo.com”),function(){n&&addOverlay(n,”right”,e);var t=document.querySelector(“.”.concat(Css$4[“ybar-icon-image-wrapper”]));e.addElementListener(t,”click”,(function(){null==n||n.dispatchEvent(new CustomEvent(“toggle-overlay”))}))}(),e.addElementListener(a,”click”,(function(){var e,t;accSettingDropdownOpen?(null==c||c.classList.remove(“hide”),null==l||l.classList.add(“hide”),u&&(u.style.height=”0″)):(null==c||c.classList.add(“hide”),null==l||l.classList.remove(“hide”),u&&(t=(e=u).scrollHeight,e.style.height=t+”px”));var n=”manage-account-open”,i={elm:”expand”,subsec:”settings”,pkgt:”profile-pane”,itc:”1″};(accSettingDropdownOpen=!accSettingDropdownOpen)||(n=”manage-account-close”,i.elm=”btn”),beaconClick(“ybar”,n,””,i)})),notify(e,t)}else{var _=document.querySelector(“#ybarAccountMenu + label”);_&&(addHoverEvent(e,_,”ybar”,”profile-expand”,params),e.addElementListener(_,”mouseenter”,v),e.addElementListener(f,”focus”,v)),i&&i.parentNode&&(e.addElementListener(i.parentNode,”mouseenter”,g),e.addElementListener(i.parentNode,”focusin”,g))}hideOutlineOnMouseDown(“#ybarAccountMenu”,”#ybarAccountMenu + label”,e)}e.addElementListener(f,”focusin”,(function(){null==n||n.classList.add(“ybarMenuOpen”),null==i||i.setAttribute(“aria-expanded”,”true”)})),e.addElementListener(f,”focusout”,y),e.addElementListener(r,”click”,y)}Object.keys(imageElementsConfig).forEach((function(e){var t=imageElementsConfig[e],n=document.querySelector(“.”.concat(Css$4[t.selector]));n&&(n.onerror=function(){pictureOnErrorForSize(t.size,n)})}))}};initModule(“ybar-account-init”,(function(e){var t=document.getElementById(“ybarAccountContainer”),n={ybarAccountContainer:t,ybarAccountMenu:document.getElementById(“ybarAccountMenu”),ybarMobile:document.querySelector(“.”.concat(Css$4.mobile,” .”).concat(Css$4[“ybar-account-user-email”])),isSmartphone:document.querySelector(“.”.concat(Css$4.smartphone)),ybarMenuManagePub:document.getElementById(“ybarMenuManagePub”),arrowWrapper:document.getElementById(“smartphone-arrow”),downArrow:document.getElementById(“down-arrow”),upArrow:document.getElementById(“up-arrow”),otherAccWrapper:document.getElementById(“otherAccWrapper”),signInAccountMenu:document.querySelector(“.”.concat(Css$4[“ybar-mod-account”],” .”).concat(Css$4[“sign-in-menu”])),signInBtn:document.querySelector(“.”.concat(Css$4[“ybar-mod-account”],” .”).concat(Css$4[“ybar-login-btn”])),ybarModAccount:document.querySelector(“.”.concat(Css$4[“ybar-mod-account”])),yahooPlusImpression:t&&t.querySelector(“.”.concat(Css$4[“ybar-account-yahoo-plus-imp”])),crumb:document.querySelector(‘input[name=”crumb”]’),ybarAccMenuItemTemplate:document.getElementById(“ybarAccMenuItemTemplate”),generalSignin:document.getElementById(“generalSignin”),inSessionSignin:document.getElementById(“inSessionSignin”),smartphoneNotifContainer:document.getElementById(“smartphoneNotifContainer”),notificationMenu:document.getElementById(“smartphoneNotifMenu”),notifBadge:document.getElementById(“notif-badge”),profNotifBadge:document.querySelector(“.”.concat(Css$4[“prof-notif-badge”])),dropdownContainer:document.getElementById(“notifDropdownContainer”),ybarNotificationBody:document.getElementById(“ybarNotificationBody”),backButton:document.getElementById(“backButton”)};init$3(e,n)}));var Css$2={“popover-body”:”_yb_1yhlo”,”ybar-mail-item-desc”:”_yb_mr06u”,”ybar-mail-item-image”:”_yb_1p0yw”,”ybar-mail-item-link”:”_yb_8w4lu”,”ybar-mail-item-name”:”_yb_84d7o”,”ybar-mail-item-snippet”:”_yb_a2r1k”,”ybar-mail-item-time”:”_yb_ubajt”,”ybar-mail-item-unread”:”_yb_diu7h”,”ybar-mail-link”:”_yb_1f8hc”,”ybar-mail-list”:”_yb_pzdhk”,”ybar-mail-preview”:”_yb_1qmkz”,”ybar-mail-signin-link”:”_yb_l87ha”,”ybar-mod-mail”:”_yb_89wy3″,”ybar-mod-mail-promo-imp”:”_yb_15t8v”},loadAssets=function(e,t,n){for(var i,o,s=[],r=[],a=0;a0&&function(e){var t=document.createElement(“script”);t.src=e,t.type=”text/javascript”,t.async=!0,document.getElementsByTagName(“head”)[0].appendChild(t)}(c))}),10)}},getNextGenMailPreview=function(e){postreq({url:”/fp_ngymtls_ms/_rcv/remote”,body:{m_id:”react-wafer-mailpreview”,m_mode:”json”,ctrl:”MailPreview”}},(function(t,n){t||e(n)}))},loaded=!1,init$2=function(e,t){var n=t.mailModule,i=t.mailLink,o=t.mailSigninLink,s=t.ybarMailMessages;if(n){var r=new Jws;if(e.addElementListener(n,”mouseenter”,(function(){e.triggerEvent(“close-all-menus”),triggerRapidBeacon()})),e.addEventListener(“close-all-menus”,(function(){isHovered(n)||hideMailPopover(t)})),e.onDestroy((function(){hideMailPopover(t)})),loaded=!1,loadUnreadCount(e,t,r),s)e.addElementListener(i,”mouseover”,(function(){loadMessages(e,t,r),fireYahooImpBeacon(e,t)})),e.addElementListener(i,”focus”,(function(){loadMessages(e,t,r),triggerRapidBeacon(),fireYahooImpBeacon(e,t)}));else{var a=i.getAttribute(“data-redirect-params”);if(a&&””!==a){var c=i.href;e.onDestroy((function(){i.href=c})),a=-1!==i.href.indexOf(“&activity=ybar-“)?””:a.replace(/[[pspid]]/,getSpaceId()),i.href=appendQorA(i.href)+a,(null==o?void 0:o.href)&&(o.href=appendQorA(o.href)+a)}}}},mailBeaconTimeout=!1,triggerRapidBeacon=function(){mailBeaconTimeout||(mailBeaconTimeout=!0,sendRapid({slk:”Mail”,elm:”expand”,sec:”ybar”,subsec:”mailprev”,itc:”2″}),setTimeout((function(){mailBeaconTimeout=!1}),1e3))},sendRapid=function(e){beaconClick(“ybar”,(null==e?void 0:e.slk)||”Mail”,””,e,null)},relativeDate=function(e){if(!e)return””;var t=Math.round((new Date).getTime()/1e3)-e;return t86400?Math.floor(t/86400)+”d”:””},createMailItemElement=function(e,t,n,i){var o,s=getTemplateContent(t.ybarMailItemTemplate),r=null===(o=s.children)||void 0===o?void 0:o[0];if(!r&&s.childNodes)for(var a=0;a0){if(i.style.visibility=”visible”,o){var n=t>999,r=s?”99+”:”999+”;o.textContent=n?r:t+””}e.onDestroy((function(){i.style.visibility=”hidden”,o&&(o.textContent=””)}))}})).catch((function(){}))},loadMessages=function(e,t,n){loaded||(loaded=!0,t.isNextGenYahoo?loadNGYMailPreview(e,t):loadMailPreview(e,t,n))},loadMailPreview=function(e,t,n){n.fetchPreview().then((function(n){var i;if(n&&0!==n.length){var o=document.createElement(“ul”);o.className=Css$2[“ybar-mail-list”];for(var s=0;s a”),i=document.querySelector(“#ybar-navigation-item-mail > a > span”);null!==t&&null!==n&&(new Jws).fetchCount().then((function(t){i&&t>0&&(i.textContent=”(“+(t>999?”999+”:t)+”)”,e.onDestroy((function(){i.textContent=””})))})).catch((function(){}))},nodeContains=function(e,t){var n=!1;if(!e||!t)return n;if(“function”==typeof e.contains)n=e.contains(t);else for(var i=t;i;){if(i===e){n=!0;break}i=i.parentElement}return n},MORE_MENU_WIDTH=61,MORE_MENU_LONG_LIST_COUNT=10,moreMenuIndex=-1,marginLeftOffset,initDropdowns=function(e,t){var n;__spreadArray([],null===(n=t.ybarNav)||void 0===n?void 0:n.querySelectorAll(“.”.concat(t.dropdownOpenClass)),!0).forEach((function(e){return e.classList.remove(t.dropdownOpenClass)}));var i=t.isTablet?”touchstart”:”mouseover”,o=delegate_1(“.”.concat(t.dropdownWrapperClass,”, .”).concat(t.navigationDropdownListClass),i,(function(n){if(window||document){var i=window.innerWidth||document.documentElement.clientWidth,o=n.delegateTarget;if(o&&-1!=o.className.indexOf(t.dropdownWrapperClass)&&(o=o.querySelector(“.”.concat(t.navigationDropdownListClass))),o){o.style.removeProperty(“left”),t.shiftMoreMenuEnabled&&o.style.removeProperty(“margin-left”),t.shiftMoreMenuEnabled&&marginLeftOffset&&(o.style.marginLeft=marginLeftOffset+”px”);var s=o.getBoundingClientRect().right;s>i&&(t.shiftMoreMenuEnabled?(marginLeftOffset||(marginLeftOffset=parseInt(window.getComputedStyle(o).marginLeft,10)),o.style.marginLeft=marginLeftOffset+i-s+”px”):o.style.left=i-s+”px”)}}else{var r=new Error(“Dropdown could not be initialized”);e.logError(“Error:”,r)}}));e.onDestroy((function(){o.destroy()}))},updateMoreMenu=function(e,t,n){var i,o,s,r=-1,a=0;if(e.ybarNav){var c=window.getComputedStyle(e.ybarNav),l=parseInt(c.width,10)-parseInt(c.paddingLeft,10)-parseInt(c.paddingRight,10),u=MORE_MENU_WIDTH,d=e.navigationPlacement();if(d)u+=d.getBoundingClientRect().width;for(var p=0;ph&&(p!==e.navItems.length-1||a+f>h||e.moreMenuDropdown&&e.moreMenuDropdown.hasChildNodes()&&moreMenuIndexmoreMenuIndex&&-1!==moreMenuIndex)for(var g=moreMenuIndex;g=r;){var v=e.navItems[y].cloneNode(!0),b=v.querySelector(“a”);b&&(b.setAttribute(“id”,””),b.classList.remove(Css$1.focused));var _=v.querySelector(“.”.concat(e.navigationDropdownListClass));if(_&&(_.style.display=”none”),v.classList.remove(e.dropdownWrapperClass),v.classList.remove(e.ybarNavigationItemClass),v.classList.add(e.navigationDropdownItemClass),e.moreMenuDropdown){e.moreMenuDropdown.insertBefore(v,e.moreMenuDropdown.firstChild);var w=v.getElementsByTagName(“a”)[0];n.unshiftMoreMenuItem(w)}null===(s=e.navItems[y].querySelector(“a”))||void 0===s||s.setAttribute(“tabindex”,”-1″),y–}moreMenuIndex=r}if(-1!==r&&e.navList){var C=parseInt(a.toString(),10)+”px”;e.navList.style.maxWidth=C,t.textContent=”.”.concat(Css$1[“ybar-nav-list-desktop”],”{ max-width: “).concat(C,”}”)}e.moreMenuNavItem&&e.moreMenuDropdown&&e.moreMenuDropdown.hasChildNodes()?(e.moreMenuNavItem.classList.add(e.dropdownWrapperClass),e.moreMenuNavItem.style.visibility=”visible”):null!==e.moreMenuNavItem&&(e.moreMenuNavItem.classList.remove(e.dropdownWrapperClass),e.moreMenuNavItem.style.visibility=”hidden”),e.moreMenuDropdown&&e.moreMenuDropdown.childElementCount>MORE_MENU_LONG_LIST_COUNT?e.moreMenuDropdown.classList.add(e.longListClass):null!==e.moreMenuDropdown&&e.moreMenuDropdown.classList.remove(e.longListClass)}},handleDropdownFocus=function(e,t){var n=delegate_1(“.”.concat(t.dropdownWrapperClass),”focusin”,(function(e){var n=e.delegateTarget;n&&n.classList.contains(t.dropdownWrapperClass)&&n.classList.add(t.dropdownOpenClass)})),i=delegate_1(“.”.concat(t.dropdownWrapperClass,”, .”).concat(t.navigationDropdownListClass),”focusout”,(function(e){var n=e.delegateTarget;if(null==n?void 0:n.classList.contains(t.navigationDropdownListClass)){var i=n.parentElement;i&&!i.contains(e.relatedTarget)&&i.classList.contains(t.dropdownWrapperClass)&&i.classList.remove(t.dropdownOpenClass)}else(null==n?void 0:n.classList.contains(t.dropdownOpenClass))&&n.classList.remove(t.dropdownOpenClass)}));e.onDestroy((function(){var e;n.destroy(),i.destroy(),__spreadArray([],null===(e=t.ybarNav)||void 0===e?void 0:e.querySelectorAll(“.”.concat(t.dropdownOpenClass)),!0).forEach((function(e){e.classList.remove(t.dropdownOpenClass);var n=document.activeElement;nodeContains(t.ybarNav,n)&&setTimeout((function(){null==n||n.blur()}),1)}))}))},setNavigationFocus=function(e,t,n,i){for(var o=t||window.location.pathname,s=n||window.location.hostname,r=(i||{}).setParentFocus,a=void 0!==r&&r,c=__spreadArray([],e.topLevelNavLinks,!0),l=null,u=null,d=0;d0),s=new A11yNavigation(e,{containerElm:t.ybarNav,navlistItemSelector:”.”.concat(Css$1[“ybar-parent-navigation”],” > li”),dropdownClass:t.dropdownWrapperClass,enableMoreMenu:o,moreMenuNavElm:t.moreMenuMainFocusItem});initDropdowns(e,t),showMailUnreadCount(e),e.addElementListener(document,”DOMContentLoaded”,(function(){showMailUnreadCount(e)})),handleDropdownFocus(e,t);var r=e.getConfig().bucketConfig,a=(void 0===r?{}:r).enableDynamicNavfocus;if(void 0!==a&&a&&setNavigationFocus(t),e.addEventListener(“nav:setFocus”,(function(e){var n=e.detail,i=void 0===n?{}:n,o=i.hostname,s=void 0===o?window.location.hostname:o,r=i.pathname,a=void 0===r?window.location.pathname:r,c=i.options;setNavigationFocus(t,a,s,void 0===c?{}:c)})),o){var c=document.createElement(“style”);c.title=”ybar_nav_interim”,document.head.appendChild(c);var l=delegate_1(“#ybar-nav-more-menu ul a”,”click”,(function(t){e.triggerEvent(“navigation”,{event:t})}));e.addEventListener(“nav:resize”,(function(){updateMoreMenu(t,c,s)})),updateMoreMenu(t,c,s),e.addElementListener(window,”load”,(function(){updateMoreMenu(t,c,s)})),e.addElementListener(window,”resize”,(function(){updateMoreMenu(t,c,s)})),e.onDestroy((function(){var e=c.parentNode;null==e||e.removeChild(c),l.destroy()}))}},SELECTOR_MORE_MENU=”#ybar-nav-more-menu”;initModule(“ybar-mod-navigation”,(function(e){var t,n={dropdownWrapperClass:Css$1[“dropdown-wrapper”],isFuji2:null!==document.querySelector(“.ybar-ytheme-fuji2”),isTablet:null!==document.querySelector(“.tablet”),longListClass:Css$1[“long-list”],moreMenuDropdown:document.querySelector(“”.concat(SELECTOR_MORE_MENU,” ul”)),moreMenuNavItem:document.querySelector(SELECTOR_MORE_MENU),moreMenuNavLinksSelector:””.concat(SELECTOR_MORE_MENU,” ul a”),moreMenuMainFocusItem:document.querySelector(“”.concat(SELECTOR_MORE_MENU,’ > span[tabindex=”0″]’)),navigationDropdownItemClass:Css$1[“navigation-dropdown-item”],navigationDropdownListClass:Css$1[“navigation-dropdown-list”],navItems:document.querySelectorAll(“li.”.concat(Css$1[“ybar-navigation-item”])),topLevelNavLinks:document.querySelectorAll(“li.”.concat(Css$1[“ybar-navigation-item”],” > a”)),navLinks:document.querySelectorAll(“.ybar-mod-navigation a”),navList:document.querySelector(“.ybar-mod-navigation ul”),shiftMoreMenuEnabled:document.querySelector(“.ybar-shift-more-menu”),ybarNav:document.getElementById(“ybar-navigation”),ybarNavigationItemClass:Css$1[“ybar-navigation-item”],dropdownOpenClass:Css$1[“dropdown-open”],navigationPlacement:function(){return t||(t=document.getElementById(“ybar-nav-placement”)),t}};init$1(e,n)}));var Css={“notification-container–no-history”:”_yb_1ot6a”,”tooltip-container”:”_yb_19duj”,”tooltip-container–active”:”_yb_1yn7j”,”tooltip-container–open”:”_yb_ffd7a”,”tooltip-container__btn–close”:”_yb_18b9q”,”tooltip-container__inner”:”_yb_1dt1f”},LOCALSTORAGE_KEY=”ytlv”,HOURS_24=864e5,DAYS_7=7*HOURS_24,CLASS_OPEN=Css[“tooltip-container–open”],CLASS_ACTIVE=Css[“tooltip-container–active”],CLASS_BTN_CLOSE=Css[“tooltip-container__btn–close”],CLASS_MENU=Css[“tooltip-container__inner”],MAX_INIT_ATTEMPTS=5,INIT_INTERVAL_MS=100,PromoTooltip=function(){function e(e,t){var n=this;this.initialized=!1,this.ybar=e,this.container=t,this.a11yMenu=this.container.querySelector(“.”.concat(CLASS_MENU)),this.historyEnabled=!!Number(this.container.dataset.history);var i=this.getLocalStorage();this.state={lastSeen:(null==i?void 0:i.lastSeen)||null,manuallyClosed:(null==i?void 0:i.manuallyClosed)||!1},this.init();var o=0,s=setInterval((function(){o>=MAX_INIT_ATTEMPTS||n.initialized?clearInterval(s):(void 0!==n.isNotificationsSupported()&&n.init(),o++)}),INIT_INTERVAL_MS)}return e.prototype.show=function(e){var t;this.initialized&&(this.historyEnabled&&!e||(document.body.classList.add(CLASS_OPEN),null===(t=this.a11yMenu)||void 0===t||t.setAttribute(“aria-expanded”,”true”),this.lastSeen=(new Date).getTime()))},e.prototype.hide=function(){var e;this.initialized&&(this.historyEnabled&&document.body.classList.remove(CLASS_ACTIVE),document.body.classList.remove(CLASS_OPEN),null===(e=this.a11yMenu)||void 0===e||e.setAttribute(“aria-expanded”,”false”))},Object.defineProperty(e.prototype,”lastSeen”,{get:function(){return this.state.lastSeen},set:function(e){this.state.lastSeen=e,this.setLocalStorage()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,”manuallyClosed”,{get:function(){return this.state.manuallyClosed},set:function(e){this.state.manuallyClosed=!!e,this.setLocalStorage()},enumerable:!1,configurable:!0}),e.prototype.init=function(){this.isNotificationsSupported()&&this.isNotificationPermissionDefault()&&(this.historyEnabled||document.body.classList.add(CLASS_ACTIVE),this.addEventListeners(),this.initialized=!0,this.hasSeenTooltipIn(this.manuallyClosed?DAYS_7:HOURS_24)||(document.body.classList.add(CLASS_ACTIVE),this.show(!0)))},e.prototype.addEventListeners=function(){var e=this;this.ybar.addElementListener(this.container.getElementsByClassName(CLASS_BTN_CLOSE)[0],”click”,(function(){e.hide(),e.manuallyClosed=!0}))},e.prototype.isNotificationsSupported=function(){var e;return null===(e=null===window||void 0===window?void 0:window.subscriptionHelperInstance)||void 0===e?void 0:e.checkIsSupportedBrowser()},e.prototype.isNotificationPermissionDefault=function(){var e;return”default”===(null===(e=window.Notification)||void 0===e?void 0:e.permission)},e.prototype.hasSeenTooltipIn=function(e){if(!this.lastSeen)return!1;var t=new Date(this.lastSeen),n=new Date;return t.getTime()+e>n.getTime()},e.prototype.setLocalStorage=function(){var e;null===(e=window.localStorage)||void 0===e||e.setItem(LOCALSTORAGE_KEY,JSON.stringify(this.state))},e.prototype.getLocalStorage=function(){var e,t,n=null===(e=window.localStorage)||void 0===e?void 0:e.getItem(LOCALSTORAGE_KEY);if(null===n)return null;try{return JSON.parse(n)}catch(e){return null===(t=window.localStorage)||void 0===t||t.removeItem(LOCALSTORAGE_KEY),null}},e}(),REFRESH_RATE=3e5,init=function(e,t){var n,i=t.notifMenu,o=t.notifMenuOpener,s=t.notifDropdown,r=t.notifBadge,a=t.notifContainer,c=t.animatedIcon;t.tooltipContainer&&(n=new PromoTooltip(e,t.tooltipContainer));var l=getNotifClient(),u=function(){i&&(i.checked=!1),null==s||s.classList.remove(“ybarMenuOpen”),null==i||i.setAttribute(“aria-expanded”,”false”)},d=function(e){(null==e?void 0:e.newCount)&&e.newCount>0&&r&&(r.style.visibility=”visible”,c&&c.play())},p=function(){l.refreshPanel().then(d).catch((function(){}))};e.addEventListener(“close-all-menus”,(function(){isHovered(a)||u()})),a&&(p(),setInterval((function(){p()}),REFRESH_RATE),a.addEventListener(“mouseenter”,(function(){e.triggerEvent(“close-all-menus”),document.querySelector(“.display-push-promos .”.concat(Css[“notification-container–no-history”]))||(l.resetBadge(),r&&(r.style.visibility=”hidden”)),null==n||n.show()})),a.addEventListener(“mouseleave”,(function(){u(),null==n||n.hide()}))),e.addElementListener(i,”click”,(function(){beaconClick(“ybar”,”notification”,””,{elm:”btn”,elmt:”visible”===(null==r?void 0:r.style.visibility)?”newalert”:””,subsec:”notification”,itc:”1″})})),o&&addHoverEvent(e,o,”ybar”,”notification”,{elm:”expand”,subsec:”notifications”,itc:”2″}),e.addElementListener(s,”focusin”,(function(){i&&(i.checked=!0),null==s||s.classList.add(“ybarMenuOpen”),null==i||i.setAttribute(“aria-expanded”,”true”)})),e.addElementListener(s,”focusout”,u),e.addElementListener(t.tooltipContainer,”focusin”,(function(){null==n||n.show()})),e.addElementListener(t.tooltipContainer,”focusout”,(function(){null==n||n.hide()}))};initModule(“ybar-mod-notification”,(function(e){var t={notifContainer:document.getElementById(“notification-container”),notifBadge:document.getElementById(“notif-badge”),notifMenu:document.getElementById(“ybarNotificationMenu”),notifMenuOpener:document.querySelector(“#ybarNotificationMenu + label”),notifDropdown:document.getElementById(“notifDropdownContainer”),animatedIcon:document.getElementById(“notifBell”),tooltipContainer:document.querySelector(“.”.concat(Css[“tooltip-container”]))};init(e,t)}))})()}};

    Leave a Comment