if (self.CavalryLogger) { CavalryLogger.start_js(["hOhRn"]); } __d('LegacyMentionsInput.react',['cx','FocusListener','Bootloader','TypeaheadMetricsConfig','Event','Keys','React','ReactDOM'],(function a(b,c,d,e,f,g,h){var i,j;if(c.__markCompiled)c.__markCompiled();c('FocusListener');var k=c('React').PropTypes;i=babelHelpers.inherits(l,c('React').Component);j=i&&i.prototype;function l(){var m,n;'use strict';for(var o=arguments.length,p=Array(o),q=0;q0)if(this._isBottomOfColumnVisible()){this._setFixedToBottom();return;}if(this._scrollDelta<0)if(this._isTopOfColumnVisible()){this._setFixedToTop();return;}var n=this._getTopPositionForRef('column'),o=this._getTopPositionForRef('container'),p=n-o;this._setNotFixed(p);},_getTopPositionForRef:function m(n){var o=this.refs[n];!o?i(0):void 0;var p=c('Vector').getElementPosition(c('ReactDOM').findDOMNode(o),'viewport').y;if(this._scroll<0)p+=this._scroll;return p;},_getTopBoundWithOffset:function m(){return c('ViewportBounds').getTop()+this.props.topOffset;},_isContainerBelowViewportTop:function m(){var n=this._getTopPositionForRef('container');return n>=this._getTopBoundWithOffset();},_isColumnLargerThanViewport:function m(){var n=c('Vector').getViewportDimensions().y-c('ViewportBounds').getBottom()-this._getTopBoundWithOffset();return c('ReactDOM').findDOMNode(this.refs.column).offsetHeight>n;},_isBottomOfColumnVisible:function m(){var n=this._getTopPositionForRef('column'),o=c('Vector').getElementDimensions(c('ReactDOM').findDOMNode(this.refs.column),'viewport').y,p=n+o;return p<=c('Vector').getViewportDimensions().y-c('ViewportBounds').getBottom();},_isTopOfColumnVisible:function m(){var n=this._getTopPositionForRef('column');return n>=this._getTopBoundWithOffset();},_getFixedLeft:function m(){return (c('Vector').getElementPosition(c('ReactDOM').findDOMNode(this.refs.container),'viewport').x);},_setFixedToBottom:function m(){this.setState({fixed:'bottom',fixedBottom:c('ViewportBounds').getBottom(),fixedLeft:this._getFixedLeft()});},_setFixedToTop:function m(){this.setState({fixed:'top',fixedLeft:this._getFixedLeft(),fixedTop:this._getTopBoundWithOffset()});},_setNotFixed:function m(n){this.setState({fixed:false,top:n});},_updateContainerHeight:function m(){c('ReactDOM').findDOMNode(this.refs.container).style.height=c('ReactDOM').findDOMNode(this.refs.column).offsetHeight+this.state.top+'px';},_updateColumnWidth:function m(){c('ReactDOM').findDOMNode(this.refs.column).style.width=c('ReactDOM').findDOMNode(this.refs.container).offsetWidth+'px';}});l.EVENT_SHOULD_ADJUST=k;f.exports=l;}),null); __d('StickyArea',['cx','CSS','DOM','DOMQuery','Event','Run','Style','ViewportBounds','getNormalizedClientRect','getOverlayZIndex','removeFromArray','throttle'],(function a(b,c,d,e,f,g,h){if(c.__markCompiled)c.__markCompiled();var i=[],j=null,k=null,l=c('throttle').acrossTransitions(o,1000),m='$$StickyArea_scrollListener',n='$$StickyArea_scrollListenerCount';function o(){i.sort(function(u,v){var w=u.getNode(),x=v.getNode();if(w.compareDocumentPosition){return 3-(w.compareDocumentPosition(x)&6);}else return w.sourceIndex-x.sourceIndex;});}function p(u,v,w){var x=u.getPlaceholder(),y=u.getNode(),z=c('Style').get(y,'float'),aa=u.getData();if(aa.placeholderWidth!==v||aa.placeholderHeight!==w||aa.placeholderFloat!==z){c('Style').apply(x,{'float':z,height:w+'px',width:v+'px'});aa.placeholderHeight=w;aa.placeholderWidth=v;}if(y.nextSibling!==x)c('DOM').insertAfter(y,x);}function q(u,v){var w=u.getData();if(w.fixed!==v){c('Style').apply(u.getNode(),w.styles);c('CSS').conditionShow(u.getPlaceholder(),v);c('CSS').conditionClass(u.getNode(),"_1a1e",v);c('Event').fire(u.getNode(),'change');w.fixed=v;}}function r(u,v){if(!u){return 0;}else if(v.right<=u.rect.left||v.left>=u.rect.right){return r(u.prev,v);}else return u.bottom;}function s(){var u=0,v=i.length,w=100,x=null;function y(z,aa){var ba=w;while(una+ja||!ca.getIsBoundToContainer()){var ra=parseInt(c('Style').get(da,'margin-left'),10);ha.position='fixed';ha.bottom='auto';ha.top=na+la+'px';ha.left=ma.left-ra+'px';}else{if(!fa.parent||ga!==fa.parent){if(c('Style').get(ga,'position')==='static')c('Style').set(ga,'position','relative');fa.parent=ga;}ha.position='absolute';ha.top='auto';ha.bottom=pa+'px';var sa=parseInt(c('Style').get(ga,'border-left-width'),10);ha.left=ma.left-qa.left-sa+'px';}p(ca,ka,ja);q(ca,true);}u++;var ta={bottom:na+ja,prev:z,rect:ma},ua=0;if(!ca.getIsBoundToContainer()){x=ta;ua=100;}y(ta,ga);c('Style').set(da,'z-index',w+++ua);}}y(null,null);}function t(u,v,w){var x=arguments.length<=3||arguments[3]===undefined?{}:arguments[3];'use strict';this._isDestroyed=false;this._node=u;this._data={fixed:false,placeholderFloat:null,placeholderHeight:null,placeholderWidth:null,styles:{}};this._offset=w;this._boundToContainer=x.boundToContainer!==false;if(x.stickTo===t.stickTo.SCROLL_PARENT){this._scrollTarget=c('Style').getScrollParent(u.parentNode)||window;}else this._scrollTarget=window;c('CSS').addClass(u,"_k");if(!v)c('Run').onLeave(this.destroy.bind(this));if(!this._scrollTarget[m]){this._scrollTarget[m]=c('Event').listen(this._scrollTarget,'scroll',function(){l();s();});this._scrollTarget[n]=1;}else this._scrollTarget[n]++;if(!i.length){j=c('Event').listen(window,'resize',function(){l();s();});k=c('ViewportBounds').subscribe('change',function(){l();s();});}i.push(this);t.reflow();}t.prototype.destroy=function(){'use strict';if(this._isDestroyed)return;c('removeFromArray')(i,this);this._scrollTarget[n]--;if(this._scrollTarget[n]===0){this._scrollTarget[m].remove();this._scrollTarget[m]=null;}if(!i.length){j.remove();j=null;k.unsubscribe();k=null;}if(this._placeholder)c('DOM').remove(this._placeholder);var u=0;for(var v in this._data.styles){this._data.styles[v]='';u++;}if(u)c('Style').apply(this._node,this._data.styles);this._isDestroyed=true;};t.prototype.getData=function(){'use strict';return this._data;};t.prototype.getNode=function(){'use strict';return this._node;};t.prototype.getOffset=function(){'use strict';return this._offset||0;};t.prototype.getPlaceholder=function(){'use strict';if(!this._placeholder)this._placeholder=c('DOM').create('div');return this._placeholder;};t.prototype.getIsBoundToContainer=function(){'use strict';return this._boundToContainer;};t.prototype.getZIndex=function(){'use strict';if(!this._zIndex)this._zIndex=c('getOverlayZIndex')(this._node);return this._zIndex;};t.prototype.setOffset=function(u){'use strict';this._offset=u;};t.reflow=c('throttle').acrossTransitions(function(){o();s();},100);t.stickTo={SCROLL_PARENT:'SCROLL_PARENT',WINDOW:'WINDOW'};f.exports=t;}),null); __d('StickyArea.react',['cx','React','ReactDOM','StickyArea','joinClasses'],(function a(b,c,d,e,f,g,h){var i,j;if(c.__markCompiled)c.__markCompiled();var k=c('React').PropTypes;i=babelHelpers.inherits(l,c('React').Component);j=i&&i.prototype;l.prototype.componentDidMount=function(){'use strict';this.$StickyArea1=new (c('StickyArea'))(c('ReactDOM').findDOMNode(this),true,this.props.offset||0,{boundToContainer:this.props.boundToContainer,stickTo:this.props.stickTo});};l.prototype.componentDidUpdate=function(m){'use strict';if(this.props.offset!==m.offset)this.$StickyArea1.setOffset(this.props.offset);c('StickyArea').reflow();};l.prototype.componentWillUnmount=function(){'use strict';this.$StickyArea1.destroy();this.$StickyArea1=null;};l.prototype.render=function(){'use strict';return (c('React').createElement('div',babelHelpers['extends']({},this.props,{className:c('joinClasses')(this.props.className,"_k"),ref:'root'}),this.props.children));};function l(){'use strict';i.apply(this,arguments);}l.propTypes={boundToContainer:k.bool,stickTo:k.oneOf([c('StickyArea').stickTo.SCROLL_PARENT,c('StickyArea').stickTo.WINDOW]).isRequired};l.defaultProps={boundToContainer:true,stickTo:c('StickyArea').stickTo.WINDOW};f.exports=l;}),null); __d("XVideoPermalinkController",["XController"],(function a(b,c,d,e,f,g){c.__markCompiled&&c.__markCompiled();f.exports=c("XController").create("\/{vanity}\/videos\/{?set_token}\/{video_id}\/",{photo_id:{type:"Int"},set_token:{type:"String"},type:{type:"Enum",defaultValue:3,enumType:0},link_share:{type:"String"},subject:{type:"Int"},object_id:{type:"Int"},opaque_cursor:{type:"String"},legacy_user_id:{type:"Int"},legacy_photo_id:{type:"Int"},video_id:{type:"Int"},comment_id:{type:"Int"},notif_t:{type:"Bool",defaultValue:false},is_notification_preview:{type:"Bool",defaultValue:false},vanity:{type:"String"},reply_comment_id:{type:"Int"}});}),null);