if (self.CavalryLogger) { CavalryLogger.start_js(["1PshU"]); } __d("MLogoutClearCache",["MCache","Stratcom"],(function(a,b,c,d,e,f){b("Stratcom").listen("click","logout",b("MCache").clear)}),null); __d("KaiOSLoggerEvent",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({IMPRESSION:"impression",UPDATE_APP_VERSION:"update_app_version",PUSH_SUBSCRIPTION_CHANGE:"push_subscription_change",PUSH_SUBSCRIPTION_UPDATE_ERROR:"push_subscription_update_error",CONTACTS_UPLOADED:"contacts_uploaded",CONTACTS_RETRIEVED:"contacts_retrieved",CONTACTS_VALIDATED:"contacts_validated",CONTACTS_FRIENDABLES_FOUND:"contacts_friendables_found",CONTACTS_UPLOAD_TIME:"contacts_upload_time",CONTACTS_TIMEOUT:"contacts_timeout",CONTACTS_EXCEPTION:"contacts_exception",CONTACT_IMPORTER_OPT_IN:"contact_importer_opt_in",CONTACT_IMPORTER_OPT_OUT:"contact_importer_opt_out",CONTACT_IMPORTER_LEARN_MORE_CLICKED:"contact_importer_learn_more_clicked",START_LOADING:"start_loading",ENTER_COMPOSER:"enter_composer",FEED_JEWEL_CLICKED:"feed_jewel_clicked",REQUESTS_JEWEL_CLICKED:"requests_jewel_clicked",MESSAGING_JEWEL_CLICKED:"messaging_jewel_clicked",NOTIFICATION_JEWEL_CLICKED:"notification_jewel_clicked",SEARCH_JEWEL_CLICKED:"search_jewel_clicked",BOOKMARK_JEWEL_CLICKED:"bookmark_jewel_clicked",OTHER_JEWEL_CLICKED:"other_jewel_clicked",SOFTKEY_MENU_BUTTON_CLICKED:"softkey_menu_button_clicked",SOFTKEY_MENU_CLOSE_BUTTON_CLICKED:"softkey_menu_close_button_clicked",SOFTKEY_POST_BUTTON_CLICKED:"softkey_post_button_clicked",SOFTKEY_OTHER_BUTTON_CLICKED:"softkey_other_button_clicked",SOFTKEY_BACK_BUTTON_CLICKED:"softkey_back_button_clicked",SPLASH_SCREEN_GENERATED:"splash_screen_generated",SPLASH_SCREEN_CLEANUP_INITIATED:"splash_screen_cleanup_initiated",SPLASH_SCREEN_CLEANUP_COMPLETED:"splash_screen_cleanup_completed",SPLASH_SCREEN_CLEANUP_TIMEOUT:"splash_screen_cleanup_timeout"})}),null); __d("KaiOSLoggerEventCategory",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({APP_INFO:"app_info",PUSH_SUBSCRIPTION:"push_subscription",CONTACT_IMPORTER:"contact_importer",GALLERY_SHARE:"gallery_share",MENU_BAR:"menu_bar",SOFTKEY_TRAY:"softkey_tray",SPLASH_SCREEN:"splash_screen"})}),null); __d("KaiOSLogger",["BanzaiLogger","KaiOSLoggerEvent","KaiOSLoggerEventCategory"],(function(a,b,c,d,e,f){"use strict";a={logAppVersion:function(a){b("BanzaiLogger").log("KaiOSEventsLoggerConfig",{event:b("KaiOSLoggerEvent").UPDATE_APP_VERSION,event_category:b("KaiOSLoggerEventCategory").APP_INFO,app_version:a})},logWithBanzai:function(a,c,d){b("BanzaiLogger").log("KaiOSEventsLoggerConfig",{event:a,event_category:c,extra_data:d})},logAppMigrationEvent:function(a,c,d,e,f,g){var h=window.navigator.connection||null;b("BanzaiLogger").logImmediately("KaiOSAppMigrationLoggerConfig",babelHelpers["extends"]({event:a,migration_phase:c,experiment_name:f||"unknown",experiment_group:g||"unknown",duration_ms:d?Math.floor(d):0,connection_type:h&&h.type?h.type:"",connection_effective_type:h&&h.effectiveType?h.effectiveType:""},e))}};e.exports=a}),null); __d("SpatialNavControllerTypes",[],(function(a,b,c,d,e,f){"use strict";a=Object.freeze({CONTEXT_STACK:"context_stack",MENU_CONTEXT:"menu_context",NO_CONTEXT:"no_context"});e.exports={SpatialNavContextState:a}}),null); __d("KaiOSSpatialNavTraverserKind",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({LINEAR:"linear",HIERARCHICAL:"hierarchical",HORIZONTAL:"horizontal"})}),null); __d("SpatialNavDirection",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({UP:"up",DOWN:"down",LEFT:"left",RIGHT:"right"})}),null); __d("SpatialNavMutationSpecTypes",[],(function(a,b,c,d,e,f){"use strict";a=Object.freeze({PUSH_CONTEXT:"push_context",POP_CONTEXT:"pop_context",MOVE_TO_NODE:"move_to_node",INTERACT_WITH_NODE:"interact_with_node",REBUILD_TREE:"rebuild_tree",BUILD_MENU:"build_menu",HIGHLIGHT_NODE:"highlight_node",SWITCH_CONTEXT:"switch_context",CLEAR_CONTEXT:"clear_context",REMOVE_CONTEXT:"remove_context",REBUILD_PARTIAL_TREE:"rebuild_partial_tree"});e.exports=a}),null); __d("SpatialNavigationAttribute",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({PRIMARY_ELEMENT:"data-kaios-spatial-navigation",FOCUS_TRANSPARENT:"data-kaios-focus-transparent",STYLE_PARENT_INSTEAD:"data-kaios-style-parent-instead",STYLE_PARENT_HTML:"data-kaios-style-parent-html",STYLE_CHILD_HTML:"data-kaios-style-child-html",CLICK_THROUGH:"data-kaios-click-through",NO_CLICK_THROUGH:"data-kaios-no-click-through",BLACKLIST_ELEMENT:"data-kaios-blacklist-nav",WHITELIST_ELEMENT:"data-kaios-whitelist-nav",SCROLL_PARENT:"data-kaios-scroll-parent",SWALLOW_CLICK:"data-kaios-swallow-click",FILE_UPLOAD_ELEMENT:"data-kaios-file-upload-element",FOCUS_ON_HIGHLIGHT_ELEMENT:"data-kaios-focus-on-highlight"})}),null); __d("SpatialNavTreeNodeUtils",["cx","CSS","MViewport","SpatialNavigationAttribute","Vector"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();var h={isPrimaryNode:function(a){return a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").PRIMARY_ELEMENT)},isFocusTransparent:function(a){return a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").FOCUS_TRANSPARENT)},shouldPreventClickThrough:function(a){return a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").NO_CLICK_THROUGH)},shouldSwallowClick:function(a){return a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").SWALLOW_CLICK)},isPrimaryOverrideChild:function(a){var b=a.getParent();return b!=null&&b.getPrimaryChildOverride()===a},shouldStylePrimaryInstead:function(a){return!h.isPrimaryNode(a)&&a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").STYLE_PARENT_INSTEAD)},shouldStyleParentHTML:function(a){return!h.isPrimaryNode(a)&&a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").STYLE_PARENT_HTML)},shouldStyleChildHTML:function(a){return!h.isPrimaryNode(a)&&a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").STYLE_CHILD_HTML)},shouldClickChildInstead:function(a){return!h.isPrimaryNode(a)&&a.getHTMLElement().hasAttribute(b("SpatialNavigationAttribute").CLICK_THROUGH)},getFirstHighlightableNode:function(a){a=a.getFirstChild();while(a!=null&&h.isFocusTransparent(a))a=a.getFirstChild();return a},getLastHighlightableNode:function(a){a=a.getLastChild();while(a!=null&&h.isFocusTransparent(a))a=a.getLastChild();return a},getFirstHighlightableNodeInViewport:function(a){__p&&__p();var c=[],d=a.getChildren();for(var e=d.length-1;e>=0;e--)c.push(d[e]);while(c.length!==0){d=c.pop();e=d.getHTMLElement();var f=b("Vector").getPos(e).y,g=b("MViewport").getScrollTop();if(!h.isFocusTransparent(d)&&f-g>0)return d;else if(f+e.clientHeight>g){f=d.getChildren();for(var e=f.length-1;e>=0;e--)c.push(f[e])}}return this.getFirstHighlightableNode(a)},getPrevNode:function(a){__p&&__p();var b=a.getLeftSibling();if(b!=null){b=b;var c=b.getLastChild();while(c!=null)b=c,c=c.getLastChild();return b}c=a.getParent();return c!=null&&c.getParent()!=null?c:null},getNextNode:function(a){__p&&__p();var b=a.getFirstChild();if(b!=null)return b;b=a.getRightSibling();if(b!=null)return b;b=a.getParent();while(b!=null){a=b.getRightSibling();if(a!=null)return a;b=b.getParent()}return null},getPrevNodeFiltered:function(a,b){a=h.getPrevNode(a);while(a!=null){if(b(a))return a;a=h.getPrevNode(a)}return null},getNextNodeFiltered:function(a,b){a=h.getNextNode(a);while(a!=null){if(b(a))return a;a=h.getNextNode(a)}return null},getRootNode:function(a){var b=a;a=a.getParent();while(a!=null)b=a,a=b.getParent();return b},findNodeForElement:function(a,b){__p&&__p();b=[b];var c;while(b.length!==0){c=b.pop();if(c.getHTMLElement()===a)return c;c=c.getChildren();for(var d=0;d=b.length)break;e=b[d++]}else{d=b.next();if(d.done)break;e=d.value}e=e;var f=e.getHTMLElement();if(f===a||f.compareDocumentPosition(a)&(Node.DOCUMENT_POSITION_CONTAINS|Node.DOCUMENT_POSITION_CONTAINED_BY))return e}return null},getStyledHTMLElement:function(a){__p&&__p();var b=a.getHTMLElement(),c=a.getParent();if(h.shouldStylePrimaryInstead(a)&&c!=null)b=c.getHTMLElement();else if(h.shouldStyleParentHTML(a)){c=a.getHTMLElement().parentElement;c!=null&&(b=c)}else if(h.shouldStyleChildHTML(a)&&a.getHTMLElement().children.length>0){c=a.getHTMLElement().children[0];c!=null&&(b=c)}return b}};e.exports=h}),null); __d("TraverserUtils",["SpatialNavMutationSpecTypes"],(function(a,b,c,d,e,f){"use strict";function a(a,c){return[{mutationType:b("SpatialNavMutationSpecTypes").MOVE_TO_NODE,currentNode:a,nextNode:c}]}e.exports={getSingleMoveToNodeMutation:a}}),null); __d("HierarchicalTraverser",["invariant","KaiOSSpatialNavTraverserKind","SpatialNavDirection","SpatialNavMutationSpecTypes","SpatialNavTreeNodeUtils","TraverserUtils"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();var h=b("TraverserUtils").getSingleMoveToNodeMutation;function i(a,c){if(c==null)return[];if(b("SpatialNavTreeNodeUtils").isFocusTransparent(c)){var d;d=(d=c.getPrimaryChildOverride())!=null?d:c.getFirstChild();d!=null||g(0,2529);return h(a,d)}return h(a,c)}function j(a,c){__p&&__p();var d=a.getLeftSibling();if(d!=null)return i(a,d);d=a.getEnforceParent();if(b("SpatialNavTreeNodeUtils").isFocusTransparent(d)){var e=d.getLeftSibling();if(e!=null&&!l(a,c)){c=(c=e.getPrimaryChildOverride())!=null?c:e.getLastChild();c!=null||g(0,2529);return h(a,c)}return i(a,d.getLeftSibling())}return h(a,d)}function k(a,b){var c=a.getRightSibling(),d=a.getEnforceParent();return c!=null&&!l(a,b)?h(a,c):i(a,d.getRightSibling())}function l(a,c){var d=a.getEnforceParent(),e=a.getLeftSibling();return(c===b("SpatialNavDirection").DOWN||c===b("SpatialNavDirection").UP)&&b("SpatialNavTreeNodeUtils").isFocusTransparent(d)&&e==null&&b("SpatialNavTreeNodeUtils").getRootNode(a)!=d}a={traverserName:b("KaiOSSpatialNavTraverserKind").HIERARCHICAL,onLeft:function(a){a=a.currentNode;if(b("SpatialNavTreeNodeUtils").isPrimaryNode(a)){var c,d=a.getLeftSibling();if(d==null)return[];c=(c=(c=d.getPrimaryChildOverride())!=null?c:d.getLastChild())!=null?c:d;return h(a,c)}return j(a,b("SpatialNavDirection").LEFT)},onRight:function(a){a=a.currentNode;if(b("SpatialNavTreeNodeUtils").isPrimaryNode(a)){var c;c=(c=a.getPrimaryChildOverride())!=null?c:a.getFirstChild();return c==null?i(a,a.getRightSibling()):h(a,c)}return k(a,b("SpatialNavDirection").RIGHT)},onUp:function(a){__p&&__p();var c=a.currentNode,d=a.config.wrapAround;a=function(a){if(a.length>0||d!==!0)return a;a=b("SpatialNavTreeNodeUtils").getLastHighlightableNode(b("SpatialNavTreeNodeUtils").getRootNode(c));return a==null?[]:h(c,a)};if(b("SpatialNavTreeNodeUtils").isPrimaryNode(c))return a(i(c,c.getLeftSibling()));if(b("SpatialNavTreeNodeUtils").isPrimaryOverrideChild(c)){var e=c.getEnforceParent();return a(i(c,e.getLeftSibling()))}return a(j(c,b("SpatialNavDirection").UP))},onDown:function(a){__p&&__p();var c=a.currentNode,d=a.config.wrapAround;a=function(a){if(a.length>0||d!==!0)return a;a=b("SpatialNavTreeNodeUtils").getFirstHighlightableNode(b("SpatialNavTreeNodeUtils").getRootNode(c));return a==null?[]:h(c,a)};if(b("SpatialNavTreeNodeUtils").isPrimaryNode(c))return a(i(c,c.getRightSibling()));if(b("SpatialNavTreeNodeUtils").isPrimaryOverrideChild(c)){var e=c.getEnforceParent();return a(i(c,e.getRightSibling()))}return a(k(c,b("SpatialNavDirection").DOWN))},onCenterSoftKey:function(a){__p&&__p();a=a.currentNode;if(b("SpatialNavTreeNodeUtils").shouldSwallowClick(a))return[];var c=a.getChildren();if(c.length===0)return[{mutationType:b("SpatialNavMutationSpecTypes").INTERACT_WITH_NODE,node:a}];if(c.length===1&&!b("SpatialNavTreeNodeUtils").shouldPreventClickThrough(a))return[{mutationType:b("SpatialNavMutationSpecTypes").INTERACT_WITH_NODE,node:c[0]}];c=(c=a.getPrimaryChildOverride())!=null?c:a.getFirstChild();c!=null||g(0,2529);return h(a,c)}};e.exports=a}),null); __d("HorizontalTraverser",["KaiOSSpatialNavTraverserKind","SpatialNavMutationSpecTypes"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function g(a){a.config.optionalCallback&&a.config.optionalCallback()}a={traverserName:b("KaiOSSpatialNavTraverserKind").HORIZONTAL,onLeft:function(a){__p&&__p();var c=a.currentNode,d=c.getLeftSibling();if(d!=null)return[{mutationType:b("SpatialNavMutationSpecTypes").MOVE_TO_NODE,currentNode:c,nextNode:d}];if(a.config.wrapAround!==!0)return[];a=c.getParent();if(a==null)return[];d=a.getLastChild();return d==null?[]:[{mutationType:b("SpatialNavMutationSpecTypes").MOVE_TO_NODE,currentNode:c,nextNode:d}]},onUp:function(a){g(a);return[]},onRight:function(a){__p&&__p();var c=a.currentNode,d=c.getRightSibling();if(d!=null)return[{mutationType:b("SpatialNavMutationSpecTypes").MOVE_TO_NODE,currentNode:c,nextNode:d}];if(a.config.wrapAround!==!0)return[];a=c.getParent();if(a==null)return[];d=a.getFirstChild();return d==null?[]:[{mutationType:b("SpatialNavMutationSpecTypes").MOVE_TO_NODE,currentNode:c,nextNode:d}]},onDown:function(a){g(a);return[]},onCenterSoftKey:function(a){return[{mutationType:b("SpatialNavMutationSpecTypes").INTERACT_WITH_NODE,node:a.currentNode}]}};e.exports=a}),null); __d("KaiOSSpatialNavEvents",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({REFRESH:"m:kaios:spatialnav:refresh",NAVIGATE:"m:kaios:spatialnav:navigate",INIT_COMPLETE:"m:kaios:spatialnav:init_complete",RESTORE_TRAY:"m:kaios:spatialav:restore_tray",UPDATE_TRAY:"m:kaios:spatialnav:update_tray",HIDE_TRAY:"m:kaios:spatialnav:hide_tray",SHOW_TRAY:"m:kaios:spatialnav:show_tray"})}),null); __d("KaiOSSpatialNavPath",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({NONE:0,BOTTOM_SHEET:1,CONTACT_IMPORTER:2,CONFIRMATION:3,FRIENDS_TAB:4,LIKE_REACTION_FLYOUT:5,LOGIN_PAGE:6,MENU:7,MOVERLAY:8,NEWSFEED:9,NOTIFICATION:10,NUX_FRIENDS_SUGGESTION:11,PHOTO:12,PLAYGROUND:13,PLAYGROUND_VISIBILITY:14,REGISTRATION:15,STORY:16,TEST:17,NUX_PROFILE_PIC_PAGE:18,SAVE_DEVICE_PAGE:19,ACCOUNT_SWITCHER:20})}),null); __d("LinearTraverser",["KaiOSSpatialNavTraverserKind","SpatialNavMutationSpecTypes","TraverserUtils"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("TraverserUtils").getSingleMoveToNodeMutation;function h(a){var b;a=a.getLeftSibling();return a==null?null:(b=a.getLastChild())!=null?b:a}function i(a){var b;a=a.getRightSibling();return a==null?null:(b=a.getFirstChild())!=null?b:a}var j={traverserName:b("KaiOSSpatialNavTraverserKind").LINEAR,onLeft:function(a){a=a.currentNode;var b=h(a);if(b!=null)return g(a,b);b=a.getParent();if(b==null||b.getParent()==null)return[];b=h(b);return b==null?[]:g(a,b)},onUp:function(a){return j.onLeft(a)},onRight:function(a){a=a.currentNode;var b=i(a);if(b!=null)return g(a,b);b=a.getParent();if(b==null||b.getParent()==null)return[];b=i(b);return b==null?[]:g(a,b)},onDown:function(a){return j.onRight(a)},onCenterSoftKey:function(a){return[{mutationType:b("SpatialNavMutationSpecTypes").INTERACT_WITH_NODE,node:a.currentNode}]}};e.exports=j}),null); __d("SpatialNavControllerUtils",["cx","fbt","CSS","HierarchicalTraverser","HorizontalTraverser","KaiOSSpatialNavEvents","KaiOSSpatialNavPath","KaiOSSpatialNavTraverserKind","LinearTraverser","SpatialNavControllerTypes","qex"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("SpatialNavControllerTypes").SpatialNavContextState;a={getContextFromState:function(a,b){if(b!=null)return this._getContextFromStateImpl(a,b);else return this._getContextFromStateImpl(a,a.contextState)},getStackContextFromState:function(a){a=a.contextStack;return a.length!==0?a[a.length-1]:null},_getContextFromStateImpl:function(a,b){if(b===i.MENU_CONTEXT&&a.menuContext!=null)return a.menuContext;return b===i.CONTEXT_STACK?this.getStackContextFromState(a):null},shouldInterceptBackKey:function(a){return a.target&&a.target instanceof HTMLElement&&b("CSS").hasClass(a.target,"_777b")?!0:!1},isBottomSheetFlyout:function(a){return a.config.contextSigil==="share-popup"||a.config.contextSigil==="story-popup-context-init"||a.config.contextSigil==="story-popup-context"},getTraverserFromType:function(a){switch(a){case b("KaiOSSpatialNavTraverserKind").LINEAR:return b("LinearTraverser");case b("KaiOSSpatialNavTraverserKind").HORIZONTAL:return b("HorizontalTraverser");case b("KaiOSSpatialNavTraverserKind").HIERARCHICAL:default:return b("HierarchicalTraverser")}},updateSoftkeyTray:function(a){a=new CustomEvent(b("KaiOSSpatialNavEvents").UPDATE_TRAY,a);window.dispatchEvent(a)},updateCenterSoftkey:function(a,c){__p&&__p();a=a.contextStack[0].config.pathType;if(a===b("KaiOSSpatialNavPath").FRIENDS_TAB&&b("qex")._("816772"))if(c===i.CONTEXT_STACK){a=h._("Select");a={detail:{centerButtonText:a}};this.updateSoftkeyTray(a)}else if(c===i.MENU_CONTEXT){a={detail:{centerButtonText:""}};this.updateSoftkeyTray(a)}}};e.exports=a}),null); __d("KaiOSHTMLElementUtils",["EventListener","Keys","SpatialNavigationAttribute"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=["email","number","password","search","tel","text","url"];function h(a){__p&&__p();var b=a.tabIndex;if(parseInt(b,10)<0)return!1;if(b>0||b===0&&a.getAttribute("tabIndex")!==null)return!0;if(a instanceof HTMLAnchorElement)return!!a.href&&a.rel!="ignore";else if(a instanceof HTMLInputElement)return a.type!="hidden"&&a.type!="file"&&!a.disabled;else if(a instanceof HTMLButtonElement||a instanceof HTMLSelectElement||a instanceof HTMLTextAreaElement)return!a.disabled;return!1}var i={isTextfieldInput:function(a){return a instanceof HTMLTextAreaElement||a instanceof HTMLInputElement&&(g.includes(a.type)||a.type==="")},isLink:function(a){return a.tagName==="A"},isNTElement:function(a){return a.hasAttribute("data-nt")},isFileUploadElement:function(a){return a.hasAttribute(b("SpatialNavigationAttribute").FILE_UPLOAD_ELEMENT)},isSpatialNavElement:function(a){return(a.hasAttribute(b("SpatialNavigationAttribute").PRIMARY_ELEMENT)||a.hasAttribute(b("SpatialNavigationAttribute").WHITELIST_ELEMENT)||h(a))&&!a.hasAttribute(b("SpatialNavigationAttribute").BLACKLIST_ELEMENT)&&i.isVisible(a)},isVisible:function(a){return(a.offsetHeight!==0&&a.offsetWidth!==0||a.offsetParent!==null)&&window.getComputedStyle(a).visibility!=="hidden"},getFirstLink:function(a){__p&&__p();for(var b=0;bf+e-l&&(ee+d-g&&(da},scrollDownInTheSameNodeBySmallIncrement:function(){b("MViewport").scrollBy(0,i)},isVScrollParent:function(a){a=window.getComputedStyle(a);return a.overflow==="auto"||a.overflow==="scroll"||a.overflowY==="auto"||a.overflowY==="scroll"},isHScrollParent:function(a){a=window.getComputedStyle(a);return a.overflow==="auto"||a.overflow==="scroll"||a.overflowX==="auto"||a.overflowX==="scroll"}};e.exports=a}),null); __d("MutationUtils",["cx","DataStore","KaiOSHTMLElementUtils","SpatialNavControllerTypes","SpatialNavControllerUtils","SpatialNavigationAttribute","SpatialNavScrollUtils","SpatialNavTreeNodeUtils"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();var h=b("SpatialNavControllerTypes").SpatialNavContextState;function i(a){return b("KaiOSHTMLElementUtils").isTextfieldInput(a)||b("KaiOSHTMLElementUtils").isLink(a)||b("KaiOSHTMLElementUtils").isNTElement(a)||b("KaiOSHTMLElementUtils").isFileUploadElement(a)||a.hasAttribute(b("SpatialNavigationAttribute").FOCUS_ON_HIGHLIGHT_ELEMENT)}var j={SPATIAL_NAV_ELEMENT_FOCUS_KEY:"spatial_nav_element_focus_key",maybeFocusNode:function(a){a=a.getHTMLElement();i(a)&&j.focusAndTagElement(a)},focusAndTagElement:function(a){b("DataStore").set(a,j.SPATIAL_NAV_ELEMENT_FOCUS_KEY,!0),a.focus()},unhighlightNode:function(a){var c=b("SpatialNavTreeNodeUtils").getStyledHTMLElement(a);c.classList.remove("_6-_f");b("SpatialNavTreeNodeUtils").isPrimaryNode(a)&&!b("SpatialNavTreeNodeUtils").isFocusTransparent(a)&&c.classList.remove("_79wz")},unhighlightStackContext:function(a){a=b("SpatialNavControllerUtils").getStackContextFromState(a);if(a==null)return;a=a.currentNode;a.getHTMLElement().blur();j.unhighlightNode(a)},highlightNode:function(a){var c=b("SpatialNavTreeNodeUtils").getStyledHTMLElement(a);c.classList.add("_6-_f");b("SpatialNavTreeNodeUtils").isPrimaryNode(a)&&!b("SpatialNavTreeNodeUtils").isFocusTransparent(a)&&c.classList.add("_79wz")},moveToNewNode:function(a,c,d){b("SpatialNavScrollUtils").scrollToNodeIfNecessary(c,d);d=a.getHTMLElement();d!==c.getHTMLElement()&&(a.getHTMLElement().blur(),j.maybeFocusNode(c),j.unhighlightNode(a),j.highlightNode(c))},getNewControllerState:function(a,c){__p&&__p();if(a.contextState===h.MENU_CONTEXT&&a.menuContext!=null){var d={traverser:a.menuContext.traverser,currentNode:c,config:a.menuContext.config,mutationObserver:a.menuContext.mutationObserver};return{contextStack:a.contextStack,menuContext:d,contextState:a.contextState}}d=b("SpatialNavControllerUtils").getStackContextFromState(a);if(d==null)return a;c={traverser:d.traverser,currentNode:c,config:d.config,mutationObserver:d.mutationObserver};d=[].concat(a.contextStack);d.splice(-1,1,c);return{contextStack:d,menuContext:a.menuContext,contextState:a.contextState}}};e.exports=j}),null); __d("HierarchicalTreeOptimizer",["SpatialNavTreeNodeUtils"],(function(a,b,c,d,e,f){"use strict";a={validateTreeStructure:function(a){a=b("SpatialNavTreeNodeUtils").getRootNode(a);var c=a.getChildren();c.forEach(function(a,b){a.hasChildren()||c.splice(b,1)})}};e.exports=a}),null); __d("SpatialNavTreeNode",["invariant"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(){__p&&__p();function a(a){this.$1=a,this.$2=[],this.$3=null}var b=a.prototype;b.getHTMLElement=function(){return this.$1};b.addChild=function(a){this.$2.push(a),a.setParent(this)};b.getChildren=function(){return this.$2};b.removeChild=function(a){a=this.$2.indexOf(a);a!==-1&&this.$2.splice(a,1)};b.insertChildren=function(a,b){var c;(c=this.$2).splice.apply(c,[a,0].concat(b))};b.setParent=function(a){this.$3=a};b.getParent=function(){return this.$3};b.getEnforceParent=function(){this.$3!=null||g(0,12374);return this.$3};b.hasChildren=function(){return this.$2.length!==0};b.setVScrollParent=function(a){this.$4=a};b.getVScrollParent=function(){return this.$4};b.setHScrollParent=function(a){this.$5=a};b.getHScrollParent=function(){return this.$5};b.setPrimaryChildOverride=function(a){this.$6=a};b.getPrimaryChildOverride=function(){return this.$6};b.getLeftSibling=function(){if(this.$3==null)return null;var a=this.$3.getChildren(),b=a.indexOf(this);return b===-1||b===0?null:a[b-1]};b.getRightSibling=function(){if(this.$3==null)return null;var a=this.$3.getChildren(),b=a.indexOf(this);return b===-1||b===a.length-1?null:a[b+1]};b.getFirstChild=function(){return this.$2.length===0?null:this.$2[0]};b.getLastChild=function(){return this.$2.length===0?null:this.$2[this.$2.length-1]};return a}();e.exports=a}),null); __d("SpatialNavTreeBuilder",["Event","KaiOSHTMLElementUtils","SpatialNavigationAttribute","SpatialNavScrollUtils","SpatialNavTreeNode","SpatialNavTreeNodeUtils"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={buildSpatialNavTree:function(a,c,d){__p&&__p();var e=new(b("SpatialNavTreeNode"))(a);d=a.hasAttribute(b("SpatialNavigationAttribute").SCROLL_PARENT)&&b("SpatialNavScrollUtils").isVScrollParent(a)?a:d;c=a.hasAttribute(b("SpatialNavigationAttribute").SCROLL_PARENT)&&b("SpatialNavScrollUtils").isHScrollParent(a)?a:c;var f=[{element:a,parentNode:e,vScrollParent:d,hScrollParent:c}],g=new Set(),h,i,j,k=function(){__p&&__p();a=f.pop();var e=a.element;d=a.parentNode;c=a.vScrollParent;j=a.hScrollParent;if(e.hasAttribute(b("SpatialNavigationAttribute").BLACKLIST_ELEMENT))return"continue";i=b("KaiOSHTMLElementUtils").isSpatialNavElement(e)?new(b("SpatialNavTreeNode"))(e):null;i!=null&&(b("SpatialNavTreeNodeUtils").isPrimaryNode(i)&&b("SpatialNavTreeNodeUtils").isPrimaryNode(d)&&g.add(d),i.setParent(d),d.addChild(i),d=i,c!=null&&i.setVScrollParent(c),j!=null&&i.setHScrollParent(j),e.hasAttribute(b("SpatialNavigationAttribute").FILE_UPLOAD_ELEMENT)&&b("Event").listen(e,"keypress",function(a){a.key==="Enter"&&e.click()}));e.hasAttribute(b("SpatialNavigationAttribute").SCROLL_PARENT)&&(c=b("SpatialNavScrollUtils").isVScrollParent(e)?e:c,j=b("SpatialNavScrollUtils").isHScrollParent(e)?e:j);if(i!=null&&!b("SpatialNavTreeNodeUtils").isPrimaryNode(i))return"continue";h=e.children;for(var k=e.childElementCount-1;k>=0;k--)f.push({element:h[k],parentNode:d,vScrollParent:c,hScrollParent:j})};while(f.length!==0){var l=k();if(l==="continue")continue}g.forEach(function(a){__p&&__p();var b=a.getParent();if(b==null)return;var c=b.getChildren().indexOf(a);if(c===-1)return;var d=a.getChildren();for(var e=0;e0&&b("Scroll").getTop(c)>=e?a.prevent():a.stop()}};d.$MOverlay6=function(a){this.$MOverlay1=a.getTouch().clientY};d.$MOverlay7=function(a){this.$MOverlay1=null};d.onScroll=function(a){clearTimeout(this.$MOverlay11),this.$MOverlay11=b("setTimeoutAcrossTransitions")(this.updatePosition.bind(this),100)};d.onResize=function(a){clearTimeout(this.$MOverlay12),this.$MOverlay12=b("setTimeoutAcrossTransitions")(this.updatePosition.bind(this),100)};d.onFocus=function(a){this.$MOverlay10=!0};d.onBlur=function(a){this.$MOverlay10=!1,this.updatePosition(),this.$MOverlay8=b("setTimeoutAcrossTransitions")(this.updatePosition.bind(this),1e3)};d.getUpdatePositionBlocked=function(){return this.$MOverlay10};d.getInsertParent=function(){var c=this.insertParent;c||(c=b("ge")("page"));return c||a.prototype.getInsertParent.call(this)};return c}(b("MLayer"));e.exports=a}),null); __d("ServiceWorkerLoginAndLogout",["ClientServiceWorkerMessage"],(function(a,b,c,d,e,f){function g(a){new(b("ClientServiceWorkerMessage"))(a,null).sendViaController()}a={login:function(){g("login")},logout:function(){g("logout")}};e.exports=a}),null); __d("XBrowserPushDisabledController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/notifications/client/push/disabled/",{})}),null); __d("ServiceWorkerLoginAndLogoutListener",["KaiOSController","MobileAppDetect","MRequest","PushRegistration","ServiceWorkerLoginAndLogout","Stratcom","XBrowserPushDisabledController","killswitch"],(function(a,b,c,d,e,f){__p&&__p();a={listen:function(a,c,d,e){__p&&__p();b("Stratcom").listen("click",a,function(){__p&&__p();if(b("MobileAppDetect").is_kaios){if(!e)return;if(b("killswitch")("NOTIFICATIONS_LOGGED_OUT_PUSH_KAIOS_TOKEN_HANDLING")){var a=b("PushRegistration").get(d,e);a.unregisterPushAndSWOnKaiOS(b("XBrowserPushDisabledController"),b("MRequest"),b("KaiOSController"),!1)}}else if(c==="login")b("ServiceWorkerLoginAndLogout").login();else if(c==="logout")b("ServiceWorkerLoginAndLogout").logout();else throw new Error("bad login type given")})}};e.exports=a}),null);